Message134254
I'm attaching the updated patch. Changes:
- Special casing objects we can't do the metaclass computation for.
- Tests for these.
- Adding tests for the order of __new__ calls.
The special case isn't just checking if the object is a class, but instead checking if "isinstance(obj, type) and issubclass(obj, type)", because I think only these are the objects we can do the metaclass calculation for. All other objects (including classes which are not "real" metaclasses (they do not derive from type) and functions) are used "as is", without any metaclass calculation. (It's late here, so it is quite possible that I've overlooked someting in this part.)
(I'm using "hg extdiff" because the normal hg diff results in a longer and harder to read patch, but if it's needed I will send a normal diff.) |
|
Date |
User |
Action |
Args |
2011-04-21 22:00:38 | daniel.urban | set | recipients:
+ daniel.urban, gvanrossum, georg.brandl, terry.reedy, amaury.forgeotdarc, ncoghlan, rodsenra, pwerneck, benjamin.peterson |
2011-04-21 22:00:37 | daniel.urban | set | messageid: <1303423237.86.0.90711424699.issue1294232@psf.upfronthosting.co.za> |
2011-04-21 22:00:36 | daniel.urban | link | issue1294232 messages |
2011-04-21 22:00:36 | daniel.urban | create | |
|