History of Tcl
tcl.tk
tcl.tk
http://antirez.com/articoli/tclmisunderstood.html
TCL is a fun language, which seemed to get orphaned ahead of it's time. Like FORTH a lot of the joy of using TCL comes from updating the language itself, rewriting how it works. The downside of that is that you're never sure what is "real" TCL, and what is your in-house addon.
Still TCL is a fun language to implement, and I guess a lot of people have implemented both FORTH and TCL, in addition to the more typical LISP systems.
https://sourceforge.net/projects/naviserver/files/naviserver...
Latest release is last month
<INPUT name="edit1" size="50">
<SCRIPT type="text/tcl">
proc edit1_changed {} {
if {[edit value] == abc} {
button1 enable 1
} else {
button1 enable 0
}
}
edit1 onChange edit1_changed
</SCRIPT>
I did some Tcl and that went fine, but I never did enough to really have an informed opinion. I know some people really hate it though.It also has examples in VBScript and (of course) JavaScript. The W3C people did try to spec things beyond "just JS", but it was not to be.
As someone in the opposite direction, having done lots of Tcl, I love it. It is one of my favorite languages to use. I use it for simple little things on a regular basis.
Though it’s still amazingly backward compatible…
The elegant simplicity of non standard tech is there precisely because those are non standard tech tools.
Here’s a book about it:
https://www.amazon.com/Official-Netscape-Server-Side-Javascr...
I googled a bit and found:
https://en.m.wikipedia.org/wiki/Vignette_Corporation
Ex-CEO (later chairman) became a millionaire. Excerpt from above page:
[ In June 1998, Garber hired Greg Peters to succeed him as CEO, and Garber became chairman of the board.[12]
In July 1998, the company launched StoryServer 4, which featured strong support of XML technology.
By December 1998, the company raised an additional $27.5 million in venture capital.[4]
The number of the company's customers rose from 130 in 1998[5] to 700 in 2000.[3]
On February 19, 1999, during the dot-com bubble, the company became a public company via an initial public offering. On the first day of trading, the stock price rose 152%, from $19 to $47.[13]
On February 22, 1999, the company release Vignette Syndication Server.
After the IPO, in 1999, Garber, worth $200 million at the age of 33, sold most of his stock and left the company.[14] ]
I wrote a little silver for wordle in Tcl, but that’s a funny statement because it was mostly using ripgrep calling /usr/share/dict/words but I think that’s part of it charm, it get out of the way and let use you whatever tools and integrates them beautifully!
The lawsuit against BSD and prohibition of the Lion's commentary book, came shortly after US goverment allowed AT&T to profit from UNIX.
Had UNIX been commercial from its early days, at the same price as comparable OSes of its time, most likely UNIX and C would never have taken over the server room and kernel systems programming.
30+ years later Tcl/Tk is still in active use. In space industry (maybe more on the old side of the old/new space dichotomy) it is used everyday to command and control satellites (both simulators and flatsats on ground and actual satellites in space).
Source: https://www.sqlite.org/tclsqlite.html https://wiki.tcl-lang.org/page/D.+Richard+Hipp
It seems to be working out okay, though!
Is this on the level of R/tidyverse/ggplot?
Each individual script is typically very ad-hoc, to address a specific shortcoming in a tool, or to get a particular mix-and-match of tools from various vendors integrated into a design pipeline.
That being said, it is an ancient and venerable tradition, dating back to the creation of tcl itself, and as long as we're making chip from Silicon it will be the duct tape holding it all together.
The two dominate EDA companies are Cadence and Synopsys. All of the digital design tools for synthesis, place and route, and static timing analysis use the Tcl language as the built in scripting language. These tools have literally thousands of built in commands.
You can look up some of the tools like Cadence Innovus that I use every day. A single license has a list price of over $1 million. We get big discounts because we have about 800 licenses.
https://www.cadence.com/en_US/home/tools/digital-design-and-... Then you write more Tcl code to script things within the tool. A standard thing is building a power grid. You need to write a for loop to build a metal 1 stripe every 5 microns. That's done in Tcl.
You have a list of clocks you need to define with names and frequencies. Use a Tcl array and a for loop.
Our CAD flow is literally tens of thousands of lines of Tcl code to take Verilog and go through all the steps until we get a GDS file with mask data to manufacture.
There are so many TLA (Three Letter Acronyms) that are the same across industries with completely different meanings. I was on the ECE subreddit which is for Electrical and Computer Engineering. Someone posted a rant about how annoying these children were, how the pay was bad, and the parents were awful. There were some funny comments about how some engineers acted like children and others about the new grads. Finally someone pointed out that ECE was also Early Childhood Education and pointed them to a different subreddit.
Sadly there is no end in sight because all of the proprietary tools use it and you can't really do anything about that.
They did add a bytecode runner in one version of TCL and I experimented with making a new language that would compile to TCL bytecode, but unfortunately one of our tools (PowerArtist I think) still bundled TCL from 2005 or so and didn't support it.
I also experimented with a WASM to TCL transpiler, and got it to work a little, but the WASM spec is actually quite big and the TCL code you get out is huge so I don't think that is the right way really.
The only good thing about TCL is that it's value based, not reference based. Value based languages are much more intuitive and easy to reason about, but unfortunately most languages are reference based.
a = [1, 2]
b = a
a[0] = 3
print(b[0])
In JavaScript, Java, C#, Dart, Python, etc. it will print 3 because a and b are references to values.In C++, Rust and TCL, (and maybe Go? I don't remember) it will print 1 because a and b are values.
In value based languages you need explicit syntax to make references and dereference.
In reference-based languages you need explicit syntax to copy values. Often this is omitted entirely which is quite annoying. Until very recently the standard solution to copy a variable was to serialise it to JSON and back again!!
Also worth noting that for immutable values (i.e. all values in Haskell, strings in JavaScript, etc.) there's no observable difference between the two.
F5 BigIP load balancers has hooks in Tcl that control the balancing and can rewrite requests.
So there are niches for Tcl still. Nice language.
It was Rails before DHH ever came up with the idea, but on a tiny startup in Lisbon that the world never cared about.
Handling automatic generation of database bindings based on parsing SQL92 DDL generated from modeling tools, running across all major UNIX and Windows NT/2000, across DB2, Oracle, Informix, Sybase SQL Server, MS SQL Server, and even Access, just because we could.
While it was a great experience, having to constantly rewrite Tcl code into C for performance reasons, is why afterwards I never used a language for production deployment that didn't had a JIT or AOT toolchain on their reference implementation.
To this day I don't bother with Python and Ruby for anything beyond UNIX scripting.
The founders of that startup also shared the same point of view, building OutSystems on top of .NET, based on our ups and downs delivering that Tcl based application server into several kinds of production workloads.
I forget about those days until something like this comes up.
Vignette added unnecessary complexity.
I haven't coded TCL in something like 20 years; at the time Unicode support in TCL was non-existent; a quick review of modern TCL forums looks like UTF-8 support is not wart-free, and UTF-16 support is not on the table.
I used TCL on top of AOLServer, and at its best, it really did give that "you have superpowers" feeling Lisp can give an engineer. I bet it would make a very comfortable environment for experimenting. So much of modern LLM experimentation could be seen as creating DSLs for different tasks: TCL excels at this.
This is configurable, though -- I recall it was a preprocessor define in the C code, and you can change it to 32 bits per character, making it UTF-32. Of course, this won't help a Tcl script run somewhere else, but it means you _can_ build a Tcl interpreter that transparently works with "all unicode", at the cost of doubling memory consumption for every string.
All this is concerning the internal string format, not what it accepts as input/output.