Added some SELF_TYPE checking