On 4/25/13 9:12 AM, Graydon Hoare wrote:
Longer term, I would like whatever grammar we wind up denoting as canonical / documented / spec'ed to be as (re)target-able as possible. I've been relatively insistent on LL(1) since it is a nice intersection-of-inputs, practically guaranteed to parse under any framework we retarget it to. IOW I do _not_ want to force anyone working with rust grammars in the future to use antlr (3, 4, or anything else). That's too tool-specific[2]. A grammar that is trivally translatable between antlr4, antlr3, yapp2, llgen, llnextgen, coco, javacc, parsec, spirit, "some rust parser-generator", and so forth is my "eventual" goal here.
Are you concerned about the left-factoring needed to make the LL(1) grammar work? To me that's the biggest issue: the resulting grammar is kind of messy, and a tool that uses the LL(1) grammar is going to have a fun time reconstructing the first argument to method signatures (for example)...
Patrick _______________________________________________ Rust-dev mailing list [email protected] https://mail.mozilla.org/listinfo/rust-dev
