diff options
author | Bernhard Schommer <bschommer@users.noreply.github.com> | 2018-03-29 16:49:53 +0200 |
---|---|---|
committer | Xavier Leroy <xavierleroy@users.noreply.github.com> | 2018-03-29 16:49:53 +0200 |
commit | d1ff2fcb7c2875b3c371a124579aef419199195b (patch) | |
tree | e6bafaca6a1050eed828d86189ccdc408a5951da /cparser/Elab.ml | |
parent | de293458027a28f3a3576354dc0e4ec90f824bda (diff) | |
download | compcert-d1ff2fcb7c2875b3c371a124579aef419199195b.tar.gz compcert-d1ff2fcb7c2875b3c371a124579aef419199195b.zip |
Don't overwrite initializer of anonymous union member. (#69)
Instead of overwriting the initializer of the anonymous member we
should just keep it.
Bug 23353
Diffstat (limited to 'cparser/Elab.ml')
-rw-r--r-- | cparser/Elab.ml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cparser/Elab.ml b/cparser/Elab.ml index 204bc515..3ed8fe2f 100644 --- a/cparser/Elab.ml +++ b/cparser/Elab.ml @@ -1229,7 +1229,7 @@ module I = struct if fld1.fld_name = name then Some(Zunion(z, id, fld1), default_init env fld1.fld_typ) else if fld.fld_anonymous && has_member env name fld.fld_typ then - let zi = (Zunion(z, id, fld1),default_init env fld1.fld_typ) in + let zi = (Zunion(z, id, fld1),i) in member env zi name else find rem |