🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: comp.lang.forth
17 messages
17 total messages Started by dxf Sun, 15 Nov 2026 01:17
[OF] ... worth it?
#223
Author: dxf
Date: Sun, 15 Nov 2026 01:17
44 lines
2183 bytes
Existing:

  1 floats  dup  4 = [if]   38 [ELSE]
            dup  8 = [if]  308 [ELSE]
            dup 10 = [if] 4932 [ELSE]
            drop  1 abort" unknown float size"
  [THEN] [THEN] [THEN]  constant pmax  drop

Using [OF]:

  1 floats  4 [of]   38 [ELSE]
            8 [of]  308 [ELSE]
           10 [of] 4932 [ELSE]
           drop  1 abort" unknown float size"
  [THEN] [THEN] [THEN]  constant pmax

While the latter is cleaner it requires [ELSE] be extended.  Here's the
change using the source given in ANS-Forth A.15.6.2.2533.

: [ELSE]  ( -- )
    1 BEGIN                               \ level
      BEGIN
        BL WORD COUNT  DUP  WHILE         \ level adr len
        2DUP  S" [IF]"  COMPARE 0= >R
        2DUP  S" [OF]"  COMPARE 0= R> OR
        IF                                \ level adr len
          2DROP 1+                        \ level'
        ELSE                              \ level adr len
          2DUP  S" [ELSE]"
          COMPARE 0= IF                   \ level adr len
             2DROP 1- DUP IF 1+ THEN      \ level'
          ELSE                            \ level adr len
            S" [THEN]"  COMPARE 0= IF     \ level
              1-                          \ level'
            THEN
          THEN
        THEN ?DUP 0=  IF EXIT THEN        \ level'
      REPEAT  2DROP                       \ level
    REFILL 0= UNTIL                       \ level
    DROP
;  IMMEDIATE

: [OF]  ( x1 x2 --  | x1 )
    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
Re: [OF] ... worth it?
#242
Author: Hans Bezemer
Date: Fri, 20 Nov 2026 18:00
59 lines
3173 bytes
What about : EQU over = ;

     1 floats  4 EQU [if]   38 [ELSE]
               8 EQU [if]  308 [ELSE]
              10 EQU [if] 4932 [ELSE]
               drop  1 abort" unknown float size"
     [THEN] [THEN] [THEN]  constant pmax  drop

It's nearly as clean as "Using [OF]".. ;-)

Hans Bezemer


On 15-11-2026 02:17, dxf wrote:
> Existing:
> 
>    1 floats  dup  4 = [if]   38 [ELSE]
>              dup  8 = [if]  308 [ELSE]
>              dup 10 = [if] 4932 [ELSE]
>              drop  1 abort" unknown float size"
>    [THEN] [THEN] [THEN]  constant pmax  drop
> 
> Using [OF]:
> 
>    1 floats  4 [of]   38 [ELSE]
>              8 [of]  308 [ELSE]
>             10 [of] 4932 [ELSE]
>             drop  1 abort" unknown float size"
>    [THEN] [THEN] [THEN]  constant pmax
> 
> While the latter is cleaner it requires [ELSE] be extended.  Here's the
> change using the source given in ANS-Forth A.15.6.2.2533.
> 
> : [ELSE]  ( -- )
>      1 BEGIN                               \ level
>        BEGIN
>          BL WORD COUNT  DUP  WHILE         \ level adr len
>          2DUP  S" [IF]"  COMPARE 0= >R
>          2DUP  S" [OF]"  COMPARE 0= R> OR
>          IF                                \ level adr len
>            2DROP 1+                        \ level'
>          ELSE                              \ level adr len
>            2DUP  S" [ELSE]"
>            COMPARE 0= IF                   \ level adr len
>               2DROP 1- DUP IF 1+ THEN      \ level'
>            ELSE                            \ level adr len
>              S" [THEN]"  COMPARE 0= IF     \ level
>                1-                          \ level'
>              THEN
>            THEN
>          THEN ?DUP 0=  IF EXIT THEN        \ level'
>        REPEAT  2DROP                       \ level
>      REFILL 0= UNTIL                       \ level
>      DROP
> ;  IMMEDIATE
> 
> : [OF]  ( x1 x2 --  | x1 )
>      OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
Re: [OF] ... worth it?
#243
Author: dxf
Date: Fri, 20 Nov 2026 23:02
39 lines
2128 bytes
On 21/11/2026 5:00 am, Hans Bezemer wrote:
> What about : EQU over = ;
> 
>     1 floats  4 EQU [if]   38 [ELSE]
>               8 EQU [if]  308 [ELSE]
>              10 EQU [if] 4932 [ELSE]
>               drop  1 abort" unknown float size"
>     [THEN] [THEN] [THEN]  constant pmax  drop
> 
> It's nearly as clean as "Using [OF]".. ;-)
> ...

