-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Refactor/fix clippy lints #15615
Refactor/fix clippy lints #15615
Conversation
crates/flycheck/src/lib.rs
Outdated
@@ -533,7 +535,7 @@ impl CargoActor { | |||
} | |||
|
|||
enum CargoMessage { | |||
CompilerArtifact(cargo_metadata::Artifact), | |||
CompilerArtifact(Box<cargo_metadata::Artifact>), |
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.
Last time this came up (can't find the PR, though), it was pointed out that this is the most common variant, so boxing the contents will cause almost every instance to incur an allocation.
I don't know if this overhead will be larger than the speed-up obtained from the faster moves. Either way, I suspect it doesn't matter too much compared to the whole cargo check
invocation.
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.
Ah, I see. I will keep it in my mind. Thank you for your review.
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! |
☀️ Test successful - checks-actions |
As title says.