From fbc693d1d72d1a0642e80330640bce0e6fb97e9f Mon Sep 17 00:00:00 2001 From: Conrad Irwin Date: Thu, 18 Jan 2024 19:39:13 -0700 Subject: [PATCH] Revert "Improve panic logging" This reverts commit 345b983c8edd18acc346845dcdd1266e144a05a9. --- crates/zed/src/main.rs | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/crates/zed/src/main.rs b/crates/zed/src/main.rs index be07ba6a5f..b251453670 100644 --- a/crates/zed/src/main.rs +++ b/crates/zed/src/main.rs @@ -544,22 +544,7 @@ fn init_panic_hook(app: &App, installation_id: Option, session_id: Strin let mut backtrace = backtrace .frames() .iter() - .flat_map(|frame| { - frame.symbols().iter().filter_map(|symbol| { - let name = symbol.name()?; - let addr = symbol.addr()? as usize; - let position = if let (Some(path), Some(lineno)) = ( - symbol.filename().and_then(|path| path.file_name()), - symbol.lineno(), - ) { - format!("{}:{}", path.to_string_lossy(), lineno) - } else { - "?".to_string() - }; - - Some(format!("{:} ({:#x}) at {}", name, addr, position)) - }) - }) + .filter_map(|frame| Some(format!("{:#}", frame.symbols().first()?.name()?))) .collect::>(); // Strip out leading stack frames for rust panic-handling.