home .. forth .. colorforth mail list archive ..

RE: [colorforth] New Linux 4word


On Thu, 7 Apr 2005, [iso-8859-1] Frédéric DUBOIS wrote:

The primary feature of colorForth source is that it is preparsed, so
that functions of the compiler are handled by the editor. colorForth
source distinguishes not just between interpret and compile, but also
between numbers and text. This is not simply a matter of
character set
ASCII vs. huffman.


I'm aware of that; I was asking Terry what was his intended path to CF.
Your answer suggests that, starting from classic Forth, the upgrade path to
a CF-like system would be:
1. preparsed source
2. Tokenized source
3. Huffman encoding
Is it right? Or would you advise just to all this in one pass?


A Forth historian like Jeff Fox could better answer this or Chuck Moore who actually took the path from classic to colorForth. On the Aha page[1], Jeff mentions Chuck's addition of Huffman coding in 2000. In the Fireside Chat 1999[2], Chuck talks about pre-parsed words with 16 spaces (4 bits) and 5 bit characters. Designing a Forth today, you can take advantage of previous experiments, even using colorForth as jumping off point for a new design.

Another Forth I have seen (herkforth), takes the colorForth
concept a step further and builds the dictionary at edit time. The text of
a
word is not stored in source, instead and index is stored which
corresponds with a dictionary entry. A dictionary entry holds, among other
things, the
text of the word.


Hmmmm... Aha technology?


It would seem herkforth is directly influenced from Aha in this way. It is hard to say the extent of the similarites as Aha has not been fully elaborated. Herkforth source resembles colorForth in its 16-bit "source tokens", with 4 bits of 16 designating the color of the token. herkforth does not apear to do any compilation at edit time like Aha, that would be a main difference. Herkforth apears to differ from most Forths in that all names are globally unique. In my experience the prefixed names that occur in herkforth source interferes with readability. If you take the dictionary metaphor at face value, then each word should allow multiple definitions as this occurs in natural language dictionaries.

Mark

[1] http://www.ultratechnology.com/aha.htm
[2] http://www.ultratechnology.com/fsc99.htm
---------------------------------------------------------------------
To unsubscribe, e-mail: colorforth-unsubscribe@xxxxxxxxxxxxxxxxxx
For additional commands, e-mail: colorforth-help@xxxxxxxxxxxxxxxxxx
Main web page - http://www.colorforth.com