From cb017cbf5e4ad79a3e48419269c2739127984c4f Mon Sep 17 00:00:00 2001 From: Adam Majer Date: Fri, 30 Sep 2016 17:10:04 +0200 Subject: [PATCH] Fix compilation with older GCC versions Older GCC versions fail compiling RapidJSON due to a warning include/rapidjson/reader.h:578: error: suggest a space before ';' or explicit braces around empty body in 'while' statement : warnings being treated as errors --- include/rapidjson/reader.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/rapidjson/reader.h b/include/rapidjson/reader.h index 19f8849b1..e53bbd2c9 100644 --- a/include/rapidjson/reader.h +++ b/include/rapidjson/reader.h @@ -575,7 +575,7 @@ class GenericReader { } } else if (RAPIDJSON_LIKELY(Consume(is, '/'))) - while (is.Peek() != '\0' && is.Take() != '\n'); + while (is.Peek() != '\0' && is.Take() != '\n') {} else RAPIDJSON_PARSE_ERROR(kParseErrorUnspecificSyntaxError, is.Tell());