Re: Constant array
- From: Elizabeth D Rather <erather@xxxxxxxxx>
- Date: Mon, 26 Jan 2009 11:51:01 -1000
Alex McDonald wrote:
On Jan 26, 8:24 pm, Elizabeth D Rather <erat...@xxxxxxxxx> wrote:....Alex McDonald wrote:On Jan 26, 5:01 pm, Bernd Paysan <bernd.pay...@xxxxxx> wrote:
You're actually recommending that if a FORGET is removing severalA lot of things in Forth *can* be inspected. You can write a FORGET that isBut at the point where FORGET is executed you can't inspect something
extensible (by just providing a hook into FORGET), and you can inspect
quite a lot of things when you use FORGET. E.g. if you fear that a deferred
word is corrupted by FORGET, you hook an extension into your FORGET that
looks for all deferred words, and checks if the words linked there are
inside the range of forgotten words - if so, "fix" them (at least to
something that crashes reliable with a meaningful error message). Note that
ANS Forth might lack the tools for inspecting itself, but usually Forth
systems have such tools.
of which you now have no knowledge.
hundred words from the dictionary that all DEFERs and other vectors be
matched against the xt's of all the words to be discarded? And somehow
you'll know what to reset them to if necessary? Not too likely!
No; are you responding to the right message? I'm suggesting we FORGET
FORGET.
Right, I was responding to the paragraph beginning "A lot of things in Forth *can* be inspected."
The problem is that there's a lot of history involved: not only what
definitions were added to the dictionary since a word was defined, but
DEFERs and other vectors, interrupt vectors, addresses stored here and
there, changes to memory allocations in various memory spaces, etc.
It's preposterous (wildly bulky & inefficient) to record all this state
information with every single definition, which is what what would be
required to make plain old FORGET workable in a modern Forth. It is
really simple, however, to have MARKER record whatever state information
needs to be remembered, so that it can be restored easily.
Agreed. I can't see a disgreement between your position and mine. To
the extent that my Forth has the equivalent of;
: forget ( -<name>- )
true abort" FORGET no longer works. Use MARKER or ANEW" ;
immediate
Yes, we agree. It appears that it's folks with nostalgia for 80's Forths who are clinging to FORGET. I see no technical need to preserve it.
Cheers,
Elizabeth
--
==================================================
Elizabeth D. Rather (US & Canada) 800-55-FORTH
FORTH Inc. +1 310.999.6784
5959 West Century Blvd. Suite 700
Los Angeles, CA 90045
http://www.forth.com
"Forth-based products and Services for real-time
applications since 1973."
==================================================
.
- References:
- Constant array
- From: rickman
- Re: Constant array
- From: Alex McDonald
- Re: Constant array
- From: Ed
- Re: Constant array
- From: Elizabeth D Rather
- Re: Constant array
- From: Ed
- Re: Constant array
- From: Stephen Pelc
- Re: Constant array
- From: Ed
- Re: Constant array
- From: Andrew Haley
- Re: Constant array
- From: Ed
- Re: Constant array
- From: Andrew Haley
- Re: Constant array
- From: Ed
- Re: Constant array
- From: Andrew Haley
- Re: Constant array
- From: Bernd Paysan
- Re: Constant array
- From: Alex McDonald
- Re: Constant array
- From: Elizabeth D Rather
- Re: Constant array
- From: Alex McDonald
- Constant array
- Prev by Date: Re: cross.fs from within gforth (how too?)
- Next by Date: Re: Constant array
- Previous by thread: Re: Constant array
- Next by thread: Re: Constant array
- Index(es):
Relevant Pages
|
Loading