[m-rev.] fix mantis #308
zoltan.somogyi at runbox.com
Sat Feb 1 18:21:37 AEDT 2014
On Sat, 1 Feb 2014 18:17:09 +1100, Paul Bone <paul at bone.id.au> wrote:
> > +any_to_ground_in_ite_cond_nomax.m:036: In clause for `main(di, uo)':
> > +any_to_ground_in_ite_cond_nomax.m:036: in argument 1 of call to predicate `any_to_ground_in_ite_cond_nomax.p'/1:
> > +any_to_ground_in_ite_cond_nomax.m:036: scope error: attempt to bind a non-local variable inside the condition of an if-then-else.
> > +any_to_ground_in_ite_cond_nomax.m:036: Variable `X' has instantiatedness `any',
> > +any_to_ground_in_ite_cond_nomax.m:036: expected instantiatedness was `ground'.
> > +For more information, recompile with `-E'.
> Are error messages made up from different paragraphs? There are multiple
> lines in this error message.
Yes, error messages are made up of several components. Each component is supposed to have
a meaning. In this case, there are separate paragraphs for (1) the context, (2) the nature of the error,
(3) and (4) the two things whose mismatch is the error.
> Matthias, Zoltan has added a --no-max-error-line-width to Mercury. However
> my guess is that it doesn't quite do what you want, it appears that there
> are no line limits in the error messages but there are still multiple lines
> per error. Does this address the problem you were having or do you need all
> the newlines removed?
I wrote the diff this way because I thought this output would be the easiest format to postprocess
automatically. However, if you (Matthias) want every component squished together into one giant line, that
could be arranged easily as well. The only things is, since one-paragraph-per line and all-paragraphs-per-line
are both useful behaviors, we need an option to specify which behavior is requested.
More information about the reviews