Zulip Chat Archive
Stream: lean4
Topic: unsupported unicode
Jihoon Hyun (Aug 10 2023 at 19:17):
The unicode for double tack (⫫ : U+2AEB) is not supported.
Is there a list of unicodes supported in lean?
Eric Wieser (Aug 10 2023 at 19:17):
Works for me:
notation "⫫" => 0
#check ⫫
Eric Wieser (Aug 10 2023 at 19:18):
What do you mean by "unsupported"?
Jihoon Hyun (Aug 10 2023 at 19:18):
I meant that it couldn't be used as a variable like \alpha. Although after looking at your answer, I thought it is definitely not a variable..
Jon Eugster (Aug 10 2023 at 22:03):
Do you mean that the following things don't work:
variable (⫫ : ℕ) -- error: expected token
variable (ˣ : ℕ) -- error: expected token
variable (₁s : ℕ) -- error: expected token
I wanna say that variable names are of type Lean.Name
and not everything is allowed in them. However, I wouldn't know how I'd find out what the rules are.
Eric Wieser (Aug 10 2023 at 22:05):
variable («⫫» : ℕ) -- ok
variable («ˣ» : ℕ) -- ok
variable («₁s» : ℕ) -- ok
Mario Carneiro (Aug 11 2023 at 13:34):
there is a specific set of unicode codepoints allowed in identifiers without quoting, basically alphabetic characters in several languages plus letter-like symbols
Mario Carneiro (Aug 11 2023 at 13:35):
Last updated: Dec 20 2023 at 11:08 UTC