-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Fix [ReadOnly]Span2D<T>.TryGetSpan on legacy frameworks #3948
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
Conversation
|
Thanks Sergio0694 for opening a Pull Request! The reviewers will test the PR and highlight if there is any conflict or changes required. If the PR is approved we will proceed to merge the pull request 🙌 |
1e0f390 to
3ac46c2
Compare
|
@Sergio0694 was the original code done for a performance thing, does that impact that? |
|
@michael-hawker Not sure I understand the question, could you clarify what you mean? Do you mean why do we have the As for the performance difference of this PR in general though, the new version with the fix is comparatively just as fast as the other one (note that that In particular, that Does that help? 🙂 |
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.
Yeah, was just asking about the change in syntax and if it had an impact one the generation/code execution time, as I wasn't sure if the original code was optimized for that or not. So if it's all the same and you've done the analysis, that's all I wanted to know. 🙂 (I assumed you had, as always, but do like to check sometimes... 😋)
|
Hello @michael-hawker! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
3ec1a2c to
e2c2580
Compare
This adjusts the tests following CommunityToolkit#3951
Fixes #3947
PR Type
What kind of change does this PR introduce?
What is the current behavior?
[ReadOnly]Span2D<T>.TryGetSpanthrows an exception when wrapping aT[]instance on legacy frameworks.What is the new behavior?
[ReadOnly]Span2D<T>.TryGetSpanworks correctly on legacy frameworks.PR Checklist
Please check if your PR fulfills the following requirements:
Pull Request has been submitted to the documentation repository instructions. Link:Sample in sample app has been added / updated (for bug fixes / features)Icon has been created (if new sample) following the Thumbnail Style Guide and templates