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

[colorforth] Question regarding if



On Sat, 13 Jul 2002, I wrote:

> : eq or drop ;

Sorry, this is not equivalent. For purposes of equivalency:

: eq or if dup or drop ; then - -1 ? drop ;

Inefficient, yes. That is why one should think of 'if' as jump to then if
the result was zero. 'less' should be thought of having a result of true
(not zero) if the second item was less than the top. And '-' should be
changed so it effects the flags properly. This will make colorForth
logically consistent.

Mark

------------------------

To Unsubscribe from this list, send mail to Mdaemon@xxxxxxxxxxxxxxxxxx with:
unsubscribe ColorForth
as the first and only line within the message body
Problems   -   List-Admin@xxxxxxxxxxxxxxxxxx
Main ColorForth site   -   http://www.colorforth.com
Wiki page http://kristopherjohnson.net/wiki/ColorForth
ColorForth index http://www.users.qwest.net/~loveall/c4index.htm