[Python-ideas] Adding an "export" decorator in (e.g.) functools
Greg Ewing
greg.ewing at canterbury.ac.nz
Sat May 10 01:15:43 CEST 2014
Nick Coghlan wrote:
> You essentially have to use some
> form of dynamic scoping in order to modify __all__ in the right
> module, and then that limits your ability to wrap the export decorator
> inside other helper functions.
The version that uses the function's f_globals directly
doesn't have that problem.
--
Greg
More information about the Python-ideas
mailing list