[PATCH] D100581: [Clang] -Wunused-but-set-parameter and -Wunused-but-set-variable

Arthur Eubanks via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Apr 15 11:44:11 PDT 2021


aeubanks added a comment.

the description should be clearer about what these warnings do

running this over an existing codebase to see what fires is probably a good idea (if you haven't already done that)



================
Comment at: clang/test/Sema/vector-gcc-compat.c:38
   v2i64 v2i64_a = (v2i64){0, 1};
-  v2i64 v2i64_r;
+  v2i64 v2i64_r; // expected-warning{{variable 'v2i64_r' set but not used}}
 
----------------
this file isn't really testing this, I think this test should disable these warnings. I believe other tests do similar things, but it might be good grep around `clang/test` for `'Wno'` just to make sure


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D100581/new/

https://reviews.llvm.org/D100581



More information about the cfe-commits mailing list