[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2022-06-15 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added a comment. Herald added a project: All. This is very belated, sorry :) Our shadowing warnings have special behavior for lambdas and local variables: the warning for lambdas shadowing uncaptured local variables falls under `-Wshadow-uncaptured-local`, which isn't turned on for `-Ws

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-23 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG039f79c78cfa: [SEMA] Added warn_decl_shadow support for structured bindings (authored by Vexthil, committed by rsmith). Changed prior to commit: https://reviews.llvm.org/D96147?vs=325578&id=325892#toc

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-22 Thread David Crook via Phabricator via cfe-commits
Vexthil added a comment. .. And yes I will need someone to commit this for me I believe once you are happy with it. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96147/new/ https://reviews.llvm.org/D96147 ___ cfe-commits mailing list cfe-com

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-22 Thread David Crook via Phabricator via cfe-commits
Vexthil updated this revision to Diff 325578. Vexthil added a comment. Added unit tests for "shadows a structured binding" CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96147/new/ https://reviews.llvm.org/D96147 Files: clang/docs/ReleaseNotes.rst clang/include/clang/Basic/Diagnosti

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-21 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Hm, before we go forward with this: can we get a test for the "shadows a structured binding" case, please? You might also need to add a new case to the "declaration shadows ..." warning text. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://rev

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-21 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. Looks good, thanks! Do you need someone to commit this for you? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96147/new/ https://reviews.llvm.or

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-20 Thread David Crook via Phabricator via cfe-commits
Vexthil updated this revision to Diff 325256. Vexthil added a comment. Fixing clang format issues. The SemaDecl.cpp has a pile of incorrect clang format issues but i've only updated changes relevant to changes I have made Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-20 Thread David Crook via Phabricator via cfe-commits
Vexthil updated this revision to Diff 325252. Vexthil added a comment. Update with changes suggested by @rsmith . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96147/new/ https://reviews.llvm.org/D96147 Files: clang/docs/ReleaseNotes.rst clang

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-17 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Thanks! Comment at: clang/lib/Sema/SemaDecl.cpp:7571 + NamedDecl *ShadowedDecl = R.getFoundDecl(); + return isa(ShadowedDecl) || isa(ShadowedDecl) + ? ShadowedDecl rsmith wrote: > I think we should also warn if a `BindingDe

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-06 Thread David Crook via Phabricator via cfe-commits
Vexthil updated this revision to Diff 321930. Vexthil added a comment. Fixed the update by doing a full diff rather than just the additive update CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96147/new/ https://reviews.llvm.org/D96147 Files: clang/docs/ReleaseNotes.rst clang/includ

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-05 Thread David Crook via Phabricator via cfe-commits
Vexthil updated this revision to Diff 321860. Vexthil added a comment. Updating clang format Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96147/new/ https://reviews.llvm.org/D96147 Files: clang/include/clang/Sema/Sema.h Index: clang/include/c

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-05 Thread David Crook via Phabricator via cfe-commits
Vexthil added a comment. I have no idea what this error means or what to do about it i'm afraid but it does not look related to the changes I have made. I also do not have access to a Linux machine easily so reproducing it locally is not going to be easy. If anyone knows this error better and c

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-05 Thread David Crook via Phabricator via cfe-commits
Vexthil created this revision. Vexthil added a reviewer: rsmith. Vexthil added a project: clang. Vexthil requested review of this revision. Herald added a subscriber: cfe-commits. https://bugs.llvm.org/show_bug.cgi?id=40858 CheckShadow is now called for each binding in the structured binding to m