aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_lsp_server/src/main_loop
diff options
context:
space:
mode:
authorIlya Titkov <[email protected]>2020-02-17 08:44:58 +0000
committerIlya Titkov <[email protected]>2020-02-17 08:44:58 +0000
commita2b0bdcc24a64061364aaa017bf6caef1810da7c (patch)
treee434da0a4a0d6f8413be638d6c5d98a215e98792 /crates/ra_lsp_server/src/main_loop
parent32fc890de87e25c342b7c141ef98b07cb1471128 (diff)
Add arguments to rustfmt
Diffstat (limited to 'crates/ra_lsp_server/src/main_loop')
-rw-r--r--crates/ra_lsp_server/src/main_loop/handlers.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/crates/ra_lsp_server/src/main_loop/handlers.rs b/crates/ra_lsp_server/src/main_loop/handlers.rs
index 2e598fdcd..1da2d1814 100644
--- a/crates/ra_lsp_server/src/main_loop/handlers.rs
+++ b/crates/ra_lsp_server/src/main_loop/handlers.rs
@@ -590,6 +590,7 @@ pub fn handle_formatting(
590 let end_position = TextUnit::of_str(&file).conv_with(&file_line_index); 590 let end_position = TextUnit::of_str(&file).conv_with(&file_line_index);
591 591
592 let mut rustfmt = process::Command::new("rustfmt"); 592 let mut rustfmt = process::Command::new("rustfmt");
593 rustfmt.args(&world.options.rustfmt_args);
593 if let Some(&crate_id) = crate_ids.first() { 594 if let Some(&crate_id) = crate_ids.first() {
594 // Assume all crates are in the same edition 595 // Assume all crates are in the same edition
595 let edition = world.analysis().crate_edition(crate_id)?; 596 let edition = world.analysis().crate_edition(crate_id)?;