]> git.lizzy.rs Git - rust.git/commitdiff
Test for too many args.
authorChase Albert <thaoeuns@gmail.com>
Thu, 30 Apr 2020 22:16:56 +0000 (18:16 -0400)
committerChase Albert <thaoeuns@gmail.com>
Mon, 4 May 2020 17:51:23 +0000 (13:51 -0400)
tests/compile-fail/check_arg_count.rs

index 663fa60f72d7ac679a029ef69a3ba58398ce5f7d..0cc6dcb9a98d017356d6b4d6bd8f135311f0e69b 100644 (file)
@@ -4,4 +4,5 @@
 
 fn main() {
     unsafe { intrinsics::forget(); } //~ ERROR this function takes 1 argument but 0 arguments were supplied
+    unsafe { intrinsics::forget(1, 2); } //~ ERROR this function takes 1 argument but 2 arguments were supplied
 }