summaryrefslogtreecommitdiff
path: root/frontend
diff options
context:
space:
mode:
authorAlex Auvolat <alex.auvolat@ansys.com>2014-07-03 14:36:20 +0200
committerAlex Auvolat <alex.auvolat@ansys.com>2014-07-03 14:36:20 +0200
commit79bf56c809e727ed763e698386163706be2db0a7 (patch)
tree44abbe49e3591fc5ebf7e355c0b7778684eb6685 /frontend
parent82f267be66c1932365bb52b42f54ef03b4211081 (diff)
downloadscade-analyzer-79bf56c809e727ed763e698386163706be2db0a7.tar.gz
scade-analyzer-79bf56c809e727ed763e698386163706be2db0a7.zip
Add ABRO example ; correct interpret bug.
Diffstat (limited to 'frontend')
-rw-r--r--frontend/parser.mly11
1 files changed, 11 insertions, 0 deletions
diff --git a/frontend/parser.mly b/frontend/parser.mly
index 4e010ec..84dcd15 100644
--- a/frontend/parser.mly
+++ b/frontend/parser.mly
@@ -127,6 +127,17 @@ state:
body = b;
until = until;
} }
+| i=boption(INITIAL) STATE n=IDENT
+ unless=trans(UNLESS)
+ b=ext(eqn) SEMICOLON
+ until=trans(UNTIL)
+{ if unless <> [] then failwith "UNLESS transitions not supported.";
+ { initial = i;
+ st_name = n;
+ st_locals = [];
+ body = [b];
+ until = until;
+} }
trans(TT):
| TT t=nonempty_list(terminated(transition, SEMICOLON)) { t }