Crates.io | slog-mock |
lib.rs | slog-mock |
version | 0.5.0 |
source | src |
created_at | 2021-04-19 18:30:01.128467 |
updated_at | 2021-09-11 22:54:07.153491 |
description | Mock crate for slog to compile out all logging |
homepage | |
repository | https://github.com/ammongit/slog-mock |
max_upload_size | |
id | 386774 |
size | 5,651 |
This crate has been abandoned. The technique of using let _
did not compile out code
as expected. While it does suppress "unused" warnings, the objects are still uninitialized,
which doesn't address the performance concerns this crate was made to address.
Crate to mock slog
, returning macros which mimic slog's.
This is not a full drop-in replacement for slog
, but a limited subset of its functionality.
The goal is to enable crates to provide a feature that compiles out all logging code entirely,
in cases where logging is not needed for a specific target due to sensitive performance concerns.
The lint #![forbid(unsafe_code)]
is set, and therefore this crate has only safe code.
Available under the terms of the MIT License.
This library targets the latest stable Rust. At time of writing, that is 1.55.0
.
$ cargo build --release