Skip to content

fix Container::getByType() compatibility with PHPStan#285

Merged
dg merged 1 commit intonette:masterfrom
JanTvrdik:patch-1
Feb 22, 2023
Merged

fix Container::getByType() compatibility with PHPStan#285
dg merged 1 commit intonette:masterfrom
JanTvrdik:patch-1

Conversation

@JanTvrdik
Copy link
Copy Markdown
Contributor

Without specifying the upper bound, PHPStan fails to resolve the return type.

@dg
Copy link
Copy Markdown
Member

dg commented Feb 22, 2023

Thanks

@dg dg merged commit bae2a7a into nette:master Feb 22, 2023
@ondrejmirtes
Copy link
Copy Markdown
Contributor

Generics should be verified with files like these analysed by PHPStan :) https://github.com/laravel/framework/blob/10.x/types/Support/Collection.php

@JanTvrdik JanTvrdik deleted the patch-1 branch March 16, 2023 15:08
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