After rust-lang/rust#69189, the following check returns true for types, where only the lifetimes differ: &'a T == &'b T
|
let from_ty = cx.tables.expr_ty(&args[0]); |
|
let to_ty = cx.tables.expr_ty(e); |
|
|
|
match (&from_ty.kind, &to_ty.kind) { |
|
_ if from_ty == to_ty => span_lint( |
According to rust-lang/rust#69189 (comment), this probably needs to be fixed by checking the lifetimes of the types with MIR borrowck.
Originally posted by @flip1995 in #5333
After rust-lang/rust#69189, the following check returns
truefor types, where only the lifetimes differ:&'a T == &'b Trust-clippy/clippy_lints/src/transmute.rs
Lines 303 to 307 in c036c4f
According to rust-lang/rust#69189 (comment), this probably needs to be fixed by checking the lifetimes of the types with MIR
borrowck.Originally posted by @flip1995 in #5333