After playing with decorators alittle I found that @-syntax is nearly optimal especially that it comes before def, but there are other things to keep in mind. 1. Decorators must transfer __doc__-strings and probably even add information about functions 2. As now functions could have arbitrary attributes, some mechanism must be in place to ensure this information is not lost. If it is purely up to the decorator to decide, we will end up with undocumented functions... Is it possible to change function inplace? Is it even an option? Sincerely yours, Roman Suzi -- rnd at onego.ru =\= My AI powered by GNU/Linux RedHat 7.3
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