about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAndy Wang <cbeuw.andy@gmail.com>2021-04-03 20:44:18 +0100
committerAndy Wang <cbeuw.andy@gmail.com>2021-05-04 17:35:32 +0100
commit65520ec802f77ab191423f3a1507d6c0be7cfb9c (patch)
tree7f52106f3391415a1f9f84a0f116b72e7d8918cd
parentfed59d669c5ca3c0e9c39dcb1f6510b5876ede64 (diff)
downloadrust-65520ec802f77ab191423f3a1507d6c0be7cfb9c.tar.gz
rust-65520ec802f77ab191423f3a1507d6c0be7cfb9c.zip
Add test for --remap-path-prefix on std imports
-rw-r--r--src/test/codegen/remap_path_prefix/issue-73167-remap-std.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/test/codegen/remap_path_prefix/issue-73167-remap-std.rs b/src/test/codegen/remap_path_prefix/issue-73167-remap-std.rs
new file mode 100644
index 00000000000..56c695d4ded
--- /dev/null
+++ b/src/test/codegen/remap_path_prefix/issue-73167-remap-std.rs
@@ -0,0 +1,12 @@
+// ignore-windows
+
+// compile-flags: -g  -C no-prepopulate-passes --remap-path-prefix=/=/the/root/
+
+// Here we check that imported code from std has their path remapped
+
+// CHECK: !DIFile(filename: "{{/the/root/.*/library/std/src/panic.rs}}"
+fn main() {
+    std::thread::spawn(|| {
+        println!("hello");
+    });
+}