style: use inline format args for improved readability#20
Closed
style: use inline format args for improved readability#20
Conversation
Replace format!("{}", var) with format!("{var}") across cache, backend,
server, and cli crates. This follows the Rust 2021 edition style and
improves code readability.
- Add backticks to ErrorPayload in error.rs doc (clippy doc_markdown) - Inline format args in to_error_payload() (clippy uninlined_format_args) - Add # Errors documentation to Decode and Encode trait methods (clippy missing_errors_doc) - Add # Errors documentation to Handle::join() (clippy missing_errors_doc)
Add 16 tests covering the TokioContext implementation: - Constructor tests (new, default) - Spawner trait (spawn, with_label, stop, stopped) - Clock trait (now, sleep) - Clone/state sharing behavior - Debug implementation
Replace format!("{}", var) with format!("{var}") in cache, backend,
server, and cli crates. This follows the Rust 2021 edition style.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
format!("{}", var)withformat!("{var}")across multiple cratesChanges
crates/cache/src/memory.rs: 3 instancescrates/cache/src/redis.rs: 5 instancescrates/cache/src/compressed.rs: 2 instancescrates/backend/src/http.rs: 1 instancecrates/server/src/websocket.rs: 2 instancescrates/cli/src/server.rs: 2 instances