Enforce writing log::<op>!(...) in CODE_STYLE.md

This commit is contained in:
Hirrolot 2021-03-28 09:00:36 +06:00 committed by GitHub
parent afa9c8f8f5
commit 5affdf1759
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -124,3 +124,4 @@ C: Into<String>, { ... }
1. Use `Into<...>` only where there exists at least one conversion **and** it will be logically to use.
2. Always mark a function as `#[must_use]` if its return value **must** be used.
3. `Box::pin(async [move] { ... })` instead of `async [move] { ... }.boxed()`.
4. Always write `log::<op>!(...)` instead of importing `use log::<op>;` and invoking `<op>!(...)`. For example, write `log::info!("blah")`.