1#[cfg(feature = "logging")]
12pub use tracing::{debug, enabled, error, info, trace, warn, Level};
13
14#[cfg(not(feature = "logging"))]
17#[macro_export]
18#[doc(hidden)]
19macro_rules! __protocol_log_noop_info {
20 ($($arg:tt)*) => {
21 ()
22 };
23}
24
25#[cfg(not(feature = "logging"))]
26#[macro_export]
27#[doc(hidden)]
28macro_rules! __protocol_log_noop_warn {
29 ($($arg:tt)*) => {
30 ()
31 };
32}
33
34#[cfg(not(feature = "logging"))]
35#[macro_export]
36#[doc(hidden)]
37macro_rules! __protocol_log_noop_debug {
38 ($($arg:tt)*) => {
39 ()
40 };
41}
42
43#[cfg(not(feature = "logging"))]
44#[macro_export]
45#[doc(hidden)]
46macro_rules! __protocol_log_noop_error {
47 ($($arg:tt)*) => {
48 ()
49 };
50}
51
52#[cfg(not(feature = "logging"))]
53#[macro_export]
54#[doc(hidden)]
55macro_rules! __protocol_log_noop_trace {
56 ($($arg:tt)*) => {
57 ()
58 };
59}
60
61#[cfg(not(feature = "logging"))]
62#[macro_export]
63#[doc(hidden)]
64macro_rules! __protocol_log_noop_enabled {
65 ($($arg:tt)*) => {
66 false
67 };
68}
69
70#[cfg(not(feature = "logging"))]
71pub use __protocol_log_noop_debug as debug;
72#[cfg(not(feature = "logging"))]
73pub use __protocol_log_noop_enabled as enabled;
74#[cfg(not(feature = "logging"))]
75pub use __protocol_log_noop_error as error;
76#[cfg(not(feature = "logging"))]
77pub use __protocol_log_noop_info as info;
78#[cfg(not(feature = "logging"))]
79pub use __protocol_log_noop_trace as trace;
80#[cfg(not(feature = "logging"))]
81pub use __protocol_log_noop_warn as warn;
82
83#[cfg(not(feature = "logging"))]
85#[allow(dead_code)]
86pub struct Level;
87
88#[cfg(not(feature = "logging"))]
89#[allow(dead_code)]
90impl Level {
91 pub const DEBUG: Self = Self;
93 pub const INFO: Self = Self;
95 pub const WARN: Self = Self;
97 pub const ERROR: Self = Self;
99 pub const TRACE: Self = Self;
101}