[Import-sig] Imputil
Guido van Rossum
guido@digicool.com
Fri, 09 Feb 2001 00:58:33 -0500
OK, I see that there's some convergence here. It appears that most
uses of PyImport_ImportModule() should really be using
PyImport_Import() instead. There are two solutions: change the body
of PyImport_ImportModule() to call PyImport_Import(), or change all
(most?) calls to PyImport_ImportModule() to use PyImport_Import()
instead.
I'd vote for the former -- it's less work and more effective. Note
that those places that really need to use the built-in import
primitive (e.g. the default built-in __import__ function) can use
PyImport_ImportModuleEx(). __import__ already does this.
Somebody submit a patch (or just check it in if you're feeling very
confident :-), please...
--Guido van Rossum (home page: http://www.python.org/~guido/)