-
Notifications
You must be signed in to change notification settings - Fork 400
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor main loop in raft node of five node example to improve readability #549
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: hhwyt <[email protected]>
cd322d7
to
d133b6d
Compare
- Adjusted the indentation in documentation comments to ensure proper formatting. - Replaced legacy numeric constants with associated constants. - Removed unnecessary import of legacy numeric constants. Signed-off-by: hhwyt <[email protected]>
/cc @glorv @overvenus PTAL. |
@@ -201,7 +201,7 @@ The `Ready` state contains quite a bit of information, and you need to check and | |||
by one: | |||
|
|||
1. Check whether `messages` is empty or not. If not, it means that the node will send messages to | |||
other nodes: | |||
other nodes: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unnecessary space?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unnecessary space?
This is a compiler error from CI, so I made this change.
CI output:
error: doc list item missing indentation
--> src/lib.rs:204:1
|
204 | other nodes:
| ^
|
= help: if this is supposed to be its own paragraph, add a blank line
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation
note: the lint level is defined here
--> src/lib.rs:478:9
|
478 | #![deny(clippy::all)]
| ^^^^^^^^^^^
= note: `#[deny(clippy::doc_lazy_continuation)]` implied by `#[deny(clippy::all)]`
help: indent this line
|
204 | other nodes:
| +++
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR two commits: