[API Proposal]: Add possibility to create ReadOnlySequence<T> with multiple segments. #111570
Labels
api-suggestion
Early API idea and discussion, it is NOT ready for implementation
area-System.Memory
untriaged
New issue has not been triaged by the area owner
Background and motivation
ReadOnlySequence<T>
has APIs to create empty or single-segment instances, but there's no on-the-box help for creating multiple-segment instances.The first thing a user needs to do is create a
ReadOnlySequenceSegment<T>
derived class.API Proposal
ASP.NET Core has a few implementations of this:
Just having a public implementation would go a long way helping users.
I know there are a few more elaborated implementations, but just having this would help a lot.
Adding to that, simple APIs to create from
IEnumerable<IEnumerable<T>>
API Usage
Alternative Designs
No response
Risks
No response
The text was updated successfully, but these errors were encountered: