diff options
author | Alexandre Oliva <aoliva@redhat.com> | 2018-03-31 03:44:12 +0000 |
---|---|---|
committer | Alexandre Oliva <aoliva@gcc.gnu.org> | 2018-03-31 03:44:12 +0000 |
commit | fc8b67411812f81151b4fa3dfcc0bd378e2d5cf8 (patch) | |
tree | aa2d7f2777c76281bd8764c9a564d0ce67a0b79f /gcc/config.gcc | |
parent | ec8d8a5b5c1cf75cd62b908e2ace053ed2b05ec2 (diff) | |
download | gcc-fc8b67411812f81151b4fa3dfcc0bd378e2d5cf8.zip gcc-fc8b67411812f81151b4fa3dfcc0bd378e2d5cf8.tar.gz gcc-fc8b67411812f81151b4fa3dfcc0bd378e2d5cf8.tar.bz2 |
[PR c++/85027] deal with baselink in save_expr in instantiate_type
We use SAVE_EXPRs in conditional expressions without the middle
operand, to evaluate the first operand only once. When the conversion
of the first operand fails, we may call instantiate_type get a better
error message. We have code to peel off the SAVE_EXPR there, but then
we may end up with a BASELINK, and we're past the code that deals with
BASELINKs. Reorder the tests so that we expose the saved expr first,
and then deal with BASELINKs.
for gcc/cp/ChangeLog
PR c++/85027
* class.c (instantiate_type): Peel off SAVE_EXPR before
BASELINK.
for gcc/testsuite/ChangeLog
PR c++/85027
* g++.dg/pr85027.C: New.
From-SVN: r258989
Diffstat (limited to 'gcc/config.gcc')
0 files changed, 0 insertions, 0 deletions