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

 
 

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

Submitter:  -Deleted Account- <steele>
Submitted:  Tue 28 Sep 2010 01:34:48 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

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

Fixed in 1.9 git,. Thanks for the report!

Andy Wingo <wingo>
Group 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 Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

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

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2010-11-15 wingo StatusNone Fixed
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-caa5.
    Corresponding source code