Has it happened to anyone to initialize a variable...
# android
g
Has it happened to anyone to initialize a variable and have it skipping the first
when
clause?
Copy code
val CASE_0 = 0
. . .
val a = json.get("value") // It's 0
when (a) {
    CASE_0 -> // When I debug at this point, 'a' doesn't have a value assigned
    CASE_1 -> // It reaches this clause and now debugger shows it has value '0' assigned
    . . .
}