Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #35038 > unrolled thread
| Started by | iMath <redstone-cold@163.com> |
|---|---|
| First post | 2012-12-17 21:25 -0800 |
| Last post | 2012-12-18 03:55 -0500 |
| Articles | 12 — 6 participants |
Back to article view | Back to comp.lang.python
where to view open() function's C implementation source code ? iMath <redstone-cold@163.com> - 2012-12-17 21:25 -0800
Re: where to view open() function's C implementation source code ï¼ Roy Smith <roy@panix.com> - 2012-12-18 00:35 -0500
Re: where to view open() function's C implementation source code � iMath <redstone-cold@163.com> - 2012-12-17 22:32 -0800
Re: where to view open() function's C implementation source code ? Roy Smith <roy@panix.com> - 2012-12-18 09:28 -0500
Re: where to view open() function's C implementation source code ? Chris Angelico <rosuav@gmail.com> - 2012-12-19 02:03 +1100
Re: where to view open() function's C implementation source code ? Andrew Robinson <andrew3@r3dsolutions.com> - 2012-12-18 13:09 -0800
Re: where to view open() function's C implementation source code � rurpy@yahoo.com - 2012-12-18 12:57 -0800
Re: where to view open() function's C implementation source code � rurpy@yahoo.com - 2012-12-18 13:15 -0800
Re: where to view open() function's C implementation source code � iMath <redstone-cold@163.com> - 2012-12-18 15:55 -0800
Re: where to view open() function's C implementation source code � iMath <redstone-cold@163.com> - 2012-12-18 15:55 -0800
Re: where to view open() function's C implementation source code � rurpy@yahoo.com - 2012-12-18 20:49 -0800
Re: where to view open() function's C implementation source code ? Terry Reedy <tjreedy@udel.edu> - 2012-12-18 03:55 -0500
| From | iMath <redstone-cold@163.com> |
|---|---|
| Date | 2012-12-17 21:25 -0800 |
| Subject | where to view open() function's C implementation source code ? |
| Message-ID | <f3af9605-2dc7-40a9-861f-52724d29bf1e@googlegroups.com> |
where to view open() function's C implementation source code ?
[toc] | [next] | [standalone]
| From | Roy Smith <roy@panix.com> |
|---|---|
| Date | 2012-12-18 00:35 -0500 |
| Subject | Re: where to view open() function's C implementation source code ï¼ |
| Message-ID | <roy-9CAF53.00355818122012@news.panix.com> |
| In reply to | #35038 |
In article <f3af9605-2dc7-40a9-861f-52724d29bf1e@googlegroups.com>, iMath <redstone-cold@163.com> wrote: > where to view open() function's C implementation source code ? http://www.python.org/download/releases/ Download the source for the version you're interested in.
[toc] | [prev] | [next] | [standalone]
| From | iMath <redstone-cold@163.com> |
|---|---|
| Date | 2012-12-17 22:32 -0800 |
| Subject | Re: where to view open() function's C implementation source code � |
| Message-ID | <ad040201-ba94-496c-bb17-7433b0e09d9d@googlegroups.com> |
| In reply to | #35040 |
在 2012年12月18日星期二UTC+8下午1时35分58秒,Roy Smith写道: > In article <f3af9605-2dc7-40a9-861f-52724d29bf1e@googlegroups.com>, > > iMath <redstone-cold@163.com> wrote: > > > > > where to view open() function's C implementation source code ? > > > > http://www.python.org/download/releases/ > > > > Download the source for the version you're interested in. but which python module is open() in ?
[toc] | [prev] | [next] | [standalone]
| From | Roy Smith <roy@panix.com> |
|---|---|
| Date | 2012-12-18 09:28 -0500 |
| Subject | Re: where to view open() function's C implementation source code ? |
| Message-ID | <roy-0389D1.09281918122012@news.panix.com> |
| In reply to | #35041 |
In article <ad040201-ba94-496c-bb17-7433b0e09d9d@googlegroups.com>, iMath <redstone-cold@163.com> wrote: > � 2012N1218����UTC+8��1时35分58秒,Roy Smith写道: > > In article <f3af9605-2dc7-40a9-861f-52724d29bf1e@googlegroups.com>, > > > > iMath <redstone-cold@163.com> wrote: > > > > > > > > > where to view open() function's C implementation source code ? > > > > > > > > http://www.python.org/download/releases/ > > > > > > > > Download the source for the version you're interested in. > > but which python module is open() in ? I met you half-way, I showed you where the source code is. Now you need to come the other half and look at the code. Maybe start by grepping the entire source tree for "open"?
[toc] | [prev] | [next] | [standalone]
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2012-12-19 02:03 +1100 |
| Subject | Re: where to view open() function's C implementation source code ? |
| Message-ID | <mailman.1019.1355843015.29569.python-list@python.org> |
| In reply to | #35057 |
On Wed, Dec 19, 2012 at 1:28 AM, Roy Smith <roy@panix.com> wrote: > In article <ad040201-ba94-496c-bb17-7433b0e09d9d@googlegroups.com>, > iMath <redstone-cold@163.com> wrote: >> > Download the source for the version you're interested in. >> >> but which python module is open() in ? > > I met you half-way, I showed you where the source code is. Now you > need to come the other half and look at the code. Maybe start by > grepping the entire source tree for "open"? Ouch, that mightn't be very effective! With some function names, you could do that. Not so much "open". Still, it'd be a start... ChrisA
[toc] | [prev] | [next] | [standalone]
| From | Andrew Robinson <andrew3@r3dsolutions.com> |
|---|---|
| Date | 2012-12-18 13:09 -0800 |
| Subject | Re: where to view open() function's C implementation source code ? |
| Message-ID | <mailman.1027.1355861508.29569.python-list@python.org> |
| In reply to | #35057 |
On 12/18/2012 07:03 AM, Chris Angelico wrote: > On Wed, Dec 19, 2012 at 1:28 AM, Roy Smith<roy@panix.com> wrote: >> In article<ad040201-ba94-496c-bb17-7433b0e09d9d@googlegroups.com>, >> iMath<redstone-cold@163.com> wrote: >>>> Download the source for the version you're interested in. >>> but which python module is open() in ? >> I met you half-way, I showed you where the source code is. Now you >> need to come the other half and look at the code. Maybe start by >> grepping the entire source tree for "open"? > Ouch, that mightn't be very effective! With some function names, you > could do that. Not so much "open". Still, it'd be a start... > > ChrisA In Python3.3.0 -- the built in open() appears in Python-3.3.0/Modules/_io/_iomodule.c; There is another module defined in an object in Python-3.3.0/Modules/_io/fileio.c; but I don't think that the one called when a lone x=open(...) is done. Cheers. --Andrew.
[toc] | [prev] | [next] | [standalone]
| From | rurpy@yahoo.com |
|---|---|
| Date | 2012-12-18 12:57 -0800 |
| Subject | Re: where to view open() function's C implementation source code � |
| Message-ID | <d487f302-2e0c-4a53-b3b3-1f263c7665a6@googlegroups.com> |
| In reply to | #35040 |
On Monday, December 17, 2012 10:35:58 PM UTC-7, Roy Smith wrote: > iMath <redstone-cold@163.com> wrote: > > where to view open() function's C implementation source code ? > http://www.python.org/download/releases/ > Download the source for the version you're interested in. iMath: There is no need to download the source. You can browse the source code online. For the v3.0.0 version of open(): hg.python.org/cpython/file/bd8afb90ebf2/Modules/_io/_iomodule.c For 2.7.3 I think what you want is the builtin_open() function in http://hg.python.org/cpython/file/70274d53c1dd/Python/bltinmodule.c and the file object and open_the_file() function in http://hg.python.org/cpython/file/70274d53c1dd/Objects/fileobject.c Hope this helps.
[toc] | [prev] | [next] | [standalone]
| From | rurpy@yahoo.com |
|---|---|
| Date | 2012-12-18 13:15 -0800 |
| Subject | Re: where to view open() function's C implementation source code � |
| Message-ID | <a9562a9b-f143-49e9-a9c1-ca7802dc03db@googlegroups.com> |
| In reply to | #35071 |
On Tuesday, December 18, 2012 1:57:37 PM UTC-7, ru...@yahoo.com wrote: >[...] > source code online. For the v3.0.0 version of open(): > hg.python.org/cpython/file/bd8afb90ebf2/Modules/_io/_iomodule.c oops, that should have been: http://hg.python.org/cpython/file/bd8afb90ebf2/Modules/_io/_iomodule.c
[toc] | [prev] | [next] | [standalone]
| From | iMath <redstone-cold@163.com> |
|---|---|
| Date | 2012-12-18 15:55 -0800 |
| Subject | Re: where to view open() function's C implementation source code � |
| Message-ID | <ed9d199b-e078-4481-959e-cf71ccb5d662@googlegroups.com> |
| In reply to | #35071 |
在 2012年12月19日星期三UTC+8上午4时57分37秒,ru...@yahoo.com写道: > On Monday, December 17, 2012 10:35:58 PM UTC-7, Roy Smith wrote: > > > iMath <redstone-cold@163.com> wrote: > > > > where to view open() function's C implementation source code ? > > > http://www.python.org/download/releases/ > > > Download the source for the version you're interested in. > > > > iMath: > > > > There is no need to download the source. You can browse the > > source code online. For the v3.0.0 version of open(): > > hg.python.org/cpython/file/bd8afb90ebf2/Modules/_io/_iomodule.c > > > > For 2.7.3 I think what you want is the builtin_open() function in > > http://hg.python.org/cpython/file/70274d53c1dd/Python/bltinmodule.c > > and the file object and open_the_file() function in > > http://hg.python.org/cpython/file/70274d53c1dd/Objects/fileobject.c > > > > Hope this helps. thanks very much !
[toc] | [prev] | [next] | [standalone]
| From | iMath <redstone-cold@163.com> |
|---|---|
| Date | 2012-12-18 15:55 -0800 |
| Subject | Re: where to view open() function's C implementation source code � |
| Message-ID | <9b82d14c-6e1f-4bf6-8683-97d0537656fd@googlegroups.com> |
| In reply to | #35071 |
在 2012年12月19日星期三UTC+8上午4时57分37秒,ru...@yahoo.com写道: > On Monday, December 17, 2012 10:35:58 PM UTC-7, Roy Smith wrote: > > > iMath <redstone-cold@163.com> wrote: > > > > where to view open() function's C implementation source code ? > > > http://www.python.org/download/releases/ > > > Download the source for the version you're interested in. > > > > iMath: > > > > There is no need to download the source. You can browse the > > source code online. For the v3.0.0 version of open(): > > hg.python.org/cpython/file/bd8afb90ebf2/Modules/_io/_iomodule.c > > > > For 2.7.3 I think what you want is the builtin_open() function in > > http://hg.python.org/cpython/file/70274d53c1dd/Python/bltinmodule.c > > and the file object and open_the_file() function in > > http://hg.python.org/cpython/file/70274d53c1dd/Objects/fileobject.c > > > > Hope this helps. thanks very much !
[toc] | [prev] | [next] | [standalone]
| From | rurpy@yahoo.com |
|---|---|
| Date | 2012-12-18 20:49 -0800 |
| Subject | Re: where to view open() function's C implementation source code � |
| Message-ID | <80b8a52c-9649-4c5a-8e2e-19531afd709c@googlegroups.com> |
| In reply to | #35083 |
On 12/18/2012 04:55 PM, iMath wrote: > > 在 2012年12月19日星期三UTC+8上午4时57分37秒,ru...@yahoo.com写道: > >[...] >> >> There is no need to download the source. You can browse the >> >> source code online. For the v3.0.0 version of open(): >> >> hg.python.org/cpython/file/bd8afb90ebf2/Modules/_io/_iomodule.c >> >> >> >> For 2.7.3 I think what you want is the builtin_open() function in >> >> http://hg.python.org/cpython/file/70274d53c1dd/Python/bltinmodule.c >> >> and the file object and open_the_file() function in >> >> http://hg.python.org/cpython/file/70274d53c1dd/Objects/fileobject.c >> >> >> >> Hope this helps. > > > > thanks very much ! Your welcome. I noticed that you, like me, are using Google Groups. You might want to read this page about posting from Google Groups: http://wiki.python.org/moin/GoogleGroupsPython It will help you avoid double posts and other Google Groups posting problems that annoy other people here.
[toc] | [prev] | [next] | [standalone]
| From | Terry Reedy <tjreedy@udel.edu> |
|---|---|
| Date | 2012-12-18 03:55 -0500 |
| Message-ID | <mailman.1010.1355820967.29569.python-list@python.org> |
| In reply to | #35038 |
On 12/18/2012 12:25 AM, iMath wrote: > where to view open() function's C implementation source code ? depends on the python version. io in 3.x otherwise, it is a builtin -- Terry Jan Reedy
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.python
csiph-web