GARTHWILSON wrote:
>BODY doesn't make any changes to the word. All it does is return the PFA, given the CFA. It's only information about the word.
I didn't mean to indicate that
>BODY by itself could cause any damage.
Fig Forth, and the Forth I am using is based on Fig Forth but with the 79 Standard, returns the PFA when [b[-FIND[/b] is used.
>BODY, then is not needed. But, I changed
-FIND to return the CFA instead. And I changed the PFA in
INTERPRET to point to a null word, so it doesn't do anything. But I may revive it if there turns out to be a better way. Which now means I might need
>BODY, but I need to understand under what conditions
>BODY is used, or only should be use, and what it was meant to reference.
I was looking at
DOER/MAKE and some examples which means it can make a word do different things. My first thought was that if I mistyped a word after
MAKE, and it happened to be a word that contained a word primitive, then there would be machine language code starting where the PFA is. In this case
MAKE wouldn't be doing anything other than causing a fantastic crash down the road.
Therefore I am trying to understand the reference that
>BODY is trying to make. Also the fact that some of my words don't even contain a PFA, has confused me quite a bit. Then, having a word that references the PFA of another word, then becomes too much to bear, especially when some words may not contain a PFA or the PFA is Machine Language code instead of an indirect thread address.
I still am not sure I understand the context in which
>BODY is being used. Is
>BODY taking the place of
PFA in newer standards?