Why new Python 2.5 feature "class C()" return old-style class ?

Felipe Almeida Lessa felipe.lessa at gmail.com
Tue Apr 11 12:44:56 EDT 2006


Em Ter, 2006-04-11 às 07:17 -0700, Aahz escreveu:
> Can, yes.  But should it?  The whole point of adding the () option to
> classes was to ease the learning process for newbies who don't
> understand why classes have a different syntax from functions.  Having
> 
> class C(): pass
> 
> behave differently from
> 
> class C: pass
> 
> would be of no benefit for that purpose.

Why should a newbie use an old-style class?

-- 
Felipe.




More information about the Python-list mailing list