Simplify diagnostic message for ACTUAL_MISSING
#KT-21939 Fixed
This commit is contained in:
+1
-1
@@ -261,7 +261,7 @@ public class DefaultErrorMessages {
|
||||
|
||||
MAP.put(NO_ACTUAL_CLASS_MEMBER_FOR_EXPECTED_CLASS, "Actual class ''{0}'' has no corresponding members for expected class members:{1}",
|
||||
NAME, IncompatibleExpectedActualClassScopesRenderer.TEXT);
|
||||
MAP.put(ACTUAL_MISSING, "Declaration should be marked with 'actual' (suppress with -Xno-check-actual)");
|
||||
MAP.put(ACTUAL_MISSING, "Declaration must be marked with 'actual'");
|
||||
|
||||
MAP.put(PROJECTION_ON_NON_CLASS_TYPE_ARGUMENT, "Projections are not allowed on type arguments of functions and properties");
|
||||
MAP.put(SUPERTYPE_NOT_INITIALIZED, "This type has a constructor, and thus must be initialized here");
|
||||
|
||||
+1
-1
@@ -5,6 +5,6 @@ Output:
|
||||
-- JVM --
|
||||
Exit code: COMPILATION_ERROR
|
||||
Output:
|
||||
compiler/testData/multiplatform/simpleNoImplKeywordOnTopLevelFunction/jvm.kt:3:5: error: declaration should be marked with 'actual' (suppress with -Xno-check-actual)
|
||||
compiler/testData/multiplatform/simpleNoImplKeywordOnTopLevelFunction/jvm.kt:3:5: error: declaration must be marked with 'actual'
|
||||
fun foo(s: String): Array<CharSequence?> = arrayOf(s)
|
||||
^
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Add 'actual' modifier" "true"
|
||||
// ERROR: Declaration should be marked with 'actual' (suppress with -Xno-check-actual)
|
||||
// ERROR: Declaration must be marked with 'actual'
|
||||
|
||||
class <caret>Foo
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Add 'actual' modifier" "true"
|
||||
// ERROR: Declaration should be marked with 'actual' (suppress with -Xno-check-actual)
|
||||
// ERROR: Declaration must be marked with 'actual'
|
||||
|
||||
actual class Foo
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// "Add 'actual' modifier" "true"
|
||||
// ERROR: Declaration should be marked with 'actual' (suppress with -Xno-check-actual)
|
||||
// ERROR: Declaration must be marked with 'actual'
|
||||
|
||||
actual class Foo {
|
||||
fun <caret>foo() {}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// "Add 'actual' modifier" "true"
|
||||
// ERROR: Declaration should be marked with 'actual' (suppress with -Xno-check-actual)
|
||||
// ERROR: Declaration must be marked with 'actual'
|
||||
|
||||
actual class Foo {
|
||||
actual fun foo() {}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// "Add 'actual' modifier" "true"
|
||||
// ERROR: Declaration should be marked with 'actual' (suppress with -Xno-check-actual)
|
||||
// ERROR: Declaration must be marked with 'actual'
|
||||
|
||||
fun <caret>foo() {}
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Add 'actual' modifier" "true"
|
||||
// ERROR: Declaration should be marked with 'actual' (suppress with -Xno-check-actual)
|
||||
// ERROR: Declaration must be marked with 'actual'
|
||||
|
||||
actual fun foo() {}
|
||||
|
||||
Reference in New Issue
Block a user