I was given the following grammar
$S \rightarrow S ( S ) S\mid \epsilon$
First I was asked to eliminate left recursion, yielding me the following :
$S \rightarrow S' $
$S' \rightarrow (S)SS' \mid \epsilon$
I was then asked If the grammar is LL(1). So I computed the FIRST and FOLLOW sets shown below:
$\mathrm{FIRST}(S) = \mathrm{FIRST}(S') = \{ ( , \epsilon \}$,
$\mathrm{FOLLOW}(S) = \mathrm{FOLLOW}(S') = \{ \$, ( , ) \}$.
I now tried building the LL(1) parsing table $M$ as follow:
Since we have production $S \rightarrow S' $ and $\mathrm{FIRST}(S') = \{ ( , \epsilon \}$, the table's entry $M [ S , ( ] = S \rightarrow S'$.
But since $\epsilon$ belongs in $\mathrm{FIRST}(S')$ then for each element $b$ in $\mathrm{FOLLOW}(S)$,
$M [ S , b ] = S \rightarrow S' $.
This would entail that $M [ S , ( ] = S \rightarrow S' $.
Since the entry was already populated, is this a conflict? If yes, what kind?
Or since the 2 productions are the same we can just ignore it?
Also if the second case is the right one, is the grammar LL(1)?