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

Refactor use of FastAllocateString #110929

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

xtqqczze
Copy link
Contributor

No description provided.

@dotnet-issue-labeler dotnet-issue-labeler bot added the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label Dec 24, 2024
@dotnet-policy-service dotnet-policy-service bot added the community-contribution Indicates that the PR has been added by a community member label Dec 24, 2024
@xtqqczze
Copy link
Contributor Author

@MihuBot

string result = FastAllocateString(length);
resultSpan = new Span<char>(ref result._firstChar, result.Length);
return result;
}
Copy link
Member

Choose a reason for hiding this comment

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

Should we rather use string.Create everywhere?

Copy link
Member

Choose a reason for hiding this comment

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

If the delegate can be inlined everywhere, otherwise there may be performance hot spots?

@jkotas
Copy link
Member

jkotas commented Dec 25, 2024

What are you trying to achieve with this refactoring?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community-contribution Indicates that the PR has been added by a community member needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants