feat: Shorter symbol category

This commit is contained in:
Leni Aniva 2023-11-26 22:14:58 -08:00
parent 7b59937853
commit 7690272bfa
Signed by: aniva
GPG Key ID: 4D9B1C8D10EA4C50
1 changed files with 8 additions and 8 deletions

View File

@ -14,14 +14,14 @@ def is_symbol_unsafe_or_internal (n: Lean.Name) (info: Lean.ConstantInfo): Bool
def to_compact_symbol_name (n: Lean.Name) (info: Lean.ConstantInfo): String := def to_compact_symbol_name (n: Lean.Name) (info: Lean.ConstantInfo): String :=
let pref := match info with let pref := match info with
| .axiomInfo _ => "axiom" | .axiomInfo _ => "a"
| .defnInfo _ => "defn" | .defnInfo _ => "d"
| .thmInfo _ => "thm" | .thmInfo _ => "t"
| .opaqueInfo _ => "opaque" | .opaqueInfo _ => "o"
| .quotInfo _ => "quot" | .quotInfo _ => "q"
| .inductInfo _ => "induct" | .inductInfo _ => "i"
| .ctorInfo _ => "ctor" | .ctorInfo _ => "c"
| .recInfo _ => "rec" | .recInfo _ => "r"
s!"{pref}|{toString n}" s!"{pref}|{toString n}"
def to_filtered_symbol (n: Lean.Name) (info: Lean.ConstantInfo): Option String := def to_filtered_symbol (n: Lean.Name) (info: Lean.ConstantInfo): Option String :=