Hello,

Some time ago I posted something about a Lua->Parrot compiler I was planning to write 
as a project for my bachelor's in computer science. (about 4/5 weeks ago I think)
Just to let you know where the project stands (in case you're interested), here's a 
short overview:

The lexer (made with Flex) is ready, maybe some adjustments here and there, but that's 
quite isolated, so that won't give any trouble in the rest of the project.
The parser (made with Bison) is ready, didn't do full testing yet, because I don't 
know the source language that well yet, but I have a good reference, the official Lua 
interpreter. 
The parser also builds an abstract syntax tree. The code for that is generated by 
TreeCC, a really cool tool for managing tree nodes and their operations. I'll probably 
have to do some rearranging with the tree nodes, but at least it's working.
The next phase I'll be working on, is semantic checking. I'll have to do a lot of 
reading on that, as I am no experienced compiler writer (this is my first real 
project) (nor have I experience in programming in a GNU environment)

As Lua is a typeless language, variables can take values of any type. This has to be 
checked during runtime, obviously. My guess is that variables should be implemented on 
parrot as PMC's. I have tried to read as much as possible on PMC's, but it's still a 
bit unclear. What I have understood is that PMC's are like C unions, but all fields 
are accessible (or something like that).
Are there any good tutorials on PMC's somewhere? I looked in the mailing lists, but I 
couldn't find much there.

(For people who are interested in this project, have a look at: 
http://members.home.nl/joeijoei/parrot
On that site, I'm keeping a record of what I have already done, and what I'm planning 
to do (don't expect too much of it, though).)

Well, just wanted to let you know I'm still there working on this project :-)

Regards,
Klaas-Jan

Reply via email to