It is aggressive in its unicode support. You want to use vulgar fractions? Or Mayan numerals? They'll work. You want to use mathematical notation like ∈? It works.
I wish more languages other than Raku did this. But no, not equal is written as surprised equal. And if something ought to be less or equal, you have to write a fat arrow pointing left. :/
Yes, I was pointing to Raku as the one exception that does have Unicode operators. Other languages (that I know of) unfortunately don’t support them out of the box.
Then you just need a programming language that accepts ≠ as a synonym of !=. But who knows, maybe there is already one?
Rakulang has you covered.
It is aggressive in its unicode support. You want to use vulgar fractions? Or Mayan numerals? They'll work. You want to use mathematical notation like ∈? It works.
You can literally do this:
`my $var = ⅒ + 2 + Ⅻ;`
https://docs.raku.org/language/unicode_ascii
Julia example: https://juliamono.netlify.app/#fnref:zscode
I can't include an example here because VC News strips out math.
1 reply →
Or just pipe your source through a sed script that replaces one with the other before compiling/running.
Yes, but why?
[dead]
I wish more languages other than Raku did this. But no, not equal is written as surprised equal. And if something ought to be less or equal, you have to write a fat arrow pointing left. :/
Not true: you can use the unicode equivalent as well:
say 42 ≤ 666; # True
say 42 ≠ 666; # True
say 42 ≥ 666; # False
For a full list, see https://docs.raku.org/language/unicode_ascii#Other_acceptabl...
Yes, I was pointing to Raku as the one exception that does have Unicode operators. Other languages (that I know of) unfortunately don’t support them out of the box.
1 reply →
But languages are made by older or less progressive people, so of course you can't use ≠ Unicode in your language enforcing ascii