Do the hard part first

The only bit failing was the module, so change that before removing the
`span` field.
This commit is contained in:
Joshua Nelson
2021-03-24 00:52:52 -04:00
parent a4b6214279
commit b412b46cf7
9 changed files with 33 additions and 20 deletions

View File

@@ -211,7 +211,7 @@ impl<'a, 'b> fold::DocFolder for CoverageCalculator<'a, 'b> {
None,
);
let filename = i.span.filename(self.ctx.sess());
let filename = i.span().filename(self.ctx.sess());
let has_doc_example = tests.found_tests != 0;
let hir_id = self.ctx.tcx.hir().local_def_id_to_hir_id(i.def_id.expect_local());
let (level, source) = self.ctx.tcx.lint_level_at_node(MISSING_DOCS, hir_id);