diff --git a/lib/Quox/Parser/Lexer.idr b/lib/Quox/Parser/Lexer.idr index c18c4a5..1e50c8c 100644 --- a/lib/Quox/Parser/Lexer.idr +++ b/lib/Quox/Parser/Lexer.idr @@ -153,23 +153,12 @@ tag = tmatch (is '\'' <+> name) (Tag . drop 1) <|> match (is '\'' <+> stringLit) (fromStringLit Tag . drop 1) - -private %inline -fromSub : Char -> Char -fromSub c = case c of - '₀' => '0'; '₁' => '1'; '₂' => '2'; '₃' => '3'; '₄' => '4' - '₅' => '5'; '₆' => '6'; '₇' => '7'; '₈' => '8'; '₉' => '9'; _ => c - private %inline fromSup : Char -> Char fromSup c = case c of '⁰' => '0'; '¹' => '1'; '²' => '2'; '³' => '3'; '⁴' => '4' '⁵' => '5'; '⁶' => '6'; '⁷' => '7'; '⁸' => '8'; '⁹' => '9'; _ => c -private %inline -subToNat : String -> Nat -subToNat = cast . pack . map fromSub . unpack - private %inline supToNat : String -> Nat supToNat = cast . pack . map fromSup . unpack diff --git a/lib/Quox/Syntax/Term/Pretty.idr b/lib/Quox/Syntax/Term/Pretty.idr index ffdb3e9..cc1784d 100644 --- a/lib/Quox/Syntax/Term/Pretty.idr +++ b/lib/Quox/Syntax/Term/Pretty.idr @@ -30,14 +30,6 @@ BTelescope : Nat -> Nat -> Type BTelescope = Telescope' BindName -private -subscript : String -> String -subscript = pack . map sub . unpack where - sub : Char -> Char - sub c = case c of - '0' => '₀'; '1' => '₁'; '2' => '₂'; '3' => '₃'; '4' => '₄' - '5' => '₅'; '6' => '₆'; '7' => '₇'; '8' => '₈'; '9' => '₉'; _ => c - private superscript : String -> String superscript = pack . map sup . unpack where