KT-351 Distinguish statement and expression positions
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
//KT-607 Val reassignment is not marked as an error
|
||||
|
||||
namespace kt607
|
||||
|
||||
fun foo(a: A) {
|
||||
val o = object {
|
||||
val y : Int
|
||||
get() = 42
|
||||
}
|
||||
|
||||
<!VAL_REASSIGNMENT!>a.z<!> = 23
|
||||
<!VAL_REASSIGNMENT!>o.y<!> = 11 //Should be an error here
|
||||
}
|
||||
|
||||
class A() {
|
||||
val z : Int
|
||||
get() = 3
|
||||
}
|
||||
Reference in New Issue
Block a user