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

typeof(T).IsValueType isn't resolved to a constant #35897

Closed
john-h-k opened this issue May 6, 2020 · 2 comments
Closed

typeof(T).IsValueType isn't resolved to a constant #35897

john-h-k opened this issue May 6, 2020 · 2 comments

Comments

@john-h-k
Copy link
Contributor

john-h-k commented May 6, 2020

https://sharplab.io/#v2:EYLgxg9gTgpgtADwGwBYA0AXEBDAzgWwB8ABAJgEYBYAKGIGYACMhgYQYG8aHuGueBtAMoALbFAAOAGWzAAdACUArgDsMAS3wxZAKTUYA4jGUwoasAAoMAT3EwIAM3NrVAShcBdPt3oNgECAA2DACSuABq2AEAKjYwADxRAHzmLgwAvIkM1rYO5lEusqERAYowMbYA3DQAvkA===

It can always be resolved to a constant as of course in reference type shared generics, is it always false. Would be useful for optimising Span<T>(T[]) and Memory<T>(T[]) in particular

@Dotnet-GitSync-Bot Dotnet-GitSync-Bot added area-System.Runtime untriaged New issue has not been triaged by the area owner labels May 6, 2020
@samsosa
Copy link

samsosa commented May 6, 2020

Like this: #1157 ?

:-D

@john-h-k
Copy link
Contributor Author

john-h-k commented May 6, 2020

.......not sure how i missed that, oops

@john-h-k john-h-k closed this as completed May 6, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Dec 9, 2020
@tannergooding tannergooding removed the untriaged New issue has not been triaged by the area owner label Jun 24, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants