Hi Phillip,
All of the things you mentioned and then some. Lately, L has been my goto lang for things I used to do in perl (yeah perl is faster at text processing but L is fast enough for the stuff I do).
I’ve also learned to use all the cpus, if you look at http://mcvoy.com/lm/L/photos.l search for parallel and go until you find the procedure thumbs(). Read that while loop and you’ll see a template for processing each file in parallel using all the cpus. I use that all over the place, L has a handy little function cpus() that (on linux at least) returns the number of cpus.
What you are doing, prototyping in tcl and migrating to L, yeah, I’ve done that (though less and less because I much prefer L, duh), mostly I’ll get frustrated at some main proc we have that doesn’t have getopt processing I like so I’ll rewrite that in L.
It certainly was designed so you can mix and match. Damon or Rob would have to way in but I believe it is like so:
L array is a Tcl list, L hash is a Tcl dict, L structs are a Tcl list as well. So it would be awkward for stuff like structs but you could pass them back and forth to Tcl just fine. L follows Tcl pass by “value” except it is pass by reference but copy on write, the L references are just Tcl’s upvars (though FAIR WARNING: if you pass a struct field {so a list element} by reference we do this horrible gross, but handy thing, where we put the element in a local var, pass a reference to that, and when you come back from the function it assigns the list element the value of the local var. It’s disgusting but it gives you the appearance of pass by reference on struct fields which is not a thing in Tcl).
The other fair warning is that L is based on some old interm 8.5 Tcl, we haven’t merged it forward and we haven’t fixed the Tcl tests that we broke (we use PCRE instead of whatever RE engine that Tcl uses, maybe Henry Spencers?). I can’t remember why but merging forward is a pain in the ass and it’s unlikely we’ll do it unless the user base grows and someone really wants it. Oh, and we completely broke Tcl’s threading model (that I don’t understand) which made the Tcl core team not have any interest in taking our changes back. Their loss?
I completely get the idea of using L so you can push Tcl code through C/C# people, one of our guys hates L because it’s Larry’s pet language and he didn’t see it going anywhere, but there was a commit flying past and it looked so much like C he pointed out a bug in the code without knowing it was L
Using L with Tk drives Damon nuts, he’s never liked it, we’ve never figured out a way to do it in a pleasant way. That said, it doesn’t bother me, I use it with Tk.
Debug? printf. Rob can maybe weigh in here, there are some tracing features in there that he did. Profile? I just don’t.
Editor: vim
Html - so there is some support for doing stuff with html that Damon did but I’ve never used it. I believe it’s like PHP. Damon?
Anyhoo, glad you are using it, I love L, I wish there was a C dialect that was L compat at least for the none gui stuff. I like C, I can’t stand C++ or Rust or whatever, I’m happy with C’s syntax, I just wish there was a C that picked up stuff like Tcl’s ref counting so I don’t have to do memory management, hashes as a type, all the RE stuff in expressions (and switch statements! It’s about time, right?). Rob loves it too and he’s the guy that did the compiler so it’s not dieing anytime soon, we use it all the time.
–lm