-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
No boxing for structs #22030
No boxing for structs #22030
Conversation
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.
Thanks! Apart from the minor indentation issue this looks good.
It's also possible to simplify the Equals(object) method to something like the following, if you feel like doing that in this PR:
public override bool Equals(object obj)
=> obj is CompiledQueryCacheKey other && Equals(other)
Looks good, thanks! Two other structs which come to mind here are StoreObjectIdentifier (used as Dictionary key here), ValueBuffer which already has Equals. @AndriySvyryd may have other ideas. If you're uncomfortable with any of these of prefer to scope them out, just say so. |
Oops) StoreObjectIdentifier added by someone. |
Thanks for this contribution @SergerGood! |
No description provided.