From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA20133 for caml-redistribution; Thu, 15 Apr 1999 17:47:08 +0200 (MET DST) 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 SAA03115 for ; Wed, 14 Apr 1999 18:45:20 +0200 (MET DST) Received: from miss.wu-wien.ac.at (miss.wu-wien.ac.at [137.208.107.17]) by nez-perce.inria.fr (8.8.7/8.8.7) with ESMTP id SAA18490 for ; Wed, 14 Apr 1999 18:45:19 +0200 (MET DST) Received: (from mottl@localhost) by miss.wu-wien.ac.at (8.9.0/8.9.0) id SAA04614 for caml-list@inria.fr; Wed, 14 Apr 1999 18:45:18 +0200 (MET DST) From: Markus Mottl Message-Id: <199904141645.SAA04614@miss.wu-wien.ac.at> Subject: ocamlyacc error reporting To: caml-list@inria.fr (OCAML) Date: Wed, 14 Apr 1999 18:45:18 +0100 (MET DST) X-Mailer: ELM [version 2.4 PL21] MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: weis Hello, it would be great if "ocamlyacc" reported more errors on badly specified grammars. Some difficult to spot mistakes could then be resolved more easily. E.g.: main : SOME_TOKEN foo {} foo : main {} It is impossible to derive any sentence from this grammar - still, there is no error/warning. But also parts of a grammar can be underivable. This can be very difficult to see in large grammars. I have tried this example with "bison" and it can report such errors. This is not the case with "yacc", but since ocamlyacc is based on "yacc"-code, this is understandable... Best regards, Markus Mottl -- Markus Mottl, mottl@miss.wu-wien.ac.at, http://miss.wu-wien.ac.at/~mottl