Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where can I get the source code of module __builtin__ in python?

Tags:

python

where can I get the source code for module builtin in python ? I am interested in version 2.6.x.

like image 413
Ankur Agarwal Avatar asked Jun 04 '26 22:06

Ankur Agarwal


2 Answers

Go to the folder you installed the Python libraries in, check under the version\Python folder - you should find the bltinmodule.c file.

Something along the lines of C:\python\2.X\Python

On CentOS it's...

root@xenos ~> locate bltinmodule.c
/usr/src/debug/Python-2.5.1/Python/bltinmodule.c
/usr/src/debug/Python-2.6.4/Python/bltinmodule.c

Perhaps you need http://packages.ubuntu.com/dapper/python-dev

like image 177
dotalchemy Avatar answered Jun 07 '26 10:06

dotalchemy


The easiest place to find the CPython source code is the web view of the Mercurial repository: http://hg.python.org/cpython/file/2.6/Python/bltinmodule.c

(Updated link to refer to the copy in Mercurial, although 2.6 security releases happened from the SVN repo)

like image 38
ncoghlan Avatar answered Jun 07 '26 12:06

ncoghlan



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!