mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 11:31:15 +00:00
refactor: remove boxing
This commit is contained in:
parent
96c333262a
commit
dd843060f9
@ -488,9 +488,7 @@ impl CargoActor {
|
|||||||
// Skip certain kinds of messages to only spend time on what's useful
|
// Skip certain kinds of messages to only spend time on what's useful
|
||||||
JsonMessage::Cargo(message) => match message {
|
JsonMessage::Cargo(message) => match message {
|
||||||
cargo_metadata::Message::CompilerArtifact(artifact) if !artifact.fresh => {
|
cargo_metadata::Message::CompilerArtifact(artifact) if !artifact.fresh => {
|
||||||
self.sender
|
self.sender.send(CargoMessage::CompilerArtifact(artifact)).unwrap();
|
||||||
.send(CargoMessage::CompilerArtifact(Box::new(artifact)))
|
|
||||||
.unwrap();
|
|
||||||
}
|
}
|
||||||
cargo_metadata::Message::CompilerMessage(msg) => {
|
cargo_metadata::Message::CompilerMessage(msg) => {
|
||||||
self.sender.send(CargoMessage::Diagnostic(msg.message)).unwrap();
|
self.sender.send(CargoMessage::Diagnostic(msg.message)).unwrap();
|
||||||
@ -535,7 +533,7 @@ impl CargoActor {
|
|||||||
}
|
}
|
||||||
|
|
||||||
enum CargoMessage {
|
enum CargoMessage {
|
||||||
CompilerArtifact(Box<cargo_metadata::Artifact>),
|
CompilerArtifact(cargo_metadata::Artifact),
|
||||||
Diagnostic(Diagnostic),
|
Diagnostic(Diagnostic),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user