aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-inline.c
diff options
context:
space:
mode:
authorJason Merrill <jason@redhat.com>2021-05-31 12:36:25 -0400
committerJason Merrill <jason@redhat.com>2021-06-02 14:40:20 -0400
commit63d182b29306e582bfb151cf762820211ea1cc7e (patch)
tree920f37acf7dc517abab88adcdb035293a121d340 /gcc/tree-inline.c
parent659cc7d6320aae7ab390b5886f0efed22f78e244 (diff)
downloadgcc-63d182b29306e582bfb151cf762820211ea1cc7e.zip
gcc-63d182b29306e582bfb151cf762820211ea1cc7e.tar.gz
gcc-63d182b29306e582bfb151cf762820211ea1cc7e.tar.bz2
c++: missing dtor with -fno-elide-constructors [PR100838]
tf_no_cleanup only applies to the outermost TARGET_EXPR, and we already clear it for nested calls in build_over_call, but in this case both constructor calls came from convert_like, so we need to clear it in the recursive call as well. This revealed that we were adding an extra ck_rvalue in direct-initialization cases where it was wrong. PR c++/100838 gcc/cp/ChangeLog: * call.c (convert_like_internal): Clear tf_no_cleanup when recursing. (build_user_type_conversion_1): Only add ck_rvalue if LOOKUP_ONLYCONVERTING. gcc/testsuite/ChangeLog: * g++.dg/init/no-elide2.C: New test.
Diffstat (limited to 'gcc/tree-inline.c')
0 files changed, 0 insertions, 0 deletions