Repository navigation
ref(util): Narrow RingBuffer count type to drop PHPStan baseline entry - #2331
Open
sentry-junior[bot] wants to merge 1 commit into
Open
sentry-junior[bot] wants to merge 1 commit into
sentry-junior[bot] wants to merge 1 commit into
Conversation
stayallive
approved these changes
Nov 7, 2026
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.
Removes this entry from
phpstan-baseline.neon:RingBufferimplements\Countable, whosecount()PHPStan types asint<0, max>. The private$countproperty was documented as plainint, so the return didn't match. This narrows its@vartoint<0, max>. That's accurate, since$countstarts at 0, only goes up while below capacity, and is only decremented after an=== 0guard. PHPStan agrees and reports no new errors.This only changes a docblock on a private property, so there's no runtime or public API change. PHPStan and Mago results are otherwise unchanged, and
RingBufferTestpasses.via automation
sched_f05c2f3e9355ecbdd933cf87d44ec5c6· Run IDsched_f05c2f3e9355ecbdd933cf87d44ec5c6:1794042000000.--
View Session [Sentry]