I wrote:
> I googled a bit and found these recommendations on stackoverflow:
> my $inf    = 9**9**9;
> my $neginf = -9**9**9;
> my $nan    = -sin(9**9**9);
> These do seem to produce the desired results, at least on the
> couple of Perl versions I checked, including 5.8.3.

Nope, buildfarm shows that still doesn't work everywhere.

If we had a transform function that converted SQL float8 directly
to Perl NV, we could use that to produce NVs containing inf/nan.
But that would be a pretty ridiculous amount of test scaffolding
to create to test what, in the end, is two lines of very
straightforward and unlikely-to-break code.

My recommendation is just to drop these test cases.  Getting them
to work on all old Perl versions is more trouble than they're worth.

                        regards, tom lane

Reply via email to