October 27, 2003

forth love if honk then

While I ought to detail, in detail, why I don't really hate Unicode, just some of the uses people make of it... instead I've been hacking at the forth implementation in Parrot.

Still integer-only, and it has a single mixed stack (so when ints and strings are put in they'll all coexist on the stack), but Parrot Forth now has working if/then, begin/again, and begin/until control structures. Oh, and when you compile words you really compile words--it generates bytecode on the fly for compiled words.

Woo! (and, I might add, Hoo!)

Now to go wedge in an interface to Parrot's calling conventions so we can write ncurses_life.forth to go with ncurses_life.imc. That's probably the sign of some Apocalypse or other though not, alas, a Perl 6 apocalypse. (When I add in the object extensions to Forth, then expect something big)

Posted by Dan at October 27, 2003 01:58 PM | TrackBack (0)
Comments

I'm sure you've seen this before, but as you have mentioned Forth and Life in conjunction, I have to respond in kind with this: http://www.albany.net/~hello/life.htm

Posted by: Gnomon at October 28, 2003 10:49 AM

interesting forth site gnomon. Wow.. there are actually people who know forth outside of my dungeoun.. I mean company. :)

IF FALSE ELSE TRUE THEN = !
OK. that was stupid. hehe.

Posted by: Ian at October 5, 2004 07:51 PM

We did, alas, break the forth a bit shifting over to CPS. Worked OK in the basic setup, but when we tried to make the words normal parrot subroutines... bang. Unfortunate side effect of continuations. :(

Not too big a deal, since you wouldn't want to do things that way in general anyway, at least if you were looking for speed, but...

Posted by: Dan at October 5, 2004 08:49 PM