Files
rust/tests/ui
Matthias Krüger 2667d853a6 Rollup merge of #114784 - Urgau:many-improve-invalid_reference_casting-lint, r=est31
Improve `invalid_reference_casting` lint

This PR improves the `invalid_reference_casting` lint:
 - by considering an unlimited number of casts instead only const to mut ptr
 - by also considering ptr-to-integer and integer-to-ptr casts
 - by also taking into account [`ptr::cast`](https://doc.rust-lang.org/std/primitive.pointer.html#method.cast), [`ptr::cast`](https://doc.rust-lang.org/std/primitive.pointer.html#method.cast-1) and [`ptr::cast_const`](https://doc.rust-lang.org/std/primitive.pointer.html#method.cast_const)

Most of this improvements comes from skimming Github Code Search result for [`&mut \*.*as \*const`](https://github.com/search?q=lang%3Arust+%2F%26mut+%5C*.*as+%5C*const%2F&type=code)

r? ``@est31`` (maybe)
2023-08-16 20:10:37 +02:00
..
…
…
…
2023-08-15 03:44:21 +00:00
…
…
…
…
…
2023-08-07 19:06:18 +00:00
2023-08-15 04:03:04 +00:00
…
…
…
…
…
…
2023-08-10 11:00:06 +02:00
…
…
…
2023-08-14 16:57:51 -07:00
…
…
…
2023-08-15 00:57:18 +08:00
…
2023-08-12 17:18:46 +00:00
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…