Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: bit shifts

From: hallvard:ystad:helpinhand at: 20-Sep-2001 19:12

Gregg Irwin skrev (Thursday 20.09.2001, kl. 18.23):
>I forgot to ask, can you give me an example or two of how it fails?
Sure. I'm posting it to the list, since the results are odd. And maybe someone feels like trying to reproduce this on some other platforms than mine? Here we go (from my windows2000):
>> print to-integer debase/base "F2" 16
>> print to-integer debase/base "10" 2
0 On my SuSE linux 7.1, I got this:
>> print debase/base "10101010" 2
** Script Error: Not enough memory ** Where: halt-view ** Near: print debase/base "10101010" 2
>> print debase/base "10101" 2
(Not enough memory? 256M RAM?) And then this:
>> print to-integer debase/base "F2" 16
Segmentation fault allvardo:/rebol # The rebol console vanishes, but the process is still running: allvardo:/rebol # ps aux | grep rebol root 24283 0.0 0.3 3040 820 pts/1 S 19:03 0:00 ./rebol Your bin-str-val function: bin-str-val: func [s[string!]] [to-integer debase/base s 2] sometimes crashes on my windows machine. The whole rebol console disappears. I haven't been able to reproduce this on my linux. There you go. Hope this helps someone in some way. ~H