[Python-bugs-list] [ python-Bugs-456175 ] add dictionary "tokens" to token.py
noreply@sourceforge.net
noreply@sourceforge.net
Tue, 28 Aug 2001 08:48:27 -0700
Bugs item #456175, was opened at 2001-08-28 08:48
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=456175&group_id=5470
Category: Python Library
Group: Feature Request
Status: Open
Resolution: None
Priority: 5
Submitted By: Grant Griffin (dspguru)
Assigned to: Nobody/Anonymous (nobody)
Summary: add dictionary "tokens" to token.py
Initial Comment:
I would like for token.py to provide a dictionary,
called "tokens" that maps the name of each token to
its value, e.g.:
token.tokens[token.INDENT] is 'INDENT'
This would be useful for debugging programs that use
tokenize.
A user currently could create a dictionary like this
using introspection on token.py (assuming tokens are
in all caps) but that's a lot of trouble. Instead, I
believe it would be better to solve the problem once-
and-for-all by building the extra logic required to
create the dictionary into token.main.
thanks much,
=g2
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=456175&group_id=5470