Re: bin2c.lua
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: bin2c.lua
- From: Duck <duck@...>
- Date: 2007年9月26日 08:22:05 +1000 (EST)
Try Hisham's luatoc at http://www.inf.puc-rio.br/~hisham/ .
Thank you, this absolutely looks promising.
It does...interesting reading. One non-trivial problem I can see, however,
is that the converted code doesn't (yet) support tail calls. The TAILCALL
opcode is "downgraded" and rendered using a CALL.
If you have any constructs which rely on tail calls, such as state
machines, then you are in some sort of trouble.
There are libraries for implementing proper tail calls in C, of course.
For example:
www.complang.tuwien.ac.at/schani/diplarb.ps
So it should be "easy enough" to implement TAILCALL if you need to :-)