From f422094b9fcf634c0c839d0685f6347a82a1a6f9 Mon Sep 17 00:00:00 2001 From: Milo Yip Date: Tue, 2 Feb 2016 18:36:27 +0800 Subject: [PATCH] Fix the last warning fix --- include/rapidjson/fwd.h | 9 --------- test/unittest/fwdtest.cpp | 9 +++++++++ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/include/rapidjson/fwd.h b/include/rapidjson/fwd.h index eab45c7..9c0466c 100644 --- a/include/rapidjson/fwd.h +++ b/include/rapidjson/fwd.h @@ -17,11 +17,6 @@ #include "rapidjson.h" -#ifdef __GNUC__ -RAPIDJSON_DIAG_PUSH -RAPIDJSON_DIAG_OFF(effc++) -#endif - RAPIDJSON_NAMESPACE_BEGIN // encodings.h @@ -148,8 +143,4 @@ typedef GenericSchemaValidator, voi RAPIDJSON_NAMESPACE_END -#ifdef __GNUC__ -RAPIDJSON_DIAG_POP -#endif - #endif // RAPIDJSON_RAPIDJSONFWD_H_ diff --git a/test/unittest/fwdtest.cpp b/test/unittest/fwdtest.cpp index 279868d..5a3582b 100644 --- a/test/unittest/fwdtest.cpp +++ b/test/unittest/fwdtest.cpp @@ -14,6 +14,11 @@ #include "unittest.h" +#ifdef __GNUC__ +RAPIDJSON_DIAG_PUSH +RAPIDJSON_DIAG_OFF(effc++) +#endif + // Using forward declared types here. #include "rapidjson/fwd.h" @@ -206,3 +211,7 @@ Foo::~Foo() { TEST(Fwd, Fwd) { Foo f; } + +#ifdef __GNUC__ +RAPIDJSON_DIAG_POP +#endif