Skip to content
Snippets Groups Projects
Verified Commit 0568bbe1 authored by Denis Smirnov's avatar Denis Smirnov
Browse files

perf: improve logging

parent 0b934231
No related branches found
No related tags found
1 merge request!1414sbroad import
...@@ -9,13 +9,16 @@ macro_rules! log { ...@@ -9,13 +9,16 @@ macro_rules! log {
let _line: i32 = line!().try_into().unwrap_or(0); let _line: i32 = line!().try_into().unwrap_or(0);
#[cfg(not(feature = "mock"))] #[cfg(not(feature = "mock"))]
{ {
tarantool::log::say( let tnt_level: i32 = unsafe { tarantool::ffi::tarantool::LOG_LEVEL };
tarantool::log::SayLevel::$level, if tnt_level >= tarantool::log::SayLevel::$level as i32 {
file!(), tarantool::log::say(
_line, tarantool::log::SayLevel::$level,
$error, file!(),
$($message)* _line,
); $error,
$($message)*
);
}
} }
}}; }};
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment