Merge pull request #2364 from zed-industries/put-backtrace-on-a-newline-when-reporting-panics

Joseph T. Lyons created

Put backtrace on a new line when reporting panics

Change summary

crates/zed/src/main.rs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Detailed changes

crates/zed/src/main.rs 🔗

@@ -336,7 +336,7 @@ fn init_panic_hook(app_version: String) {
         let message = match info.location() {
             Some(location) => {
                 format!(
-                    "thread '{}' panicked at '{}': {}:{}{:?}",
+                    "thread '{}' panicked at '{}': {}:{}\n{:?}",
                     thread,
                     payload,
                     location.file(),
@@ -345,7 +345,7 @@ fn init_panic_hook(app_version: String) {
                 )
             }
             None => format!(
-                "thread '{}' panicked at '{}'{:?}",
+                "thread '{}' panicked at '{}'\n{:?}",
                 thread, payload, backtrace
             ),
         };