Commit 962f827
committed
Full rewrite of type resolving
Types are no longer parsed by this library. We do now use the phpstan
parser to parse types. Having support for more advanced type definitions
without the burden to support all parser logic.
In this commit I do introduce support for:
- array shapes
- constant expressions like integers, strings and floats
- constant expressions for enums and class constants
- Callable support with and without params and return types.
A new set of unittests have been added to ensure everything keeps working as
expected.1 parent 9066199 commit 962f827
17 files changed
Lines changed: 1730 additions & 464 deletions
File tree
- src
- PseudoTypes
- Types
- tests/unit
- Types
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
| 14 | + | |
| 15 | + | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| |||
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
23 | | - | |
| 24 | + | |
| 25 | + | |
24 | 26 | | |
25 | 27 | | |
26 | 28 | | |
| |||
0 commit comments