I just tried to implement an autoloader using a technique
I'm sure I used in an earlier Python version, but it no
longer seems to be allowed.

I'm trying to change the __class__ of a newly-imported
module to a subclass of types.ModuleType, but I'm getting

   TypeError: __class__ assignment: only for heap types

Have the rules concerning assignent to __class__ been
made more restrictive recently?

-- 
Greg Ewing, Computer Science Dept, +--------------------------------------+
University of Canterbury,          | A citizen of NewZealandCorp, a       |
Christchurch, New Zealand          | wholly-owned subsidiary of USA Inc.  |
[EMAIL PROTECTED]          +--------------------------------------+
_______________________________________________
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