Remove JSONReader::ValueWithError error_code field
There are two categories of base::ValueDeserializer error codes: content errors (e.g. invalid syntax) and context errors (e.g. file not found, network is down). Callers do care about distinguishing between those categories, but within the content category, callers don't care about e.g. distinguishing JSON_TRAILING_COMMA from JSON_UNQUOTED_DICTIONARY_KEY, except to show a human-readable error string, which is already available in the JSONReader::ValueWithError error_message field. The error_code field adds nothing interesting, and as per the commit message to https://crrev.com/c/2251561 "Move JSONParser-specific enums out of JSONReader", it has made it harder to experiment with different JSON implementations. This commit deletes it. Bug: 1069271 Bug: 1070409 Change-Id: If7b8a7ffd18e48a23b5e8071b4a83850ca3692a2 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2405336Reviewed-by:Robert Sesek <rsesek@chromium.org> Reviewed-by:
Eugene But <eugenebut@chromium.org> Commit-Queue: Nigel Tao <nigeltao@chromium.org> Cr-Commit-Position: refs/heads/master@{#806855}
Showing
Please register or sign in to comment