[Python-Dev] (Specific syntax of) PEP 318 - function/method/class decoration

Greg Ewing greg at cosc.canterbury.ac.nz
Mon Mar 8 18:07:36 EST 2004


"Phillip J. Eby" <pje at telecommunity.com>:

> The positioning is different, though.  C# puts the bracketed list of 
> "attributes" at the *beginning* of the declarations, so if we were really 
> following C#'s lead, the syntax would actually be:
> 
> class [interface] Foo:

I don't think we should be following the C style of putting variable
amounts of stuff in front of the name being declared.  It pushes the
names into unpredictable positions and makes it hard to visually scan
down a list of declarations looking for something.

The proposed syntax has things in just the right order, IMO.

Greg Ewing, Computer Science Dept, +--------------------------------------+
University of Canterbury,	   | A citizen of NewZealandCorp, a	  |
Christchurch, New Zealand	   | wholly-owned subsidiary of USA Inc.  |
greg at cosc.canterbury.ac.nz	   +--------------------------------------+



More information about the Python-Dev mailing list