[docs] [issue31567] Inconsistent documentation around decorators
report at bugs.python.org
Thu Oct 12 11:29:25 EDT 2017
Éric Araujo <merwok at netwok.org> added the comment:
I think existing uses of the decorator markup rely on the reader’s understanding that it’s syntactic sugar for a call and an assignment, and they don’t have decorator+function markup. The PRs for this ticket follow that.
That said, staticmethod as a non-decorator has an important use case for function injection in tests (using self.func in TestCase classes that work with a C module and an equivalent Python version). Maybe this deserves an extra example?
Python tracker <report at bugs.python.org>
More information about the docs