diff options
| author | Maybe Waffle <waffle.lapkin@gmail.com> | 2022-09-16 19:07:20 +0400 |
|---|---|---|
| committer | Maybe Waffle <waffle.lapkin@gmail.com> | 2022-10-01 10:03:06 +0000 |
| commit | 6ecacf76bcd9165eafdb7223e754e74982a00a4c (patch) | |
| tree | 248ed5288276e939d5cce6c04a1530317c607716 /src/librustdoc/core.rs | |
| parent | 7e90a4184437fb39904288106cfb4bfab322e18a (diff) | |
| download | rust-6ecacf76bcd9165eafdb7223e754e74982a00a4c.tar.gz rust-6ecacf76bcd9165eafdb7223e754e74982a00a4c.zip | |
rustdoc: adopt to the new lint API
Diffstat (limited to 'src/librustdoc/core.rs')
| -rw-r--r-- | src/librustdoc/core.rs | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/librustdoc/core.rs b/src/librustdoc/core.rs index f00dff9828d..b463b934e29 100644 --- a/src/librustdoc/core.rs +++ b/src/librustdoc/core.rs @@ -404,12 +404,8 @@ pub(crate) fn run_global_ctxt( tcx.struct_lint_node( crate::lint::MISSING_CRATE_LEVEL_DOCS, DocContext::as_local_hir_id(tcx, krate.module.item_id).unwrap(), - |lint| { - let mut diag = - lint.build("no documentation found for this crate's top-level module"); - diag.help(&help); - diag.emit(); - }, + "no documentation found for this crate's top-level module", + |lint| lint.help(help), ); } |
