Path: csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!nx01.iad01.newshosting.com!newshosting.com!198.186.194.249.MISMATCH!transit3.readnews.com!news-out.readnews.com!news-xxxfer.readnews.com!news.misty.com!news.iecc.com!nerds-end From: Gene Newsgroups: comp.compilers Subject: Re: How detect cycle in grammar ? Date: Sun, 27 Nov 2011 10:18:56 -0800 (PST) Organization: Compilers Central Lines: 14 Sender: news@iecc.com Approved: comp.compilers@iecc.com Message-ID: <11-11-056@comp.compilers> References: <11-11-041@comp.compilers> <11-11-045@comp.compilers> <11-11-046@comp.compilers> NNTP-Posting-Host: news.iecc.com X-Trace: leila.iecc.com 1322426252 91585 64.57.183.58 (27 Nov 2011 20:37:32 GMT) X-Complaints-To: abuse@iecc.com NNTP-Posting-Date: Sun, 27 Nov 2011 20:37:32 +0000 (UTC) Keywords: parse, theory Posted-Date: 27 Nov 2011 15:37:32 EST X-submission-address: compilers@iecc.com X-moderator-address: compilers-request@iecc.com X-FAQ-and-archives: http://compilers.iecc.com Xref: x330-a1.tempe.blueboxinc.net comp.compilers:358 On Nov 22, 10:20 am, an...@mips.complang.tuwien.ac.at (Anton Ertl) wrote: > Gene writes: > >Nonterminals that can never derive a terminal string are the > >problem. > > Is it really? Since they cannot derive a terminal, they have no > influence on the language described by the grammar. They might just > as well not be there. Are they really a problem (except for certain > implementation techniques)? The algorithm is commonly used to print warnings in parser generators. Check recent releases of bison, for example.