From de2147cce030fa81f7593744de3fdca453a087b7 Mon Sep 17 00:00:00 2001 From: Valentin Perrelle <valentin.perrelle@cea.fr> Date: Tue, 4 Aug 2020 11:43:47 +0200 Subject: [PATCH] [Aorai] Use semicolons to separate metavariable assignements --- src/plugins/aorai/tests/ya/metavariables-right.ya | 3 ++- src/plugins/aorai/yaparser.mly | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/plugins/aorai/tests/ya/metavariables-right.ya b/src/plugins/aorai/tests/ya/metavariables-right.ya index bacd7713870..e893ccf4d07 100644 --- a/src/plugins/aorai/tests/ya/metavariables-right.ya +++ b/src/plugins/aorai/tests/ya/metavariables-right.ya @@ -3,11 +3,12 @@ %deterministic; $x : int; +$y : int; a : { CALL(main) } -> b; b : - { CALL(f) } $x := f().x -> c + { CALL(f) } $y := $x; $x := f().x -> c | { CALL(g) } -> d ; diff --git a/src/plugins/aorai/yaparser.mly b/src/plugins/aorai/yaparser.mly index 655a5d32db9..2e05fb24680 100644 --- a/src/plugins/aorai/yaparser.mly +++ b/src/plugins/aorai/yaparser.mly @@ -400,8 +400,8 @@ actions ; non_empty_actions - : non_empty_actions action { $1 @ [$2] } - | action { [$1] } + : non_empty_actions SEMI_COLON action { $1 @ [$3] } + | action { [$1] } ; action -- GitLab