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

Replace RuntimeHelpers.CreateSpan<T>(LdMemberToken) with new T[] { } #3380

Conversation

ds5678
Copy link
Contributor

@ds5678 ds5678 commented Jan 24, 2025

Problem

Resolves #3379

Solution

  • Any comments on the approach taken, its consistency with surrounding code, etc.
    • I tried to make it very similar to the code for Span<T>(void*, int).
  • Which part of this PR is most in need of attention/improvement?
    • Testing. I'm happy to write additional tests and modify my existing test.
  • At least one test covering the code changed

@siegfriedpammer siegfriedpammer force-pushed the runtimehelpers-createspan-array-initialization branch from f2c6aa1 to 9315d98 Compare February 22, 2025 07:11
@ds5678
Copy link
Contributor Author

ds5678 commented Feb 22, 2025

Sorry, I meant to come back to this. It just slipped my mind.

@ds5678
Copy link
Contributor Author

ds5678 commented Feb 22, 2025

I appreciate you working on it. If you want, I can finish things up. I saw that the CI failed for the unit test. I'll resolve that.

@ds5678
Copy link
Contributor Author

ds5678 commented Feb 22, 2025

If there's any other changes you want me to make, let me know.

@siegfriedpammer
Copy link
Member

I have fixed some more things locally, I will try to re-integrate your recent additions as well...

@siegfriedpammer siegfriedpammer force-pushed the runtimehelpers-createspan-array-initialization branch from fef9777 to 3a13d5a Compare February 22, 2025 10:38
@siegfriedpammer siegfriedpammer merged commit 180428a into icsharpcode:master Feb 22, 2025
5 checks passed
@siegfriedpammer
Copy link
Member

Thank you very much for your contribution! Sorry for the trouble!

@ds5678
Copy link
Contributor Author

ds5678 commented Feb 22, 2025

Thank you as well!

@ds5678 ds5678 deleted the runtimehelpers-createspan-array-initialization branch February 22, 2025 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Static Initialization for Non-Byte Spans
2 participants