enable clippy::must_use_candidate, add #[must_use] to the 3 flagged fns
This commit is contained in:
parent
760e5ad4cc
commit
c661d699ad
4 changed files with 3 additions and 1 deletions
|
|
@ -44,7 +44,6 @@ pedantic = { level = "deny", priority = -1 }
|
|||
missing_errors_doc = "allow"
|
||||
missing_panics_doc = "allow"
|
||||
module_name_repetitions = "allow"
|
||||
must_use_candidate = "allow"
|
||||
|
||||
[workspace.lints.rustdoc]
|
||||
# Doc-link rot has no other discoverer: clippy does not read intra-doc
|
||||
|
|
|
|||
|
|
@ -487,6 +487,7 @@ pub struct LifecycleScope {
|
|||
impl LifecycleScope {
|
||||
/// True when nothing is explicitly selected — interpreted as "all
|
||||
/// classes" (the bare `hivectl stop` / `start` with no scope flags).
|
||||
#[must_use]
|
||||
pub fn is_everything(&self) -> bool {
|
||||
!(self.agents || self.ci || self.forge || self.gateway || self.matrix)
|
||||
&& self.agent_names.is_empty()
|
||||
|
|
|
|||
|
|
@ -628,6 +628,7 @@ pub async fn list_room_members(client: &Client, room_ref: &str) -> DaemonRespons
|
|||
DaemonResponse::ok(&list)
|
||||
}
|
||||
|
||||
#[must_use]
|
||||
pub fn list_invites(client: &Client) -> DaemonResponse {
|
||||
let invites: Vec<InviteInfo> = client
|
||||
.invited_rooms()
|
||||
|
|
|
|||
|
|
@ -61,6 +61,7 @@ pub enum InfraAction {
|
|||
|
||||
impl InfraAction {
|
||||
/// The `systemctl` subcommand this action maps to.
|
||||
#[must_use]
|
||||
pub fn systemctl_verb(self) -> &'static str {
|
||||
match self {
|
||||
InfraAction::Start => "start",
|
||||
|
|
|
|||
Loading…
Reference in a new issue