I'll update this node with the outcome of that reportSeems it's a known bug (ticket #41202 from nearly 3 years ago) - and perhaps it's worthy of a separate post instead of an update.
I haven't found a build of perl that's not affected (and I've got quite a few) across intel (MS Windows), amd64 (Ubuntu) and PowerPC (debian) machines.
However, on some systems it's an off-by-one discrepancy , whereas on other systems it's off-by-two. (These could well be different bugs.)
And it seems to not occur across the full range of exponents ... so, for most perl purposes it's probably not much of an issue.
Still, it annoyed me enough to write a Math::NV module whose nv($str) function will assign the "C" value of $str to an NV - the assumption being that "C" gets it right. (It's an assumption I've tested against what both Data::Float and the mpfr library reckon is the correct representation but, with so many different versions of compiler/libc around, there's always a possibility of a bug to muddy the waters.)
Cheers,
Rob
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.