[Python-3000] PEP for Metaclasses in Python 3000

Greg Ewing greg.ewing at canterbury.ac.nz
Tue Mar 13 11:10:06 CET 2007


Nick Coghlan wrote:
> Along similar lines, I'd be marginally happier with:
> 
>    class Bob(meta=Planet): pass

Is there some way we could remove the word "meta"
from the syntax altogether? I don't mind using
it in conversation, but it seems a tad too geeky
to have as an actual part of the language.

How about

   class Bob(Base1, Base2, class Planet):
     ...

i.e. we're saying what we want the class of the
class to be.

A benefit would be that the metaclass doesn't
end up as being one of the keyword args in the
first place, so there's no issue of whether to
strip it out or not.

--
Greg


More information about the Python-3000 mailing list