about summary refs log tree commit diff
path: root/compiler/rustc_mir_transform/src/coverage/mod.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-03-30 17:50:36 +0000
committerbors <bors@rust-lang.org>2024-03-30 17:50:36 +0000
commitcebf879de895deae27be8593692ce54023d7f48e (patch)
treead316fbf2a6e0fcc93ca0b8b4408962dde11601c /compiler/rustc_mir_transform/src/coverage/mod.rs
parente0e7ee183f673b13ba9378450db5175fe2f257b7 (diff)
parentf2e91ab1b9aaab23b81fc5ea5de43367cb9b9e6d (diff)
downloadrust-cebf879de895deae27be8593692ce54023d7f48e.tar.gz
rust-cebf879de895deae27be8593692ce54023d7f48e.zip
Auto merge of #12312 - pitaj:legacy_numeric_constants, r=xFrednet
new lint `legacy_numeric_constants`

Rework of #10997

- uses diagnostic items
- does not lint imports of the float modules (`use std::f32`)
- does not lint usage of float constants that look like `f32::MIN`

I chose to make the float changes because the following pattern is actually pretty useful
```rust
use std::f32;
let omega = freq * 2 * f32::consts::PI;
```
and the float modules are not TBD-deprecated like the integer modules.

Closes #10995

---

changelog: New lint [`legacy_numeric_constants`]
[#12312](https://github.com/rust-lang/rust-clippy/pull/12312)
Diffstat (limited to 'compiler/rustc_mir_transform/src/coverage/mod.rs')
0 files changed, 0 insertions, 0 deletions