diff options
Diffstat (limited to 'subprojects/frontend/src/language/problem.grammar')
-rw-r--r-- | subprojects/frontend/src/language/problem.grammar | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/subprojects/frontend/src/language/problem.grammar b/subprojects/frontend/src/language/problem.grammar index 95861110..7feb6bfe 100644 --- a/subprojects/frontend/src/language/problem.grammar +++ b/subprojects/frontend/src/language/problem.grammar | |||
@@ -18,7 +18,10 @@ statement { | |||
18 | (EnumBody { "{" sep<",", IndividualNodeName> "}" } | ".") | 18 | (EnumBody { "{" sep<",", IndividualNodeName> "}" } | ".") |
19 | } | | 19 | } | |
20 | PredicateDefinition { | 20 | PredicateDefinition { |
21 | (ckw<"error"> ckw<"pred">? | ckw<"pred">) | 21 | ( |
22 | (ckw<"error"> | ckw<"contained"> | ckw<"containment">) ckw<"pred">? | | ||
23 | ckw<"pred"> | ||
24 | ) | ||
22 | RelationName ParameterList<Parameter>? | 25 | RelationName ParameterList<Parameter>? |
23 | PredicateBody { ("<->" sep<OrOp, Conjunction>)? "." } | 26 | PredicateBody { ("<->" sep<OrOp, Conjunction>)? "." } |
24 | } | | 27 | } | |
@@ -28,23 +31,29 @@ statement { | |||
28 | RuleBody { ":" sep<OrOp, Conjunction> "==>" sep<OrOp, Consequent> "." } | 31 | RuleBody { ":" sep<OrOp, Conjunction> "==>" sep<OrOp, Consequent> "." } |
29 | } | | 32 | } | |
30 | Assertion { | 33 | Assertion { |
31 | kw<"default">? (NotOp | UnknownOp)? RelationName | 34 | ckw<"default">? (NotOp | UnknownOp)? RelationName |
32 | ParameterList<AssertionArgument> (":" LogicValue)? "." | 35 | ParameterList<AssertionArgument> (":" LogicValue)? "." |
33 | } | | 36 | } | |
34 | NodeValueAssertion { | 37 | NodeValueAssertion { |
35 | IndividualNodeName ":" Constant "." | 38 | QualifiedName ":" Constant "." |
36 | } | | 39 | } | |
37 | IndividualDeclaration { | 40 | IndividualDeclaration { |
38 | ckw<"indiv"> sep<",", IndividualNodeName> "." | 41 | ckw<"indiv"> sep<",", IndividualNodeName> "." |
39 | } | | 42 | } | |
40 | ScopeDeclaration { | 43 | ScopeDeclaration { |
41 | kw<"scope"> sep<",", ScopeElement> "." | 44 | ckw<"scope"> sep<",", ScopeElement> "." |
42 | } | 45 | } |
43 | } | 46 | } |
44 | 47 | ||
45 | ReferenceDeclaration { | 48 | ReferenceDeclaration { |
46 | (kw<"refers"> | kw<"contains">)? | 49 | ( |
47 | RelationName | 50 | ExplicitContainmentReference[@dynamicPrecedence=1] { |
51 | (ckw<"refers"> | ckw<"contains"> | ckw<"container">) RelationName ~containment | ||
52 | } | | ||
53 | ImplicitContainmentReference { | ||
54 | RelationName ~containment | ||
55 | } | ||
56 | ) | ||
48 | ("[" Multiplicity? "]")? | 57 | ("[" Multiplicity? "]")? |
49 | RelationName | 58 | RelationName |
50 | (kw<"opposite"> RelationName)? | 59 | (kw<"opposite"> RelationName)? |