Skip to content

Commit 7f4be12

Browse files
fix: lint
1 parent 2cd2083 commit 7f4be12

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

clippy_lints/src/methods/mod.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4113,6 +4113,8 @@ declare_clippy_lint! {
41134113
suspicious,
41144114
"is_empty() called on strings known at compile time"
41154115
}
4116+
4117+
#[allow(clippy::struct_excessive_bools)]
41164118
pub struct Methods {
41174119
avoid_breaking_exported_api: bool,
41184120
msrv: Msrv,
@@ -4124,6 +4126,7 @@ pub struct Methods {
41244126

41254127
impl Methods {
41264128
#[must_use]
4129+
#[allow(clippy::fn_params_excessive_bools)]
41274130
pub fn new(
41284131
avoid_breaking_exported_api: bool,
41294132
msrv: Msrv,
@@ -4570,7 +4573,7 @@ impl Methods {
45704573
_ => {},
45714574
},
45724575
("min" | "max", [arg]) => {
4573-
unnecessary_min_or_max::check(cx, expr, name, recv, arg, self.allowed_external_crates)
4576+
unnecessary_min_or_max::check(cx, expr, name, recv, arg, self.allowed_external_crates);
45744577
},
45754578
("drain", ..) => {
45764579
if let Node::Stmt(Stmt { hir_id: _, kind, .. }) = cx.tcx.parent_hir_node(expr.hir_id)

clippy_lints/src/methods/unnecessary_min_or_max.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ fn detect_extrema<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) -> Option<
9292
}
9393
}
9494

95-
fn is_external_const<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'_>) -> bool {
95+
fn is_external_const(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool {
9696
let ExprKind::Path(ref qpath) = expr.kind else {
9797
return false;
9898
};

0 commit comments

Comments
 (0)