antecedent/patchwork

Handle new token types and PHP parser enhancements

antecedent opened this issue · 1 comments

This entails, first and foremost, dealing with the T_NAME_* trio of PHP 8:

  • T_NAME_FULLY_QUALIFIED,
  • T_NAME_QUALIFIED,
  • T_NAME_RELATIVE.

The preceding is a priority, because there are places where Patchwork scans relative names and resolves them into qualified names. And as of v2.1.12, it still assumes that the names are made of T_STRING and T_NS_SEPARATOR only.

After that, there are attributes, and there is fn, and perhaps there is something else that I cannot recall for the time being. Some new test cases are due to verify that neither of these tokens will interfere with Patchwork's parser.

Also, somewhat tangentially, we should make sure that Patchwork plays nice with the syntax enhancements that came PHP 7. Some precedences changed; some new compositions of preexisting syntactic constructs became possible.

The T_NAME_* part is now fixed. Not closing since this issue originally subsumes extending the test suite too.