Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-23 Thread Nick Coghlan
On Tue, Nov 23, 2010 at 2:46 AM, exar...@twistedmatrix.com wrote: On 04:24 pm, solip...@pitrou.net wrote: On Mon, 22 Nov 2010 17:08:36 +0100 Hrvoje Niksic hrvoje.nik...@avl.com wrote: On 11/22/2010 04:37 PM, Antoine Pitrou wrote: +1.  The problem with int constants is that the int gets

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-22 Thread Nick Coghlan
On Mon, Nov 22, 2010 at 10:54 AM, Éric Araujo mer...@netwok.org wrote: +.. function:: getgeneratorstate(generator) + +    Get current state of a generator-iterator. + +    Possible states are: +      GEN_CREATED: Waiting to start execution. +      GEN_RUNNING: Currently being executed by

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-22 Thread Michael Foord
On 22/11/2010 15:14, Nick Coghlan wrote: On Mon, Nov 22, 2010 at 10:54 AM, Éric Araujomer...@netwok.org wrote: +.. function:: getgeneratorstate(generator) + +Get current state of a generator-iterator. + +Possible states are: + GEN_CREATED: Waiting to start execution. +

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-22 Thread Antoine Pitrou
On Mon, 22 Nov 2010 15:19:04 + Michael Foord fuzzy...@voidspace.org.uk wrote: On 22/11/2010 15:14, Nick Coghlan wrote: On Mon, Nov 22, 2010 at 10:54 AM, Éric Araujomer...@netwok.org wrote: +.. function:: getgeneratorstate(generator) + +Get current state of a generator-iterator.

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-22 Thread Nick Coghlan
On Tue, Nov 23, 2010 at 1:19 AM, Michael Foord fuzzy...@voidspace.org.uk wrote: On 22/11/2010 15:14, Nick Coghlan wrote: On Mon, Nov 22, 2010 at 10:54 AM, Éric Araujomer...@netwok.org  wrote: +    Possible states are: +      GEN_CREATED: Waiting to start execution. +      GEN_RUNNING:

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-22 Thread Hrvoje Niksic
On 11/22/2010 04:37 PM, Antoine Pitrou wrote: +1. The problem with int constants is that the int gets printed, not the name, when you dump them for debugging purposes :) Well, it's trivial to subclass int to something with a nicer __repr__. PyGTK uses that technique for wrapping C enums:

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-22 Thread Antoine Pitrou
On Mon, 22 Nov 2010 17:08:36 +0100 Hrvoje Niksic hrvoje.nik...@avl.com wrote: On 11/22/2010 04:37 PM, Antoine Pitrou wrote: +1. The problem with int constants is that the int gets printed, not the name, when you dump them for debugging purposes :) Well, it's trivial to subclass int to

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-22 Thread Michael Foord
On 22/11/2010 16:24, Antoine Pitrou wrote: On Mon, 22 Nov 2010 17:08:36 +0100 Hrvoje Niksichrvoje.nik...@avl.com wrote: On 11/22/2010 04:37 PM, Antoine Pitrou wrote: +1. The problem with int constants is that the int gets printed, not the name, when you dump them for debugging purposes :)

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-22 Thread exarkun
On 04:24 pm, solip...@pitrou.net wrote: On Mon, 22 Nov 2010 17:08:36 +0100 Hrvoje Niksic hrvoje.nik...@avl.com wrote: On 11/22/2010 04:37 PM, Antoine Pitrou wrote: +1. The problem with int constants is that the int gets printed, not the name, when you dump them for debugging purposes :)

Re: [Python-Dev] [Python-checkins] r86633 - in python/branches/py3k: Doc/library/inspect.rst Doc/whatsnew/3.2.rst Lib/inspect.py Lib/test/test_inspect.py Misc/NEWS

2010-11-21 Thread Éric Araujo
Author: nick.coghlan New Revision: 86633 Issue #10220: Add inspect.getgeneratorstate(). Initial patch by Rodolpho Eckhardt Modified: python/branches/py3k/Doc/library/inspect.rst == ---