lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Thu, Aug 6, 2009 at 21:16, Javier Guerra<javier@guerrag.com> wrote:
> On Wed, Aug 5, 2009 at 10:36 AM, Cosmin
> Apreutesei<cosmin.apreutesei@gmail.com> wrote:
>> Another solution would be to keep the callbacks into FIFO list and
>> have lua pull them from there
>
> that's what i did for my Helper Threads Toolkit
> (http://luaforge.net/projects/helper-threads/).  feel free to use
> whatever code you want from there.

In fact, HTT was the first lib I checked for this. Problem is I want a
pure-lua solution. Reason:

With a few minor mods to alien, I managed to bind the most of a quite
old little API, the kind which wants you to do all alloc &
struct-filling in a mixed alignment/byte-order mode.. you know the
80's kind. Results: no compilation, no makefile, still more readable
and simple code than I would have had in C (even the pointer-offseting
stuff!), no much garbage, less bugs, less time, more fun, merry
popins, london... So obviously I'm impressed by this coding style than
by the traditional C+Lua mix and I wouldn't want to spoil it all now
with this asynchronous business... that's why I'm still looking...
phew, so many words :)