Legacy Words (v4)

[ RfDs/CfVs | Other proposals ]

Poll Standings

See below for voting instructions.

Systems

[ ] I agree with the proposed alteration to the document text.
Gerry Jackson
Hans Bezemer
Bernd Paysan
Marcel Hendrix
[ ] I do not agree with the proposed alteration to the document text.
Leon Wagner

Informal Results

Problem

Section 1.4.2 "Obsolescent features" declared seven words as obsolescent and warned "they may be withdrawn from future revisions of the Standard". It is now 15 years since that warning was issued, it is time to remove these words from the document.

In order to do this a number of alterations to the main document are required.

Proposal

  1. Replace the first three paragraphs of section 1.4.2 "Obsolescent features", listing the obsolescent words:
    This Standard adopts certain words and practices that cause some previously used words and practices to become obsolescent. Although retained here because of their widespread use, their use in new implementations or new programs is discouraged, because they may be withdrawn from future revisions of the Standard.

    This Standard designates the following words as obsolescent:

    6.2.0060 #TIB 15.6.2.1580FORGET 6.2.2240 SPAN
    6.2.0970 CONVERT 6.2.2040 QUERY 6.2.2290 TIB
    6.2.1390 EXPECT

    with:
    This Standard adopts certain words and practices that cause some previously used words and practices to become obsolescent. Their use in new implementations or new programs is discouraged, as they may be withdrawn from future revisions of the Standard.

    This Standard designates no words as obsolescent.

  2. Remove reference to EXPECT and CONVERT from the Documentation requirements:
    4.1.1 Implementation-defined options:
    character editing of ACCEPT and EXPECT;
    display after input terminates in ACCEPT and EXPECT;
    4.1.2 Ambiguous conditions
    producing a result out of range, e.g., multiplication (using *) results in a value too big to be represented by a single-cell integer (*, */, */MOD, >NUMBER, FM/MOD, SM/REM, UM/MOD, CONVERT, M*/);
    4.2.1 Environmental dependencies
    depending on the presence or absence of non-graphic characters in a received string (ACCEPT, EXPECT);
  3. CORE EXT Wordset
    6.1.2216 SOURCE
    Remove ", declaring TIB and #TIB obsolescent" from the end of the first paragraph, and the following text from the rationale:
    SOURCE in this form exists in F83, polyFORTH, LMI's Forths and others. In conventional systems it is equivalent to the phrase
    BLK @ IF BLK @ BLOCK 1024 ELSE TIB #TIB @ THEN
    6.1.2450 WORD
    Remove the sentence "A space, not included in the length, follows the string" from the second paragraph and the note in the definition.

    Remove the second paragraph from the rationale:

    As a concession to the obsolesecent word CONVERT, Forth94 required an implementation to put a space after the string placed by WORD. This standard neither requires nor prohibits such a space.
    6.2.0060 #TIB
    Remove the definition and rationale.
    6.2.0695 ACCEPT
    Remove reference to EXPECT from the first paragraph, and the following paragraphs from the rationale:
    ACCEPT and EXPECT perform similar functions. ACCEPT is recommended for new programs, and future use of EXPECT is discouraged.

    As in previous standards, EXPECT returns the input string immediately after the requested number of characters are entered, as well as when a line terminator is received. The "automatic termination after specified count of characters have been entered" behavior is widely considered undesirable because the user "loses control" of the input editing process at a potentially unknown time (the user does not necessarily know how many characters were requested from EXPECT). Thus EXPECT and SPAN have been made obsolescent and exist in the Standard only as a concession to existing implementations. If EXPECT exists in a Standard System it must have the "automatic termination" behavior.

    ACCEPT does not have the "automatic termination" behavior of EXPECT. However, because external system hardware and software may perform the ACCEPT function, when a line terminator is received the action of the cursor, and therefore the display, is implementation-defined. It is recommended that the cursor remain immediately following the entered text after a line terminator is received.

    6.2.0970 CONVERT
    Remove the definition and rationale.
    6.2.1390 EXPECT
    Remove the definition and rationale.
    6.2.2040 QUERY
    Remove the definition and rationale.
    6.2.2125 REFILL
    Remove the reference to QUERY in the rationale leaving:
    REFILL is designed to behave reasonably for all possible input sources. If the input source is coming from the user REFILL could still return a false value if, for instance, a communication channel closes so that the system knows that no more input will be available.
    6.2.2240 SPAN
    Remove the definition, there is no rationale.
    6.2.2290 TIB
    Remove the definition and rationale.
  4. TOOLS EXT Wordset
    15.6.2.1580 FORGET
    Remove the following note from the end of the third paragraph:
    Note: This word is obsolescent and is included as a concession to existing implementations.
    A.15.6.2.1580 FORGET
    Replace the existing rationale:
    Typical use:
    ... FORGET name ...
    FORGET assumes that all the information needed to restore the dictionary to its previous state is inferable somehow from the forgotten word. While this may be true in simple linear dictionary models, it is difficult to implement in other Forth systems; e.g., those with multiple address spaces. For example, if Forth is embedded in ROM, how does FORGET know how much RAM to recover when an array is forgotten? A general and preferred solution is provided by MARKER.
    with the text:
    Typical use:
    ... FORGET name ...
    FORGET tries to infer information about the previous dictionary state from the forgotten word, which is not always possible. In consequence, FORGET is guaranteed to restore the state of name space, but not necessarily the state of dictionary.

    For example,

    ALIGN HERE 100 CELLS ALLOT CONSTANT mybuffer
    FORGET mybuffer
          
    in this case the 100 reserved cells are a part of the buffer, but FORGET can not infer this. A solution to the restoration of the dictionary state is provided by MARKER.

    Nevertheless, FORGET is a useful tool for interactive sessions, because it does not require creation of a marker in advance. An example session may look like following:

    : foo ... foo ... ( buggy redefinition) ;
    \ finding out the bug
    FORGET foo
    : foo ... foo ... ( bug fixed) ;
    \ checking that it works
    \ copying the definition of foo into a file
          
    It should be noted that such sessions are practical only in environments that support input history (often persistent) and copy/paste to/from the console.
  5. Remove the reference to #TIB and TIB from the first sentence of the "Data space" rationale (A.3.3.3).
  6. Remove the reference to CONVERT in the rationale for the Core extension words (A.6.2):
    Words that are being deprecated in favour of new words introduced to solve specific problems (e.g., CONVERT).
  7. Add the following to Annex D:

    D.7 ANS Forth '94

    D.7.1 Removed Definitions

    This standard removes six words that were marked 'obsolescent' in the ANS Forth '94 document. These are:
    6.2.0060 #TIB 6.2.1390 EXPECT 6.2.2240 SPAN
    6.2.0970 CONVERT 6.2.2040 QUERY 6.2.2290 TIB
    Reuse of these names is strongly discouraged.

