blob: f2cf20a7781f58c245c668b29d5480b05b63dbcf (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
// eta expansion to Function0 is problematic (as shown here).
// Perhaps we should we deprecate it? See discussion in the comments of
// on SI-9178.
//
// This test encodes the status quo: no deprecation.
object Test {
def foo(): () => String = () => ""
val f: () => Any = foo
def main(args: Array[String]): Unit = {
println(f()) // <function0>
}
}
|