use log::*; fn main() { env_logger::builder() .filter_level(LevelFilter::Trace) .init(); info!("{}", one(2)); info!("{}", one(3)); info!("{}", one(4)); } #[log_instrument::instrument] fn one(x: u32) -> u32 { let cmp = x == 2; debug!("cmp: {cmp}"); if cmp { return 4; } x + 3 }