fglock has asked for the wisdom of the Perl Monks concerning the following question:

I've got a module test fail because Perl 5.9.0 stringifies infinity and minus infinity with extra spaces, like this:

" -Inf" " Inf"

I've already fixed my tests, but is this a bug in Perl 5.9.0?

Replies are listed 'Best First'.
Re: "infinity" stringification problem in Perl 5.9.0
by perrin (Chancellor) on Sep 04, 2003 at 03:12 UTC
    Perhaps you should ask the p5p mailing list, since there is no public release of perl 5.9.0 and the only people who would know anything about it are probably the ones on that list.
Re: "infinity" stringification problem in Perl 5.9.0
by Abigail-II (Bishop) on Sep 04, 2003 at 07:37 UTC
    Could you provide us with a short code fragment that produces the different stringification under the 5.9 and 5.8 tracks? Then I'll pass it on to p5p.

    Abigail

      $ perl -le 'print q(").(100**100**100).q(")' " Inf"

      (thanks go to David Dyck for kindly providing this)

        I just synced with the most recent version of 5.9.0, and I cannot reproduce this:
        $ /opt/perl/5.9.0/bin/perl -wle 'print q(").(100**100**100).q(")' "inf" $ /opt/perl/5.8.1/bin/perl -wle 'print q(").(100**100**100).q(")' "inf"

        That means that it's either fixed, or the stringification is done by some library, which works correctly on my platform, and not yours.

        Could you compile with the newest blead and see what happens? If you still get a problem, send a report to p5p, with the output of perl -V.

        Abigail