[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH 1 of 6] xen: Add -Wno-unused-value to the clang CFLAGS


  • To: xen-devel@xxxxxxxxxxxxx
  • From: Tim Deegan <tim@xxxxxxx>
  • Date: Thu, 5 Apr 2012 13:07:14 +0100
  • Delivery-date: Thu, 05 Apr 2012 12:11:14 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xen.org>

# HG changeset patch
# User Tim Deegan <tim@xxxxxxx>
# Date 1333626954 -3600
# Node ID 8518fb0c8c996dca67efd39d31962a6d3502c2ed
# Parent  d690c7e896a26c54a5ab85458824059de72d5cba
xen: Add -Wno-unused-value to the clang CFLAGS

clang complains about a lot of functions and macros whose return value
is unused.  I started on patches to drop some functions' return values
and scatter (void)s around callers, but it was getting too messy.
Just turn off the warning instead.

Signed-off-by: Tim Deegan <tim@xxxxxxx>

diff -r d690c7e896a2 -r 8518fb0c8c99 Config.mk
--- a/Config.mk Thu Apr 05 11:06:03 2012 +0100
+++ b/Config.mk Thu Apr 05 12:55:54 2012 +0100
@@ -159,7 +159,8 @@ CFLAGS += -Wall -Wstrict-prototypes
 
 # Clang complains about macros that expand to 'if ( ( foo == bar ) ) ...'
 # and is over-zealous with the printf format lint
-CFLAGS-$(clang) += -Wno-parentheses -Wno-format
+# and is a bit too fierce about unused return values
+CFLAGS-$(clang) += -Wno-parentheses -Wno-format -Wno-unused-value
 
 $(call cc-option-add,HOSTCFLAGS,HOSTCC,-Wdeclaration-after-statement)
 $(call cc-option-add,CFLAGS,CC,-Wdeclaration-after-statement)

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.