NEW ARTICLE
Explore vocabularies. It's a very powerful tool, but quite confusing for >anyone new to FORTH programming. >https://esp32.arduino-forth.com/article/elements_vocabularies
It is not a synonym of VOCABULARY. It pushes the wordlist, not[..]
replaces it. I consider that an anachronistic feature handed down
from the first implementations where there were two wordlists.
In ciforth all denotation words ( $ % # " ' 0-9 ) are real words 1]
and sit comfortably in a namespace called ONLY. Surprisingly
ONLY behaves conform ISO.
Then
PRIMES: PRIME? \ FORTH
But the „traditional” VOCABULARY word is nicer and better.
We've got no namespaces in Forth, since the prefixes a
namespace usually adds aren't in use in Forth.
On Friday, May 26, 2023 at 12:49:10 PM UTC+2, none albert wrote:
[..]
It is not a synonym of VOCABULARY. It pushes the wordlist, not[..]
replaces it. I consider that an anachronistic feature handed down
from the first implementations where there were two wordlists.
In ciforth all denotation words ( $ % # " ' 0-9 ) are real words 1]
and sit comfortably in a namespace called ONLY. Surprisingly
ONLY behaves conform ISO.
Then
PRIMES: PRIME? \ FORTH
Is this only for a single word, or should one pop back after PRIME?
I remember one or two occasions where I want the same word for
functions in different libraries/word-lists that both have to be present.
-marcelGroetjes Albert
But the „traditional” VOCABULARY word is nicer and better.Don't fool yourself. Wordlists are the Forth equivalent of namespaces.
We've got no namespaces in Forth, since the prefixes a
namespace usually adds aren't in use in Forth.
But the „traditional” VOCABULARY word is nicer and better.Don't fool yourself. Wordlists are the Forth equivalent of namespaces.
We've got no namespaces in Forth, since the prefixes a
namespace usually adds aren't in use in Forth.
„Wordlists”, „namespaces”… it's better to stick with the traditional VOCABULARY
in Forth. Which, besides, stresses it's not exactly the same as namespace.
VOCABULARY is not in the standard because it is one of those archaic remnants.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 300 |
Nodes: | 16 (2 / 14) |
Uptime: | 40:24:03 |
Calls: | 6,708 |
Calls today: | 1 |
Files: | 12,243 |
Messages: | 5,353,721 |