Decorated class question

Devin Jeanpierre jeanpierreda at
Mon Jan 16 11:18:51 EST 2012

On Mon, Jan 16, 2012 at 10:10 AM, deathweaselx86 <deathweasel at> wrote:
> If I decorate a class, then subclass it, does my subclass feature
> whatever the decorator did to my superclass?

Yes. The following two things are completely equivalent:

class Bar(...):

# and

class Bar(...)
# immediately afterward
Bar = foo(Bar)

-- Devin

More information about the Python-list mailing list