Ref T11933. This lets PhutilTypeLexer support qualified names.
Details
Details
- Reviewers
joshuaspence epriestley - Group Reviewers
Blessed Reviewers - Maniphest Tasks
- T11933: Let `PhutilTypeLexer` support PHP style qualified names
- Commits
- rPHUde65ac554ca3: Let PhutilTypeLexer support qualified names
- Required Signatures
L28 Phacility Individual Contributor License Agreement
Unit test
Diff Detail
Diff Detail
- Repository
- rPHU libphutil
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
Comment Actions
This change is fine, but I think the new expression is too permissive. Let's add these "good" test cases:
\SomeClass \Namespace\SomeClass A\B\C \A\B\C
And these "bad" test cases:
\ \\ \SomeClass\ SomeClass\
I think some of those won't pass; adjust the regular expression until they do.
(I think all those bad cases are actually illegal, but I haven't used namespaces in PHP very much so my understanding of the syntax may be incorrect.)