{BUG] In number coercion!
Brent Simmons
brent at userland.com
Mon Oct 8 14:24:52 PDT 2001
David -- thanks for the report.
-Brent
On Mon, 8 Oct 2001, David A. Bayly wrote:
> The following quickscript
>
> number("2,1")
>
> returns the value 21.
>
> All other non numeric characters that I tried in place of the comma
> correctly yield an error citing non numeric characters. 2.1 returns
> 2 as expected.
>
> Mac 9.1 US system, Frontier 7.1.
>
> Took me ages to find this , it was tripping up the metadata plugin.
>
> Unfortunately, I have frequently used a construct like
>
> try
> number(s)
> else
> scriptError(s + " is not a number")
>
> Working around this is going to be extremely time consuming.
> --
>
> - David Bayly. Programmer and digest reader. dbayly at udena dot ch
> Digest Readers do it once a day.
>
>
More information about the Frontier-Server
mailing list