[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Integration of lalr-scm
From: |
Ludovic Courtès |
Subject: |
Integration of lalr-scm |
Date: |
Tue, 30 Mar 2010 01:24:16 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) |
Hello,
The ‘wip-lalr’ branch aims to integrate Boucher’s lalr-scm
<http://code.google.com/p/lalr-scm/> as a documented Guile module named
(system base lalr).
I’ve (apparently) been able to adapt the ECMAScript lexer and parser to
the new API without too much work. The main API differences compared to
the old version found as (text parse-lalr) in Guile-Lib are:
- There are now first-class ‘lexical-token’ objects (records), so
lexers are required to use ‘make-lexical-token’ instead of ‘cons’,
which improves clarity.
- There are also first-class ‘source-location’ objects, whereas there
wasn’t anything like that before.
- Generated parsers are stateful, so one must instantiate a new one
whenever parsing anew.
Unless someone objects, I’ll merge it one of these days.
Thanks,
Ludo’.
- Integration of lalr-scm,
Ludovic Courtès <=