"WITH-SPY kernel extension"

with_spy EXTENSIONS
* SPY-EXIT ( -- )

will unnest the current colon-word so it will actually
return the word calling it. This can be found in the
middle of a colon-sequence between : and ;

EXTENSIONS with_spy ordinary primitive

* SPY: ( name -- )

create a header for a nesting word and go to compiling
mode then. This word is usually ended with ; but
the execution of the resulting colon-word can also
return with EXIT
this is the spy-version SPY_ON

EXTENSIONS with_spy defining primitive

* ;SPY ( -- )

compiles ((;)) which does EXIT the current
colon-definition. It does then end compile-mode
and returns to execute-mode. See : and :NONAME

EXTENSIONS with_spy compiling primitive

* SPY_ON ( -- )

change the runtime-code of (NEST)
to call a special word that prints info
to the screen whenever a colon word is
entered. It will print the name and
the current stack, and results in a kind
of execution trace over SPY' :-colon nested
words.

EXTENSIONS with_spy ordinary primitive

* SPY_OFF ( -- )

disable SPY_ON nest-trace.

EXTENSIONS with_spy ordinary primitive

SPY-ENTER

[] no special info, see general notes

EXTENSIONS with_spy loader code P4_DVaL

SPY-LEAVE

[] no special info, see general notes

EXTENSIONS with_spy loader code P4_DVaL

SPY'
* : ( 'name' -- )

create a header for a nesting word and go to compiling
mode then. This word is usually ended with ; but
the execution of the resulting colon-word can also
return with EXIT

SPY' with_spy forthword synonym

* ; ( -- )

compiles ((;)) which does EXIT the current
colon-definition. It does then end compile-mode
and returns to execute-mode. See : and :NONAME

SPY' with_spy immediate synonym

* EXIT ( -- )

will unnest the current colon-word so it will actually
return the word calling it. This can be found in the
middle of a colon-sequence between : and ;

SPY' with_spy immediate synonym