-
-
Notifications
You must be signed in to change notification settings - Fork 637
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
Fixes DistinctIterator to not eat null values #2426
Conversation
next = null; | ||
return result; | ||
nextDefined = false; | ||
return next; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We still hold the reference on the last consumed next
value.
Corner case: a reference to this iterator remains. Then the last iterator value that was consumed can't be garbage collected.
I think I will set next = null
in another commit to be clean here.
Codecov Report
@@ Coverage Diff @@
## master #2426 +/- ##
===========================================
+ Coverage 95.89% 95.9% +<.01%
Complexity 5479 5479
===========================================
Files 94 94
Lines 13340 13344 +4
Branches 1612 1612
===========================================
+ Hits 12793 12797 +4
Misses 408 408
Partials 139 139
Continue to review full report at Codecov.
|
1 similar comment
Codecov Report
@@ Coverage Diff @@
## master #2426 +/- ##
===========================================
+ Coverage 95.89% 95.9% +<.01%
Complexity 5479 5479
===========================================
Files 94 94
Lines 13340 13344 +4
Branches 1612 1612
===========================================
+ Hits 12793 12797 +4
Misses 408 408
Partials 139 139
Continue to review full report at Codecov.
|
* Fixes #2425 * Releasing last consumed 'next' element.
* Fixes vavr-io#2425 * Releasing last consumed 'next' element.
Fixes #2425