diff --git a/compiler/testData/codegen/boxInline/anonymousObject/kt9591.kt b/compiler/testData/codegen/boxInline/anonymousObject/kt9591.kt index bb11673f32d..0cc1a4afc20 100644 --- a/compiler/testData/codegen/boxInline/anonymousObject/kt9591.kt +++ b/compiler/testData/codegen/boxInline/anonymousObject/kt9591.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test diff --git a/compiler/testData/codegen/boxInline/anonymousObject/kt9877.kt b/compiler/testData/codegen/boxInline/anonymousObject/kt9877.kt index 74f24a4588a..d3cd3ef82d6 100644 --- a/compiler/testData/codegen/boxInline/anonymousObject/kt9877.kt +++ b/compiler/testData/codegen/boxInline/anonymousObject/kt9877.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test fun T.noInline(p: (T) -> Unit) { diff --git a/compiler/testData/codegen/boxInline/argumentOrder/extensionInClass.kt b/compiler/testData/codegen/boxInline/argumentOrder/extensionInClass.kt index d97a31d59b8..8870ba6311a 100644 --- a/compiler/testData/codegen/boxInline/argumentOrder/extensionInClass.kt +++ b/compiler/testData/codegen/boxInline/argumentOrder/extensionInClass.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test class Z { diff --git a/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessInClass.kt b/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessInClass.kt index 8ddc596dba6..98947d35b34 100644 --- a/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessInClass.kt +++ b/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessInClass.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test var res = 1 diff --git a/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessWithDefaultInClass.kt b/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessWithDefaultInClass.kt index 395c99bf342..974b843f626 100644 --- a/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessWithDefaultInClass.kt +++ b/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessWithDefaultInClass.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test var res = 1 diff --git a/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessWithLambdaInClass.kt b/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessWithLambdaInClass.kt index 39eef427f6e..550aa88fa5d 100644 --- a/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessWithLambdaInClass.kt +++ b/compiler/testData/codegen/boxInline/arrayConvention/simpleAccessWithLambdaInClass.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test var res = 1 diff --git a/compiler/testData/codegen/boxInline/builders/builders.kt b/compiler/testData/codegen/boxInline/builders/builders.kt index cb67a3eba51..540dc8710d0 100644 --- a/compiler/testData/codegen/boxInline/builders/builders.kt +++ b/compiler/testData/codegen/boxInline/builders/builders.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package builders import java.util.ArrayList diff --git a/compiler/testData/codegen/boxInline/builders/buildersAndLambdaCapturing.kt b/compiler/testData/codegen/boxInline/builders/buildersAndLambdaCapturing.kt index 424b654ad2a..e4115bf4512 100644 --- a/compiler/testData/codegen/boxInline/builders/buildersAndLambdaCapturing.kt +++ b/compiler/testData/codegen/boxInline/builders/buildersAndLambdaCapturing.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package builders import java.util.ArrayList diff --git a/compiler/testData/codegen/boxInline/complex/forEachLine.kt b/compiler/testData/codegen/boxInline/complex/forEachLine.kt index 5d2930bac37..0f84d5f201f 100644 --- a/compiler/testData/codegen/boxInline/complex/forEachLine.kt +++ b/compiler/testData/codegen/boxInline/complex/forEachLine.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test public class Input(val s1: String, val s2: String) { diff --git a/compiler/testData/codegen/boxInline/complex/lambdaInLambda.kt b/compiler/testData/codegen/boxInline/complex/lambdaInLambda.kt index 040d0e42818..10650ea8e09 100644 --- a/compiler/testData/codegen/boxInline/complex/lambdaInLambda.kt +++ b/compiler/testData/codegen/boxInline/complex/lambdaInLambda.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test public class Input(val s1: String, val s2: String) { diff --git a/compiler/testData/codegen/boxInline/complex/with.kt b/compiler/testData/codegen/boxInline/complex/with.kt index 94a8af3ac44..54e147cfeeb 100644 --- a/compiler/testData/codegen/boxInline/complex/with.kt +++ b/compiler/testData/codegen/boxInline/complex/with.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test diff --git a/compiler/testData/codegen/boxInline/complexStack/asCheck.kt b/compiler/testData/codegen/boxInline/complexStack/asCheck.kt index d5a4474f4d8..7612ca6abd5 100644 --- a/compiler/testData/codegen/boxInline/complexStack/asCheck.kt +++ b/compiler/testData/codegen/boxInline/complexStack/asCheck.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test object ContentTypeByExtension { diff --git a/compiler/testData/codegen/boxInline/defaultValues/defaultInExtension.kt b/compiler/testData/codegen/boxInline/defaultValues/defaultInExtension.kt index edb0b0b2bd1..c48b83e2365 100644 --- a/compiler/testData/codegen/boxInline/defaultValues/defaultInExtension.kt +++ b/compiler/testData/codegen/boxInline/defaultValues/defaultInExtension.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test inline public fun String.run(p1: String? = null): String { diff --git a/compiler/testData/codegen/boxInline/enclosingInfo/anonymousInLambda.kt b/compiler/testData/codegen/boxInline/enclosingInfo/anonymousInLambda.kt index cbe7407d465..5cb2afecf50 100644 --- a/compiler/testData/codegen/boxInline/enclosingInfo/anonymousInLambda.kt +++ b/compiler/testData/codegen/boxInline/enclosingInfo/anonymousInLambda.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test inline fun call(s: () -> R) = s() diff --git a/compiler/testData/codegen/boxInline/enclosingInfo/inlineChain.kt b/compiler/testData/codegen/boxInline/enclosingInfo/inlineChain.kt index c089d726cff..86109c29e99 100644 --- a/compiler/testData/codegen/boxInline/enclosingInfo/inlineChain.kt +++ b/compiler/testData/codegen/boxInline/enclosingInfo/inlineChain.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test inline fun call(s: () -> R) = s() diff --git a/compiler/testData/codegen/boxInline/enclosingInfo/inlineChain2.kt b/compiler/testData/codegen/boxInline/enclosingInfo/inlineChain2.kt index c03e4262b8d..a2e14658405 100644 --- a/compiler/testData/codegen/boxInline/enclosingInfo/inlineChain2.kt +++ b/compiler/testData/codegen/boxInline/enclosingInfo/inlineChain2.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test inline fun call(crossinline s: () -> R) = { s() }() diff --git a/compiler/testData/codegen/boxInline/enclosingInfo/objectInInlineFun.kt b/compiler/testData/codegen/boxInline/enclosingInfo/objectInInlineFun.kt index 04e19565dbd..72128666774 100644 --- a/compiler/testData/codegen/boxInline/enclosingInfo/objectInInlineFun.kt +++ b/compiler/testData/codegen/boxInline/enclosingInfo/objectInInlineFun.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface Z { diff --git a/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructor.kt b/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructor.kt index a9b289be2f2..4a65e0023a3 100644 --- a/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructor.kt +++ b/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructor.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface Z { diff --git a/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructorWithAdditionalObject.kt b/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructorWithAdditionalObject.kt index 573f69933ff..28e261cf667 100644 --- a/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructorWithAdditionalObject.kt +++ b/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructorWithAdditionalObject.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface Z { diff --git a/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructorWithNestedInline.kt b/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructorWithNestedInline.kt index 6d28c9967e1..691aa26cf69 100644 --- a/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructorWithNestedInline.kt +++ b/compiler/testData/codegen/boxInline/enclosingInfo/transformedConstructorWithNestedInline.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface Z { diff --git a/compiler/testData/codegen/boxInline/functionExpression/extension.kt b/compiler/testData/codegen/boxInline/functionExpression/extension.kt index 960746f0d0a..747e96a6b61 100644 --- a/compiler/testData/codegen/boxInline/functionExpression/extension.kt +++ b/compiler/testData/codegen/boxInline/functionExpression/extension.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME inline fun Inline.calcExt(s: (Int) -> Int, p: Int) : Int { return s(p) } diff --git a/compiler/testData/codegen/boxInline/innerClasses/innerLambda.kt b/compiler/testData/codegen/boxInline/innerClasses/innerLambda.kt index c1a7fbb38ab..cdfa4af7a5f 100644 --- a/compiler/testData/codegen/boxInline/innerClasses/innerLambda.kt +++ b/compiler/testData/codegen/boxInline/innerClasses/innerLambda.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test inline fun foo1() = run { diff --git a/compiler/testData/codegen/boxInline/innerClasses/kt10259.kt b/compiler/testData/codegen/boxInline/innerClasses/kt10259.kt index 48e0ac31383..6be1923c15e 100644 --- a/compiler/testData/codegen/boxInline/innerClasses/kt10259.kt +++ b/compiler/testData/codegen/boxInline/innerClasses/kt10259.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test inline fun test(s: () -> Unit) { diff --git a/compiler/testData/codegen/boxInline/lambdaTransformation/lambdaInLambda2.kt b/compiler/testData/codegen/boxInline/lambdaTransformation/lambdaInLambda2.kt index 894a09d203d..7813b01f402 100644 --- a/compiler/testData/codegen/boxInline/lambdaTransformation/lambdaInLambda2.kt +++ b/compiler/testData/codegen/boxInline/lambdaTransformation/lambdaInLambda2.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test inline fun mfun(f: () -> R) { diff --git a/compiler/testData/codegen/boxInline/localFunInLambda/localFunInLambda.kt b/compiler/testData/codegen/boxInline/localFunInLambda/localFunInLambda.kt index d77e6f9f1a4..aef72d1f305 100644 --- a/compiler/testData/codegen/boxInline/localFunInLambda/localFunInLambda.kt +++ b/compiler/testData/codegen/boxInline/localFunInLambda/localFunInLambda.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test public class Data(val value: Int) diff --git a/compiler/testData/codegen/boxInline/multifileClasses/inlineFromOtherPackage.kt b/compiler/testData/codegen/boxInline/multifileClasses/inlineFromOtherPackage.kt index d9f92d8c835..366e5445b2c 100644 --- a/compiler/testData/codegen/boxInline/multifileClasses/inlineFromOtherPackage.kt +++ b/compiler/testData/codegen/boxInline/multifileClasses/inlineFromOtherPackage.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME @file:[JvmName("MultifileClass") JvmMultifileClass] package a diff --git a/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/callSite/exceptionTableSplit.kt b/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/callSite/exceptionTableSplit.kt index b5929b8d8f7..4d944fae4c0 100644 --- a/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/callSite/exceptionTableSplit.kt +++ b/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/callSite/exceptionTableSplit.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test public class Holder(var value: String = "") { diff --git a/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/callSite/exceptionTableSplitNoReturn.kt b/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/callSite/exceptionTableSplitNoReturn.kt index 9c89df9721d..91c01700263 100644 --- a/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/callSite/exceptionTableSplitNoReturn.kt +++ b/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/callSite/exceptionTableSplitNoReturn.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test public class Holder(var value: String = "") { diff --git a/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/exceptionTable/exceptionInFinally.kt b/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/exceptionTable/exceptionInFinally.kt index 05154cce86d..24699b9bfd0 100644 --- a/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/exceptionTable/exceptionInFinally.kt +++ b/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/exceptionTable/exceptionInFinally.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test public interface MCloseable { diff --git a/compiler/testData/codegen/boxInline/private/privateInInlineInMultiFileFacade.kt b/compiler/testData/codegen/boxInline/private/privateInInlineInMultiFileFacade.kt index 8ac16cf60dd..df2284054f7 100644 --- a/compiler/testData/codegen/boxInline/private/privateInInlineInMultiFileFacade.kt +++ b/compiler/testData/codegen/boxInline/private/privateInInlineInMultiFileFacade.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME @file:kotlin.jvm.JvmMultifileClass @file:kotlin.jvm.JvmName("TestKt") package test diff --git a/compiler/testData/codegen/boxInline/reified/capturedLambda.kt b/compiler/testData/codegen/boxInline/reified/capturedLambda.kt index ef5b92aa7ad..baab480f19f 100644 --- a/compiler/testData/codegen/boxInline/reified/capturedLambda.kt +++ b/compiler/testData/codegen/boxInline/reified/capturedLambda.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test inline fun foo() = bar() {"OK"} diff --git a/compiler/testData/codegen/boxInline/reified/capturedLambda2.kt b/compiler/testData/codegen/boxInline/reified/capturedLambda2.kt index dd19276d19e..dcc09a82265 100644 --- a/compiler/testData/codegen/boxInline/reified/capturedLambda2.kt +++ b/compiler/testData/codegen/boxInline/reified/capturedLambda2.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test inline fun bar(crossinline tasksFactory: () -> T) = { diff --git a/compiler/testData/codegen/boxInline/reified/checkCast/chain.kt b/compiler/testData/codegen/boxInline/reified/checkCast/chain.kt index 1c527785e8f..b9078dc2809 100644 --- a/compiler/testData/codegen/boxInline/reified/checkCast/chain.kt +++ b/compiler/testData/codegen/boxInline/reified/checkCast/chain.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test class A diff --git a/compiler/testData/codegen/boxInline/reified/checkCast/kt8043.kt b/compiler/testData/codegen/boxInline/reified/checkCast/kt8043.kt index 5281f35a86c..7e4425eff4d 100644 --- a/compiler/testData/codegen/boxInline/reified/checkCast/kt8043.kt +++ b/compiler/testData/codegen/boxInline/reified/checkCast/kt8043.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test inline fun T.castTo(): R = this as R diff --git a/compiler/testData/codegen/boxInline/reified/checkCast/nullable.kt b/compiler/testData/codegen/boxInline/reified/checkCast/nullable.kt index 8876298611e..53bc4865eb4 100644 --- a/compiler/testData/codegen/boxInline/reified/checkCast/nullable.kt +++ b/compiler/testData/codegen/boxInline/reified/checkCast/nullable.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test class A diff --git a/compiler/testData/codegen/boxInline/reified/checkCast/simple.kt b/compiler/testData/codegen/boxInline/reified/checkCast/simple.kt index 950c3797131..34008fd0b49 100644 --- a/compiler/testData/codegen/boxInline/reified/checkCast/simple.kt +++ b/compiler/testData/codegen/boxInline/reified/checkCast/simple.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test class A diff --git a/compiler/testData/codegen/boxInline/reified/checkCast/simpleSafe.kt b/compiler/testData/codegen/boxInline/reified/checkCast/simpleSafe.kt index 6fbfb5b1721..14a08dcf82d 100644 --- a/compiler/testData/codegen/boxInline/reified/checkCast/simpleSafe.kt +++ b/compiler/testData/codegen/boxInline/reified/checkCast/simpleSafe.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test class A diff --git a/compiler/testData/codegen/boxInline/reified/kt11081.kt b/compiler/testData/codegen/boxInline/reified/kt11081.kt index d967e239a06..ee454599dd8 100644 --- a/compiler/testData/codegen/boxInline/reified/kt11081.kt +++ b/compiler/testData/codegen/boxInline/reified/kt11081.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test open class TypeRef { diff --git a/compiler/testData/codegen/boxInline/reified/kt6988.kt b/compiler/testData/codegen/boxInline/reified/kt6988.kt index 92e7358b8d8..06816cd59ae 100644 --- a/compiler/testData/codegen/boxInline/reified/kt6988.kt +++ b/compiler/testData/codegen/boxInline/reified/kt6988.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface Call { diff --git a/compiler/testData/codegen/boxInline/reified/kt6988_2.kt b/compiler/testData/codegen/boxInline/reified/kt6988_2.kt index 8abb5cced0f..26e812a18de 100644 --- a/compiler/testData/codegen/boxInline/reified/kt6988_2.kt +++ b/compiler/testData/codegen/boxInline/reified/kt6988_2.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test diff --git a/compiler/testData/codegen/boxInline/reified/kt6990.kt b/compiler/testData/codegen/boxInline/reified/kt6990.kt index 9ac695998a7..3bb5b6bb58a 100644 --- a/compiler/testData/codegen/boxInline/reified/kt6990.kt +++ b/compiler/testData/codegen/boxInline/reified/kt6990.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test public inline fun inlineMeIfYouCan(): String? = diff --git a/compiler/testData/codegen/boxInline/reified/kt9637.kt b/compiler/testData/codegen/boxInline/reified/kt9637.kt index b108d5a3086..465739063d3 100644 --- a/compiler/testData/codegen/boxInline/reified/kt9637.kt +++ b/compiler/testData/codegen/boxInline/reified/kt9637.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test import java.util.* diff --git a/compiler/testData/codegen/boxInline/reified/packages.kt b/compiler/testData/codegen/boxInline/reified/packages.kt index b7bb717daef..c0379c66f26 100644 --- a/compiler/testData/codegen/boxInline/reified/packages.kt +++ b/compiler/testData/codegen/boxInline/reified/packages.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test public abstract class A diff --git a/compiler/testData/codegen/boxInline/signature/inProjectionSubstitution.kt b/compiler/testData/codegen/boxInline/signature/inProjectionSubstitution.kt index 3059b2f104c..05f382e51a2 100644 --- a/compiler/testData/codegen/boxInline/signature/inProjectionSubstitution.kt +++ b/compiler/testData/codegen/boxInline/signature/inProjectionSubstitution.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface F { diff --git a/compiler/testData/codegen/boxInline/signature/outProjectionSubstitution.kt b/compiler/testData/codegen/boxInline/signature/outProjectionSubstitution.kt index 72c062cd495..a91c056f3e3 100644 --- a/compiler/testData/codegen/boxInline/signature/outProjectionSubstitution.kt +++ b/compiler/testData/codegen/boxInline/signature/outProjectionSubstitution.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface F { diff --git a/compiler/testData/codegen/boxInline/signature/recursion.kt b/compiler/testData/codegen/boxInline/signature/recursion.kt index e748a4a8198..7bf2af3e876 100644 --- a/compiler/testData/codegen/boxInline/signature/recursion.kt +++ b/compiler/testData/codegen/boxInline/signature/recursion.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test diff --git a/compiler/testData/codegen/boxInline/signature/sameFormalParameterName.kt b/compiler/testData/codegen/boxInline/signature/sameFormalParameterName.kt index 481d65edac9..2459c235e72 100644 --- a/compiler/testData/codegen/boxInline/signature/sameFormalParameterName.kt +++ b/compiler/testData/codegen/boxInline/signature/sameFormalParameterName.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test class B diff --git a/compiler/testData/codegen/boxInline/signature/sameReifiedFormalParameterName.kt b/compiler/testData/codegen/boxInline/signature/sameReifiedFormalParameterName.kt index 979e27ad546..ad1dbc802a8 100644 --- a/compiler/testData/codegen/boxInline/signature/sameReifiedFormalParameterName.kt +++ b/compiler/testData/codegen/boxInline/signature/sameReifiedFormalParameterName.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test class B diff --git a/compiler/testData/codegen/boxInline/signature/starProjectionSubstitution.kt b/compiler/testData/codegen/boxInline/signature/starProjectionSubstitution.kt index f0ee022399e..dd548679b20 100644 --- a/compiler/testData/codegen/boxInline/signature/starProjectionSubstitution.kt +++ b/compiler/testData/codegen/boxInline/signature/starProjectionSubstitution.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface F { diff --git a/compiler/testData/codegen/boxInline/signature/typeParameterInLambda.kt b/compiler/testData/codegen/boxInline/signature/typeParameterInLambda.kt index f9a8a0bc9b1..a31da9eb45d 100644 --- a/compiler/testData/codegen/boxInline/signature/typeParameterInLambda.kt +++ b/compiler/testData/codegen/boxInline/signature/typeParameterInLambda.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test open class Test { diff --git a/compiler/testData/codegen/boxInline/signature/typeParametersSubstitution.kt b/compiler/testData/codegen/boxInline/signature/typeParametersSubstitution.kt index 219428d0fc9..a6a423efee5 100644 --- a/compiler/testData/codegen/boxInline/signature/typeParametersSubstitution.kt +++ b/compiler/testData/codegen/boxInline/signature/typeParametersSubstitution.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test import java.util.* diff --git a/compiler/testData/codegen/boxInline/signature/typeParametersSubstitution2.kt b/compiler/testData/codegen/boxInline/signature/typeParametersSubstitution2.kt index b6f5bcd2e35..99204e9ee57 100644 --- a/compiler/testData/codegen/boxInline/signature/typeParametersSubstitution2.kt +++ b/compiler/testData/codegen/boxInline/signature/typeParametersSubstitution2.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test interface MComparator { diff --git a/compiler/testData/codegen/boxInline/simple/extension.kt b/compiler/testData/codegen/boxInline/simple/extension.kt index f9a0d136629..ad48f1b993f 100644 --- a/compiler/testData/codegen/boxInline/simple/extension.kt +++ b/compiler/testData/codegen/boxInline/simple/extension.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME inline fun Inline.calcExt(s: (Int) -> Int, p: Int) : Int { return s(p) } diff --git a/compiler/testData/codegen/boxInline/simple/vararg.kt b/compiler/testData/codegen/boxInline/simple/vararg.kt index 53d283ed97f..4f75fcfe224 100644 --- a/compiler/testData/codegen/boxInline/simple/vararg.kt +++ b/compiler/testData/codegen/boxInline/simple/vararg.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test inline fun doSmth(vararg a: String) : String { diff --git a/compiler/testData/codegen/boxInline/smap/inlineOnly/noSmap.kt b/compiler/testData/codegen/boxInline/smap/inlineOnly/noSmap.kt index 142be4ab1c9..8ee31295455 100644 --- a/compiler/testData/codegen/boxInline/smap/inlineOnly/noSmap.kt +++ b/compiler/testData/codegen/boxInline/smap/inlineOnly/noSmap.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_RUNTIME package test inline fun stub() { diff --git a/compiler/testData/codegen/boxInline/smap/inlineOnly/reified.kt b/compiler/testData/codegen/boxInline/smap/inlineOnly/reified.kt index f25f2f74ff5..a6d9cf0e108 100644 --- a/compiler/testData/codegen/boxInline/smap/inlineOnly/reified.kt +++ b/compiler/testData/codegen/boxInline/smap/inlineOnly/reified.kt @@ -1,5 +1,5 @@ // FILE: 1.kt - +// WITH_REFLECT package test inline fun className() = T::class.java.simpleName diff --git a/compiler/testData/codegen/boxInline/tryCatchFinally/tryCatchFinally.kt b/compiler/testData/codegen/boxInline/tryCatchFinally/tryCatchFinally.kt index cec4fc278ae..7ae742a68b4 100644 --- a/compiler/testData/codegen/boxInline/tryCatchFinally/tryCatchFinally.kt +++ b/compiler/testData/codegen/boxInline/tryCatchFinally/tryCatchFinally.kt @@ -1,4 +1,5 @@ // FILE: 1.kt +// WITH_RUNTIME class My(val value: Int) diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxCodegenTest.java b/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxCodegenTest.java index e61955a6e8d..89648d057bf 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxCodegenTest.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxCodegenTest.java @@ -55,12 +55,10 @@ public abstract class AbstractBlackBoxCodegenTest extends CodegenTestCase { @Override protected void doMultiFileTest(@NotNull File wholeFile, @NotNull List files, @Nullable File javaFilesDir) throws Exception { - TestJdkKind jdkKind = TestJdkKind.MOCK_JDK; + TestJdkKind jdkKind = getJdkKind(files); + List javacOptions = new ArrayList(0); for (TestFile file : files) { - if (InTextDirectivesUtils.isDirectiveDefined(file.content, "FULL_JDK")) { - jdkKind = TestJdkKind.FULL_JDK; - } if (InTextDirectivesUtils.isDirectiveDefined(file.content, "WITH_RUNTIME")) { addRuntime = true; } diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxInlineCodegenTest.kt b/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxInlineCodegenTest.kt index 7ad77e70713..b81f56580dd 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxInlineCodegenTest.kt +++ b/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxInlineCodegenTest.kt @@ -16,15 +16,11 @@ package org.jetbrains.kotlin.codegen -import org.jetbrains.kotlin.test.ConfigurationKind import java.io.File abstract class AbstractBlackBoxInlineCodegenTest : AbstractBlackBoxCodegenTest() { - override fun doMultiFileTest(file: File, files: List, javaFilesDir: File?) { - createEnvironmentWithMockJdkAndIdeaAnnotations(ConfigurationKind.ALL, files) - loadMultiFiles(files) - blackBox() - + override fun doMultiFileTest(wholeFile: File, files: List, javaFilesDir: File?) { + super.doMultiFileTest(wholeFile, files, javaFilesDir) try { InlineTestUtil.checkNoCallsToInline(initializedClassLoader.allGeneratedFiles.filterClassFiles(), myFiles.psiFiles) SMAPTestUtil.checkSMAP(files, generateClassesInFile().getClassFiles()) diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/AbstractCompileKotlinAgainstKotlinTest.java b/compiler/tests/org/jetbrains/kotlin/codegen/AbstractCompileKotlinAgainstKotlinTest.java index 5d0f8276b92..29332f05df1 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/AbstractCompileKotlinAgainstKotlinTest.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/AbstractCompileKotlinAgainstKotlinTest.java @@ -69,10 +69,10 @@ public abstract class AbstractCompileKotlinAgainstKotlinTest extends CodegenTest assert files.size() == 2 : "There should be exactly two files in this test"; TestFile fileA = files.get(0); TestFile fileB = files.get(1); - ClassFileFactory factoryA = compileA(fileA.name, fileA.content); + ClassFileFactory factoryA = compileA(fileA.name, fileA.content, files); ClassFileFactory factoryB = null; try { - factoryB = compileB(fileB.name, fileB.content); + factoryB = compileB(fileB.name, fileB.content, files); invokeBox(PackagePartClassUtils.getFilePartShortName(new File(fileB.name).getName())); } catch (Throwable e) { @@ -101,16 +101,16 @@ public abstract class AbstractCompileKotlinAgainstKotlinTest extends CodegenTest } @NotNull - protected ClassFileFactory compileA(@NotNull String fileName, @NotNull String content) throws IOException { + protected ClassFileFactory compileA(@NotNull String fileName, @NotNull String content, List files) throws IOException { KotlinCoreEnvironment environment = - KotlinTestUtils.createEnvironmentWithMockJdkAndIdeaAnnotations(getTestRootDisposable(), ConfigurationKind.ALL); + KotlinTestUtils.createEnvironmentWithJdkAndNullabilityAnnotationsFromIdea(getTestRootDisposable(), ConfigurationKind.ALL, getJdkKind(files)); return compileKotlin(fileName, content, aDir, environment, getTestRootDisposable()); } @NotNull - protected ClassFileFactory compileB(@NotNull String fileName, @NotNull String content) throws IOException { + protected ClassFileFactory compileB(@NotNull String fileName, @NotNull String content, List files) throws IOException { CompilerConfiguration configurationWithADirInClasspath = KotlinTestUtils - .compilerConfigurationForTests(ConfigurationKind.ALL, TestJdkKind.MOCK_JDK, KotlinTestUtils.getAnnotationsJar(), aDir); + .compilerConfigurationForTests(ConfigurationKind.ALL, getJdkKind(files), KotlinTestUtils.getAnnotationsJar(), aDir); KotlinCoreEnvironment environment = KotlinCoreEnvironment.createForTests(getTestRootDisposable(), configurationWithADirInClasspath, EnvironmentConfigFiles.JVM_CONFIG_FILES); diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/CodegenTestCase.java b/compiler/tests/org/jetbrains/kotlin/codegen/CodegenTestCase.java index 57f31de73e9..36f04fae24b 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/CodegenTestCase.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/CodegenTestCase.java @@ -91,6 +91,16 @@ public abstract class CodegenTestCase extends UsefulTestCase { createEnvironmentWithMockJdkAndIdeaAnnotations(configurationKind, Collections.emptyList(), javaSourceRoots); } + @NotNull + protected static TestJdkKind getJdkKind(@NotNull List files) { + for (TestFile file : files) { + if (InTextDirectivesUtils.isDirectiveDefined(file.content, "FULL_JDK")) { + return TestJdkKind.FULL_JDK; + } + } + return TestJdkKind.MOCK_JDK; + } + protected final void createEnvironmentWithMockJdkAndIdeaAnnotations( @NotNull ConfigurationKind configurationKind, @NotNull List testFilesWithConfigurationDirectives,