-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Dedup UnboundedChannel and UnboundedPriorityChannel #101396
Conversation
We can use generic specialization to avoid duplicating all the code for the different queue types. This should also make it much simpler to add other queue types in the future.
Tagging subscribers to this area: @dotnet/area-system-threading-channels |
src/libraries/System.Threading.Channels/src/System/Threading/Channels/UnboundedChannel.cs
Outdated
Show resolved
Hide resolved
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.
LGTM!
I've left some comments but they were all subjective rename proposals, so feel free to ignore them or address after merging this PR before Preview 4 snap (solving the bug is more important ;) ).
src/libraries/System.Threading.Channels/src/System/Threading/Channels/Channel.netcoreapp.cs
Show resolved
Hide resolved
src/libraries/System.Threading.Channels/src/System/Threading/Channels/IDebugEnumerator.cs
Show resolved
Hide resolved
src/libraries/System.Threading.Channels/src/System/Threading/Channels/Channel.netcoreapp.cs
Outdated
Show resolved
Hide resolved
src/libraries/System.Threading.Channels/src/System/Threading/Channels/Channel.netcoreapp.cs
Show resolved
Hide resolved
src/libraries/System.Threading.Channels/src/System/Threading/Channels/UnboundedChannel.cs
Outdated
Show resolved
Hide resolved
src/libraries/System.Threading.Channels/src/System/Threading/Channels/UnboundedChannel.cs
Outdated
Show resolved
Hide resolved
* Dedup UnboundedChannel and UnboundedPriorityChannel We can use generic specialization to avoid duplicating all the code for the different queue types. This should also make it much simpler to add other queue types in the future. * Address PR feedback
* Dedup UnboundedChannel and UnboundedPriorityChannel We can use generic specialization to avoid duplicating all the code for the different queue types. This should also make it much simpler to add other queue types in the future. * Address PR feedback
We can use generic specialization to avoid duplicating all the code for the different queue types. This should also make it much simpler to add other queue types in the future.