Joshua Haberman wrote:
This is not as bad as having someone
set __class__ on one of my instances, or set attributes on my type, etc.

Is there any real need to prevent someone from doing
those things?

Note that even when you are allowed to change the
__class__ of an instance, you're still prevented
from changing it to something that has a different
C layout, so you can't crash the intepreter that
way.

Similarly, built-in methods check that they're
given an object of appropriate type at the C
level.

My suggestion is to just let it be a full heap
type and accept whatever consequences follow.

--
Greg
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to