ANNOUNCE: hiccup, a toy tcl impersonator in haskell

A while back I saw a toy tcl interpreter in 550 lines of C called 'picol'. I was looking for a simple language to implement in haskell, so I made my own toy tcl interpreter. It was surprisingly easy to make, thanks to the magic of Haskell and Bytestrings. :) It handles a few things incorrectly, and it is not feature complete, but I thought maybe somebody else might find it interesting. For the record (though it means nothing), my interpreter is about half the size of picol and runs about 30% faster in the few tests I've run, despite having a few more features. (it was certainly less than half the size of picol, but I keep tacking on functions when I get bored). Anyway, you can check it out at: http://code.google.com/p/hiccup/ I plan on making it more complete and faithful to tcl, but I'm branching into a different project for this one. However, any suggestions to make hiccup more efficient, elegant, or correct are certainly appreciated. Cheers, Kyle

consalus:
A while back I saw a toy tcl interpreter in 550 lines of C called 'picol'. I was looking for a simple language to implement in haskell, so I made my own toy tcl interpreter. It was surprisingly easy to make, thanks to the magic of Haskell and Bytestrings. :) It handles a few things incorrectly, and it is not feature complete, but I thought maybe somebody else might find it interesting.
For the record (though it means nothing), my interpreter is about half the size of picol and runs about 30% faster in the few tests I've run, despite having a few more features. (it was certainly less than half the size of picol, but I keep tacking on functions when I get bored).
Anyway, you can check it out at: http://code.google.com/p/hiccup/
I plan on making it more complete and faithful to tcl, but I'm branching into a different project for this one. However, any suggestions to make hiccup more efficient, elegant, or correct are certainly appreciated.
Cheers,
Great work! Would you like to upload it to hackage.haskell.org, so it can be found more easily? -- Don

Hi, some time ago I started a Tcl->C compiler in Haskell. It should compile Tcl code to an Tcl extension. http://wiki.tcl.tk/17385 http://88.198.17.44/~fridolin/tclc/ (darcs) Few tests (e.g. recursive from shootout) are much faster than Tcl (original) interpreter but a lot of tests are slower. This is, because the variable lookup is done with slow Tcl_GetVar2Ex. But at the moment I'm a bit disapointed (about Tcl, not Haskell ;-) and don't work on it anymore... Regards. Christoph Bauer
participants (3)
-
c-bauer-olsbruecken@t-online.de
-
dons@cse.unsw.edu.au
-
Kyle Consalus