https://bugzilla.wikimedia.org/show_bug.cgi?id=18233

           Summary: nondeterministic #expr rounding error
           Product: MediaWiki extensions
           Version: any
          Platform: All
               URL: http://hu.wikipedia.org/w/index.php?title=Wikip%C3%A9dia
                    :Kocsmafal_(m%C5%B1szaki)&oldid=5211133#Sz.C3.A1m.C3.ADt
                    .C3.A1sok
        OS/Version: All
            Status: NEW
          Severity: minor
          Priority: Normal
         Component: ParserFunctions
        AssignedTo: [email protected]
        ReportedBy: [email protected]


{{#expr: 1000.33 - 1000}} sometimes evaluates to 0.33, other times to
0.33000000000004 (the second one happens far more often). I'm not sure which
one is correct (it has the right magnitude for a floating point precision
error, 0.00000000000004 being about the 10^17-th part of 1000, and 2^53 ~=
10^16 (a double uses 53 bits for the mantissa), though as far as my
understanding of floating point arithmetic goes, that should be rounded off),
but the nondeterministic behavior is definitely weird.


-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to