Skip to content

Conversation

@dgadmin
Copy link

@dgadmin dgadmin commented Aug 14, 2017

Hello!

Single quotes in a literal would cause the PEG to crash with:

PHP Parse error:  syntax error, unexpected '';' (T_ENCAPSED_AND_WHITESPACE), expecting ';'

This happens because the literal gets eval()ed to check if it's a single character.

This patch escapes the quotes, and the parser gets generated correctly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant