[metapost] Finding line containg error in Metapost file
taco at elvenkind.com
Tue Jul 9 10:20:09 CEST 2013
On 07/09/2013 09:01 AM, Hans Hagen wrote:
> On 7/9/2013 1:18 AM, Peter Zeman wrote:
>> I would like to ask whether it is "algorithmically" possible to find
>> the line with error in a metapost file just with the information given
>> by "mpost". I mean, is the line with error uniquely determined by the
>> output of "mpost"?
>> I would like to write a program, which tells me the line containing
>> error. I know, that metapost gives me a line, but I would like to know
>> the exact line. For example if I have a macro with an error, I don't
>> want the line where the macro was used, but the line in the macro,
>> which contains the error. Is this possible?
> The error line is where the error shows up but errors can also be in
> macros that are defined anywhere so the best you can catch are typos or
> wrong calls
Metapost (and (XXX)TeX) error reporting is not a full backtrace, so no,
you cannot find the exact line. It would be a nice idea to have that
option, but I do not have plans to add such a feature right now.
More information about the metapost