Skip to content

Commit 1c53e27

Browse files
committed
Make diagnostics experimental by default
1 parent 85ab1c4 commit 1c53e27

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+47
-33
lines changed

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/await_outside_of_async.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ pub(crate) fn await_outside_of_async(
1414
format!("`await` is used inside {}, which is not an `async` context", d.location),
1515
display_range,
1616
)
17+
.stable()
1718
}
1819

1920
#[cfg(test)]

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/bad_rtn.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ pub(crate) fn bad_rtn(ctx: &DiagnosticsContext<'_>, d: &hir::BadRtn) -> Diagnost
1212
"return type notation not allowed in this position yet",
1313
d.rtn.map(Into::into),
1414
)
15+
.stable()
1516
}
1617

1718
#[cfg(test)]

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/break_outside_of_loop.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ pub(crate) fn break_outside_of_loop(
1919
message,
2020
d.expr.map(|it| it.into()),
2121
)
22+
.stable()
2223
}
2324

2425
#[cfg(test)]

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/elided_lifetimes_in_path.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,13 @@ pub(crate) fn elided_lifetimes_in_path(
1515
"implicit elided lifetime not allowed here",
1616
d.generics_or_segment.map(Into::into),
1717
)
18-
.experimental()
1918
} else {
2019
Diagnostic::new_with_syntax_node_ptr(
2120
ctx,
2221
DiagnosticCode::RustcLint("elided_lifetimes_in_paths"),
2322
"hidden lifetime parameters in types are deprecated",
2423
d.generics_or_segment.map(Into::into),
2524
)
26-
.experimental()
2725
}
2826
}
2927

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/expected_function.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ pub(crate) fn expected_function(
1515
format!("expected function, found {}", d.found.display(ctx.sema.db, ctx.display_target)),
1616
d.call.map(|it| it.into()),
1717
)
18-
.experimental()
1918
}
2019

2120
#[cfg(test)]

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/generic_args_prohibited.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ pub(crate) fn generic_args_prohibited(
2121
describe_reason(d.reason),
2222
d.args.map(Into::into),
2323
)
24+
.stable()
2425
.with_fixes(fixes(ctx, d))
2526
}
2627

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/inactive_code.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ pub(crate) fn inactive_code(
3333
message,
3434
ctx.sema.diagnostics_display_range(d.node),
3535
)
36+
.stable()
3637
.with_unused(true);
3738
Some(res)
3839
}

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/incoherent_impl.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ pub(crate) fn incoherent_impl(ctx: &DiagnosticsContext<'_>, d: &hir::IncoherentI
1919
"cannot define inherent `impl` for foreign type".to_owned(),
2020
display_range,
2121
)
22+
.stable()
2223
}
2324

2425
#[cfg(test)]

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/incorrect_case.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ pub(crate) fn incorrect_case(ctx: &DiagnosticsContext<'_>, d: &hir::IncorrectCas
2929
),
3030
InFile::new(d.file, d.ident.into()),
3131
)
32+
.stable()
3233
.with_fixes(fixes(ctx, d))
3334
}
3435

src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/incorrect_generics_len.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ pub(crate) fn incorrect_generics_len(
2828
message,
2929
d.generics_or_segment.map(Into::into),
3030
)
31-
.experimental()
3231
}
3332

3433
#[cfg(test)]

0 commit comments

Comments
 (0)