[FIR] Add saving of local context in anonymous functions for further resolve
#KT-37066 Fixed
This commit is contained in:
+2
-2
@@ -6,14 +6,14 @@ fun testLambda() {
|
||||
if (x is String) return@myRun { it -> x.length <!AMBIGUITY!>+<!> it }
|
||||
if (x !is Int) return@myRun { it -> it }
|
||||
|
||||
{ it -> <!UNRESOLVED_REFERENCE!>x<!> + it }
|
||||
{ it -> x <!AMBIGUITY!>+<!> it }
|
||||
}
|
||||
|
||||
val twoLambda: (Int) -> Int = myRun {
|
||||
val x: Int = 1
|
||||
run {
|
||||
val y: Int = 2
|
||||
{ x <!AMBIGUITY!>+<!> <!UNRESOLVED_REFERENCE!>y<!> }
|
||||
{ x + y }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user