Skip to content

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 ghost assigned stephentoub May 3, 2022
@ghost ghost added the area-System.Security label May 3, 2022
@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.

3 participants