From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=AWL autolearn=disabled version=3.1.3 Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id E1F60BC0A for ; Sat, 13 Jan 2007 23:59:26 +0100 (CET) Received: from ipmail02.adl2.internode.on.net (ipmail02.adl2.internode.on.net [203.16.214.141]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l0DMxOaU024767 for ; Sat, 13 Jan 2007 23:59:25 +0100 Received: from ppp14-213.lns2.syd7.internode.on.net (HELO rosella) ([59.167.14.213]) by ipmail02.adl2.internode.on.net with ESMTP; 14 Jan 2007 09:29:22 +1030 X-IronPort-AV: i="4.13,184,1167571800"; d="scan'208"; a="71088387:sNHT27582520" Subject: ocamlyacc: named attributes From: skaller To: caml-list@inria.fr Content-Type: text/plain Date: Sun, 14 Jan 2007 09:59:17 +1100 Message-Id: <1168729157.26042.7.camel@rosella.wigram> Mime-Version: 1.0 X-Mailer: Evolution 2.6.1 Content-Transfer-Encoding: 7bit X-Miltered: at discorde with ID 45A9644C.001 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; ocamlyacc:01 ocamlyacc:01 non-terminal:01 sourceforge:01 grammar:01 simplest:02 inconvenient:08 attributes:08 attributes:08 john:09 felix:09 felix:09 instead:14 instead:14 used:16 What is involved in changing Ocamlyacc to allow names instead of numbers? Use of numbered attributes is inconvenient when refactoring a grammar. The simplest use would be: fred: one two { $one, $two } where the name of a non-terminal can be used instead of its index, provided it is unique. -- John Skaller Felix, successor to C++: http://felix.sf.net