We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#[track_calls]
Super easy attribute macro. Input:
#[track_calls] fn foo(a: i32, b: usize) -> Option<&str> { todo!() }
Output:
fn foo(a: i32, b: usize) -> Option<&str> { debug!("entering foo"); fn __inner(a: i32, b: usize) -> Option<&str> { todo!() } debug!("exiting foo"); inner() }
Or even with something like #[debug_calls(args, result]
#[debug_calls(args, result]
fn foo(a: i32, b: usize) -> Option<&str> { #[derive(Debug)] struct Args {a: i32, b: usize} debug!("entering foo with values: {:?}", Args {a, b}); fn inner(a: i32, b: usize) -> Option<&str> { todo!() } let ret = inner(); debug!("exiting foo with {:?}", ret); }
The text was updated successfully, but these errors were encountered:
We might just want to switch to tracing
tracing
Sorry, something went wrong.
No branches or pull requests
Super easy attribute macro. Input:
Output:
Or even with something like
#[debug_calls(args, result]
The text was updated successfully, but these errors were encountered: