]> git.proxmox.com Git - rustc.git/blob - src/tools/clippy/src/docs/crosspointer_transmute.txt
New upstream version 1.65.0+dfsg1
[rustc.git] / src / tools / clippy / src / docs / crosspointer_transmute.txt
1 ### What it does
2 Checks for transmutes between a type `T` and `*T`.
3
4 ### Why is this bad?
5 It's easy to mistakenly transmute between a type and a
6 pointer to that type.
7
8 ### Example
9 ```
10 core::intrinsics::transmute(t) // where the result type is the same as
11 // `*t` or `&t`'s
12 ```