Skip to content

Comment on K: We need to talk about groupparent

Comments

Isn't the original APL the only lang that uses actual Unicode symbols for operators?

APL predates Unicode! You used to have to use special APL keyboards to write it. The symbols were included in Unicode as a way to try and make APL more palatable.

The symbols were included in Unicode as a way to try and make APL more palatable.

That seems highly unlikely. Do you have a source, or are you sharing speculation as fact?

It’s more likely that APL symbols were included in Unicode as part of its mission to unify all the world’s scripts into single code set.

They weren't included to make it more palatable, but because APL was being actively used in larger systems.

There are esoteric code golf languages that use unicode. MPW (shell, assembler) used extended characters (MacRoman, not unicode but then again, APL also predates unicode) for some operations.

eg, instead of "echo yo >> file" you would "echo yo ≥ file"

Julia has support for Unicode operators. Most editor plugins for Julia allow you to enter the characters using (La)Tex syntax, so it’s quite common to see.

Unicode support doesn't really seem that uncommon, in the grand scheme. Rosetta Code's wiki has a page for languages that support Unicode variable names[0] and some of them were surprising to me (e.g. AppleScript).

Of course, supporting Unicode variable names doesn't mean a language supports Unicode anywhere, but it's a starting point for historical research at least.

[0]: https://rosettacode.org/wiki/Unicode_variable_names

APL predates the first documented thoughts (not specification/implementation) of unicode by roughly 20 years.

APL predates the first documented thoughts

I used to think that Lisp was bad, with its "God coded the universe in Lisp", then I read only the first part of your sentence, and was "Woha, so APL predates thought?!"

https://www.youtube.com/watch?v=5-OjTPj7K54

There’s also at least BQN, which I suspect is the language used in those comments:

https://mlochbaum.github.io/BQN/

Yep, the comments are the BQN version.

Raku (fka perl6) has some, eg you can use <atom emoji>+= to atomically increment a value.

Haskell allows defining unicode operators, and has an extension that allows you to use unicode symbols instead of ascii sequences in various parts of the syntax.

Agda does too! https://plfa.github.io/ for examples

No.

In the Raku Programming Language there are several non-ASCII operators, although each of them has a pure ASCII equivalent. Some examples: ≤ vs <=, ≠ vs !=, ∈ vs (elem), etc.

The full list: https://docs.raku.org/language/unicode_ascii.html

this is a bit obscure but Trealla Prolog allows for full unicode in the source and user defined operators, which is nice.

Fortress.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.