Skip to content

Commit 962f827

Browse files
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

+1730
-464
lines changed

composer.json

+4-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@
1111
],
1212
"require": {
1313
"php": "^7.4 || ^8.0",
14-
"phpdocumentor/reflection-common": "^2.0"
14+
"phpdocumentor/reflection-common": "^2.0",
15+
"phpstan/phpdoc-parser": "^1.13"
1516
},
1617
"require-dev": {
1718
"ext-tokenizer": "*",
@@ -20,7 +21,8 @@
2021
"phpstan/phpstan-phpunit": "^1.1",
2122
"phpstan/extension-installer": "^1.1",
2223
"vimeo/psalm": "^4.25",
23-
"rector/rector": "^0.13.9"
24+
"rector/rector": "^0.13.9",
25+
"phpbench/phpbench": "^1.2"
2426
},
2527
"autoload": {
2628
"psr-4": {

0 commit comments

Comments
 (0)