You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bertram Felgenhauer has written one for strings that should translate well for decimal conversion.
byteArrayToBigNat# should let you write something absurdly fast for hexadecimal and (if you think it's worth the trouble) octal. Count the digits to determine how many bytes you need, round up to the nearest multiple of the word size, allocate a MutableByteArray#, fill it up with words (I think) smallest first, unsafe freeze it, and then convert for free. Special case numbers that fit in one word.
The text was updated successfully, but these errors were encountered:
Bertram Felgenhauer has written one for strings that should translate well for decimal conversion.
byteArrayToBigNat#
should let you write something absurdly fast for hexadecimal and (if you think it's worth the trouble) octal. Count the digits to determine how many bytes you need, round up to the nearest multiple of the word size, allocate aMutableByteArray#
, fill it up with words (I think) smallest first, unsafe freeze it, and then convert for free. Special case numbers that fit in one word.The text was updated successfully, but these errors were encountered: