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

Add inline attribute to array casts #116

Merged
merged 1 commit into from
Oct 6, 2022

Conversation

shssoichiro
Copy link
Contributor

I found that the Rust compiler was not inlining the methods to_array and as_array_ref, which are extremely thin wrappers around cast functions and should in theory always be inlined. The lack of inlining was also preventing certain code optimizations that the compiler would normally perform.

I found that the Rust compiler was not inlining the methods
`to_array` and `as_array_ref`, which are extremely thin wrappers
around cast functions and should in theory always be inlined.
The lack of inlining was also preventing certain code optimizations
that the compiler would normally perform.
@Lokathor Lokathor merged commit 2e722ae into Lokathor:main Oct 6, 2022
@Lokathor
Copy link
Owner

Lokathor commented Oct 7, 2022

I added even more #[inline] on a lot of other methods too and then released 0.7.5

@shssoichiro shssoichiro deleted the inline-casts branch October 7, 2022 16:15
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.

None yet

2 participants