From: Ryan Davis Date: 2005-10-30T19:39:27+09:00 Subject: Re: PARSER for RUBY On Oct 29, 2005, at 12:47 AM, puellula@gmail.com wrote: > Mr. Matsumoto, > can you help me? I need a Ruby Grammar without Left Recursion. I have > find Ruby Grammar, but when I try to cancel left recursion, antlr > don't > like this. ANTLR is a good parser generator or is better another > parser > generator? Below are the notes I wrote up while doing an LR to LL flip on an ST80 grammar. ST80 is much cleaner than ruby in terms of how many grammar rules there are in the language so it was easier to get my head around when I was doing the work. I tried to do an LR to LL flip on ruby a couple years back and I failed at it. Your professor is a sadist as far as I'm concerned. I hope these notes help: http://www.zenspider.com/Languages/PCCTS/LR2LL.html -- ryand-ruby@zenspider.com - Seattle.rb - http://www.zenspider.com/ seattle.rb http://blog.zenspider.com/ - http://rubyforge.org/projects/ruby2c