summaryrefslogtreecommitdiffstats
path: root/src/test/ui/unsized/unsized-fn-arg.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/unsized/unsized-fn-arg.rs')
-rw-r--r--src/test/ui/unsized/unsized-fn-arg.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/test/ui/unsized/unsized-fn-arg.rs b/src/test/ui/unsized/unsized-fn-arg.rs
new file mode 100644
index 000000000..9fc08bd6d
--- /dev/null
+++ b/src/test/ui/unsized/unsized-fn-arg.rs
@@ -0,0 +1,6 @@
+// run-rustfix
+#![crate_type="lib"]
+#![allow(unused)]
+
+fn f<T: ?Sized>(t: T) {}
+//~^ ERROR the size for values of type `T` cannot be known at compilation time