Skip to content
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

Use switch over a span in a few more places #68831

Merged
merged 1 commit into from
May 4, 2022

Conversation

stephentoub
Copy link
Member

C# has added the ability to switch on a ReadOnlySpan<char>, using cascading SequenceEquals calls when there are only a few cases, and using the same hash-based jump table when there are enough cases. Use it in a few more places.

@ghost
Copy link

ghost commented May 3, 2022

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

Issue Details

C# has added the ability to switch on a ReadOnlySpan<char>, using cascading SequenceEquals calls when there are only a few cases, and using the same hash-based jump table when there are enough cases. Use it in a few more places.

Author: stephentoub
Assignees: stephentoub
Labels:

area-System.Security

Milestone: -

C# has added the ability to `switch` on a `ReadOnlySpan<char>`, using cascading `SequenceEquals` calls when there are only a few cases, and using the same hash-based jump table when there are enough cases.  Use it in a few more places.
@stephentoub stephentoub merged commit e109bbd into dotnet:main May 4, 2022
@stephentoub stephentoub deleted the switchspans branch May 4, 2022 12:14
@ghost ghost locked as resolved and limited conversation to collaborators Jun 3, 2022
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.

None yet

3 participants