trait Foo { def app(x: Object)(y: Object): Object } object O { def main(args: Array[String]): Unit = { val z: Foo = x => ??? } }