diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2021-03-02 11:59:37 +0100 |
|---|---|---|
| committer | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2021-03-04 21:22:44 +0100 |
| commit | 1683cb12e44e433bc75ab3ffa2cfc65c6d0bdd24 (patch) | |
| tree | 275ad55a44363070231ace7e721b1b974f3544e0 /src | |
| parent | e4287992a7b37ed0ae9a9158b1d7bfb4509d2164 (diff) | |
| download | rust-1683cb12e44e433bc75ab3ffa2cfc65c6d0bdd24.tar.gz rust-1683cb12e44e433bc75ab3ffa2cfc65c6d0bdd24.zip | |
Use cache access levels
Diffstat (limited to 'src')
| -rw-r--r-- | src/librustdoc/passes/doc_test_lints.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustdoc/passes/doc_test_lints.rs b/src/librustdoc/passes/doc_test_lints.rs index c97684c7e01..ede9e18a511 100644 --- a/src/librustdoc/passes/doc_test_lints.rs +++ b/src/librustdoc/passes/doc_test_lints.rs @@ -53,7 +53,7 @@ impl crate::doctest::Tester for Tests { } crate fn should_have_doc_example(cx: &DocContext<'_>, item: &clean::Item) -> bool { - if !cx.renderinfo.access_levels.is_public(item.def_id) + if !cx.cache.access_levels.is_public(item.def_id) || matches!( *item.kind, clean::StructFieldItem(_) |
