diff options
author | Marek Polacek <polacek@redhat.com> | 2024-02-01 16:11:43 -0500 |
---|---|---|
committer | Marek Polacek <polacek@redhat.com> | 2024-02-01 16:21:36 -0500 |
commit | 8efcdbf59bfed2b888db7def16c7641f26927260 (patch) | |
tree | 096f5de0a9054c6f1f756fda823b38f234e54b5e /libcpp | |
parent | 44764984cf24e27cf7756cffd197283b9c62db8b (diff) | |
download | gcc-8efcdbf59bfed2b888db7def16c7641f26927260.zip gcc-8efcdbf59bfed2b888db7def16c7641f26927260.tar.gz gcc-8efcdbf59bfed2b888db7def16c7641f26927260.tar.bz2 |
c++: -Wdangling-reference tweak to unbreak aarch64
My recent -Wdangling-reference change to not warn on std::span-like classes
unfortunately caused a new warning: extending reference_like_class_p also
opens the door to new warnings since we use reference_like_class_p for
checking the return type of the function: either it must be a reference
or a reference_like_class_p.
We can consider even non-templates as std::span-like to get rid of the
warning here.
gcc/cp/ChangeLog:
* call.cc (reference_like_class_p): Consider even non-templates for
std::span-like classes.
gcc/ChangeLog:
* doc/invoke.texi: Update -Wdangling-reference documentation.
gcc/testsuite/ChangeLog:
* g++.dg/warn/Wdangling-reference21.C: New test.
Diffstat (limited to 'libcpp')
0 files changed, 0 insertions, 0 deletions