home .. forth .. colorforth mail list archive ..

Re: [colorforth] bug in bit32?


On Sat, May 07, 2005 at 12:33:01PM -0400, Mark Slicker wrote:
<SNIP>
>
> This is not entirely correct, remember that bit32 shifts EAX for each
> iteration, and bit16 shifts just AX. This is where I argue that bit32 has
> a bug, since the carry should be tested on the shift of AX.
>
> I don't know if it helps but I've coded bit16 in colorForth:
>
> : bit16 w drop *byte 15 2*s 16 for 2* -if p! then 2 +i next ;

I reread your original post and at last I understand it.
(Somehow I imagined the shifting going to the right.)

Groetjes Albert

--
Albert van der Horst,Oranjestr 8,3511 RA UTRECHT,THE NETHERLANDS
Economic growth -- like all pyramid schemes -- ultimately falters.
albert@xxxxxxxxxxxxxxxxxx http://home.hccnet.nl/a.w.m.van.der.horst

---------------------------------------------------------------------
To unsubscribe, e-mail: colorforth-unsubscribe@xxxxxxxxxxxxxxxxxx
For additional commands, e-mail: colorforth-help@xxxxxxxxxxxxxxxxxx
Main web page - http://www.colorforth.com