dotnet / dotnet/reactive

Merge concurrent/sequential overloads are not at all obvious

Open
#1,254 4 comments 1 reaction 0 assignees View on GitHub
[area] Ix
Dominant language
C#
Stars
7.2k
Forks
798
PR merge metrics
No merged PRs in 30d

Description

Currently the overload `Merge(IAsyncEnumerable[])` is concurrent while `Merge(IEnumerable>)` and `Merge(IAsyncEnumerable>)` are sequential, this is not at all intuitive without looking at the source code.

I'd argue `Merge` should always be a concurrent operator as merge implies items can be interleaved, `Concat` should be the sequential version of this.

You can see [a comment](https://github.com/dotnet/reactive/blob/c940949fe61fe984ad42a71d3ddff5d40540dc92/Ix.NET/Source/System.Interactive.Async/System/Linq/Operators/Merge.cs#L319-L335) in the source code explaining this complexity.

It looks like the breaking change for previous users the sequential Merge should have been made with the release of the BCL interfaces but was not done so.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.