aboutsummaryrefslogtreecommitdiff
path: root/gcc/expr.c
diff options
context:
space:
mode:
authorMarek Polacek <polacek@redhat.com>2019-10-21 18:45:45 +0000
committerMarek Polacek <mpolacek@gcc.gnu.org>2019-10-21 18:45:45 +0000
commitafa8c090bf5ee17d89628b4885efad3a7ea62505 (patch)
tree65f87ce073121c8d4bd994dcf4e5e74123b412fd /gcc/expr.c
parente011c0100a83030e0cfd230658debbb6c97660a1 (diff)
downloadgcc-afa8c090bf5ee17d89628b4885efad3a7ea62505.zip
gcc-afa8c090bf5ee17d89628b4885efad3a7ea62505.tar.gz
gcc-afa8c090bf5ee17d89628b4885efad3a7ea62505.tar.bz2
PR c++/92062 - ODR-use ignored for static member of class template.
has_value_dependent_address wasn't stripping location wrappers so it gave the wrong answer for "&x" in the static_assert. That led us to thinking that the expression isn't instantiation-dependent, and we skipped static initialization of A<0>::x. This patch adds stripping so that has_value_dependent_address gives the same answer as it used to before the location wrappers addition. * pt.c (has_value_dependent_address): Strip location wrappers. * g++.dg/cpp0x/constexpr-odr1.C: New test. * g++.dg/cpp0x/constexpr-odr2.C: New test. From-SVN: r277266
Diffstat (limited to 'gcc/expr.c')
0 files changed, 0 insertions, 0 deletions