diff options
author | Jason Merrill <jason@redhat.com> | 2020-02-25 13:37:18 -0500 |
---|---|---|
committer | Jason Merrill <jason@redhat.com> | 2020-02-25 23:35:45 -0500 |
commit | b6136084ea86ab0d3fac54be83e50817a3db74a9 (patch) | |
tree | 2a2bc6cb6254348a297a46d55b3214948f58ccf2 /gcc/cp/ChangeLog | |
parent | a57528b33be33d4428ac62901d04cf39807d624e (diff) | |
download | gcc-b6136084ea86ab0d3fac54be83e50817a3db74a9.zip gcc-b6136084ea86ab0d3fac54be83e50817a3db74a9.tar.gz gcc-b6136084ea86ab0d3fac54be83e50817a3db74a9.tar.bz2 |
PR c++/87685 - generic lambda 'this' capture error.
The standard says that in a generic lambda we should speculatively capture
'this' if we see a call to an overload set that contains a non-static member
function, but it seems wrong to reject the program if we can't capture,
since it might not actually be needed.
gcc/cp/ChangeLog
2020-02-25 Jason Merrill <jason@redhat.com>
PR c++/87685 - generic lambda 'this' capture error.
* lambda.c (lambda_expr_this_capture): Change add_capture_p to int.
(maybe_generic_this_capture): Pass -1.
Diffstat (limited to 'gcc/cp/ChangeLog')
-rw-r--r-- | gcc/cp/ChangeLog | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 3480403..edbc1ba 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,11 @@ 2020-02-25 Jason Merrill <jason@redhat.com> + PR c++/87685 - generic lambda 'this' capture error. + * lambda.c (lambda_expr_this_capture): Change add_capture_p to int. + (maybe_generic_this_capture): Pass -1. + +2020-02-25 Jason Merrill <jason@redhat.com> + PR c++/87554 - ICE with extern template and reference member. * decl.c (cp_finish_decl): Don't set DECL_INITIAL of external vars. |