Re: [Json] Consensus on JSON-text (WAS: JSON: remove gap between Ecma-404 and IETF draft)

On 28 Nov 2013, at 08:44, Joe Hildebrand (jhildebr) <jhildebr@cisco.com> wrote:

>> JSON-text  = value
> 
> We also need to make an explicit decision about whitespace-tolerance.

If the point is to track the changes made by ECMA-404 that decision has been made for us (see end of section 4 in 404).
(Note also that JSON is whitespace-tolerant today, so not having that for the new non-containers at top-levels but everywhere else would be rather surprising.*)

Minimal change appears to be:

JSON-text = ws value ws

Grüße, Carsten

*) The other interesting practical usage here is removing newlines from the allowed whitespace for a single JSON-text and joining sequences of these by newlines to form streams of JSON values.
But that is outside the scope of application/json and application/__+json, an instance of which is exactly one JSON-text.
(truenull3true is a valid stream of JSON texts if you don’t require adding whitespace as delimiters.
Implementations that employ a typical form of tokenization without knowing what those tokens can be in JSON won’t like that.  In any case, whitespace is needed to separate numbers.)

Received on Thursday, 28 November 2013 08:41:47 UTC