macro_rules! trace_operation {
($op_name:expr, $result:expr) => { ... };
}
Expand description
Wraps an operation with start/end logging.
Logs operation lifecycle at DEBUG level and returns the operation’s result. Ideal for timing and monitoring critical sections.
§Examples
let data = trace_operation!("process_batch", {
// CPU/GPU intensive work
vec![0u8; 1024]
});