JStify progress update

November 19, 2007 § 2 Comments

The development of JStify has been somewhat chaotic but the situation seems to be improving.

It took me a few weeks to adapt the SML/NJ-based parser of the Reference Implementation to OCaml and a few days to realize that it would quickly prove too hard to customize and maintain. It then took me another two weeks to convince myself that the specifications of JavaScript 2 were basically incompatible with Yacc, Menhir or Dypgen, due to a number of factors and to dump again all that code. After another two weeks, the recursive descent parser looks close to completion. I have managed to implement all the nasty tricks in the official grammar of JavaScript 2, despite the inconsistencies between Release 0 and Release 0 and within each release, between the .txt file, the .xls document and the actual implementation.

I’m currently debugging it and trying to understand why it keeps attempting to parse after the end of the file.

Camlp4 has proved slightly less useful than expected for this task, as I’ve managed to do everything I needed with a few regexps, higher order functions and the lazy module. On the other hand, the ability to combine OCaml stream parsers and build stream parser operators is quite comfortable.

In the meantime, I’ve also learnt how to write plug-ins for ocamlbuild and I’ve dumped the Makefile-based system for something more modern.

For the moment, I believe I can hold my personal deadline of end-of-November for the first full prototype of the parser.


§ 2 Responses to JStify progress update

  • fridojet says:

    Is the source code of JStify avaible anywhere? I’m playing around with statical analysis of JavaScript programs for a while and so I’m interested in your project.

    • yoric says:

      Unfortunately, the project was cancelled just a few weeks after having started, and I was asked to work on static analysis of C instead.

      On the other hand, if you have something to show, I am interested 🙂

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

What’s this?

You are currently reading JStify progress update at Il y a du thé renversé au bord de la table.


%d bloggers like this: