[metapost] Bug report on metapost from texlive-2013

Taco Hoekwater taco at elvenkind.com
Wed Jan 29 15:22:22 CET 2014


On 27 Jan 2014, at 21:39, Pétiard François <petiard.francois at free.fr> wrote:
> I think the problem is operator precedence

Almost. The problem is the handling of the primitive spark “/“ at the 
end of a primarydef’s macro, when the next token is not a known 

The smallest erroneous case I could find was this one:

  a := 2**2/(3); % should give 1.333, but actually gives 3

and it is caused by the special precedence level associated with the 
"/<literal numeric>” construct (as used in e.g. 2/3a). There is code in
metapost that does a bit of backtracking in that case, and it is that
backtracking code that fails to push back the / operator properly. 

Now I only have to figure out how to fix it !

Best wishes,

More information about the metapost mailing list