rustc_lint::builtin

Static UNGATED_ASYNC_FN_TRACK_CALLER

Source
static UNGATED_ASYNC_FN_TRACK_CALLER: &Lint
Expand description

The ungated_async_fn_track_caller lint warns when the #[track_caller] attribute is used on an async function without enabling the corresponding unstable feature flag.

§Example

#[track_caller]
async fn foo() {}

{{produces}}

§Explanation

The attribute must be used in conjunction with the async_fn_track_caller feature flag. Otherwise, the #[track_caller] annotation will function as a no-op.