Equations
- instToFormat = { format := Std.Format.text ∘ toString }
Equations
- List.format _fun_discr = match _fun_discr with | [] => Std.Format.text "[]" | xs => Std.Format.sbracket (Std.Format.joinSep xs (Std.Format.text "," ++ Std.Format.line))
Equations
- instToFormatList = { format := List.format }
Equations
- instToFormatArray = { format := fun a => Std.Format.text "#" ++ Std.format (Array.toList a) }
Equations
- Option.format _fun_discr = match _fun_discr with | none => Std.Format.text "none" | some a => Std.Format.text "some " ++ Std.format a
Equations
- instToFormatOption = { format := Option.format }
instance
instToFormatProd
{α : Type u}
{β : Type v}
[inst : Std.ToFormat α]
[inst : Std.ToFormat β]
:
Std.ToFormat (α × β)
Equations
- instToFormatProd = { format := fun x => match x with | (a, b) => Std.Format.paren (Std.format a ++ Std.Format.text "," ++ Std.Format.line ++ Std.format b) }
Equations
Equations
- instToFormatPos = { format := fun p => Std.format p.byteIdx }