From 36c48157db26d58b70b414c1ed9a46a9531e9f4f Mon Sep 17 00:00:00 2001 From: Robbert van der Helm Date: Sun, 19 Feb 2023 22:56:35 +0100 Subject: [PATCH] Add a nih_warn!() macro --- src/debug.rs | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/debug.rs b/src/debug.rs index acff77b0..853db51d 100644 --- a/src/debug.rs +++ b/src/debug.rs @@ -29,7 +29,17 @@ macro_rules! nih_log { #[doc(inline)] pub use nih_log; -/// Similar to `nih_log!()`, more scream-y. Used for printing fatal errors. +/// Similar to `nih_log!()`, but less subtle. Used for printing warnings. +#[macro_export] +macro_rules! nih_warn { + ($($args:tt)*) => ( + $crate::log::warn!($($args)*) + ); +} +#[doc(inline)] +pub use nih_warn; + +/// Similar to `nih_log!()`, but more scream-y. Used for printing fatal errors. #[macro_export] macro_rules! nih_error { ($($args:tt)*) => (