link vs import

Brian Rowe roweb004 at hawaii.rr.com
Fri May 25 18:36:03 EDT 2001


In article <9elnm40131d at enews2.newsguy.com>, "Alex Martelli"
<aleaxit at yahoo.com> wrote:

> PyImport_AppendInittab will let you add your module to the table of
> "built-in" modules.  PyImport_ImportModule lets you "load" it.  You may
> then place an entry for it in module '__builtin__' or wherever you wish.
>  Is that what you mean...?

So if I link it in at compile time and do a PyImport_AppendInittab on it,
and then later in my scripts that need it call PyImport_ImportModule I'll
then have access to it from the scripts?



More information about the Python-list mailing list