Sujet : Re: History of CREATE...DOES> ?
De : dxforth (at) *nospam* gmail.com (dxf)
Groupes : comp.lang.forthDate : 02. Aug 2024, 05:18:20
Autres entêtes
Organisation : Ausics - https://newsgroups.ausics.net
Message-ID : <66ac5e0a$1@news.ausics.net>
References : 1 2 3 4 5
User-Agent : Mozilla Thunderbird
On 1/08/2024 11:48 pm, Anton Ertl wrote:
dxf <dxforth@gmail.com> writes:
On 26/07/2024 5:13 pm, Anton Ertl wrote:
...
But CREATE...DOES> also made it into Forth-79, so it must have been
more widespread by then.
>
Not necessarily. What systems had 'multiple WHILE' before ANS introduced
it?
cmForth
<https://raw.githubusercontent.com/ForthHub/cmFORTH/combined/cmforth.fth>:
: WHILE ( a - a a) \ IF SWAP ;
: REPEAT ( a a) \ AGAIN \ THEN ;
where "\" is [COMPILE]. AFAIK the SWAP in the WHILE was relatively
late and while the SWAP was still in REPEAT, you had to implement
multiple-exit BEGIN loops differently, but up until fig-Forth (where
"compiler security" was a headline feature) such things were certainly
possible. It's interesting that "compiler security" discouraged such
usage, which made it easier to specify in Forth-94 that the CS-SwAP
happens in WHILE, not in REPEAT (because there was little existing
practice for such things at the time).
Brodie mentions it in 'Thinking FORTH' (1984) but without details or
endorsement by a Standard who would risk it?
Apparently not that many, or they had switched to the newer WHILE
already, otherwise standardizing it in Forth-94 would not have flown.
It's often been left to Standards to bring in new developments. It
helped when the one introducing it was Forth Inc and it happened to
be well designed and tested. There are also examples where the TC
botched it - things invented on the fly. To this day nobody knows
how PRECISION applies to F. Long story short F. prints differently
from one implementation to the next thanks to the unintelligible spec.