diff --git a/compiler/rustc_lint_defs/src/builtin.rs b/compiler/rustc_lint_defs/src/builtin.rs index 0463cb2b765..781ac6a14a4 100644 --- a/compiler/rustc_lint_defs/src/builtin.rs +++ b/compiler/rustc_lint_defs/src/builtin.rs @@ -327,14 +327,16 @@ declare_lint! { /// ### Example /// /// ```rust + /// #![feature(must_not_suspend)] + /// /// #[must_not_suspend] /// struct SyncThing {} /// - /// async fn yield() {} + /// async fn yield_now() {} /// /// pub async fn uhoh() { /// let guard = SyncThing {}; - /// yield().await; + /// yield_now().await; /// } /// ``` pub MUST_NOT_SUSPEND,