Find This Module

Peter Otten __peter__ at web.de
Thu Jul 5 04:34:54 EDT 2007


gregpinero at gmail.com wrote:

> I'm looking at the source for the module sre_compile.py and it does
> this import:
> 
> import _sre
> 
> But I can't find a file related to _sre anywhere.  Where is it?  

If you want the source code, have a look at

http://svn.python.org/view/python/trunk/Modules/_sre.c?rev=52147&view=markup

> And more generally, how does one find the location of a built in module?

For the source of modules written in C, built in or not, you have to look in
the source distribution. 

Peter





More information about the Python-list mailing list