aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
Diffstat (limited to 'crates')
-rw-r--r--crates/rust-analyzer/src/bin/args.rs3
-rw-r--r--crates/rust-analyzer/src/bin/main.rs2
2 files changed, 4 insertions, 1 deletions
diff --git a/crates/rust-analyzer/src/bin/args.rs b/crates/rust-analyzer/src/bin/args.rs
index c5f814021..100e46d2f 100644
--- a/crates/rust-analyzer/src/bin/args.rs
+++ b/crates/rust-analyzer/src/bin/args.rs
@@ -52,7 +52,8 @@ FLAGS:
52 --log-file <PATH> Log to the specified file instead of stderr 52 --log-file <PATH> Log to the specified file instead of stderr
53 --no-buffering Flush log records to the file immediately 53 --no-buffering Flush log records to the file immediately
54 54
55 --wait-dbg Wait until a debugger is attached to 55 --wait-dbg Wait until a debugger is attached to.
56 The flag is valid for debug builds only
56 57
57ENVIRONMENTAL VARIABLES: 58ENVIRONMENTAL VARIABLES:
58 RA_LOG Set log filter in env_logger format 59 RA_LOG Set log filter in env_logger format
diff --git a/crates/rust-analyzer/src/bin/main.rs b/crates/rust-analyzer/src/bin/main.rs
index 80637cbff..8f8939863 100644
--- a/crates/rust-analyzer/src/bin/main.rs
+++ b/crates/rust-analyzer/src/bin/main.rs
@@ -29,6 +29,8 @@ fn main() {
29 29
30fn try_main() -> Result<()> { 30fn try_main() -> Result<()> {
31 let args = args::Args::parse()?; 31 let args = args::Args::parse()?;
32
33 #[cfg(debug_assertions)]
32 if args.wait_dbg || env::var("RA_WAIT_DBG").is_ok() { 34 if args.wait_dbg || env::var("RA_WAIT_DBG").is_ok() {
33 #[allow(unused_mut)] 35 #[allow(unused_mut)]
34 let mut d = 4; 36 let mut d = 4;