Hi Anand,

Bison expects its input to come from a lexer, i.e. all inputs are valid
tokens of the language Bison parses. If a token cannot be "matched", the
input is invalid.

If you want to be able to skip any input that is not a valid token, you
have to skip it in the lexer.

Yours
Alex

On 27.04.2018 15:15, Anand Akhare wrote:
> in following code, bison matches for word1 and word2 for input
> but it doesn't bypass word3 while it matches, executes action and throws
> error.
> Is it possible that anything that doesn't reach till input can be blocked?
> 
> 
> input:  word1
>          | word2
> 
> word1 : WORD1
> 
> word2: WORD2
> 
> word3: WORD3
> 
> Thank a lot!
> Anand
> _______________________________________________
> [email protected] https://lists.gnu.org/mailman/listinfo/help-bison
> 

_______________________________________________
[email protected] https://lists.gnu.org/mailman/listinfo/help-bison

Reply via email to