The DROP has to be handled manually which complicates.  Chances are
folks have used EQU for other things (I have) and perhaps enough reason
to bite the bullet and implement [OF].

I overcame my reluctance to mess with [ELSE] by shifting the tool out
of the kernel and into the user-modifiable TOOLS library.  I was worried
about a potential chicken-egg issue but thankfully it worked out.

FWIW here's my def for [ELSE] which is somewhat shorter (for me) than
the ANS version.  Exploits TRUE = -1.

: [ELSE] ( -- )
  1  begin  token  2dup upper  dup if
    2dup s" [IF]" compare >r  2dup s" [OF]" compare r> and if
      2dup s" [ELSE]" compare if
        s" [THEN]" compare 0=
      else  2drop dup 1 =  then
    else  2drop 1  then  +
  else  2drop refill and  then  ?dup 0= until ; immediate

aka noop [THEN] immediate
: [IF] ( flag -- )  0= if  postpone [ELSE]  then ; immediate
: [OF] ( x1 x2 --  | x1 )
  over =  dup if nip then  postpone [IF] ; immediate

 
Re: [OF] ... worth it?
#244
Author: albert
Date: Sun, 22 Nov 2026 12:22
54 lines
2833 bytes
In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>Existing:
>
>  1 floats  dup  4 = [if]   38 [ELSE]
>            dup  8 = [if]  308 [ELSE]
>            dup 10 = [if] 4932 [ELSE]
>            drop  1 abort" unknown float size"
>  [THEN] [THEN] [THEN]  constant pmax  drop
>
>Using [OF]:
>
>  1 floats  4 [of]   38 [ELSE]
>            8 [of]  308 [ELSE]
>           10 [of] 4932 [ELSE]
>           drop  1 abort" unknown float size"
>  [THEN] [THEN] [THEN]  constant pmax
>
>While the latter is cleaner it requires [ELSE] be extended.  Here's the
>change using the source given in ANS-Forth A.15.6.2.2533.
>
>: [ELSE]  ( -- )
>    1 BEGIN                               \ level
>      BEGIN
>        BL WORD COUNT  DUP  WHILE         \ level adr len
>        2DUP  S" [IF]"  COMPARE 0= >R
>        2DUP  S" [OF]"  COMPARE 0= R> OR
>        IF                                \ level adr len
>          2DROP 1+                        \ level'
>        ELSE                              \ level adr len
>          2DUP  S" [ELSE]"
>          COMPARE 0= IF                   \ level adr len
>             2DROP 1- DUP IF 1+ THEN      \ level'
>          ELSE                            \ level adr len
>            S" [THEN]"  COMPARE 0= IF     \ level
>              1-                          \ level'
>            THEN
>          THEN
>        THEN ?DUP 0=  IF EXIT THEN        \ level'
>      REPEAT  2DROP                       \ level
>    REFILL 0= UNTIL                       \ level
>    DROP
>;  IMMEDIATE
>
>: [OF]  ( x1 x2 --  | x1 )
>    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE

I favour CONDS ... THENS introduced by Anton Ertl.
Perfectly understandable and very flexible.

Groetjes Albert
-- 
The Chinese government is satisfied with its military superiority over USA.
The next 5 year plan has as primary goal to advance life expectancy
over 80 years, like Western Europe.
Re: [OF] ... worth it?
#245
Author: albert
Date: Sun, 22 Nov 2026 12:28
19 lines
1563 bytes
In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>Existing:
>
>  1 floats  dup  4 = [if]   38 [   ELSE]
>  1 floats  dup  4 = [if]   38 [   ELSE]
>            dup  8 = [if]  308 [ELSE]
>            dup 10 = [if] 4932 [ELSE]
>            drop  1 abort" unknown float size"
>  [THEN] [THEN] [THEN]  constant pmax  drop
What is wrong with
1 floats  4 = [IF]   38 [THEN]
1 floats  8 = [IF]   308 [THEN]

If you have a 1 Floats that is 12309 then you have
more problems you can throw a stick at.
-- 
The Chinese government is satisfied with its military superiority over USA.
The next 5 year plan has as primary goal to advance life expectancy
over 80 years, like Western Europe.
Re: [OF] ... worth it?
#246
Author: Anton Ertl
Date: Sun, 22 Nov 2026 15:37
17 lines
1798 bytes
albert@spenarnc.xs4all.nl writes:
>In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>: [OF]  ( x1 x2 --  | x1 )
>>    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
>
>I favour CONDS ... THENS introduced by Anton Ertl.

As already mentioned in 2022, not by me.  And as far as I can see,
CONDS ... THENS are words that compile a control structure, while [OF]
is a word that does text-interpretation time conditional compilation.

- anton
-- 
M. Anton Ertl  http://www.complang.tuwien.ac.at/anton/home.html
comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html
     New standard: https://forth-standard.org/
EuroForth 2026 CFP: http://www.euroforth.org/ef26/cfp.html
Re: [OF] ... worth it?
#247
Author: dxf
Date: Sun, 22 Nov 2026 23:20
22 lines
1608 bytes
On 22/11/2026 11:28 pm, albert@spenarnc.xs4all.nl wrote:
> In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>> Existing:
>>
>>  1 floats  dup  4 = [if]   38 [   ELSE]
>>  1 floats  dup  4 = [if]   38 [   ELSE]
>>            dup  8 = [if]  308 [ELSE]
>>            dup 10 = [if] 4932 [ELSE]
>>            drop  1 abort" unknown float size"
>>  [THEN] [THEN] [THEN]  constant pmax  drop
> What is wrong with
> 1 floats  4 = [IF]   38 [THEN]
> 1 floats  8 = [IF]   308 [THEN]
> 
> If you have a 1 Floats that is 12309 then you have
> more problems you can throw a stick at.

It would be a good solution provided the scenario you identify doesn't
arise.  But now that I've implemented [OF] I'd need a reason to get
rid of it.  At this point, I'm not sure what that might be.  Not being
standard isn't an issue for me.
Re: [OF] ... worth it?
#248
Author: dxf
Date: Mon, 23 Nov 2026 02:28
15 lines
1558 bytes
On 23/11/2026 2:37 am, Anton Ertl wrote:
> albert@spenarnc.xs4all.nl writes:
>> In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>> : [OF]  ( x1 x2 --  | x1 )
>>>    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
>>
>> I favour CONDS ... THENS introduced by Anton Ertl.
> 
> As already mentioned in 2022, not by me.  And as far as I can see,
> CONDS ... THENS are words that compile a control structure, while [OF]
> is a word that does text-interpretation time conditional compilation.

Would an interpretive THENS even be possible?  In the usual implementations
there has to be a [THEN] present for each nest as it serves as a down-count.
Re: [OF] ... worth it?
#249
Author: Anton Ertl
Date: Mon, 23 Nov 2026 07:28
20 lines
1801 bytes
dxf <dxforth@gmail.com> writes:
>Would an interpretive THENS even be possible?

Why not?

>In the usual implementations
>there has to be a [THEN] present for each nest as it serves as a down-count.

And when you see a [THENS], you unnest until you are at a scope
started by [CONDS] (if I understand correctly what CONDS ... THENS
does).

Whether it's worth doing, is another question.

