https://bugs.llvm.org/show_bug.cgi?id=39088
Nick Desaulniers <ndesaulni...@google.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|INVALID |---
CC| |richard-l...@metafoo.co.uk
--- Comment #2 from Nick Desaulniers <ndesaulni...@google.com> ---
Reopening, there are simply too many drivers in the Linux kernel that trigger
this warning.
Ideas:
* make it so that attribute alias marks the referenced variable as used
(assuming the referenced one still gets cleaned up; we care about the alias,
not the original) or referenced.
* make it so that -Wunneeded-internal-declaration has a pedantic ExtWarn
version for this case? (eh, this doesn't sound as good on paper)
* ???
When in a local function, we could do something like `(void) foo;` to silence
these unused var warnings. Can't do that trick for globally defined variables,
but maybe there's something similar we can do.
The alias is created in a macro that's used pervasively, so adding something to
the macro is more feasible than adding __attribute__((unused)) to every macro
expansion site in the kernel.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs