Compare commits
2 Commits
92c6eb16bb
...
4ebca473df
Author | SHA1 | Date |
---|---|---|
|
4ebca473df | |
|
9d328b3d0c |
|
@ -86,7 +86,7 @@ const parser = peg("Schema", p: ParseState):
|
|||
match(readFile path, state)
|
||||
p.schema = move state.schema
|
||||
|
||||
Definition <- ?Annotation * *LineComment * id * '=' * S * (OrPattern | AndPattern | Pattern):
|
||||
Definition <- *LineComment * ?Annotation * id * '=' * S * (OrPattern | AndPattern | Pattern):
|
||||
if p.schema.definitions.hasKey(Symbol $1):
|
||||
raise newException(ValueError, "duplicate definition of " & $0)
|
||||
var
|
||||
|
@ -287,7 +287,8 @@ const parser = peg("Schema", p: ParseState):
|
|||
Value <- Preserves.Value:
|
||||
discard
|
||||
|
||||
Annotation <- '@' * (Preserves.String | Preserves.Record) * S
|
||||
Annotation <- '@' * (Preserves.String | Preserves.Record) * S:
|
||||
discard
|
||||
|
||||
S <- *{ ' ', '\t', '\r', '\n' }
|
||||
|
||||
|
|
Loading…
Reference in New Issue