[polly] r249472 - Fix configure checks when applied by the latest clang

David Blaikie via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 6 14:45:06 PDT 2015


Author: dblaikie
Date: Tue Oct  6 16:45:06 2015
New Revision: 249472

URL: http://llvm.org/viewvc/llvm-project?rev=249472&view=rev
Log:
Fix configure checks when applied by the latest clang

Clang's been taught to warn on more things here (unused values when
calling pure functions and ignoring their result, for example).

It might be better to figure out how to have cmake compile these tests
without -Werror/without any warnings enabled. But this'll do for now & I
don't know enough about cmake to fix it any other way, or to understand
the tradeoffs in that space.

Modified:
    polly/trunk/lib/External/CMakeLists.txt

Modified: polly/trunk/lib/External/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/External/CMakeLists.txt?rev=249472&r1=249471&r2=249472&view=diff
==============================================================================
--- polly/trunk/lib/External/CMakeLists.txt (original)
+++ polly/trunk/lib/External/CMakeLists.txt Tue Oct  6 16:45:06 2015
@@ -72,7 +72,7 @@ check_c_source_compiles("
 
 check_c_source_compiles_numeric("
   #include <strings.h>
-  int main() { ffs(0); return 0; }
+  int main() { (void)ffs(0); return 0; }
   " HAVE_DECL_FFS)
 
 check_c_source_compiles_numeric("
@@ -93,7 +93,7 @@ endif ()
 
 check_c_source_compiles_numeric("
   #include <strings.h>
-  int main() { strcasecmp(\"\", \"\"); return 0; }
+  int main() { (void)strcasecmp(\"\", \"\"); return 0; }
   " HAVE_DECL_STRCASECMP)
 
 check_c_source_compiles_numeric("
@@ -108,7 +108,7 @@ endif ()
 
 check_c_source_compiles_numeric("
   #include <strings.h>
-  int main() { strncasecmp(\"\", \"\", 0); return 0; }
+  int main() { (void)strncasecmp(\"\", \"\", 0); return 0; }
   " HAVE_DECL_STRNCASECMP)
 
 check_c_source_compiles_numeric("




More information about the llvm-commits mailing list