about summary refs log tree commit diff
path: root/tests/ui/box/alloc-unstable-fail.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/box/alloc-unstable-fail.rs')
-rw-r--r--tests/ui/box/alloc-unstable-fail.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/ui/box/alloc-unstable-fail.rs b/tests/ui/box/alloc-unstable-fail.rs
new file mode 100644
index 00000000000..9427571648c
--- /dev/null
+++ b/tests/ui/box/alloc-unstable-fail.rs
@@ -0,0 +1,6 @@
+use std::boxed::Box;
+
+fn main() {
+    let _boxed: Box<u32, _> = Box::new(10);
+    //~^ ERROR use of unstable library feature 'allocator_api'
+}