[PATCH] D109862: Don't diagnose unused but set when the Cleanup attribute is used.

2021-09-22 Thread Michael Benfield via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGaf9923674787: Don't diagnose unused but set when the Cleanup attribute is used. (authored by mbenfield). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109862

[PATCH] D109862: Don't diagnose unused but set when the Cleanup attribute is used.

2021-09-17 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM, thank you! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109862/new/ https://reviews.llvm.org/D109862 _

[PATCH] D109862: Don't diagnose unused but set when the Cleanup attribute is used.

2021-09-16 Thread Michael Benfield via Phabricator via cfe-commits
mbenfield updated this revision to Diff 373069. mbenfield added a comment. Added a test case. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109862/new/ https://reviews.llvm.org/D109862 Files: clang/lib/Sema/SemaDecl.cpp clang/test/Sema/warn-un

[PATCH] D109862: Don't diagnose unused but set when the Cleanup attribute is used.

2021-09-16 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: aaron.ballman. aaron.ballman added a comment. I think this is reasonable, but it's missing test coverage. Can you add some tests to `clang/test/Sema` to demonstrate that we purposefully do not issue a diagnostic when the cleanup attribute is used? Repository:

[PATCH] D109862: Don't diagnose unused but set when the Cleanup attribute is used.

2021-09-15 Thread Michael Benfield via Phabricator via cfe-commits
mbenfield created this revision. mbenfield added a reviewer: dblaikie. mbenfield requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This applies to -Wunused-but-set-variable and -Wunused-but-set-parameter. This addresses bug 51865. Reposito