| 1086 | } |
| 1087 | |
| 1088 | bool Reader::pushError(const Value& value, const JSONCPP_STRING& message) { |
| 1089 | ptrdiff_t const length = end_ - begin_; |
| 1090 | if (value.getOffsetStart() > length || value.getOffsetLimit() > length) |
| 1091 | return false; |
| 1092 | Token token; |
| 1093 | token.type_ = tokenError; |
| 1094 | token.start_ = begin_ + value.getOffsetStart(); |
| 1095 | token.end_ = end_ + value.getOffsetLimit(); |
| 1096 | ErrorInfo info; |
| 1097 | info.token_ = token; |
| 1098 | info.message_ = message; |
| 1099 | info.extra_ = 0; |
| 1100 | errors_.push_back(info); |
| 1101 | return true; |
| 1102 | } |
| 1103 | |
| 1104 | bool Reader::pushError(const Value& value, |
| 1105 | const JSONCPP_STRING& message, |
nothing calls this directly
no test coverage detected