diff options
| author | Samuel Tardieu <sam@rfc1149.net> | 2025-03-18 20:51:24 +0100 |
|---|---|---|
| committer | Samuel Tardieu <sam@rfc1149.net> | 2025-05-21 17:17:31 +0200 |
| commit | 68ea46179b912e58ef9511559ba7b30ea569def0 (patch) | |
| tree | 5ef5ba3b254718cdb4bcbd8ccbf266e1a2203118 | |
| parent | e3ec0d2de6b6f764d49fe9150335c9cda7ee5600 (diff) | |
| download | rust-68ea46179b912e58ef9511559ba7b30ea569def0.tar.gz rust-68ea46179b912e58ef9511559ba7b30ea569def0.zip | |
Add TODO for const stability MSRV checking
Also, update error marker for consistency.
| -rw-r--r-- | clippy_lints/src/incompatible_msrv.rs | 1 | ||||
| -rw-r--r-- | tests/ui/incompatible_msrv.rs | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/clippy_lints/src/incompatible_msrv.rs b/clippy_lints/src/incompatible_msrv.rs index bf165624b43..a31168fc746 100644 --- a/clippy_lints/src/incompatible_msrv.rs +++ b/clippy_lints/src/incompatible_msrv.rs @@ -168,6 +168,7 @@ impl IncompatibleMsrv { impl<'tcx> LateLintPass<'tcx> for IncompatibleMsrv { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) { + // TODO: check for const stability when in const context match expr.kind { ExprKind::MethodCall(_, _, _, span) => { if let Some(method_did) = cx.typeck_results().type_dependent_def_id(expr.hir_id) { diff --git a/tests/ui/incompatible_msrv.rs b/tests/ui/incompatible_msrv.rs index 41ee9d22124..37e55e9e18a 100644 --- a/tests/ui/incompatible_msrv.rs +++ b/tests/ui/incompatible_msrv.rs @@ -74,7 +74,7 @@ fn lang_items() { #[clippy::msrv = "1.80.0"] fn issue14212() { let _ = std::iter::repeat_n((), 5); - //~^ ERROR: is `1.80.0` but this item is stable since `1.82.0` + //~^ incompatible_msrv } fn local_msrv_change_suggestion() { |
