We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e471ebe commit 8cce6d0Copy full SHA for 8cce6d0
compiler/testData/diagnostics/tests/infos/SmartCasts.kt
@@ -205,8 +205,9 @@ fun f(): String {
205
// a is a string, despite of being a variable
206
val <!UNUSED_VARIABLE!>i<!>: String = <!DEBUG_INFO_SMARTCAST!>a<!>
207
<!DEBUG_INFO_SMARTCAST!>a<!>.compareTo("f")
208
- val <!UNUSED_VARIABLE!>f<!>: Function0<String> = { <!DEBUG_INFO_SMARTCAST!>a<!> }
209
- return <!DEBUG_INFO_SMARTCAST!>a<!>
+ // Beginning from here a is captured in a closure so we have to be cautious
+ val <!UNUSED_VARIABLE!>f<!>: Function0<String> = { <!SMARTCAST_IMPOSSIBLE!>a<!> }
210
+ return <!SMARTCAST_IMPOSSIBLE!>a<!>
211
}
212
return ""
213
0 commit comments