about summary refs log tree commit diff
path: root/src/librustdoc/clean/utils.rs
diff options
context:
space:
mode:
authorAlexis (Poliorcetics) Bourget <ab_contribs@poliorcetiq.eu>2024-12-26 23:41:58 +0100
committerAlexis (Poliorcetics) Bourget <ab_contribs@poliorcetiq.eu>2025-01-30 21:12:50 +0100
commita063cf5f1c151873f753905c75d8e67115308f9d (patch)
treea41c19cd31d2bd221bd0b97bdf5ea7ff3d5b9458 /src/librustdoc/clean/utils.rs
parenta6434ef9c0246fa39eecb34e22807da2a68f3904 (diff)
downloadrust-a063cf5f1c151873f753905c75d8e67115308f9d.tar.gz
rust-a063cf5f1c151873f753905c75d8e67115308f9d.zip
fix(rustdoc): always use a channel when linking to doc.rust-lang.org
Diffstat (limited to 'src/librustdoc/clean/utils.rs')
-rw-r--r--src/librustdoc/clean/utils.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/librustdoc/clean/utils.rs b/src/librustdoc/clean/utils.rs
index 77040aeb94d..65722eff1da 100644
--- a/src/librustdoc/clean/utils.rs
+++ b/src/librustdoc/clean/utils.rs
@@ -590,9 +590,9 @@ pub(crate) fn attrs_have_doc_flag<'a>(
 /// so that the channel is consistent.
 ///
 /// Set by `bootstrap::Builder::doc_rust_lang_org_channel` in order to keep tests passing on beta/stable.
-pub(crate) const DOC_RUST_LANG_ORG_CHANNEL: &str = env!("DOC_RUST_LANG_ORG_CHANNEL");
-pub(crate) static DOC_CHANNEL: Lazy<&'static str> =
-    Lazy::new(|| DOC_RUST_LANG_ORG_CHANNEL.rsplit('/').find(|c| !c.is_empty()).unwrap());
+pub(crate) const DOC_RUST_LANG_ORG_VERSION: &str = env!("DOC_RUST_LANG_ORG_CHANNEL");
+pub(crate) static RUSTDOC_VERSION: Lazy<&'static str> =
+    Lazy::new(|| DOC_RUST_LANG_ORG_VERSION.rsplit('/').find(|c| !c.is_empty()).unwrap());
 
 /// Render a sequence of macro arms in a format suitable for displaying to the user
 /// as part of an item declaration.