Skip to content

Commit

Permalink
Add unicode minus: U+2122 (#72)
Browse files Browse the repository at this point in the history
  • Loading branch information
rocky authored Sep 8, 2024
1 parent a07df87 commit 5f8f525
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions mathics_scanner/data/named-characters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5674,10 +5674,12 @@ Micro:
wl-unicode-name: MICRO SIGN

Minus:
amslatex: "$-$"
ascii: "-"
has-unicode-inverse: false
is-letter-like: false
operator-name: Minus
unicode-equivalent: "\u2212"

MinusPlus:
amslatex: "\\mp"
Expand Down
2 changes: 1 addition & 1 deletion mathics_scanner/generate/build_tables.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def compile_tables(data: dict) -> dict:
# Conversion from unicode or ascii to wl dictionary entry.
# We filter the dictionary after it's first created to redundant entries
unicode_to_wl_dict = {
v.get("unicode-equivalent", v.get("ascii")): v["wl-unicode"]
v.get("unicode-equivalent", v.get("ascii")): v.get("wl-unicode", v.get("ascii"))
for v in data.values()
if ("unicode-equivalent" in v or "ascii" in v) and v["has-unicode-inverse"]
}
Expand Down

0 comments on commit 5f8f525

Please sign in to comment.