slackbuilds_ponce/libraries/rapidjson/fix-build-on-gcc7.diff
Robby Workman d8f337bb0a libraries/rapidjson: Fix build with gcc7
I ran into this trying to build rapidjson on ARM -current:
https://github.com/Tencent/rapidjson/pull/941

Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
2017-12-27 18:10:32 -06:00

13 lines
484 B
Diff

diff -Nur rapidjson-1.1.0.orig/include/rapidjson/internal/regex.h rapidjson-1.1.0/include/rapidjson/internal/regex.h
--- rapidjson-1.1.0.orig/include/rapidjson/internal/regex.h 2016-08-25 02:59:05.000000000 -0500
+++ rapidjson-1.1.0/include/rapidjson/internal/regex.h 2017-12-27 01:10:17.765316098 -0600
@@ -29,6 +29,9 @@
#ifdef __GNUC__
RAPIDJSON_DIAG_PUSH
RAPIDJSON_DIAG_OFF(effc++)
+#if __GNUC__ >= 7
+RAPIDJSON_DIAG_OFF(implicit-fallthrough)
+#endif
#endif
#ifdef _MSC_VER