lua-users home
lua-l archive

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

>There are two changes I'd like to see in Lua, both of which would make
>it a little easier to connect C code to Lua.
>I try to be careful in my code to use const char * when I know I'm
>dealing with immutable strings.  Unfortunately, many Lua functions use
>parameter types of char *, even when const char * would be correct, so
>I get a slew of warning messages.  It would be nice if the signatures
>were updated properly.  I believe that *all* strings are immutable in
>Lua, so that all instances of char * could be replaced with const

I agree. I've been bitten by that before.

>The other change I'd like to see is minor: I'd like the C version of
>lua_error to have the same signature as printf.  This should
>relatively easy to implement in ANSI C using <stdarg.h> and vsprintf.

Speaking of errors, I wish there was a seperate error reporting mechanism
and api for parse errors. Requiring the debugger to parse the parse error
makes for a fragile interface.