diff options
author | Alexandre Oliva <aoliva@redhat.com> | 2018-03-06 06:24:40 +0000 |
---|---|---|
committer | Alexandre Oliva <aoliva@gcc.gnu.org> | 2018-03-06 06:24:40 +0000 |
commit | 1ea71a82f9d42684c542147b231afb63e8a6da8f (patch) | |
tree | 20819b137643b69d6eadb2f84b1076132aff78cf /gcc/ada/gcc-interface/utils.c | |
parent | 4900146ce0cf227aee88a1bd3b152c9394c64771 (diff) | |
download | gcc-1ea71a82f9d42684c542147b231afb63e8a6da8f.zip gcc-1ea71a82f9d42684c542147b231afb63e8a6da8f.tar.gz gcc-1ea71a82f9d42684c542147b231afb63e8a6da8f.tar.bz2 |
[PR c++/84492] stmt expr ending with overload
We ICEd when returning a stmt expr that ends with an overloaded
function, because instantiate_type did not know what to do with
STMT_EXPRs. And it shouldn't have to: the expected type of a stmt
expr cannot be used to resolve its value: an unresolved overload
cannot supply the result of a stmt expr. Catch that and report the
error in the stmt expr before we have a chance to instantiate it.
for gcc/cp/ChangeLog
PR c++/84492
* semantics.c (finish_stmt_expr_expr): Reject unresolved
overloads used as stmt expr values.
for gcc/testsuite/ChangeLog
PR c++/84492
* g++.dg/pr84492.C: New.
From-SVN: r258269
Diffstat (limited to 'gcc/ada/gcc-interface/utils.c')
0 files changed, 0 insertions, 0 deletions