Liste des Groupes | Revenir à cl forth |
Ruvim <ruvim.pinka@gmail.com> writes:Yes, and I wonder why introducing new words like `<:` and `;>` is better than putting the smarts into `:` and `;`.On 2025-07-02 15:37, albert@spenarnc.xs4all.nl wrote:Or something. Anyway, [ and ] are used for a variety of purposes andOr it has not even know it, if [ is smart enough to compile a jump to>
after ].
This can be tricky because the following should work:
>
create foo [ 123 , ] [ 456 ,
>
: bar [ ' foo compile, 123 lit, ] ;
trying to smarten them seems fraught with pitfalls. If one really
wants to have
: foo ... [ : bar ... ; ] ... ;
work, it may be better to put the smarts into : and ;. E.g., on a
system with sections, they could switch to another section and back.
The benefit of defining a normal colon definition inside another colonAs I can see, the idea is that the name of a nested definition has the limited scope — the same as a local variable, and it is not visible outside of the containing definition.
definition eludes me, however. Maybe mutual recursion, but the need
is rare and deferred words handle that well.
Les messages affichés proviennent d'usenet.