Skip to content

Eval ignores closing tag #127

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
thiagorb opened this issue Mar 6, 2018 · 1 comment
Closed

Eval ignores closing tag #127

thiagorb opened this issue Mar 6, 2018 · 1 comment
Assignees

Comments

@thiagorb
Copy link

thiagorb commented Mar 6, 2018

Input:

echo "hello"; ?> world

Running the code above in PHP's eval would result in:

php > eval('echo "hello"; ?> world');
    hello world

But the parser is failing with syntax error.

I also noticed that the following code will not result in error, and generates an AST with no children, while it should contain '?>?>' as inline:

parser.parseEval(`?>?>?>`)
@ichiriac ichiriac self-assigned this Mar 6, 2018
ichiriac added a commit that referenced this issue Mar 6, 2018
@ichiriac
Copy link
Member

ichiriac commented Mar 6, 2018

Hi @thiagorb,

Thanks for the report, it's fixed now and will be released on v3.0.0 soon

@ichiriac ichiriac closed this as completed Mar 6, 2018
@ichiriac ichiriac added this to the 3.0.0 milestone Mar 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants