[Python-3000] PEP for Metaclasses in Python 3000

Greg Ewing greg.ewing at canterbury.ac.nz
Sun Mar 11 07:01:15 CET 2007


Josiah Carlson wrote:

>     class foo(...):
>         a = ...
>         __metaclass__ = callable(a, ...)

Personally I wouldn't mind if it were made a requirement
that __metaclass__, if it is present, must be the first
name bound in the class body (and can't be inside an
if statement, etc.)

Does anyone know of any actual code out there that
would be broken by this?

--
Greg



More information about the Python-3000 mailing list