- anton
-- 
M. Anton Ertl  http://www.complang.tuwien.ac.at/anton/home.html
comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html
     New standard: https://forth-standard.org/
EuroForth 2026 CFP: http://www.euroforth.org/ef26/cfp.html
Re: [OF] ... worth it?
#250
Author: albert
Date: Mon, 23 Nov 2026 08:16
35 lines
2216 bytes
In article <6b0378bf$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>On 22/11/2026 11:28 pm, albert@spenarnc.xs4all.nl wrote:
>> In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>> Existing:
>>>
>>>  1 floats  dup  4 = [if]   38 [   ELSE]
>>>  1 floats  dup  4 = [if]   38 [   ELSE]
>>>            dup  8 = [if]  308 [ELSE]
>>>            dup 10 = [if] 4932 [ELSE]
>>>            drop  1 abort" unknown float size"
>>>  [THEN] [THEN] [THEN]  constant pmax  drop
>> What is wrong with
>> 1 floats  4 = [IF]   38 [THEN]
>> 1 floats  8 = [IF]   308 [THEN]
>>
>> If you have a 1 Floats that is 12309 then you have
>> more problems you can throw a stick at.
>
>It would be a good solution provided the scenario you identify doesn't
>arise.  But now that I've implemented [OF] I'd need a reason to get
>rid of it.  At this point, I'm not sure what that might be.  Not being
>standard isn't an issue for me.
>

Being unnecessary is a good reason to get rid of.
For example I think about getting rid of CREATE DOES> (as a syntax)
and incorporate the functionality in class M: M; endclass
This replace the two words CREATE DOES> with class: .
One word less is a good deal.

Groetjes Albert
-- 
The Chinese government is satisfied with its military superiority over USA.
The next 5 year plan has as primary goal to advance life expectancy
over 80 years, like Western Europe.
Re: [OF] ... worth it?
#251
Author: albert
Date: Mon, 23 Nov 2026 08:21
25 lines
1651 bytes
In article <2026Nov22.163719@mips.complang.tuwien.ac.at>,
Anton Ertl <anton@mips.complang.tuwien.ac.at> wrote:
>albert@spenarnc.xs4all.nl writes:
>>In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>>: [OF]  ( x1 x2 --  | x1 )
>>>    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
>>
>>I favour CONDS ... THENS introduced by Anton Ertl.
>
>As already mentioned in 2022, not by me.

You have introduced it to me.

>And as far as I can see,
>CONDS ... THENS are words that compile a control structure, while [OF]
>is a word that does text-interpretation time conditional compilation.

Valid point.

>
>- anton
-- 
The Chinese government is satisfied with its military superiority over USA.
The next 5 year plan has as primary goal to advance life expectancy
over 80 years, like Western Europe.
Re: [OF] ... worth it?
#252
Author: albert
Date: Mon, 23 Nov 2026 08:34
32 lines
2179 bytes
In article <6b03a4bb$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>On 23/11/2026 2:37 am, Anton Ertl wrote:
>> albert@spenarnc.xs4all.nl writes:
>>> In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>>> : [OF]  ( x1 x2 --  | x1 )
>>>>    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
>>>
>>> I favour CONDS ... THENS introduced by Anton Ertl.
>>
>> As already mentioned in 2022, not by me.  And as far as I can see,
>> CONDS ... THENS are words that compile a control structure, while [OF]
>> is a word that does text-interpretation time conditional compilation.
>
>Would an interpretive THENS even be possible?  In the usual implementations
>there has to be a [THEN] present for each nest as it serves as a down-count.
>

Not tested, depends on the implementation.
In my book an interpretative version would be

: [CONDS] ; IMMEDIATE
: [THENS] ; IMMEDIATE

Add one line in SKIPPING :

DUP '[THENS] = IF ( dea) DROP  ( nesting count) DROP 0 THEN

