aboutsummaryrefslogtreecommitdiff
path: root/tests/pos/t1987a.scala
diff options
context:
space:
mode:
Diffstat (limited to 'tests/pos/t1987a.scala')
-rw-r--r--tests/pos/t1987a.scala8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/pos/t1987a.scala b/tests/pos/t1987a.scala
new file mode 100644
index 000000000..ccab13371
--- /dev/null
+++ b/tests/pos/t1987a.scala
@@ -0,0 +1,8 @@
+package object overloading {
+ def bar(f: (Int) => Unit): Unit = ()
+ def bar(f: (Int, Int) => Unit): Unit = ()
+}
+
+class PackageObjectOverloadingTest {
+ overloading.bar( (i: Int) => () ) // doesn't compile.
+}