From 44310aad68b053afbc2ba9e46fff04e18f54ed06 Mon Sep 17 00:00:00 2001 From: DevJac Date: Fri, 30 Oct 2020 15:52:42 -0600 Subject: [PATCH] Clarify ordering of log levels in the docs It was not clear whether `error` or `trace` was the maximum log level. The docs said "`error!` represents the _highest_-priority log messages and `trace!` the _lowest_". Yet, `set_max_level` regards `Trace` to be the maximum level. I attempted to clarify this by avoiding the terms "high" and "low" in the docs except for where they are applicable to the Rust order as defined in `Ord`. --- src/lib.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/lib.rs b/src/lib.rs index 2edcdf31c..a25c92bac 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1228,6 +1228,8 @@ where /// Sets the global maximum log level. /// /// Generally, this should only be called by the active logging implementation. +/// +/// Note that `Trace` is the maximum level, because it provides the maximum amount of detail in the emitted logs. #[inline] pub fn set_max_level(level: LevelFilter) { MAX_LOG_LEVEL_FILTER.store(level as usize, Ordering::SeqCst)