Crates.io | log-attributes |
lib.rs | log-attributes |
version | 0.1.0 |
source | src |
created_at | 2021-11-28 17:38:02.500757 |
updated_at | 2021-11-28 17:38:02.500757 |
description | A set of function log attributes, that make logging function in- and outputs a charm. |
homepage | |
repository | https://github.com/DzenanJupic/log-attributes |
max_upload_size | |
id | 488900 |
size | 10,915 |
A set of function log attributes.
This project is currently in active development. It's already usable, but not nearly feature complete.
log-attributes
provides a set of attribute macros, that allow to easily log a function's inputs and return value.
1.0
Roadmapuse log_attributes::{log, info};
#[log(warn, "{fn} was called with {a} and returned {return}")]
fn using_log_attribute(a: &[u32]) -> u32 {
a[0]
}
#[info("{fn} was called")]
fn using_level_attribute() {
// -- snip --
}
Stay tuned for more.
log-attributes is still in a pretty early stage, and you are welcome to contribute to it! The goal is to make logging function inputs and returns more ergonomically.
This project is 100% open source. Any contribution submitted for inclusion in rustube by you, shall have both the MIT licence and the Apache-2.0 licence, and shall be licensed as MIT OR Apache-2.0, without any additional terms or conditions.
This project is licensed under the terms of the MIT licence or the Apache-2.0 licence, at your own choice.