Re: ‘?dup’ and ‘drop’

Jason Kemp <[email protected]> Fri, 17 Oct 2008 17:55:09 +0100
Newsgroups gmane.comp.lang.forth.colorforth
Message-ID <[email protected]>
Sorry: ignore that one.  Kristopher Johnson had asked it before and got 
an answer. http://www.strangegizmo.com/forth/ColorForth/msg00193.html

I've just spent quite a while trying to work it out but should have 
looked at the archive first.

Jason Kemp said the following on 17/10/2008 17:42:
> Hi,
>
> I understand that ?dup only compiles a dup if the previous instruction 
> was not a drop.  If it was a drop then the drop is removed and no dup 
> is compiled either.  Karig, http://www.karig.net/os/cf/c.htm#cdrop 
> explains this.
>
> But how can it be assumed that the TOS (that was to have been dropped) 
> and NOS are identical so that we don't need a drop followed by a dup?
>
> Thanks,
> Jason
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
> Main web page - http://www.colorforth.com
>
>
>