make 0 in ★₀ optional
This commit is contained in:
parent
7c68cd9098
commit
3bbf0366c8
8 changed files with 56 additions and 56 deletions
|
@ -274,7 +274,7 @@ tupleTerm fname = withLoc fname $ do
|
|||
|
||||
export
|
||||
universe1 : Grammar True Universe
|
||||
universe1 = universeTok <|> res "★" *> super
|
||||
universe1 = universeTok <|> res "★" *> option 0 super
|
||||
|
||||
||| argument/atomic term: single-token terms, or those with delimiters e.g.
|
||||
||| `[t]`
|
||||
|
@ -359,8 +359,8 @@ compTerm fname = withLoc fname $ do
|
|||
export
|
||||
splitUniverseTerm : FileName -> Grammar True PTerm
|
||||
splitUniverseTerm fname =
|
||||
withLoc fname $ resC "★" *> mustWork [|TYPE $ nat <|> super|]
|
||||
-- having super here looks redundant, but when parsing a non-atomic term
|
||||
withLoc fname $ resC "★" *> [|TYPE $ option 0 $ nat <|> super|]
|
||||
-- some of this looks redundant, but when parsing a non-atomic term
|
||||
-- this branch will be taken first
|
||||
|
||||
export
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue