From 05d8c46c60a48cec860d2e41da5767258923f802 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Cl=C3=A9ment=20Tosi?= Date: Fri, 20 Oct 2023 16:45:53 +0100 Subject: [PATCH] Remove intermediate MAX_LEVEL_INNER Drop the constant as it now seems unnecessary. Note: this is done in a separate commit to be easy to bisect and revert. --- src/lib.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 77b4c8afa..ec9b868b9 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1480,9 +1480,7 @@ pub mod __private_api; /// should compare the level against this value. /// /// [`logger`]: fn.logger.html -pub const STATIC_MAX_LEVEL: LevelFilter = MAX_LEVEL_INNER; - -const MAX_LEVEL_INNER: LevelFilter = match cfg!(debug_assertions) { +pub const STATIC_MAX_LEVEL: LevelFilter = match cfg!(debug_assertions) { false if cfg!(feature = "release_max_level_off") => LevelFilter::Off, false if cfg!(feature = "release_max_level_error") => LevelFilter::Error, false if cfg!(feature = "release_max_level_warn") => LevelFilter::Warn,