Skip to content

Assignment to constant values should trigger error #78

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
ichiriac opened this issue Jul 14, 2017 · 1 comment
Closed

Assignment to constant values should trigger error #78

ichiriac opened this issue Jul 14, 2017 · 1 comment
Assignees

Comments

@ichiriac
Copy link
Member

Related to : https://gitlab.com/kornelski/babel-preset-php/issues/4

<?php
// this should not be valid
a = 1;

Caused by a fallback trap :
https://github.com/glayzzle/php-parser/blob/master/src/parser/statement.js#L330

There is no such fallback in PHP :
https://github.com/php/php-src/blob/master/Zend/zend_language_parser.y#L457

@ichiriac ichiriac self-assigned this Jul 14, 2017
ichiriac added a commit that referenced this issue Jul 15, 2017
ichiriac added a commit that referenced this issue Jul 15, 2017
@ichiriac
Copy link
Member Author

fixed

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

1 participant