Skip to content

Expose ChannelReader.ReadAllAsync from non-core builds as well #94417

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

Merged
merged 3 commits into from
Nov 14, 2023

Conversation

stephentoub
Copy link
Member

I'm not sure why we didn't fix this before when we shipped Microsoft.Bcl.AsyncInterfaces, but with IAsyncEnumerable available downlevel, there's no need to hide this method away; it can be in all builds. Doing so makes it easier for others to create their own channel implementations, as they don't need to multitarget in order to override everything they might want to.

I've not changed any C# code, just moved it between files.

I'm not sure why we didn't fix this before when we shipped Microsoft.Bcl.AsyncInterfaces, but with IAsyncEnumerable available downlevel, there's no need to hide this method away; it can be in all builds.  Doing so makes it easier for others to create their own channel implementations, as they don't _need_ to multitarget in order to override everything they might want to.

I've not changed any C# code, just moved it between files.
@ghost
Copy link

ghost commented Nov 6, 2023

Note regarding the new-api-needs-documentation label:

This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change.

@ghost
Copy link

ghost commented Nov 6, 2023

Tagging subscribers to this area: @dotnet/area-system-threading-channels
See info in area-owners.md if you want to be subscribed.

Issue Details

I'm not sure why we didn't fix this before when we shipped Microsoft.Bcl.AsyncInterfaces, but with IAsyncEnumerable available downlevel, there's no need to hide this method away; it can be in all builds. Doing so makes it easier for others to create their own channel implementations, as they don't need to multitarget in order to override everything they might want to.

I've not changed any C# code, just moved it between files.

Author: stephentoub
Assignees: stephentoub
Labels:

area-System.Threading.Channels, new-api-needs-documentation

Milestone: -

@stephentoub
Copy link
Member Author

Thanks, @ViktorHofer. Fixed.

@stephentoub stephentoub merged commit ab2d63b into dotnet:main Nov 14, 2023
@stephentoub stephentoub deleted the exposereadallasync branch November 14, 2023 11:41
@github-actions github-actions bot locked and limited conversation to collaborators Dec 15, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants