3 ms·
> Most modern FORTH don't have SMUDGE any more, which has been replaced by HIDE and REVEAL. I think, the modern Forths (i.e. since 1994 ANS Forth standard) nee
by dvdkhlng 7y ago
> Most modern FORTH don't have SMUDGE any more, which has been replaced by HIDE and REVEAL.
I think, the modern Forths (i.e. since 1994 ANS Forth standard) need neither HIDE nor REVEAL as these are made superflous by RECURSE.
Other edge cases could be handled using a mechanism like DEFER [1] (which can be implemented in terms of ANS Standard words).
Just looking through the manual, even the modern Gforth has something like RECURSIVE [2] which is just a differently named implementation of REVEAL.
[1] http://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Deferred-Words.html http://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Defe...
https://forth-standard.org/standard/core/RECURSE https://forth-standard.org/standard/core/RECURSE
[2] http://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Calls-and-returns.html#Calls-and-returns http://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Call...
- DonHopkins 7y agoOne thing I love about SMUDGE is that SMUDGING again undoes the effect. If only that worked for my glasses. DEFER is great! But the word that resolves it should have been named REFED.