4 ms·
Exactly. Tcl competes with Lua, not Python or Ruby. And Tcl and Lua both have their respective advantages and disadvantages. - Lua has better support for handl
by rbehrends 9y ago
Exactly. Tcl competes with Lua, not Python or Ruby. And Tcl and Lua both have their respective advantages and disadvantages.
- Lua has better support for handling non-trivial data structures, but Tcl interop is a lot less cumbersome, as the host language only needs to know how to pass strings back and forth, basically.
- Tcl is more suitable for writing DSLs due to its homoiconicity, but Lua's more conventional syntax is more suitable for traditional programming.
- Tcl's command-oriented syntax makes it fairly easy to write an expressive shell-like interface for your application (debugging, state inspection, expert interface).
I'll note that via JimTcl [1], Tcl also has an additional niche for bootstrapping software as a much saner replacement for /bin/sh programming, such as in autosetup [2].
[1] http://jim.tcl.tk/index.html/doc/www/www/index.html http://jim.tcl.tk/index.html/doc/www/www/index.html
[2] https://msteveb.github.io/autosetup/ https://msteveb.github.io/autosetup/