Bounty program for improvements to Tcl and certain Tcl packages
github.com
github.com
Just hire a programmer to do the work and pay them in accord with a contract.
The bounties are not large enough to pay someone to solve them. The ones that are fairly low value are likely to get picked off rapidly by the existing community by just focusing their attention slightly differently. The high value ones are in the class where you'd need a team of expert programmers to take them on, and would expect to be supporting them for an extended period of time; that can burn through $100k in pretty short order. (Yes, I'm working on that particular bounty, but I was doing so before the bounty was announced. I know how exactly difficult it is.)
IOW, these are all rewards for success, not pay for doing.
Tcl was one the the popular scripting languages when Flightaware started using it.
But remember that Lua was specifically designed for embedded scripting and has minimal footprint. A javascript engine is a huge beast in comparison.
> In the fall of 1987, while on sabbatical at DEC's Western Research Laboratory, I got the idea of building an embeddable command language. The idea was to spend extra effort to create a good interpreted language, and furthermore to build it as a library package that could be reused in many different applications.
If you pay yourself $50 an hour, fixing all those two things will be well more than 20 hours. It's not that much money.
Lua seems pretty good. So ... many ... languages...
I'll venture a guess that if any other tool could do the job better, they would use it.
- shell-like command syntax a bit friendlier for interactive use (the default lack of brackets alone goes a long way!)
- straightforward, easy-to-read internal code (Lua's code is fine but a bit inscrutable - this is obviously subjective but I know I'm not the only one to feel this way)
- GC by reference counting (more predictable object destruction)
- very straightforward extension API
You may disagree that they are excellent reasons, but I claim they at least reach the level of "reasonable" ;)
Tcl did solve the problem of handling double-precision floating point number precision loss well. A numerical analyst fixed the code so that the automatic conversion generates the shortest string representation that will reparse to the same bit representation. It also avoids quite a few bugs in the C library in the process (on the grounds that different platforms have different bugs to each other).
The obvious thing to do is just turn an object into a parseable string. So if you have a Texture object, which is a struct Texture at address 0x12345678, you might let this become a string, "(Texture * )0x12345678" (or similar). And then if you're expecting a Texture object you can check for not just a TclObj struct of the appropriate type, but also a string of the right format. I'm sure I found this unworkable, though, my recollection being that Tcl would call the free callback on the original object after turning it into a string, and so you'd quite possibly end up with a string representation of a dead object... but now that I say that out loud, it sounds super insane.
So maybe I'm recalling rightly. And then Tcl is still insane, and I stand by everything I said. It happens.
Or maybe I'm wrong... and that's good! Because I otherwise really did prefer it to Lua. I know exactly why Lua's C API is the way it is, but that doesn't make it any less horrid. And Tcl's shell-style syntax is way better for interactive use.
Still, we don't recommend tying objects with important lifetimes to values; Tcl really assumes that it can clone and release them as it sees fit (and effectively that it can interconvert through the serialization without problems). It's a pretty different design decision to what most programming languages go with, and has a lot of consequences, some really good and some quite irksome at times.
There's quite a few extension packages that do the sort of thing you're talking about without trouble. In particular, the packages for handling talking to DOM trees, DCOM interfaces, and JVMs all take this approach without becoming disaster zones. Another approach is to put the magical value in a variable and refer to that variable by name (which is a bit more easily done when it is an array element). I'm sure something could be worked out.