feat: formatter: interpret checkWsBefore as soft space

This commit is contained in:
Sebastian Ullrich 2020-09-18 16:36:43 +02:00 committed by Leonardo de Moura
parent 95007171a8
commit 519eda2459
2 changed files with 7 additions and 5 deletions

View file

@ -375,7 +375,7 @@ p
@[combinatorFormatter checkWsBefore] def checkWsBefore.formatter : Formatter := do
modify fun st => { st with leadWord := "" };
push " "
pushLine
@[combinatorFormatter checkPrec] def checkPrec.formatter : Formatter := pure ()
@[combinatorFormatter checkStackTop] def checkStackTop.formatter : Formatter := pure ()

View file

@ -20,7 +20,9 @@ fun
(b : Bool) =>
a
fun {a b : Nat} => a
typeAs ({α : Type} → αα) fun
typeAs
({α : Type} → αα)
fun
{α : Type}
(a : α) =>
a
@ -52,6 +54,6 @@ Type → Type → Type
(1, 2, 3)
(1, 2).fst
1 < 2 || true
id (fun
(a : Nat) =>
a) 0
id
(fun (a : Nat) => a)
0