summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKWSys Robot <kwrobot@kitware.com>2014-12-18 13:31:15 (GMT)
committerBrad King <brad.king@kitware.com>2014-12-18 15:17:16 (GMT)
commit1f7de54346142f05aef5814ee16754fba017b521 (patch)
tree9719ff6b88ea45ebabafb5b247adb931851d88e0
parent6a5ab894fbb1683ed24bfa5d603eff6ff3f40039 (diff)
downloadCMake-1f7de54346142f05aef5814ee16754fba017b521.zip
CMake-1f7de54346142f05aef5814ee16754fba017b521.tar.gz
CMake-1f7de54346142f05aef5814ee16754fba017b521.tar.bz2
KWSys 2014-12-18 (87c65319)
Extract upstream KWSys using the following shell commands. $ git archive --prefix=upstream-kwsys/ 87c65319 | tar x $ git shortlog --no-merges --abbrev=8 --format='%h %s' cc4046a8..87c65319 Sean McBride (1): 87c65319 SharedForward: Suppress clang -Wcast-qual warnings with conditional pragma Change-Id: I2f79780385aca7e0caa24e5bb0c0b4106b786c37
-rw-r--r--SharedForward.h.in16
1 files changed, 16 insertions, 0 deletions
diff --git a/SharedForward.h.in b/SharedForward.h.in
index c6f345f..f22fa58 100644
--- a/SharedForward.h.in
+++ b/SharedForward.h.in
@@ -65,6 +65,15 @@
See the comments below for specific explanations of each macro.
*/
+/* Disable -Wcast-qual warnings since they are too hard to fix in a
+ cross-platform way. */
+#if defined(__clang__) && defined(__has_warning)
+# if __has_warning("-Wcast-qual")
+# pragma clang diagnostic push
+# pragma clang diagnostic ignored "-Wcast-qual"
+# endif
+#endif
+
/*--------------------------------------------------------------------------*/
/* Full path to the directory in which this executable is built. Do
@@ -917,6 +926,13 @@ static int @KWSYS_NAMESPACE@_shared_forward_to_real(int argc, char** argv_in)
return 1;
}
+/* Restore warning stack. */
+#if defined(__clang__) && defined(__has_warning)
+# if __has_warning("-Wcast-qual")
+# pragma clang diagnostic pop
+# endif
+#endif
+
#else
# error "@KWSYS_NAMESPACE@/SharedForward.h should be included only once."
#endif