[PATCH] D153536: [Clang] Implement P2169 A nice placeholder with no name
Hubert Tong via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Jul 14 16:53:27 PDT 2023
hubert.reinterpretcast added inline comments.
================
Comment at: clang/docs/ReleaseNotes.rst:136-139
+- Implemented `P2169R4: A nice placeholder with no name <https://wg21.link/P2169R4>`_. This allows using `_`
+ as a variable name multiple times in the same scope and is supported in all C++ language modes as an extension.
+ An extension warning is produced when multiple variables are introduced by `_` in the same scope.
+ Unused warnings are no longer produced for variables named `_`.
----------------
Use double backticks to start/end inline code in RST.
================
Comment at: clang/lib/Sema/SemaInit.cpp:2607
+ ValueDecl *VD =
+ SemaRef.tryLookupUnambiguousFieldDecl(RT->getDecl(), FieldName);
+ if (auto *FD = dyn_cast_if_present<FieldDecl>(VD)) {
----------------
Needs rebase on top of 632dd6a4ca00.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D153536/new/
https://reviews.llvm.org/D153536
More information about the cfe-commits
mailing list