Detect and report inner classes capturing script instance

This commit is contained in:
Ilya Chernikov
2021-12-09 13:55:44 +01:00
committed by TeamCityServer
parent e865652602
commit c1c94778ce
18 changed files with 306 additions and 16 deletions
@@ -0,0 +1,15 @@
// IGNORE_BACKEND: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
// expected: rv: abc!
// KT-19423 variation
val used = "abc"
class Outer {
val bang = "!"
inner class User {
val property = used + bang
}
}
val rv = Outer().User().property