The compiler won't be confused, it would just be v...
# language-proposals
k
The compiler won't be confused, it would just be very difficult to read:
Copy code
when(obj.state) {
    .A -> ...
    .B -> ...
}

when (obj.letter) {
    .A -> ...
}
isn't that readable if
letter
and
state
have different types.