Macro warn

Source
macro_rules! warn {
    (logger: $logger:expr, $($arg:tt)+) => { ... };
    ($($arg:tt)+) => { ... };
}
Expand description

Logs a message at the warn level.

§Named optional parameters

NameTypeDescription
loggerArc<Logger> or LoggerIf specified, the given logger will be used instead of the global default logger.

§Examples

use spdlog::warn;

let warn_description = "Invalid Input";

// Using the global default logger
warn!("Warning! {}!", warn_description);

// Or using the specified logger
warn!(logger: input_events, "App received warning: {}", warn_description);