Repository navigation
fix(templates): compare the conditional return type of an implementation by its branches, as the guide's - #14502
Merged
orklah merged 3 commits intoNov 24, 2026
Conversation
…ion by its branches, as the guide's vimeo#12988 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
Behaviour change
|
Contributor
✅ Performance: unchanged · Types: decreased
How to read this table
✅ laravel: issues +0 −1Memory 1 757 → 1 757 MB (<0.1 %) · Wall 63.3 → 61.9 s (−2.2 %) Weighted 53 052 → 53 048 (−4, −0.01 %): L4 −1
Removed (1)
✅ symfony: issues +0 −1Memory 3 650 → 3 650 MB (<0.1 %) · Wall 281.4 → 288.1 s (+2.4 %) Weighted 100 487 → 100 483 (−4, <0.01 %): L4 −1
Removed (1)
✅ guzzle-promises: issues +0 −2Memory 46 → 46 MB (<0.1 %) · Wall 1.6 → 1.6 s (−2.5 %) Weighted 433 → 425 (−8, −1.85 %): L4 −2
Removed (2)
head b5b1e6e · base 66b5f4a (merge-base) · workflow run |
…the values the guide's param takes vimeo#12988 An implementation widening `class-string<T>` to `string|class-string<T>` with `@return ($className is class-string<T> ? T : object)` was compared by both branches, so its `object` branch, which only strings the guide never takes reach, made it an `ImplementedReturnTypeMismatch` (doctrine-orm `EntityManagerInterface::getClassMetadata()`). Only the branch the guide's values reach is compared when that is decidable. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
Review findings of the triage report (head 632db32), checked:
|
Collaborator
|
Thanks @jirkace! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
An implemented method with the same conditional return type as the interface method reports
ImplementedReturnTypeMismatch: the interface's conditional is evaluated to its branches before the comparison, the implementation's isn't.Before
After
Fixes #12988