4 ms·
You may be ready for Forth [1] ;-). Strangely, the Wikipedia article apparently doesn't put forward that Forth allows access both to the parameter and the retur
by astrobe_ 3y ago
You may be ready for Forth [1] ;-). Strangely, the Wikipedia article apparently doesn't put forward that Forth allows access both to the parameter and the return stack, which is a major feature of the model.
[1] https://en.wikipedia.org/wiki/Forth_(programming_language) https://en.wikipedia.org/wiki/Forth_(programming_language)
- mikewarot 3y agoForth has a parameter stack, return stack, vocabulary stack STOIC, a variant of Forth, includes a file stack when loading words
- samatman 3y agoI'm not sure what you're referring to with "vocabulary stack" here, perhaps the dictionary? More of a linked list, really a distinctive data structure of its own.
- astrobe_ 3y agoMaybe OP refers to vocabulary search order manipulation [1]. It's sort of like namespaces, but "stacked". There's also the old MARKER and FORGET pair [2]. The dictionary pointer can also be manipulated in some dialects. That can be used directly as the stack variant of the arena allocator idea. It is particularly useful for text concatenation. [1] https://forth-standard.org/standard/search https://forth-standard.org/standard/search [2] https://forth-standard.org/standard/core/MARKER https://forth-standard.org/standard/core/MARKER
- samatman 3y agoThat does seem like a significant oversight. >r and r>, and cousins, are part of ANSI Forth, and I've never used a Forth which doesn't have them.