Eliminating Left Recursion

SyntaxEditor for Windows Forms Forum

Posted 17 years ago by amit
Version: 4.0.0250

I have been searching for how to eliminate left recursion and have found loads of literature on the internet. This topic seems not so complicated to me as is presented in the literature. So I am confused about my implementation. Here is a prototype where i am eliminating the left recursion. Can someone plz tell me whether i am doing mistake or not.

(A and B represent Non-Terminals. a, b, and c represent Terminals.)

The resursive production rule is shown below.

B |
A a |
A b |
A c

And the corresponding non-recursive iterative rule that i understand is -

A: B { a | b | c }

Is something wrong with my understanding ? If someone throws some light on this topic, it will be of great help for me.


Comments (1)

Posted 17 years ago by Actipro Software Support - Cleveland, OH, USA
It looks like what you have is correct.

Actipro Software Support

The latest build of this product (v24.1.0) was released 4 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.