summaryrefslogtreecommitdiff
path: root/rapidjsonwrapper.h
diff options
context:
space:
mode:
Diffstat (limited to 'rapidjsonwrapper.h')
-rw-r--r--rapidjsonwrapper.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/rapidjsonwrapper.h b/rapidjsonwrapper.h
index cf3dd829..1ff02e7e 100644
--- a/rapidjsonwrapper.h
+++ b/rapidjsonwrapper.h
@@ -2,6 +2,12 @@
#include <exception>
#include <stdexcept>
+#if defined(__GNUC__) && __GNUC__ >= 8
+// Disable warnings from rapidjson performance optimizations
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wclass-memaccess"
+#endif
+
struct GenericException;
struct ParseException;
@@ -30,4 +36,6 @@ struct ParseException: public std::runtime_error, rapidjson::ParseResult
#include "rapidjson/rapidjson.h"
#include "rapidjson/document.h"
-
+#if defined(__GNUC__) && __GNUC__ >= 8
+#pragma GCC diagnostic pop
+#endif