KT-3573 "Error generating primary constructor" when trying to use "this" in extensions from constructors
#KT-3573 Fixed
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
class Data
|
||||
|
||||
fun newInit(f: Data.() -> Data) = Data().f()
|
||||
|
||||
class TestClass {
|
||||
val test: Data = newInit() { this }
|
||||
}
|
||||
|
||||
fun box() : String {
|
||||
TestClass()
|
||||
return "OK"
|
||||
}
|
||||
Reference in New Issue
Block a user