[PATCH] D25937: [Sema] -Wunused-variable warning for variables with array types should behave similarly to variables with scalar types

John McCall via cfe-commits cfe-commits at lists.llvm.org
Tue Oct 25 09:33:13 PDT 2016


rjmccall requested changes to this revision.
rjmccall added a comment.
This revision now requires changes to proceed.

There's no reason for this to only consider constant-sized arrays, and you should use getBaseElementTypeUnsafe() so you look through nested array types.  That method is a no-op on non-array types, so you can just call it unconditionally here.


Repository:
  rL LLVM

https://reviews.llvm.org/D25937





More information about the cfe-commits mailing list