]> git.lizzy.rs Git - rust.git/commitdiff
Add a test for check_arg_count.
authorChase Albert <thaoeuns@gmail.com>
Thu, 30 Apr 2020 21:30:21 +0000 (17:30 -0400)
committerChase Albert <thaoeuns@gmail.com>
Mon, 4 May 2020 17:51:23 +0000 (13:51 -0400)
tests/compile-fail/check_arg_count.rs [new file with mode: 0644]

diff --git a/tests/compile-fail/check_arg_count.rs b/tests/compile-fail/check_arg_count.rs
new file mode 100644 (file)
index 0000000..663fa60
--- /dev/null
@@ -0,0 +1,7 @@
+#![feature(core_intrinsics)]
+
+use std::intrinsics;
+
+fn main() {
+    unsafe { intrinsics::forget(); } //~ ERROR this function takes 1 argument but 0 arguments were supplied
+}