Browse thread
[Caml-list] Ocamlyacc vs stream parser
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | brogoff@s... |
| Subject: | Re: [Caml-list] Ocamlyacc vs stream parser |
On Wed, 28 May 2003, Michal Moskal wrote: > On Wed, May 28, 2003 at 11:37:03AM +0200, Diego Olivier Fernandez Pons wrote: > > Bonjour, > > > > > Sorry, I thought camlp4 recognizes LL(1) languages, and my dragon book > > > copy states that LR(1) > LL(1) (I'm not sure about LARL(1) though). > > > > My Appel states that LL(1) is not included in LALR(1). > > Oh, so by proof-by-book you're right :-) That's pretty funny, but those Romans did have this case covered. I believe the Latin expression is "argumentum ad verecundiam". > But in practice LARL(1) seems > more usefull for parsing, at parsing least programming languages. This is esoteric flame bait for the parsing crowd. I happen to think that recursive descent is the best way to write parsers, but note that recursive descent parsers are capable of parsing non-LL(1) grammars, even without the fairly obvious hacks. As a real world proof by example, consider that Ada is often cited as a language not amenable to RDP (Fraser&Hanson : "For example, C is in the class of languages that can be recognized by recursive descent parsers, but other languages, like ADA (sic), are not."), yet somehow the authors of GNAT were ignorant enough to make it work. In the real world, you'll need to be proficient with YACC and RDP, of course. -- Brian ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners