lua-users home
lua-l archive

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


On Fri, Oct 7, 2011 at 1:05 PM, Patrick Rapin <toupie300@gmail.com> wrote:
> I have two questions to ask to the entire community. Because for me,
> there is a mystery.
>
>  - Do you run Lua scripts from within a C or C++ application ?

Yes.

>  - If yes, what API are you using for it?

Lua's, with a small lib of utility functions (a couple dozen small
functions, which do things your lib doesn't, like setup weak tables to
map C pointers back to userdata objects).

> The standard Lua API is powerful and complete, but not really handy.

Your C++ code doesn't look any easier to use than Lua's to me.

Everything that can be done with Lua's C API exists because there is
occaison when it is useful. For your API to be simpler, it would need
to narrow the API, and thus be less generally useful.

Also, it's C++. If you work in C++, it might appear that the whole
world uses C++. Me, I can't recall the last time I saw any C++ code on
Linux, other than KDE/Qt (which I don't hack).

Cheers,
Sam