about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorLukas Wirth <lukastw97@gmail.com>2025-02-19 06:37:01 +0000
committerGitHub <noreply@github.com>2025-02-19 06:37:01 +0000
commit1ad2fa8d8a67794065eac2f1e947ea9118aacea4 (patch)
tree078c3d090084bd90db7c9f220ce01cd8e26e9cc1 /src
parent1ed047137e47c3fd48dd1102c8e13a923b353609 (diff)
parentd09cabb0b07820cc6238f6b31770392251123f9c (diff)
downloadrust-1ad2fa8d8a67794065eac2f1e947ea9118aacea4.tar.gz
rust-1ad2fa8d8a67794065eac2f1e947ea9118aacea4.zip
Merge pull request #19180 from joshrotenberg/fix-source-file-url
doc: use fully qualified url for source path
Diffstat (limited to 'src')
-rw-r--r--src/tools/rust-analyzer/xtask/src/codegen.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/tools/rust-analyzer/xtask/src/codegen.rs b/src/tools/rust-analyzer/xtask/src/codegen.rs
index e84c259e979..58a3fb64415 100644
--- a/src/tools/rust-analyzer/xtask/src/codegen.rs
+++ b/src/tools/rust-analyzer/xtask/src/codegen.rs
@@ -117,7 +117,13 @@ impl fmt::Display for Location {
         let path = self.file.strip_prefix(project_root()).unwrap().display().to_string();
         let path = path.replace('\\', "/");
         let name = self.file.file_name().unwrap();
-        write!(f, " [{}](/{}#{}) ", name.to_str().unwrap(), path, self.line)
+        write!(
+            f,
+            " [{}](https://github.com/rust-lang/rust-analyzer/blob/master/{}#{}) ",
+            name.to_str().unwrap(),
+            path,
+            self.line
+        )
     }
 }