about summary refs log tree commit diff
path: root/src/tools/clippy/clippy_utils
diff options
context:
space:
mode:
authorOli Scherer <github333195615777966@oli-obk.de>2025-03-19 08:59:19 +0000
committerOli Scherer <github333195615777966@oli-obk.de>2025-04-03 09:22:21 +0000
commit805f389da5d8870dc19f879300684bd421194d88 (patch)
tree78ec0ccdef27760b2e67671b04daa219d0ed4685 /src/tools/clippy/clippy_utils
parentc51816ee59576477f79d58e633e145bec381d807 (diff)
downloadrust-805f389da5d8870dc19f879300684bd421194d88.tar.gz
rust-805f389da5d8870dc19f879300684bd421194d88.zip
Remove `LintExpectationId` from `Level` variants
Diffstat (limited to 'src/tools/clippy/clippy_utils')
-rw-r--r--src/tools/clippy/clippy_utils/src/lib.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/tools/clippy/clippy_utils/src/lib.rs b/src/tools/clippy/clippy_utils/src/lib.rs
index b4c5b85dcab..6d2c2a2d692 100644
--- a/src/tools/clippy/clippy_utils/src/lib.rs
+++ b/src/tools/clippy/clippy_utils/src/lib.rs
@@ -1977,14 +1977,14 @@ pub fn fulfill_or_allowed(cx: &LateContext<'_>, lint: &'static Lint, ids: impl I
     let mut suppress_lint = false;
 
     for id in ids {
-        let LevelAndSource { level, .. } = cx.tcx.lint_level_at_node(lint, id);
-        if let Some(expectation) = level.get_expectation_id() {
+        let LevelAndSource { level, lint_id, .. } = cx.tcx.lint_level_at_node(lint, id);
+        if let Some(expectation) = lint_id {
             cx.fulfill_expectation(expectation);
         }
 
         match level {
-            Level::Allow | Level::Expect(_) => suppress_lint = true,
-            Level::Warn | Level::ForceWarn(_) | Level::Deny | Level::Forbid => {},
+            Level::Allow | Level::Expect => suppress_lint = true,
+            Level::Warn | Level::ForceWarn | Level::Deny | Level::Forbid => {},
         }
     }