Re: bug in bit32?
[email protected] (Albert van der Horst)
| Newsgroups | gmane.comp.lang.forth.colorforth |
|---|---|
| Message-ID | <[email protected]> |
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. [email protected] http://home.hccnet.nl/a.w.m.van.der.horst