summaryrefslogtreecommitdiff
path: root/cparser/Elab.ml
diff options
context:
space:
mode:
authorGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2012-02-04 19:14:14 +0000
committerGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2012-02-04 19:14:14 +0000
commit25b9b003178002360d666919f2e49e7f5f4a36e2 (patch)
treed5f7fb317f34f3a7ac9383c21b0eb143317c30f8 /cparser/Elab.ml
parent145b32ec504541e98f73b2c87ff2d8181b5e7968 (diff)
Merge of the "volatile" branch:
- native treatment of volatile accesses in CompCert C's semantics - translation of volatile accesses to built-ins in SimplExpr - native treatment of struct assignment and passing struct parameter by value - only passing struct result by value remains emulated - in cparser, remove emulations that are no longer used - added C99's type _Bool and used it to express || and && more efficiently. git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@1814 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'cparser/Elab.ml')
-rw-r--r--cparser/Elab.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/cparser/Elab.ml b/cparser/Elab.ml
index 870385d..2da1936 100644
--- a/cparser/Elab.ml
+++ b/cparser/Elab.ml
@@ -1508,13 +1508,13 @@ let rec enter_decdefs local loc env = function
(* check for incomplete type *)
if sto' <> Storage_extern && incomplete_type env ty' then
warning loc "'%s' has incomplete type" s;
- if local && sto <> Storage_extern && sto <> Storage_static then begin
+ if local && sto' <> Storage_extern && sto' <> Storage_static then begin
(* Local definition *)
let (decls, env3) = enter_decdefs local loc env2 rem in
((sto', id, ty', init') :: decls, env3)
end else begin
(* Global definition *)
- emit_elab (elab_loc loc) (Gdecl(sto, id, ty', init'));
+ emit_elab (elab_loc loc) (Gdecl(sto', id, ty', init'));
enter_decdefs local loc env2 rem
end