aboutsummaryrefslogtreecommitdiffstats
path: root/cparser/pre_parser.mly
diff options
context:
space:
mode:
authorXavier Leroy <xavier.leroy@inria.fr>2014-12-29 11:51:25 +0100
committerXavier Leroy <xavier.leroy@inria.fr>2014-12-29 11:51:25 +0100
commit10120fe4d9980139e44012888a91716df2edf2e0 (patch)
treef7348c43fb2c3aca61397b352761394ba17f87f4 /cparser/pre_parser.mly
parentc8287e6578f313769c794fd407868b1ecb51c43f (diff)
downloadcompcert-10120fe4d9980139e44012888a91716df2edf2e0.tar.gz
compcert-10120fe4d9980139e44012888a91716df2edf2e0.zip
Support "asm volatile" (closes: PR#5).
The CompCert back-end already treats "asm" inserts as "volatile" in GCC's sense (performing unpredictable side-effects), so no change is required outside of the parser.
Diffstat (limited to 'cparser/pre_parser.mly')
-rw-r--r--cparser/pre_parser.mly2
1 files changed, 1 insertions, 1 deletions
diff --git a/cparser/pre_parser.mly b/cparser/pre_parser.mly
index 4755518b..ef356d3a 100644
--- a/cparser/pre_parser.mly
+++ b/cparser/pre_parser.mly
@@ -616,7 +616,7 @@ jump_statement:
{}
asm_statement:
-| ASM LPAREN string_literals_list RPAREN SEMICOLON
+| ASM VOLATILE? LPAREN string_literals_list RPAREN SEMICOLON
{}
translation_unit_file: