Date: Wed, 16 Jan 2008 14:39:26 +0000 From: Bob Bishop <rb@gid.co.uk> To: Ulf Lilleengen <lulf@stud.ntnu.no> Cc: freebsd-hackers@freebsd.org Subject: Re: Csup cvsmode build discussion Message-ID: <D95047BD-C463-45CF-8588-B6E463FE32B7@gid.co.uk> In-Reply-To: <20080116133214.GA2666@carrot.studby.ntnu.no> References: <20080116093302.GA13632@carrot.studby.ntnu.no> <0CE4984F-41F7-44EA-9FE7-0E573DB2B338@gid.co.uk> <20080116133214.GA2666@carrot.studby.ntnu.no>
next in thread | previous in thread | raw e-mail | index | archive | help
Hi, On 16 Jan 2008, at 13:32, Ulf Lilleengen wrote: > On Wed, Jan 16, 2008 at 11:08:20AM +0000, Bob Bishop wrote: >> [...] >> Why do you want prefixing? And precisely what do you want to do with >> parameters? >> > Prefixing is needed since csup already have a configuration parser > written in > lex/yacc and therefore needed to avoid conflicts. You can alternatively avoid conflicts by putting both grammars in the same file, with an entry rule which refers to one or other of the two grammars' real entries based on a defined token. You then arrange for the lexer to supply the appropriate value of the switch token each time the parser is started up. > Parameters is nice if one > were to modify the parser to take extra arguments, I don't have a > concrete > example for it yet, but it's nonetheless a requirement for > reentrancy. [etc] You may be able to do this using a variation on the above trick. > -- > Ulf Lilleengen > -- Bob Bishop +44 (0)118 940 1243 rb@gid.co.uk fax +44 (0)118 940 1295
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?D95047BD-C463-45CF-8588-B6E463FE32B7>