[Python-ideas] Statement local functions and classes (aka PEP 3150 is dead, say 'Hi!' to PEP 403)

Ka-Ping Yee python at zesty.ca
Thu Oct 13 08:24:54 CEST 2011


I don't see why the leading colon is necessary, actually.  Isn't
the presence of a bare @ enough to signal that a function or class
definition must come next?

It reads more cleanly and naturally without the colon, to me:

     return sorted(original, key=@)
     def normalize(item):
         return item.strip().lower()


--Ping



More information about the Python-ideas mailing list