Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #14452

Re: Quotations revisited

Newsgroups comp.lang.forth
From Albert van der Horst <albert@spenarnc.xs4all.nl>
Subject Re: Quotations revisited
Date 2012-07-27 12:58 +0000
Message-ID <m7tldg.knt@spenarnc.xs4all.nl> (permalink)
Organization Dutch Forth Workshop
References <50031807.129829772@192.168.0.50> <58811288968435@frunobulax.edu> <P7qdnXtZvtOlwZ7NnZ2dnUVZ_rqdnZ2d@supernews.com> <1058f010-386d-4b6b-b3b9-77607c3d23e4@a16g2000vby.googlegroups.com>

Show all headers | View raw


In article <1058f010-386d-4b6b-b3b9-77607c3d23e4@a16g2000vby.googlegroups.com>,
Mark Wills  <markrobertwills@yahoo.co.uk> wrote:
>On Jul 16, 1:11=A0am, "Elizabeth D. Rather" <erat...@forth.com> wrote:
>> On 7/15/12 11:54 AM, Marcel Hendrix wrote:
>> ...
>>
>> > Maybe we first need a convincing example of the usefulness of
>> > quotations and closures -- (*) would certainly be useful, but
>> > the cost seems to be a little excessive?
>>
>> Um, yeah. Aside from looking obscure & clever and satisfying the "[x]
>> can do it, why not Forth?" test, what on earth does this buy you?
>>
>> Cheers,
>> Elizabeth
>>
>> --
>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
>=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
>=3D
>> Elizabeth D. Rather =A0 (US & Canada) =A0 800-55-FORTH
>> FORTH Inc. =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 +1 310.999.678=
>4
>> 5959 West Century Blvd. Suite 700
>> Los Angeles, CA 90045http://www.forth.com
>>
>> "Forth-based products and Services for real-time
>> applications since 1973."
>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
>=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
>=3D
>
>Indeed.
>
>A while back, for my own Forth system, I was looking at a more
>intelligent dictionary structure that would allow something like this:
>
>: WORD_A
>  ... ... ...
>  ... ... ...
>  : WORD_B
>    ... ... ...
>    ... ... ...
>  ;
>;
>
>So, WORD_B can see WORD_A (and everything above it) but WORD_A can't
>see WORD_B or its children.

I'd say that you plan to use WORD_B somewhere in WORD_A
or it wouldn't have much use.
Furthermore I think you forget the most important one:
the environment can see WORD_A but not WORD_B.

>
>Never got the chance to follow up on it. I think it's neat. Though I'm
>sure it's not new.

There is an implementation technique I thought off.
Add a levels-down counter to a header, that is normally 0,
but upped by one by each nesting.
Now if you look into the dictionary you ignore words above a certain
level. This starts  with the current level L and is MIN -ed with all
the words you encounter. Soon the level is back at 0.

If you want to be clever, you probably can jump over spades of
nested words. In debugging you can still find everything.
This probably should replace a wordlist mechanism or things
get complicated.

Groetjes Albert

--
-- 
Albert van der Horst, UTRECHT,THE NETHERLANDS
Economic growth -- being exponential -- ultimately falters.
albert@spe&ar&c.xs4all.nl &=n http://home.hccnet.nl/a.w.m.van.der.horst

