summaryrefslogtreecommitdiff
path: root/test/files
diff options
context:
space:
mode:
Diffstat (limited to 'test/files')
-rw-r--r--test/files/run/t8197.scala13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/files/run/t8197.scala b/test/files/run/t8197.scala
new file mode 100644
index 0000000000..5ca67088de
--- /dev/null
+++ b/test/files/run/t8197.scala
@@ -0,0 +1,13 @@
+// NOTE: according to SI-4728, this shouldn't even compile...
+class A
+class B
+// default arguments do not participate in overload resolution
+class Foo(val x: A = null) {
+ def this(bla: B*) {
+ this(new A)
+ }
+}
+
+object Test extends App {
+ assert((new Foo).x != null)
+}