__getattr__ functionality for modules?
Aahz
aahz at pythoncraft.com
Sun May 18 18:55:20 EDT 2003
In article <squfcv03b21tog08han1nan2bbnr1pj5vt at 4ax.com>,
Stefan Franke <franke at ableton.com> wrote:
>
>Is there a way to achieve for modules what overriding __getattr__ does
>for classes?
Nope, and Guido is violently opposed to making this possible. Why not
just use a class?
(To Alex, Stefan isn't about using getattr(), he's asking about
<module>.__getattr__())
--
Aahz (aahz at pythoncraft.com) <*> http://www.pythoncraft.com/
"In many ways, it's a dull language, borrowing solid old concepts from
many other languages & styles: boring syntax, unsurprising semantics,
few automatic coercions, etc etc. But that's one of the things I like
about it." --Tim Peters on Python, 16 Sep 93
More information about the Python-list
mailing list