AST in JSON format

Oliver Hunt oliver at apple.com
Mon Dec 7 16:07:26 PST 2009


<snip>

> OTOH, if we standardize an AST format, then presumably we'll be adding
> a source->AST API function that uses the implementation's existing parser.

I'd be worried about assuming that this is an obvious/trivial thing for implementations to do, you're effectively requiring that the internal AST representation of an implementation be entirely standardised.  For example it is not possible for JSC's parser to produce an AST that exactly matches the input code -- I would expect similar problems with other implementations.

--Oliver



More information about the es-discuss mailing list