Files
kotlin-fork/compiler/testData/multiplatform/incompatibleProperties/output.txt
T
Alexander Udalov 74ba0080b1 Improve header/impl mismatch diagnostic messages
Try to report most mismatch errors on the 'impl' declaration. Only
report a mismatch error on the 'header' declaration if no error would be
otherwise reported on any 'impl' declaration in the compilation unit.
Also render declaration kind in the message

 #KT-18447 In Progress
2017-08-25 15:35:05 +03:00

20 lines
677 B
Plaintext
Vendored

-- Common --
Exit code: OK
Output:
-- JVM --
Exit code: COMPILATION_ERROR
Output:
compiler/testData/multiplatform/incompatibleProperties/jvm.kt:1:1: error: 'impl' property 'pval' has no corresponding 'header' declaration
The following declaration is incompatible because property kinds are different (val vs var):
public header val pval: String
impl var pval: String = ""
^
compiler/testData/multiplatform/incompatibleProperties/jvm.kt:2:1: error: 'impl' property 'pvar' has no corresponding 'header' declaration
The following declaration is incompatible because property kinds are different (val vs var):
public header var pvar: String
impl val pvar: String = ""
^