How do you deal with registering templated classes in JUCE, i found no way to use templates in Lua or making them accesible, i had to register a class with a specific template (i used float types for Rectangle though int should be there too, there is a lot more like that).
I know no other way, unfortunately...
Do you have some way to debug a code like that, get a stack trace or set breakpoints within your project ?
Not exactly the simplest, but not really that hard either: pretty much like you would when debugging a library, except you have to load the lua executable and your lua script as a loader. For instance, I start gdb like this:
gdb -ex "set breakpoint pending on" -ex "break luaopen_luce" -ex run --args lua my_script.lua
luaopen_luce being the entry point for the library/module here.
For long debug sessions, I'd use CodeLite, but any good IDE would do, of course.
To debug a lua script alone or a callback, I'd use ZeroBrane Studio, which has a really good integrated lua debugger.