[Python-Dev] Re: Re: Call for defense of @decorators

"Martin v. Löwis" martin at v.loewis.de
Sat Aug 7 11:31:29 CEST 2004


Florian Schulze wrote:
> Does it really need to be only one character? Would this make the 
> parser  to complicated? If not, I would propose '::' which stands out 
> much more  than ':'

Anything involving colon might break tools who believe that in Python,
the colon opens a block. Of course, it might then also be that these
tools recognize that there text after the colon (both after the first
and after the second one), and assume that this uses the single-line
version of suite.

> What about '~'?

It already is a unary operator:

 >>> def foo():
...   return 1
...
 >>> ~foo()
-2

Regards,
Martin


More information about the Python-Dev mailing list