schmittjoh / serializer

Library for (de-)serializing data of any complexity (supports JSON, and XML)
http://jmsyst.com/libs/serializer
MIT License
2.32k stars 587 forks source link

Make doblock type resolver compatibile with newest phpdoc #1455

Closed dgafka closed 1 year ago

dgafka commented 1 year ago

This fixes compatibility with newest version of phpstan/phpdoc-parser: Screenshot from 2023-01-06 18-36-21

Q A
Bug fix? yes
New feature? no
Doc updated no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets
License MIT
dgafka commented 1 year ago

@goetas this fixes 3.19.0 in case someone uses phpstan array type with phpstan/phpdoc-parser >= 1.0

goetas commented 1 year ago

@dgafka I have to say that src/Metadata/Driver/DocBlockDriver/DocBlockTypeResolver.php is getting a Mess... so many edge cases... maybe is doing too much?

dgafka commented 1 year ago

That's true, there are a lot of concepts hidden inside single class, so it could be refactored. If nobody will do it, I may pick it up, when I will be adding some new feature. :)