Pretty much everything that Alex McDonald says is wrong!
On Monday, July 15, 2019 at 3:47:45 AM UTC-7, Alex McDonald wrote:
> Hugh's disambugifiers (and here I guess what his IF looks like)
>
> : IF state @ 0= if
> ." warning IF is undefined in interpretation state"
> else postpone if then ; immediate
>
> illustrate the problem. This would fail to run the above, because (like
> many state-smart words) they conflate run time and text interpretation
> time. They're two different things.
Alex McDonald is lying. This is my disambiguifier:
---------------------------------------------------------------------
: if
state @ 0= if
cr ." WARNING: *** no interpretation semantics for: IF ***" cr
then
postpone if ;
immediate
---------------------------------------------------------------------
I have seen this happen many times previously.
An ANS-Forth cult member will post non-working code,
and claim that it is my code --- a typical troll attack.
> On Hugh's meta-compilation point and your counter point, I'm surprised
> that you would claim it's not possible to write an meta-compiler without
> a POSTPONE that works inside [ ] (much like Hugh's claim that you can't
> do it without a vectored LITERAL), but that it's OK because it's "not
> essential". Systems like mine and Win32Forth are testament to the
> capability of ANS Forths and their authors to write meta-compilers
> without POSTPONEs that work as you describe.
Forth is not really Forth without literal numbers,
so supporting literal numbers in a cross-compiler is "essential."
It is possible to work around Elizabeth Rather's incompetence
by doing this: : xxx ... [ 12345 ] literal ... ;
instead of: : xxx ... 12345 ... ;
Bizarre work-arounds such as this aren't a
"testament to the capability of ANS-Forths and their authors."
Alex McDonald is just brown-nosing Elizabeth Rather.
This is crap code --- typical for ANS-Forth.
This is the same crap code that Forth-83 required.
Note that Charles Moore left Forth Inc. in 1982, so Forth-83
is the fault of Elizabeth Rather, as was ANS-Forth in 1994.
Here is more bullshit from Alex McDonald:
On Monday, July 15, 2019 at 9:34:00 AM UTC-7, Alex McDonald wrote:
> On 15-Jul-19 16:05, Ruvim wrote:
> > On 2019-07-15 16:18, Alex McDonald wrote:
> >> On 15-Jul-19 13:17, Ruvim wrote:
>
> >>> You claim that the interpretation semantics for FOOBAR is
> >>> STATE-depended. But how to prove it? By definition, the
> >>> interpretation semantics of FOOBAR is a behavior that occurs when
> >>> FOOBAR name is encountered by the text interpreter *in interpretation
> >>> state*.
> >>
> >> And its XT is EXECUTEd.
> >
> > Actually, the Standard does not specify what XT is EXECUTed in this
> > situation. Formally it may be another associated XT (that cannot be
> > obtained by Tick).
>
> What? When the text interpreter looks up <name> by using (classically)
> FIND and gets back an XT to execute, it must be the same XT from tick; '
> <name> execute is the equivalent of the interpretation semantics *by
> definition*.
The ANS-Forth documentation for FIND (6.1.1550) says:
"For a given string, the values returned by FIND while compiling
may differ from those returned while not compiling."
Tick executes at compile-time, so it is only guaranteed to provide
the same xt as FIND provides if FIND executes at compile-time
(interpretive mode) which is the interpretation semantics
("semantics" is Elizabeth Rather's goofy term for action or behavior).
If FIND is executed at run-time, it might return a different xt.
Alex McDonald way lying when he said that FIND and tick "must"
provide the same xt.
In my experience, this weird nonsense only happens when FIND is
used on the 50 some words in ANS-Forth (such as IF etc.) that say:
"Interpretation semantics for this word are undefined."
This isn't guaranteed by the ANS-Forth document, as this weird
nonsense may theoretically happen for any word.
Assuming that this weird nonsense only happens for these problematic
words, my disambiguifiers fix the broken behavior of FIND on them.
My disambiguifiers make all of these words immediate, and allow FIND
to find them and to provide only one xt for each of them.
According to the ANS-Forth section 4.1.2 "Ambiguous Conditions"),
one particularly disturbing ambiguous condition is:
"attempting to obtain the execution token,
(e.g., with 6.1.0070 ', 6.1.1550 FIND, etc.)
of a definition with undefined interpretation semantics"
Effectively FIND and tick etc. can't be used to obtain an xt of
words such as IF etc.. My disambiguifiers fix this bug in ANS-Forth
so FIND does work on IF etc. and it works in a consistent manner.
On Tuesday, July 16, 2019 at 5:31:16 AM UTC-7, Alex McDonald wrote:
> This
>
> : FOO POSTPONE POSTPONE ;
> : PPP4 123 ;
> : PPP5 [ FOO PPP4 ] ;
>
> does *not* execute POSTPONE in interpret mode. There is no text
> interpretation of POSTPONE beyond line 1 in the definition of FOO, and
> hence no meaningful STATE for anything in or around the compiled
> POSTPONE to inspect, since we no longer text interpret POSTPONE. FOO
> executes the *compilation semantics* of POSTPONE.
>
> This is what POSTPONE does when compiled by the text interpreter (when
> STATE was -1);
>
> Compilation: Skip leading space delimiters. Parse name delimited by a
> space. Find name. Append the /compilation semantics/ of name to the
> current definition.
>
> So we append the /compilation semantics/ of POSTPONE to FOO. When FOO is
> executed, it does the /compilation semantics/ shown above for POSTPONE.
> Nowhere does it say in those semantics "Inspect the execution state, and
> abort if interpreting (STATE is 0)".
>
> The problem is state-smartness. I suspect your POSTPONE inspects STATE,
> in which case
>
> : POSTPONE POSTPONE POSTPONE ; IMMEDIATE
>
> will fix this specific problem.
LOL Getting rid of the warning message (or abort with error message)
doesn't actually fix the problem.
This reminds me of one time when I was quite young and working as a
dishwasher. We ran out of dish-washing soap! Ruh-roh!
My solution was to tape a wet paper-towel over the warning bell so
I wouldn't have to listen to that annoying beeping all day long.
Alex McDonald is a total bullshitter! He says:
On Tuesday, July 16, 2019 at 5:31:16 AM UTC-7, Alex McDonald wrote:
> This
>
> : FOO POSTPONE POSTPONE ;
> : PPP4 123 ;
> : PPP5 [ FOO PPP4 ] ;
>
> does *not* execute POSTPONE in interpret mode.
When does the POSTPONE of PPP4 happen?
It happens inside of [ ... ] brackets which is interpret mode!
Alex McDonald says:
> The problem is state-smartness. I suspect your POSTPONE inspects STATE,
> in which case
>
> : POSTPONE POSTPONE POSTPONE ; IMMEDIATE
>
> will fix this specific problem.
This is essentially a disambiguifier without a warning. I have:
------------------------------------------------------------------------
: postpone
state @ 0= if
cr ." WARNING: *** no interpretation semantics for: POSTPONE ***" cr
then
postpone postpone ;
immediate
------------------------------------------------------------------------
So, lets see what happens when the disambiguifier is used:
------------------------------------------------------------------------
: FOO POSTPONE POSTPONE ; ok
: PPP4 123 ; ok
: PPP5 [ FOO PPP4 ] ;
WARNING: *** no interpretation semantics for: POSTPONE ***
ok
------------------------------------------------------------------------
This warning occurs because the POSTPONE of PPP4 is happening
inside of the [ ... ] brackets which is interpret mode. Duh!
Notice that Alex McDonald the mystic has written FOO as:
FOO POSTPONE POSTPONE ;
and he has written POSTPONE as:
: POSTPONE POSTPONE POSTPONE ; IMMEDIATE
Notice the similarity? These are the same thing!
POSTPONE is immediate and FOO is not, but FOO is being run
inside of [ ... ] brackets so it executes at compile-time
just like an immediate word inside of a colon word.
Alex McDonald the mystic believes that piling these
definitions on top of each other magically causes POSTPONE
to not execute in interpret mode.
This is like saying: "Its turtles all the way down!"
This isn't true though. POSTPONE ends up executing in interpret mode
no matter how many levels are piled on top of each other.
Similarly, the bottom turtle doesn't have anything to stand on...
In summary --- essentially nothing that Alex McDonald says
about ANS-Forth is true. He is an idiot or a liar, or both.
I think that Anton Ertl and Alex McDonald are doing a lot of
hand-waving for the purpose of confusing everybody.
The purpose of this obfuscation is that Anton Ertl wants to
use compiling words such as POSTPONE IF ELSE THEN etc.
inside of [ ... ] brackets (which makes sense), but he also
wants to claim that this is ANS-Forth (he is lying about this).
All of this pseudo-intellectual blather may very well confuse
Forthers with less than a year of experience in Forth.
They will decide that Anton Ertl and Alex McDonald are big
Forth experts and that the whole question is above their
training level, so they will just believe the big experts.
They won't realize that Anton Ertl and Alex McDonald are liars.
I've got about 1/4 century of experience with Forth though,
so the liars aren't going to fool me quite so easily!