From: Ken A. <kan...@bb...> - 2002-12-30 18:10:09
|
Hi Johathan, What's happening here is that one of the JScheme extensions is to allow the use of Java syntax for numbers. You can turn it off with: > (set! U.useJavaSyntax$ #f) #t > (string->number "01438") 1438 Because of the leading "0" JScheme attempts to read the string in octal. Because of the "8" an exception is thrown. Our code catches the exception and simply tries to read the string as a float, which succeeds. Clearly it should throw an error, which might have at least given you a hint. I'll work to Tim to clean this up, thanks. k At 10:48 AM 12/30/2002, Jonathan A Rees wrote: >I believe the following behavior is incorrect (according to the scheme >report). > > Jscheme 5.0 04/05/2002 http://jscheme.sourceforge.net > > (string->number "01438") > 1438.0 > > > >It should be more like the following: > > > (string->number "1438") > 1438 > > > >Jonathan > > >------------------------------------------------------- >This sf.net email is sponsored by:ThinkGeek >Welcome to geek heaven. >http://thinkgeek.com/sf >_______________________________________________ >Jscheme-user mailing list >Jsc...@li... >https://lists.sourceforge.net/lists/listinfo/jscheme-user |