Use clippy to disallow e/print/ln macros

This commit is contained in:
Spyros Roum 2023-11-07 22:42:11 +02:00
parent cd0bb24f92
commit b5e0bc889d
3 changed files with 16 additions and 5 deletions

View file

@ -53,11 +53,14 @@ fn main() {
tracing::error!("Unknown backend: {}", other);
}
None => {
println!("USAGE: anvil --backend");
println!();
println!("Possible backends are:");
for b in POSSIBLE_BACKENDS {
println!("\t{}", b);
#[allow(clippy::disallowed_macros)]
{
println!("USAGE: anvil --backend");
println!();
println!("Possible backends are:");
for b in POSSIBLE_BACKENDS {
println!("\t{}", b);
}
}
}
}

View file

@ -1,3 +1,4 @@
#![allow(clippy::disallowed_macros)]
#[cfg(any(feature = "backend_egl", feature = "renderer_gl"))]
fn gl_generate() {
use gl_generator::{Api, Fallbacks, Profile, Registry};

View file

@ -1,2 +1,9 @@
msrv = "1.65.0"
type-complexity-threshold = 400
disallowed-macros = [
{ path = "std::print", reason = "We use tracing for logging" },
{ path = "std::println", reason = "We use tracing for logging" },
{ path = "std::eprint", reason = "We use tracing for logging" },
{ path = "std::eprintln", reason = "We use tracing for logging" },
]