Better looks_like_number() function [sv.c]
authorGisle Aas <aas@bergen.sn.no>
Fri, 14 Feb 1997 17:08:52 +0000 (18:08 +0100)
committerChip Salzenberg <chip@atlantic.net>
Tue, 18 Feb 1997 01:22:00 +0000 (13:22 +1200)
commit8dbaa58ee2aba7cc22d84199a674c58bbf108b46
treea3b3a3ac667d805ccba40b7dfad749a81be1747c
parentf65adc383296c14b415f0ade0cf7fc4a27049a24
Better looks_like_number() function [sv.c]

The old looks_like_number() function was too forgiving.  It classified
strings like these as numbers:

   "+"
   "+e+"
   "e3"
   "."

With this patch perl -lwe 'print int(".")' prints:

   Argument "." isn't numeric in int at -e line 1.
   0

as it should and perl still passes all its tests.

p5p-msgid: <199702141708.SAA17546@bergen.sn.no>
sv.c