class A { fun foo(a: Int, b: Int): Int { class L: Function0 { override fun invoke(): Int { return a + b - 1 } } return L().invoke() } }