about summary refs log tree commit diff
path: root/src/tools/clippy/clippy_lints
diff options
context:
space:
mode:
authorUrgau <urgau@numericable.fr>2025-07-27 21:21:49 +0200
committerUrgau <urgau@numericable.fr>2025-08-24 00:03:54 +0200
commit02a67cc4a535fdb226a57a3d8d3ef32d68fd347c (patch)
tree3b5229457792e1cedfe698d9f35f5619b41d9c6f /src/tools/clippy/clippy_lints
parent3c664785c12a5b32b4489d0791cf8cc77fd1b3f6 (diff)
downloadrust-02a67cc4a535fdb226a57a3d8d3ef32d68fd347c.tar.gz
rust-02a67cc4a535fdb226a57a3d8d3ef32d68fd347c.zip
Adjust clippy lints for rustc `integer_to_ptr_transmutes` lint
Diffstat (limited to 'src/tools/clippy/clippy_lints')
-rw-r--r--src/tools/clippy/clippy_lints/src/transmute/useless_transmute.rs12
1 files changed, 1 insertions, 11 deletions
diff --git a/src/tools/clippy/clippy_lints/src/transmute/useless_transmute.rs b/src/tools/clippy/clippy_lints/src/transmute/useless_transmute.rs
index ec5fb2793f9..b898920baef 100644
--- a/src/tools/clippy/clippy_lints/src/transmute/useless_transmute.rs
+++ b/src/tools/clippy/clippy_lints/src/transmute/useless_transmute.rs
@@ -49,17 +49,7 @@ pub(super) fn check<'tcx>(
             true
         },
         (ty::Int(_) | ty::Uint(_), ty::RawPtr(_, _)) => {
-            span_lint_and_then(
-                cx,
-                USELESS_TRANSMUTE,
-                e.span,
-                "transmute from an integer to a pointer",
-                |diag| {
-                    if let Some(arg) = sugg::Sugg::hir_opt(cx, arg) {
-                        diag.span_suggestion(e.span, "try", arg.as_ty(to_ty.to_string()), Applicability::Unspecified);
-                    }
-                },
-            );
+            // Handled by the upstream rustc `integer_to_ptr_transmutes` lint
             true
         },
         _ => false,