From 7d5e95f013ec16c8672a92cf82c4f77722201e41 Mon Sep 17 00:00:00 2001 From: holger krekel Date: Mon, 16 Dec 2019 19:19:06 +0100 Subject: [PATCH] thread-name seems to be unnamed all the time so it's use is currently theoretic --- src/log.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/log.rs b/src/log.rs index 80697852e..dbd298bcd 100644 --- a/src/log.rs +++ b/src/log.rs @@ -8,9 +8,8 @@ macro_rules! info { ($ctx:expr, $msg:expr, $($args:expr),* $(,)?) => {{ let formatted = format!($msg, $($args),*); let thread = ::std::thread::current(); - let full = format!("{thid:?}/{thname} {file}:{line}: {msg}", + let full = format!("{thid:?} {file}:{line}: {msg}", thid = thread.id(), - thname = thread.name().unwrap_or("unnamed"), file = file!(), line = line!(), msg = &formatted); @@ -26,9 +25,8 @@ macro_rules! warn { ($ctx:expr, $msg:expr, $($args:expr),* $(,)?) => {{ let formatted = format!($msg, $($args),*); let thread = ::std::thread::current(); - let full = format!("{thid:?}/{thname} {file}:{line}: {msg}", + let full = format!("{thid:?} {file}:{line}: {msg}", thid = thread.id(), - thname = thread.name().unwrap_or("unnamed"), file = file!(), line = line!(), msg = &formatted);