3 ms·
Where Tcl is nice is embedding the Tcl interpreter in a C main program. Lua also does this well. This is the oft-overlooked embedding case which can be diffic
by rwmj 6y ago
Where Tcl is nice is embedding the Tcl interpreter in a C main program. Lua also does this well.
This is the oft-overlooked embedding case which can be difficult in other languages (compared to the normal case where you start out in language X and need to call into a C function to do something low level). For example in Python the embedding case is tricky and lightly documented, and with only a semi-stable API which has changed under us a few times.
In nbdkit we do a lot of language embedding (https://github.com/libguestfs/nbdkit/tree/master/plugins https://github.com/libguestfs/nbdkit/tree/master/plugins) including Tcl, Lua, Python and many others.