> My users want extension modules to be able to control how their > attributes are imported when using "import *". In particular, > Boost.Python includes a kind of multimethod facility, and some of my > users would like it if > > from bpl_extension import * > > caused multimethod definitions in bpl_extension to be /merged/ into > the current module, rather than replacing any multimethod bindings > with the same name in the current module. Alas, the current import hooking mechanisms don't allow control over this (the interpretation of * is hardcoded). Feel free to suggest an API and/or implementation of a hook for that, after reading how it's done now. The crucial code is import_all_from() in ceval.c. --Guido van Rossum (home page: http://www.python.org/~guido/)
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