]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/internal/parsing/parser/SCL.grammar
(refs #7250) Support for record syntax for CHR relations
[simantics/platform.git] / bundles / org.simantics.scl.compiler / src / org / simantics / scl / compiler / internal / parsing / parser / SCL.grammar
index 8ff94fd4b8f4db278f4f79f3b57010219f362a90..f7ea1b263617cee6eae8dbc4e5dda34139e10e45 100644 (file)
@@ -55,6 +55,7 @@ declaration
       WHERE ruleDeclarations                                 # RuleDefinition
     | MAPPING_RELATION ID atype*                             # MappingRelationDefinition
     | bexp FOLLOWS ruleDeclarations                          # RelationDefinition
+    | RULESET ID WHERE statements                            # RulesetDefinition
     ;
 
 import
@@ -120,7 +121,6 @@ ruleDeclaration
  */
  
 exp = bexp (HASTYPE type)?                                   # LocalTypeAnnotation, shift HASTYPE, shift COLON
-    | bexp COLON ID WITH? queryBlock?                        # EntityTypeAnnotation, shift LBRACE, shift WITH
     ;
 
 bexp 
@@ -200,7 +200,8 @@ statement
     | exp FOLLOWS queryBlock                                 # RuleStatement
     | chrQuery IMPLIES chrQuery                              # CHRStatement
     | WHEN verboseChrQuery THEN_AFTER_WHEN verboseChrQuery   # VerboseCHRStatement
-    | CONSTRAINT ID atype*                                   # ConstraintStatement
+    | CONSTRAINT constructor                                 # ConstraintStatement
+    | INCLUDE ID aexp                                        # LocalInclude
     ;
 
 chrQuery