[Python-Dev] Re: PEP 318: Can't we all just get along?
Jp Calderone
exarkun at divmod.com
Thu Aug 19 22:09:21 CEST 2004
Bob Ippolito wrote:
>
> class Foo(object):
> __metaclass__ = Bar
> ...
>
> is *much* different than
>
> class Foo(object):
> ...
> Foo = barEquivalentFunction(Foo)
>
> which is the same as
>
> @barEquivalentFunction
> class Foo(object):
> ...
>
Only if you choose to write it such that it is different. Either can
result in effects that persist down the inheritence tree, and either can
result in effects that do not.
Jp
More information about the Python-Dev
mailing list