Skip to content
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

PHP8: Adds support for throw expressions #76

Merged
merged 1 commit into from
May 1, 2021

Conversation

cfroystad
Copy link
Collaborator

RFC

Changes the throw statement into a throw expression in accordance with PHP 8. The change has been tested with all edge cases kindfully listed by the RFC author.

According to the RFC and the test suite, the change does not break backwards compatability.

Notable changes:

  • Renamed throw_statement to throw_expression
  • Changed throw_expression behaviour to mach expression behaviour

Checklist

  • All tests pass in CI.
  • There are sufficient tests for the new fix/feature (see tests in expressions.txt)
  • Grammar rules have not been renamed unless absolutely necessary (1 rules renamed)
  • The conflicts section hasn't grown too much (0 new conflicts)
  • The parser size hasn't grown too much (master: 1664 , PR: 1666)

@cfroystad cfroystad mentioned this pull request May 1, 2021
32 tasks
@maxbrunsfeld maxbrunsfeld merged commit e43534e into tree-sitter:master May 1, 2021
@maxbrunsfeld
Copy link
Contributor

Very nice work ⚡

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.

2 participants