[metapost] Bug with simple number comparisons with new number systems
Toby Thurston
thurston at eml.cc
Tue Jul 28 09:21:55 CEST 2015
I'm getting strange results comparing numbers with the new number systems.
Consider this program:
show 0.0001 < 0.001, numbersystem, mpversion; end.
With the default number system this gives
>> true
>> "scaled"
>> "1.999" )
on my log. But with the other number systems I get:
>> true
>> "double"
>> "1.999" )
>> false
>> "binary"
>> "1.999" )
>> false
>> "decimal"
>> "1.999" )
which is a bit unexpected...
I'm using a version I compiled myself from source after you fixed the normaldeviate bug a couple of months ago.
Testing with V1.902, the only other version I have on hand, I only get the error with "decimal". But it does not appear to matter what numbers I use. I get the same results with "1<2", or "1/4<1/2", etc
This is MetaPost, version 1.902 (TeX Live 2014) (kpathsea version 6.2.0)
>> true
>> "scaled" )
This is MetaPost, version 1.902 (TeX Live 2014) (kpathsea version 6.2.0)
>> true
>> "double" )
This is MetaPost, version 1.902 (TeX Live 2014) (kpathsea version 6.2.0)
>> true
>> "binary" )
This is MetaPost, version 1.902 (TeX Live 2014) (kpathsea version 6.2.0)
>> false
>> "decimal" )
I've posted an entry on the tracker. Toby
More information about the metapost
mailing list