update wording of lint
This commit is contained in:
parent
dc2c4ce578
commit
e28a07a0a1
@ -351,7 +351,7 @@ lint_builtin_mutable_transmutes =
|
||||
lint_builtin_unstable_features = unstable feature
|
||||
|
||||
lint_ungated_async_fn_track_caller = `#[track_caller]` on async functions is a no-op
|
||||
.suggestion = enable this feature
|
||||
.suggestion = enable this unstable feature
|
||||
|
||||
lint_builtin_unreachable_pub = unreachable `pub` {$what}
|
||||
.suggestion = consider restricting its visibility
|
||||
|
@ -1409,7 +1409,7 @@ impl<'tcx> LateLintPass<'tcx> for UngatedAsyncFnTrackCaller {
|
||||
|lint| {
|
||||
lint.span_label(span, "this function will not propagate the caller location");
|
||||
if cx.tcx.sess.is_nightly_build() {
|
||||
lint.span_suggestion(attr.span, fluent::suggestion, "#[closure_track_caller]", Applicability::MachineApplicable);
|
||||
lint.span_suggestion(attr.span, fluent::suggestion, "closure_track_caller", Applicability::MachineApplicable);
|
||||
}
|
||||
lint
|
||||
}
|
||||
|
@ -2,7 +2,7 @@ warning: `#[track_caller]` on async functions is a no-op
|
||||
--> $DIR/issue-104588-no-op-track-caller.rs:4:1
|
||||
|
|
||||
LL | #[track_caller]
|
||||
| ^^^^^^^^^^^^^^^ help: enable this feature: `#[closure_track_caller]`
|
||||
| ^^^^^^^^^^^^^^^ help: enable this unstable feature: `closure_track_caller`
|
||||
LL | async fn foo() {}
|
||||
| ----------------- this function will not propagate the caller location
|
||||
|
|
||||
|
@ -2,7 +2,7 @@ warning: `#[track_caller]` on async functions is a no-op
|
||||
--> $DIR/panic-track-caller.rs:50:1
|
||||
|
|
||||
LL | #[track_caller]
|
||||
| ^^^^^^^^^^^^^^^ help: enable this feature: `#[closure_track_caller]`
|
||||
| ^^^^^^^^^^^^^^^ help: enable this unstable feature: `closure_track_caller`
|
||||
LL | / async fn bar_track_caller() {
|
||||
LL | | panic!()
|
||||
LL | | }
|
||||
|
Loading…
x
Reference in New Issue
Block a user