bugGuile - Bugs: bug #31151, string->number radix only...

 
 

bug #31151: string->number radix only partly working

Submitted by:  -Deleted Account- <steele>
Submitted on:  Tue 28 Sep 2010 01:34:48 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: Fixed
Privacy: PublicAssigned to: None
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Mon 15 Nov 2010 10:41:12 PM UTC, comment #1:

Fixed in 1.9 git,. Thanks for the report!

Andy Wingo <wingo>
Project Administrator
Tue 28 Sep 2010 01:34:48 PM UTC, original submission:

Hello,

I'm using guile 1.8.7 and I see that (number->string 16 35) works (result is "g") but (string->number "g" 35) returns #f.

In string->number it works from "0" to "f", but higher numbers fail.

The guile docs http://www.gnu.org/software/guile/manual/html_node/Conversion.html say that string->number is only available with Radix 2 8 10 16 which is at least wrong.

I work with radix 7 all the time and it works fine.

And radix 35 works at least up to "f". After a short test it seems that all radixes work only up to "f", not only 35.

It would be great if this could be extended or at least can be documented correctly (that all radices up to 16 work fine and that the limit is indeed "f")

-Deleted Account- <steele>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by wingo (Posted a comment)
  • -unavailable- added by steele (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 15 Nov 2010 10:41:12 PM UTCwingoStatusNone=>Fixed
      Open/ClosedOpen=>Closed

    Back to the top


    Powered by Savane 3.1-cleanup1