(Retracted by #7927.)
Simon Cozens [Wed, 29 Nov 2000 14:48:20 +0000 (14:48 +0000)]
Subject: [PATCH] Is infinity a number?
Message-ID: <20001129144820.A31339@pembro33.pmb.ox.ac.uk>

p4raw-id: //depot/perl@7921

sv.c

diff --git a/sv.c b/sv.c
index d7b4c8b..f4732e1 100644 (file)
--- a/sv.c
+++ b/sv.c
@@ -2038,7 +2038,7 @@ Perl_looks_like_number(pTHX_ SV *sv)
     }
     while (isSPACE(*s))
        s++;
-    if (s >= send)
+    if (s >= send || sawinf)
        return numtype;
     if (len == 10 && memEQ(sbegin, "0 but true", 10))
        return IS_NUMBER_TO_INT_BY_ATOL;