diff options
Diffstat (limited to 'test/files/neg/varargs.check')
-rw-r--r-- | test/files/neg/varargs.check | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/files/neg/varargs.check b/test/files/neg/varargs.check new file mode 100644 index 0000000000..f3254708b8 --- /dev/null +++ b/test/files/neg/varargs.check @@ -0,0 +1,7 @@ +varargs.scala:11: error: A method without repeated parameters cannot be annotated with the `varargs` annotation. + @varargs def nov(a: Int) = 0 + ^ +varargs.scala:13: error: A method with a varargs annotation produces a forwarder method with the same signature (a: Int,b: Array[java.lang.String])Int as an existing method. + @varargs def v2(a: Int, b: String*) = 0 + ^ +two errors found
\ No newline at end of file |