lua-users home
lua-l archive

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


> To Roberto and Luiz: it would be great (for us embedded users) to  
> someday have stdio (and strcoll) fully decoupled from Lua sources, e.g.  
> by using macros in luaconf.h for all the relevant functions, or by  
> adding a stdio_funcs.c file.
> At least for baselib and auxlib (see above), so we wouldn't have to  
> re-patch at every new release.

Can't you use the relevant functions as macros? I guess some of these
changes can be done through luaconf.h, with code like this:

  #if defined(LUA_LIB)
  #define fputs(s,f)	myownfputs(s,f)
  #define fopen(f,o)	luaL_error(L, "file operations not available")
  ...
  #endif

-- Roberto