https://kotlinlang.org logo
#k2-early-adopters
Title
# k2-early-adopters
b

brabo-hi

11/13/2023, 6:24 PM
Hi, guys, i have a class with an argument that is used inside init block, after enabling k2 compiler, it is giving me error
myVariable must be initialized
Copy code
class MyClass( val myVariable: String) {
    init {
        // do something with `myVariable` here
    }
}
What am i missing ?
d

dmitriy.novozhilov

11/13/2023, 6:41 PM
Please report an issue
K 1