[Patches] [ python-Patches-586561 ] Better token-related error messages
noreply@sourceforge.net
noreply@sourceforge.net
Thu, 25 Jul 2002 09:21:33 -0700
Patches item #586561, was opened at 2002-07-25 11:21
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=586561&group_id=5470
Category: Parser/Compiler
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Skip Montanaro (montanaro)
Assigned to: Jeremy Hylton (jhylton)
Summary: Better token-related error messages
Initial Comment:
There were some complaints recently on c.l.py about the rather
non-informative error messages emitted as a result of the tokenizer
detecting a problem. In many situations it simply returns
E_TOKEN which generates a fairly benign, but often unhelpful
"invalid token" message.
This patch adds several new E_* macrosto Includes/errorcode.h,
returns them from the appropriate places in Parser/tokenizer.c and
generates more specific messages in Python/pythonrun.c. I think the
error messages are always better, though in some situations they may
still not be strictly correct.
Assigning to Jeremy since he's the compiler wiz.
Skip
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=586561&group_id=5470