From 22bfc9786a2eab6974c8a9922d86c346cb137aa7 Mon Sep 17 00:00:00 2001 From: Alexander Udalov Date: Mon, 7 Mar 2016 12:47:06 +0300 Subject: [PATCH] Add WITH_RUNTIME or WITH_REFLECT to boxWithStdlib testData --- .../property/listOfStringsMapLength.kt | 4 ++++ .../boxWithStdlib/annotations/annotatedEnumEntry.kt | 1 + .../annotations/annotatedLambda/funExpression.kt | 2 ++ .../annotations/annotatedLambda/lambda.kt | 2 ++ .../annotations/annotatedObjectLiteral.kt | 2 ++ .../annotations/annotationsOnDefault.kt | 2 ++ .../annotations/defaultParameterValues.kt | 2 ++ .../annotations/delegatedPropertySetter.kt | 2 ++ .../annotations/fileClassWithFileAnnotation.kt | 4 +++- .../kotlinPropertyFromClassObjectAsParameter.kt | 2 ++ .../kotlinTopLevelPropertyAsParameter.kt | 2 ++ .../codegen/boxWithStdlib/annotations/kt10136.kt | 4 +++- .../annotations/nestedClassPropertyAsParameter.kt | 2 ++ .../annotations/parameterWithPrimitiveType.kt | 2 ++ .../propertyWithPropertyInInitializerAsParameter.kt | 2 ++ .../annotations/resolveWithLowPriorityAnnotation.kt | 4 +++- .../annotations/varargInAnnotationParameter.kt | 4 +++- .../boxWithStdlib/arrays/arrayConstructorsSimple.kt | 3 ++- .../boxWithStdlib/arrays/inProjectionOfList.kt | 4 +++- .../codegen/boxWithStdlib/arrays/indices.kt | 2 ++ .../codegen/boxWithStdlib/arrays/indicesChar.kt | 2 ++ .../testData/codegen/boxWithStdlib/arrays/kt602.kt | 3 ++- .../testData/codegen/boxWithStdlib/arrays/kt7009.kt | 4 +++- .../testData/codegen/boxWithStdlib/arrays/kt7338.kt | 4 +++- .../boxWithStdlib/arrays/multiArrayConstructors.kt | 2 ++ .../boxWithStdlib/boxingOptimization/casts.kt | 1 + .../boxingOptimization/checkcastAndInstanceOf.kt | 1 + .../boxWithStdlib/boxingOptimization/fold.kt | 1 + .../boxWithStdlib/boxingOptimization/foldRange.kt | 2 ++ .../boxWithStdlib/boxingOptimization/kt5844.kt | 3 ++- .../boxWithStdlib/boxingOptimization/kt6047.kt | 2 ++ .../boxWithStdlib/boxingOptimization/kt6842.kt | 2 ++ .../boxWithStdlib/boxingOptimization/nullCheck.kt | 1 + .../boxingOptimization/progressions.kt | 2 +- .../boxingOptimization/safeCallWithElvis.kt | 1 + .../boxWithStdlib/boxingOptimization/simple.kt | 2 ++ .../boxingOptimization/simpleUninitializedMerge.kt | 2 ++ .../boxingOptimization/unsafeRemoving.kt | 1 + .../boxWithStdlib/boxingOptimization/variables.kt | 1 + .../function/getArityViaFunctionImpl.kt | 2 ++ .../function/listOfStringsMapLength.kt | 2 -- .../codegen/boxWithStdlib/casts/asFunKBig.kt | 3 ++- .../codegen/boxWithStdlib/casts/asWithGeneric.kt | 2 ++ .../codegen/boxWithStdlib/casts/asWithMutable.kt | 4 +++- .../codegen/boxWithStdlib/casts/isFunKBig.kt | 3 ++- .../codegen/boxWithStdlib/casts/isFunKSmall.kt | 4 +++- .../codegen/boxWithStdlib/casts/isWithMutable.kt | 4 +++- .../codegen/boxWithStdlib/casts/reifiedAsFunKBig.kt | 3 ++- .../boxWithStdlib/casts/reifiedAsWithMutable.kt | 4 +++- .../codegen/boxWithStdlib/casts/reifiedIsFunKBig.kt | 3 ++- .../boxWithStdlib/casts/reifiedIsFunKSmall.kt | 4 +++- .../boxWithStdlib/casts/reifiedIsWithMutable.kt | 4 +++- .../boxWithStdlib/casts/reifiedSafeAsWithMutable.kt | 4 +++- .../codegen/boxWithStdlib/casts/safeAsFunKBig.kt | 3 ++- .../codegen/boxWithStdlib/casts/safeAsFunKSmall.kt | 4 +++- .../boxWithStdlib/casts/safeAsWithMutable.kt | 4 +++- .../codegen/boxWithStdlib/casts/unitAsInt.kt | 2 ++ .../boxWithStdlib/casts/weirdMutableCasts.kt | 4 +++- .../codegen/boxWithStdlib/classes/kt8011.kt | 4 +++- .../classes/mutabilityMarkerInterfaces.kt | 4 ++-- .../const/constValInAnnotationDefault.kt | 4 +++- .../boxWithStdlib/const/interfaceCompanion.kt | 4 +++- .../controlStructures/continueInExpr.kt | 4 +++- .../equals/alreadyDeclaredWrongSignature.kt | 4 +++- .../hashcode/alreadyDeclaredWrongSignature.kt | 4 +++- .../tostring/alreadyDeclaredWrongSignature.kt | 4 +++- .../deadCodeElimination/emptyVariableRange.kt | 2 ++ .../constructor/checkIfConstructorIsSynthetic.kt | 2 ++ .../defaultArguments/constructor/manyArgs.kt | 2 ++ .../boxWithStdlib/defaultArguments/kt6382.kt | 4 +++- .../defaultArguments/superCallCheck.kt | 1 + .../delegatedProperty/delegateWithPrivateSet.kt | 2 +- .../boxWithStdlib/delegatedProperty/kt6722.kt | 4 +++- .../boxWithStdlib/delegatedProperty/kt9712.kt | 4 +++- .../delegatedProperty/protectedVarWithPrivateSet.kt | 4 +++- .../stackOverflowOnCallFromGetValue.kt | 1 + .../delegatedProperty/useKPropertyLater.kt | 3 +++ .../codegen/boxWithStdlib/enum/sortEnumEntries.kt | 2 ++ .../testData/codegen/boxWithStdlib/evaluate/char.kt | 2 ++ .../codegen/boxWithStdlib/evaluate/divide.kt | 2 ++ .../codegen/boxWithStdlib/evaluate/intrincics.kt | 4 +++- .../codegen/boxWithStdlib/evaluate/kt9443.kt | 4 +++- .../codegen/boxWithStdlib/evaluate/maxValue.kt | 4 +++- .../codegen/boxWithStdlib/evaluate/maxValueByte.kt | 4 +++- .../codegen/boxWithStdlib/evaluate/maxValueInt.kt | 4 +++- .../codegen/boxWithStdlib/evaluate/miltiply.kt | 4 +++- .../codegen/boxWithStdlib/evaluate/minus.kt | 4 +++- .../testData/codegen/boxWithStdlib/evaluate/mod.kt | 4 +++- .../codegen/boxWithStdlib/evaluate/paranthesized.kt | 4 +++- .../testData/codegen/boxWithStdlib/evaluate/plus.kt | 4 +++- .../boxWithStdlib/evaluate/simpleCallBinary.kt | 2 ++ .../codegen/boxWithStdlib/evaluate/unaryMinus.kt | 2 ++ .../codegen/boxWithStdlib/evaluate/unaryPlus.kt | 2 ++ .../codegen/boxWithStdlib/fullJdk/constFlags.kt | 1 + .../boxWithStdlib/fullJdk/jvmAnnotationFlags.kt | 1 + .../codegen/boxWithStdlib/fullJdk/kt2423.kt | 1 + .../boxWithStdlib/fullJdk/lateinitVisibility.kt | 1 + .../codegen/boxWithStdlib/fullJdk/native/default.kt | 1 + .../boxWithStdlib/fullJdk/native/privateStatic.kt | 1 + .../boxWithStdlib/fullJdk/native/staticNative.kt | 1 + .../fullJdk/regressions/collections.kt | 1 + .../boxWithStdlib/fullJdk/regressions/kt1202.kt | 3 ++- .../boxWithStdlib/fullJdk/regressions/kt1406.kt | 1 + .../boxWithStdlib/fullJdk/regressions/kt274.kt | 1 + .../boxWithStdlib/fullJdk/regressions/kt528.kt | 1 + .../boxWithStdlib/fullJdk/regressions/kt529.kt | 1 + .../boxWithStdlib/fullJdk/regressions/kt533.kt | 1 + .../boxWithStdlib/fullJdk/regressions/kt6485.kt | 1 + .../boxWithStdlib/fullJdk/regressions/kt864.kt | 1 + .../boxWithStdlib/fullJdk/smap/chainCalls.kt | 9 +++++---- .../boxWithStdlib/fullJdk/smap/infixCalls.kt | 7 ++++--- .../fullJdk/smap/simpleCallWithParams.kt | 13 +++++++------ .../fullJdk/synchronized/changeMonitor.kt | 1 + .../synchronized/exceptionInMonitorExpression.kt | 4 +++- .../boxWithStdlib/fullJdk/synchronized/finally.kt | 1 + .../boxWithStdlib/fullJdk/synchronized/longValue.kt | 4 +++- .../fullJdk/synchronized/nestedDifferentObjects.kt | 4 +++- .../fullJdk/synchronized/nestedSameObject.kt | 4 +++- .../fullJdk/synchronized/nonLocalReturn.kt | 1 + .../fullJdk/synchronized/objectValue.kt | 4 +++- .../boxWithStdlib/fullJdk/synchronized/sync.kt | 1 + .../boxWithStdlib/fullJdk/synchronized/value.kt | 4 +++- .../boxWithStdlib/fullJdk/synchronized/wait.kt | 1 + .../codegen/boxWithStdlib/hashPMap/empty.kt | 2 ++ .../codegen/boxWithStdlib/hashPMap/manyNumbers.kt | 2 ++ .../boxWithStdlib/hashPMap/rewriteWithDifferent.kt | 2 ++ .../boxWithStdlib/hashPMap/rewriteWithEqual.kt | 2 ++ .../codegen/boxWithStdlib/hashPMap/simplePlusGet.kt | 2 ++ .../boxWithStdlib/hashPMap/simplePlusMinus.kt | 2 ++ .../testData/codegen/boxWithStdlib/inline/kt6895.kt | 4 +++- .../codegen/boxWithStdlib/inline/kt9644let.kt | 4 +++- .../intrinsics/defaultObjectMapping.kt | 2 ++ .../codegen/boxWithStdlib/intrinsics/kt10131.kt | 4 +++- .../codegen/boxWithStdlib/intrinsics/kt10131a.kt | 4 +++- .../codegen/boxWithStdlib/intrinsics/kt5937.kt | 4 +++- .../boxWithStdlib/jvmField/captureClassFields.kt | 4 +++- .../boxWithStdlib/jvmField/capturePackageFields.kt | 4 +++- .../boxWithStdlib/jvmField/checkNoAccessors.kt | 4 +++- .../boxWithStdlib/jvmField/classFieldReference.kt | 5 +++-- .../boxWithStdlib/jvmField/classFieldReflection.kt | 5 +++-- .../codegen/boxWithStdlib/jvmField/publicField.kt | 4 +++- .../codegen/boxWithStdlib/jvmField/superCall.kt | 4 +++- .../codegen/boxWithStdlib/jvmField/superCall2.kt | 4 +++- .../jvmField/topLevelFieldReference.kt | 5 +++-- .../jvmField/topLevelFieldReflection.kt | 4 +++- .../codegen/boxWithStdlib/jvmField/visibility.kt | 1 + .../boxWithStdlib/jvmField/writeFieldReference.kt | 4 +++- .../boxWithStdlib/jvmName/callableReference.kt | 4 +++- .../boxWithStdlib/jvmName/clashingErasure.kt | 4 +++- .../codegen/boxWithStdlib/jvmName/classMembers.kt | 3 +-- .../codegen/boxWithStdlib/jvmName/functionName.kt | 4 +++- .../codegen/boxWithStdlib/jvmName/multifileClass.kt | 4 +++- .../jvmName/multifileClassWithLocalClass.kt | 4 +++- .../jvmName/multifileClassWithLocalGeneric.kt | 4 +++- .../jvmName/propertyAccessorsUseSite.kt | 2 ++ .../codegen/boxWithStdlib/jvmName/propertyName.kt | 4 +++- .../boxWithStdlib/jvmName/renamedFileClass.kt | 4 +++- .../boxWithStdlib/jvmOverloads/companionObject.kt | 2 ++ .../boxWithStdlib/jvmOverloads/defaultsNotAtEnd.kt | 2 ++ .../boxWithStdlib/jvmOverloads/doubleParameters.kt | 2 ++ .../boxWithStdlib/jvmOverloads/extensionMethod.kt | 2 ++ .../jvmOverloads/multipleDefaultParameters.kt | 2 ++ .../jvmOverloads/nonDefaultParameter.kt | 2 ++ .../jvmOverloads/primaryConstructor.kt | 2 ++ .../jvmOverloads/secondaryConstructor.kt | 2 ++ .../codegen/boxWithStdlib/jvmOverloads/simple.kt | 2 ++ .../codegen/boxWithStdlib/jvmStatic/closure.kt | 4 +++- .../codegen/boxWithStdlib/jvmStatic/convention.kt | 4 +++- .../codegen/boxWithStdlib/jvmStatic/default.kt | 4 +++- .../boxWithStdlib/jvmStatic/explicitObject.kt | 4 +++- .../codegen/boxWithStdlib/jvmStatic/funAccess.kt | 2 ++ .../jvmStatic/importStaticMemberFromObject.kt | 4 +++- .../codegen/boxWithStdlib/jvmStatic/inline.kt | 4 +++- .../boxWithStdlib/jvmStatic/kt9897_static.kt | 4 +++- .../codegen/boxWithStdlib/jvmStatic/postfixInc.kt | 4 +++- .../codegen/boxWithStdlib/jvmStatic/prefixInc.kt | 4 +++- .../boxWithStdlib/jvmStatic/privateMethod.kt | 4 +++- .../boxWithStdlib/jvmStatic/propertyAccess.kt | 4 +++- .../boxWithStdlib/jvmStatic/propertyAsDefault.kt | 4 +++- .../codegen/boxWithStdlib/jvmStatic/simple.kt | 4 +++- .../boxWithStdlib/jvmStatic/syntheticAccessor.kt | 4 +++- .../localFunInLambda/definedWithinLambda.kt | 2 ++ .../definedWithinLambdaInnerUsage1.kt | 2 ++ .../definedWithinLambdaInnerUsage2.kt | 2 ++ .../boxWithStdlib/localFunInLambda/simple.kt | 2 ++ .../codegen/boxWithStdlib/mangling/field.kt | 4 +++- .../testData/codegen/boxWithStdlib/mangling/fun.kt | 4 +++- .../boxWithStdlib/multiDeclForArray/kt9828.kt | 4 +++- .../codegen/boxWithStdlib/nonLocalReturns/use.kt | 2 ++ .../nonLocalReturns/useWithException.kt | 4 +++- .../postfixIncrementDecrement/memberExtOnLong.kt | 4 +++- .../postfixIncrementDecrement/mutableListElement.kt | 4 +++- .../boxWithStdlib/privateConstructor/synthetic.kt | 2 ++ .../boxWithStdlib/ranges/expression/emptyDownto.kt | 2 ++ .../boxWithStdlib/ranges/expression/emptyRange.kt | 2 ++ .../ranges/expression/inexactDownToMinValue.kt | 2 ++ .../ranges/expression/inexactSteppedDownTo.kt | 2 ++ .../ranges/expression/inexactSteppedRange.kt | 2 ++ .../ranges/expression/inexactToMaxValue.kt | 2 ++ .../ranges/expression/maxValueMinusTwoToMaxValue.kt | 2 ++ .../ranges/expression/maxValueToMaxValue.kt | 2 ++ .../ranges/expression/maxValueToMinValue.kt | 2 ++ .../ranges/expression/oneElementDownTo.kt | 2 ++ .../ranges/expression/oneElementRange.kt | 2 ++ .../boxWithStdlib/ranges/expression/openRange.kt | 2 ++ .../ranges/expression/progressionDownToMinValue.kt | 2 ++ .../progressionMaxValueMinusTwoToMaxValue.kt | 2 ++ .../expression/progressionMaxValueToMaxValue.kt | 2 ++ .../expression/progressionMaxValueToMinValue.kt | 2 ++ .../expression/progressionMinValueToMinValue.kt | 2 ++ .../ranges/expression/reversedBackSequence.kt | 2 ++ .../ranges/expression/reversedEmptyBackSequence.kt | 2 ++ .../ranges/expression/reversedEmptyRange.kt | 2 ++ .../expression/reversedInexactSteppedDownTo.kt | 2 ++ .../ranges/expression/reversedRange.kt | 2 ++ .../ranges/expression/reversedSimpleSteppedRange.kt | 2 ++ .../boxWithStdlib/ranges/expression/simpleDownTo.kt | 2 ++ .../boxWithStdlib/ranges/expression/simpleRange.kt | 2 ++ .../expression/simpleRangeWithNonConstantEnds.kt | 2 ++ .../ranges/expression/simpleSteppedDownTo.kt | 2 ++ .../ranges/expression/simpleSteppedRange.kt | 2 ++ .../ranges/forByteProgressionWithIntIncrement.kt | 2 ++ .../codegen/boxWithStdlib/ranges/forIntRange.kt | 2 ++ .../boxWithStdlib/ranges/literal/emptyDownto.kt | 2 ++ .../boxWithStdlib/ranges/literal/emptyRange.kt | 2 ++ .../ranges/literal/inexactDownToMinValue.kt | 2 ++ .../ranges/literal/inexactSteppedDownTo.kt | 2 ++ .../ranges/literal/inexactSteppedRange.kt | 2 ++ .../ranges/literal/inexactToMaxValue.kt | 2 ++ .../ranges/literal/maxValueMinusTwoToMaxValue.kt | 2 ++ .../ranges/literal/maxValueToMaxValue.kt | 2 ++ .../ranges/literal/maxValueToMinValue.kt | 2 ++ .../ranges/literal/oneElementDownTo.kt | 2 ++ .../boxWithStdlib/ranges/literal/oneElementRange.kt | 2 ++ .../boxWithStdlib/ranges/literal/openRange.kt | 2 ++ .../ranges/literal/progressionDownToMinValue.kt | 2 ++ .../progressionMaxValueMinusTwoToMaxValue.kt | 2 ++ .../ranges/literal/progressionMaxValueToMaxValue.kt | 2 ++ .../ranges/literal/progressionMaxValueToMinValue.kt | 2 ++ .../ranges/literal/progressionMinValueToMinValue.kt | 2 ++ .../ranges/literal/reversedBackSequence.kt | 2 ++ .../ranges/literal/reversedEmptyBackSequence.kt | 2 ++ .../ranges/literal/reversedEmptyRange.kt | 2 ++ .../ranges/literal/reversedInexactSteppedDownTo.kt | 2 ++ .../boxWithStdlib/ranges/literal/reversedRange.kt | 2 ++ .../ranges/literal/reversedSimpleSteppedRange.kt | 2 ++ .../boxWithStdlib/ranges/literal/simpleDownTo.kt | 2 ++ .../boxWithStdlib/ranges/literal/simpleRange.kt | 2 ++ .../literal/simpleRangeWithNonConstantEnds.kt | 2 ++ .../ranges/literal/simpleSteppedDownTo.kt | 2 ++ .../ranges/literal/simpleSteppedRange.kt | 2 ++ .../ranges/multiAssignmentIterationOverIntRange.kt | 2 ++ .../codegen/boxWithStdlib/ranges/safeCallRangeTo.kt | 4 +++- .../annotations/annotationRetentionAnnotation.kt | 2 ++ .../reflection/annotations/propertyAccessors.kt | 2 ++ .../annotations/propertyWithoutBackingField.kt | 2 ++ .../reflection/annotations/retentions.kt | 2 ++ .../reflection/annotations/simpleClassAnnotation.kt | 2 ++ .../annotations/simpleConstructorAnnotation.kt | 2 ++ .../reflection/annotations/simpleFunAnnotation.kt | 2 ++ .../reflection/annotations/simpleParamAnnotation.kt | 2 ++ .../reflection/annotations/simpleValAnnotation.kt | 2 ++ .../reflection/call/cannotCallEnumConstructor.kt | 2 ++ .../call/disallowNullValueForNotNullField.kt | 2 ++ .../reflection/call/equalsHashCodeToString.kt | 2 ++ .../reflection/call/exceptionHappened.kt | 1 + .../boxWithStdlib/reflection/call/fakeOverride.kt | 2 ++ .../reflection/call/fakeOverrideSubstituted.kt | 2 ++ .../reflection/call/incorrectNumberOfArguments.kt | 2 ++ .../reflection/call/innerClassConstructor.kt | 2 ++ .../boxWithStdlib/reflection/call/jvmStatic.kt | 2 ++ .../call/jvmStaticInObjectIncorrectReceiver.kt | 2 ++ .../reflection/call/localClassMember.kt | 2 ++ .../reflection/call/memberOfGenericClass.kt | 2 ++ .../reflection/call/privateProperty.kt | 2 ++ .../reflection/call/propertyAccessors.kt | 2 ++ .../boxWithStdlib/reflection/call/returnUnit.kt | 2 ++ .../reflection/call/simpleConstructor.kt | 2 ++ .../reflection/call/simpleMemberFunction.kt | 2 ++ .../reflection/call/simpleTopLevelFunctions.kt | 2 ++ .../callBy/defaultAndNonDefaultIntertwined.kt | 2 ++ .../reflection/callBy/extensionFunction.kt | 2 ++ .../reflection/callBy/jvmStaticInObject.kt | 2 ++ .../callBy/manyArgumentsOnlyOneDefault.kt | 2 ++ .../reflection/callBy/manyMaskArguments.kt | 2 ++ .../reflection/callBy/nonDefaultParameterOmitted.kt | 2 ++ .../boxWithStdlib/reflection/callBy/nullValue.kt | 2 ++ ...naryMethodIsInvokedWhenNoDefaultValuesAreUsed.kt | 1 + .../reflection/callBy/primitiveDefaultValues.kt | 2 ++ .../reflection/callBy/privateMemberFunction.kt | 2 ++ .../reflection/callBy/simpleConstructor.kt | 2 ++ .../reflection/callBy/simpleMemberFunciton.kt | 2 ++ .../reflection/callBy/simpleTopLevelFunction.kt | 2 ++ .../classLiterals/annotationClassLiteral.kt | 4 +++- .../reflection/classLiterals/arrays.kt | 2 ++ .../classLiterals/builtinClassLiterals.kt | 2 ++ .../reflection/classLiterals/genericArrays.kt | 4 +++- .../reflection/classLiterals/genericClass.kt | 2 ++ .../classLiterals/reifiedTypeClassLiteral.kt | 2 ++ .../reflection/classLiterals/simpleClassLiteral.kt | 2 ++ .../reflection/classes/classSimpleName.kt | 2 ++ .../reflection/classes/companionObject.kt | 2 ++ .../boxWithStdlib/reflection/classes/defaultType.kt | 2 ++ .../boxWithStdlib/reflection/classes/jvmName.kt | 2 ++ .../reflection/classes/localClassSimpleName.kt | 2 ++ .../reflection/classes/nestedClasses.kt | 1 + .../reflection/classes/objectInstance.kt | 2 ++ .../reflection/classes/qualifiedName.kt | 2 ++ .../constructors/classesWithoutConstructors.kt | 2 ++ .../reflection/constructors/constructorName.kt | 2 ++ .../reflection/constructors/primaryConstructor.kt | 2 ++ .../constructors/simpleGetConstructors.kt | 2 ++ .../enclosing/anonymousObjectInInlinedLambda.kt | 2 ++ .../reflection/enclosing/classInLambda.kt | 2 ++ .../enclosing/functionExpressionInProperty.kt | 4 +++- .../boxWithStdlib/reflection/enclosing/kt6368.kt | 2 ++ .../enclosing/kt6691_lambdaInSamConstructor.kt | 2 ++ .../reflection/enclosing/lambdaInClassObject.kt | 2 ++ .../reflection/enclosing/lambdaInConstructor.kt | 4 +++- .../reflection/enclosing/lambdaInFunction.kt | 2 ++ .../reflection/enclosing/lambdaInLambda.kt | 4 +++- .../enclosing/lambdaInLocalClassConstructor.kt | 2 ++ .../enclosing/lambdaInLocalClassSuperCall.kt | 2 ++ .../reflection/enclosing/lambdaInLocalFunction.kt | 4 +++- .../reflection/enclosing/lambdaInMemberFunction.kt | 4 +++- .../enclosing/lambdaInMemberFunctionInLocalClass.kt | 4 +++- .../lambdaInMemberFunctionInNestedClass.kt | 4 +++- .../enclosing/lambdaInObjectDeclaration.kt | 2 ++ .../enclosing/lambdaInObjectExpression.kt | 2 ++ .../enclosing/lambdaInObjectLiteralSuperCall.kt | 2 ++ .../reflection/enclosing/lambdaInPackage.kt | 2 ++ .../reflection/enclosing/lambdaInPropertyGetter.kt | 2 ++ .../reflection/enclosing/lambdaInPropertySetter.kt | 2 ++ .../enclosing/localClassInTopLevelFunction.kt | 1 + .../reflection/enclosing/objectInLambda.kt | 2 ++ .../reflection/functions/functionFromStdlib.kt | 4 +++- .../reflection/functions/platformName.kt | 2 ++ .../reflection/functions/privateMemberFunction.kt | 2 ++ .../reflection/functions/simpleGetFunctions.kt | 2 ++ .../reflection/functions/simpleNames.kt | 2 ++ .../genericSignature/covariantOverride.kt | 2 ++ .../genericBackingFieldSignature.kt | 1 + .../genericSignature/genericMethodSignature.kt | 2 ++ .../reflection/genericSignature/kt11121.kt | 4 +++- .../reflection/genericSignature/kt5112.kt | 4 +++- .../reflection/genericSignature/kt6106.kt | 2 ++ .../boxWithStdlib/reflection/javaProperties/java.kt | 2 ++ .../reflection/javaProperties/javaObjectType.kt | 2 ++ .../javaProperties/javaObjectTypeReified.kt | 2 ++ .../reflection/javaProperties/javaPrimitiveType.kt | 2 ++ .../javaProperties/javaPrimitiveTypeReified.kt | 2 ++ .../reflection/javaProperties/javaReified.kt | 2 ++ .../reflection/kClassInAnnotation/array.kt | 2 ++ .../reflection/kClassInAnnotation/basic.kt | 2 ++ .../reflection/kClassInAnnotation/checkcast.kt | 2 ++ .../reflection/kClassInAnnotation/vararg.kt | 2 ++ .../lambdaClasses/parameterNamesAndNullability.kt | 2 ++ .../boxWithStdlib/reflection/mapping/constructor.kt | 2 ++ .../reflection/mapping/extensionProperty.kt | 2 ++ .../mapping/fakeOverrides/javaFieldGetterSetter.kt | 1 + .../reflection/mapping/fakeOverrides/javaMethod.kt | 2 ++ .../boxWithStdlib/reflection/mapping/functions.kt | 2 ++ .../mapping/jvmStatic/companionObjectFunction.kt | 2 ++ .../reflection/mapping/jvmStatic/objectFunction.kt | 2 ++ .../mapping/mappedClassIsEqualToClassLiteral.kt | 2 ++ .../reflection/mapping/memberProperty.kt | 2 ++ .../reflection/mapping/propertyAccessors.kt | 2 ++ .../mapping/propertyAccessorsWithJvmName.kt | 2 ++ .../reflection/mapping/syntheticFields.kt | 2 ++ .../reflection/mapping/topLevelProperty.kt | 2 ++ .../boxWithStdlib/reflection/mapping/types/array.kt | 1 + .../reflection/mapping/types/constructors.kt | 2 ++ .../reflection/mapping/types/memberFunctions.kt | 2 ++ .../mapping/types/overrideAnyWithPrimitive.kt | 2 ++ .../reflection/mapping/types/parameterizedTypes.kt | 1 + .../reflection/mapping/types/propertyAccessors.kt | 2 ++ .../reflection/mapping/types/topLevelFunctions.kt | 2 ++ .../reflection/mapping/types/typeParameters.kt | 1 + .../boxWithStdlib/reflection/mapping/types/unit.kt | 2 ++ .../callableReferencesEqualToCallablesFromAPI.kt | 2 ++ .../reflection/methodsFromAny/classToString.kt | 2 ++ .../extensionPropertyReceiverToString.kt | 2 ++ .../methodsFromAny/functionEqualsHashCode.kt | 2 ++ .../reflection/methodsFromAny/functionToString.kt | 2 ++ .../methodsFromAny/memberExtensionToString.kt | 2 ++ .../methodsFromAny/parametersEqualsHashCode.kt | 2 ++ .../reflection/methodsFromAny/parametersToString.kt | 2 ++ .../methodsFromAny/propertyEqualsHashCode.kt | 2 ++ .../reflection/methodsFromAny/propertyToString.kt | 2 ++ .../reflection/methodsFromAny/typeEqualsHashCode.kt | 2 ++ .../reflection/methodsFromAny/typeToString.kt | 2 ++ .../parameters/functionParameterNameAndIndex.kt | 2 ++ .../reflection/parameters/isMarkedNullable.kt | 2 ++ .../reflection/parameters/isOptional.kt | 2 ++ .../boxWithStdlib/reflection/parameters/kinds.kt | 2 ++ .../reflection/parameters/propertySetter.kt | 2 ++ .../properties/accessors/accessorNames.kt | 2 ++ .../accessors/extensionPropertyAccessors.kt | 2 ++ .../properties/accessors/memberExtensions.kt | 2 ++ .../properties/accessors/memberPropertyAccessors.kt | 2 ++ .../accessors/topLevelPropertyAccessors.kt | 2 ++ .../reflection/properties/allVsDeclared.kt | 2 ++ .../callPrivatePropertyFromGetProperties.kt | 2 ++ .../properties/fakeOverridesInSubclass.kt | 2 ++ .../genericClassLiteralPropertyReceiverIsStar.kt | 2 ++ .../getExtensionPropertiesMutableVsReadonly.kt | 2 ++ .../properties/getPropertiesMutableVsReadonly.kt | 2 ++ .../reflection/properties/invokeKProperty.kt | 2 ++ .../memberAndMemberExtensionWithSameName.kt | 2 ++ .../reflection/properties/privateClassVal.kt | 2 ++ .../reflection/properties/privateClassVar.kt | 2 ++ .../properties/privateFakeOverrideFromSuperclass.kt | 2 ++ .../properties/privateJvmStaticVarInObject.kt | 2 ++ .../privatePropertyCallIsAccessibleOnAccessors.kt | 2 ++ .../reflection/properties/privateToThisAccessors.kt | 2 ++ .../properties/propertyOfNestedClassAndArrayType.kt | 2 ++ .../reflection/properties/protectedClassVar.kt | 2 ++ .../properties/publicClassValAccessible.kt | 2 ++ .../reflection/properties/simpleGetProperties.kt | 2 ++ .../getMembersOfStandardJavaClasses.kt | 1 + .../codegen/boxWithStdlib/regressions/Kt1149.kt | 2 ++ .../codegen/boxWithStdlib/regressions/Kt1619Test.kt | 3 ++- .../codegen/boxWithStdlib/regressions/Kt2495Test.kt | 4 +++- .../codegen/boxWithStdlib/regressions/generic.kt | 2 ++ .../regressions/getGenericInterfaces.kt | 1 + .../codegen/boxWithStdlib/regressions/kt1172.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt1568.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt1779.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt1800.kt | 1 + .../codegen/boxWithStdlib/regressions/kt1932.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt2017.kt | 4 +++- .../codegen/boxWithStdlib/regressions/kt2246.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt2318.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt2593.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt3046.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt344.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt3442.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt4259.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt4262.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt5056.kt | 2 ++ .../regressions/kt5786_privateWithDefault.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt5953.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt6434.kt | 4 +++- .../codegen/boxWithStdlib/regressions/kt6434_2.kt | 4 +++- .../codegen/boxWithStdlib/regressions/kt715.kt | 2 ++ .../codegen/boxWithStdlib/regressions/kt998.kt | 2 ++ .../objectCaptureOuterConstructorProperty.kt | 2 ++ .../regressions/referenceToSelfInLocal.kt | 1 + .../boxWithStdlib/regressions/typeCastException.kt | 2 ++ .../codegen/boxWithStdlib/reified/DIExample.kt | 2 ++ .../boxWithStdlib/reified/anonymousObject.kt | 2 ++ .../reified/anonymousObjectNoPropagate.kt | 2 ++ .../reified/anonymousObjectReifiedSupertype.kt | 2 ++ .../reified/approximateCapturedTypes.kt | 1 + .../reified/arraysReification/instanceOf.kt | 2 ++ .../reified/arraysReification/instanceOfArrays.kt | 2 ++ .../reified/arraysReification/jClass.kt | 2 ++ .../reified/arraysReification/jaggedArrayOfNulls.kt | 2 ++ .../codegen/boxWithStdlib/reified/checkcast.kt | 2 ++ .../codegen/boxWithStdlib/reified/copyToArray.kt | 2 ++ .../boxWithStdlib/reified/defaultJavaClass.kt | 2 ++ .../boxWithStdlib/reified/filterIsInstance.kt | 2 ++ .../boxWithStdlib/reified/innerAnonymousObject.kt | 2 ++ .../codegen/boxWithStdlib/reified/instanceof.kt | 2 ++ .../codegen/boxWithStdlib/reified/javaClass.kt | 2 ++ .../codegen/boxWithStdlib/reified/nestedReified.kt | 2 ++ .../boxWithStdlib/reified/nestedReifiedSignature.kt | 2 ++ .../codegen/boxWithStdlib/reified/newArrayInt.kt | 1 + .../reified/nonInlineableLambdaInReifiedFunction.kt | 2 ++ .../reified/recursiveInnerAnonymousObject.kt | 2 ++ .../boxWithStdlib/reified/recursiveNewArray.kt | 1 + .../reified/recursiveNonInlineableLambda.kt | 2 ++ .../reified/reifiedInlineFunOfObject.kt | 2 ++ .../reifiedInlineFunOfObjectWithinReified.kt | 2 ++ .../reified/reifiedInlineIntoNonInlineableLambda.kt | 2 ++ .../codegen/boxWithStdlib/reified/safecast.kt | 2 ++ .../boxWithStdlib/reified/sameIndexRecursive.kt | 1 + .../codegen/boxWithStdlib/reified/spreads.kt | 2 ++ .../codegen/boxWithStdlib/reified/varargs.kt | 2 ++ .../storeStackBeforeInline/differentTypes.kt | 2 ++ .../storeStackBeforeInline/primitiveMerge.kt | 2 ++ .../boxWithStdlib/storeStackBeforeInline/simple.kt | 2 ++ .../storeStackBeforeInline/unreachableMarker.kt | 2 ++ .../storeStackBeforeInline/withLambda.kt | 2 ++ .../codegen/boxWithStdlib/strings/forInString.kt | 2 ++ .../strings/stringPlusOnlyWorksOnString.kt | 2 ++ .../synthetic/syntheticAccessorNames.kt | 1 + .../codegen/boxWithStdlib/toArray/copyToArray.kt | 4 +++- .../boxWithStdlib/toArray/kt3177-copyToArray.kt | 2 ++ .../boxWithStdlib/toArray/returnCopyToArray.kt | 4 +++- .../codegen/boxWithStdlib/toArray/toArray.kt | 4 +++- .../boxWithStdlib/toArray/toArrayAlreadyPresent.kt | 4 +++- .../noPrivateNoAccessorsInMultiFileFacade.kt | 4 +++- .../noPrivateNoAccessorsInMultiFileFacade2.kt | 4 +++- .../topLevelPrivate/syntheticAccessorInMultiFile.kt | 4 +++- .../typeMapping/genericTypeWithNothing.kt | 2 ++ .../typeMapping/typeParameterMultipleBounds.kt | 2 ++ .../boxWithStdlib/vararg/spreadCopiesArray.kt | 4 +++- .../when/integralWhenWithNoInlinedConstants.kt | 2 ++ .../testData/codegen/boxWithStdlib/when/kt5448.kt | 4 +++- .../boxWithStdlib/when/switchOptimizationDense.kt | 3 ++- .../when/switchOptimizationMultipleConditions.kt | 2 ++ .../boxWithStdlib/when/switchOptimizationSparse.kt | 3 ++- .../when/switchOptimizationStatement.kt | 3 ++- .../boxWithStdlib/when/switchOptimizationTypes.kt | 4 ++-- .../when/switchOptimizationUnordered.kt | 4 +++- .../boxWithStdlib/whenEnumOptimization/bigEnum.kt | 2 ++ .../whenEnumOptimization/duplicatingItems.kt | 2 ++ .../whenEnumOptimization/enumInsideClassObject.kt | 2 ++ .../whenEnumOptimization/expression.kt | 2 ++ .../functionLiteralInTopLevel.kt | 2 -- .../whenEnumOptimization/manyWhensWithinClass.kt | 2 ++ .../whenEnumOptimization/nullability.kt | 2 ++ .../whenEnumOptimization/subjectAny.kt | 2 ++ .../whenEnumOptimization/withoutElse.kt | 2 ++ .../whenStringOptimization/duplicatingItems.kt | 3 ++- .../duplicatingItemsSameHashCode.kt | 2 ++ .../whenStringOptimization/expression.kt | 2 ++ .../whenStringOptimization/nullability.kt | 2 ++ .../whenStringOptimization/sameHashCode.kt | 2 ++ .../whenStringOptimization/statement.kt | 2 ++ .../kotlin/codegen/AbstractBlackBoxCodegenTest.java | 1 - .../codegen/BlackBoxCodegenTestGenerated.java | 6 ++++++ .../BlackBoxWithStdlibCodegenTestGenerated.java | 6 ------ .../tests/GenerateRangesCodegenTestData.java | 2 ++ 525 files changed, 1122 insertions(+), 164 deletions(-) create mode 100644 compiler/testData/codegen/box/callableReference/property/listOfStringsMapLength.kt delete mode 100644 compiler/testData/codegen/boxWithStdlib/callableReference/function/listOfStringsMapLength.kt diff --git a/compiler/testData/codegen/box/callableReference/property/listOfStringsMapLength.kt b/compiler/testData/codegen/box/callableReference/property/listOfStringsMapLength.kt new file mode 100644 index 00000000000..1a035732ad3 --- /dev/null +++ b/compiler/testData/codegen/box/callableReference/property/listOfStringsMapLength.kt @@ -0,0 +1,4 @@ +// WITH_RUNTIME + +fun box(): String = + if (listOf("abc", "de", "f").map(String::length) == listOf(3, 2, 1)) "OK" else "Fail" diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/annotatedEnumEntry.kt b/compiler/testData/codegen/boxWithStdlib/annotations/annotatedEnumEntry.kt index 9c6a5124c25..e151fb9bbb9 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/annotatedEnumEntry.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/annotatedEnumEntry.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // KT-5665 @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/annotatedLambda/funExpression.kt b/compiler/testData/codegen/boxWithStdlib/annotations/annotatedLambda/funExpression.kt index a4ec1cbc96c..662a410221b 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/annotatedLambda/funExpression.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/annotatedLambda/funExpression.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.lang.reflect.Method import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/annotatedLambda/lambda.kt b/compiler/testData/codegen/boxWithStdlib/annotations/annotatedLambda/lambda.kt index 13731d81f69..4a865ac1f3b 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/annotatedLambda/lambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/annotatedLambda/lambda.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.lang.reflect.Method import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/annotatedObjectLiteral.kt b/compiler/testData/codegen/boxWithStdlib/annotations/annotatedObjectLiteral.kt index 8716d50d5f9..ab4a2e91d58 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/annotatedObjectLiteral.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/annotatedObjectLiteral.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + annotation class Ann(val v: String = "???") @Ann open class My fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/annotationsOnDefault.kt b/compiler/testData/codegen/boxWithStdlib/annotations/annotationsOnDefault.kt index 05409aa4339..590352e65b4 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/annotationsOnDefault.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/annotationsOnDefault.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/defaultParameterValues.kt b/compiler/testData/codegen/boxWithStdlib/annotations/defaultParameterValues.kt index c80708d99d7..d276628211c 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/defaultParameterValues.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/defaultParameterValues.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.reflect.KClass @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/delegatedPropertySetter.kt b/compiler/testData/codegen/boxWithStdlib/annotations/delegatedPropertySetter.kt index b61821ab39a..4eabb21d853 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/delegatedPropertySetter.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/delegatedPropertySetter.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.reflect.KProperty @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/fileClassWithFileAnnotation.kt b/compiler/testData/codegen/boxWithStdlib/annotations/fileClassWithFileAnnotation.kt index 466e448f00b..2646a99bbd3 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/fileClassWithFileAnnotation.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/fileClassWithFileAnnotation.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @file:StringHolder("OK") @file:JvmName("FileClass") @@ -6,4 +8,4 @@ public annotation class StringHolder(val value: String) fun box(): String = - Class.forName("FileClass").getAnnotation(StringHolder::class.java)?.value ?: "null" \ No newline at end of file + Class.forName("FileClass").getAnnotation(StringHolder::class.java)?.value ?: "null" diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/kotlinPropertyFromClassObjectAsParameter.kt b/compiler/testData/codegen/boxWithStdlib/annotations/kotlinPropertyFromClassObjectAsParameter.kt index 40ec55908f5..881412499b7 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/kotlinPropertyFromClassObjectAsParameter.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/kotlinPropertyFromClassObjectAsParameter.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Ann(Foo.i, Foo.s, Foo.f, Foo.d, Foo.l, Foo.b, Foo.bool, Foo.c, Foo.str) class MyClass fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/kotlinTopLevelPropertyAsParameter.kt b/compiler/testData/codegen/boxWithStdlib/annotations/kotlinTopLevelPropertyAsParameter.kt index 8ca2212a0b1..8bc47db277e 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/kotlinTopLevelPropertyAsParameter.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/kotlinTopLevelPropertyAsParameter.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Ann(i, s, f, d, l, b, bool, c, str) class MyClass fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/kt10136.kt b/compiler/testData/codegen/boxWithStdlib/annotations/kt10136.kt index 69f88544ff7..f942250810c 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/kt10136.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/kt10136.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + annotation class A @Target(AnnotationTarget.CLASS) @@ -16,4 +18,4 @@ fun box(): String { assert(items[0] is A) { "Expected: [A()], got ${items.asList()}" } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/nestedClassPropertyAsParameter.kt b/compiler/testData/codegen/boxWithStdlib/annotations/nestedClassPropertyAsParameter.kt index 131c36e0ce2..3b0c913e475 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/nestedClassPropertyAsParameter.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/nestedClassPropertyAsParameter.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Ann(A.B.i) class MyClass fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/parameterWithPrimitiveType.kt b/compiler/testData/codegen/boxWithStdlib/annotations/parameterWithPrimitiveType.kt index 7bace72d726..a41c9a2d23e 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/parameterWithPrimitiveType.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/parameterWithPrimitiveType.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val b: Byte, diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/propertyWithPropertyInInitializerAsParameter.kt b/compiler/testData/codegen/boxWithStdlib/annotations/propertyWithPropertyInInitializerAsParameter.kt index 6fa352a6e27..ae6e747e1b8 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/propertyWithPropertyInInitializerAsParameter.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/propertyWithPropertyInInitializerAsParameter.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Ann(i) class MyClass fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/resolveWithLowPriorityAnnotation.kt b/compiler/testData/codegen/boxWithStdlib/annotations/resolveWithLowPriorityAnnotation.kt index c54cd584bbf..9b51c9fdb51 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/resolveWithLowPriorityAnnotation.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/resolveWithLowPriorityAnnotation.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE") @kotlin.internal.LowPriorityInOverloadResolution fun foo(i: Int) = 1 @@ -14,4 +16,4 @@ fun box(): String { if (foo(1) != 2) return "fail1" if (bar(null) != 3) return "fail2" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/annotations/varargInAnnotationParameter.kt b/compiler/testData/codegen/boxWithStdlib/annotations/varargInAnnotationParameter.kt index f315ff06420..c3affdc64ab 100644 --- a/compiler/testData/codegen/boxWithStdlib/annotations/varargInAnnotationParameter.kt +++ b/compiler/testData/codegen/boxWithStdlib/annotations/varargInAnnotationParameter.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann(vararg val p: Int) @@ -45,4 +47,4 @@ fun test(klass: Class<*>, expected: String) { if (result != expected) { throw AssertionError("fail: expected = ${expected}, actual = ${result}") } -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/arrayConstructorsSimple.kt b/compiler/testData/codegen/boxWithStdlib/arrays/arrayConstructorsSimple.kt index 87558b42c95..1c28cf17aa0 100644 --- a/compiler/testData/codegen/boxWithStdlib/arrays/arrayConstructorsSimple.kt +++ b/compiler/testData/codegen/boxWithStdlib/arrays/arrayConstructorsSimple.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun simpleIntArray(): Array = Array(3) { it } @@ -22,4 +24,3 @@ fun box(): String { return "OK" } - diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/inProjectionOfList.kt b/compiler/testData/codegen/boxWithStdlib/arrays/inProjectionOfList.kt index 148aebf6ca6..3a22c9124c9 100644 --- a/compiler/testData/codegen/boxWithStdlib/arrays/inProjectionOfList.kt +++ b/compiler/testData/codegen/boxWithStdlib/arrays/inProjectionOfList.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val x: Array> = arrayOf(listOf(1)) val y : Array> = x @@ -7,4 +9,4 @@ fun box(): String { y[0] = listOf("OK") return x[0][0] as String -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/indices.kt b/compiler/testData/codegen/boxWithStdlib/arrays/indices.kt index 332b5add5fa..65976591a77 100644 --- a/compiler/testData/codegen/boxWithStdlib/arrays/indices.kt +++ b/compiler/testData/codegen/boxWithStdlib/arrays/indices.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val a = Array(5, {it}) val x = a.indices.iterator() diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/indicesChar.kt b/compiler/testData/codegen/boxWithStdlib/arrays/indicesChar.kt index cd322a43478..5d3470e389d 100644 --- a/compiler/testData/codegen/boxWithStdlib/arrays/indicesChar.kt +++ b/compiler/testData/codegen/boxWithStdlib/arrays/indicesChar.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val a = CharArray(5) val x = a.indices.iterator() diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/kt602.kt b/compiler/testData/codegen/boxWithStdlib/arrays/kt602.kt index eb527f81d8a..6dc746cf37b 100644 --- a/compiler/testData/codegen/boxWithStdlib/arrays/kt602.kt +++ b/compiler/testData/codegen/boxWithStdlib/arrays/kt602.kt @@ -1,2 +1,3 @@ -fun box() = if(arrayOfNulls(10).isArrayOf()) "OK" else "fail" +// WITH_RUNTIME +fun box() = if(arrayOfNulls(10).isArrayOf()) "OK" else "fail" diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/kt7009.kt b/compiler/testData/codegen/boxWithStdlib/arrays/kt7009.kt index 6adbc2e7923..91cf7e4fa5b 100644 --- a/compiler/testData/codegen/boxWithStdlib/arrays/kt7009.kt +++ b/compiler/testData/codegen/boxWithStdlib/arrays/kt7009.kt @@ -1,4 +1,6 @@ +// WITH_RUNTIME + fun box() : String { val value = (1 to doubleArrayOf(1.0)).second[0] return if (value == 1.0) "OK" else "fail" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/kt7338.kt b/compiler/testData/codegen/boxWithStdlib/arrays/kt7338.kt index 040fa1dd9b9..580729defda 100644 --- a/compiler/testData/codegen/boxWithStdlib/arrays/kt7338.kt +++ b/compiler/testData/codegen/boxWithStdlib/arrays/kt7338.kt @@ -1,7 +1,9 @@ +// WITH_RUNTIME + fun foo(x : Any): String { return if(x is Array<*> && x.isArrayOf()) (x as Array)[0] else "fail" } fun box(): String { return foo(arrayOf("OK")) -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/multiArrayConstructors.kt b/compiler/testData/codegen/boxWithStdlib/arrays/multiArrayConstructors.kt index 28f422f0ab9..77663265456 100644 --- a/compiler/testData/codegen/boxWithStdlib/arrays/multiArrayConstructors.kt +++ b/compiler/testData/codegen/boxWithStdlib/arrays/multiArrayConstructors.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun stringMultiArray(): Array> = Array(3) { diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/casts.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/casts.kt index deda6a18570..47ce676892b 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/casts.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/casts.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/checkcastAndInstanceOf.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/checkcastAndInstanceOf.kt index 5654b449964..484926e5633 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/checkcastAndInstanceOf.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/checkcastAndInstanceOf.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/fold.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/fold.kt index c5867716d32..7bb1608458b 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/fold.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/fold.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/foldRange.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/foldRange.kt index 984591735ed..1127090af9e 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/foldRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/foldRange.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt5844.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt5844.kt index dd86d807e49..acc4da5c729 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt5844.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt5844.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun test1() { @@ -25,4 +27,3 @@ fun box(): String { test2() return "OK" } - diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt6047.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt6047.kt index e1d582770b3..93d9a22f60d 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt6047.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt6047.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun checkLongAB5E(x: Long) = assertEquals(0xAB5EL, x) diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt6842.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt6842.kt index 6e384506e69..e3162a626a3 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt6842.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/kt6842.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/nullCheck.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/nullCheck.kt index ef15a3b75e5..4ba74af4165 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/nullCheck.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/nullCheck.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/progressions.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/progressions.kt index f57685da01e..6892c12e89d 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/progressions.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/progressions.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME import kotlin.test.assertEquals @@ -30,4 +31,3 @@ fun box() : String { return "OK" } - diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/safeCallWithElvis.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/safeCallWithElvis.kt index e25a93221bd..1ffec309237 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/safeCallWithElvis.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/safeCallWithElvis.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/simple.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/simple.kt index 87df3f72ff1..fbe93a5233a 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/simple.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/simple.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun foo(x : R, block : (R) -> R) : R { diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/simpleUninitializedMerge.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/simpleUninitializedMerge.kt index ab73e3a2da7..9612abbe1bb 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/simpleUninitializedMerge.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/simpleUninitializedMerge.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/unsafeRemoving.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/unsafeRemoving.kt index a092f2fd64d..e11a594361d 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/unsafeRemoving.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/unsafeRemoving.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/variables.kt b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/variables.kt index 6f701ece55f..18f6bf3d71e 100644 --- a/compiler/testData/codegen/boxWithStdlib/boxingOptimization/variables.kt +++ b/compiler/testData/codegen/boxWithStdlib/boxingOptimization/variables.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/callableReference/function/getArityViaFunctionImpl.kt b/compiler/testData/codegen/boxWithStdlib/callableReference/function/getArityViaFunctionImpl.kt index e89b5abb45a..f22fe88ff23 100644 --- a/compiler/testData/codegen/boxWithStdlib/callableReference/function/getArityViaFunctionImpl.kt +++ b/compiler/testData/codegen/boxWithStdlib/callableReference/function/getArityViaFunctionImpl.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals import kotlin.jvm.internal.FunctionImpl diff --git a/compiler/testData/codegen/boxWithStdlib/callableReference/function/listOfStringsMapLength.kt b/compiler/testData/codegen/boxWithStdlib/callableReference/function/listOfStringsMapLength.kt deleted file mode 100644 index 060cdb78c15..00000000000 --- a/compiler/testData/codegen/boxWithStdlib/callableReference/function/listOfStringsMapLength.kt +++ /dev/null @@ -1,2 +0,0 @@ -fun box(): String = - if (listOf("abc", "de", "f").map(String::length.getter) == listOf(3, 2, 1)) "OK" else "Fail" diff --git a/compiler/testData/codegen/boxWithStdlib/casts/asFunKBig.kt b/compiler/testData/codegen/boxWithStdlib/casts/asFunKBig.kt index 4799c108a6a..76713f7bfd1 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/asFunKBig.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/asFunKBig.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // This is a big, ugly, semi-auto generated test. // Use corresponding 'Small' test for debug. @@ -247,4 +248,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/asWithGeneric.kt b/compiler/testData/codegen/boxWithStdlib/casts/asWithGeneric.kt index 5de4210c9a1..f4d6984a4ca 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/asWithGeneric.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/asWithGeneric.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun test1() = null as T fun test2(): T { val a : Any? = null diff --git a/compiler/testData/codegen/boxWithStdlib/casts/asWithMutable.kt b/compiler/testData/codegen/boxWithStdlib/casts/asWithMutable.kt index 019c275fb73..699db8abfd5 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/asWithMutable.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/asWithMutable.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.* class Itr : Iterator by ArrayList().iterator() @@ -123,4 +125,4 @@ fun box(): String { asSucceeds("hashMapEntry as MutableMap.MutableEntry") { hashMapEntry as MutableMap.MutableEntry<*, *> } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/isFunKBig.kt b/compiler/testData/codegen/boxWithStdlib/casts/isFunKBig.kt index 939ac15626a..b5fa07547d2 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/isFunKBig.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/isFunKBig.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // This is a big, ugly, semi-auto generated test. // Use corresponding 'Small' test for debug. @@ -174,4 +175,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/isFunKSmall.kt b/compiler/testData/codegen/boxWithStdlib/casts/isFunKSmall.kt index b6545373f4b..87d0d50b7bb 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/isFunKSmall.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/isFunKSmall.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun fn0() {} fun fn1(x: Any) {} @@ -52,4 +54,4 @@ fun box(): String { assert(afoo is Function1<*, *>) { "afoo is Function1<*, *>" } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/isWithMutable.kt b/compiler/testData/codegen/boxWithStdlib/casts/isWithMutable.kt index ea419f776ce..0c868c37cf1 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/isWithMutable.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/isWithMutable.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.* class Itr : Iterator by ArrayList().iterator() @@ -106,4 +108,4 @@ fun box(): String { assert((mlist as Any) !is MutableIterator<*>) { "ML !is MutableIterator" } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/reifiedAsFunKBig.kt b/compiler/testData/codegen/boxWithStdlib/casts/reifiedAsFunKBig.kt index 133e8063c88..37798e8b640 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/reifiedAsFunKBig.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/reifiedAsFunKBig.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // This is a big, ugly, semi-auto generated test. // Use corresponding 'Small' test for debug. @@ -270,4 +271,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/reifiedAsWithMutable.kt b/compiler/testData/codegen/boxWithStdlib/casts/reifiedAsWithMutable.kt index 4e139c40f2e..2fa33e37ecf 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/reifiedAsWithMutable.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/reifiedAsWithMutable.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.* class Itr : Iterator by ArrayList().iterator() @@ -125,4 +127,4 @@ fun box(): String { reifiedAsSucceeds>(hashMapEntry, "reifiedAs>(hashMapEntry)") return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsFunKBig.kt b/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsFunKBig.kt index ec9872c7620..7ef564df42c 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsFunKBig.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsFunKBig.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // This is a big, ugly, semi-auto generated test. // Use corresponding 'Small' test for debug. @@ -188,4 +189,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsFunKSmall.kt b/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsFunKSmall.kt index cf85d18a8c8..2743c975bdb 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsFunKSmall.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsFunKSmall.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun fn0() {} fun fn1(x: Any) {} @@ -33,4 +35,4 @@ fun box(): String { assertReifiedIsNot>(f0, "Function1<*, *>") return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsWithMutable.kt b/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsWithMutable.kt index 09fc60ab169..350848e4d20 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsWithMutable.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/reifiedIsWithMutable.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.* class Itr : Iterator by ArrayList().iterator() @@ -106,4 +108,4 @@ fun box(): String { assert(reifiedIs>(hashMapEntry)) { "reifiedIs>(hashMapEntry)"} return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/reifiedSafeAsWithMutable.kt b/compiler/testData/codegen/boxWithStdlib/casts/reifiedSafeAsWithMutable.kt index 458d7cea01b..ec1ac3d0d88 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/reifiedSafeAsWithMutable.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/reifiedSafeAsWithMutable.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.* class Itr : Iterator by ArrayList().iterator() @@ -136,4 +138,4 @@ fun box(): String { reifiedSafeAsReturnsNull>(null, "reifiedSafeAs>(null)") return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/safeAsFunKBig.kt b/compiler/testData/codegen/boxWithStdlib/casts/safeAsFunKBig.kt index fb6ed2f26d6..5fe99f4d3aa 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/safeAsFunKBig.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/safeAsFunKBig.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // This is a big, ugly, semi-auto generated test. // Use corresponding 'Small' test for debug. @@ -324,4 +325,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/safeAsFunKSmall.kt b/compiler/testData/codegen/boxWithStdlib/casts/safeAsFunKSmall.kt index 4f922b04e83..a93d8355ce6 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/safeAsFunKSmall.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/safeAsFunKSmall.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun fn0() {} fun fn1(x: Any) {} @@ -31,4 +33,4 @@ fun box(): String { safeAsReturnsNonNull("f1 as? Function1<*, *>") { f1 as? Function1<*, *> } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/safeAsWithMutable.kt b/compiler/testData/codegen/boxWithStdlib/casts/safeAsWithMutable.kt index 641a29afb26..96b47c3b851 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/safeAsWithMutable.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/safeAsWithMutable.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.* class Itr : Iterator by ArrayList().iterator() @@ -134,4 +136,4 @@ fun box(): String { safeAsReturnsNull("mlist as? MutableIterator") { mlist as? MutableIterator<*> } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/casts/unitAsInt.kt b/compiler/testData/codegen/boxWithStdlib/casts/unitAsInt.kt index f702bcedd2a..476e6ad27f6 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/unitAsInt.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/unitAsInt.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun foo() {} fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/casts/weirdMutableCasts.kt b/compiler/testData/codegen/boxWithStdlib/casts/weirdMutableCasts.kt index 29917efac34..514e6f5c606 100644 --- a/compiler/testData/codegen/boxWithStdlib/casts/weirdMutableCasts.kt +++ b/compiler/testData/codegen/boxWithStdlib/casts/weirdMutableCasts.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun unsupported(): Nothing = throw UnsupportedOperationException() class Weird : Iterator, MutableIterable, MutableMap.MutableEntry { @@ -135,4 +137,4 @@ fun box(): String { reifiedSafeAsReturnsNonNull>(w, "reified w as? MutableMap.MutableEntry<*, *>") return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/classes/kt8011.kt b/compiler/testData/codegen/boxWithStdlib/classes/kt8011.kt index b98989525ea..e4ab453aa33 100644 --- a/compiler/testData/codegen/boxWithStdlib/classes/kt8011.kt +++ b/compiler/testData/codegen/boxWithStdlib/classes/kt8011.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun testFun1(str: String): String { val local = str @@ -14,4 +16,4 @@ fun box(): String { testFun1("test1") != "test1" -> "Fail #1" else -> "OK" } -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/classes/mutabilityMarkerInterfaces.kt b/compiler/testData/codegen/boxWithStdlib/classes/mutabilityMarkerInterfaces.kt index 958d8725927..09985577f68 100644 --- a/compiler/testData/codegen/boxWithStdlib/classes/mutabilityMarkerInterfaces.kt +++ b/compiler/testData/codegen/boxWithStdlib/classes/mutabilityMarkerInterfaces.kt @@ -1,4 +1,4 @@ -import kotlin.reflect.jvm.* +// WITH_RUNTIME abstract class Itr : Iterator abstract class MItr : MutableIterator @@ -54,4 +54,4 @@ fun box(): String { "java.util.List", "kotlin.jvm.internal.markers.KMutableList")) return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/const/constValInAnnotationDefault.kt b/compiler/testData/codegen/boxWithStdlib/const/constValInAnnotationDefault.kt index ae18c7a874a..43cc9d9e2f8 100644 --- a/compiler/testData/codegen/boxWithStdlib/const/constValInAnnotationDefault.kt +++ b/compiler/testData/codegen/boxWithStdlib/const/constValInAnnotationDefault.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + const val z = "OK" annotation class A(val value: String = z) @@ -7,4 +9,4 @@ class Test fun box(): String { return Test::class.java.getAnnotation(A::class.java).value -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/const/interfaceCompanion.kt b/compiler/testData/codegen/boxWithStdlib/const/interfaceCompanion.kt index 9b602a5a5e9..6e0781016c9 100644 --- a/compiler/testData/codegen/boxWithStdlib/const/interfaceCompanion.kt +++ b/compiler/testData/codegen/boxWithStdlib/const/interfaceCompanion.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + interface KInt { companion object { @@ -15,4 +17,4 @@ fun box(): String { if (b !== "ba") return "fail 2: 'ba' !== KInt.Companion.b" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/controlStructures/continueInExpr.kt b/compiler/testData/codegen/boxWithStdlib/controlStructures/continueInExpr.kt index f5d84f7340c..328f8efafec 100644 --- a/compiler/testData/codegen/boxWithStdlib/controlStructures/continueInExpr.kt +++ b/compiler/testData/codegen/boxWithStdlib/controlStructures/continueInExpr.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun concatNonNulls(strings: List): String { var result = "" for (str in strings) { @@ -11,4 +13,4 @@ fun box(): String { if (test != "abcdef") return "Failed: test=$test" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/dataClasses/equals/alreadyDeclaredWrongSignature.kt b/compiler/testData/codegen/boxWithStdlib/dataClasses/equals/alreadyDeclaredWrongSignature.kt index 81ab7817764..a3e9c6e18e4 100644 --- a/compiler/testData/codegen/boxWithStdlib/dataClasses/equals/alreadyDeclaredWrongSignature.kt +++ b/compiler/testData/codegen/boxWithStdlib/dataClasses/equals/alreadyDeclaredWrongSignature.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + data class B(val x: Int) { fun equals(other: B): Boolean = false } @@ -29,4 +31,4 @@ fun box(): String { E::class.java.getDeclaredMethod("equals", E::class.java) return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/dataClasses/hashcode/alreadyDeclaredWrongSignature.kt b/compiler/testData/codegen/boxWithStdlib/dataClasses/hashcode/alreadyDeclaredWrongSignature.kt index 1b2fe1b0301..03252d8762f 100644 --- a/compiler/testData/codegen/boxWithStdlib/dataClasses/hashcode/alreadyDeclaredWrongSignature.kt +++ b/compiler/testData/codegen/boxWithStdlib/dataClasses/hashcode/alreadyDeclaredWrongSignature.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + data class A(val x: Int) { fun hashCode(other: Any): Int = 0 } @@ -14,4 +16,4 @@ fun box(): String { B::class.java.getDeclaredMethod("hashCode", B::class.java, Any::class.java) return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/dataClasses/tostring/alreadyDeclaredWrongSignature.kt b/compiler/testData/codegen/boxWithStdlib/dataClasses/tostring/alreadyDeclaredWrongSignature.kt index 2a080133ee3..3eefa862a87 100644 --- a/compiler/testData/codegen/boxWithStdlib/dataClasses/tostring/alreadyDeclaredWrongSignature.kt +++ b/compiler/testData/codegen/boxWithStdlib/dataClasses/tostring/alreadyDeclaredWrongSignature.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + data class A(val x: Int) { fun toString(other: Any): String = "" } @@ -14,4 +16,4 @@ fun box(): String { B::class.java.getDeclaredMethod("toString", B::class.java, Any::class.java) return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/deadCodeElimination/emptyVariableRange.kt b/compiler/testData/codegen/boxWithStdlib/deadCodeElimination/emptyVariableRange.kt index 2948d8b48a6..c162fbeec34 100644 --- a/compiler/testData/codegen/boxWithStdlib/deadCodeElimination/emptyVariableRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/deadCodeElimination/emptyVariableRange.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(): Int { diff --git a/compiler/testData/codegen/boxWithStdlib/defaultArguments/constructor/checkIfConstructorIsSynthetic.kt b/compiler/testData/codegen/boxWithStdlib/defaultArguments/constructor/checkIfConstructorIsSynthetic.kt index 8c9402d7595..1e85e23d713 100644 --- a/compiler/testData/codegen/boxWithStdlib/defaultArguments/constructor/checkIfConstructorIsSynthetic.kt +++ b/compiler/testData/codegen/boxWithStdlib/defaultArguments/constructor/checkIfConstructorIsSynthetic.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class A(value: Int = 1) fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/defaultArguments/constructor/manyArgs.kt b/compiler/testData/codegen/boxWithStdlib/defaultArguments/constructor/manyArgs.kt index 855e303069b..ff98ae1f354 100644 --- a/compiler/testData/codegen/boxWithStdlib/defaultArguments/constructor/manyArgs.kt +++ b/compiler/testData/codegen/boxWithStdlib/defaultArguments/constructor/manyArgs.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class A(val a: Int = 1, val b: Int = 2, val c: Int = 3, diff --git a/compiler/testData/codegen/boxWithStdlib/defaultArguments/kt6382.kt b/compiler/testData/codegen/boxWithStdlib/defaultArguments/kt6382.kt index ae0bbc1f044..07910e2cf12 100644 --- a/compiler/testData/codegen/boxWithStdlib/defaultArguments/kt6382.kt +++ b/compiler/testData/codegen/boxWithStdlib/defaultArguments/kt6382.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { return if (A().run() == "Aabc") "OK" else "fail" } @@ -11,4 +13,4 @@ public class A { private fun String.show(p: Boolean = false): String = getName() + this private fun getName() = "A" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/defaultArguments/superCallCheck.kt b/compiler/testData/codegen/boxWithStdlib/defaultArguments/superCallCheck.kt index 39beae3d570..0b1521ccbe8 100644 --- a/compiler/testData/codegen/boxWithStdlib/defaultArguments/superCallCheck.kt +++ b/compiler/testData/codegen/boxWithStdlib/defaultArguments/superCallCheck.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME fun def(i: Int = 0): Int { return i; diff --git a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/delegateWithPrivateSet.kt b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/delegateWithPrivateSet.kt index 35643b6cd0c..d44684bb4c8 100644 --- a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/delegateWithPrivateSet.kt +++ b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/delegateWithPrivateSet.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // See KT-10107: 'Variable must be initialized' for delegate with private set class My { @@ -10,4 +11,3 @@ class My { } fun box() = My().delegate - diff --git a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/kt6722.kt b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/kt6722.kt index 2760188b91a..f680293e6dc 100644 --- a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/kt6722.kt +++ b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/kt6722.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + interface T { } @@ -9,4 +11,4 @@ fun box(): String { } } return t.foo -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/kt9712.kt b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/kt9712.kt index 91bd849c646..dd4f6cf1945 100644 --- a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/kt9712.kt +++ b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/kt9712.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.properties.Delegates object X { @@ -19,4 +21,4 @@ class B : A() { } fun box(): String = - X.O + B().K \ No newline at end of file + X.O + B().K diff --git a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/protectedVarWithPrivateSet.kt b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/protectedVarWithPrivateSet.kt index 99cf9d50f03..76bb953d48f 100644 --- a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/protectedVarWithPrivateSet.kt +++ b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/protectedVarWithPrivateSet.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.properties.Delegates open class A { @@ -11,4 +13,4 @@ fun box(): String { B() return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/stackOverflowOnCallFromGetValue.kt b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/stackOverflowOnCallFromGetValue.kt index 3b577802838..e1a2d78a284 100644 --- a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/stackOverflowOnCallFromGetValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/stackOverflowOnCallFromGetValue.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK import java.lang.reflect.InvocationTargetException diff --git a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/useKPropertyLater.kt b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/useKPropertyLater.kt index 6d29f44bb08..48039e88e5b 100644 --- a/compiler/testData/codegen/boxWithStdlib/delegatedProperty/useKPropertyLater.kt +++ b/compiler/testData/codegen/boxWithStdlib/delegatedProperty/useKPropertyLater.kt @@ -1,3 +1,6 @@ +// WITH_REFLECT +// TODO: replace with WITH_RUNTIME once KT-11316 is fixed + import java.util.* import kotlin.reflect.* diff --git a/compiler/testData/codegen/boxWithStdlib/enum/sortEnumEntries.kt b/compiler/testData/codegen/boxWithStdlib/enum/sortEnumEntries.kt index 37745e71984..8b894a1ffe2 100644 --- a/compiler/testData/codegen/boxWithStdlib/enum/sortEnumEntries.kt +++ b/compiler/testData/codegen/boxWithStdlib/enum/sortEnumEntries.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import Game.* enum class Game { diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/char.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/char.kt index 4cd9ce832c6..b86ef1af2ca 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/char.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/char.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package test @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/divide.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/divide.kt index 9d7825ed6a8..7acca3d1f82 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/divide.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/divide.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val b: Byte, diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/intrincics.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/intrincics.kt index c5384e7921b..9fc8592cab4 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/intrincics.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/intrincics.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Int, @@ -26,4 +28,4 @@ fun box(): String { if (annotation.p5 != prop5) return "fail 5, expected = ${prop5}, actual = ${annotation.p5}" if (annotation.p6 != prop6) return "fail 6, expected = ${prop6}, actual = ${annotation.p6}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/kt9443.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/kt9443.kt index 89deaf48d00..9a8946a9e79 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/kt9443.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/kt9443.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + abstract class BaseClass { protected open val menuId: Int = 0 @@ -15,4 +17,4 @@ public fun box(): String { if (result != ("3" to false)) return "Fail: $result" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/maxValue.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/maxValue.kt index 5f436cfe39c..c1e55eacc01 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/maxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/maxValue.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Int, @@ -26,4 +28,4 @@ fun box(): String { if (annotation.p5 != 2147483648.toLong()) return "fail 5, expected = ${2147483648}, actual = ${annotation.p5}" if (annotation.p6 != java.lang.Long.MAX_VALUE + 1) return "fail 5, expected = ${java.lang.Long.MAX_VALUE + 1}, actual = ${annotation.p6}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/maxValueByte.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/maxValueByte.kt index dc01187b78b..7c8f85c720c 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/maxValueByte.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/maxValueByte.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Int, @@ -20,4 +22,4 @@ fun box(): String { if (annotation.p4 != 2) return "fail 4, expected = ${2}, actual = ${annotation.p4}" if (annotation.p5 != 2) return "fail 5, expected = ${2}, actual = ${annotation.p5}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/maxValueInt.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/maxValueInt.kt index 97d23e0468b..a6ff31de6ba 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/maxValueInt.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/maxValueInt.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Int, @@ -20,4 +22,4 @@ fun box(): String { if (annotation.p4 != 2.toLong()) return "fail 4, expected = ${2}, actual = ${annotation.p4}" if (annotation.p5 != 2) return "fail 5, expected = ${2}, actual = ${annotation.p5}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/miltiply.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/miltiply.kt index 9dedfded966..c3530695448 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/miltiply.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/miltiply.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Byte, @@ -26,4 +28,4 @@ fun box(): String { if (annotation.p5 != prop5) return "fail 5, expected = ${prop5}, actual = ${annotation.p5}" if (annotation.p6 != prop6) return "fail 6, expected = ${prop6}, actual = ${annotation.p6}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/minus.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/minus.kt index 8d2cbbdfd95..b69b459de4d 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/minus.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/minus.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Byte, @@ -26,4 +28,4 @@ fun box(): String { if (annotation.p5 != prop5) return "fail 5, expected = ${prop5}, actual = ${annotation.p5}" if (annotation.p6 != prop6) return "fail 6, expected = ${prop6}, actual = ${annotation.p6}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/mod.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/mod.kt index e3708a625a4..49773af074d 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/mod.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/mod.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Byte, @@ -26,4 +28,4 @@ fun box(): String { if (annotation.p5 != prop5) return "fail 5, expected = ${prop5}, actual = ${annotation.p5}" if (annotation.p6 != prop6) return "fail 6, expected = ${prop6}, actual = ${annotation.p6}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/paranthesized.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/paranthesized.kt index a06ddc82ef0..d09bc17dd08 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/paranthesized.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/paranthesized.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Byte, @@ -26,4 +28,4 @@ fun box(): String { if (annotation.p5 != prop5) return "fail 5, expected = ${prop5}, actual = ${annotation.p5}" if (annotation.p6 != prop6) return "fail 6, expected = ${prop6}, actual = ${annotation.p6}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/plus.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/plus.kt index e783c6d847a..48e1f5665ce 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/plus.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/plus.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Byte, @@ -26,4 +28,4 @@ fun box(): String { if (annotation.p5 != prop5) return "fail 5, expected = ${prop5}, actual = ${annotation.p5}" if (annotation.p6 != prop6) return "fail 6, expected = ${prop6}, actual = ${annotation.p6}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/simpleCallBinary.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/simpleCallBinary.kt index d9543370851..c283eae8775 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/simpleCallBinary.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/simpleCallBinary.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Int, diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/unaryMinus.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/unaryMinus.kt index 62d58fbe7b6..d835e8ed1e6 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/unaryMinus.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/unaryMinus.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Byte, diff --git a/compiler/testData/codegen/boxWithStdlib/evaluate/unaryPlus.kt b/compiler/testData/codegen/boxWithStdlib/evaluate/unaryPlus.kt index 2e85ba12957..4e897d12829 100644 --- a/compiler/testData/codegen/boxWithStdlib/evaluate/unaryPlus.kt +++ b/compiler/testData/codegen/boxWithStdlib/evaluate/unaryPlus.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @Retention(AnnotationRetention.RUNTIME) annotation class Ann( val p1: Byte, diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/constFlags.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/constFlags.kt index 9b799346055..7b10847459d 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/constFlags.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/constFlags.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK @file:JvmName("XYZ") diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/jvmAnnotationFlags.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/jvmAnnotationFlags.kt index b33b1978504..f41169b0e5d 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/jvmAnnotationFlags.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/jvmAnnotationFlags.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK import java.lang.reflect.Modifier diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/kt2423.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/kt2423.kt index d1de819df3b..33dc1075e78 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/kt2423.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/kt2423.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK import java.util.LinkedList diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/lateinitVisibility.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/lateinitVisibility.kt index 9b17ec24ff3..ebb8304f777 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/lateinitVisibility.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/lateinitVisibility.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK import java.lang.reflect.Modifier diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/native/default.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/native/default.kt index ef9209a1f7f..fedf9602fba 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/native/default.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/native/default.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK package foo diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/native/privateStatic.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/native/privateStatic.kt index fce9961ae83..bdcc4f65702 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/native/privateStatic.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/native/privateStatic.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK class C { diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/native/staticNative.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/native/staticNative.kt index 4c4d4d1f416..8f59a64e9df 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/native/staticNative.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/native/staticNative.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK package foo diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/collections.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/collections.kt index 0ddaf043e25..a28928bd2e1 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/collections.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/collections.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK package collections diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1202.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1202.kt index 2a9cfc7ff07..e0e3ca96271 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1202.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1202.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK package testeval @@ -115,4 +116,4 @@ fun box(): String { if (1 != eval(parse("1").value)) return "fail 5" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1406.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1406.kt index 898bd1b3f1e..d01c296636d 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1406.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1406.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK package pack diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt274.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt274.kt index 3d534c6dde2..6505d3ca48f 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt274.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt274.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK fun box() : String { diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt528.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt528.kt index 905593cdc08..e0735e271fe 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt528.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt528.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK package mask diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt529.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt529.kt index 68a5f0a762a..4ed3a4b9ed6 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt529.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt529.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK package mask diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt533.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt533.kt index 17bebda5876..2b78444eeda 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt533.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt533.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK package mask diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt6485.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt6485.kt index ec2964694bf..9e48e139774 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt6485.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt6485.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt864.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt864.kt index 87d7875c148..a396d14ab1e 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt864.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt864.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK import java.io.* diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/chainCalls.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/chainCalls.kt index 522f86e238c..0c2942f3cac 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/chainCalls.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/chainCalls.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK fun testProperLineNumber(): String { @@ -11,7 +12,7 @@ fun testProperLineNumber(): String { catch(e: AssertionError) { val entry = (e as java.lang.Throwable).getStackTrace()!!.get(1) val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("chainCalls.kt:8" != actual) { + if ("chainCalls.kt:9" != actual) { return "fail 1: ${actual}" } exceptionCount++ @@ -25,7 +26,7 @@ fun testProperLineNumber(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("chainCalls.kt:23" != actual) { + if ("chainCalls.kt:24" != actual) { return "fail 2: ${actual}" } exceptionCount++ @@ -38,7 +39,7 @@ fun testProperLineNumber(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("chainCalls.kt:36" != actual) { + if ("chainCalls.kt:37" != actual) { return "fail 3: ${actual}" } exceptionCount++ @@ -50,7 +51,7 @@ fun testProperLineNumber(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("chainCalls.kt:48" != actual) { + if ("chainCalls.kt:49" != actual) { return "fail 4: ${actual}" } exceptionCount++ diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/infixCalls.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/infixCalls.kt index 51a118f6761..76e9224ef34 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/infixCalls.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/infixCalls.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK fun testProperLineNumber(): String { @@ -9,7 +10,7 @@ fun testProperLineNumber(): String { catch(e: AssertionError) { val entry = (e as java.lang.Throwable).getStackTrace()!!.get(1) val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("infixCalls.kt:6" != actual) { + if ("infixCalls.kt:7" != actual) { return "fail 1: ${actual}" } exceptionCount++ @@ -22,7 +23,7 @@ fun testProperLineNumber(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("infixCalls.kt:19" != actual) { + if ("infixCalls.kt:20" != actual) { return "fail 1: ${actual}" } exceptionCount++ @@ -34,7 +35,7 @@ fun testProperLineNumber(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("infixCalls.kt:32" != actual) { + if ("infixCalls.kt:33" != actual) { return "fail 1: ${actual}" } exceptionCount++ diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/simpleCallWithParams.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/simpleCallWithParams.kt index ba2114b59b2..f7ec55b4a0f 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/simpleCallWithParams.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/smap/simpleCallWithParams.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK fun testProperLineNumberAfterInline(): String { @@ -9,7 +10,7 @@ fun testProperLineNumberAfterInline(): String { catch(e: AssertionError) { val entry = (e as java.lang.Throwable).getStackTrace()!!.get(1) val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("simpleCallWithParams.kt:6" != actual) { + if ("simpleCallWithParams.kt:7" != actual) { return "fail 1: ${actual}" } exceptionCount++ @@ -22,7 +23,7 @@ fun testProperLineNumberAfterInline(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("simpleCallWithParams.kt:19" != actual) { + if ("simpleCallWithParams.kt:20" != actual) { return "fail 2: ${actual}" } exceptionCount++ @@ -40,7 +41,7 @@ fun testProperLineForOtherParameters(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("simpleCallWithParams.kt:37" != actual) { + if ("simpleCallWithParams.kt:38" != actual) { return "fail 3: ${actual}" } exceptionCount++ @@ -54,7 +55,7 @@ fun testProperLineForOtherParameters(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("simpleCallWithParams.kt:51" != actual) { + if ("simpleCallWithParams.kt:52" != actual) { return "fail 4: ${actual}" } exceptionCount++ @@ -66,7 +67,7 @@ fun testProperLineForOtherParameters(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("simpleCallWithParams.kt:64" != actual) { + if ("simpleCallWithParams.kt:65" != actual) { return "fail 5: ${actual}" } exceptionCount++ @@ -78,7 +79,7 @@ fun testProperLineForOtherParameters(): String { catch(e: AssertionError) { val entry = e.stackTrace!![1] val actual = "${entry.getFileName()}:${entry.getLineNumber()}" - if ("simpleCallWithParams.kt:76" != actual) { + if ("simpleCallWithParams.kt:77" != actual) { return "fail 6: ${actual}" } exceptionCount++ diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/changeMonitor.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/changeMonitor.kt index fd77e13fd0b..43d93e34aa5 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/changeMonitor.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/changeMonitor.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/exceptionInMonitorExpression.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/exceptionInMonitorExpression.kt index a7cb71e3dcb..04b919dc260 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/exceptionInMonitorExpression.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/exceptionInMonitorExpression.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val obj = "" as java.lang.Object val e = IllegalArgumentException() @@ -12,4 +14,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/finally.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/finally.kt index 3a17bcc7fcd..2a2f2e7c0db 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/finally.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/finally.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/longValue.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/longValue.kt index de2eecd464a..bcf53f19328 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/longValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/longValue.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { var obj = "0" as java.lang.Object val result = synchronized (obj) { @@ -7,4 +9,4 @@ fun box(): String { if (result != 239L) return "Fail: $result" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nestedDifferentObjects.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nestedDifferentObjects.kt index fac1470096d..03ca8137b7e 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nestedDifferentObjects.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nestedDifferentObjects.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val obj = "" as java.lang.Object val obj2 = "1" as java.lang.Object @@ -10,4 +12,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nestedSameObject.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nestedSameObject.kt index e66d981f95d..5b1e4d05678 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nestedSameObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nestedSameObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val obj = "" as java.lang.Object @@ -8,4 +10,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nonLocalReturn.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nonLocalReturn.kt index f40a9480654..515dfa54caa 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nonLocalReturn.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/nonLocalReturn.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK import java.util.concurrent.CountDownLatch diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/objectValue.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/objectValue.kt index bcfa98d1ad8..31c149c4e79 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/objectValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/objectValue.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { var obj = "0" as java.lang.Object val result = synchronized (obj) { @@ -7,4 +9,4 @@ fun box(): String { if (result != "239") return "Fail: $result" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/sync.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/sync.kt index 513d2ed76e9..fc3fe96bc46 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/sync.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/sync.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK import java.util.concurrent.* diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/value.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/value.kt index 020c42ba61c..32767e5666c 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/value.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/value.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { var obj = "0" as java.lang.Object val result = synchronized (obj) { @@ -7,4 +9,4 @@ fun box(): String { if (result != 239) return "Fail: $result" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/wait.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/wait.kt index 0c75b1c7610..1eb96c4b713 100644 --- a/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/wait.kt +++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/synchronized/wait.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // FULL_JDK fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/hashPMap/empty.kt b/compiler/testData/codegen/boxWithStdlib/hashPMap/empty.kt index 4c91756b263..6e5969a73a4 100644 --- a/compiler/testData/codegen/boxWithStdlib/hashPMap/empty.kt +++ b/compiler/testData/codegen/boxWithStdlib/hashPMap/empty.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.internal.pcollections.HashPMap import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/hashPMap/manyNumbers.kt b/compiler/testData/codegen/boxWithStdlib/hashPMap/manyNumbers.kt index 408928f3331..bbf0bde06c7 100644 --- a/compiler/testData/codegen/boxWithStdlib/hashPMap/manyNumbers.kt +++ b/compiler/testData/codegen/boxWithStdlib/hashPMap/manyNumbers.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import java.util.* import kotlin.reflect.jvm.internal.pcollections.HashPMap import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/hashPMap/rewriteWithDifferent.kt b/compiler/testData/codegen/boxWithStdlib/hashPMap/rewriteWithDifferent.kt index 7d06e9be51c..7f82cc0c36e 100644 --- a/compiler/testData/codegen/boxWithStdlib/hashPMap/rewriteWithDifferent.kt +++ b/compiler/testData/codegen/boxWithStdlib/hashPMap/rewriteWithDifferent.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.internal.pcollections.HashPMap import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/hashPMap/rewriteWithEqual.kt b/compiler/testData/codegen/boxWithStdlib/hashPMap/rewriteWithEqual.kt index d94f22ff6f3..a1f2c89b7ce 100644 --- a/compiler/testData/codegen/boxWithStdlib/hashPMap/rewriteWithEqual.kt +++ b/compiler/testData/codegen/boxWithStdlib/hashPMap/rewriteWithEqual.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.internal.pcollections.HashPMap import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/hashPMap/simplePlusGet.kt b/compiler/testData/codegen/boxWithStdlib/hashPMap/simplePlusGet.kt index d9debf6fa77..bad0dca07b7 100644 --- a/compiler/testData/codegen/boxWithStdlib/hashPMap/simplePlusGet.kt +++ b/compiler/testData/codegen/boxWithStdlib/hashPMap/simplePlusGet.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.internal.pcollections.HashPMap import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/hashPMap/simplePlusMinus.kt b/compiler/testData/codegen/boxWithStdlib/hashPMap/simplePlusMinus.kt index affdcff09ea..818b9c05a6e 100644 --- a/compiler/testData/codegen/boxWithStdlib/hashPMap/simplePlusMinus.kt +++ b/compiler/testData/codegen/boxWithStdlib/hashPMap/simplePlusMinus.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.internal.pcollections.HashPMap import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/inline/kt6895.kt b/compiler/testData/codegen/boxWithStdlib/inline/kt6895.kt index d7bbb1d62e1..3d8260167ea 100644 --- a/compiler/testData/codegen/boxWithStdlib/inline/kt6895.kt +++ b/compiler/testData/codegen/boxWithStdlib/inline/kt6895.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.concurrent.locks.ReentrantReadWriteLock import kotlin.concurrent.write @@ -19,4 +21,4 @@ class UpdateableThing { fun box(): String { return UpdateableThing().performUpdates { "OK" } -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/inline/kt9644let.kt b/compiler/testData/codegen/boxWithStdlib/inline/kt9644let.kt index d12593090b5..2972f593a56 100644 --- a/compiler/testData/codegen/boxWithStdlib/inline/kt9644let.kt +++ b/compiler/testData/codegen/boxWithStdlib/inline/kt9644let.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun foo() { with(1) { return (1..2).forEach { it } @@ -7,4 +9,4 @@ fun foo() { fun box(): String { foo() return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/intrinsics/defaultObjectMapping.kt b/compiler/testData/codegen/boxWithStdlib/intrinsics/defaultObjectMapping.kt index 18cc827475a..7196d3ba86e 100644 --- a/compiler/testData/codegen/boxWithStdlib/intrinsics/defaultObjectMapping.kt +++ b/compiler/testData/codegen/boxWithStdlib/intrinsics/defaultObjectMapping.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/intrinsics/kt10131.kt b/compiler/testData/codegen/boxWithStdlib/intrinsics/kt10131.kt index 8dfd1db030f..b388bc4fb62 100644 --- a/compiler/testData/codegen/boxWithStdlib/intrinsics/kt10131.kt +++ b/compiler/testData/codegen/boxWithStdlib/intrinsics/kt10131.kt @@ -1,2 +1,4 @@ +// WITH_RUNTIME + fun box(): String = - listOf('O', 'K').fold("", String::plus) \ No newline at end of file + listOf('O', 'K').fold("", String::plus) diff --git a/compiler/testData/codegen/boxWithStdlib/intrinsics/kt10131a.kt b/compiler/testData/codegen/boxWithStdlib/intrinsics/kt10131a.kt index 240390106d2..db05fd54b18 100644 --- a/compiler/testData/codegen/boxWithStdlib/intrinsics/kt10131a.kt +++ b/compiler/testData/codegen/boxWithStdlib/intrinsics/kt10131a.kt @@ -1,2 +1,4 @@ +// WITH_RUNTIME + fun box(): String = - charArrayOf('O', 'K').fold("", String::plus) \ No newline at end of file + charArrayOf('O', 'K').fold("", String::plus) diff --git a/compiler/testData/codegen/boxWithStdlib/intrinsics/kt5937.kt b/compiler/testData/codegen/boxWithStdlib/intrinsics/kt5937.kt index 466ee2aad5a..ece3f084f2c 100644 --- a/compiler/testData/codegen/boxWithStdlib/intrinsics/kt5937.kt +++ b/compiler/testData/codegen/boxWithStdlib/intrinsics/kt5937.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + var result = "Fail" var l = 10L @@ -26,4 +28,4 @@ fun box(): String { if (2.javaClass != i.javaClass) return "fail 7" return result -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/captureClassFields.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/captureClassFields.kt index a9572ef78bc..17e7d9cc22b 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/captureClassFields.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/captureClassFields.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + open class A { @JvmField public val publicField = "1"; @JvmField internal val internalField = "2"; @@ -13,4 +15,4 @@ open class A { fun box(): String { return if (A().test() == "1234") return "OK" else "fail" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/capturePackageFields.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/capturePackageFields.kt index 1438479c804..d1ab6c9cbe1 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/capturePackageFields.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/capturePackageFields.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @JvmField public val publicField = "1"; @JvmField internal val internalField = "23"; @@ -10,4 +12,4 @@ fun test(): String { fun box(): String { return if (test() == "123") return "OK" else "fail" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/checkNoAccessors.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/checkNoAccessors.kt index d02020609be..3fd39121edb 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/checkNoAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/checkNoAccessors.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertFalse @JvmField public val field = "OK"; @@ -32,4 +34,4 @@ public fun checkNoAccessors(clazz: Class<*>) { "Class ${clazz.name} has accessor '${it.name}'" ) } -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/classFieldReference.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/classFieldReference.kt index 10106df9287..faf60c11fff 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/classFieldReference.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/classFieldReference.kt @@ -1,6 +1,7 @@ +// WITH_RUNTIME + package zzz import java.lang.reflect.Field -import kotlin.reflect.jvm.javaField import kotlin.reflect.KProperty1 import kotlin.test.assertEquals @@ -38,4 +39,4 @@ fun box(): String { public fun checkAccessor(prop: KProperty1, value: R, receiver: T) { assertEquals(prop.get(receiver), value, "Property ${prop} has wrong value") -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/classFieldReflection.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/classFieldReflection.kt index 24ebe84280e..66d6e4e37d3 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/classFieldReflection.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/classFieldReflection.kt @@ -1,6 +1,7 @@ +// WITH_REFLECT + package zzz import java.lang.reflect.Field -import kotlin.reflect.jvm.javaField import kotlin.reflect.KProperty1 import kotlin.test.assertEquals @@ -41,4 +42,4 @@ public fun checkAccessor(prop: KMutableProperty1, value: R, newValu assertEquals(prop.get(receiver), value, "Property ${prop} has wrong value") prop.set(receiver, newValue) assertEquals(prop.get(receiver), newValue, "Property ${prop} has wrong value") -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/publicField.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/publicField.kt index 813d451fbca..acf9fb408e3 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/publicField.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/publicField.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class A { @JvmField public val field = "OK"; @@ -20,4 +22,4 @@ fun box(): String { return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/superCall.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/superCall.kt index d98a7d1758b..f5723a3ec20 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/superCall.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/superCall.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + open class A { @JvmField public val publicField = "1"; @JvmField internal val internalField = "2"; @@ -14,4 +16,4 @@ class B : A() { fun box(): String { return if (B().test() == "123") return "OK" else "fail" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/superCall2.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/superCall2.kt index 502967ce22c..fad6f43a28c 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/superCall2.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/superCall2.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + open class A { @JvmField public val publicField = "1"; @JvmField internal val internalField = "2"; @@ -17,4 +19,4 @@ open class C : B() { fun box(): String { return if (C().test() == "123") return "OK" else "fail" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/topLevelFieldReference.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/topLevelFieldReference.kt index 44fcf2df17a..68e5ca9fd89 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/topLevelFieldReference.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/topLevelFieldReference.kt @@ -1,6 +1,7 @@ +// WITH_RUNTIME + package zzz import java.lang.reflect.Field -import kotlin.reflect.jvm.javaField import kotlin.test.assertEquals import kotlin.reflect.KProperty0 @@ -21,4 +22,4 @@ fun box(): String { public fun checkAccessor(prop: KProperty0, value: R) { assertEquals(prop.get(), value, "Property ${prop} has wrong value") -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/topLevelFieldReflection.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/topLevelFieldReflection.kt index a7dc0da54b8..46ea2370620 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/topLevelFieldReflection.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/topLevelFieldReflection.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + package test import kotlin.reflect.KMutableProperty0 @@ -24,4 +26,4 @@ public fun < R> checkAccessor(prop: KMutableProperty0, value: R, newValue: R) assertEquals(prop.get(), value, "Property ${prop} has wrong value") prop.set(newValue) assertEquals(prop.get(), newValue, "Property ${prop} has wrong value") -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/visibility.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/visibility.kt index e8675a61f64..122e2b3c275 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/visibility.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/visibility.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK import java.lang.reflect.Field diff --git a/compiler/testData/codegen/boxWithStdlib/jvmField/writeFieldReference.kt b/compiler/testData/codegen/boxWithStdlib/jvmField/writeFieldReference.kt index 2e38cf00e14..697f6533029 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmField/writeFieldReference.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmField/writeFieldReference.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package zzz import kotlin.reflect.KMutableProperty1 import kotlin.test.assertEquals @@ -22,4 +24,4 @@ public fun checkAccessor(prop: KMutableProperty1, value: R, newValu assertEquals(prop.get(receiver), value, "Property ${prop} has wrong value") prop.set(receiver, newValue) assertEquals(prop.get(receiver), newValue, "Property ${prop} has wrong value") -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/callableReference.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/callableReference.kt index 2296d1e7c57..dffc81872a2 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/callableReference.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/callableReference.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @JvmName("bar") fun foo() = "foo" @@ -6,4 +8,4 @@ fun box(): String { if (f != "foo") return "Fail: $f" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/clashingErasure.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/clashingErasure.kt index b887c4a5b98..968e679e1e5 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/clashingErasure.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/clashingErasure.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun List.foo() = "foo" @JvmName("fooInt") @@ -11,4 +13,4 @@ fun box(): String { if (ints != "fooInt") return "Fail: $ints" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/classMembers.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/classMembers.kt index 4c923efe3ec..6be0e28ed14 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/classMembers.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/classMembers.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // See: // http://kotlinlang.org/docs/reference/java-interop.html#handling-signature-clashes-with-platformname // https://youtrack.jetbrains.com/issue/KT-5524 @@ -115,5 +116,3 @@ fun box(): String { return "OK" } - - diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/functionName.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/functionName.kt index 74f4cc5343c..b7c93238e01 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/functionName.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/functionName.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @JvmName("bar") fun foo() = "foo" @@ -6,4 +8,4 @@ fun box(): String { if (f != "foo") return "Fail: $f" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClass.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClass.kt index f39b36ea291..e988b50027a 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClass.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @file:JvmName("Test") @file:JvmMultifileClass package test @@ -6,4 +8,4 @@ fun foo(): String = bar() fun bar(): String = qux() fun qux(): String = "OK" -fun box(): String = foo() \ No newline at end of file +fun box(): String = foo() diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClassWithLocalClass.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClassWithLocalClass.kt index 134bf63d551..fe20a842564 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClassWithLocalClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClassWithLocalClass.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @file:JvmName("Test") @file:JvmMultifileClass package test @@ -8,4 +10,4 @@ fun bar(): String { return Local("OK").x } -fun box(): String = foo() \ No newline at end of file +fun box(): String = foo() diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClassWithLocalGeneric.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClassWithLocalGeneric.kt index 32528c422d4..d67819ded54 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClassWithLocalGeneric.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/multifileClassWithLocalGeneric.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @file:JvmName("Test") @file:JvmMultifileClass package test @@ -14,4 +16,4 @@ fun bar(): String { return Local3().method(localFun(Derived("OK")).extFun()) } -fun box(): String = foo() \ No newline at end of file +fun box(): String = foo() diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/propertyAccessorsUseSite.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/propertyAccessorsUseSite.kt index 218495d8283..13bbfb77239 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/propertyAccessorsUseSite.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/propertyAccessorsUseSite.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals class TestIt { diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/propertyName.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/propertyName.kt index ae4200bff07..50a251ead58 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/propertyName.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/propertyName.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + var v: Int = 1 @JvmName("vget") get @@ -9,4 +11,4 @@ fun box(): String { if (v != 2) return "Fail: $v" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmName/renamedFileClass.kt b/compiler/testData/codegen/boxWithStdlib/jvmName/renamedFileClass.kt index 55871f1f87d..b1ca27df0d8 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmName/renamedFileClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmName/renamedFileClass.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @file:JvmName("Util") package test @@ -5,4 +7,4 @@ fun foo(): String = bar() fun bar(): String = qux() fun qux(): String = "OK" -fun box(): String = foo() \ No newline at end of file +fun box(): String = foo() diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/companionObject.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/companionObject.kt index f33f708d4be..28fac230ac9 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/companionObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/companionObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C { companion object { @JvmStatic @kotlin.jvm.JvmOverloads public fun foo(o: String, k: String = "K"): String { diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/defaultsNotAtEnd.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/defaultsNotAtEnd.kt index e4e4ea7b898..17e302bc6f5 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/defaultsNotAtEnd.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/defaultsNotAtEnd.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C { @kotlin.jvm.JvmOverloads public fun foo(o: String = "O", i1: Int, k: String = "K", i2: Int): String { return o + k diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/doubleParameters.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/doubleParameters.kt index c965a918e26..c1b4658d9e1 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/doubleParameters.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/doubleParameters.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C { @kotlin.jvm.JvmOverloads public fun foo(d1: Double, d2: Double, status: String = "OK"): String { return if (d1 + d2 == 3.0) status else "fail" diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/extensionMethod.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/extensionMethod.kt index caf72f7ab28..261b051a2d4 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/extensionMethod.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/extensionMethod.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C { } diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/multipleDefaultParameters.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/multipleDefaultParameters.kt index 66c076ca573..da39def9bbc 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/multipleDefaultParameters.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/multipleDefaultParameters.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C { @kotlin.jvm.JvmOverloads public fun foo(o: String = "O", k: String = "K"): String { return o + k diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/nonDefaultParameter.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/nonDefaultParameter.kt index f0c449920bc..f005aa25530 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/nonDefaultParameter.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/nonDefaultParameter.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C { @kotlin.jvm.JvmOverloads public fun foo(o: String, k: String = "K"): String { return o + k diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/primaryConstructor.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/primaryConstructor.kt index c25134cce3b..bdf24baabb9 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/primaryConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/primaryConstructor.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C @kotlin.jvm.JvmOverloads constructor(s1: String, s2: String = "K") { public val status: String = s1 + s2 } diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/secondaryConstructor.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/secondaryConstructor.kt index 07692fe708f..a01115c8be1 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/secondaryConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/secondaryConstructor.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C(val i: Int) { var status = "fail" diff --git a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/simple.kt b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/simple.kt index e85d5152e0b..10db210e371 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmOverloads/simple.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmOverloads/simple.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C { @kotlin.jvm.JvmOverloads public fun foo(s: String = "OK"): String { return s diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/closure.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/closure.kt index fed342abc8b..e1fa1100d97 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/closure.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/closure.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object A { val b: String = "OK" @@ -43,4 +45,4 @@ fun box(): String { if (A.test6() != "OK") return "fail 6" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/convention.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/convention.kt index 979bad60814..0d760c53367 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/convention.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/convention.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class B(var s: Int = 0) { } @@ -28,4 +30,4 @@ fun box(): String { if (b.s != 1011) return "fail 2" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/default.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/default.kt index eff91f2c145..0cdae8e14df 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/default.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/default.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object A { @JvmStatic fun test(b: String = "OK") : String { @@ -10,4 +12,4 @@ fun box(): String { if (A.test() != "OK") return "fail 1" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/explicitObject.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/explicitObject.kt index 36c74d18bc0..7b328408051 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/explicitObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/explicitObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object AX { @JvmStatic val c: String = "OK" @@ -29,4 +31,4 @@ fun box() : String { if (AX.getProperty() != "OK") return "fail 3" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/funAccess.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/funAccess.kt index 61778fa2d76..b4ad4f8fdc5 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/funAccess.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/funAccess.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + var holder = "" fun getA(): A { diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/importStaticMemberFromObject.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/importStaticMemberFromObject.kt index b9c9c1fcf20..63d166517a1 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/importStaticMemberFromObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/importStaticMemberFromObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import O.p import O.f import C.Companion.p1 @@ -27,4 +29,4 @@ fun box(): String { if (p1 + f1() != 9) return "fail2" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/inline.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/inline.kt index 679f2c4c3c8..de12d13ac96 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/inline.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/inline.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object A { @JvmStatic inline fun test(b: String = "OK") : String { @@ -10,4 +12,4 @@ fun box(): String { if (A.test() != "OK") return "fail 1" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/kt9897_static.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/kt9897_static.kt index 66559576b7b..ea243dab2f9 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/kt9897_static.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/kt9897_static.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object Test { var z = "0" var l = 0L @@ -38,4 +40,4 @@ fun box(): String { if (changeLong != 1L) return "fail 1: $changeLong" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/postfixInc.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/postfixInc.kt index d03947f0c6e..a484652dbd8 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/postfixInc.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/postfixInc.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object A { @JvmStatic var a: Int = 1 @@ -42,4 +44,4 @@ fun box(): String { holder = "" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/prefixInc.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/prefixInc.kt index 4dc897fb233..c6a034a829b 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/prefixInc.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/prefixInc.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object A { @JvmStatic var a: Int = 1 @@ -42,4 +44,4 @@ fun box(): String { holder = "" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/privateMethod.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/privateMethod.kt index 8bd7f0c2e69..38e9120c013 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/privateMethod.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/privateMethod.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object A { private @JvmStatic fun a(): String { @@ -11,4 +13,4 @@ object A { fun box(): String { return A.Z.p -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/propertyAccess.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/propertyAccess.kt index b436519e629..a0a3bdf3d43 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/propertyAccess.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/propertyAccess.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + var holder = "" fun getA(): A { @@ -42,4 +44,4 @@ fun box(): String { holder = "" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/propertyAsDefault.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/propertyAsDefault.kt index a23b005d223..aad50dc8270 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/propertyAsDefault.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/propertyAsDefault.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object X { @JvmStatic val x = "OK" @@ -6,4 +8,4 @@ object X { fun box(): String { return X.fn() -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/simple.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/simple.kt index c65413f4634..d84a4c3dd3a 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/simple.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/simple.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object A { val b: String = "OK" @@ -39,4 +41,4 @@ fun box(): String { if (A.c != "OK") return "fail 6" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/jvmStatic/syntheticAccessor.kt b/compiler/testData/codegen/boxWithStdlib/jvmStatic/syntheticAccessor.kt index 274a68615e1..f05b89a8b56 100644 --- a/compiler/testData/codegen/boxWithStdlib/jvmStatic/syntheticAccessor.kt +++ b/compiler/testData/codegen/boxWithStdlib/jvmStatic/syntheticAccessor.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class C { companion object { private @JvmStatic fun foo(): String { @@ -12,4 +14,4 @@ class C { fun box(): String { return C().bar() -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambda.kt b/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambda.kt index 41ccf0f2efd..935d8b4963c 100644 --- a/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambda.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun foo(x: String, block: (String) -> String) = block(x) diff --git a/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambdaInnerUsage1.kt b/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambdaInnerUsage1.kt index edb963dd8b5..6609be78133 100644 --- a/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambdaInnerUsage1.kt +++ b/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambdaInnerUsage1.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun foo(x: String, block: (String) -> String) = block(x) diff --git a/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambdaInnerUsage2.kt b/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambdaInnerUsage2.kt index b97f93fd8b5..158e845f9ad 100644 --- a/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambdaInnerUsage2.kt +++ b/compiler/testData/codegen/boxWithStdlib/localFunInLambda/definedWithinLambdaInnerUsage2.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun foo(x: String, block: (String) -> String) = block(x) diff --git a/compiler/testData/codegen/boxWithStdlib/localFunInLambda/simple.kt b/compiler/testData/codegen/boxWithStdlib/localFunInLambda/simple.kt index 8f86cc3c384..a59a7507800 100644 --- a/compiler/testData/codegen/boxWithStdlib/localFunInLambda/simple.kt +++ b/compiler/testData/codegen/boxWithStdlib/localFunInLambda/simple.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun foo(x: String, block: (String) -> String) = block(x) diff --git a/compiler/testData/codegen/boxWithStdlib/mangling/field.kt b/compiler/testData/codegen/boxWithStdlib/mangling/field.kt index 1a48324d1ba..89a1d393e5b 100644 --- a/compiler/testData/codegen/boxWithStdlib/mangling/field.kt +++ b/compiler/testData/codegen/boxWithStdlib/mangling/field.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package test internal val noMangling = 1; @@ -15,4 +17,4 @@ fun box(): String { if (topLevel == null) return "Top level internal backing field should exist" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/mangling/fun.kt b/compiler/testData/codegen/boxWithStdlib/mangling/fun.kt index 491e98a352b..4494bca9123 100644 --- a/compiler/testData/codegen/boxWithStdlib/mangling/fun.kt +++ b/compiler/testData/codegen/boxWithStdlib/mangling/fun.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package test internal fun noMangling() = 1; @@ -19,4 +21,4 @@ fun box(): String { if (topLevel == null) return "Top level internal function should exist" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/multiDeclForArray/kt9828.kt b/compiler/testData/codegen/boxWithStdlib/multiDeclForArray/kt9828.kt index fc8cebd6c74..cfc3732417f 100644 --- a/compiler/testData/codegen/boxWithStdlib/multiDeclForArray/kt9828.kt +++ b/compiler/testData/codegen/boxWithStdlib/multiDeclForArray/kt9828.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.* fun box(): String { @@ -8,4 +10,4 @@ fun box(): String { } return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/nonLocalReturns/use.kt b/compiler/testData/codegen/boxWithStdlib/nonLocalReturns/use.kt index 9568664da9c..e745b282871 100644 --- a/compiler/testData/codegen/boxWithStdlib/nonLocalReturns/use.kt +++ b/compiler/testData/codegen/boxWithStdlib/nonLocalReturns/use.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.io.Closeable class MyException(message: String) : Exception(message) diff --git a/compiler/testData/codegen/boxWithStdlib/nonLocalReturns/useWithException.kt b/compiler/testData/codegen/boxWithStdlib/nonLocalReturns/useWithException.kt index d29190d6bda..b764a109b64 100644 --- a/compiler/testData/codegen/boxWithStdlib/nonLocalReturns/useWithException.kt +++ b/compiler/testData/codegen/boxWithStdlib/nonLocalReturns/useWithException.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.io.Closeable import kotlin.test.assertTrue import kotlin.test.fail @@ -182,4 +184,4 @@ public fun assertError(index: Int, expected: String, l: TestLocal.()->Unit) { } catch (e: Exception) { assertEquals(expected, testLocal.status.value, "failed on $index") } -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/postfixIncrementDecrement/memberExtOnLong.kt b/compiler/testData/codegen/boxWithStdlib/postfixIncrementDecrement/memberExtOnLong.kt index 6383a1c691b..c51bf9b901d 100644 --- a/compiler/testData/codegen/boxWithStdlib/postfixIncrementDecrement/memberExtOnLong.kt +++ b/compiler/testData/codegen/boxWithStdlib/postfixIncrementDecrement/memberExtOnLong.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + object ExtProvider { operator fun Long.get(i: Int) = this operator fun Long.set(i: Int, newValue: Long) {} @@ -9,4 +11,4 @@ fun box(): String { val y = x[0]++ return if (y == 0L) "OK" else "Failed, y=$y" } -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/postfixIncrementDecrement/mutableListElement.kt b/compiler/testData/codegen/boxWithStdlib/postfixIncrementDecrement/mutableListElement.kt index 2dc6f6d16d1..b861d31e15d 100644 --- a/compiler/testData/codegen/boxWithStdlib/postfixIncrementDecrement/mutableListElement.kt +++ b/compiler/testData/codegen/boxWithStdlib/postfixIncrementDecrement/mutableListElement.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val aByte = arrayListOf(1) var bByte: Byte = 1 @@ -78,4 +80,4 @@ fun box(): String { if (aDouble[0] != bDouble) return "Failed post-increment Double: ${aDouble[0]} != $bDouble" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/privateConstructor/synthetic.kt b/compiler/testData/codegen/boxWithStdlib/privateConstructor/synthetic.kt index 5078c0c729f..032f50bf017 100644 --- a/compiler/testData/codegen/boxWithStdlib/privateConstructor/synthetic.kt +++ b/compiler/testData/codegen/boxWithStdlib/privateConstructor/synthetic.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + // private constructors are transformed into synthetic class PrivateConstructor private constructor() { class Nested { val a = PrivateConstructor() } diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/emptyDownto.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/emptyDownto.kt index 0912f85c4d7..59e009da1a7 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/emptyDownto.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/emptyDownto.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/emptyRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/emptyRange.kt index a965230a411..1328f7658a1 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/emptyRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/emptyRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactDownToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactDownToMinValue.kt index 92100f0be82..8dd880501ec 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactDownToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactDownToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactSteppedDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactSteppedDownTo.kt index 0fbd4b3469d..1a4e3818a0a 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactSteppedDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactSteppedDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactSteppedRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactSteppedRange.kt index fe679e3e535..574a7ea7c21 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactSteppedRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactSteppedRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactToMaxValue.kt index 8a45d71ebb7..34eeeab01ec 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/inexactToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueMinusTwoToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueMinusTwoToMaxValue.kt index 7e32256de9b..e2d984b5bbe 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueMinusTwoToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueMinusTwoToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueToMaxValue.kt index 3d2240c941a..c4f4465cf6a 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueToMinValue.kt index e1c5119616f..435d55532e5 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/maxValueToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/oneElementDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/oneElementDownTo.kt index bb92a32c94d..d477ccf7f64 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/oneElementDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/oneElementDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/oneElementRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/oneElementRange.kt index 9b88a12f2b1..666b1a2a617 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/oneElementRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/oneElementRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/openRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/openRange.kt index db3ae755bb2..e8a14931515 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/openRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/openRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionDownToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionDownToMinValue.kt index 05e028cfab9..5c85639fd78 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionDownToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionDownToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueMinusTwoToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueMinusTwoToMaxValue.kt index a7b7fba59db..d7bce340efc 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueMinusTwoToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueMinusTwoToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueToMaxValue.kt index 8e2a7a117b4..fe616e67112 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueToMinValue.kt index f3dfd3538f5..310992ec9e7 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMaxValueToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMinValueToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMinValueToMinValue.kt index 6c52915b863..4e1c13ebcb9 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMinValueToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/progressionMinValueToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedBackSequence.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedBackSequence.kt index 074ec6d727f..8d04eb30302 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedBackSequence.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedBackSequence.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedEmptyBackSequence.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedEmptyBackSequence.kt index 955527cdccf..823d064cbf3 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedEmptyBackSequence.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedEmptyBackSequence.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedEmptyRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedEmptyRange.kt index 512a5c8a5a6..8d77df80a4d 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedEmptyRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedEmptyRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedInexactSteppedDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedInexactSteppedDownTo.kt index 0bfc25c5b11..19300b45f90 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedInexactSteppedDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedInexactSteppedDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedRange.kt index 92d15b9058e..c267bd7a3cb 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedSimpleSteppedRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedSimpleSteppedRange.kt index 3c96a303c06..5712875686c 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedSimpleSteppedRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/reversedSimpleSteppedRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleDownTo.kt index cc5f68ff88a..07359b3c012 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleRange.kt index b250598cf70..0fe7419b2d7 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleRangeWithNonConstantEnds.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleRangeWithNonConstantEnds.kt index 35d2034b4c4..3e5f00123c8 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleRangeWithNonConstantEnds.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleRangeWithNonConstantEnds.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleSteppedDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleSteppedDownTo.kt index a892d90da9f..b27237d7568 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleSteppedDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleSteppedDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleSteppedRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleSteppedRange.kt index b6c5cd24f3b..8f8e4d93f30 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleSteppedRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/expression/simpleSteppedRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/forByteProgressionWithIntIncrement.kt b/compiler/testData/codegen/boxWithStdlib/ranges/forByteProgressionWithIntIncrement.kt index ec16945a875..8596acc44fd 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/forByteProgressionWithIntIncrement.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/forByteProgressionWithIntIncrement.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { for (element in 5.toByte()..1.toByte() step 255) { return "Fail: iterating over an empty progression, element: $element" diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/forIntRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/forIntRange.kt index 6dd9278c030..1dd52f48533 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/forIntRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/forIntRange.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box() : String { val a = arrayOfNulls(3) a[0] = "a" diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/emptyDownto.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/emptyDownto.kt index da34c280764..cbe751b7573 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/emptyDownto.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/emptyDownto.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/emptyRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/emptyRange.kt index 06268f432e2..2f6848968de 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/emptyRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/emptyRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactDownToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactDownToMinValue.kt index bb15dc78c66..aa09f24c845 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactDownToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactDownToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactSteppedDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactSteppedDownTo.kt index db36a6bed47..c68bac2eda5 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactSteppedDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactSteppedDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactSteppedRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactSteppedRange.kt index 1071411da04..64e28e1ba03 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactSteppedRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactSteppedRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactToMaxValue.kt index 503732f47b0..1603d1307b7 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/inexactToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueMinusTwoToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueMinusTwoToMaxValue.kt index da12a8da7e9..cbd5d35661a 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueMinusTwoToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueMinusTwoToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueToMaxValue.kt index 7278d76daef..078587aeba9 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueToMinValue.kt index 9126b61a743..19ae98a0e97 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/maxValueToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/oneElementDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/oneElementDownTo.kt index 21e94841cf1..286bfad68fd 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/oneElementDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/oneElementDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/oneElementRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/oneElementRange.kt index 14f71e7a2b6..b00e4b642b2 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/oneElementRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/oneElementRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/openRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/openRange.kt index 6d8110f0198..3f32906280c 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/openRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/openRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionDownToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionDownToMinValue.kt index baec07dcae2..276771d50f4 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionDownToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionDownToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueMinusTwoToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueMinusTwoToMaxValue.kt index 5895949634f..90b498a02ec 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueMinusTwoToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueMinusTwoToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueToMaxValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueToMaxValue.kt index 4935b0bebd0..2a919fe5c8c 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueToMaxValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueToMaxValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueToMinValue.kt index 80e6d7bbbb6..d2ed26a8373 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMaxValueToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMinValueToMinValue.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMinValueToMinValue.kt index 05f576f1552..1720148fe98 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMinValueToMinValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/progressionMinValueToMinValue.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList import java.lang.Integer.MAX_VALUE as MaxI diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedBackSequence.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedBackSequence.kt index d2e8e88cd51..1966f2e58ab 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedBackSequence.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedBackSequence.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedEmptyBackSequence.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedEmptyBackSequence.kt index f4431b433cf..c2666765c8b 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedEmptyBackSequence.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedEmptyBackSequence.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedEmptyRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedEmptyRange.kt index 50ffa6efb9b..942f12a1d3e 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedEmptyRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedEmptyRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedInexactSteppedDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedInexactSteppedDownTo.kt index c1959412965..f7bc3ef6e0f 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedInexactSteppedDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedInexactSteppedDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedRange.kt index 8152dd64782..21cf3169642 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedSimpleSteppedRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedSimpleSteppedRange.kt index 6f31b5025fa..d6826b35d12 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedSimpleSteppedRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/reversedSimpleSteppedRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleDownTo.kt index 94441dc82e1..a81230f19ab 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleRange.kt index e44ce2a5bc8..933b7e9a95a 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleRangeWithNonConstantEnds.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleRangeWithNonConstantEnds.kt index eb8abcd9c9c..2e3af3dd55e 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleRangeWithNonConstantEnds.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleRangeWithNonConstantEnds.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleSteppedDownTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleSteppedDownTo.kt index 0b4139af209..dd200c5a3f8 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleSteppedDownTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleSteppedDownTo.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleSteppedRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleSteppedRange.kt index 98730b32783..b0e1673185c 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleSteppedRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/literal/simpleSteppedRange.kt @@ -1,4 +1,6 @@ // Auto-generated by org.jetbrains.kotlin.generators.tests.GenerateRangesCodegenTestData. DO NOT EDIT! +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/multiAssignmentIterationOverIntRange.kt b/compiler/testData/codegen/boxWithStdlib/ranges/multiAssignmentIterationOverIntRange.kt index 01edfadc0ce..d8fef0b509a 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/multiAssignmentIterationOverIntRange.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/multiAssignmentIterationOverIntRange.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + operator fun Int.component1(): String { return arrayListOf("zero", "one", "two", "three")[this] } diff --git a/compiler/testData/codegen/boxWithStdlib/ranges/safeCallRangeTo.kt b/compiler/testData/codegen/boxWithStdlib/ranges/safeCallRangeTo.kt index bcb5397fa92..eb2e7e22006 100644 --- a/compiler/testData/codegen/boxWithStdlib/ranges/safeCallRangeTo.kt +++ b/compiler/testData/codegen/boxWithStdlib/ranges/safeCallRangeTo.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun charRange(x: Char?, y: Char) = x?.rangeTo(y) fun byteRange(x: Byte?, y: Byte) = x?.rangeTo(y) fun shortRange(x: Short?, y: Short) = x?.rangeTo(y) @@ -23,4 +25,4 @@ fun box(): String { testSafeRange(0.0f, 1.0f, "0.0..1.0", ::floatRange) testSafeRange(0.0, 1.0, "0.0..1.0", ::dougleRange) return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/annotationRetentionAnnotation.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/annotationRetentionAnnotation.kt index 593ac093a85..edbfc485aef 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/annotationRetentionAnnotation.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/annotationRetentionAnnotation.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/propertyAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/propertyAccessors.kt index 38b46e756f8..4053df2dc9c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/propertyAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/propertyAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + annotation class Get annotation class Set annotation class SetParam diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/propertyWithoutBackingField.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/propertyWithoutBackingField.kt index 80cd7da73ab..34681921415 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/propertyWithoutBackingField.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/propertyWithoutBackingField.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + annotation class Ann(val value: String) @Ann("OK") diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/retentions.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/retentions.kt index 7ac85019596..ca600e33176 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/retentions.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/retentions.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals @Retention(AnnotationRetention.SOURCE) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleClassAnnotation.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleClassAnnotation.kt index 5361cb11d9f..b91815bfba8 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleClassAnnotation.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleClassAnnotation.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + @Retention(AnnotationRetention.RUNTIME) annotation class Simple(val value: String) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleConstructorAnnotation.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleConstructorAnnotation.kt index 21b6d1d0807..679034577b9 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleConstructorAnnotation.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleConstructorAnnotation.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + annotation class Primary annotation class Secondary diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleFunAnnotation.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleFunAnnotation.kt index c8a7e9d7cc2..ec463e1268e 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleFunAnnotation.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleFunAnnotation.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + @Retention(AnnotationRetention.RUNTIME) annotation class Simple(val value: String) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleParamAnnotation.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleParamAnnotation.kt index e1235966775..6336cae250d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleParamAnnotation.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleParamAnnotation.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + @Retention(AnnotationRetention.RUNTIME) annotation class Simple(val value: String) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleValAnnotation.kt b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleValAnnotation.kt index 7ca1861cd71..5439ee6d8af 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleValAnnotation.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/annotations/simpleValAnnotation.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + @Retention(AnnotationRetention.RUNTIME) annotation class Simple(val value: String) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/cannotCallEnumConstructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/cannotCallEnumConstructor.kt index 48b8c8bb118..16fd72c8503 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/cannotCallEnumConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/cannotCallEnumConstructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* enum class E diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/disallowNullValueForNotNullField.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/disallowNullValueForNotNullField.kt index 869f8b39801..b87d16a93fc 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/disallowNullValueForNotNullField.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/disallowNullValueForNotNullField.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/equalsHashCodeToString.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/equalsHashCodeToString.kt index aa168aa0e93..706a9cacc0e 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/equalsHashCodeToString.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/equalsHashCodeToString.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class A data class D(val s: String) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/exceptionHappened.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/exceptionHappened.kt index a311aebdd44..e1cae18abdc 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/exceptionHappened.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/exceptionHappened.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK import java.lang.reflect.InvocationTargetException diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/fakeOverride.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/fakeOverride.kt index dbcb0b39d1a..56627cb9d9b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/fakeOverride.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/fakeOverride.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + open class A { fun foo() = "OK" } diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/fakeOverrideSubstituted.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/fakeOverrideSubstituted.kt index 506a1a44dee..9adaec164da 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/fakeOverrideSubstituted.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/fakeOverrideSubstituted.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + open class A(val t: T) { fun foo() = t } diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/incorrectNumberOfArguments.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/incorrectNumberOfArguments.kt index c07820acd69..1aa8a1adbed 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/incorrectNumberOfArguments.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/incorrectNumberOfArguments.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.isAccessible import kotlin.reflect.KCallable import kotlin.reflect.KFunction diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/innerClassConstructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/innerClassConstructor.kt index 85bd90c6e04..c0899244fc1 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/innerClassConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/innerClassConstructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class A { class Nested(val result: String) inner class Inner(val result: String) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/jvmStatic.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/jvmStatic.kt index be25d4bd9a7..7ea4639af48 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/jvmStatic.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/jvmStatic.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + object Obj { @JvmStatic fun foo() {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/jvmStaticInObjectIncorrectReceiver.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/jvmStaticInObjectIncorrectReceiver.kt index f36ebc2a768..540702ab589 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/jvmStaticInObjectIncorrectReceiver.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/jvmStaticInObjectIncorrectReceiver.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + object Obj { @JvmStatic fun foo(s: String) {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/localClassMember.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/localClassMember.kt index 115b402b794..c24fdfd0f1c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/localClassMember.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/localClassMember.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun box(): String { class Local { fun result(s: String) = s diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/memberOfGenericClass.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/memberOfGenericClass.kt index 76220c13639..387bab8989b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/memberOfGenericClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/memberOfGenericClass.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + var result = "Fail" class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/privateProperty.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/privateProperty.kt index fb5a42dbe5a..9fdca51ba9a 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/privateProperty.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/privateProperty.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/propertyAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/propertyAccessors.kt index 0ed8a1c6ffa..2c853c8ca99 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/propertyAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/propertyAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/returnUnit.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/returnUnit.kt index 66bd1180355..33f5e78df21 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/returnUnit.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/returnUnit.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals fun foo() {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleConstructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleConstructor.kt index afcb2fd3794..7788fc38e51 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleConstructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class A(val result: String) fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleMemberFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleMemberFunction.kt index 87bf9c0daff..73677cbec1d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleMemberFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleMemberFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class A { fun foo(x: Int, y: Int) = x + y } diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleTopLevelFunctions.kt b/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleTopLevelFunctions.kt index 93536b69e39..3a4f53989c1 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleTopLevelFunctions.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/call/simpleTopLevelFunctions.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun String.foo(): Int = length var state = "Fail" diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/defaultAndNonDefaultIntertwined.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/defaultAndNonDefaultIntertwined.kt index d6c5f8a1f1a..dd21fcd0f72 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/defaultAndNonDefaultIntertwined.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/defaultAndNonDefaultIntertwined.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals fun foo(a: String, b: String = "b", c: String, d: String = "d", e: String) = diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/extensionFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/extensionFunction.kt index 0e590a98b6d..d98b779a2d3 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/extensionFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/extensionFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals fun String.sum(other: String = "b") = this + other diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/jvmStaticInObject.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/jvmStaticInObject.kt index 33ce67933a5..3e815a42458 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/jvmStaticInObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/jvmStaticInObject.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals object Obj { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/manyArgumentsOnlyOneDefault.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/manyArgumentsOnlyOneDefault.kt index e12b07e13db..0a75015efc0 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/manyArgumentsOnlyOneDefault.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/manyArgumentsOnlyOneDefault.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals // Generate: diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/manyMaskArguments.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/manyMaskArguments.kt index 39e0173ca90..8742cf70ac8 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/manyMaskArguments.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/manyMaskArguments.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals // Generate: diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/nonDefaultParameterOmitted.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/nonDefaultParameterOmitted.kt index dcef2cfa42c..df6397f71d5 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/nonDefaultParameterOmitted.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/nonDefaultParameterOmitted.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun foo(x: Int, y: Int = 2) = x + y fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/nullValue.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/nullValue.kt index a5d1695e243..28a1ca01827 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/nullValue.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/nullValue.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertNull fun foo(x: String? = "Fail") { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/ordinaryMethodIsInvokedWhenNoDefaultValuesAreUsed.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/ordinaryMethodIsInvokedWhenNoDefaultValuesAreUsed.kt index 76cef1f832b..3ed561224f0 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/ordinaryMethodIsInvokedWhenNoDefaultValuesAreUsed.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/ordinaryMethodIsInvokedWhenNoDefaultValuesAreUsed.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/primitiveDefaultValues.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/primitiveDefaultValues.kt index 17270d6ffa0..d38402226e1 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/primitiveDefaultValues.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/primitiveDefaultValues.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals fun primitives( diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/privateMemberFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/privateMemberFunction.kt index 449635c7f27..b3402f4803d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/privateMemberFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/privateMemberFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.IllegalCallableAccessException import kotlin.reflect.jvm.isAccessible diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleConstructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleConstructor.kt index 8cd6f0ea6d8..b086db53db5 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleConstructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class A(val result: String = "OK") fun box(): String = ::A.callBy(mapOf()).result diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleMemberFunciton.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleMemberFunciton.kt index e4219f898b4..2d846684a82 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleMemberFunciton.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleMemberFunciton.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class A(val result: String = "OK") { fun foo(x: Int = 42): String { assert(x == 42) { x } diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleTopLevelFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleTopLevelFunction.kt index bf99394bd30..e13823c034f 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleTopLevelFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleTopLevelFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun foo(result: String = "OK") = result fun box(): String = ::foo.callBy(mapOf()) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/annotationClassLiteral.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/annotationClassLiteral.kt index 11cc7f49045..aa20ee8ebab 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/annotationClassLiteral.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/annotationClassLiteral.kt @@ -1,7 +1,9 @@ +// WITH_REFLECT + import kotlin.test.assertEquals fun box(): String { assertEquals("Deprecated", Deprecated::class.simpleName) return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/arrays.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/arrays.kt index bdc934fb108..4bcae97c6e3 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/arrays.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/arrays.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* import kotlin.reflect.KClass diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/builtinClassLiterals.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/builtinClassLiterals.kt index 9d716000f73..89dd5e1739c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/builtinClassLiterals.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/builtinClassLiterals.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/genericArrays.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/genericArrays.kt index 46e3ed06abd..dcceed3cfc8 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/genericArrays.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/genericArrays.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* import kotlin.reflect.* import kotlin.reflect.jvm.* @@ -25,4 +27,4 @@ fun box(): String { assertEquals("[Ljava.lang.Object;", arrayClass>().jvmName) return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/genericClass.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/genericClass.kt index cf447a2544a..c80289cb43b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/genericClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/genericClass.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals class Generic diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/reifiedTypeClassLiteral.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/reifiedTypeClassLiteral.kt index 9b2012bbcd9..28d2d92b1de 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/reifiedTypeClassLiteral.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/reifiedTypeClassLiteral.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* class Klass diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/simpleClassLiteral.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/simpleClassLiteral.kt index 8833eaf475d..2749cd70720 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/simpleClassLiteral.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classLiterals/simpleClassLiteral.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class A fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classes/classSimpleName.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classes/classSimpleName.kt index 947ae376a42..c1846a891d0 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classes/classSimpleName.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classes/classSimpleName.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals class Klass diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classes/companionObject.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classes/companionObject.kt index fe985437cdb..af1a4d9444c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classes/companionObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classes/companionObject.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classes/defaultType.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classes/defaultType.kt index 802e0a765b7..3b2eb42c2cb 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classes/defaultType.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classes/defaultType.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.defaultType import kotlin.reflect.jvm.javaType import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classes/jvmName.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classes/jvmName.kt index 3cf93e0d87a..c9010f0ab92 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classes/jvmName.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classes/jvmName.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals import kotlin.test.assertTrue import kotlin.reflect.jvm.jvmName diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classes/localClassSimpleName.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classes/localClassSimpleName.kt index 28fff5a582e..027c49b58a8 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classes/localClassSimpleName.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classes/localClassSimpleName.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classes/nestedClasses.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classes/nestedClasses.kt index 1b4d048271c..be4202301ff 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classes/nestedClasses.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classes/nestedClasses.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK import kotlin.reflect.KClass diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classes/objectInstance.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classes/objectInstance.kt index f6cf2a7326c..8189d66d9e0 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classes/objectInstance.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classes/objectInstance.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals object Obj { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/classes/qualifiedName.kt b/compiler/testData/codegen/boxWithStdlib/reflection/classes/qualifiedName.kt index 26248238b38..05c3e25fe4c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/classes/qualifiedName.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/classes/qualifiedName.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals class Klass { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/constructors/classesWithoutConstructors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/constructors/classesWithoutConstructors.kt index 04027d34f89..67a43153b3b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/constructors/classesWithoutConstructors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/constructors/classesWithoutConstructors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.assertTrue diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/constructors/constructorName.kt b/compiler/testData/codegen/boxWithStdlib/reflection/constructors/constructorName.kt index 155efebed30..b0cda31133e 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/constructors/constructorName.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/constructors/constructorName.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals class A diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/constructors/primaryConstructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/constructors/primaryConstructor.kt index c44e31b5140..e3a18509a26 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/constructors/primaryConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/constructors/primaryConstructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertNull import kotlin.test.assertNotNull import kotlin.reflect.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/constructors/simpleGetConstructors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/constructors/simpleGetConstructors.kt index 3f4e52ac1c9..18901b33944 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/constructors/simpleGetConstructors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/constructors/simpleGetConstructors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import java.util.Collections import kotlin.reflect.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/anonymousObjectInInlinedLambda.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/anonymousObjectInInlinedLambda.kt index a1d3c1b512b..daca8f51a24 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/anonymousObjectInInlinedLambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/anonymousObjectInInlinedLambda.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + interface A { fun f(): String } diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/classInLambda.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/classInLambda.kt index d4603687624..3417d77e21b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/classInLambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/classInLambda.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun box(): String { val classInLambda = { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/functionExpressionInProperty.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/functionExpressionInProperty.kt index 01ac36f66dc..27991cd5f32 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/functionExpressionInProperty.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/functionExpressionInProperty.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + val property = fun () {} fun box(): String { @@ -13,4 +15,4 @@ fun box(): String { if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6368.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6368.kt index 768c41c5d60..2bce063fc60 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6368.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6368.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import java.util.HashMap interface R { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6691_lambdaInSamConstructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6691_lambdaInSamConstructor.kt index fd9007d3f42..702cda552f1 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6691_lambdaInSamConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6691_lambdaInSamConstructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + var lambda = {} class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInClassObject.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInClassObject.kt index cf83208b3e1..5a264567cb3 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInClassObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInClassObject.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class O { companion object { // Currently we consider in class O as the enclosing method of this lambda, diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInConstructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInConstructor.kt index 85bc0d54920..73ec065d49a 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInConstructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class C { val l: Any = {} } @@ -14,4 +16,4 @@ fun box(): String { if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInFunction.kt index c45d234b78c..548b78d25c6 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun box(): String { val l: Any = {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLambda.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLambda.kt index 57b47dfdfdc..1225c38da7c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLambda.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun box(): String { val l = { {} @@ -14,4 +16,4 @@ fun box(): String { if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalClassConstructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalClassConstructor.kt index 962f25c29ad..2c31a9e340b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalClassConstructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalClassConstructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + open class C fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalClassSuperCall.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalClassSuperCall.kt index b3089c8d0c6..05584ebd8fb 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalClassSuperCall.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalClassSuperCall.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + open class C(val a: Any) fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalFunction.kt index fab5d888d35..a229a090903 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInLocalFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun box(): String { fun foo(): Any { return {} @@ -14,4 +16,4 @@ fun box(): String { if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunction.kt index 25bf499b73c..84604bc1878 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class C { fun foo(): Any { return {} @@ -17,4 +19,4 @@ fun box(): String { if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunctionInLocalClass.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunctionInLocalClass.kt index 7fd0bc06989..49bddb4ecee 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunctionInLocalClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunctionInLocalClass.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun box(): String { class C { fun foo(): Any { @@ -16,4 +18,4 @@ fun box(): String { if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunctionInNestedClass.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunctionInNestedClass.kt index 4be5c4543b1..34aedc4e246 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunctionInNestedClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInMemberFunctionInNestedClass.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class C { class D { fun foo(): Any { @@ -18,4 +20,4 @@ fun box(): String { if (declaringClass != null) return "anonymous function has a declaring class: $declaringClass" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectDeclaration.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectDeclaration.kt index 7fb76f26102..410586993e4 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectDeclaration.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectDeclaration.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + object O { val f = {} } diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectExpression.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectExpression.kt index 9cf1821e1d3..2888456d7f4 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectExpression.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectExpression.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + interface C { val a: Any } diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectLiteralSuperCall.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectLiteralSuperCall.kt index aa603c03429..b6e164cdad4 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectLiteralSuperCall.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectLiteralSuperCall.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + open class C(val a: Any) fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPackage.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPackage.kt index ef9f1cb35bd..8532bceafb1 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPackage.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPackage.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + val l: Any = {} fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPropertyGetter.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPropertyGetter.kt index 7d7885cf438..a9545aad404 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPropertyGetter.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPropertyGetter.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + val l: Any get() = {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPropertySetter.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPropertySetter.kt index 302b74b5494..4e001b59a52 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPropertySetter.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInPropertySetter.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + var _l: Any = "" var l: Any diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/localClassInTopLevelFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/localClassInTopLevelFunction.kt index b56966d171b..7bc0245f394 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/localClassInTopLevelFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/localClassInTopLevelFunction.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // KT-4234 fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/objectInLambda.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/objectInLambda.kt index 5671b426673..adf8d285b44 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/objectInLambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/objectInLambda.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + fun box(): String { val objectInLambda = { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/functions/functionFromStdlib.kt b/compiler/testData/codegen/boxWithStdlib/reflection/functions/functionFromStdlib.kt index 472d2475e58..231c44f208d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/functions/functionFromStdlib.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/functions/functionFromStdlib.kt @@ -1,5 +1,7 @@ +// WITH_REFLECT + fun doStuff(fn: String.() -> String) = "ok".fn() fun box(): String { return doStuff(String::toUpperCase) -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/functions/platformName.kt b/compiler/testData/codegen/boxWithStdlib/reflection/functions/platformName.kt index 9d84219d94e..22db575e7b3 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/functions/platformName.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/functions/platformName.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + @JvmName("Fail") fun OK() {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/functions/privateMemberFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/functions/privateMemberFunction.kt index 313b1cbe0bb..1fe3bf243d2 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/functions/privateMemberFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/functions/privateMemberFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/functions/simpleGetFunctions.kt b/compiler/testData/codegen/boxWithStdlib/reflection/functions/simpleGetFunctions.kt index f3a8415c73e..85cfc49d806 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/functions/simpleGetFunctions.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/functions/simpleGetFunctions.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* open class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/functions/simpleNames.kt b/compiler/testData/codegen/boxWithStdlib/reflection/functions/simpleNames.kt index 417d2391154..9df53d8ee51 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/functions/simpleNames.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/functions/simpleNames.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals fun foo() {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/covariantOverride.kt b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/covariantOverride.kt index e49c7ae13b3..5d8165ed1d3 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/covariantOverride.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/covariantOverride.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + interface A { fun foo(): Collection } diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/genericBackingFieldSignature.kt b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/genericBackingFieldSignature.kt index 02a26b8a3d1..583d090ed38 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/genericBackingFieldSignature.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/genericBackingFieldSignature.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT //test for KT-3722 Write correct generic type information for generated fields import kotlin.properties.Delegates diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/genericMethodSignature.kt b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/genericMethodSignature.kt index d55b875746b..9b827b45c2d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/genericMethodSignature.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/genericMethodSignature.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class Z {} class TParam {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt11121.kt b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt11121.kt index 5dfabb2cd86..d322041345d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt11121.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt11121.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class B interface A> { @@ -20,4 +22,4 @@ fun box(): String { if (declaredProperty.toGenericString() != "public static T A\$DefaultImpls.getZ(A,T)") return "fail 2: ${declaredProperty.toGenericString()}" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt5112.kt b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt5112.kt index 5356819b58a..2ac6d0d0de0 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt5112.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt5112.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + package test class G(val s: T) { @@ -23,4 +25,4 @@ fun box(): String { val genericTypeInClass = ErrorsJvmClass::class.java.getField("param").getGenericType() if (genericTypeInClass.toString() != "test.G") return "fail1: genericTypeInClass" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt6106.kt b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt6106.kt index e14ab00fe62..5a6c85bef24 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt6106.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt6106.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + package test open class B diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/java.kt b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/java.kt index be5fdc6d292..5afce1b22ed 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/java.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/java.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass fun checkPrimitive(clazz: Class<*>, expected: String) { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaObjectType.kt b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaObjectType.kt index 21ddc05e859..36aab5acef5 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaObjectType.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaObjectType.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass fun check(clazz: Class<*>?, expected: String) { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaObjectTypeReified.kt b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaObjectTypeReified.kt index b1fca4906fd..7844911a818 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaObjectTypeReified.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaObjectTypeReified.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass inline fun check(expected: String) { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaPrimitiveType.kt b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaPrimitiveType.kt index b4a68e8ad4d..6cdc3e159b0 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaPrimitiveType.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaPrimitiveType.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass fun check(clazz: Class<*>?, expected: String) { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaPrimitiveTypeReified.kt b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaPrimitiveTypeReified.kt index 0eb61184d65..8f2da244504 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaPrimitiveTypeReified.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaPrimitiveTypeReified.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass inline fun check(expected: String) { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaReified.kt b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaReified.kt index a681d32fdc9..b2aefb60254 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaReified.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/javaProperties/javaReified.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass inline fun check(expected: String) { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/array.kt b/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/array.kt index d5a7046a678..ef4f8a60001 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/array.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/array.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/basic.kt b/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/basic.kt index 07e70c679cf..91660147ebf 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/basic.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/basic.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/checkcast.kt b/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/checkcast.kt index b239fa76926..faee03ae10b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/checkcast.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/checkcast.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/vararg.kt b/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/vararg.kt index 12557abece1..cebff8661f8 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/vararg.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/kClassInAnnotation/vararg.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KClass @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/lambdaClasses/parameterNamesAndNullability.kt b/compiler/testData/codegen/boxWithStdlib/reflection/lambdaClasses/parameterNamesAndNullability.kt index 96744628f8c..9aa1534a65d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/lambdaClasses/parameterNamesAndNullability.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/lambdaClasses/parameterNamesAndNullability.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/constructor.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/constructor.kt index 3523def22a6..3ddee0eee87 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/constructor.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/constructor.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/extensionProperty.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/extensionProperty.kt index a4d0c5c1036..ec5059ecf06 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/extensionProperty.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/extensionProperty.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/fakeOverrides/javaFieldGetterSetter.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/fakeOverrides/javaFieldGetterSetter.kt index d32b3fc3c59..824a0572770 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/fakeOverrides/javaFieldGetterSetter.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/fakeOverrides/javaFieldGetterSetter.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // KT-8131 Cannot find backing field in ancestor class via reflection import kotlin.reflect.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/fakeOverrides/javaMethod.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/fakeOverrides/javaMethod.kt index d22cecef010..82f0e71524c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/fakeOverrides/javaMethod.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/fakeOverrides/javaMethod.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/functions.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/functions.kt index f7201fed09e..a2f0325e037 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/functions.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/functions.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/jvmStatic/companionObjectFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/jvmStatic/companionObjectFunction.kt index a1f4893e6fc..f211f3b0d41 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/jvmStatic/companionObjectFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/jvmStatic/companionObjectFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KFunction import kotlin.reflect.jvm.* import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/jvmStatic/objectFunction.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/jvmStatic/objectFunction.kt index 056b06fc381..23004bb1337 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/jvmStatic/objectFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/jvmStatic/objectFunction.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KFunction import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/mappedClassIsEqualToClassLiteral.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/mappedClassIsEqualToClassLiteral.kt index d0d863e0119..de82320ff67 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/mappedClassIsEqualToClassLiteral.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/mappedClassIsEqualToClassLiteral.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + class A fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/memberProperty.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/memberProperty.kt index da042a50a22..0a33eda138c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/memberProperty.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/memberProperty.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/propertyAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/propertyAccessors.kt index 2cfdf212a63..8cdd7b189d9 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/propertyAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/propertyAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/propertyAccessorsWithJvmName.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/propertyAccessorsWithJvmName.kt index 298ab6b9117..c4074c7ea49 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/propertyAccessorsWithJvmName.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/propertyAccessorsWithJvmName.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* var state: String = "value" diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/syntheticFields.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/syntheticFields.kt index 54332c52819..cd87506296f 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/syntheticFields.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/syntheticFields.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.kotlin enum class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/topLevelProperty.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/topLevelProperty.kt index 4ba52bdb2d9..d3c78a98873 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/topLevelProperty.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/topLevelProperty.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/array.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/array.kt index 260d143c279..f84011c27b3 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/array.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/array.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK import java.lang.reflect.GenericArrayType diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/constructors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/constructors.kt index e38f0b5762e..9a20a8b0f1b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/constructors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/constructors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/memberFunctions.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/memberFunctions.kt index 91c27d93255..30e318f0d7b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/memberFunctions.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/memberFunctions.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.javaType import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/overrideAnyWithPrimitive.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/overrideAnyWithPrimitive.kt index c1be4965aa7..ddca907bd8c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/overrideAnyWithPrimitive.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/overrideAnyWithPrimitive.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/parameterizedTypes.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/parameterizedTypes.kt index b86e7e774c2..e844e329196 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/parameterizedTypes.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/parameterizedTypes.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK import java.lang.reflect.ParameterizedType diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/propertyAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/propertyAccessors.kt index ba37a5a0689..5cc2ac44ac5 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/propertyAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/propertyAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KMutableProperty import kotlin.reflect.jvm.javaType import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/topLevelFunctions.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/topLevelFunctions.kt index 8e40b3e9b83..da34b786432 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/topLevelFunctions.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/topLevelFunctions.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/typeParameters.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/typeParameters.kt index 9aa7b2c8126..03ec38f32c4 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/typeParameters.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/typeParameters.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK import java.lang.reflect.TypeVariable diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/unit.kt b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/unit.kt index 7e0f21d1734..05073d25467 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/unit.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/mapping/types/unit.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/callableReferencesEqualToCallablesFromAPI.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/callableReferencesEqualToCallablesFromAPI.kt index 1ff5c16f546..7daf097fb0c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/callableReferencesEqualToCallablesFromAPI.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/callableReferencesEqualToCallablesFromAPI.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/classToString.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/classToString.kt index 57c2a3a748c..e36b58ac701 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/classToString.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/classToString.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/extensionPropertyReceiverToString.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/extensionPropertyReceiverToString.kt index 5b26edcad0d..6c6c29a940f 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/extensionPropertyReceiverToString.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/extensionPropertyReceiverToString.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KProperty1 import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/functionEqualsHashCode.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/functionEqualsHashCode.kt index bc313072f2e..c014b754a99 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/functionEqualsHashCode.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/functionEqualsHashCode.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* fun top() = 42 diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/functionToString.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/functionToString.kt index c31d26a62d5..62e122087f6 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/functionToString.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/functionToString.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + package test import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/memberExtensionToString.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/memberExtensionToString.kt index 46e5b58005e..d3ec360b10b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/memberExtensionToString.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/memberExtensionToString.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/parametersEqualsHashCode.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/parametersEqualsHashCode.kt index bcc19a09e9d..1b57bd974bf 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/parametersEqualsHashCode.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/parametersEqualsHashCode.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/parametersToString.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/parametersToString.kt index f3857901927..721c180add6 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/parametersToString.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/parametersToString.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* fun Int.foo(s: String) {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/propertyEqualsHashCode.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/propertyEqualsHashCode.kt index 476b185d961..eb6fefb226b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/propertyEqualsHashCode.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/propertyEqualsHashCode.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* val top = 42 diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/propertyToString.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/propertyToString.kt index 7107e4cdca1..d31fc271d2e 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/propertyToString.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/propertyToString.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + package test import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/typeEqualsHashCode.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/typeEqualsHashCode.kt index 921054c5a39..c0bb6105ab9 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/typeEqualsHashCode.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/typeEqualsHashCode.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KType import kotlin.test.assertEquals import kotlin.test.assertNotEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/typeToString.kt b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/typeToString.kt index a74b96e38b0..2f718fef6fb 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/typeToString.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/methodsFromAny/typeToString.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals fun String?.foo(x: Int, y: Array, z: IntArray, w: List>>) {} diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/functionParameterNameAndIndex.kt b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/functionParameterNameAndIndex.kt index 81726490c9b..a83e8b5a130 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/functionParameterNameAndIndex.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/functionParameterNameAndIndex.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/isMarkedNullable.kt b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/isMarkedNullable.kt index 52009e065e5..42bf721d070 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/isMarkedNullable.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/isMarkedNullable.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.assertEquals import kotlin.test.assertTrue diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/isOptional.kt b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/isOptional.kt index 1fe125c3baa..7b557b8c0c4 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/isOptional.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/isOptional.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.* open class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/kinds.kt b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/kinds.kt index a6d7b05f6d0..4709aae24cd 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/kinds.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/kinds.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.KParameter.Kind.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/propertySetter.kt b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/propertySetter.kt index 1c53cda44b8..0a722fa6940 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/parameters/propertySetter.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/parameters/propertySetter.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/accessorNames.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/accessorNames.kt index c5b09da74f2..512b387b562 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/accessorNames.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/accessorNames.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/extensionPropertyAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/extensionPropertyAccessors.kt index 46dc4fe8829..9a6c268f28f 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/extensionPropertyAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/extensionPropertyAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals var state: String = "" diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/memberExtensions.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/memberExtensions.kt index 7c7113b4849..f1fb97ac71c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/memberExtensions.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/memberExtensions.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.assertEquals diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/memberPropertyAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/memberPropertyAccessors.kt index dcf3c560b42..e70d5601802 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/memberPropertyAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/memberPropertyAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals class C(var state: String) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/topLevelPropertyAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/topLevelPropertyAccessors.kt index 49ab1f5ef8e..d404091d960 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/topLevelPropertyAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/accessors/topLevelPropertyAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.test.assertEquals var state: String = "" diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/allVsDeclared.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/allVsDeclared.kt index 3f7a0bc2033..e598b048b25 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/allVsDeclared.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/allVsDeclared.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/callPrivatePropertyFromGetProperties.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/callPrivatePropertyFromGetProperties.kt index 1959cc102a4..5e7dc81c727 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/callPrivatePropertyFromGetProperties.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/callPrivatePropertyFromGetProperties.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/fakeOverridesInSubclass.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/fakeOverridesInSubclass.kt index 2e015f4ea08..dce05472405 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/fakeOverridesInSubclass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/fakeOverridesInSubclass.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/genericClassLiteralPropertyReceiverIsStar.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/genericClassLiteralPropertyReceiverIsStar.kt index 18c0b2b52d7..e7ffcc897a7 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/genericClassLiteralPropertyReceiverIsStar.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/genericClassLiteralPropertyReceiverIsStar.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/getExtensionPropertiesMutableVsReadonly.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/getExtensionPropertiesMutableVsReadonly.kt index d2c66f58b34..eb88cf370b7 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/getExtensionPropertiesMutableVsReadonly.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/getExtensionPropertiesMutableVsReadonly.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* var storage = "before" diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/getPropertiesMutableVsReadonly.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/getPropertiesMutableVsReadonly.kt index 9d29e03f7ce..da2ff7e0a3e 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/getPropertiesMutableVsReadonly.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/getPropertiesMutableVsReadonly.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* class A(val readonly: String) { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/invokeKProperty.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/invokeKProperty.kt index b9337faa934..e98ac2e2bfa 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/invokeKProperty.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/invokeKProperty.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.declaredMemberProperties class A(val foo: String) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/memberAndMemberExtensionWithSameName.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/memberAndMemberExtensionWithSameName.kt index ac93a917c42..5e104424669 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/memberAndMemberExtensionWithSameName.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/memberAndMemberExtensionWithSameName.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateClassVal.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateClassVal.kt index 2eea52e18cd..fc2d23ddf50 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateClassVal.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateClassVal.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.isAccessible diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateClassVar.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateClassVar.kt index e33d6e8f321..07c1667458f 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateClassVar.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateClassVar.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.isAccessible diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateFakeOverrideFromSuperclass.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateFakeOverrideFromSuperclass.kt index 3cf71da4021..9b48253d31a 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateFakeOverrideFromSuperclass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateFakeOverrideFromSuperclass.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* open class A(private val p: Int) diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateJvmStaticVarInObject.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateJvmStaticVarInObject.kt index d6434e551a7..05f06ee95ef 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateJvmStaticVarInObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateJvmStaticVarInObject.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privatePropertyCallIsAccessibleOnAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privatePropertyCallIsAccessibleOnAccessors.kt index b85c30595dc..18e3449e2f2 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privatePropertyCallIsAccessibleOnAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privatePropertyCallIsAccessibleOnAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* import kotlin.test.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateToThisAccessors.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateToThisAccessors.kt index bbbacc99338..eeb42fa475a 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateToThisAccessors.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/privateToThisAccessors.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.* diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/propertyOfNestedClassAndArrayType.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/propertyOfNestedClassAndArrayType.kt index 8d4bc7a3181..caa8d09c580 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/propertyOfNestedClassAndArrayType.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/propertyOfNestedClassAndArrayType.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.KMutableProperty1 class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/protectedClassVar.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/protectedClassVar.kt index c28c12e597c..6ca50d448d5 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/protectedClassVar.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/protectedClassVar.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* import kotlin.reflect.jvm.isAccessible diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/publicClassValAccessible.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/publicClassValAccessible.kt index 3fe95c7c7e0..e0b9e61d21a 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/publicClassValAccessible.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/publicClassValAccessible.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.jvm.accessible class Result { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/properties/simpleGetProperties.kt b/compiler/testData/codegen/boxWithStdlib/reflection/properties/simpleGetProperties.kt index 30dca9b3264..2ea1828a819 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/properties/simpleGetProperties.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/properties/simpleGetProperties.kt @@ -1,3 +1,5 @@ +// WITH_REFLECT + import kotlin.reflect.* class A(param: String) { diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/specialBuiltIns/getMembersOfStandardJavaClasses.kt b/compiler/testData/codegen/boxWithStdlib/reflection/specialBuiltIns/getMembersOfStandardJavaClasses.kt index d5ff8a0dadd..4a3b39d8e7b 100644 --- a/compiler/testData/codegen/boxWithStdlib/reflection/specialBuiltIns/getMembersOfStandardJavaClasses.kt +++ b/compiler/testData/codegen/boxWithStdlib/reflection/specialBuiltIns/getMembersOfStandardJavaClasses.kt @@ -1,3 +1,4 @@ +// WITH_REFLECT // FULL_JDK // See KT-11258 Incorrect resolution sequence for Java field diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/Kt1149.kt b/compiler/testData/codegen/boxWithStdlib/regressions/Kt1149.kt index 2fd0d29e972..f0786dbf85a 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/Kt1149.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/Kt1149.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package test.regressions.kt1149 import java.util.ArrayList diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/Kt1619Test.kt b/compiler/testData/codegen/boxWithStdlib/regressions/Kt1619Test.kt index 2b435b31ee9..d8f38f37765 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/Kt1619Test.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/Kt1619Test.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package regressions class Kt1619Test { @@ -15,4 +17,3 @@ class Kt1619Test { fun box(): String { return if (Kt1619Test().testCollectionNotNullCanBeUsedForNullables() == 2) "OK" else "fail" } - diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/Kt2495Test.kt b/compiler/testData/codegen/boxWithStdlib/regressions/Kt2495Test.kt index 8a8dee2137a..072eba9a2f8 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/Kt2495Test.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/Kt2495Test.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package regressions fun f(xs: Iterator): Int { @@ -12,4 +14,4 @@ fun box(): String { val list = arrayListOf(1, 2, 3) val result = f(list.iterator()) return if (6 == result) "OK" else "fail" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/generic.kt b/compiler/testData/codegen/boxWithStdlib/regressions/generic.kt index 21203c396d3..8e1c1f3f644 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/generic.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/generic.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.* fun ArrayList.findAll(predicate: (T) -> Boolean): ArrayList { diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/getGenericInterfaces.kt b/compiler/testData/codegen/boxWithStdlib/regressions/getGenericInterfaces.kt index b7ba0bc09f6..616abc83f5d 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/getGenericInterfaces.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/getGenericInterfaces.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // KT-4485 getGenericInterfaces vs getInterfaces for kotlin classes class SimpleClass diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt1172.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt1172.kt index ecc936bcf7c..aa384349722 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt1172.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt1172.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package test.regressions.kt1172 import kotlin.concurrent.* diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt1568.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt1568.kt index 393b4b87392..5d5b2881712 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt1568.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt1568.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box() : String { val i = 1 return if(i.javaClass.getSimpleName() == "int") "OK" else "fail" diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt1779.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt1779.kt index d1027d7f1d3..ffcb7d79844 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt1779.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt1779.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.collections.AbstractIterator class MyIterator : AbstractIterator() { diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt1800.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt1800.kt index 94187405f67..d07dd2aac2b 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt1800.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt1800.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME //KT-1800 error/NonExistentClass generated on runtime package i diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt1932.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt1932.kt index 89c2a937e80..0f6544d3075 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt1932.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt1932.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.lang.annotation.Annotation @Retention(AnnotationRetention.RUNTIME) diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt2017.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt2017.kt index a48430c1bf6..3b1b64b5dc1 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt2017.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt2017.kt @@ -1,4 +1,6 @@ +// WITH_RUNTIME + fun box(): String { val sorted = arrayListOf("1", "3", "2").sorted() return if (sorted != arrayListOf("1", "2", "3")) "$sorted" else "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt2246.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt2246.kt index 5fa670d53ce..657229c051d 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt2246.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt2246.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { kotlin.assert(true) return "OK" diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt2318.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt2318.kt index 359283c9de8..7bc54ac1f2c 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt2318.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt2318.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { Boolean::class.java Byte::class.java diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt2593.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt2593.kt index 790bf56ab49..da0c558175c 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt2593.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt2593.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun foo() { if (1==1) { 1.javaClass diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt3046.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt3046.kt index 6297b6a74d2..ef9733aa748 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt3046.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt3046.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val bool = true if (bool.javaClass != Boolean::class.java) return "javaClass function on boolean fails" diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt344.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt344.kt index a83fbaf9354..3afa534ce02 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt344.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt344.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun s0() : Boolean { val y = "222" val foo = { diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt3442.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt3442.kt index 0876d42e1b9..0a28219ff5f 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt3442.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt3442.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val m = hashMapOf() m.put("b", null) diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt4259.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt4259.kt index c486ed77d84..d1d4cb289ff 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt4259.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt4259.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val s: String? = "a" val o: Char? = s?.get(0) diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt4262.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt4262.kt index 94b4fe059ea..8cc4cb2d4e6 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt4262.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt4262.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun > Byte.toEnum(clazz : Class) : E = (clazz.getMethod("values").invoke(null) as Array)[this.toInt()] diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt5056.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt5056.kt index fb265c626d2..eb6855473ee 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt5056.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt5056.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val list = arrayOf("a", "c", "b").sorted() return if (list.toString() == "[a, b, c]") "OK" else "Fail: $list" diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt5786_privateWithDefault.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt5786_privateWithDefault.kt index c0984e29da3..916ed482c60 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt5786_privateWithDefault.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt5786_privateWithDefault.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { run { test("ok") diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt5953.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt5953.kt index c18c893f441..3a7cdb1f7e5 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt5953.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt5953.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun box(): String { val res = (1..3).map { it -> if (it == 1) diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt6434.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt6434.kt index 2ad094dbcdd..d3222799030 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt6434.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt6434.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + enum class E { VALUE, VALUE2 @@ -25,4 +27,4 @@ class C(val nums: Map) { fun box(): String { val res = C(hashMapOf(E.VALUE to 11, E.VALUE2 to 12)).normalizedNums.values.sorted().joinToString() return if ("0.0, 1.0" == res) "OK" else "fail $res" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt6434_2.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt6434_2.kt index f67a2d90e3e..19cd842906a 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt6434_2.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt6434_2.kt @@ -1,7 +1,9 @@ +// WITH_RUNTIME + fun box(): String { val p = 1 to 1 val (e, num) = p val a = 1f return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt715.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt715.kt index 123c9d8c643..e4696a97c91 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt715.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt715.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.* @Suppress("REIFIED_TYPE_PARAMETER_NO_INLINE") diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt998.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt998.kt index 08e2887f04b..7fef173ff74 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/kt998.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt998.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun findPairless(a : IntArray) : Int { loop@ for (i in a.indices) { for (j in a.indices) { diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/objectCaptureOuterConstructorProperty.kt b/compiler/testData/codegen/boxWithStdlib/regressions/objectCaptureOuterConstructorProperty.kt index a425a2b416c..b9011debfe9 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/objectCaptureOuterConstructorProperty.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/objectCaptureOuterConstructorProperty.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + interface Stream { fun iterator(): Iterator } diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/referenceToSelfInLocal.kt b/compiler/testData/codegen/boxWithStdlib/regressions/referenceToSelfInLocal.kt index 605bb372b3e..323e94cfd07 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/referenceToSelfInLocal.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/referenceToSelfInLocal.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // KT-4351 Cannot resolve reference to self in init of class local to function fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/typeCastException.kt b/compiler/testData/codegen/boxWithStdlib/regressions/typeCastException.kt index 972f550e342..0cce8c8a8a1 100644 --- a/compiler/testData/codegen/boxWithStdlib/regressions/typeCastException.kt +++ b/compiler/testData/codegen/boxWithStdlib/regressions/typeCastException.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.ArrayList // KT-2823 TypeCastException has no message diff --git a/compiler/testData/codegen/boxWithStdlib/reified/DIExample.kt b/compiler/testData/codegen/boxWithStdlib/reified/DIExample.kt index 6ef4caf88ea..b1c5325c16d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/DIExample.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/DIExample.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals import kotlin.reflect.KProperty diff --git a/compiler/testData/codegen/boxWithStdlib/reified/anonymousObject.kt b/compiler/testData/codegen/boxWithStdlib/reified/anonymousObject.kt index 8178965a31f..ef39d672057 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/anonymousObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/anonymousObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals abstract class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectNoPropagate.kt b/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectNoPropagate.kt index 0756a97ccb5..95b984f98b6 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectNoPropagate.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectNoPropagate.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals interface A { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectReifiedSupertype.kt b/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectReifiedSupertype.kt index 80b0fc20b68..3b800e85cda 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectReifiedSupertype.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectReifiedSupertype.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals abstract class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/approximateCapturedTypes.kt b/compiler/testData/codegen/boxWithStdlib/reified/approximateCapturedTypes.kt index 1731a9a6d62..9eb4523f51c 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/approximateCapturedTypes.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/approximateCapturedTypes.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // Basically this test checks that no captured type used as argument for signature mapping class SwOperator: Operator, T> diff --git a/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/instanceOf.kt b/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/instanceOf.kt index d8af7f30937..a0c4808ade4 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/instanceOf.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/instanceOf.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + inline fun foo(x: Any?) = Pair(x is T, x is T?) fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/instanceOfArrays.kt b/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/instanceOfArrays.kt index a9ce7dce4e0..ba0f2d81040 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/instanceOfArrays.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/instanceOfArrays.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + inline fun foo(x: Any?) = Pair(x is T, x is T?) inline fun bar(y: Any?) = foo>(y) inline fun barNullable(y: Any?) = foo?>(y) diff --git a/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/jClass.kt b/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/jClass.kt index a75a7b0bf17..0f0f5b3e939 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/jClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/jClass.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + inline fun jClass() = T::class.java inline fun jClassArray() = jClass>() diff --git a/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/jaggedArrayOfNulls.kt b/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/jaggedArrayOfNulls.kt index d15a19ec769..d0df83ecb48 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/jaggedArrayOfNulls.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/arraysReification/jaggedArrayOfNulls.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + inline fun jaggedArrayOfNulls(): Array?> = arrayOfNulls>(1) fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/checkcast.kt b/compiler/testData/codegen/boxWithStdlib/reified/checkcast.kt index 833a6a0db65..3b10a4bd5f8 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/checkcast.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/checkcast.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun checkcast(x: Any?): T { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/copyToArray.kt b/compiler/testData/codegen/boxWithStdlib/reified/copyToArray.kt index 6e880e125b6..4cbf10bdec5 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/copyToArray.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/copyToArray.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun copy(c: Collection): Array { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/defaultJavaClass.kt b/compiler/testData/codegen/boxWithStdlib/reified/defaultJavaClass.kt index 918afc81466..dc168797105 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/defaultJavaClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/defaultJavaClass.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun foo(x: Class = T::class.java): String = x.getName() diff --git a/compiler/testData/codegen/boxWithStdlib/reified/filterIsInstance.kt b/compiler/testData/codegen/boxWithStdlib/reified/filterIsInstance.kt index 6c80a55f698..1c3e60a4297 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/filterIsInstance.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/filterIsInstance.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun Array.filterIsInstance(): List { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/innerAnonymousObject.kt b/compiler/testData/codegen/boxWithStdlib/reified/innerAnonymousObject.kt index aaafb952e31..e0b740f9386 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/innerAnonymousObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/innerAnonymousObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals abstract class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/instanceof.kt b/compiler/testData/codegen/boxWithStdlib/reified/instanceof.kt index 4d20512d772..e6d655c9f64 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/instanceof.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/instanceof.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + inline fun isinstance(x: Any?): Boolean { return x is T } diff --git a/compiler/testData/codegen/boxWithStdlib/reified/javaClass.kt b/compiler/testData/codegen/boxWithStdlib/reified/javaClass.kt index 7d487e720d4..e3c221a1cce 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/javaClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/javaClass.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun javaClassName(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/nestedReified.kt b/compiler/testData/codegen/boxWithStdlib/reified/nestedReified.kt index 2ec778a7c9d..8f07a4026da 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/nestedReified.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/nestedReified.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun foo(): Array { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/nestedReifiedSignature.kt b/compiler/testData/codegen/boxWithStdlib/reified/nestedReifiedSignature.kt index 04210636a3e..d1469bf61be 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/nestedReifiedSignature.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/nestedReifiedSignature.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals open class A diff --git a/compiler/testData/codegen/boxWithStdlib/reified/newArrayInt.kt b/compiler/testData/codegen/boxWithStdlib/reified/newArrayInt.kt index 017cafb91b3..51154e9f1e7 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/newArrayInt.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/newArrayInt.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME inline fun createArray(n: Int, crossinline block: () -> T): Array { return Array(n) { block() } diff --git a/compiler/testData/codegen/boxWithStdlib/reified/nonInlineableLambdaInReifiedFunction.kt b/compiler/testData/codegen/boxWithStdlib/reified/nonInlineableLambdaInReifiedFunction.kt index 2dc96dcde97..a2ac77adaa7 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/nonInlineableLambdaInReifiedFunction.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/nonInlineableLambdaInReifiedFunction.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(block: () -> String) = block() diff --git a/compiler/testData/codegen/boxWithStdlib/reified/recursiveInnerAnonymousObject.kt b/compiler/testData/codegen/boxWithStdlib/reified/recursiveInnerAnonymousObject.kt index c6499a5e810..f72bd891457 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/recursiveInnerAnonymousObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/recursiveInnerAnonymousObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals abstract class A { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/recursiveNewArray.kt b/compiler/testData/codegen/boxWithStdlib/reified/recursiveNewArray.kt index b740e7cdea3..2054cd33d8d 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/recursiveNewArray.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/recursiveNewArray.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME inline fun createArray(n: Int, crossinline block: () -> T): Array { return Array(n) { block() } diff --git a/compiler/testData/codegen/boxWithStdlib/reified/recursiveNonInlineableLambda.kt b/compiler/testData/codegen/boxWithStdlib/reified/recursiveNonInlineableLambda.kt index 9fb50925297..8380a599dee 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/recursiveNonInlineableLambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/recursiveNonInlineableLambda.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(block: () -> String) = block() diff --git a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObject.kt b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObject.kt index 0c0537e2b48..858cc0511c2 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(block: () -> String) = block() diff --git a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObjectWithinReified.kt b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObjectWithinReified.kt index 5ac8e112c04..dc3eeda0a59 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObjectWithinReified.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObjectWithinReified.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(block: () -> String) = block() diff --git a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineIntoNonInlineableLambda.kt b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineIntoNonInlineableLambda.kt index 29a4dd4b4f2..1c923c0d2a9 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineIntoNonInlineableLambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineIntoNonInlineableLambda.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(block: () -> String) = block() diff --git a/compiler/testData/codegen/boxWithStdlib/reified/safecast.kt b/compiler/testData/codegen/boxWithStdlib/reified/safecast.kt index cb31cc60793..10171dd33fe 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/safecast.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/safecast.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun safecast(x: Any?): T? { diff --git a/compiler/testData/codegen/boxWithStdlib/reified/sameIndexRecursive.kt b/compiler/testData/codegen/boxWithStdlib/reified/sameIndexRecursive.kt index 3abebd96224..bea6ef5288f 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/sameIndexRecursive.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/sameIndexRecursive.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME inline fun createArray(n: Int, crossinline block: () -> Pair): Pair, Array> { return Pair(Array(n) { block().first }, Array(n) { block().second }) diff --git a/compiler/testData/codegen/boxWithStdlib/reified/spreads.kt b/compiler/testData/codegen/boxWithStdlib/reified/spreads.kt index 066f13b6f6e..d0861109cbb 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/spreads.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/spreads.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(vararg a: T) = a.size diff --git a/compiler/testData/codegen/boxWithStdlib/reified/varargs.kt b/compiler/testData/codegen/boxWithStdlib/reified/varargs.kt index d593428d2de..73eaba238dc 100644 --- a/compiler/testData/codegen/boxWithStdlib/reified/varargs.kt +++ b/compiler/testData/codegen/boxWithStdlib/reified/varargs.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(vararg a: T) = a.size diff --git a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/differentTypes.kt b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/differentTypes.kt index c41967e3ed5..2d38eb00026 100644 --- a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/differentTypes.kt +++ b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/differentTypes.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun bar(x: Int, y: Long, z: Byte, s: String) = x.toString() + y.toString() + z.toString() + s diff --git a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/primitiveMerge.kt b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/primitiveMerge.kt index 8044be982e2..7a0c44138c9 100644 --- a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/primitiveMerge.kt +++ b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/primitiveMerge.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun bar() : Boolean = true diff --git a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/simple.kt b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/simple.kt index 23867793db6..02c77ef3f87 100644 --- a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/simple.kt +++ b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/simple.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun bar(x: Int) : Int { diff --git a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/unreachableMarker.kt b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/unreachableMarker.kt index e2b0aa8d959..303293d3cd8 100644 --- a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/unreachableMarker.kt +++ b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/unreachableMarker.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun bar(block: () -> String) : String { diff --git a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/withLambda.kt b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/withLambda.kt index 4c229244e47..44e64d5a9bc 100644 --- a/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/withLambda.kt +++ b/compiler/testData/codegen/boxWithStdlib/storeStackBeforeInline/withLambda.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals inline fun bar(x: String, block: (String) -> String) = "def" + block(x) diff --git a/compiler/testData/codegen/boxWithStdlib/strings/forInString.kt b/compiler/testData/codegen/boxWithStdlib/strings/forInString.kt index 95d3eb0ee9a..f5bcbbde7be 100644 --- a/compiler/testData/codegen/boxWithStdlib/strings/forInString.kt +++ b/compiler/testData/codegen/boxWithStdlib/strings/forInString.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun foo(): Int { var sum = 0 for (c in "239") diff --git a/compiler/testData/codegen/boxWithStdlib/strings/stringPlusOnlyWorksOnString.kt b/compiler/testData/codegen/boxWithStdlib/strings/stringPlusOnlyWorksOnString.kt index 124a0fe2d9a..b8ac015ccae 100644 --- a/compiler/testData/codegen/boxWithStdlib/strings/stringPlusOnlyWorksOnString.kt +++ b/compiler/testData/codegen/boxWithStdlib/strings/stringPlusOnlyWorksOnString.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.ArrayList fun box(): String { diff --git a/compiler/testData/codegen/boxWithStdlib/synthetic/syntheticAccessorNames.kt b/compiler/testData/codegen/boxWithStdlib/synthetic/syntheticAccessorNames.kt index b2393e95b9d..403a142a7bb 100644 --- a/compiler/testData/codegen/boxWithStdlib/synthetic/syntheticAccessorNames.kt +++ b/compiler/testData/codegen/boxWithStdlib/synthetic/syntheticAccessorNames.kt @@ -1,3 +1,4 @@ +// WITH_RUNTIME // This test checks that synthetic accessors generated by Kotlin compiler have names starting with "access$" // This is crucial for some JVM frameworks like Quasar which rely on the bytecode being similar to the one generated by javac // See https://youtrack.jetbrains.com/issue/KT-6870 diff --git a/compiler/testData/codegen/boxWithStdlib/toArray/copyToArray.kt b/compiler/testData/codegen/boxWithStdlib/toArray/copyToArray.kt index 54b11577942..7b6f7faeab8 100644 --- a/compiler/testData/codegen/boxWithStdlib/toArray/copyToArray.kt +++ b/compiler/testData/codegen/boxWithStdlib/toArray/copyToArray.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.Arrays fun box(): String { @@ -8,4 +10,4 @@ fun box(): String { if (str != "[2, 3, 9]") return str return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/toArray/kt3177-copyToArray.kt b/compiler/testData/codegen/boxWithStdlib/toArray/kt3177-copyToArray.kt index c64f5d38573..b9f91e69bda 100644 --- a/compiler/testData/codegen/boxWithStdlib/toArray/kt3177-copyToArray.kt +++ b/compiler/testData/codegen/boxWithStdlib/toArray/kt3177-copyToArray.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.ArrayList import java.util.Arrays diff --git a/compiler/testData/codegen/boxWithStdlib/toArray/returnCopyToArray.kt b/compiler/testData/codegen/boxWithStdlib/toArray/returnCopyToArray.kt index 2f0a2871a30..f61ae06af65 100644 --- a/compiler/testData/codegen/boxWithStdlib/toArray/returnCopyToArray.kt +++ b/compiler/testData/codegen/boxWithStdlib/toArray/returnCopyToArray.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.Arrays fun getCopyToArray(): Array = Arrays.asList(2, 3, 9).toTypedArray() @@ -7,4 +9,4 @@ fun box(): String { if (str != "[2, 3, 9]") return str return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/toArray/toArray.kt b/compiler/testData/codegen/boxWithStdlib/toArray/toArray.kt index ce7010bc6b2..213272b6e2c 100644 --- a/compiler/testData/codegen/boxWithStdlib/toArray/toArray.kt +++ b/compiler/testData/codegen/boxWithStdlib/toArray/toArray.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.Arrays class MyCollection(val delegate: Collection): Collection by delegate @@ -18,4 +20,4 @@ fun box(): String { if (s2 != "[2, 3, 9]") return "s2 = $s2" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/toArray/toArrayAlreadyPresent.kt b/compiler/testData/codegen/boxWithStdlib/toArray/toArrayAlreadyPresent.kt index 93be5ffff0f..9c8edeb9e11 100644 --- a/compiler/testData/codegen/boxWithStdlib/toArray/toArrayAlreadyPresent.kt +++ b/compiler/testData/codegen/boxWithStdlib/toArray/toArrayAlreadyPresent.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.Arrays class MyCollection(val delegate: Collection): Collection by delegate { @@ -33,4 +35,4 @@ fun box(): String { if (s2 != "[0, 1, 2]") return "s2 = $s2" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/noPrivateNoAccessorsInMultiFileFacade.kt b/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/noPrivateNoAccessorsInMultiFileFacade.kt index 87cd2a141a3..abbc5d29303 100644 --- a/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/noPrivateNoAccessorsInMultiFileFacade.kt +++ b/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/noPrivateNoAccessorsInMultiFileFacade.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @file:kotlin.jvm.JvmMultifileClass @file:kotlin.jvm.JvmName("TestKt") package test @@ -17,4 +19,4 @@ fun box(): String { return { prop + test() }() -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/noPrivateNoAccessorsInMultiFileFacade2.kt b/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/noPrivateNoAccessorsInMultiFileFacade2.kt index 7f02e734285..15331a096da 100644 --- a/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/noPrivateNoAccessorsInMultiFileFacade2.kt +++ b/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/noPrivateNoAccessorsInMultiFileFacade2.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @file:kotlin.jvm.JvmMultifileClass @file:kotlin.jvm.JvmName("TestKt") package test @@ -22,4 +24,4 @@ fun box(): String { prop = "O" prop + test() }() -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/syntheticAccessorInMultiFile.kt b/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/syntheticAccessorInMultiFile.kt index ad983df3576..e8bce4b68da 100644 --- a/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/syntheticAccessorInMultiFile.kt +++ b/compiler/testData/codegen/boxWithStdlib/topLevelPrivate/syntheticAccessorInMultiFile.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + @file:kotlin.jvm.JvmMultifileClass @file:kotlin.jvm.JvmName("TestKt") package test @@ -10,4 +12,4 @@ fun box(): String { return { prop + test() }() -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/typeMapping/genericTypeWithNothing.kt b/compiler/testData/codegen/boxWithStdlib/typeMapping/genericTypeWithNothing.kt index d682f34021e..4c9a86689aa 100644 --- a/compiler/testData/codegen/boxWithStdlib/typeMapping/genericTypeWithNothing.kt +++ b/compiler/testData/codegen/boxWithStdlib/typeMapping/genericTypeWithNothing.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + package foo import kotlin.reflect.KClass diff --git a/compiler/testData/codegen/boxWithStdlib/typeMapping/typeParameterMultipleBounds.kt b/compiler/testData/codegen/boxWithStdlib/typeMapping/typeParameterMultipleBounds.kt index 25034a7014f..02a00ae50b0 100644 --- a/compiler/testData/codegen/boxWithStdlib/typeMapping/typeParameterMultipleBounds.kt +++ b/compiler/testData/codegen/boxWithStdlib/typeMapping/typeParameterMultipleBounds.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + interface I1 interface I2 open class C diff --git a/compiler/testData/codegen/boxWithStdlib/vararg/spreadCopiesArray.kt b/compiler/testData/codegen/boxWithStdlib/vararg/spreadCopiesArray.kt index 674e652e23a..d5b7fc1fe65 100644 --- a/compiler/testData/codegen/boxWithStdlib/vararg/spreadCopiesArray.kt +++ b/compiler/testData/codegen/boxWithStdlib/vararg/spreadCopiesArray.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.* fun copyArray(vararg data: T): Array = data @@ -24,4 +26,4 @@ fun box(): String { assertEquals(iarr2[0], 1, "Failed: IntArray") return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/when/integralWhenWithNoInlinedConstants.kt b/compiler/testData/codegen/boxWithStdlib/when/integralWhenWithNoInlinedConstants.kt index 970266e7084..4e1fb2ab416 100644 --- a/compiler/testData/codegen/boxWithStdlib/when/integralWhenWithNoInlinedConstants.kt +++ b/compiler/testData/codegen/boxWithStdlib/when/integralWhenWithNoInlinedConstants.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun foo1(x: Int): Boolean { when(x) { 2 + 2 -> return true diff --git a/compiler/testData/codegen/boxWithStdlib/when/kt5448.kt b/compiler/testData/codegen/boxWithStdlib/when/kt5448.kt index d1c09d5dc1f..e1c81b55ca9 100644 --- a/compiler/testData/codegen/boxWithStdlib/when/kt5448.kt +++ b/compiler/testData/codegen/boxWithStdlib/when/kt5448.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + class A class B(val items: Collection) @@ -17,4 +19,4 @@ fun box(): String { if (C().bar().items.isNotEmpty()) return "fail" return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationDense.kt b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationDense.kt index 2f1fc2ef4e2..c10f7a03e0c 100644 --- a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationDense.kt +++ b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationDense.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.ArrayList fun dense(x: Int): Int { @@ -22,4 +24,3 @@ fun box(): String { if (result != "19, 9, 19, 19, 10, 11, 12, 19, 19, 13, 14, 15, 16, 17, 18, 19") return "dense:" + result return "OK" } - diff --git a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationMultipleConditions.kt b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationMultipleConditions.kt index b9d147cec47..d9cd6fd5809 100644 --- a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationMultipleConditions.kt +++ b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationMultipleConditions.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun foo(x: Int): Int { return when (x) { 1, 2, 3 -> 1 diff --git a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationSparse.kt b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationSparse.kt index 9a05bff9e0f..0c7647b23cf 100644 --- a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationSparse.kt +++ b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationSparse.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import java.util.ArrayList fun sparse(x: Int): Int { @@ -15,4 +17,3 @@ fun box(): String { if (result != "4, 1, 2, 3") return "sparse:" + result return "OK" } - diff --git a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationStatement.kt b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationStatement.kt index a4249660d72..2e436ca37f1 100644 --- a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationStatement.kt +++ b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationStatement.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun exhaustive(x: Int): Int { var r: Int when (x) { @@ -31,4 +33,3 @@ fun box(): String { if (result != "4, 1, 2, 3") return "non-exhaustive:" + result return "OK" } - diff --git a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationTypes.kt b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationTypes.kt index 8427ba9e35b..75333b05096 100644 --- a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationTypes.kt +++ b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationTypes.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun intFoo(x: Int): Int { return when (x) { 1 -> 5 @@ -52,5 +54,3 @@ fun box(): String { if (result != "5, 6, 7, 8") return "int:" + result return "OK" } - - diff --git a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationUnordered.kt b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationUnordered.kt index 1c637c29fbb..e299845073a 100644 --- a/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationUnordered.kt +++ b/compiler/testData/codegen/boxWithStdlib/when/switchOptimizationUnordered.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + fun foo(x: Int): Int { return when (x) { 2 -> 6 @@ -12,4 +14,4 @@ fun box(): String { if (result != "8, 5, 6, 7") return "unordered:" + result return "OK" -} \ No newline at end of file +} diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/bigEnum.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/bigEnum.kt index 73218e7e773..fb76910b59d 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/bigEnum.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/bigEnum.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals enum class BigEnum { diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/duplicatingItems.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/duplicatingItems.kt index dc0e6aaa037..2760d6daa88 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/duplicatingItems.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/duplicatingItems.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals enum class Season { diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/enumInsideClassObject.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/enumInsideClassObject.kt index 23b635436d8..18131fed078 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/enumInsideClassObject.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/enumInsideClassObject.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals class A { diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/expression.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/expression.kt index f26632c28d6..e1774794dea 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/expression.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/expression.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals enum class Season { diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/functionLiteralInTopLevel.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/functionLiteralInTopLevel.kt index 2955a0383a6..9b97152b2f3 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/functionLiteralInTopLevel.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/functionLiteralInTopLevel.kt @@ -1,5 +1,3 @@ -import kotlin.test.assertEquals - enum class Season { WINTER, SPRING, diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/manyWhensWithinClass.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/manyWhensWithinClass.kt index e1e8bfadc70..3a29f080cb3 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/manyWhensWithinClass.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/manyWhensWithinClass.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals enum class Season { diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/nullability.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/nullability.kt index 2fc708eee4b..d8734f77526 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/nullability.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/nullability.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals enum class Season { diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/subjectAny.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/subjectAny.kt index fca893fae5e..0f21003c5f6 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/subjectAny.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/subjectAny.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals enum class Season { diff --git a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/withoutElse.kt b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/withoutElse.kt index cb1c20aac37..abaea695949 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/withoutElse.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenEnumOptimization/withoutElse.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals enum class Season { diff --git a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/duplicatingItems.kt b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/duplicatingItems.kt index 3f63575a06d..d000aa96cfa 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/duplicatingItems.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/duplicatingItems.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(x : String) : String { @@ -17,4 +19,3 @@ fun box() : String { return "OK" } - diff --git a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/duplicatingItemsSameHashCode.kt b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/duplicatingItemsSameHashCode.kt index ec44ca0f332..cb6a35b8058 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/duplicatingItemsSameHashCode.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/duplicatingItemsSameHashCode.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(x : String) : String { diff --git a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/expression.kt b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/expression.kt index 50cf056d00e..bc9759e64ee 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/expression.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/expression.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(x : String) : String { diff --git a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/nullability.kt b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/nullability.kt index 3219824d1cb..d2d047fb153 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/nullability.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/nullability.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo1(x : String?) : String { diff --git a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/sameHashCode.kt b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/sameHashCode.kt index 80bd3d166b6..be3a891f13e 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/sameHashCode.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/sameHashCode.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo(x : String) : String { diff --git a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/statement.kt b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/statement.kt index bf3e24c4a21..4f9bdc05158 100644 --- a/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/statement.kt +++ b/compiler/testData/codegen/boxWithStdlib/whenStringOptimization/statement.kt @@ -1,3 +1,5 @@ +// WITH_RUNTIME + import kotlin.test.assertEquals fun foo1(x : String) : String { diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxCodegenTest.java b/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxCodegenTest.java index 1857c048e69..151314409ec 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxCodegenTest.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/AbstractBlackBoxCodegenTest.java @@ -81,7 +81,6 @@ public abstract class AbstractBlackBoxCodegenTest extends CodegenTestCase { } protected void doTestWithStdlib(@NotNull String filename) throws Exception { - addReflect = true; doTest(filename); } diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java index fd085e330c5..8c3787801fa 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java @@ -1572,6 +1572,12 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest { doTest(fileName); } + @TestMetadata("listOfStringsMapLength.kt") + public void testListOfStringsMapLength() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/callableReference/property/listOfStringsMapLength.kt"); + doTest(fileName); + } + @TestMetadata("localClassVar.kt") public void testLocalClassVar() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/callableReference/property/localClassVar.kt"); diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxWithStdlibCodegenTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxWithStdlibCodegenTestGenerated.java index 3f6c67afa13..cacb301e5ba 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxWithStdlibCodegenTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxWithStdlibCodegenTestGenerated.java @@ -320,12 +320,6 @@ public class BlackBoxWithStdlibCodegenTestGenerated extends AbstractBlackBoxCode String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxWithStdlib/callableReference/function/getArityViaFunctionImpl.kt"); doTestWithStdlib(fileName); } - - @TestMetadata("listOfStringsMapLength.kt") - public void testListOfStringsMapLength() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxWithStdlib/callableReference/function/listOfStringsMapLength.kt"); - doTestWithStdlib(fileName); - } } } diff --git a/generators/src/org/jetbrains/kotlin/generators/tests/GenerateRangesCodegenTestData.java b/generators/src/org/jetbrains/kotlin/generators/tests/GenerateRangesCodegenTestData.java index afc95d44c7d..b1defe3a870 100644 --- a/generators/src/org/jetbrains/kotlin/generators/tests/GenerateRangesCodegenTestData.java +++ b/generators/src/org/jetbrains/kotlin/generators/tests/GenerateRangesCodegenTestData.java @@ -117,6 +117,8 @@ public class GenerateRangesCodegenTestData { } out.println("// Auto-generated by " + GenerateRangesCodegenTestData.class.getName() + ". DO NOT EDIT!"); + out.println("// WITH_RUNTIME"); + out.println(); out.println("import java.util.ArrayList"); if (generatedBody.contains("Max") || generatedBody.contains("Min")) { // Import min/max values, but only in case when the generated test case actually uses them (not to clutter tests which don't)