Fix diagnostic messages for properties.

Fix IDE tests.
Update quick fixes in IDE
(TODO: review new inheritance-related diagnostics with regards to quick fixes)
This commit is contained in:
Dmitry Petrov
2015-12-09 13:03:48 +03:00
parent 94bea54db3
commit 70c200d265
11 changed files with 61 additions and 31 deletions
+3 -4
View File
@@ -1,12 +1,11 @@
interface Base {
fun foo(): Int
var bar: Int
val qux: Int
}
class Derived : Base {
override fun foo(): <error descr="[RETURN_TYPE_MISMATCH_ON_OVERRIDE] Return type of 'foo' is not a subtype of the return type of the overridden member 'public abstract fun foo(): kotlin.Int defined in Base'">String</error> = ""
override var bar: <error descr="[PROPERTY_TYPE_MISMATCH_ON_OVERRIDE] Type of 'bar' doesn't match the type of the overridden var-property 'public abstract var bar: kotlin.Int defined in Base'">String</error> = ""
override var bar: <error descr="[VAR_TYPE_MISMATCH_ON_OVERRIDE] Type of 'bar' doesn't match the type of the overridden var-property 'public abstract var bar: kotlin.Int defined in Base'">String</error> = ""
override val qux: <error descr="[PROPERTY_TYPE_MISMATCH_ON_OVERRIDE] Type of 'qux' is not a subtype of the overridden property 'public abstract val qux: kotlin.Int defined in Base'">String</error> = ""
}