decimals without integer part in JSON source text (was: Re: JSON parser grammar)

Hallvord R. M. Steen hallvord at
Wed Aug 26 13:18:18 PDT 2009

On Tue, 25 Aug 2009 21:57:11 +0200, Mark S. Miller <erights at>  

> While the JSON spec itself allows parsers to accept strings outside the
> standard JSON grammar, the ES5 spec for the JSON object was carefully
> constructed to give us a validating parser: one that rejects non-JSON  
> text.

Well, I may have suggested a change in the wrong place but the intention  
was to make this legal in JSON text, not to break validation generally.

On Tue, 25 Aug 2009 22:09:54 +0200, Oliver Hunt <oliver at> wrote:

> The WebKit JSON parser does not allow this (You can test in Safari 4.0.3  
> or a nightly build)

Indeed. As you haven't seen any compat problems so far I'll withdraw the  
suggestion and make sure we (Opera) follows the spec as-is, hopefully the  
Gecko and IE teams will fix it too :)

Hallvord R. M. Steen, Core Tester, Opera Software

More information about the es-discuss mailing list