phpstan-symfony icon indicating copy to clipboard operation
phpstan-symfony copied to clipboard

Stubs should not be loaded when using versions of Symfony with upstream generic types

Open stof opened this issue 9 months ago • 2 comments

Once generic types are added upstream in Symfony itself, the stubs should not be loaded again to override them, so that the official type definitions are used.

phpstan-doctrine already has a similar logic to prefer using the official generic types instead of stubbing them.

stof avatar Mar 12 '25 12:03 stof

@ondrejmirtes should I submit this to the 1.4.x branch or the 2.0.x branch ?

stof avatar Mar 24 '25 10:03 stof

@stof I'd accept either, given the merge would be easy and conflict-free (very likely).

ondrejmirtes avatar May 05 '25 16:05 ondrejmirtes