From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA19451; Fri, 13 Aug 2004 17:52:08 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id RAA17623 for ; Fri, 13 Aug 2004 17:52:07 +0200 (MET DST) Received: from petasus.isw.intel.com (petasus.isw.intel.com [192.55.37.196]) by nez-perce.inria.fr (8.12.10/8.12.10) with ESMTP id i7DFq6mL031734 for ; Fri, 13 Aug 2004 17:52:06 +0200 Received: from swsmsxvs01.isw.intel.com (swsmsxvs01.isw.intel.com [172.28.130.22]) by petasus.isw.intel.com (8.12.9-20030918-01/8.12.9/d: small-solo.mc,v 1.9 2004/01/09 01:01:53 root Exp $) with SMTP id i7DFq4NZ004771; Fri, 13 Aug 2004 15:52:07 GMT Received: from swsmsx331.ger.corp.intel.com ([172.28.130.50]) by swsmsxvs01.isw.intel.com (SAVSMTP 3.1.2.35) with SMTP id M2004081316520515336 ; Fri, 13 Aug 2004 16:52:05 +0100 Received: from swsmsx402.ger.corp.intel.com ([172.28.130.26]) by swsmsx331.ger.corp.intel.com with Microsoft SMTPSVC(5.0.2195.6713); Fri, 13 Aug 2004 16:52:05 +0100 X-MimeOLE: Produced By Microsoft Exchange V6.0.6487.1 content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: [Caml-list] CFG Parsers Date: Fri, 13 Aug 2004 16:52:04 +0100 Message-ID: <78B55F0E8771CC4B8F6995AB83AF65520514D668@swsmsx402.ger.corp.intel.com> Thread-Topic: [Caml-list] CFG Parsers Thread-Index: AcSBTE1g3B7xqbLkSa6VP7qBRvQKtQAAErKA From: "Ennals, Robert" To: "David McClain" , "caml" X-OriginalArrivalTime: 13 Aug 2004 15:52:05.0104 (UTC) FILETIME=[7B1ADF00:01C4814D] X-Miltered: at nez-perce with ID 411CE3A6.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 combinator:01 haskell:01 combinator:01 owner-caml-:01 mcclain:01 2004:99 caml-list:01 criticism:01 plea:01 mismatch:01 blind:99 spears:99 mcclain:01 bug:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk Have you tried using a combinatory parser? Such parsers are usually *MUCH* easier to use, allow much wider choices of grammar, much better error messages etc, and are usually more than fast enough. I don't know what combinator parsers are available for O'Caml, but Parsec (for Haskell) is pretty sweet.=20 Does anyone know of any good combinator parsing libraries for O'Caml? If there aren't any then I might be tempted to do one myself (getting sick of yacc). -Rob > -----Original Message----- > From: owner-caml-list@pauillac.inria.fr [mailto:owner-caml- > list@pauillac.inria.fr] On Behalf Of David McClain > Sent: 13 August 2004 16:42 > To: caml > Subject: [Caml-list] CFG Parsers >=20 > With all due respect, it appears that I need to reframe my thinking about > these YACC parser builders and go backward in time by about 30-40 years. > Now > that I'm getting the hang of what it is doing, it looks strongly > reminiscent > of the style of programming we did back on old IBM 360's. >=20 > I do notice that YACC becomes very sensitive to slight perturbations in > the > grammar. This is not meant as a criticism of YACC, but rather a plea for > some more modern thinking in compiler generators. Perhaps the GLC tool > will > do better here. >=20 > The problem seems to be the impedance mismatch between the way humans are > led to think when viewing the "structured" YACC input clauses, and the > more > or less blind way the computer is actually using that information. I see > that being a master of removing reduce/reduce conflicts seems to be a rite > of passage. But surely there has to be a better way to approach these > kinds > of problems. Just because my ancestors used to hunt with spears doesn't > mean > I still ought to do so. >=20 > David McClain > Senior Corporate Scientist > Avisere, Inc. >=20 > +1.520.390.7738 (USA) > david.mcclain@avisere.com >=20 >=20 >=20 > ------------------- > 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 ------------------- 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