Back to comp.lang.forth | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Quotations revisited mhx@iae.nl (Marcel Hendrix) - 2012-07-14 15:55 +0200
  Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-15 19:26 +0000
    Re: Quotations revisited Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-15 23:53 +0200
    Re: Quotations revisited mhx@iae.nl (Marcel Hendrix) - 2012-07-15 23:54 +0200
      Re: Quotations revisited Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-16 00:48 +0200
        Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-22 15:01 +0000
          Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-23 16:49 +0000
            Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-23 21:39 +0000
              Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-25 13:13 +0000
        Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-22 11:07 -0500
          Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-22 10:21 -0700
            Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-22 12:35 -0500
              Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-22 11:39 -0700
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-22 15:16 -0500
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-22 14:35 -0700
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-23 04:18 -0500
                Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-23 12:58 +0000
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-23 11:55 -0700
                Re: Quotations revisited BruceMcF <agila61@netscape.net> - 2012-07-23 05:45 -0700
            Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-27 12:41 +0000
      Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-15 14:11 -1000
        Re: Quotations revisited "A. K." <akk@nospam.org> - 2012-07-16 07:47 +0200
          Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-16 13:56 +0000
            Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-16 07:20 -1000
              Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-17 13:49 +0000
        Re: Quotations revisited Mark Wills <markrobertwills@yahoo.co.uk> - 2012-07-16 02:32 -0700
          Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-27 12:58 +0000
        Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 04:32 -0500
          Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-16 11:41 +0000
            Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 07:40 -0500
              Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-16 14:05 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 09:20 -0500
                Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-16 15:46 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 11:33 -0500
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-16 15:32 +0000
                Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-16 17:56 +0000
                Re: Quotations revisited Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-16 23:37 +0200
          Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-27 13:05 +0000
            Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-27 08:21 -0500
      Re: Quotations revisited Roelf Toxopeus <rt4all@notthis.hetnet.nl> - 2012-07-16 10:14 +0200
      Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 04:23 -0500
        Re: Quotations revisited m.a.m.hendrix@tue.nl - 2012-07-16 03:39 -0700
          Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 07:09 -0500
            Re: Quotations revisited mhx@iae.nl (Marcel Hendrix) - 2012-07-16 23:47 +0200
              Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-17 04:14 -0500
                Re: Quotations revisited Coos Haak <chforth@hccnet.nl> - 2012-07-17 17:39 +0200
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-17 12:18 -0500
                Re: Quotations revisited mhx@iae.nl (Marcel Hendrix) - 2012-07-17 20:26 +0200
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-19 16:21 +0000
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-19 15:58 -0700
      Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-16 14:05 +0000
    Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-16 12:47 +0000
      Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 08:56 -0500
      Re: Quotations revisited Gerry Jackson <gerry@jackson9000.fsnet.co.uk> - 2012-07-16 15:04 +0100
        Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 09:23 -0500
          Re: Quotations revisited Gerry Jackson <gerry@jackson9000.fsnet.co.uk> - 2012-07-16 17:38 +0100
            Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-16 12:58 -0500
        Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-16 14:56 +0000
      Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-16 22:53 +0000
        Re: Quotations revisited BruceMcF <agila61@netscape.net> - 2012-07-16 19:59 -0700
          Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-16 17:04 -1000
            Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-17 06:51 +0000
              Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-16 21:39 -1000
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-17 07:48 +0000
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-16 22:24 -1000
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-17 10:48 +0000
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-17 08:19 -1000
                Re: Quotations revisited Aleksej Saushev <asau@inbox.ru> - 2012-07-18 01:31 +0400
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-19 16:11 +0000
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-19 12:41 -1000
                Re: Quotations revisited Aleksej Saushev <asau@inbox.ru> - 2012-07-21 01:24 +0400
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-20 16:20 -1000
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-21 03:59 -0700
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-21 21:33 -1000
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-22 01:35 -0700
                Re: Quotations revisited Aleksej Saushev <asau@inbox.ru> - 2012-07-22 21:19 +0400
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-22 08:15 -1000
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-22 11:48 -0700
                Re: Quotations revisited Coos Haak <chforth@hccnet.nl> - 2012-07-22 21:48 +0200
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-22 15:22 -0500
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-22 14:50 -0700
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-22 15:08 -0700
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-22 15:20 -0700
                Re: Quotations revisited Aleksej Saushev <asau@inbox.ru> - 2012-07-23 03:29 +0400
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-22 14:22 -1000
                Re: Quotations revisited Aleksej Saushev <asau@inbox.ru> - 2012-07-23 05:46 +0400
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-22 21:46 -1000
                Re: Quotations revisited Aleksej Saushev <asau@inbox.ru> - 2012-07-25 03:31 +0400
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-23 16:50 +0000
                Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-23 07:57 -1000
                Re: Quotations revisited Aleksej Saushev <asau@inbox.ru> - 2012-07-25 03:38 +0400
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-26 13:01 +0000
                Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-21 12:10 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-21 09:19 -0500
                Re: Quotations revisited Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-21 18:58 +0200
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-22 04:24 -0500
                Re: Quotations revisited Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-22 14:25 +0200
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-22 11:11 -0500
                Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-21 19:29 +0000
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-23 16:31 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-23 12:21 -0500
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-23 17:32 +0000
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-23 11:23 -0700
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-24 03:28 -0500
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-25 13:15 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-25 11:47 -0500
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-26 13:06 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-26 09:50 -0500
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-26 15:11 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-26 11:06 -0500
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-26 16:46 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-27 04:52 -0500
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-26 09:48 -0700
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-27 14:51 +0000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-28 08:29 -0500
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-29 20:55 -0700
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-30 04:40 -0500
                Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-31 23:46 -0700
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-08-01 04:30 -0500
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-23 16:17 +0000
                Re: Quotations revisited "Rod Pemberton" <do_not_have@notemailnot.cmm> - 2012-07-22 18:41 -0400
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-23 16:53 +0000
            Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-17 12:22 +0000
              Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-17 07:30 -0500
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-17 06:34 -0700
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-17 09:04 -0500
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-18 07:07 -0700
                Re: Quotations revisited Coos Haak <chforth@hccnet.nl> - 2012-07-18 17:43 +0200
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-18 09:29 -0700
                Re: Quotations revisited Coos Haak <chforth@hccnet.nl> - 2012-07-18 20:59 +0200
                Re: Quotations revisited Coos Haak <chforth@hccnet.nl> - 2012-07-18 21:14 +0200
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-19 16:05 +0000
                Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-20 14:50 +0000
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-20 15:08 +0000
                Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-21 11:27 +0000
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-23 16:28 +0000
                Re: Quotations revisited Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-23 19:41 +0000
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-18 10:18 -0700
                Re: Quotations revisited anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-19 17:00 +0000
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-19 15:34 -0700
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-19 16:08 -0700
                Re: Quotations revisited Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-17 20:09 +0200
  Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-16 12:01 +0000
    Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-16 10:42 -0700
      Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-16 18:06 +0000
        Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-16 11:08 -1000
          Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-16 21:38 +0000
            Re: Quotations revisited Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-17 00:29 +0200
              Re: Quotations revisited "Elizabeth D. Rather" <erather@forth.com> - 2012-07-16 12:38 -1000
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-17 04:20 -0500
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-17 03:21 -0700
                Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-17 03:14 -0700
                Re: Quotations revisited Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-17 19:58 +0200
                Re: Quotations revisited Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-17 13:05 -0500
  Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-20 11:12 +0000
    Re: Quotations revisited Alex McDonald <blog@rivadpm.com> - 2012-07-20 05:40 -0700
      Re: Quotations revisited stephenXXX@mpeforth.com (Stephen Pelc) - 2012-07-20 15:55 +0000
    Re: Quotations revisited Paul Rubin <no.email@nospam.invalid> - 2012-07-22 20:54 -0700
      Re: Quotations revisited Aleksej Saushev <asau@inbox.ru> - 2012-07-25 03:55 +0400

csiph-web