}
}
else if (!SvPOKp(sv)) { /* require 5.005_03 */
- NV n = SvNV(sv);
- rev = (UV)n;
- ver = (UV)((n-rev)*1000);
- sver = (UV)((((n-rev)*1000 - ver) + 0.0009) * 1000);
-
if ((NV)PERL_REVISION + ((NV)PERL_VERSION/(NV)1000)
+ ((NV)PERL_SUBVERSION/(NV)1000000)
+ 0.00000099 < SvNV(sv))
{
+ NV nrev = SvNV(sv);
+ UV rev = (UV)nrev;
+ NV nver = (nrev - rev) * 1000;
+ UV ver = (UV)(nver + 0.0009);
+ NV nsver = (nver - ver) * 1000;
+ UV sver = (UV)(nsver + 0.0009);
+
DIE(aTHX_ "Perl v%"UVuf".%"UVuf".%"UVuf" required--this is only version "
"v%d.%d.%d, stopped", rev, ver, sver, PERL_REVISION,
PERL_VERSION, PERL_SUBVERSION);
# don't make this lexical
$i = 1;
-print "1..18\n";
+print "1..19\n";
sub do_require {
%INC = ();
print "ok ",$i++,"\n";
# check inaccurate fp
-#$ver = 10.2;
-#eval { require $ver; };
-#print "# $@\nnot " unless $@ =~ /^Perl v10\.200\.0 required/;
-#print "ok ",$i++,"\n";
+$ver = 10.2;
+eval { require $ver; };
+print "# $@\nnot " unless $@ =~ /^Perl v10\.200\.0 required/;
+print "ok ",$i++,"\n";
$ver = 10.000_02;
eval { require $ver; };