Commit 39933322 authored by thebusytypist's avatar thebusytypist

Use assertion for impossible case(The Predict() can ensure the token is…

Use assertion for impossible case(The Predict() can ensure the token is ColonToken, otherwise it would be marked as Error state. So there is no need to check ColonToken again).
parent 85767473
......@@ -1273,12 +1273,9 @@ private:
return dst;
case IterativeParsingKeyValueDelimiterState:
if (token == ColonToken) {
is.Take();
return dst;
}
else
return IterativeParsingErrorState;
RAPIDJSON_ASSERT(token == ColonToken);
is.Take();
return dst;
case IterativeParsingMemberValueState:
// Must be non-compound value. Or it would be ObjectInitial or ArrayInitial state.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment