Conversation
Six new aggregation combinators mirroring Seq.min/max/minBy/maxBy: - minByAsync / maxByAsync: find element with min/max async-projected key - minBy / maxBy: synchronous projection variants - min / max: compare elements directly (require 'T : comparison) All raise InvalidOperationException on empty sequences, matching Seq behaviour. Includes 8 tests covering correctness, async projections, and empty-sequence errors. Fixes shadowing of Operators.max in bufferByTime by qualifying the call. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
Author
|
Pull request created: #243 |
6 tasks
This was referenced Feb 24, 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.
🤖 This PR was created by Repo Assist, an automated AI assistant.
Summary
Adds six new aggregation combinators that mirror
Seq.min/Seq.max/Seq.minBy/Seq.maxBy:All six raise
InvalidOperationExceptionon empty sequences, matching the behaviour of the correspondingSeqfunctions.Implementation Notes
foldAsyncwith anoptionaccumulator — no new enumerator boilerplate.min/maxdelegate tominBy id/maxBy id.bufferByTime: the existingAsync.Sleep (max 0 rt)call was shadowed by the newmaxdefinition, and has been qualified asOperators.max 0 rt.Test Status
All 202 tests pass ✅ (8 new tests added covering: correct min/max, async projections, empty-sequence errors for
minandmax).