print a slightly better error if 'case' has no qty

This commit is contained in:
rhiannon morris 2023-03-31 19:33:40 +02:00
parent 13e9285bec
commit 1ab0e42605

View file

@ -166,7 +166,9 @@ lamIntro = symbolsC [(Lam, "λ"), (DLam, "δ")]
private covering
caseIntro : Grammar True PQty
caseIntro = symbols [(One, "case1"), (Any, "caseω")]
<|> resC "case" *> qty <* resC "."
<|> resC "case" *>
(qty <* resC "." <|>
fatalError {c = True} "missing quantity on 'case'")
private
optNameBinder : Grammar False BName