diff options
author | Jason Merrill <jason@redhat.com> | 2019-09-16 00:34:28 -0400 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2019-09-16 00:34:28 -0400 |
commit | ddc1a45b373ce98929d0d67e8c97ab6783236c40 (patch) | |
tree | b9bb7f45f7ac6bf4b3c98acb45531feae12abf9e /gcc/tree-ssa-alias.c | |
parent | 47518e131f299f69d0c14f7e5efe83609185ed9f (diff) | |
download | gcc-ddc1a45b373ce98929d0d67e8c97ab6783236c40.zip gcc-ddc1a45b373ce98929d0d67e8c97ab6783236c40.tar.gz gcc-ddc1a45b373ce98929d0d67e8c97ab6783236c40.tar.bz2 |
PR c++/30277 - int-width bit-field promotion.
Here, if cp_perform_integral_promotions saw that the TREE_TYPE of a
bit-field reference was the same as the type it promotes to, it didn't do
anything. But then decay_conversion saw that the bit-field reference was
unchanged, and converted it to its declared type. So I needed to add
something to make it clear that promotion has been done. But then the 33819
change caused trouble by looking through the NOP_EXPR I just added. This
was the wrong fix for that bug; I've now fixed that better by recognizing in
cp_perform_integral_promotions that we won't promote a bit-field larger than
32 bits, so we should use the declared type.
PR c++/33819 - long bit-field promotion.
* typeck.c (cp_perform_integral_promotions): Handle large bit-fields
properly. Handle 32-bit non-int bit-fields properly.
(is_bitfield_expr_with_lowered_type): Don't look through NOP_EXPR.
From-SVN: r275746
Diffstat (limited to 'gcc/tree-ssa-alias.c')
0 files changed, 0 insertions, 0 deletions