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

Avoid transmute for binding primitive argument types #1907

Merged
merged 2 commits into from
Jul 13, 2022
Merged

Conversation

kennykerr
Copy link
Collaborator

Now that signature types are categorized more clearly, we can remove the use of transmute for primitive types.

@kennykerr kennykerr merged commit 9cda4e0 into master Jul 13, 2022
@kennykerr kennykerr deleted the less-transmute branch July 13, 2022 17:39
@@ -1158,6 +1158,9 @@ impl<'a> Reader<'a> {
pub fn signature_param_is_convertible(&self, param: &SignatureParam) -> bool {
self.signature_param_maybe_generic(param) && self.type_is_convertible(&param.ty)
}
pub fn signature_param_is_primitive(&self, param: &SignatureParam) -> bool {
self.signature_param_maybe_generic(param) && self.type_is_primitive(&param.ty)
Copy link
Contributor

Choose a reason for hiding this comment

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

It feels like the name signature_param_maybe_generic is wrong now. I'm not sure exactly what it represents. It's an input param that's not a pointer, not a winrt array, and has no array info. How do we succinctly describe that?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yep those names don't make sense to me. I'm slowly making my way to these inner helpers.

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.

2 participants