diff --git a/compiler/testData/diagnostics/helpers/types/checkType.kt b/compiler/testData/diagnostics/helpers/types/checkType.kt new file mode 100644 index 00000000000..1e4869bc28b --- /dev/null +++ b/compiler/testData/diagnostics/helpers/types/checkType.kt @@ -0,0 +1,7 @@ +package tests._checkType + +fun checkSubtype(t: T) = t +class Inv +fun Inv._() {} + +infix fun T.checkType(f: Inv.() -> Unit) {} diff --git a/compiler/tests-common/tests/org/jetbrains/kotlin/checkers/BaseDiagnosticsTest.kt b/compiler/tests-common/tests/org/jetbrains/kotlin/checkers/BaseDiagnosticsTest.kt index 3a82fab0568..6ed701881be 100644 --- a/compiler/tests-common/tests/org/jetbrains/kotlin/checkers/BaseDiagnosticsTest.kt +++ b/compiler/tests-common/tests/org/jetbrains/kotlin/checkers/BaseDiagnosticsTest.kt @@ -100,7 +100,9 @@ abstract class BaseDiagnosticsTest : KotlinMultiFileTestWithJava> = setOf( @@ -355,11 +358,6 @@ abstract class BaseDiagnosticsTest : KotlinMultiFileTestWithJava checkSubtype(t: T) = t" + - "\nclass Inv" + - "\nfun Inv._() {}" + - "\ninfix fun T.checkType(f: Inv.() -> Unit) {}" val CHECK_TYPE_IMPORT = "import $CHECK_TYPE_PACKAGE.*" val EXPLICIT_FLEXIBLE_TYPES_DIRECTIVE = "EXPLICIT_FLEXIBLE_TYPES"