Skip to content

Commit 95a65c8

Browse files
committed
style nit
1 parent bc39ddc commit 95a65c8

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

clippy_lints/src/casts/cast_possible_truncation.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,6 @@ pub(super) fn check(
8686
cast_to: Ty<'_>,
8787
cast_to_span: Span,
8888
) {
89-
let help = "if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...";
9089
let msg = match (cast_from.kind(), cast_to.is_integral()) {
9190
(ty::Int(_) | ty::Uint(_), true) => {
9291
let from_nbits = apply_reductions(
@@ -166,7 +165,7 @@ pub(super) fn check(
166165
};
167166

168167
span_lint_and_then(cx, CAST_POSSIBLE_TRUNCATION, expr.span, &msg, |diag| {
169-
diag.help(help);
168+
diag.help("if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...");
170169
if !cast_from.is_floating_point() {
171170
offer_suggestion(cx, expr, cast_expr, cast_to_span, diag);
172171
}

0 commit comments

Comments
 (0)