7 ms·
I regard lua as essentially trivial to embed and to use to script a host application. The ease of hooking to/from the host application written in C is very stra
by kwdc 6y ago
I regard lua as essentially trivial to embed and to use to script a host application. The ease of hooking to/from the host application written in C is very straightforward and painless. Its possible to have lua call C which calls lua which could call C. That reentrancy is underrated but so very useful.
The simple design also means you can have multiple independent lua interpreters with no overlap. Isolation is quite achieveable with no real effort. Just create a new lua state.
Contrast this with python. Ouch. But python also supports embedding and can import C functions etc. Quite a bit more effort though. Multiple interpreters isn’t so nice. Not when you've experienced lua's ease of embedding. The GIL isn’t great either but not a big deal if everything about a script is in a single thread.