3 ms·
Icon is a fantastic programming language. It's... a lot like jq, actually, though both are independently developed, and Stephen Dolan never knew about Icon whe
by cryptonector 5y ago
Icon is a fantastic programming language. It's... a lot like jq, actually, though both are independently developed, and Stephen Dolan never knew about Icon when he wrote jq.
The primary characteristic of both is that they have pervasive backtracking. The primary difference is that jq is built around a concept of immutable, copy-on-write data types. Well, the syntax is also radically different, but that's less interesting to me.
Anyways, I'm very fond of Icon, and I miss writing code in it. It really feels like a language that could have been a much better Python or Perl N. There was an effort to make it so called Unicon, but it never really took off.
- xscott 5y agoThank you for the info on jq. I had seen it before, but I dismissed it as a "grep for JSON" kind of thing, and I don't do a lot of JSON. Hearing it's got more in common with Icon, I'll have to give it another look. Icon was the first language I really got enamored with. I took two classes from Ralph Griswold, and generators, backtracking, and string scanning made for really pretty algorithms. Python has /almost/ caught up to the expressiveness that Icon had in the late 80s / early 90s.
- cryptonector 5y agoGenerators and backtracking are even more pervasive in jq than in Icon because jq evaluates all generators fully, even conditional expressions. You have to use the first() -or related- functions to limit evaluation of generators. Whereas in Icon conditionals are always limited to the first value, and you have to use the `every` keyword to evaluate generators fully. To me, Icon and jq are kindred spirits, even though they have nothing in common in terms of lineage.
- AlexeyBrin 5y agoUnicon seems pretty alive to me and it works on Linux and Windows http://www.unicon.org/ http://www.unicon.org/
- Ultimatt 5y agoI agree strongly on the it could (and should) have been a better Python or Perl. A lot of the reasons I like Raku (previously Perl 6) is that it's adopted a lot of the philosophy of Icon possibly accidentally.