feat: Shorter symbol category #33

Merged
aniva merged 3 commits from io/symbol into dev 2023-11-27 10:36:44 -08:00
2 changed files with 10 additions and 10 deletions

View File

@ -14,15 +14,15 @@ 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 :=
if is_symbol_unsafe_or_internal n info if is_symbol_unsafe_or_internal n info

View File

@ -1,5 +1,5 @@
namespace Pantograph namespace Pantograph
def version := "0.2.8" def version := "0.2.9"
end Pantograph end Pantograph