[FE] Allow lambda argument cast to contextual functional type
This commit is contained in:
committed by
TeamCityServer
parent
d8faa9686d
commit
7fce2691e2
+1
-1
@@ -17,7 +17,7 @@ fun File.open(): InputStream = TODO()
|
||||
fun withAutoClose(block: context(AutoCloseScope) () -> Unit) {
|
||||
val scope = AutoCloseScopeImpl() // Not shown here
|
||||
try {
|
||||
with(scope) { block() }
|
||||
with(scope) { block(<!NO_VALUE_FOR_PARAMETER!>)<!> }
|
||||
} finally {
|
||||
scope.close()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user