summaryrefslogtreecommitdiffstats
path: root/src/test/ui/statics/issue-14227.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/statics/issue-14227.rs')
-rw-r--r--src/test/ui/statics/issue-14227.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/test/ui/statics/issue-14227.rs b/src/test/ui/statics/issue-14227.rs
new file mode 100644
index 000000000..5f866ec90
--- /dev/null
+++ b/src/test/ui/statics/issue-14227.rs
@@ -0,0 +1,10 @@
+// revisions: mir thir
+// [thir]compile-flags: -Z thir-unsafeck
+
+extern "C" {
+ pub static symbol: u32;
+}
+static CRASH: u32 = symbol;
+//~^ ERROR use of extern static is unsafe and requires
+
+fn main() {}