New issue 2639: PyPy3.5 should allow assigning to module object __class__ https://bitbucket.org/pypy/pypy/issues/2639/pypy35-should-allow-assigning-to-module
Nathaniel Smith: I was trying to use [`metamodule`](https://github.com/njsmith/metamodule) on pypy3 5.8.0, but it doesn't work: unlike CPython, you can't assign to module object's `__class__` attribute. This is a narrow exception to the normal "`__class__` assignment is only for heap types" rule that was added in CPython 3.5 – now the rule is "only heap types or modules". [CPython source.](https://github.com/python/cpython/blob/772d809a63f40fd35679da3fb115cdf7fa81bd20/Objects/typeobject.c#L3813-L3870) PyPy should implement this too so I can deprecate module attributes :-) _______________________________________________ pypy-issue mailing list [email protected] https://mail.python.org/mailman/listinfo/pypy-issue
