Skip to content

Conversation

@SirCxyrtyx
Copy link
Contributor

@SirCxyrtyx SirCxyrtyx commented Jul 29, 2024

Part of #81500

API Proposal: #105653

This implements IUtf8SpanParsable on Guid by making the core of the parsing logic generic on TChar : IUtfChar<TChar>. A small amount of it is duplicated, with a version for char and byte, because doing so prevented a performance regression for char parsing.

In addition, it adds a Utf8 Parse and TryParse without the unused IFormatProvider parameter, to match how ISpanParsable was implemented. I did not add Utf8 overloads for ParseExact, but that can be discussed in the linked API proposal.

@ghost ghost added needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners new-api-needs-documentation labels Jul 29, 2024
@ghost
Copy link

ghost commented Jul 29, 2024

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.

1 similar comment
@ghost
Copy link

ghost commented Jul 29, 2024

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.

@dotnet-policy-service dotnet-policy-service bot added the community-contribution Indicates that the PR has been added by a community member label Jul 29, 2024
@SirCxyrtyx
Copy link
Contributor Author

@dotnet-policy-service agree

@SirCxyrtyx SirCxyrtyx marked this pull request as ready for review July 30, 2024 06:42
@huoyaoyuan huoyaoyuan added area-System.Runtime and removed needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners labels Aug 1, 2024
@dotnet-policy-service
Copy link
Contributor

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

Copy link
Member

@stephentoub stephentoub left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other than my comments/questions, LGTM. Thanks.

@stephentoub stephentoub force-pushed the GuidIUtf8Parseable branch from 58f51af to 81820ce Compare June 1, 2025 01:45
@stephentoub stephentoub merged commit 50bf168 into dotnet:main Jun 1, 2025
142 checks passed
@SirCxyrtyx
Copy link
Contributor Author

Just saw the updates, sorry for not responding quicker. Glad to see this merged!

@github-actions github-actions bot locked and limited conversation to collaborators Jul 2, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-System.Runtime community-contribution Indicates that the PR has been added by a community member new-api-needs-documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants