diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/files/run/t8197.scala | 13 |
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) +} |