public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug c++/102610] New: [C++23] P2036R3 - Change scope of lambda trailing-return-type @ 2021-10-05 16:13 mpolacek at gcc dot gnu.org 2022-08-16 16:16 ` [Bug c++/102610] " mpolacek at gcc dot gnu.org 2023-08-31 11:38 ` jakub at gcc dot gnu.org 0 siblings, 2 replies; 3+ messages in thread From: mpolacek at gcc dot gnu.org @ 2021-10-05 16:13 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102610 Bug ID: 102610 Summary: [C++23] P2036R3 - Change scope of lambda trailing-return-type Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: mpolacek at gcc dot gnu.org Target Milestone: --- See https://wg21.link/p2036r3 ^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c++/102610] [C++23] P2036R3 - Change scope of lambda trailing-return-type 2021-10-05 16:13 [Bug c++/102610] New: [C++23] P2036R3 - Change scope of lambda trailing-return-type mpolacek at gcc dot gnu.org @ 2022-08-16 16:16 ` mpolacek at gcc dot gnu.org 2023-08-31 11:38 ` jakub at gcc dot gnu.org 1 sibling, 0 replies; 3+ messages in thread From: mpolacek at gcc dot gnu.org @ 2022-08-16 16:16 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102610 Marek Polacek <mpolacek at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever confirmed|0 |1 Last reconfirmed| |2022-08-16 --- Comment #1 from Marek Polacek <mpolacek at gcc dot gnu.org> --- https://wg21.link/p2579r0, Mitigation strategies for P2036 ”Changing scope for lambda trailing-return-type”, was also approved. ^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c++/102610] [C++23] P2036R3 - Change scope of lambda trailing-return-type 2021-10-05 16:13 [Bug c++/102610] New: [C++23] P2036R3 - Change scope of lambda trailing-return-type mpolacek at gcc dot gnu.org 2022-08-16 16:16 ` [Bug c++/102610] " mpolacek at gcc dot gnu.org @ 2023-08-31 11:38 ` jakub at gcc dot gnu.org 1 sibling, 0 replies; 3+ messages in thread From: jakub at gcc dot gnu.org @ 2023-08-31 11:38 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102610 Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jakub at gcc dot gnu.org --- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Related question for the last paper: https://github.com/cplusplus/draft/issues/6536 Other than that, I guess opening a new sk_lambda scope in cp_parser_lambda_declarator_opt at the start and leaving it at the end should be easy, but we only build_capture_proxy later on. Shall we pushdecl into the sk_lambda scope instead the LAMBDA_CAPTURE_EXPLICIT_P && !DECL_NORMAL_CAPTURE_P captures and somehow special-case them in name lookup or just finish_decltype_type where we currently handle the if (outer_automatic_var_p (expr) && current_function_decl && LAMBDA_FUNCTION_P (current_function_decl)) type = capture_decltype (expr); case? Though, in the lambda declarator, current_function_decl is still the containing function and outer_automatic_var_p also will not work. I guess we need some way to know whether we are in the lambda declarator (and also whether it is before the end of parameter declarations or after and whether in the latter case the lambda is mutable or not) and special case in that case both the init-captures and automatic? vars from the current function (which will be outer vars in lambda body). ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-08-31 11:38 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2021-10-05 16:13 [Bug c++/102610] New: [C++23] P2036R3 - Change scope of lambda trailing-return-type mpolacek at gcc dot gnu.org 2022-08-16 16:16 ` [Bug c++/102610] " mpolacek at gcc dot gnu.org 2023-08-31 11:38 ` jakub at gcc dot gnu.org
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).