[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: CSV File parsing
- From: "Richard Simes" <ricardo.nz@...>
- Date: Fri, 21 Jul 2006 00:03:27 +1200
Ask for more details if you need.
--lhf
Alas, I do need. Haven't done a lot of C programming and and haven't got my head around the lua C api yet...
So I'm probably barking up completely the wrong tree.
From what I gather,
static const char *getF (lua_State *L, void *ud, size_t *size)
is where the lua function dofile(fname) reads the data from the file.
and this appears to be passed as a reader to lua_load.
so to make a function available to lua that loads the translated csv file, would i need to copy the code of dofile and replace getF with my function that does the translation?
I'll give this a shot (unless someone points out that I'm completely mistaken) and report on my success.
Thanks for your help.
Richard