Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add template generics for PSR-11 implementations in PHPStan and Psalm #3322

Merged
merged 8 commits into from
Jun 13, 2024

Conversation

limarkxx
Copy link
Contributor

Slim v4 abstracts out DI to PSR-11, which means given a Slim/App it is unclear what its DI container is capable of.
Psalm and PHPStan both provide mechanisms to express the types generically, allowing them to ensure that you are calling the correct set method on a DI container received from getContainer

@limarkxx limarkxx marked this pull request as ready for review May 14, 2024 04:17
@coveralls
Copy link

Coverage Status

coverage: 99.427% (-0.002%) from 99.429%
when pulling c7910ea on limarkxx:add-psalm
into 8388b33 on slimphp:4.x.

@coveralls
Copy link

Coverage Status

coverage: 99.429%. remained the same
when pulling c7910ea on limarkxx:add-psalm
into 8388b33 on slimphp:4.x.

@akrabat akrabat merged commit b8de7c1 into slimphp:4.x Jun 13, 2024
6 checks passed
@akrabat
Copy link
Member

akrabat commented Jun 13, 2024

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants