fix typeid to type
fix rule