about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src/errors.rs
diff options
context:
space:
mode:
authorllogiq <bogusandre@gmail.com>2025-06-05 19:37:32 +0000
committerGitHub <noreply@github.com>2025-06-05 19:37:32 +0000
commitb379d54c22f9f6b9577075d7f89645ac2498c931 (patch)
tree7c18665c058298b80eb9062798c78cb0ead4f357 /compiler/rustc_codegen_llvm/src/errors.rs
parent6ef2a2d17718734f29b3d80d432e39a12a1e41fe (diff)
parentb51e73701d49b3f18cd2f2bdac3d0b72eba12f1e (diff)
downloadrust-b379d54c22f9f6b9577075d7f89645ac2498c931.tar.gz
rust-b379d54c22f9f6b9577075d7f89645ac2498c931.zip
Introduce coerce_container_to_any (#14812)
This PR introduces a lint which detects when `&Box<dyn Any>` is coerced
to `&dyn Any`, which is usually a mistake where the intent was to
directly pass the `dyn Any` inside the box without coercion.

cc @llogiq

Remaining work:
- [x] Documentation
- [x] Generalize from Box to any implementer of `Deref<Target=dyn Any>`

----

changelog: add [`coerce_container_to_any`] lint
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/errors.rs')
0 files changed, 0 insertions, 0 deletions