Re: [Pyparsing] better parse error reporting
Brought to you by:
ptmcg
From: Paul M. <pt...@au...> - 2008-04-09 01:18:37
|
Pyparsing includes the line, lineno, and col builtins. You can convert a location to the corresponding line of text by calling line(locn,string). -- Paul -----Original Message----- From: pyp...@li... [mailto:pyp...@li...] On Behalf Of W. Martin Borgert Third, with the numeric position, one can calculate the line number in a larger input file and print out the suspicious line(s). A convenience function for this would be nice in pyparsing, but maybe this is too application specific. |