Remarks

Annex D needs work to bring it up to date, let along explain the difference between Forth200x and ANS Forth '94. This should be the topic of another RfD. The text given in point 9 is intended as a place holder until annex D is discussed in full.

The new rationale for FORGET is taken from Michael Gassanenko's "un-obsolete FORGET".

Change History

2010-09-01 v4 (PJK)
Removed FORGET from the list of obsolete words, reinstating it as a TOOL EXT word, with Gassanenko's rationale.
2010-08-31 v3 (PJK)
Removed FORGET from the list of words removed, leaving it marked as obsolete
2009-09-09 v2 (PJK)
Removed legacy word set in favour of section D.7
1998-11-30 v1 (LZ)
Original text by Len Zettel

Credits

Peter Knaggs <pjk@bcs.org.uk>
Engineering, Mathematics and Physical Sciences,
University of Exeter, Exeter, Devon EX4 7QF, England
web: www.rigwit.co.uk

Voting Instructions

Fill out the ballot below and email it <vote@forth200x.org>. Your vote will be published (including your name (without email address) and/or the name of your system) here. You can vote (or change your vote) at any time, and the results will be published here.

Ballot

Please mark the statements that are correct for you (e.g., by putting an ":x" between the brackets).
[ ] I agree with the proposed alteration to the document text.
[ ] I do not agree with the proposed alteration to the document text.
If you feel that the text does not cover all the aspects you would expect, then please make an informal comment. These will be reported in addition to the formal votes. Note that the best time to voice such issues is the RfD stage. Alternatively, you could propose a counter RfD.