about summary refs log tree commit diff
path: root/src/librustdoc/html/render
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2021-05-07 16:24:46 +0000
committerbors <bors@rust-lang.org>2021-05-07 16:24:46 +0000
commitca712bc4255cd0912e00ec2eee5b6a547385c2b0 (patch)
treeff4d9ea888df4811d26c260f8bd532d901c016df /src/librustdoc/html/render
parente5f83d24aee866a14753a7cedbb4e301dfe5bef5 (diff)
parent42848090b588a53bc31cfe3718090f488a69633e (diff)
downloadrust-ca712bc4255cd0912e00ec2eee5b6a547385c2b0.tar.gz
rust-ca712bc4255cd0912e00ec2eee5b6a547385c2b0.zip
Auto merge of #85036 - Dylan-DPC:rollup-4qfabo3, r=Dylan-DPC
Rollup of 9 pull requests

Successful merges:

 - #84254 (illumos should put libc last in library search order)
 - #84442 (Unify rustc and rustdoc parsing of `cfg()`)
 - #84655 (Cleanup of `wasm`)
 - #84866 (linker: Avoid library duplication with `/WHOLEARCHIVE`)
 - #84930 (rename LLVM target for RustyHermit)
 - #84991 (rustc: Support Rust-specific features in -Ctarget-feature)
 - #85029 (SGX mutex is movable)
 - #85030 (Rearrange SGX split module files)
 - #85033 (some further small cleanups)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'src/librustdoc/html/render')
-rw-r--r--src/librustdoc/html/render/context.rs2
-rw-r--r--src/librustdoc/html/render/print_item.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/librustdoc/html/render/context.rs b/src/librustdoc/html/render/context.rs
index 2f3f87215c3..e0c1fd06e7b 100644
--- a/src/librustdoc/html/render/context.rs
+++ b/src/librustdoc/html/render/context.rs
@@ -155,7 +155,7 @@ impl<'tcx> Context<'tcx> {
         &self.cache
     }
 
-    fn sess(&self) -> &'tcx Session {
+    pub(super) fn sess(&self) -> &'tcx Session {
         &self.shared.tcx.sess
     }
 
diff --git a/src/librustdoc/html/render/print_item.rs b/src/librustdoc/html/render/print_item.rs
index 70b5458ece8..9d4ac3cf015 100644
--- a/src/librustdoc/html/render/print_item.rs
+++ b/src/librustdoc/html/render/print_item.rs
@@ -296,7 +296,7 @@ fn item_module(w: &mut Buffer, cx: &Context<'_>, item: &clean::Item, items: &[cl
                     let import_item = clean::Item {
                         def_id: import_def_id.into(),
                         attrs: import_attrs,
-                        cfg: ast_attrs.cfg(cx.tcx().sess.diagnostic()),
+                        cfg: ast_attrs.cfg(cx.sess()),
                         ..myitem.clone()
                     };