Implementing DOES> in Forth, the entire reason I started this mess

78 todsacerdoti 8 6/10/2025, 1:36:39 AM boston.conman.org ↗

Comments (8)

5- · 9m ago
i've never looked closely at any of this, and it's been a long time since i looked at all.

reading colorforth code and especially commentary (https://github.com/Howerd/colorForth) it seemed that it refines the concept of staging into colours (does> might correspond to cyan?).

hopefully someone more knowledgeable will chime in here!

jackdoe · 1h ago
Amazing article!

I hate DOES> I was implementing it well after 1am last night and I hate it, I have this feeling as something gets harder to implement it means its not right, but I know DOES> is right, so its me, I just couldn't implement it well. It was super frustrating. But now I feel better :)

I am new to Forth but it feels like `create does>` has to be replaced with some new construct, I just want word code to operate on its data, but I need to gain more experience to find out, for now `create does>` will do.

rickcarlino · 4h ago
Similar (but NOT identical) concept in RetroForth I really enjoyed learning about years ago: https://rickcarlino.com/2021/til-how-retroforth-implements-d...

It’s nice to see Forth internal deep dives hitting the front page, great article.

mikewarot · 1h ago
Long, long ago I wrote a Forth for OS/2 in assembler (mostly out of spite, because I was told you couldn't write OS/2 programs in assembler, you had to use C++)

I still don't know what DOES> really does... ;-)

pyinstallwoes · 2h ago
Okay, so what's the significance of it and what's the boon?

Surprised so little public forth's implement it.

anthk · 6m ago
Even EForth under Sublex/Muxleq implements it.
sph · 1h ago
All the most common Forth I know implement CREATE DOES>

What’s funny, is that I used to know how it works, now any time I come across these kind of articles I get more and more confused and further away from understanding. It’s like reading those convoluted explanations of what a monad is.

spc476 · 1h ago
It only briefly goes into what it does, this article goes into how it's done for a particular implementation.