aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2009-04-20 01:56:54 +0000
committerEli Friedman <eli.friedman@gmail.com>2009-04-20 01:56:54 +0000
commit0272b56daef094f74613c7838f48de8ebd1c6e79 (patch)
tree543ccdc380a1d9587b794ab85289b5867b23a5cd
parent60952f94cf67ddb566600434857cad7a48264c3b (diff)
Hook up -Wunused-value to the unused expression warning. This is
useful for macro-heavy codebases that tend to trigger this warning a lot. Note that a make clean is required to get the option working; the dependencies for DiagnosticGroups.inc appear to be broken. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69564 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--include/clang/Basic/DiagnosticSemaKinds.td3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/clang/Basic/DiagnosticSemaKinds.td b/include/clang/Basic/DiagnosticSemaKinds.td
index b2f14633bf..09624cfca7 100644
--- a/include/clang/Basic/DiagnosticSemaKinds.td
+++ b/include/clang/Basic/DiagnosticSemaKinds.td
@@ -1289,7 +1289,8 @@ def err_typecheck_choose_expr_requires_constant : Error<
"'__builtin_choose_expr' requires a constant expression">;
def ext_typecheck_expression_not_constant_but_accepted : Extension<
"expression is not a constant, but is accepted as one by GNU extensions">;
-def warn_unused_expr : Warning<"expression result unused">;
+def warn_unused_expr : Warning<"expression result unused">,
+ InGroup<UnusedValue>;
// inline asm.
def err_asm_wide_character : Error<"wide string is invalid in 'asm'">;