class Foo(f: () -> Unit) fun main(args: String) { Foo(fun() { val p = 1 }) }