[issue26576] Tweak wording of decorator docos

Terry J. Reedy report at bugs.python.org
Fri Mar 18 16:05:04 EDT 2016


Terry J. Reedy added the comment:

Guido, the discrepancy between the decorator doc's 'equivalent code' and actual, optimized, behavior with regard to skipping an intermediate binding of the function to the name came up soon after decorators were added.  I cannot find the issue, but as I remember, you said at the time that the doc's 'equivalent' code was good enough, and perhaps that you did not want to force the optimization on other implementations (not sure of this latter).

This issue has come up often enough on Python list and SO that many think that the actual behavior should be documented.  But should it be documented as a guaranteed language feature or as just an optional optimization?

----------
nosy: +gvanrossum, terry.reedy

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26576>
_______________________________________


More information about the Python-bugs-list mailing list