diff options
Diffstat (limited to 'tests/pos/implicitFuns.scala')
-rw-r--r-- | tests/pos/implicitFuns.scala | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/tests/pos/implicitFuns.scala b/tests/pos/implicitFuns.scala new file mode 100644 index 000000000..e62682546 --- /dev/null +++ b/tests/pos/implicitFuns.scala @@ -0,0 +1,30 @@ +object Test { + + val x: ImplicitFunction1[String, Boolean] = ??? + + val y: String => Boolean = x + + val b = x("hello") + + val b1: Boolean = b + +} +object Test2 { + + val x: implicit String => Boolean = ??? + + val xx: implicit (String, Int) => Int = ??? + + val y: String => Boolean = x + + val yy: (String, Int) => Any = xx + + val b = x("hello") + + val b1: Boolean = b + + val c = xx("hh", 22) + + val c1: Int = c + +} |