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

Put backtrace on a new line when reporting panics
This commit is contained in:
Joseph T. Lyons 2023-04-07 12:46:53 -04:00 committed by GitHub
commit f450692e77
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

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