Fix comparison of Type objects