Skip to content

Commit 30e5f26

Browse files
committed
New test, with fixed syntax
1 parent 8ddfcaf commit 30e5f26

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

tests/neg/i2514a.scala

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
object Foo {
2+
def foo(): Int = {
3+
val f: implicit Int => Int = implicit (x: Int) => 2 * x
4+
f(2)
5+
}
6+
7+
val f = implicit (x: Int) => x
8+
9+
(implicit (x: Int) => x): (implicit Int => Int) // error: no implicit argument found
10+
}

0 commit comments

Comments
 (0)