> The one thing I do dislike about the new addition is the arbitrary (?) > restriction on expression allowed in a decorator. From Grammar.. > decorator: '@' dotted_name [ '(' [arglist] ')' ] > That seems quite odd to me. Is there some reason it couldn't be: > decorator: '@' test > ? The first patch on SF actually had '@' test, and I requested that it be changed. Most things that are 'test' but not 'dotted_name' optionally followed by an argument list don't make sense as decorators; if you really have a need to write @ foo or bar def f(): ... you can write deco = foo or bar @deco def f(): ... --Guido van Rossum (home page: http://www.python.org/~guido/)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4