AST in JSON format

Oliver Hunt oliver at
Mon Dec 7 15:29:41 PST 2009

On Dec 7, 2009, at 3:21 PM, ihab.awad at wrote:

> On Mon, Dec 7, 2009 at 3:10 PM, David-Sarah Hopwood
> <david-sarah at> wrote:
>> ... programmers of AST-processing applications will see this
>> serialization when debugging, and it is likely to appear in test
>> cases for such applications and for parsers/emitters.
> Also: would a JsonML representation be *quicker* to execute than the
> original human readable JS source? If so, it could be useful as a wire
> format for the code of mobile objects.

I doubt it -- the format would be larger and therefore have more ota time and more content to parse than plain JS content.  The AST would be untrusted content so would still need to be validated (as the normal parser does implicitly).

> Furthermore, this format could be a good target for *generated* code.

I'm not sure what you mean here...


More information about the es-discuss mailing list