Report invisible setter error if it's resolved to synthetic property of base class with public getter and protected setter

^KT-11713 Fixed
This commit is contained in:
Victor Petukhov
2020-09-21 23:53:13 +03:00
parent fdd71c0bce
commit fcfabb70d5
21 changed files with 372 additions and 36 deletions
@@ -23,7 +23,7 @@ class B : A() {
a.<!INVISIBLE_MEMBER!>foo<!>
// TODO: should be INVISIBLE_SETTER
a.bar = a.bar + ""
a.<!INVISIBLE_SETTER!>bar<!> = a.bar + ""
if (a is B) {
<!DEBUG_INFO_SMARTCAST!>a<!>.foo
@@ -34,12 +34,12 @@ class B : A() {
d.x.abc // Ok
d.x.<!INVISIBLE_MEMBER!>foo<!>
// TODO: should be INVISIBLE_SETTER
d.x.bar = d.x.bar + ""
d.x.<!INVISIBLE_SETTER!>bar<!> = d.x.bar + ""
}
}
}
fun baz(a: A) {
a.<!INVISIBLE_MEMBER!>foo<!>
<!INVISIBLE_SETTER!>a.bar<!> = a.bar + ""
<!INVISIBLE_SETTER!>a.<!INVISIBLE_SETTER!>bar<!><!> = a.bar + ""
}
@@ -17,7 +17,7 @@ class B : A() {
b.foo { }
if (a is B) {
<!DEBUG_INFO_SMARTCAST!>a<!>.foo {}
<!OI;DEBUG_INFO_SMARTCAST!>a<!>.<!NI;INVISIBLE_MEMBER!>foo<!> {}
}
if (d.x is B) {