Groetjes Albert
-- 
The Chinese government is satisfied with its military superiority over USA.
The next 5 year plan has as primary goal to advance life expectancy
over 80 years, like Western Europe.
Re: [OF] ... worth it?
#253
Author: Anton Ertl
Date: Mon, 23 Nov 2026 08:42
32 lines
2506 bytes
albert@spenarnc.xs4all.nl writes:
>In article <2026Nov22.163719@mips.complang.tuwien.ac.at>,
>Anton Ertl <anton@mips.complang.tuwien.ac.at> wrote:
>>albert@spenarnc.xs4all.nl writes:
>>>In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>>>: [OF]  ( x1 x2 --  | x1 )
>>>>    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
>>>
>>>I favour CONDS ... THENS introduced by Anton Ertl.
>>
>>As already mentioned in 2022, not by me.
>
>You have introduced it to me.

When and how is that supposed to have happened?

In my postings on c.l.f the first occurence of CONDS is in my posting
from 2022 <2022Jun28.144956@mips.complang.tuwien.ac.at> where I cite
your claim that you have it from me, and I deny it.

My memory says that Gordon Charlton presented some way to finish
several THENs at EuroForth '92 or '94, but when I look at the topics
of his talks, he did not present it there (at least not in the listed
talks, maybe as an impromptu talk), or maybe I am confusing him with
someone else.  The name he used for this word was END (IIRC).

- anton
-- 
M. Anton Ertl  http://www.complang.tuwien.ac.at/anton/home.html
comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html
     New standard: https://forth-standard.org/
EuroForth 2026 CFP: http://www.euroforth.org/ef26/cfp.html
Re: [OF] ... worth it?
#254
Author: marcel hendrix
Date: Mon, 23 Nov 2026 10:47
29 lines
2448 bytes
On 11/23/2026 9:42 AM, Anton Ertl wrote:
> albert@spenarnc.xs4all.nl writes:
>> In article <2026Nov22.163719@mips.complang.tuwien.ac.at>,
>> Anton Ertl <anton@mips.complang.tuwien.ac.at> wrote:
>>> albert@spenarnc.xs4all.nl writes:
>>>> In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>>>> : [OF]  ( x1 x2 --  | x1 )
>>>>>     OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
>>>>
>>>> I favour CONDS ... THENS introduced by Anton Ertl.
>>>
>>> As already mentioned in 2022, not by me.
>>
>> You have introduced it to me.
> 
> When and how is that supposed to have happened?

[..]

> My memory says that Gordon Charlton presented some way to finish
> several THENs at EuroForth '92 or '94, but when I look at the topics
> of his talks, he did not present it there (at least not in the listed
> talks, maybe as an impromptu talk), or maybe I am confusing him with
> someone else.  The name he used for this word was END (IIRC).

It traces back to `Miser's CASE` by dxforth 
:https://dxforth.mirrors.minimaltype.com/miser.html

-marcel
Re: [OF] ... worth it?
#258
Author: dxf
Date: Tue, 24 Nov 2026 08:22
54 lines
2842 bytes
On 23/11/2026 7:42 pm, Anton Ertl wrote:
> albert@spenarnc.xs4all.nl writes:
>> In article <2026Nov22.163719@mips.complang.tuwien.ac.at>,
>> Anton Ertl <anton@mips.complang.tuwien.ac.at> wrote:
>>> albert@spenarnc.xs4all.nl writes:
>>>> In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>>>> : [OF]  ( x1 x2 --  | x1 )
>>>>>    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
>>>>
>>>> I favour CONDS ... THENS introduced by Anton Ertl.
>>>
>>> As already mentioned in 2022, not by me.
>>
>> You have introduced it to me.
> 
> When and how is that supposed to have happened?
> 
> In my postings on c.l.f the first occurence of CONDS is in my posting
> from 2022 <2022Jun28.144956@mips.complang.tuwien.ac.at> where I cite
> your claim that you have it from me, and I deny it.
> 
> My memory says that Gordon Charlton presented some way to finish
> several THENs at EuroForth '92 or '94, but when I look at the topics
> of his talks, he did not present it there (at least not in the listed
> talks, maybe as an impromptu talk), or maybe I am confusing him with
> someone else.  The name he used for this word was END (IIRC).

What may be an early version of THENS appears in a Wil Baden file
'BADENCON.TXT'.  The file I have is date-stamped 1990-01-04.
It defines the following:

  : END     [COMPILE] UNTIL ; IMMEDIATE

  : ENDIF   [COMPILE] THEN ; IMMEDIATE

  : UNLESS  COMPILE 0=  [COMPILE] IF ; IMMEDIATE

  : OF  COMPILE OVER   COMPILE =   [COMPILE] IF   COMPILE DROP ; IMMEDIATE
 
  : THENS ( n) 0 DO (  ) [COMPILE] THEN   LOOP; IMMEDIATE

with the example:

  : CRAPS ( n -- )
    2 OF ." You lose. " ELSE
    3 OF ." You lose. " ELSE
    7 OF ." You win. " ELSE
    11 OF ." You win. " ELSE
    12 OF ." You lose. " ELSE
    ( Otherwise:) . ." is your point. "
    [ 5 ] THENS ;

AFAIR Baden later used COND THENS in the form we now know it.
Re: [OF] ... worth it?
#259
Author: albert
Date: Tue, 24 Nov 2026 16:57
30 lines
2043 bytes
In article <2026Nov23.094237@mips.complang.tuwien.ac.at>,
Anton Ertl <anton@mips.complang.tuwien.ac.at> wrote:
>albert@spenarnc.xs4all.nl writes:
>>In article <2026Nov22.163719@mips.complang.tuwien.ac.at>,
>>Anton Ertl <anton@mips.complang.tuwien.ac.at> wrote:
>>>albert@spenarnc.xs4all.nl writes:
>>>>In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>>>>: [OF]  ( x1 x2 --  | x1 )
>>>>>    OVER =  DUP IF  NIP  THEN  POSTPONE [IF] ;  IMMEDIATE
>>>>
>>>>I favour CONDS ... THENS introduced by Anton Ertl.
>>>
>>>As already mentioned in 2022, not by me.
>>
>>You have introduced it to me.
>
>When and how is that supposed to have happened?

Not something to loose sleep over, I didn't say you invented
it or promoted it. I seem to remember the first time I heard
about it was from you, maybe not.

>
>- anton

Groetjes Albert
-- 
The Chinese government is satisfied with its military superiority over USA.
The next 5 year plan has as primary goal to advance life expectancy
over 80 years, like Western Europe.
Re: [OF] ... worth it?
#260
Author: dxf
Date: Tue, 24 Nov 2026 23:32
34 lines
2274 bytes
On 23/11/2026 7:16 pm, albert@spenarnc.xs4all.nl wrote:
> In article <6b0378bf$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>> On 22/11/2026 11:28 pm, albert@spenarnc.xs4all.nl wrote:
>>> In article <6af9083e$1@news.ausics.net>, dxf  <dxforth@gmail.com> wrote:
>>>> Existing:
>>>>
>>>>  1 floats  dup  4 = [if]   38 [   ELSE]
>>>>  1 floats  dup  4 = [if]   38 [   ELSE]
>>>>            dup  8 = [if]  308 [ELSE]
>>>>            dup 10 = [if] 4932 [ELSE]
>>>>            drop  1 abort" unknown float size"
>>>>  [THEN] [THEN] [THEN]  constant pmax  drop
>>> What is wrong with
>>> 1 floats  4 = [IF]   38 [THEN]
>>> 1 floats  8 = [IF]   308 [THEN]
>>>
>>> If you have a 1 Floats that is 12309 then you have
>>> more problems you can throw a stick at.
>>
>> It would be a good solution provided the scenario you identify doesn't
>> arise.  But now that I've implemented [OF] I'd need a reason to get
>> rid of it.  At this point, I'm not sure what that might be.  Not being
>> standard isn't an issue for me.
>>
> 
> Being unnecessary is a good reason to get rid of.
> For example I think about getting rid of CREATE DOES> (as a syntax)
> and incorporate the functionality in class M: M; endclass
> This replace the two words CREATE DOES> with class: .
> One word less is a good deal.

I think about removing things only to conclude they're necessary.
If you've spent your money well, there's really nothing to cut.
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads