Report NO_ACTUAL_FOR_EXPECT etc. on relevant declaration

So #KT-20398 Fixed
This commit is contained in:
Mikhail Glukhikh
2017-10-02 16:44:42 +03:00
parent 472e6f462f
commit 8a3fed15f8
17 changed files with 182 additions and 108 deletions
@@ -5,9 +5,9 @@ Output:
-- JVM --
Exit code: COMPILATION_ERROR
Output:
compiler/testData/multiplatform/classScopes/constructorIncorrectSignature/jvm.kt:2:12: error: actual constructor of 'Foo' has no corresponding expected declaration
compiler/testData/multiplatform/classScopes/constructorIncorrectSignature/jvm.kt:2:23: error: actual constructor of 'Foo' has no corresponding expected declaration
The following declaration is incompatible because parameter types are different:
public constructor Foo(s: String)
actual constructor(s: Array<String>)
^
^
@@ -5,9 +5,9 @@ Output:
-- JVM --
Exit code: COMPILATION_ERROR
Output:
compiler/testData/multiplatform/classScopes/functionIncorrectSignature/jvm.kt:2:5: error: actual function 'function' has no corresponding expected declaration
compiler/testData/multiplatform/classScopes/functionIncorrectSignature/jvm.kt:2:40: error: actual function 'function' has no corresponding expected declaration
The following declaration is incompatible because return type is different:
public final expect fun function(b: ByteArray): Int
actual fun function(b: ByteArray): Long = b.size.toLong()
^
^