diff --git a/analysis/analysis-api/testData/components/callResolver/resolveCall/samConstructorCall.txt b/analysis/analysis-api/testData/components/callResolver/resolveCall/samConstructorCall.txt index ab8d5e379a7..22ae448254e 100644 --- a/analysis/analysis-api/testData/components/callResolver/resolveCall/samConstructorCall.txt +++ b/analysis/analysis-api/testData/components/callResolver/resolveCall/samConstructorCall.txt @@ -7,13 +7,13 @@ KtSuccessCallInfo: signature = KtFunctionLikeSignature: receiverType = null returnType = java.util.Comparator - symbol = kotlin/Comparator(function: kotlin.Function2, ft, kotlin.Int>): java.util.Comparator + symbol = kotlin/Comparator(function: kotlin.Function2): java.util.Comparator valueParameters = [ KtVariableLikeSignature: name = function receiverType = null returnType = kotlin.Function2 - symbol = function: kotlin.Function2, ft, kotlin.Int> + symbol = function: kotlin.Function2 callableIdIfNonLocal = null ] callableIdIfNonLocal = kotlin/Comparator @@ -25,6 +25,6 @@ KtSuccessCallInfo: name = function receiverType = null returnType = kotlin.Function2 - symbol = function: kotlin.Function2, ft, kotlin.Int> + symbol = function: kotlin.Function2 callableIdIfNonLocal = null) } diff --git a/analysis/analysis-api/testData/components/callResolver/resolveCandidates/singleCandidate/samConstructorCall.txt b/analysis/analysis-api/testData/components/callResolver/resolveCandidates/singleCandidate/samConstructorCall.txt index d094573d272..a8b70b35400 100644 --- a/analysis/analysis-api/testData/components/callResolver/resolveCandidates/singleCandidate/samConstructorCall.txt +++ b/analysis/analysis-api/testData/components/callResolver/resolveCandidates/singleCandidate/samConstructorCall.txt @@ -7,13 +7,13 @@ KtApplicableCallCandidateInfo: signature = KtFunctionLikeSignature: receiverType = null returnType = java.util.Comparator - symbol = kotlin/Comparator(function: kotlin.Function2, ft, kotlin.Int>): java.util.Comparator + symbol = kotlin/Comparator(function: kotlin.Function2): java.util.Comparator valueParameters = [ KtVariableLikeSignature: name = function receiverType = null returnType = kotlin.Function2 - symbol = function: kotlin.Function2, ft, kotlin.Int> + symbol = function: kotlin.Function2 callableIdIfNonLocal = null ] callableIdIfNonLocal = kotlin/Comparator @@ -25,7 +25,7 @@ KtApplicableCallCandidateInfo: name = function receiverType = null returnType = kotlin.Function2 - symbol = function: kotlin.Function2, ft, kotlin.Int> + symbol = function: kotlin.Function2 callableIdIfNonLocal = null) } isInBestCandidates = true diff --git a/analysis/analysis-api/testData/components/scopeProvider/memberScope/javaClass.pretty.txt b/analysis/analysis-api/testData/components/scopeProvider/memberScope/javaClass.pretty.txt index 6cf65554515..573822f9d09 100644 --- a/analysis/analysis-api/testData/components/scopeProvider/memberScope/javaClass.pretty.txt +++ b/analysis/analysis-api/testData/components/scopeProvider/memberScope/javaClass.pretty.txt @@ -1,6 +1,6 @@ open fun hello() -open fun method(vararg classes: java.lang.Class!) +open fun method(vararg classes: java.lang.Class!) @java.lang.Override open fun getActualRandomNumber(): kotlin.Int diff --git a/analysis/analysis-api/testData/components/scopeProvider/memberScope/javaClass.txt b/analysis/analysis-api/testData/components/scopeProvider/memberScope/javaClass.txt index 67fe8f4e8bb..015e57c19dc 100644 --- a/analysis/analysis-api/testData/components/scopeProvider/memberScope/javaClass.txt +++ b/analysis/analysis-api/testData/components/scopeProvider/memberScope/javaClass.txt @@ -82,7 +82,7 @@ KtFunctionSymbol: receiverParameter: null returnType: KtFlexibleType: annotationsList: [] - type: ft>, java/lang/Class>?> + type: ft, java/lang/Class?> symbolKind: LOCAL typeParameters: [] getContainingFileSymbol: null diff --git a/analysis/analysis-api/testData/components/scopeProvider/substitutionOverridesUnwrapping/Implement_java_util_Collection.pretty.txt b/analysis/analysis-api/testData/components/scopeProvider/substitutionOverridesUnwrapping/Implement_java_util_Collection.pretty.txt index 2f8d0cfb081..08d754e2a7b 100644 --- a/analysis/analysis-api/testData/components/scopeProvider/substitutionOverridesUnwrapping/Implement_java_util_Collection.pretty.txt +++ b/analysis/analysis-api/testData/components/scopeProvider/substitutionOverridesUnwrapping/Implement_java_util_Collection.pretty.txt @@ -8,7 +8,7 @@ override operator fun iterator(): kotlin.collections.MutableIterator! -fun toArray(p0: kotlin.Array<(T & kotlin.Any..T?)>!): kotlin.Array<(T & kotlin.Any..T?)>! +fun toArray(p0: kotlin.Array!): kotlin.Array! override fun add(p0: test.SomeClass!): kotlin.Boolean diff --git a/analysis/analysis-api/testData/referenceResolve/SamConstructor.descriptors.txt b/analysis/analysis-api/testData/referenceResolve/SamConstructor.descriptors.txt deleted file mode 100644 index 5a99b8d511d..00000000000 --- a/analysis/analysis-api/testData/referenceResolve/SamConstructor.descriptors.txt +++ /dev/null @@ -1,2 +0,0 @@ -Resolved to: -0: (in java.util) Comparator(function: (T!, T!) -> kotlin.Int): java.util.Comparator \ No newline at end of file diff --git a/analysis/analysis-api/testData/referenceResolve/SamConstructor.txt b/analysis/analysis-api/testData/referenceResolve/SamConstructor.txt index 6993cfdb27c..5a99b8d511d 100644 --- a/analysis/analysis-api/testData/referenceResolve/SamConstructor.txt +++ b/analysis/analysis-api/testData/referenceResolve/SamConstructor.txt @@ -1,2 +1,2 @@ Resolved to: -0: (in java.util) Comparator(function: ((T & kotlin.Any..T?), (T & kotlin.Any..T?)) -> kotlin.Int): java.util.Comparator +0: (in java.util) Comparator(function: (T!, T!) -> kotlin.Int): java.util.Comparator \ No newline at end of file diff --git a/analysis/analysis-api/testData/referenceResolve/SamConstructorTypeArguments.descriptors.txt b/analysis/analysis-api/testData/referenceResolve/SamConstructorTypeArguments.descriptors.txt deleted file mode 100644 index 5a99b8d511d..00000000000 --- a/analysis/analysis-api/testData/referenceResolve/SamConstructorTypeArguments.descriptors.txt +++ /dev/null @@ -1,2 +0,0 @@ -Resolved to: -0: (in java.util) Comparator(function: (T!, T!) -> kotlin.Int): java.util.Comparator \ No newline at end of file diff --git a/analysis/analysis-api/testData/referenceResolve/SamConstructorTypeArguments.txt b/analysis/analysis-api/testData/referenceResolve/SamConstructorTypeArguments.txt index 6993cfdb27c..5a99b8d511d 100644 --- a/analysis/analysis-api/testData/referenceResolve/SamConstructorTypeArguments.txt +++ b/analysis/analysis-api/testData/referenceResolve/SamConstructorTypeArguments.txt @@ -1,2 +1,2 @@ Resolved to: -0: (in java.util) Comparator(function: ((T & kotlin.Any..T?), (T & kotlin.Any..T?)) -> kotlin.Int): java.util.Comparator +0: (in java.util) Comparator(function: (T!, T!) -> kotlin.Int): java.util.Comparator \ No newline at end of file diff --git a/analysis/analysis-api/testData/referenceResolve/inImport/javaClass.descriptors.txt b/analysis/analysis-api/testData/referenceResolve/inImport/javaClass.descriptors.txt deleted file mode 100644 index 143004b5ac3..00000000000 --- a/analysis/analysis-api/testData/referenceResolve/inImport/javaClass.descriptors.txt +++ /dev/null @@ -1,2 +0,0 @@ -Resolved to: -0: (in java.util) open class HashMap : java.util.AbstractMap(), kotlin.Cloneable, java.io.Serializable, kotlin.collections.MutableMap \ No newline at end of file diff --git a/analysis/analysis-api/testData/referenceResolve/inImport/javaClass.txt b/analysis/analysis-api/testData/referenceResolve/inImport/javaClass.txt index 10176fb7b61..143004b5ac3 100644 --- a/analysis/analysis-api/testData/referenceResolve/inImport/javaClass.txt +++ b/analysis/analysis-api/testData/referenceResolve/inImport/javaClass.txt @@ -1,2 +1,2 @@ Resolved to: -0: (in java.util) open class HashMap : java.util.AbstractMap<(K & kotlin.Any..K?), (V & kotlin.Any..V?)>(), kotlin.Cloneable, java.io.Serializable, kotlin.collections.MutableMap +0: (in java.util) open class HashMap : java.util.AbstractMap(), kotlin.Cloneable, java.io.Serializable, kotlin.collections.MutableMap \ No newline at end of file diff --git a/analysis/analysis-api/testData/referenceResolve/java/JavaReference.descriptors.txt b/analysis/analysis-api/testData/referenceResolve/java/JavaReference.descriptors.txt deleted file mode 100644 index 91c55865caf..00000000000 --- a/analysis/analysis-api/testData/referenceResolve/java/JavaReference.descriptors.txt +++ /dev/null @@ -1,2 +0,0 @@ -Resolved to: -0: (in java.util) open class HashSet : java.util.AbstractSet(), kotlin.Cloneable, java.io.Serializable, kotlin.collections.MutableSet \ No newline at end of file diff --git a/analysis/analysis-api/testData/referenceResolve/java/JavaReference.txt b/analysis/analysis-api/testData/referenceResolve/java/JavaReference.txt index 7fd63079202..91c55865caf 100644 --- a/analysis/analysis-api/testData/referenceResolve/java/JavaReference.txt +++ b/analysis/analysis-api/testData/referenceResolve/java/JavaReference.txt @@ -1,2 +1,2 @@ Resolved to: -0: (in java.util) open class HashSet : java.util.AbstractSet<(E & kotlin.Any..E?)>(), kotlin.Cloneable, java.io.Serializable, kotlin.collections.MutableSet +0: (in java.util) open class HashSet : java.util.AbstractSet(), kotlin.Cloneable, java.io.Serializable, kotlin.collections.MutableSet \ No newline at end of file diff --git a/analysis/analysis-api/testData/symbols/symbolByReference/constructorViaTypeAlias.pretty.txt b/analysis/analysis-api/testData/symbols/symbolByReference/constructorViaTypeAlias.pretty.txt index 002fbd25275..68acaedb3d3 100644 --- a/analysis/analysis-api/testData/symbols/symbolByReference/constructorViaTypeAlias.pretty.txt +++ b/analysis/analysis-api/testData/symbols/symbolByReference/constructorViaTypeAlias.pretty.txt @@ -1 +1 @@ -constructor(c: kotlin.collections.(Mutable)Collection!) +constructor(c: kotlin.collections.(Mutable)Collection!) \ No newline at end of file diff --git a/analysis/analysis-api/testData/symbols/symbolByReference/constructorViaTypeAlias.txt b/analysis/analysis-api/testData/symbols/symbolByReference/constructorViaTypeAlias.txt index f5af69f2127..7511840d843 100644 --- a/analysis/analysis-api/testData/symbols/symbolByReference/constructorViaTypeAlias.txt +++ b/analysis/analysis-api/testData/symbols/symbolByReference/constructorViaTypeAlias.txt @@ -39,7 +39,7 @@ KtConstructorSymbol: receiverParameter: null returnType: KtFlexibleType: annotationsList: [] - type: ft>, kotlin/collections/Collection>?> + type: ft, kotlin/collections/Collection?> symbolKind: LOCAL typeParameters: [] getContainingFileSymbol: null diff --git a/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/OuterClassesWithFlexibleArgs/OuterClassesWithFlexibleArgs.k2.txt b/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/OuterClassesWithFlexibleArgs/OuterClassesWithFlexibleArgs.k2.txt deleted file mode 100644 index 895f6e26c7a..00000000000 --- a/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/OuterClassesWithFlexibleArgs/OuterClassesWithFlexibleArgs.k2.txt +++ /dev/null @@ -1,50 +0,0 @@ -PsiJetFileStubImpl[package=test] -KotlinStub$PACKAGE_DIRECTIVE - KotlinStub$REFERENCE_EXPRESSION[referencedName=test] -KotlinStub$IMPORT_LIST -KotlinStub$CLASS[classId=test/OuterClassesWithFlexibleArgs, fqName=test.OuterClassesWithFlexibleArgs, isEnumEntry=false, isInterface=false, isLocal=false, isTopLevel=true, name=OuterClassesWithFlexibleArgs, superNames=[]] - KotlinStub$MODIFIER_LIST[public final] - KotlinStub$TYPE_PARAMETER_LIST - KotlinStub$TYPE_PARAMETER[fqName=null, isInVariance=false, isOutVariance=false, name=K] - KotlinStub$TYPE_PARAMETER[fqName=null, isInVariance=false, isOutVariance=false, name=L] - KotlinStub$PRIMARY_CONSTRUCTOR[fqName=null, hasBody=false, isDelegatedCallToThis=false, isExplicitDelegationCall=false, isExtension=false, isTopLevel=false, name=OuterClassesWithFlexibleArgs] - KotlinStub$MODIFIER_LIST[public] - KotlinStub$VALUE_PARAMETER_LIST - KotlinStub$VALUE_PARAMETER[fqName=null, hasDefaultValue=false, hasValOrVar=false, isMutable=false, name=k] - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE - KotlinStub$REFERENCE_EXPRESSION[referencedName=K] - KotlinStub$VALUE_PARAMETER[fqName=null, hasDefaultValue=false, hasValOrVar=false, isMutable=false, name=l] - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE - KotlinStub$REFERENCE_EXPRESSION[referencedName=L] - KotlinStub$CLASS_BODY - KotlinStub$PROPERTY[fqName=test.OuterClassesWithFlexibleArgs.baz, hasDelegate=false, hasDelegateExpression=false, hasInitializer=false, hasReturnTypeRef=true, isExtension=false, isTopLevel=false, isVar=false, name=baz] - KotlinStub$MODIFIER_LIST[public final] - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE ft: d.JavaClass.InnerClass? - KotlinStub$USER_TYPE - KotlinStub$USER_TYPE - KotlinStub$REFERENCE_EXPRESSION[referencedName=d] - KotlinStub$REFERENCE_EXPRESSION[referencedName=JavaClass] - KotlinStub$TYPE_ARGUMENT_LIST - KotlinStub$TYPE_PROJECTION[projectionKind=NONE] - KotlinStub$TYPE_REFERENCE - KotlinStub$INTERSECTION_TYPE - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE ft: K? - KotlinStub$REFERENCE_EXPRESSION[referencedName=K] - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE - KotlinStub$REFERENCE_EXPRESSION[referencedName=Any] - KotlinStub$REFERENCE_EXPRESSION[referencedName=InnerClass] - KotlinStub$TYPE_ARGUMENT_LIST - KotlinStub$TYPE_PROJECTION[projectionKind=NONE] - KotlinStub$TYPE_REFERENCE - KotlinStub$INTERSECTION_TYPE - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE ft: L? - KotlinStub$REFERENCE_EXPRESSION[referencedName=L] - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE - KotlinStub$REFERENCE_EXPRESSION[referencedName=Any] \ No newline at end of file diff --git a/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/OuterClassesWithFlexibleArgs/OuterClassesWithFlexibleArgs.kt b/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/OuterClassesWithFlexibleArgs/OuterClassesWithFlexibleArgs.kt index b507d026c84..6d556382b3d 100644 --- a/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/OuterClassesWithFlexibleArgs/OuterClassesWithFlexibleArgs.kt +++ b/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/OuterClassesWithFlexibleArgs/OuterClassesWithFlexibleArgs.kt @@ -1,3 +1,4 @@ +// FIR_IDENTICAL /* Java interop */ // KNM_K2_IGNORE diff --git a/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/TypeParametersInFlexibleTypes/TypeParametersInFlexibleTypes.k2.txt b/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/TypeParametersInFlexibleTypes/TypeParametersInFlexibleTypes.k2.txt index 31264b0abe9..e52c5d2f278 100644 --- a/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/TypeParametersInFlexibleTypes/TypeParametersInFlexibleTypes.k2.txt +++ b/analysis/decompiled/decompiler-to-file-stubs/testData/additionalClsStubInfo/TypeParametersInFlexibleTypes/TypeParametersInFlexibleTypes.k2.txt @@ -56,7 +56,7 @@ KotlinStub$CLASS[classId=test/TypeParametersInFlexibleTypes, fqName=test.TypePar KotlinStub$PROPERTY[fqName=test.TypeParametersInFlexibleTypes.bar, hasDelegate=false, hasDelegateExpression=false, hasInitializer=false, hasReturnTypeRef=true, isExtension=false, isTopLevel=false, isVar=false, name=bar] KotlinStub$MODIFIER_LIST[public final] KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE ft: kotlin.collections.Collection? + KotlinStub$USER_TYPE ft: kotlin.collections.Collection? KotlinStub$USER_TYPE KotlinStub$USER_TYPE KotlinStub$REFERENCE_EXPRESSION[referencedName=kotlin] @@ -65,13 +65,8 @@ KotlinStub$CLASS[classId=test/TypeParametersInFlexibleTypes, fqName=test.TypePar KotlinStub$TYPE_ARGUMENT_LIST KotlinStub$TYPE_PROJECTION[projectionKind=NONE] KotlinStub$TYPE_REFERENCE - KotlinStub$INTERSECTION_TYPE - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE ft: A? - KotlinStub$REFERENCE_EXPRESSION[referencedName=A] - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE - KotlinStub$REFERENCE_EXPRESSION[referencedName=Any] + KotlinStub$USER_TYPE ft: A? + KotlinStub$REFERENCE_EXPRESSION[referencedName=A] KotlinStub$PROPERTY[fqName=test.TypeParametersInFlexibleTypes.baz, hasDelegate=false, hasDelegateExpression=false, hasInitializer=false, hasReturnTypeRef=true, isExtension=false, isTopLevel=false, isVar=false, name=baz] KotlinStub$MODIFIER_LIST[public final] KotlinStub$TYPE_REFERENCE @@ -95,10 +90,5 @@ KotlinStub$CLASS[classId=test/TypeParametersInFlexibleTypes, fqName=test.TypePar KotlinStub$MODIFIER_LIST[public final] KotlinStub$VALUE_PARAMETER_LIST KotlinStub$TYPE_REFERENCE - KotlinStub$INTERSECTION_TYPE - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE ft: A? - KotlinStub$REFERENCE_EXPRESSION[referencedName=A] - KotlinStub$TYPE_REFERENCE - KotlinStub$USER_TYPE - KotlinStub$REFERENCE_EXPRESSION[referencedName=Any] \ No newline at end of file + KotlinStub$USER_TYPE ft: A? + KotlinStub$REFERENCE_EXPRESSION[referencedName=A] \ No newline at end of file diff --git a/analysis/low-level-api-fir/testData/fileStructure/functionWithImplicitType.lazy.resolve.txt b/analysis/low-level-api-fir/testData/fileStructure/functionWithImplicitType.lazy.resolve.txt index 40d576d33cb..1d2e274c938 100644 --- a/analysis/low-level-api-fir/testData/fileStructure/functionWithImplicitType.lazy.resolve.txt +++ b/analysis/low-level-api-fir/testData/fileStructure/functionWithImplicitType.lazy.resolve.txt @@ -2,5 +2,5 @@ FILE: [ResolvedTo(BODY_RESOLVE)] functionWithImplicitType.kt public final [ResolvedTo(BODY_RESOLVE)] fun <[ResolvedTo(BODY_RESOLVE)] T> checkSubtype([ResolvedTo(BODY_RESOLVE)] t: R|T|): R|T| { ^checkSubtype R|/t| } - public final [ResolvedTo(BODY_RESOLVE)] val ab: R|kotlin/collections/List?| = R|/checkSubtype|?|>(Q|java/util/Collections|.R|java/util/Collections.emptyList|()) + public final [ResolvedTo(BODY_RESOLVE)] val ab: R|kotlin/collections/List?| = R|/checkSubtype|?|>(Q|java/util/Collections|.R|java/util/Collections.emptyList|()) public [ResolvedTo(BODY_RESOLVE)] get(): R|kotlin/collections/List?| diff --git a/compiler/fir/analysis-tests/testData/resolve/arguments/lambdaInLambda2.fir.txt b/compiler/fir/analysis-tests/testData/resolve/arguments/lambdaInLambda2.fir.txt index be2beba6196..003cf064027 100644 --- a/compiler/fir/analysis-tests/testData/resolve/arguments/lambdaInLambda2.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/arguments/lambdaInLambda2.fir.txt @@ -7,7 +7,7 @@ FILE: main.kt public abstract interface PsiClass : R|kotlin/Any| { } public final fun test(): R|kotlin/Unit| { - lval processor: R|AdapterProcessor| = R|/AdapterProcessor.AdapterProcessor|(R|/Function|( = Function@fun (method: R|PsiMethod?|): R|PsiClass!| { + lval processor: R|AdapterProcessor| = R|/AdapterProcessor.AdapterProcessor|(R|/Function|( = Function@fun (method: R|PsiMethod?|): R|PsiClass?| { ^ R|/method|?.{ $subj$.R|/PsiMethod.containingClass| } } )) diff --git a/compiler/fir/analysis-tests/testData/resolve/arguments/typeMismatchOnExpectedJavaMap.fir.txt b/compiler/fir/analysis-tests/testData/resolve/arguments/typeMismatchOnExpectedJavaMap.fir.txt index b2ca3021887..dbb8195c527 100644 --- a/compiler/fir/analysis-tests/testData/resolve/arguments/typeMismatchOnExpectedJavaMap.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/arguments/typeMismatchOnExpectedJavaMap.fir.txt @@ -1,4 +1,4 @@ FILE: main.kt public final fun test(executor: R|BuildActionExecuter|, modelType: R|java/lang/Class|, env: R|kotlin/collections/Map|): R|kotlin/Unit| { - lval model: R|ft>, BuildActionExecuter>?>| = R|/executor|.R|SubstitutionOverride>, BuildActionExecuter>?>|>|(R|/env|) + lval model: R|ft, BuildActionExecuter?>| = R|/executor|.R|SubstitutionOverride, BuildActionExecuter?>|>|(R|/env|) } diff --git a/compiler/fir/analysis-tests/testData/resolve/defaultJavaImportHiding.fir.txt b/compiler/fir/analysis-tests/testData/resolve/defaultJavaImportHiding.fir.txt index 17376191360..0303e443ffe 100644 --- a/compiler/fir/analysis-tests/testData/resolve/defaultJavaImportHiding.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/defaultJavaImportHiding.fir.txt @@ -26,13 +26,13 @@ FILE: main.kt } public final fun test_1(): R|kotlin/Unit| { - lval map: R|util/HashMap| = R|util/HashMap.HashMap|() + lval map: R|util/HashMap| = R|util/HashMap.HashMap|() } public final fun test_2(): R|kotlin/Unit| { lval set: R|util/HashSet| = R|util/HashSet.HashSet|() } public final fun test_3(): R|kotlin/Unit| { - lval list: R|foo/ArrayList| = R|foo/ArrayList.ArrayList|() + lval list: R|foo/ArrayList| = R|foo/ArrayList.ArrayList|() } public final fun test_4(): R|kotlin/Unit| { lval list: R|foo/LinkedList| = R|foo/LinkedList.LinkedList|() diff --git a/compiler/fir/analysis-tests/testData/resolve/expresssions/genericDiagnostic.fir.txt b/compiler/fir/analysis-tests/testData/resolve/expresssions/genericDiagnostic.fir.txt index 2356f2c98de..cc560fe19c6 100644 --- a/compiler/fir/analysis-tests/testData/resolve/expresssions/genericDiagnostic.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/expresssions/genericDiagnostic.fir.txt @@ -13,8 +13,8 @@ FILE: test.kt lval element: R|DE| = R|/d|.R|/Diagnostic.element| R|/Fix.Fix|(R|/element|) } - private final val DERIVED_FACTORY: R|DiagnosticFactory0| = R|/DiagnosticFactory0.DiagnosticFactory0|() - private get(): R|DiagnosticFactory0| + private final val DERIVED_FACTORY: R|DiagnosticFactory0| = R|/DiagnosticFactory0.DiagnosticFactory0|() + private get(): R|DiagnosticFactory0| public final fun createViaFactory(d: R|EmptyDiagnostic|): R|kotlin/Unit| { lval casted: R|Diagnostic| = R|/DERIVED_FACTORY|.R|SubstitutionOverride|>|(R|/d|) lval element: R|DerivedElement| = R|/casted|.R|/Diagnostic.element| diff --git a/compiler/fir/analysis-tests/testData/resolve/extendedCheckers/canBeReplacedWithOperatorAssignment/flexibleTypeBug.fir.txt b/compiler/fir/analysis-tests/testData/resolve/extendedCheckers/canBeReplacedWithOperatorAssignment/flexibleTypeBug.fir.txt index 85611a155f3..447f79f1d6c 100644 --- a/compiler/fir/analysis-tests/testData/resolve/extendedCheckers/canBeReplacedWithOperatorAssignment/flexibleTypeBug.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/extendedCheckers/canBeReplacedWithOperatorAssignment/flexibleTypeBug.fir.txt @@ -1,6 +1,6 @@ FILE: flexibleTypeBug.kt public final fun foo(): R|kotlin/Unit| { - lvar list1: R|ft, kotlin/collections/List?>| = Q|java/util/Collections|.R|java/util/Collections.emptyList*s|() + lvar list1: R|ft, kotlin/collections/List?>| = Q|java/util/Collections|.R|java/util/Collections.emptyList*s|() lval list2: R|kotlin/collections/List| = R|kotlin/collections/listOf|(String(b)) R|/list1| = R|/list1|.R|kotlin/collections/plus|(R|/list2|) } diff --git a/compiler/fir/analysis-tests/testData/resolve/inference/javaCollector.fir.txt b/compiler/fir/analysis-tests/testData/resolve/inference/javaCollector.fir.txt index 0aa37f50010..67b7471a70f 100644 --- a/compiler/fir/analysis-tests/testData/resolve/inference/javaCollector.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/inference/javaCollector.fir.txt @@ -1,7 +1,7 @@ FILE: javaCollector.kt public final fun foo(): R|kotlin/Unit| { - R|kotlin/collections/listOf|(String()).R|SubstitutionOverride|>|().R|SubstitutionOverride|>|, kotlin/collections/Map?>|, R|ft|>(Q|java/util/stream/Collectors|.R|java/util/stream/Collectors.groupingBy*s||, R|kotlin/Int!|>(SAM(groupingBy@fun (it: R|@EnhancedNullability kotlin/String!|): R|@EnhancedNullability kotlin/String!| { + R|kotlin/collections/listOf|(String()).R|SubstitutionOverride|>|().R|SubstitutionOverride#|<, >(Q|java/util/stream/Collectors|.R|java/util/stream/Collectors.groupingBy*s#|, R|kotlin/Any!|, R|kotlin/Int!|>(SAM(groupingBy@fun (it: R|@EnhancedNullability kotlin/String!|): { ^ R|/it| } - ), Q|java/util/stream/Collectors|.R|java/util/stream/Collectors.collectingAndThen*s||, R|kotlin/Long!|, R|kotlin/Int!|>(Q|java/util/stream/Collectors|.R|java/util/stream/Collectors.counting*s|(), SAM(Q|kotlin/Long|::R|kotlin/Long.toInt|)))) + ), Q|java/util/stream/Collectors|.R|java/util/stream/Collectors.collectingAndThen*s||, R|kotlin/Long!|, R|kotlin/Int!|>(Q|java/util/stream/Collectors|.R|java/util/stream/Collectors.counting*s|(), SAM(Q|kotlin/Long|::R|kotlin/Long.toInt|)))) } diff --git a/compiler/fir/analysis-tests/testData/resolve/inference/javaCollector.kt b/compiler/fir/analysis-tests/testData/resolve/inference/javaCollector.kt index 742ac2cf01b..2d81d51e337 100644 --- a/compiler/fir/analysis-tests/testData/resolve/inference/javaCollector.kt +++ b/compiler/fir/analysis-tests/testData/resolve/inference/javaCollector.kt @@ -6,12 +6,12 @@ import java.util.stream.Collectors fun foo(){ listOf("").stream().collect( - Collectors.groupingBy( + Collectors.groupingBy( { it }, Collectors.collectingAndThen( Collectors.counting(), Long::toInt ) - ) + ) ) } diff --git a/compiler/fir/analysis-tests/testData/resolve/inference/onlyInputTypesCapturedTypeWithRecursiveBounds.fir.txt b/compiler/fir/analysis-tests/testData/resolve/inference/onlyInputTypesCapturedTypeWithRecursiveBounds.fir.txt index 9647d3cc12a..e3972c6a0c6 100644 --- a/compiler/fir/analysis-tests/testData/resolve/inference/onlyInputTypesCapturedTypeWithRecursiveBounds.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/inference/onlyInputTypesCapturedTypeWithRecursiveBounds.fir.txt @@ -41,9 +41,9 @@ FILE: onlyInputTypesCapturedTypeWithRecursiveBounds.kt } private final fun test(node: R|FooEnumMap<*>|): R|kotlin/Unit| { - R|/node|.R|SubstitutionOverride|>|.R|kotlin/collections/get| & I), it(kotlin/Enum<*>? & I?)>|, R|kotlin/Any!|>(Q|MyEnum|.R|/MyEnum.EnumEntry|) + R|/node|.R|SubstitutionOverride|>|.R|kotlin/collections/get| & I), it(kotlin/Enum<*>? & I?)>|, R|kotlin/Any?|>(Q|MyEnum|.R|/MyEnum.EnumEntry|) lval map: R|java/util/EnumMap & I), kotlin/Any?>| = R|/node|.R|SubstitutionOverride|>| - R|/map|.R|kotlin/collections/get| & I), it(kotlin/Enum<*>? & I?)>> & I), it(kotlin/Enum<*>? & I?)>> & I), it(kotlin/Enum<*>? & I?)>|, R|kotlin/Any!|>(Q|MyEnum|.R|/MyEnum.EnumEntry|) + R|/map|.R|kotlin/collections/get| & I), it(kotlin/Enum<*>? & I?)>|, R|kotlin/Any?|>(Q|MyEnum|.R|/MyEnum.EnumEntry|) } public open class Foo2

: R|kotlin/Any| { public constructor

(data: R|kotlin/collections/Map|): R|Foo2

| { diff --git a/compiler/fir/analysis-tests/testData/resolve/inference/selfTypeFromJava.fir.txt b/compiler/fir/analysis-tests/testData/resolve/inference/selfTypeFromJava.fir.txt index 2d7fc44452b..34d95dcc00e 100644 --- a/compiler/fir/analysis-tests/testData/resolve/inference/selfTypeFromJava.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/inference/selfTypeFromJava.fir.txt @@ -1,6 +1,6 @@ FILE: main.kt public final fun main(): R|kotlin/Unit| { lval a: R|ft, Java<*, kotlin/String!>?>| = Q|Java|.R|/Java.factory*s|(String()) - lval b: R|ft, Java<*, kotlin/String!>?>| = R|/a|.R|SubstitutionOverride|>|() + lval b: R|ft, Java<*, kotlin/String!>?>| = R|/a|.R|SubstitutionOverride|>|() R|/b|.R|SubstitutionOverride|(String(testing)) } diff --git a/compiler/fir/analysis-tests/testData/resolve/problems/flexibleTypeVarAgainstNull.fir.txt b/compiler/fir/analysis-tests/testData/resolve/problems/flexibleTypeVarAgainstNull.fir.txt index a9922199723..a95e188c7d4 100644 --- a/compiler/fir/analysis-tests/testData/resolve/problems/flexibleTypeVarAgainstNull.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/problems/flexibleTypeVarAgainstNull.fir.txt @@ -1,4 +1,4 @@ FILE: main.kt public final fun main(): R|kotlin/Unit| { - R|/JavaClass.JavaClass|(Null(null)).R|SubstitutionOverride|().R|kotlin/String.length| + R|/JavaClass.JavaClass|(Null(null)).R|SubstitutionOverride|().R|kotlin/String.length| } diff --git a/compiler/fir/analysis-tests/testData/resolve/samConstructors/genericSam.fir.txt b/compiler/fir/analysis-tests/testData/resolve/samConstructors/genericSam.fir.txt index f7d7f5ea70a..ac5c36ea0f0 100644 --- a/compiler/fir/analysis-tests/testData/resolve/samConstructors/genericSam.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/samConstructors/genericSam.fir.txt @@ -1,6 +1,6 @@ FILE: main.kt public final fun main(): R|kotlin/Unit| { - R|/MyFunction|( = MyFunction@fun (x: R|kotlin/Int!|): R|kotlin/String!| { + R|/MyFunction|( = MyFunction@fun (x: R|kotlin/Int!|): R|kotlin/String!| { ^ R|/x|.R|kotlin/Int.toInt|().R|kotlin/Int.toString|() } ) diff --git a/compiler/fir/analysis-tests/testData/resolve/scopes/publicJavaAndPrivateKotlinVar.overrides.txt b/compiler/fir/analysis-tests/testData/resolve/scopes/publicJavaAndPrivateKotlinVar.overrides.txt index 5f9dfd39598..04052505e8f 100644 --- a/compiler/fir/analysis-tests/testData/resolve/scopes/publicJavaAndPrivateKotlinVar.overrides.txt +++ b/compiler/fir/analysis-tests/testData/resolve/scopes/publicJavaAndPrivateKotlinVar.overrides.txt @@ -3,8 +3,8 @@ C: [Enhancement]: public abstract fun getName(): R|kotlin/String!| from Substitution scope for [Java enhancement scope for /B] for type C [id: 1] [Enhancement]: public abstract fun getName(): R|kotlin/String!| from Java enhancement scope for /A [id: 1] [Source]: public open override fun setName(newName: R|kotlin/String|): R|kotlin/Any?| from Use site scope of /C [id: 0] - [SubstitutionOverride(DeclarationSite)]: public abstract override fun setName(newName: R|kotlin/String!|): R|kotlin/Any!| from Substitution scope for [Java enhancement scope for /B] for type C [id: 1] - [Enhancement]: public abstract fun setName(newName: R|kotlin/String!|): R|ft| from Java enhancement scope for /B [id: 2] + [SubstitutionOverride(DeclarationSite)]: public abstract override fun setName(newName: R|kotlin/String!|): R|kotlin/Any?| from Substitution scope for [Java enhancement scope for /B] for type C [id: 1] + [Enhancement]: public abstract fun setName(newName: R|kotlin/String!|): R|T!| from Java enhancement scope for /B [id: 2] [Source]: private final var name: R|kotlin/String| from Use site scope of /C [id: 0] D: @@ -14,8 +14,8 @@ D: [Enhancement]: public abstract fun getName(): R|kotlin/String!| from Java enhancement scope for /A [id: 1] [Source]: public open override fun setName(newName: R|kotlin/String|): R|kotlin/Any?| from Java enhancement scope for /D [id: 0] [Source]: public open override fun setName(newName: R|kotlin/String|): R|kotlin/Any?| from Use site scope of /C [id: 0] - [SubstitutionOverride(DeclarationSite)]: public abstract override fun setName(newName: R|kotlin/String!|): R|kotlin/Any!| from Substitution scope for [Java enhancement scope for /B] for type C [id: 1] - [Enhancement]: public abstract fun setName(newName: R|kotlin/String!|): R|ft| from Java enhancement scope for /B [id: 2] + [SubstitutionOverride(DeclarationSite)]: public abstract override fun setName(newName: R|kotlin/String!|): R|kotlin/Any?| from Substitution scope for [Java enhancement scope for /B] for type C [id: 1] + [Enhancement]: public abstract fun setName(newName: R|kotlin/String!|): R|T!| from Java enhancement scope for /B [id: 2] [Source]: private final var name: R|kotlin/String| from Java enhancement scope for /D [id: 0] [Source]: private final var name: R|kotlin/String| from Use site scope of /C [id: 0] diff --git a/compiler/fir/analysis-tests/testData/resolve/scopes/specialFunctionInJava_2.overrides.txt b/compiler/fir/analysis-tests/testData/resolve/scopes/specialFunctionInJava_2.overrides.txt index 70b28b06647..a6a7686c8f2 100644 --- a/compiler/fir/analysis-tests/testData/resolve/scopes/specialFunctionInJava_2.overrides.txt +++ b/compiler/fir/analysis-tests/testData/resolve/scopes/specialFunctionInJava_2.overrides.txt @@ -1,6 +1,6 @@ SomeMap: - [Enhancement]: public abstract fun containsKey(key: R|ft|): R|kotlin/Boolean| from Java enhancement scope for /SomeMap [id: 0] - [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsKey(key: R|ft|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 1] + [Enhancement]: public abstract fun containsKey(key: R|K3!|): R|kotlin/Boolean| from Java enhancement scope for /SomeMap [id: 0] + [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsKey(key: R|K3!|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 1] [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsKey(key: R|K|): R|kotlin/Boolean| from Use site scope of kotlin/collections/MutableMap [id: 2] [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsKey(key: R|K|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/Map] for type kotlin/collections/MutableMap [id: 2] [Library]: public abstract fun containsKey(key: R|K|): R|kotlin/Boolean| from Use site scope of kotlin/collections/Map [id: 3] @@ -8,25 +8,25 @@ SomeMap: [Enhancement]: public abstract fun containsKey(key: R|kotlin/Any!|): R|kotlin/Boolean| from Java enhancement scope for /MyMap [id: 5] [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsKey(key: R|kotlin/Any!|): R|kotlin/Boolean| from Substitution scope for [Java enhancement scope for /MyBaseMap] for type MyMap [id: 6] [Enhancement]: public abstract fun containsKey(key: R|kotlin/Any!|): R|kotlin/Boolean| from Java enhancement scope for /MyBaseMap [id: 7] - [IntersectionOverride]: public abstract override fun containsValue(value: R|ft|): R|kotlin/Boolean| from Java enhancement scope for /SomeMap [id: 0] - [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsValue(value: R|ft|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 1] + [IntersectionOverride]: public abstract override fun containsValue(value: R|V3!|): R|kotlin/Boolean| from Java enhancement scope for /SomeMap [id: 0] + [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsValue(value: R|V3!|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 1] [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsValue(value: R|V|): R|kotlin/Boolean| from Use site scope of kotlin/collections/MutableMap [id: 2] [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsValue(value: R|V|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/Map] for type kotlin/collections/MutableMap [id: 2] [Library]: public abstract fun containsValue(value: R|V|): R|kotlin/Boolean| from Use site scope of kotlin/collections/Map [id: 3] [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsValue(key: R|kotlin/Any!|): R|kotlin/Boolean| from Substitution scope for [Java enhancement scope for /MyMap] for type SomeMap [id: 4] [Enhancement]: public abstract fun containsValue(key: R|kotlin/Any!|): R|kotlin/Boolean| from Java enhancement scope for /MyMap [id: 5] - [IntersectionOverride]: public abstract override operator fun get(key: R|ft|): R|V3?| from Java enhancement scope for /SomeMap [id: 0] - [SubstitutionOverride(DeclarationSite)]: public abstract override operator fun get(key: R|ft|): R|V3?| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 1] + [IntersectionOverride]: public abstract override operator fun get(key: R|K3!|): R|V3?| from Java enhancement scope for /SomeMap [id: 0] + [SubstitutionOverride(DeclarationSite)]: public abstract override operator fun get(key: R|K3!|): R|V3?| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 1] [SubstitutionOverride(DeclarationSite)]: public abstract override operator fun get(key: R|K|): R|V?| from Use site scope of kotlin/collections/MutableMap [id: 2] [SubstitutionOverride(DeclarationSite)]: public abstract override operator fun get(key: R|K|): R|V?| from Substitution scope for [Use site scope of kotlin/collections/Map] for type kotlin/collections/MutableMap [id: 2] [Library]: public abstract operator fun get(key: R|K|): R|V?| from Use site scope of kotlin/collections/Map [id: 3] - [SubstitutionOverride(DeclarationSite)]: public abstract override operator fun get(key: R|ft|): R|ft| from Substitution scope for [Java enhancement scope for /MyMap] for type SomeMap [id: 4] - [Enhancement]: public abstract operator fun get(key: R|ft|): R|ft| from Java enhancement scope for /MyMap [id: 5] - [Enhancement]: public abstract fun remove(key: R|ft|): R|@EnhancedNullability V3?| from Java enhancement scope for /SomeMap [id: 0] - [SubstitutionOverride(DeclarationSite)]: public abstract override fun remove(key: R|ft|): R|V3?| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 1] + [SubstitutionOverride(DeclarationSite)]: public abstract override operator fun get(key: R|K3!|): R|V3!| from Substitution scope for [Java enhancement scope for /MyMap] for type SomeMap [id: 4] + [Enhancement]: public abstract operator fun get(key: R|K2!|): R|V2!| from Java enhancement scope for /MyMap [id: 5] + [Enhancement]: public abstract fun remove(key: R|K3!|): R|@EnhancedNullability V3?| from Java enhancement scope for /SomeMap [id: 0] + [SubstitutionOverride(DeclarationSite)]: public abstract override fun remove(key: R|K3!|): R|V3?| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 1] [Library]: public abstract fun remove(key: R|K|): R|V?| from Use site scope of kotlin/collections/MutableMap [id: 2] - [SubstitutionOverride(DeclarationSite)]: public open override fun remove(key: R|ft|, value: R|ft|): R|kotlin/Boolean| from Java enhancement scope for /SomeMap [id: 0] - [SubstitutionOverride(DeclarationSite)]: public open override fun remove(key: R|ft|, value: R|ft|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 0] + [SubstitutionOverride(DeclarationSite)]: public open override fun remove(key: R|K3!|, value: R|V3!|): R|kotlin/Boolean| from Java enhancement scope for /SomeMap [id: 0] + [SubstitutionOverride(DeclarationSite)]: public open override fun remove(key: R|K3!|, value: R|V3!|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableMap] for type SomeMap [id: 0] [Library]: public open fun remove(key: R|K|, value: R|V|): R|kotlin/Boolean| from Use site scope of kotlin/collections/MutableMap [id: 1] MyMap: @@ -34,5 +34,5 @@ MyMap: [SubstitutionOverride(DeclarationSite)]: public abstract override fun containsKey(key: R|kotlin/Any!|): R|kotlin/Boolean| from Substitution scope for [Java enhancement scope for /MyBaseMap] for type MyMap [id: 1] [Enhancement]: public abstract fun containsKey(key: R|kotlin/Any!|): R|kotlin/Boolean| from Java enhancement scope for /MyBaseMap [id: 2] [Enhancement]: public abstract fun containsValue(key: R|kotlin/Any!|): R|kotlin/Boolean| from Java enhancement scope for /MyMap [id: 0] - [Enhancement]: public abstract operator fun get(key: R|ft|): R|ft| from Java enhancement scope for /MyMap [id: 0] + [Enhancement]: public abstract operator fun get(key: R|K2!|): R|V2!| from Java enhancement scope for /MyMap [id: 0] diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/kt50788.fir.txt b/compiler/fir/analysis-tests/testData/resolve/smartcasts/kt50788.fir.txt index 093b92f986c..8d417099e32 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/kt50788.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/kt50788.fir.txt @@ -1,5 +1,5 @@ FILE: main.kt public final fun foo(mapper: R|Mapper|, cls: R|java/lang/Class?|): R|kotlin/Unit| { - lval result: R|T & Any| = R|/mapper|.R|/Mapper.readValue|(R|/cls|)!! + lval result: R|T & Any| = R|/mapper|.R|/Mapper.readValue|(R|/cls|)!! R|/result|.R|kotlin/CharSequence.length| } diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/problems/smartcastToStarProjectedSubclass.kt b/compiler/fir/analysis-tests/testData/resolve/smartcasts/problems/smartcastToStarProjectedSubclass.kt index 8a3537c5f19..a9e2fbcfe1b 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/problems/smartcastToStarProjectedSubclass.kt +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/problems/smartcastToStarProjectedSubclass.kt @@ -15,7 +15,7 @@ public interface Option { // FILE: test.kt fun test_1(option: Option>?) { if (option is Option.Some<*>) { - val x = ..CapturedType(*)? & kotlin.Pair?")!>option.get().first + val x = ..CapturedType(*)? & kotlin.Pair?")!>option.get().first x.length } } diff --git a/compiler/fir/analysis-tests/testData/resolve/smartcasts/smartcastedField.fir.txt b/compiler/fir/analysis-tests/testData/resolve/smartcasts/smartcastedField.fir.txt index 449cc8faeaf..4e05967570c 100644 --- a/compiler/fir/analysis-tests/testData/resolve/smartcasts/smartcastedField.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/smartcasts/smartcastedField.fir.txt @@ -1,8 +1,8 @@ FILE: main.kt - private final val anyProperty: R|Property| = R|/Property.Property|() - private get(): R|Property| - private final val boundedProperty: R|Property| = R|/Property.Property|() - private get(): R|Property| + private final val anyProperty: R|Property| = R|/Property.Property|() + private get(): R|Property| + private final val boundedProperty: R|Property| = R|/Property.Property|() + private get(): R|Property| public final fun test_1(x: R|Property|): R|kotlin/Unit| { when () { (R|/x| is R|Reference|) -> { diff --git a/compiler/fir/analysis-tests/testData/resolve/types/typeAliasInArguments.fir.txt b/compiler/fir/analysis-tests/testData/resolve/types/typeAliasInArguments.fir.txt index 6656ec01d69..c523f633b7e 100644 --- a/compiler/fir/analysis-tests/testData/resolve/types/typeAliasInArguments.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolve/types/typeAliasInArguments.fir.txt @@ -3,5 +3,5 @@ FILE: main.kt public final typealias ImmutableSet = R|MySet| private final typealias ImmutableMultimap = R|ImmutableMap>| private final fun R|ImmutableMultimap|.put(key: R|K|, value: R|V|, oldSet: R|ImmutableSet|): R|ImmutableMultimap| { - ^put this@R|/put|.R|SubstitutionOverride, ft, ImmutableSet?>>, MyMap, ft, ImmutableSet?>>?>|>|(R|/key|, R|/oldSet|.R|SubstitutionOverride>, MySet>?>|>|(R|/value|)) + ^put this@R|/put|.R|SubstitutionOverride, ImmutableSet?>>, MyMap, ImmutableSet?>>?>|>|(R|/key|, R|/oldSet|.R|SubstitutionOverride, MySet?>|>|(R|/value|)) } diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/concurrentMapOfAliases.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/concurrentMapOfAliases.fir.txt index 8d3fa46a413..67cbd334f26 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/concurrentMapOfAliases.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/concurrentMapOfAliases.fir.txt @@ -5,8 +5,8 @@ FILE: concurrentMapOfAliases.kt super() } - private final val foo: R|java/util/concurrent/ConcurrentHashMap| = Q|java/util/concurrent|.R|java/util/concurrent/ConcurrentHashMap.ConcurrentHashMap|() - private get(): R|java/util/concurrent/ConcurrentHashMap| + private final val foo: R|java/util/concurrent/ConcurrentHashMap| = Q|java/util/concurrent|.R|java/util/concurrent/ConcurrentHashMap.ConcurrentHashMap|() + private get(): R|java/util/concurrent/ConcurrentHashMap| private final fun bar(): R|kotlin/Unit| { this@R|/A|.R|/A.foo|.R|SubstitutionOverride|(String(dd))?.{ (this@R|/A|, $subj$).R|/A.baz|() } diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/intellij/PersistentStateComponent.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/intellij/PersistentStateComponent.fir.txt index 2e4891c9cf6..cd8cae48e7b 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/intellij/PersistentStateComponent.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/intellij/PersistentStateComponent.fir.txt @@ -7,7 +7,7 @@ FILE: use.kt } public abstract interface PersistentStateComponent : R|kotlin/Any| { } - public final fun deserializeAndLoadState(component: R|PersistentStateComponent|, clazz: R|java/lang/Class| = Q|ComponentSerializationUtil|.R|/ComponentSerializationUtil.getStateClass*s||>((R|/component|).R|kotlin/jvm/java|)|>)): R|kotlin/Unit| { + public final fun deserializeAndLoadState(component: R|PersistentStateComponent|, clazz: R|java/lang/Class| = Q|ComponentSerializationUtil|.R|/ComponentSerializationUtil.getStateClass*s|((R|/component|).R|kotlin/jvm/java|)|>)): R|kotlin/Unit| { } public final fun use(beforeRunTask: R|BeforeRunTask<*>|): R|kotlin/Unit| { when () { diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/j+k/flexibleTypeAliases.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/j+k/flexibleTypeAliases.fir.txt index ec333cb4b2b..c3681f88aaf 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/j+k/flexibleTypeAliases.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/j+k/flexibleTypeAliases.fir.txt @@ -4,5 +4,5 @@ FILE: main.kt public final typealias ImmutableLinkedHashSet = R|imm/LinkedHashSet| private final typealias ImmutableMultimap = R|ImmutableMap>| private final fun R|ImmutableMultimap|.put(key: R|K|, value: R|V|): R|kotlin/Unit| { - this@R|/put|.R|SubstitutionOverride, ImmutableSet?>>, imm/Option, ImmutableSet?>>?>|>|(R|/key|).R|SubstitutionOverride, ImmutableSet?>|>|(Q|ImmutableLinkedHashSet|.R|imm/LinkedHashSet.empty*s|()) + this@R|/put|.R|SubstitutionOverride, ImmutableSet?>>, imm/Option, ImmutableSet?>>?>|>|(R|/key|).R|SubstitutionOverride, ImmutableSet?>|>|(Q|ImmutableLinkedHashSet|.R|imm/LinkedHashSet.empty*s|()) } diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/j+k/genericGetterForSyntheticProperty.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/j+k/genericGetterForSyntheticProperty.fir.txt index 24fb5fa2d9b..4f595645e48 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/j+k/genericGetterForSyntheticProperty.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/j+k/genericGetterForSyntheticProperty.fir.txt @@ -3,5 +3,5 @@ FILE: test.kt lval foo: = R|/some|.# lval baz: = R|/some|.# lval getFoo: = R|/some|.R|/Some.getFoo#|<>() - lval getBaz: R|kotlin/String!| = R|/some|.R|/Some.getFoo|() + lval getBaz: R|kotlin/String!| = R|/some|.R|/Some.getFoo|() } diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/javaLangComparator.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/javaLangComparator.fir.txt index f79a31161e3..781f8d24264 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/javaLangComparator.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/javaLangComparator.fir.txt @@ -1,6 +1,6 @@ FILE: javaLangComparator.kt public final fun test_2(list: R|kotlin/collections/List|): R|kotlin/Unit| { - lval comp: R|java/util/Comparator| = Q|java/util|.R|java/util/Comparator|( = Comparator@fun (x: R|kotlin/Int!|, y: R|kotlin/Int!|): R|kotlin/Int| { + lval comp: R|java/util/Comparator| = Q|java/util|.R|java/util/Comparator|( = Comparator@fun (x: R|kotlin/Int!|, y: R|kotlin/Int!|): R|kotlin/Int| { ^ Int(1) } ) diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/NamedParameterInConcurrentMap.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/NamedParameterInConcurrentMap.fir.txt index 5a8588c350c..46d1480c955 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/NamedParameterInConcurrentMap.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/NamedParameterInConcurrentMap.fir.txt @@ -1,5 +1,5 @@ FILE: NamedParameterInConcurrentMap.kt public final fun main(): R|kotlin/Unit| { - lval map: R|java/util/concurrent/ConcurrentHashMap| = R|java/util/concurrent/ConcurrentHashMap.ConcurrentHashMap|() + lval map: R|java/util/concurrent/ConcurrentHashMap| = R|java/util/concurrent/ConcurrentHashMap.ConcurrentHashMap|() R|/map|.R|SubstitutionOverride|(key = String(key), value = String(value)) } diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/malformedRawTypes.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/malformedRawTypes.fir.txt index b2126ae3e11..c1eeb56455c 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/malformedRawTypes.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/malformedRawTypes.fir.txt @@ -2,7 +2,7 @@ FILE: Main.kt public final fun main(): R|kotlin/Unit| { lvar generic: R|ft, Generic<*>?>| = Q|Generic|.R|/Generic.raw*s| lvar inner1: R|ft, Generic.Inner<*>?>| = R|/generic|.R|SubstitutionOverride| - R|/inner1| = R|/Generic.Generic|().R|SubstitutionOverride|() + R|/inner1| = R|/Generic.Generic|().R|SubstitutionOverride|() lvar inner2: R|ft, Generic.Inner<*>?>| = R|/generic|.R|SubstitutionOverride| - R|/inner2| = R|/Generic.Generic|().R|SubstitutionOverride|() + R|/inner2| = R|/Generic.Generic|().R|SubstitutionOverride|() } diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/weakHashMap.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/weakHashMap.fir.txt index 6f3187fc599..cf244330b65 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/weakHashMap.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/problems/weakHashMap.fir.txt @@ -1,6 +1,6 @@ FILE: weakHashMap.kt - public final val someMap: R|java/util/WeakHashMap| = R|java/util/WeakHashMap.WeakHashMap|() - public get(): R|java/util/WeakHashMap| + public final val someMap: R|java/util/WeakHashMap| = R|java/util/WeakHashMap.WeakHashMap|() + public get(): R|java/util/WeakHashMap| public final fun foo(): R|kotlin/Unit| { R|/someMap|.R|SubstitutionOverride|(String()) } diff --git a/compiler/fir/analysis-tests/testData/resolveWithStdlib/typeAliasWithForEach.fir.txt b/compiler/fir/analysis-tests/testData/resolveWithStdlib/typeAliasWithForEach.fir.txt index e00e26606fe..fa5f3fe2096 100644 --- a/compiler/fir/analysis-tests/testData/resolveWithStdlib/typeAliasWithForEach.fir.txt +++ b/compiler/fir/analysis-tests/testData/resolveWithStdlib/typeAliasWithForEach.fir.txt @@ -9,9 +9,9 @@ FILE: typeAliasWithForEach.kt } public final typealias Arguments = R|kotlin/collections/Map| public final fun R|Arguments|.deepCopy(): R|Arguments| { - lval result: R|java/util/HashMap| = R|java/util/HashMap.HashMap|() + lval result: R|java/util/HashMap| = R|java/util/HashMap.HashMap|() this@R|/deepCopy|.R|SubstitutionOverride|( = SAM(forEach@fun (key: R|@EnhancedNullability kotlin/String|, value: R|@EnhancedNullability ArgsInfo|): R|kotlin/Unit| { - R|/result|.R|kotlin/collections/set|(R|/key|, R|/ArgsInfoImpl.ArgsInfoImpl|(R|/value|)) + R|/result|.R|kotlin/collections/set|(R|/key|, R|/ArgsInfoImpl.ArgsInfoImpl|(R|/value|)) Unit } )) diff --git a/compiler/fir/java/src/org/jetbrains/kotlin/fir/java/JavaTypeConversion.kt b/compiler/fir/java/src/org/jetbrains/kotlin/fir/java/JavaTypeConversion.kt index 53ac05730ff..a3877914fb9 100644 --- a/compiler/fir/java/src/org/jetbrains/kotlin/fir/java/JavaTypeConversion.kt +++ b/compiler/fir/java/src/org/jetbrains/kotlin/fir/java/JavaTypeConversion.kt @@ -110,19 +110,7 @@ private fun JavaType?.toConeTypeProjection( } val upperBound = toConeKotlinTypeForFlexibleBound(session, javaTypeParameterStack, mode, attributes, lowerBound) - val finalLowerBound = when (lowerBound) { - is ConeTypeParameterType -> - ConeDefinitelyNotNullType.create( - lowerBound, session.typeContext, - // Upper bounds might be not initialized properly yet, so we force creating DefinitelyNotNullType - // It should not affect semantics, since it would be still a valid type anyway - avoidComprehensiveCheck = true, - ) ?: lowerBound - - else -> lowerBound - } - - if (isRaw) ConeRawType.create(finalLowerBound, upperBound) else ConeFlexibleType(finalLowerBound, upperBound) + if (isRaw) ConeRawType.create(lowerBound, upperBound) else ConeFlexibleType(lowerBound, upperBound) } is JavaArrayType -> { diff --git a/compiler/fir/providers/src/org/jetbrains/kotlin/fir/types/ConeInferenceContext.kt b/compiler/fir/providers/src/org/jetbrains/kotlin/fir/types/ConeInferenceContext.kt index 1c7eeff4a19..0b60deb9d75 100644 --- a/compiler/fir/providers/src/org/jetbrains/kotlin/fir/types/ConeInferenceContext.kt +++ b/compiler/fir/providers/src/org/jetbrains/kotlin/fir/types/ConeInferenceContext.kt @@ -587,7 +587,7 @@ interface ConeInferenceContext : TypeSystemInferenceExtensionContext, ConeTypeCo return intersectionType.withAlternative(secondCandidate) } - override fun useRefinedBoundsForTypeVariableInFlexiblePosition(): Boolean = true + override fun useRefinedBoundsForTypeVariableInFlexiblePosition(): Boolean = false override fun KotlinTypeMarker.convertToNonRaw(): KotlinTypeMarker { require(this is ConeKotlinType) diff --git a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/calls/CreateFreshTypeVariableSubstitutorStage.kt b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/calls/CreateFreshTypeVariableSubstitutorStage.kt index 6a30160a385..a76ace8d654 100644 --- a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/calls/CreateFreshTypeVariableSubstitutorStage.kt +++ b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/calls/CreateFreshTypeVariableSubstitutorStage.kt @@ -15,6 +15,7 @@ import org.jetbrains.kotlin.fir.resolve.inference.model.ConeExplicitTypeParamete import org.jetbrains.kotlin.fir.resolve.substitution.ConeSubstitutor import org.jetbrains.kotlin.fir.resolve.substitution.substitutorByMap import org.jetbrains.kotlin.fir.scopes.impl.toConeType +import org.jetbrains.kotlin.fir.symbols.ConeTypeParameterLookupTag import org.jetbrains.kotlin.fir.symbols.lazyResolveToPhase import org.jetbrains.kotlin.fir.types.* import org.jetbrains.kotlin.name.StandardClassIds @@ -55,7 +56,11 @@ internal object CreateFreshTypeVariableSubstitutorStage : ResolutionStage() { when (val typeArgument = candidate.typeArgumentMapping[index]) { is FirTypeProjectionWithVariance -> csBuilder.addEqualityConstraint( freshVariable.defaultType, - typeArgument.typeRef.coneType.fullyExpandedType(context.session), + getTypePreservingFlexibilityWrtTypeVariable( + typeArgument.typeRef.coneType, + typeParameter, + context.session + ).fullyExpandedType(context.session), ConeExplicitTypeParameterConstraintPosition(typeArgument) ) is FirStarProjection -> csBuilder.addEqualityConstraint( @@ -76,6 +81,28 @@ internal object CreateFreshTypeVariableSubstitutorStage : ResolutionStage() { sink.yieldIfNeed() } } + + private fun getTypePreservingFlexibilityWrtTypeVariable( + type: ConeKotlinType, + typeParameter: FirTypeParameterRef, + session: FirSession, + ): ConeKotlinType { + return if (typeParameter.shouldBeFlexible(session.typeContext)) { + val notNullType = type.withNullability(ConeNullability.NOT_NULL, session.typeContext) as ConeSimpleKotlinType + ConeFlexibleType(notNullType, notNullType.withNullability(ConeNullability.NULLABLE, session.typeContext)) + } else { + type + } + } + + private fun FirTypeParameterRef.shouldBeFlexible(context: ConeTypeContext): Boolean { + return symbol.resolvedBounds.any { + val type = it.coneType + type is ConeFlexibleType || with(context) { + (type.typeConstructor() as? ConeTypeParameterLookupTag)?.symbol?.fir?.shouldBeFlexible(context) ?: false + } + } + } } private fun createToFreshVariableSubstitutorAndAddInitialConstraints( diff --git a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/inference/ConeConstraintSystemUtilContext.kt b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/inference/ConeConstraintSystemUtilContext.kt index 0120ffe90e4..58da2568c81 100644 --- a/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/inference/ConeConstraintSystemUtilContext.kt +++ b/compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/inference/ConeConstraintSystemUtilContext.kt @@ -8,9 +8,8 @@ package org.jetbrains.kotlin.fir.resolve.inference import org.jetbrains.kotlin.fir.declarations.FirAnonymousFunction import org.jetbrains.kotlin.fir.resolve.inference.model.ConeArgumentConstraintPosition import org.jetbrains.kotlin.fir.resolve.inference.model.ConeFixVariableConstraintPosition -import org.jetbrains.kotlin.fir.types.ConeKotlinType -import org.jetbrains.kotlin.fir.types.coneType -import org.jetbrains.kotlin.fir.types.coneTypeSafe +import org.jetbrains.kotlin.fir.symbols.ConeTypeParameterLookupTag +import org.jetbrains.kotlin.fir.types.* import org.jetbrains.kotlin.name.StandardClassIds import org.jetbrains.kotlin.resolve.calls.inference.components.ConstraintSystemUtilContext import org.jetbrains.kotlin.resolve.calls.inference.components.PostponedArgumentInputTypesResolver @@ -22,9 +21,12 @@ import org.jetbrains.kotlin.types.model.TypeVariableMarker object ConeConstraintSystemUtilContext : ConstraintSystemUtilContext { override fun TypeVariableMarker.shouldBeFlexible(): Boolean { - // In FIR, there's no need in hack with shouldTryUseDifferentFlexibilityForUpperType - // See org.jetbrains.kotlin.types.model.TypeSystemInferenceExtensionContext.useRefinedBoundsForTypeVariableInFlexiblePosition - return false + if (this !is ConeTypeVariable) return false + val typeParameter = + (this.typeConstructor.originalTypeParameter as? ConeTypeParameterLookupTag)?.typeParameterSymbol?.fir ?: return false + + // TODO: Take a look at org.jetbrains.kotlin.resolve.calls.components.CreateFreshVariablesSubstitutor.shouldBeFlexible + return typeParameter.bounds.any { it.coneType is ConeFlexibleType } } override fun TypeVariableMarker.hasOnlyInputTypesAttribute(): Boolean { diff --git a/compiler/testData/codegen/box/sam/kt54600.fir.ir.txt b/compiler/testData/codegen/box/sam/kt54600.fir.ir.txt index 175f7609d3c..56359dd5346 100644 --- a/compiler/testData/codegen/box/sam/kt54600.fir.ir.txt +++ b/compiler/testData/codegen/box/sam/kt54600.fir.ir.txt @@ -10,7 +10,7 @@ FILE fqName: fileName:/box.kt TYPE_OP type=kotlin.Unit origin=IMPLICIT_COERCION_TO_UNIT typeOperand=kotlin.Unit CONSTRUCTOR_CALL 'public constructor (filter: @[FlexibleNullability] .Condition?) declared in .J' type=.J origin=null filter: TYPE_OP type=.Condition? origin=SAM_CONVERSION typeOperand=.Condition? - TYPE_OP type=kotlin.Function1<@[FlexibleNullability] kotlin.Any?, kotlin.Boolean>? origin=IMPLICIT_CAST typeOperand=kotlin.Function1<@[FlexibleNullability] kotlin.Any?, kotlin.Boolean>? + TYPE_OP type=kotlin.Function1? origin=IMPLICIT_CAST typeOperand=kotlin.Function1? GET_VAR 'filter: kotlin.Function1? declared in .foo' type=kotlin.Function1? origin=null RETURN type=kotlin.Nothing from='public final fun foo (filter: kotlin.Function1?): kotlin.String declared in ' CONST String type=kotlin.String value="OK" diff --git a/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/jspecify/strictMode/interconnectedGenerics.fir.txt b/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/jspecify/strictMode/interconnectedGenerics.fir.txt index fca21f65196..8c5a52a5efc 100644 --- a/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/jspecify/strictMode/interconnectedGenerics.fir.txt +++ b/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/jspecify/strictMode/interconnectedGenerics.fir.txt @@ -34,7 +34,7 @@ FILE: Eq.kt public get(): R|lib/a/A| public open override fun withL(l: R|kotlin/Int|): R|lib/a/C.WithL| { - ^withL Q|lib/a/C|.R|lib/a/C.MyWithL.MyWithL|() + ^withL Q|lib/a/C|.R|lib/a/C.MyWithL.MyWithL|() } } diff --git a/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/misc/returnType.fir.kt b/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/misc/returnType.fir.kt index 9e7afe98bd6..5ffa631c516 100644 --- a/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/misc/returnType.fir.kt +++ b/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/misc/returnType.fir.kt @@ -37,7 +37,7 @@ fun main(a: ReturnType) { takeNullableStringAndKNullable(x1) takeNotNullStringAndNotNullK(x1) takeNullableStringAndNotNullK(x1) - takeNotNullString(a.foo41.foo411) + takeNotNullString(a.foo41.foo411) val x2 = ..ReturnType.A?!")!>a.foo2() takeNotNullStringAndKNullable(x2) diff --git a/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/misc/returnTypeWithWarnings.fir.kt b/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/misc/returnTypeWithWarnings.fir.kt index a4f90d4e4c9..d82b4e8a073 100644 --- a/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/misc/returnTypeWithWarnings.fir.kt +++ b/compiler/testData/diagnostics/foreignAnnotationsTests/java8Tests/misc/returnTypeWithWarnings.fir.kt @@ -39,7 +39,7 @@ fun main(a: ReturnTypeWithWarnings) { takeNullableStringAndKNullable(x1) takeNotNullStringAndNotNullK(x1) takeNullableStringAndNotNullK(x1) - takeNotNullString(a.foo41.foo411) + takeNotNullString(a.foo41.foo411) val x2 = ..ReturnTypeWithWarnings.A?!")!>a.foo2() takeNotNullStringAndKNullable(x2) diff --git a/compiler/testData/diagnostics/foreignAnnotationsTests/tests/jsr305/nullabilityWarnings/override.fir.kt b/compiler/testData/diagnostics/foreignAnnotationsTests/tests/jsr305/nullabilityWarnings/override.fir.kt index a771ab21b9d..0097d43ce28 100644 --- a/compiler/testData/diagnostics/foreignAnnotationsTests/tests/jsr305/nullabilityWarnings/override.fir.kt +++ b/compiler/testData/diagnostics/foreignAnnotationsTests/tests/jsr305/nullabilityWarnings/override.fir.kt @@ -66,10 +66,10 @@ abstract class A : Provider { abstract class B : Provider { override fun get(): T & Any = null!! override fun getNullable(): T? = null!! - override fun set(x: T & Any) {} // False positive in K1 + override fun set(x: T & Any) {} // False positive in K1 override fun setNullable(x: T?) {} - override fun getSet(x: T & Any): T & Any = x // False positive in K1 + override fun getSet(x: T & Any): T & Any = x // False positive in K1 override fun getSetNullable(x: T?): T? = x } @@ -79,6 +79,6 @@ abstract class C : Provider { } abstract class D : Provider { - override fun getSet(x: T & Any): T = x!! // False positive in K1 + override fun getSet(x: T & Any): T = x!! // False positive in K1 override fun getSetNullable(x: T?): T = x!! } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/explicitDefinitelyNotNullableViaIntersection/overridesJavaAnnotated.fir.kt b/compiler/testData/diagnostics/tests/explicitDefinitelyNotNullableViaIntersection/overridesJavaAnnotated.fir.kt deleted file mode 100644 index 1d9271fe438..00000000000 --- a/compiler/testData/diagnostics/tests/explicitDefinitelyNotNullableViaIntersection/overridesJavaAnnotated.fir.kt +++ /dev/null @@ -1,42 +0,0 @@ -// !LANGUAGE: +DefinitelyNonNullableTypes +ProhibitUsingNullableTypeParameterAgainstNotNullAnnotated - -// FILE: A.java -import org.jetbrains.annotations.*; - -public interface A { - public T foo(T x) { return x; } - @NotNull - public T bar(@NotNull T x) {} -} - -// FILE: main.kt - -interface B : A { - override fun foo(x: T1): T1 - override fun bar(x: T1 & Any): T1 & Any -} - -interface C : A { - override fun foo(x: T2 & Any): T2 & Any - override fun bar(x: T2): T2 -} - -interface D : A { - override fun foo(x: String?): String? - override fun bar(x: String): String -} - -interface E : A { - override fun foo(x: String): String - override fun bar(x: String): String -} - -interface F : A { - override fun foo(x: String): String - override fun bar(x: String?): String? -} - -interface G : A { - override fun foo(x: T3): T3 - override fun bar(x: T3): T3 -} diff --git a/compiler/testData/diagnostics/tests/explicitDefinitelyNotNullableViaIntersection/overridesJavaAnnotated.kt b/compiler/testData/diagnostics/tests/explicitDefinitelyNotNullableViaIntersection/overridesJavaAnnotated.kt index 4d0839a47ef..8fc72d541dc 100644 --- a/compiler/testData/diagnostics/tests/explicitDefinitelyNotNullableViaIntersection/overridesJavaAnnotated.kt +++ b/compiler/testData/diagnostics/tests/explicitDefinitelyNotNullableViaIntersection/overridesJavaAnnotated.kt @@ -1,3 +1,4 @@ +// FIR_IDENTICAL // !LANGUAGE: +DefinitelyNonNullableTypes +ProhibitUsingNullableTypeParameterAgainstNotNullAnnotated // FILE: A.java diff --git a/compiler/testData/diagnostics/tests/inference/builderInference/stubTypes/commonSuperTypeContravariant.fir.kt b/compiler/testData/diagnostics/tests/inference/builderInference/stubTypes/commonSuperTypeContravariant.fir.kt index 2a6c40b70e3..695cf37abda 100644 --- a/compiler/testData/diagnostics/tests/inference/builderInference/stubTypes/commonSuperTypeContravariant.fir.kt +++ b/compiler/testData/diagnostics/tests/inference/builderInference/stubTypes/commonSuperTypeContravariant.fir.kt @@ -73,14 +73,14 @@ fun test() { } val ret2 = build { emit(if (true) "" else null) - select2(get(), getIn()) - select2(get(), Test.foo(getIn())) - select2(Test.foo(get()), Test.foo(getIn())) - select2(Test.foo(get()), getIn()) - select3(get(), getIn()) - select3(get(), Test.foo(getIn())) - select3(Test.foo(get()), Test.foo(getIn())) - select3(Test.foo(get()), getIn()) + select2(get(), getIn()) + select2(get(), Test.foo(getIn())) + select2(Test.foo(get()), Test.foo(getIn())) + select2(Test.foo(get()), getIn()) + select3(get(), getIn()) + select3(get(), Test.foo(getIn())) + select3(Test.foo(get()), Test.foo(getIn())) + select3(Test.foo(get()), getIn()) "" } } diff --git a/compiler/testData/diagnostics/tests/inference/findViewById.fir.kt b/compiler/testData/diagnostics/tests/inference/findViewById.fir.kt index 9921888d514..79e20e83328 100644 --- a/compiler/testData/diagnostics/tests/inference/findViewById.fir.kt +++ b/compiler/testData/diagnostics/tests/inference/findViewById.fir.kt @@ -27,7 +27,7 @@ val xExplicit: X = Test().findViewById(0) val xCast = Test().findViewById(0) as X val xCastExplicitType = Test().findViewById(0) as X -val xSafeCastExplicitType = Test().findViewById(0) as? X +val xSafeCastExplicitType = Test().findViewById(0) as? X val yExplicit: Y = Test().findViewById(0) val yCast = Test().findViewById(0) as Y diff --git a/compiler/testData/diagnostics/tests/inference/recursiveTypes/selfTypes/enabledInferenceOnSelfTypes/basicInferenceForImplicitSelfType.fir.kt b/compiler/testData/diagnostics/tests/inference/recursiveTypes/selfTypes/enabledInferenceOnSelfTypes/basicInferenceForImplicitSelfType.fir.kt index cbd57fd4dd8..74bf4859dea 100644 --- a/compiler/testData/diagnostics/tests/inference/recursiveTypes/selfTypes/enabledInferenceOnSelfTypes/basicInferenceForImplicitSelfType.fir.kt +++ b/compiler/testData/diagnostics/tests/inference/recursiveTypes/selfTypes/enabledInferenceOnSelfTypes/basicInferenceForImplicitSelfType.fir.kt @@ -43,7 +43,7 @@ fun > testTypeParam(builder: Builder) { } fun testStarJava(builder: JavaBuilder<*>) { - builder.test() + builder.test() builder .test() diff --git a/compiler/testData/diagnostics/tests/inference/recursiveTypes/selfTypes/enabledInferenceOnSelfTypes/writerAppenderExampleRecursive.fir.kt b/compiler/testData/diagnostics/tests/inference/recursiveTypes/selfTypes/enabledInferenceOnSelfTypes/writerAppenderExampleRecursive.fir.kt index 11385017a5f..b2ac671bc6f 100644 --- a/compiler/testData/diagnostics/tests/inference/recursiveTypes/selfTypes/enabledInferenceOnSelfTypes/writerAppenderExampleRecursive.fir.kt +++ b/compiler/testData/diagnostics/tests/inference/recursiveTypes/selfTypes/enabledInferenceOnSelfTypes/writerAppenderExampleRecursive.fir.kt @@ -26,10 +26,10 @@ fun test() { } fun testJava(appender: JavaWriterAppender) { - appender.newBuilder() + appender.newBuilder() ")!>appender.Builder1() - appender.intersectTwoSelfTypes() + appender.intersectTwoSelfTypes() } object WriterAppender { diff --git a/compiler/testData/diagnostics/tests/j+k/collectionOverrides/intersectionWithMappedSignature.fir.overrides.txt b/compiler/testData/diagnostics/tests/j+k/collectionOverrides/intersectionWithMappedSignature.fir.overrides.txt index 6249bd308c6..c87e7c46eab 100644 --- a/compiler/testData/diagnostics/tests/j+k/collectionOverrides/intersectionWithMappedSignature.fir.overrides.txt +++ b/compiler/testData/diagnostics/tests/j+k/collectionOverrides/intersectionWithMappedSignature.fir.overrides.txt @@ -7,13 +7,13 @@ B2: [IntersectionOverride]: public open override fun remove(p0: R|@EnhancedNullability kotlin/Int|): R|kotlin/Boolean| from Use site scope of /B2 [id: 0] [SubstitutionOverride(DeclarationSite)]: public open override fun remove(p0: R|@EnhancedNullability kotlin/Int|): R|kotlin/Boolean| from Substitution scope for [Java enhancement scope for java/util/ArrayList] for type B2 [id: 1] [Enhancement]: public open fun remove(p0: R|@EnhancedNullability E|): R|kotlin/Boolean| from Java enhancement scope for java/util/ArrayList [id: 2] - [SubstitutionOverride(DeclarationSite)]: public open override fun remove(p0: R|ft|): R|kotlin/Boolean| from Substitution scope for [Java enhancement scope for java/util/AbstractList] for type java/util/ArrayList [id: 3] - [IntersectionOverride]: public open override fun remove(p0: R|ft|): R|kotlin/Boolean| from Java enhancement scope for java/util/AbstractList [id: 4] - [SubstitutionOverride(DeclarationSite)]: public open override fun remove(p0: R|ft|): R|kotlin/Boolean| from Substitution scope for [Java enhancement scope for java/util/AbstractCollection] for type java/util/AbstractList [id: 5] - [Enhancement]: public open fun remove(p0: R|ft|): R|kotlin/Boolean| from Java enhancement scope for java/util/AbstractCollection [id: 6] - [SubstitutionOverride(DeclarationSite)]: public abstract override fun remove(element: R|ft|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableCollection] for type java/util/AbstractCollection [id: 7] + [SubstitutionOverride(DeclarationSite)]: public open override fun remove(p0: R|E!|): R|kotlin/Boolean| from Substitution scope for [Java enhancement scope for java/util/AbstractList] for type java/util/ArrayList [id: 3] + [IntersectionOverride]: public open override fun remove(p0: R|E!|): R|kotlin/Boolean| from Java enhancement scope for java/util/AbstractList [id: 4] + [SubstitutionOverride(DeclarationSite)]: public open override fun remove(p0: R|E!|): R|kotlin/Boolean| from Substitution scope for [Java enhancement scope for java/util/AbstractCollection] for type java/util/AbstractList [id: 5] + [Enhancement]: public open fun remove(p0: R|E!|): R|kotlin/Boolean| from Java enhancement scope for java/util/AbstractCollection [id: 6] + [SubstitutionOverride(DeclarationSite)]: public abstract override fun remove(element: R|E!|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableCollection] for type java/util/AbstractCollection [id: 7] [Library]: public abstract fun remove(element: R|E|): R|kotlin/Boolean| from Use site scope of kotlin/collections/MutableCollection [id: 8] - [SubstitutionOverride(DeclarationSite)]: public abstract override fun remove(element: R|ft|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableList] for type java/util/AbstractList [id: 9] + [SubstitutionOverride(DeclarationSite)]: public abstract override fun remove(element: R|E!|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableList] for type java/util/AbstractList [id: 9] [Library]: public abstract fun remove(element: R|E|): R|kotlin/Boolean| from Use site scope of kotlin/collections/MutableList [id: 10] [SubstitutionOverride(DeclarationSite)]: public abstract override fun remove(element: R|E|): R|kotlin/Boolean| from Substitution scope for [Use site scope of kotlin/collections/MutableCollection] for type kotlin/collections/MutableList [id: 11] [Library]: public abstract fun remove(element: R|E|): R|kotlin/Boolean| from Use site scope of kotlin/collections/MutableCollection [id: 8] diff --git a/compiler/testData/diagnostics/tests/j+k/flexibleTypeVariablePosition.fir.kt b/compiler/testData/diagnostics/tests/j+k/flexibleTypeVariablePosition.fir.kt deleted file mode 100644 index cc27057f80d..00000000000 --- a/compiler/testData/diagnostics/tests/j+k/flexibleTypeVariablePosition.fir.kt +++ /dev/null @@ -1,21 +0,0 @@ -// ISSUE: KT-59138 -// SKIP_TXT -// FILE: JavaClass.java -public class JavaClass { - public static K simpleId(K k) { // fun simpleId(k: K & Any..K?): K & Any..K? = - return k; - } -} - -// FILE: main.kt - -fun takeN(n: Number?): Int = 1 - -fun bar(n: Number?) { - fun takeN(n: Number): String = "" - - // in K1, it was resolved to nullable takeN - // in K2, it would be resolved to not-nullable and may fail with NPE - takeN(JavaClass.simpleId(n)).div(1) - takeN(JavaClass.simpleId(n)).length -} diff --git a/compiler/testData/diagnostics/tests/j+k/flexibleTypeVariablePosition.kt b/compiler/testData/diagnostics/tests/j+k/flexibleTypeVariablePosition.kt index f2e31dcdb5a..bd9ca3530dc 100644 --- a/compiler/testData/diagnostics/tests/j+k/flexibleTypeVariablePosition.kt +++ b/compiler/testData/diagnostics/tests/j+k/flexibleTypeVariablePosition.kt @@ -1,3 +1,4 @@ +// FIR_IDENTICAL // ISSUE: KT-59138 // SKIP_TXT // FILE: JavaClass.java diff --git a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/removeAt.overrides.txt b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/removeAt.overrides.txt index 0e4d4203beb..b46a9794e46 100644 --- a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/removeAt.overrides.txt +++ b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/removeAt.overrides.txt @@ -5,8 +5,8 @@ A: [Library]: public abstract fun removeAt(index: R|kotlin/Int|): R|E| from Use site scope of kotlin/collections/AbstractMutableList [id: 2] [SubstitutionOverride(DeclarationSite)]: public abstract override fun removeAt(index: R|kotlin/Int|): R|E| from Substitution scope for [Use site scope of kotlin/collections/MutableList] for type kotlin/collections/AbstractMutableList [id: 3] [Library]: public abstract fun removeAt(index: R|kotlin/Int|): R|E| from Use site scope of kotlin/collections/MutableList [id: 4] - [SubstitutionOverride(DeclarationSite)]: public open override operator fun removeAt(p0: R|kotlin/Int|): R|ft| from Substitution scope for [Java enhancement scope for java/util/AbstractList] for type kotlin/collections/AbstractMutableList [id: 5] - [Enhancement]: public open operator fun removeAt(p0: R|kotlin/Int|): R|ft| from Java enhancement scope for java/util/AbstractList [id: 6] - [SubstitutionOverride(DeclarationSite)]: public abstract override fun removeAt(index: R|kotlin/Int|): R|ft| from Substitution scope for [Use site scope of kotlin/collections/MutableList] for type java/util/AbstractList [id: 7] + [SubstitutionOverride(DeclarationSite)]: public open override operator fun removeAt(p0: R|kotlin/Int|): R|E!| from Substitution scope for [Java enhancement scope for java/util/AbstractList] for type kotlin/collections/AbstractMutableList [id: 5] + [Enhancement]: public open operator fun removeAt(p0: R|kotlin/Int|): R|E!| from Java enhancement scope for java/util/AbstractList [id: 6] + [SubstitutionOverride(DeclarationSite)]: public abstract override fun removeAt(index: R|kotlin/Int|): R|E!| from Substitution scope for [Use site scope of kotlin/collections/MutableList] for type java/util/AbstractList [id: 7] [Library]: public abstract fun removeAt(index: R|kotlin/Int|): R|E| from Use site scope of kotlin/collections/MutableList [id: 4] diff --git a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution.overrides.txt b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution.overrides.txt index 5fb602e479c..fd1e49e1040 100644 --- a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution.overrides.txt +++ b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution.overrides.txt @@ -2,6 +2,6 @@ D: [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Use site scope of /D [id: 0] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Use site scope of /C [id: 0] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Substitution scope for [Java enhancement scope for /A] for type C [id: 0] - [Enhancement]: public open fun foo(x: R|kotlin/Int!|): R|ft| from Java enhancement scope for /A [id: 1] + [Enhancement]: public open fun foo(x: R|kotlin/Int!|): R|T!| from Java enhancement scope for /A [id: 1] [Source]: public open fun foo(x: R|kotlin/Int|): R|kotlin/String| from Use site scope of /D [id: 0] [Source]: public open fun foo(x: R|kotlin/Int|): R|kotlin/String| from Use site scope of /B [id: 0] diff --git a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution2.overrides.txt b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution2.overrides.txt index 627b49c8f0d..5fe7fe61a5a 100644 --- a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution2.overrides.txt +++ b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution2.overrides.txt @@ -2,6 +2,6 @@ D: [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Use site scope of /D [id: 0] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Java enhancement scope for /C [id: 0] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Substitution scope for [Java enhancement scope for /A] for type C [id: 0] - [Enhancement]: public open fun foo(x: R|ft|): R|kotlin/String!| from Java enhancement scope for /A [id: 1] + [Enhancement]: public open fun foo(x: R|T!|): R|kotlin/String!| from Java enhancement scope for /A [id: 1] [Source]: public open fun foo(x: R|kotlin/Int|): R|kotlin/String| from Use site scope of /D [id: 0] [Source]: public open fun foo(x: R|kotlin/Int|): R|kotlin/String| from Use site scope of /B [id: 0] diff --git a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution3.overrides.txt b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution3.overrides.txt index 3fb578242d4..d875ae55127 100644 --- a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution3.overrides.txt +++ b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution3.overrides.txt @@ -2,6 +2,6 @@ D: [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Use site scope of /D [id: 0] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Use site scope of /C [id: 0] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Substitution scope for [Java enhancement scope for /A] for type C [id: 0] - [Enhancement]: public open fun foo(x: R|ft|): R|kotlin/String!| from Java enhancement scope for /A [id: 1] + [Enhancement]: public open fun foo(x: R|T!|): R|kotlin/String!| from Java enhancement scope for /A [id: 1] [Source]: public open fun foo(x: R|kotlin/Int|): R|kotlin/String| from Use site scope of /D [id: 0] [Source]: public open fun foo(x: R|kotlin/Int|): R|kotlin/String| from Use site scope of /B [id: 0] diff --git a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution4.fir.overrides.txt b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution4.fir.overrides.txt index 3e3a4f905ea..89979752f94 100644 --- a/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution4.fir.overrides.txt +++ b/compiler/testData/diagnostics/tests/j+k/primitiveOverrides/triangleWithFlexibleTypeAndSubstitution4.fir.overrides.txt @@ -2,7 +2,7 @@ E: [IntersectionOverride]: public? open override fun foo(x: R|kotlin/Int|): R|kotlin/String| from Use site scope of /E [id: 0] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Use site scope of /C [id: 1] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int!|): R|kotlin/String!| from Substitution scope for [Java enhancement scope for /A] for type C [id: 1] - [Enhancement]: public open fun foo(x: R|ft|): R|kotlin/String!| from Java enhancement scope for /A [id: 2] + [Enhancement]: public open fun foo(x: R|T!|): R|kotlin/String!| from Java enhancement scope for /A [id: 2] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int|): R|kotlin/String| from Use site scope of /D [id: 3] [SubstitutionOverride(DeclarationSite)]: public open override fun foo(x: R|kotlin/Int|): R|kotlin/String| from Substitution scope for [Use site scope of /B] for type D [id: 3] [Source]: public open fun foo(x: R|T|): R|kotlin/String| from Use site scope of /B [id: 4] diff --git a/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullable.fir.kt b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullable.fir.kt index 4fe57a3269a..67df722dfa9 100644 --- a/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullable.fir.kt +++ b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullable.fir.kt @@ -23,7 +23,7 @@ fun SLRUMap.getOrPut(value: V, l: List) { takeE(value) takeEList(l) - takeE(id(value)) + takeE(id(value)) if (value != null) { takeV(value) diff --git a/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.diag.txt b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.diag.txt index 974ad9eb4af..2c53a2f7021 100644 --- a/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.diag.txt +++ b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.diag.txt @@ -5,3 +5,5 @@ /main.kt:(133,138): error: Argument type mismatch: actual type is 'V', but 'E & Any' was expected. /main.kt:(154,155): error: Argument type mismatch: actual type is 'kotlin.collections.List', but 'kotlin.collections.(Mutable)List<@NotNull() E & Any>' was expected. + +/main.kt:(167,176): error: Argument type mismatch: actual type is 'V!', but 'E & Any' was expected. diff --git a/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.kt b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.kt index 09e064e0e2a..c6d92c67b15 100644 --- a/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.kt +++ b/compiler/testData/diagnostics/tests/j+k/types/notNullTypeParameterWithKotlinNullableWarnings.fir.kt @@ -24,7 +24,7 @@ fun SLRUMap.getOrPut(value: V, l: List) { takeE(value) takeEList(l) - takeE(id(value)) + takeE(id(value)) if (value != null) { takeV(value) diff --git a/compiler/testData/diagnostics/tests/nullableTypes/inferenceFlexibleTToNullable.fir.kt b/compiler/testData/diagnostics/tests/nullableTypes/inferenceFlexibleTToNullable.fir.kt index 80a1eb0fd75..73fc3435525 100644 --- a/compiler/testData/diagnostics/tests/nullableTypes/inferenceFlexibleTToNullable.fir.kt +++ b/compiler/testData/diagnostics/tests/nullableTypes/inferenceFlexibleTToNullable.fir.kt @@ -31,12 +31,12 @@ public class Foo { // FILE: main.kt fun bar(n: Number?, d: T, e: T) { - val a: Number = Foo.simpleId(n) + val a: Number = Foo.simpleId(n) val b: Number? = Foo.simpleId(n) val c = Foo.simpleId(n) val x4 = Foo(if (true) 10 else null) - val x5: Number = x4.produceT() + val x5: Number = x4.produceT() val x6: Number? = x4.produceT() val x7 = x4.produceT() val x8 = x4.produceNotNullT() diff --git a/compiler/testData/diagnostics/tests/override/dnnOverridesFlexible.fir.kt b/compiler/testData/diagnostics/tests/override/dnnOverridesFlexible.fir.kt deleted file mode 100644 index 2140a9578e4..00000000000 --- a/compiler/testData/diagnostics/tests/override/dnnOverridesFlexible.fir.kt +++ /dev/null @@ -1,14 +0,0 @@ -// ISSUE: KT-58933 -// FILE: J.java -public interface J { - void simple(T t); - void box(Box box); -} - -// FILE: test.kt -class Box - -class K : J { - override fun simple(t: T & Any) {} - override fun box(box: Box) {} -} diff --git a/compiler/testData/diagnostics/tests/override/dnnOverridesFlexible.kt b/compiler/testData/diagnostics/tests/override/dnnOverridesFlexible.kt index 0e980384e99..8f7bc5e090d 100644 --- a/compiler/testData/diagnostics/tests/override/dnnOverridesFlexible.kt +++ b/compiler/testData/diagnostics/tests/override/dnnOverridesFlexible.kt @@ -1,3 +1,4 @@ +// FIR_IDENTICAL // ISSUE: KT-58933 // FILE: J.java public interface J { diff --git a/compiler/testData/diagnostics/tests/platformTypes/methodCall/singleton.fir.kt b/compiler/testData/diagnostics/tests/platformTypes/methodCall/singleton.fir.kt index 6c1b45fc4f2..85eb208f325 100644 --- a/compiler/testData/diagnostics/tests/platformTypes/methodCall/singleton.fir.kt +++ b/compiler/testData/diagnostics/tests/platformTypes/methodCall/singleton.fir.kt @@ -4,6 +4,6 @@ interface Foo fun test() { var nullable: Foo? = null - val foo: Collection = java.util.Collections.singleton(nullable) + val foo: Collection = java.util.Collections.singleton(nullable) val foo1: Collection = java.util.Collections.singleton(nullable!!) } diff --git a/compiler/testData/diagnostics/tests/samConversions/samConversionToGenericWrongNullability.fir.kt b/compiler/testData/diagnostics/tests/samConversions/samConversionToGenericWrongNullability.fir.kt deleted file mode 100644 index 93712887d0b..00000000000 --- a/compiler/testData/diagnostics/tests/samConversions/samConversionToGenericWrongNullability.fir.kt +++ /dev/null @@ -1,13 +0,0 @@ -// ISSUE: KT-57014 -// FULL_JDK -// JVM_TARGET: 1.8 - -import java.util.function.Supplier - -fun main() { - val sam = Supplier { - foo() - } -} - -fun foo(): String? = null diff --git a/compiler/testData/diagnostics/tests/samConversions/samConversionToGenericWrongNullability.kt b/compiler/testData/diagnostics/tests/samConversions/samConversionToGenericWrongNullability.kt index 57d5c5980a6..009476bcf7c 100644 --- a/compiler/testData/diagnostics/tests/samConversions/samConversionToGenericWrongNullability.kt +++ b/compiler/testData/diagnostics/tests/samConversions/samConversionToGenericWrongNullability.kt @@ -1,3 +1,4 @@ +// FIR_IDENTICAL // ISSUE: KT-57014 // FULL_JDK // JVM_TARGET: 1.8 diff --git a/compiler/testData/diagnostics/testsWithStdLib/resolve/ambiguousTypeReferences/qualifierForStaticCase.fir.txt b/compiler/testData/diagnostics/testsWithStdLib/resolve/ambiguousTypeReferences/qualifierForStaticCase.fir.txt index 118b2f37fbf..e41f0b347de 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/resolve/ambiguousTypeReferences/qualifierForStaticCase.fir.txt +++ b/compiler/testData/diagnostics/testsWithStdLib/resolve/ambiguousTypeReferences/qualifierForStaticCase.fir.txt @@ -37,7 +37,7 @@ FILE: test2.kt } FILE: test3.kt public final fun test3(): R|ft, kotlin/collections/Map?>| { - ^test3 Q|java/util/Map|.R|java/util/Map.of*s|() + ^test3 Q|java/util/Map|.R|java/util/Map.of*s|() } FILE: test4.kt public final fun test4(): R|kotlin/Int| { diff --git a/compiler/testData/ir/irText/expressions/constructorWithOwnTypeParametersCall.fir.ir.txt b/compiler/testData/ir/irText/expressions/constructorWithOwnTypeParametersCall.fir.ir.txt index 2e0e7a90ca4..2ad89ee285c 100644 --- a/compiler/testData/ir/irText/expressions/constructorWithOwnTypeParametersCall.fir.ir.txt +++ b/compiler/testData/ir/irText/expressions/constructorWithOwnTypeParametersCall.fir.ir.txt @@ -40,15 +40,15 @@ FILE fqName: fileName:/constructorWithOwnTypeParametersCall.kt overridden: public open fun toString (): kotlin.String declared in kotlin.Any $this: VALUE_PARAMETER name: type:kotlin.Any - FUN name:testJava visibility:public modality:FINAL <> () returnType:.J1.J2 + FUN name:testJava visibility:public modality:FINAL <> () returnType:.J1.J2<@[FlexibleNullability] kotlin.Double?, @[FlexibleNullability] kotlin.Int?> BLOCK_BODY - RETURN type=kotlin.Nothing from='public final fun testJava (): .J1.J2 declared in ' - CONSTRUCTOR_CALL 'public constructor () declared in .J1.J2' type=.J1.J2 origin=null - : kotlin.Double - : kotlin.CharSequence - $outer: CONSTRUCTOR_CALL 'public constructor () declared in .J1' type=.J1 origin=null - : kotlin.Int - : kotlin.String + RETURN type=kotlin.Nothing from='public final fun testJava (): .J1.J2<@[FlexibleNullability] kotlin.Double?, @[FlexibleNullability] kotlin.Int?> declared in ' + CONSTRUCTOR_CALL 'public constructor () declared in .J1.J2' type=.J1.J2<@[FlexibleNullability] kotlin.Double?, @[FlexibleNullability] kotlin.Int?> origin=null + : @[FlexibleNullability] kotlin.Double? + : @[FlexibleNullability] kotlin.CharSequence? + $outer: CONSTRUCTOR_CALL 'public constructor () declared in .J1' type=.J1<@[FlexibleNullability] kotlin.Int?> origin=null + : @[FlexibleNullability] kotlin.Int? + : @[FlexibleNullability] kotlin.String? FUN name:testKotlin visibility:public modality:FINAL <> () returnType:.K1.K2 BLOCK_BODY RETURN type=kotlin.Nothing from='public final fun testKotlin (): .K1.K2 declared in ' diff --git a/compiler/testData/ir/irText/expressions/constructorWithOwnTypeParametersCall.fir.kt.txt b/compiler/testData/ir/irText/expressions/constructorWithOwnTypeParametersCall.fir.kt.txt index b411c716cc5..36e1cc5bbd2 100644 --- a/compiler/testData/ir/irText/expressions/constructorWithOwnTypeParametersCall.fir.kt.txt +++ b/compiler/testData/ir/irText/expressions/constructorWithOwnTypeParametersCall.fir.kt.txt @@ -16,11 +16,10 @@ class K1 { } -fun testJava(): J2 { - return J1().J2() +fun testJava(): J2<@FlexibleNullability Double?, @FlexibleNullability Int?> { + return J1<@FlexibleNullability Int?, @FlexibleNullability String?>().J2<@FlexibleNullability Double?, @FlexibleNullability CharSequence?>() } fun testKotlin(): K2 { return K1().K2() } - diff --git a/compiler/testData/ir/irText/expressions/sam/samConversionToGeneric.fir.ir.txt b/compiler/testData/ir/irText/expressions/sam/samConversionToGeneric.fir.ir.txt index a0724f2867f..a63757f9beb 100644 --- a/compiler/testData/ir/irText/expressions/sam/samConversionToGeneric.fir.ir.txt +++ b/compiler/testData/ir/irText/expressions/sam/samConversionToGeneric.fir.ir.txt @@ -1,8 +1,8 @@ FILE fqName: fileName:/samConversionToGeneric.kt - FUN name:test1 visibility:public modality:FINAL <> () returnType:.J + FUN name:test1 visibility:public modality:FINAL <> () returnType:.J<@[FlexibleNullability] kotlin.String?> BLOCK_BODY - RETURN type=kotlin.Nothing from='public final fun test1 (): .J declared in ' - TYPE_OP type=.J origin=SAM_CONVERSION typeOperand=.J + RETURN type=kotlin.Nothing from='public final fun test1 (): .J<@[FlexibleNullability] kotlin.String?> declared in ' + TYPE_OP type=.J<@[FlexibleNullability] kotlin.String?> origin=SAM_CONVERSION typeOperand=.J<@[FlexibleNullability] kotlin.String?> FUN_EXPR type=kotlin.Function1<@[FlexibleNullability] kotlin.String?, @[FlexibleNullability] kotlin.String?> origin=LAMBDA FUN LOCAL_FUNCTION_FOR_LAMBDA name: visibility:local modality:FINAL <> (x:@[FlexibleNullability] kotlin.String?) returnType:@[FlexibleNullability] kotlin.String? VALUE_PARAMETER name:x index:0 type:@[FlexibleNullability] kotlin.String? diff --git a/compiler/testData/ir/irText/expressions/sam/samConversionToGeneric.fir.kt.txt b/compiler/testData/ir/irText/expressions/sam/samConversionToGeneric.fir.kt.txt index 00efc9b0e1c..2d11ecf271f 100644 --- a/compiler/testData/ir/irText/expressions/sam/samConversionToGeneric.fir.kt.txt +++ b/compiler/testData/ir/irText/expressions/sam/samConversionToGeneric.fir.kt.txt @@ -1,8 +1,8 @@ -fun test1(): J { +fun test1(): J<@FlexibleNullability String?> { return local fun (x: @FlexibleNullability String?): @FlexibleNullability String? { return x } - /*-> J */ + /*-> J<@FlexibleNullability String?> */ } fun test10(fn: Function1) { @@ -49,4 +49,3 @@ fun test8(efn: @ExtensionFunctionType Function1): J<@FlexibleNul fun test9(efn: @ExtensionFunctionType Function1) { bar<@FlexibleNullability String?>(j = efn /*-> J<@FlexibleNullability String?> */) } - diff --git a/compiler/testData/ir/irText/firProblems/AllCandidates.fir.ir.txt b/compiler/testData/ir/irText/firProblems/AllCandidates.fir.ir.txt index cd4de3efc78..c1a74a31626 100644 --- a/compiler/testData/ir/irText/firProblems/AllCandidates.fir.ir.txt +++ b/compiler/testData/ir/irText/firProblems/AllCandidates.fir.ir.txt @@ -58,7 +58,7 @@ FILE fqName: fileName:/AllCandidates.kt CALL 'public final fun apply (block: @[ExtensionFunctionType] kotlin.Function1): T of kotlin.apply declared in kotlin' type=@[FlexibleNullability] .OverloadResolutionResultsImpl<@[FlexibleNullability] A of .allCandidatesResult?>? origin=null : @[FlexibleNullability] .OverloadResolutionResultsImpl<@[FlexibleNullability] A of .allCandidatesResult?>? $receiver: CALL 'public open fun nameNotFound (): @[FlexibleNullability] .OverloadResolutionResultsImpl<@[FlexibleNullability] R of .OverloadResolutionResultsImpl.nameNotFound?>? declared in .OverloadResolutionResultsImpl' type=@[FlexibleNullability] .OverloadResolutionResultsImpl<@[FlexibleNullability] A of .allCandidatesResult?>? origin=null - : A of .allCandidatesResult + : @[FlexibleNullability] A of .allCandidatesResult? block: FUN_EXPR type=@[ExtensionFunctionType] kotlin.Function1<@[FlexibleNullability] .OverloadResolutionResultsImpl<@[FlexibleNullability] A of .allCandidatesResult?>?, kotlin.Unit> origin=LAMBDA FUN LOCAL_FUNCTION_FOR_LAMBDA name: visibility:local modality:FINAL <> ($receiver:@[FlexibleNullability] .OverloadResolutionResultsImpl<@[FlexibleNullability] A of .allCandidatesResult?>?) returnType:kotlin.Unit $receiver: VALUE_PARAMETER name:$this$apply type:@[FlexibleNullability] .OverloadResolutionResultsImpl<@[FlexibleNullability] A of .allCandidatesResult?>? diff --git a/compiler/testData/ir/irText/firProblems/AllCandidates.fir.kt.txt b/compiler/testData/ir/irText/firProblems/AllCandidates.fir.kt.txt index b07bf26f5d7..bc6eac029a4 100644 --- a/compiler/testData/ir/irText/firProblems/AllCandidates.fir.kt.txt +++ b/compiler/testData/ir/irText/firProblems/AllCandidates.fir.kt.txt @@ -21,7 +21,7 @@ class ResolvedCall { } private fun allCandidatesResult(allCandidates: Collection): @FlexibleNullability OverloadResolutionResultsImpl<@FlexibleNullability A?>? { - return nameNotFound().apply<@FlexibleNullability OverloadResolutionResultsImpl<@FlexibleNullability A?>?>(block = local fun @FlexibleNullability OverloadResolutionResultsImpl<@FlexibleNullability A?>?.() { + return nameNotFound<@FlexibleNullability A?>().apply<@FlexibleNullability OverloadResolutionResultsImpl<@FlexibleNullability A?>?>(block = local fun @FlexibleNullability OverloadResolutionResultsImpl<@FlexibleNullability A?>?.() { $this$apply.setAllCandidates(allCandidates = allCandidates.map>(transform = local fun (it: MyCandidate): ResolvedCall { return it.() as ResolvedCall } diff --git a/compiler/testData/ir/irText/stubs/javaConstructorWithTypeParameters.fir.ir.txt b/compiler/testData/ir/irText/stubs/javaConstructorWithTypeParameters.fir.ir.txt index fa19919e67b..ac75c666454 100644 --- a/compiler/testData/ir/irText/stubs/javaConstructorWithTypeParameters.fir.ir.txt +++ b/compiler/testData/ir/irText/stubs/javaConstructorWithTypeParameters.fir.ir.txt @@ -1,29 +1,29 @@ FILE fqName: fileName:/javaConstructorWithTypeParameters.kt - FUN name:test1 visibility:public modality:FINAL <> () returnType:.J1 + FUN name:test1 visibility:public modality:FINAL <> () returnType:.J1<@[FlexibleNullability] kotlin.Int?> BLOCK_BODY - RETURN type=kotlin.Nothing from='public final fun test1 (): .J1 declared in ' - CONSTRUCTOR_CALL 'public constructor () declared in .J1' type=.J1 origin=null - : kotlin.Int - FUN name:test2 visibility:public modality:FINAL <> () returnType:.J1 + RETURN type=kotlin.Nothing from='public final fun test1 (): .J1<@[FlexibleNullability] kotlin.Int?> declared in ' + CONSTRUCTOR_CALL 'public constructor () declared in .J1' type=.J1<@[FlexibleNullability] kotlin.Int?> origin=null + : @[FlexibleNullability] kotlin.Int? + FUN name:test2 visibility:public modality:FINAL <> () returnType:.J1<@[FlexibleNullability] kotlin.Int?> BLOCK_BODY - RETURN type=kotlin.Nothing from='public final fun test2 (): .J1 declared in ' - CONSTRUCTOR_CALL 'public constructor (x1: @[FlexibleNullability] X1 of .J1.?) declared in .J1' type=.J1 origin=null - : kotlin.Int - : kotlin.Int + RETURN type=kotlin.Nothing from='public final fun test2 (): .J1<@[FlexibleNullability] kotlin.Int?> declared in ' + CONSTRUCTOR_CALL 'public constructor (x1: @[FlexibleNullability] X1 of .J1.?) declared in .J1' type=.J1<@[FlexibleNullability] kotlin.Int?> origin=null + : @[FlexibleNullability] kotlin.Int? + : @[FlexibleNullability] kotlin.Int? x1: CONST Int type=kotlin.Int value=1 - FUN name:test3 visibility:public modality:FINAL <> (j1:.J1) returnType:.J1.J2 + FUN name:test3 visibility:public modality:FINAL <> (j1:.J1) returnType:.J1.J2<@[FlexibleNullability] kotlin.Int?, kotlin.Any> VALUE_PARAMETER name:j1 index:0 type:.J1 BLOCK_BODY - RETURN type=kotlin.Nothing from='public final fun test3 (j1: .J1): .J1.J2 declared in ' - CONSTRUCTOR_CALL 'public constructor () declared in .J1.J2' type=.J1.J2 origin=null - : kotlin.Int + RETURN type=kotlin.Nothing from='public final fun test3 (j1: .J1): .J1.J2<@[FlexibleNullability] kotlin.Int?, kotlin.Any> declared in ' + CONSTRUCTOR_CALL 'public constructor () declared in .J1.J2' type=.J1.J2<@[FlexibleNullability] kotlin.Int?, kotlin.Any> origin=null + : @[FlexibleNullability] kotlin.Int? $outer: GET_VAR 'j1: .J1 declared in .test3' type=.J1 origin=null - FUN name:test4 visibility:public modality:FINAL <> (j1:.J1) returnType:.J1.J2 + FUN name:test4 visibility:public modality:FINAL <> (j1:.J1) returnType:.J1.J2<@[FlexibleNullability] kotlin.Int?, kotlin.Any> VALUE_PARAMETER name:j1 index:0 type:.J1 BLOCK_BODY - RETURN type=kotlin.Nothing from='public final fun test4 (j1: .J1): .J1.J2 declared in ' - CONSTRUCTOR_CALL 'public constructor (x2: @[FlexibleNullability] X2 of .J1.J2.?) declared in .J1.J2' type=.J1.J2 origin=null - : kotlin.Int - : kotlin.Int + RETURN type=kotlin.Nothing from='public final fun test4 (j1: .J1): .J1.J2<@[FlexibleNullability] kotlin.Int?, kotlin.Any> declared in ' + CONSTRUCTOR_CALL 'public constructor (x2: @[FlexibleNullability] X2 of .J1.J2.?) declared in .J1.J2' type=.J1.J2<@[FlexibleNullability] kotlin.Int?, kotlin.Any> origin=null + : @[FlexibleNullability] kotlin.Int? + : @[FlexibleNullability] kotlin.Int? $outer: GET_VAR 'j1: .J1 declared in .test4' type=.J1 origin=null x2: CONST Int type=kotlin.Int value=1 diff --git a/compiler/testData/ir/irText/stubs/javaConstructorWithTypeParameters.fir.kt.txt b/compiler/testData/ir/irText/stubs/javaConstructorWithTypeParameters.fir.kt.txt index 8d3a59334f3..d932d1df450 100644 --- a/compiler/testData/ir/irText/stubs/javaConstructorWithTypeParameters.fir.kt.txt +++ b/compiler/testData/ir/irText/stubs/javaConstructorWithTypeParameters.fir.kt.txt @@ -1,15 +1,15 @@ -fun test1(): J1 { - return J1() +fun test1(): J1<@FlexibleNullability Int?> { + return J1<@FlexibleNullability Int?>() } -fun test2(): J1 { - return J1(x1 = 1) +fun test2(): J1<@FlexibleNullability Int?> { + return J1<@FlexibleNullability Int?, @FlexibleNullability Int?>(x1 = 1) } -fun test3(j1: J1): J2 { - return j1.J2() +fun test3(j1: J1): J2<@FlexibleNullability Int?, Any> { + return j1.J2<@FlexibleNullability Int?>() } -fun test4(j1: J1): J2 { - return j1.J2(x2 = 1) +fun test4(j1: J1): J2<@FlexibleNullability Int?, Any> { + return j1.J2<@FlexibleNullability Int?, @FlexibleNullability Int?>(x2 = 1) } diff --git a/compiler/testData/loadJava/compiledJava/ClassWithTypePExtendsIterableP.fir.txt b/compiler/testData/loadJava/compiledJava/ClassWithTypePExtendsIterableP.fir.txt index 9c9ce025b3c..31035d00834 100644 --- a/compiler/testData/loadJava/compiledJava/ClassWithTypePExtendsIterableP.fir.txt +++ b/compiler/testData/loadJava/compiledJava/ClassWithTypePExtendsIterableP.fir.txt @@ -1,4 +1,4 @@ -public abstract class ClassWithTypePExtendsIterableP

: R|kotlin/Any|, R|kotlin/collections/MutableIterable>| { +public abstract class ClassWithTypePExtendsIterableP

: R|kotlin/Any|, R|kotlin/collections/MutableIterable| { public constructor

(): R|test/ClassWithTypePExtendsIterableP

| } diff --git a/compiler/testData/loadJava/compiledJava/ClassWithTypePP.fir.txt b/compiler/testData/loadJava/compiledJava/ClassWithTypePP.fir.txt index dc773c22017..2447865f733 100644 --- a/compiler/testData/loadJava/compiledJava/ClassWithTypePP.fir.txt +++ b/compiler/testData/loadJava/compiledJava/ClassWithTypePP.fir.txt @@ -1,4 +1,4 @@ -public final class ClassWithTypePP

|> : R|kotlin/Any| { - public constructor

|>(): R|test/ClassWithTypePP| +public final class ClassWithTypePP

: R|kotlin/Any| { + public constructor

(): R|test/ClassWithTypePP| } diff --git a/compiler/testData/loadJava/compiledJava/ClassWithTypePRefNext.fir.txt b/compiler/testData/loadJava/compiledJava/ClassWithTypePRefNext.fir.txt index 3d44aeb3776..ff34502d2fb 100644 --- a/compiler/testData/loadJava/compiledJava/ClassWithTypePRefNext.fir.txt +++ b/compiler/testData/loadJava/compiledJava/ClassWithTypePRefNext.fir.txt @@ -1,4 +1,4 @@ -public open class ClassWithTypePRefNext>, kotlin/collections/Iterable>?>|, P : R|kotlin/Any!|> : R|kotlin/Any| { - public constructor>, kotlin/collections/Iterable>?>|, P : R|kotlin/Any!|>(): R|test/ClassWithTypePRefNext| +public open class ClassWithTypePRefNext, kotlin/collections/Iterable?>|, P : R|kotlin/Any!|> : R|kotlin/Any| { + public constructor, kotlin/collections/Iterable?>|, P : R|kotlin/Any!|>(): R|test/ClassWithTypePRefNext| } diff --git a/compiler/testData/loadJava/compiledJava/ClassWithTypePRefSelf.fir.txt b/compiler/testData/loadJava/compiledJava/ClassWithTypePRefSelf.fir.txt index 671a2f24b6e..840e5cfc5c2 100644 --- a/compiler/testData/loadJava/compiledJava/ClassWithTypePRefSelf.fir.txt +++ b/compiler/testData/loadJava/compiledJava/ClassWithTypePRefSelf.fir.txt @@ -1,4 +1,4 @@ -public final class ClassWithTypePRefSelf

>, kotlin/Enum>?>|> : R|kotlin/Any| { - public constructor

>, kotlin/Enum>?>|>(): R|test/ClassWithTypePRefSelf

| +public final class ClassWithTypePRefSelf

, kotlin/Enum?>|> : R|kotlin/Any| { + public constructor

, kotlin/Enum?>|>(): R|test/ClassWithTypePRefSelf

| } diff --git a/compiler/testData/loadJava/compiledJava/ClassWithTypePRefSelfAndClass.fir.txt b/compiler/testData/loadJava/compiledJava/ClassWithTypePRefSelfAndClass.fir.txt index 58e99fdbfc9..1b2d9be7864 100644 --- a/compiler/testData/loadJava/compiledJava/ClassWithTypePRefSelfAndClass.fir.txt +++ b/compiler/testData/loadJava/compiledJava/ClassWithTypePRefSelfAndClass.fir.txt @@ -1,4 +1,4 @@ -public final class ClassWithTypePRefSelfAndClass

>, test/ClassWithTypePRefSelfAndClass>?>|> : R|kotlin/Any| { - public constructor

>, test/ClassWithTypePRefSelfAndClass>?>|>(): R|test/ClassWithTypePRefSelfAndClass

| +public final class ClassWithTypePRefSelfAndClass

, test/ClassWithTypePRefSelfAndClass?>|> : R|kotlin/Any| { + public constructor

, test/ClassWithTypePRefSelfAndClass?>|>(): R|test/ClassWithTypePRefSelfAndClass

| } diff --git a/compiler/testData/loadJava/compiledJava/InheritMethodsDifferentReturnTypesGeneric.fir.txt b/compiler/testData/loadJava/compiledJava/InheritMethodsDifferentReturnTypesGeneric.fir.txt index a08bfccbd96..4b093c83f1a 100644 --- a/compiler/testData/loadJava/compiledJava/InheritMethodsDifferentReturnTypesGeneric.fir.txt +++ b/compiler/testData/loadJava/compiledJava/InheritMethodsDifferentReturnTypesGeneric.fir.txt @@ -4,15 +4,15 @@ public final class InheritMethodsDifferentReturnTypesGeneric : R|kotlin/Any| { public abstract interface Sub : R|test/InheritMethodsDifferentReturnTypesGeneric.Super1|, R|test/InheritMethodsDifferentReturnTypesGeneric.Super2| { } public abstract interface Super1 : R|kotlin/Any| { - public abstract fun foo(): R|ft| + public abstract fun foo(): R|F!| - public abstract fun bar(): R|ft| + public abstract fun bar(): R|B!| } public abstract interface Super2 : R|kotlin/Any| { - public abstract fun foo(): R|ft| + public abstract fun foo(): R|FF!| - public abstract fun bar(): R|ft| + public abstract fun bar(): R|BB!| } } diff --git a/compiler/testData/loadJava/compiledJava/InnerClassReferencesOuterTP.fir.txt b/compiler/testData/loadJava/compiledJava/InnerClassReferencesOuterTP.fir.txt index 4d41a38b228..9a3035bed10 100644 --- a/compiler/testData/loadJava/compiledJava/InnerClassReferencesOuterTP.fir.txt +++ b/compiler/testData/loadJava/compiledJava/InnerClassReferencesOuterTP.fir.txt @@ -1,8 +1,8 @@ public open class InnerClassReferencesOuterTP

: R|kotlin/Any| { public constructor

(): R|test/InnerClassReferencesOuterTP

| - public open inner class Inner|, Outer(P) : R|kotlin/Any!|> : R|kotlin/Any| { - public test/InnerClassReferencesOuterTP

.constructor|>(): R|test/InnerClassReferencesOuterTP.Inner| + public open inner class Inner : R|kotlin/Any| { + public test/InnerClassReferencesOuterTP

.constructor(): R|test/InnerClassReferencesOuterTP.Inner| } } diff --git a/compiler/testData/loadJava/compiledJava/InnerClassTypeMultipleGeneric.fir.txt b/compiler/testData/loadJava/compiledJava/InnerClassTypeMultipleGeneric.fir.txt index 5ae3060dbe0..8c77f61dcca 100644 --- a/compiler/testData/loadJava/compiledJava/InnerClassTypeMultipleGeneric.fir.txt +++ b/compiler/testData/loadJava/compiledJava/InnerClassTypeMultipleGeneric.fir.txt @@ -11,12 +11,12 @@ public open class InnerClassTypeMultipleGeneric : R|kotlin/Any| { } } - public open inner class Outer : R|test/InnerClassTypeMultipleGeneric.BaseOuter>| { - public open fun bar(): R|ft, java/lang/Class<*>?>, kotlin/CharSequence!, kotlin/Int!, ft>, test/InnerClassTypeMultipleGeneric.BaseOuter.BaseInner, java/lang/Class<*>?>, kotlin/CharSequence!, kotlin/Int!, ft>?>| + public open inner class Outer : R|test/InnerClassTypeMultipleGeneric.BaseOuter| { + public open fun bar(): R|ft, java/lang/Class<*>?>, kotlin/CharSequence!, kotlin/Int!, E1!>, test/InnerClassTypeMultipleGeneric.BaseOuter.BaseInner, java/lang/Class<*>?>, kotlin/CharSequence!, kotlin/Int!, E1!>?>| public test/InnerClassTypeMultipleGeneric.constructor(): R|test/InnerClassTypeMultipleGeneric.Outer| - public open inner class Inner : R|test/InnerClassTypeMultipleGeneric.BaseOuter.BaseInner, ft>| { + public open inner class Inner : R|test/InnerClassTypeMultipleGeneric.BaseOuter.BaseInner| { public test/InnerClassTypeMultipleGeneric.Outer.constructor(): R|test/InnerClassTypeMultipleGeneric.Outer.Inner| } diff --git a/compiler/testData/loadJava/compiledJava/InnerClassesInGeneric.fir.txt b/compiler/testData/loadJava/compiledJava/InnerClassesInGeneric.fir.txt index f277fb17f3f..bdfaff26aea 100644 --- a/compiler/testData/loadJava/compiledJava/InnerClassesInGeneric.fir.txt +++ b/compiler/testData/loadJava/compiledJava/InnerClassesInGeneric.fir.txt @@ -5,8 +5,8 @@ public open class InnerClassesInGeneric

public test/InnerClassesInGeneric.constructor(): R|test/InnerClassesInGeneric.Inner| } - public open inner class Inner2 : R|test/InnerClassesInGeneric.Inner, ft>| { - public open operator fun iterator(): R|ft>, kotlin/collections/Iterator>?>| + public open inner class Inner2 : R|test/InnerClassesInGeneric.Inner| { + public open operator fun iterator(): R|ft, kotlin/collections/Iterator?>| public test/InnerClassesInGeneric.constructor(): R|test/InnerClassesInGeneric.Inner2| diff --git a/compiler/testData/loadJava/compiledJava/InnerOfGeneric.fir.txt b/compiler/testData/loadJava/compiledJava/InnerOfGeneric.fir.txt index 41e41ad4e9e..13d5a43189f 100644 --- a/compiler/testData/loadJava/compiledJava/InnerOfGeneric.fir.txt +++ b/compiler/testData/loadJava/compiledJava/InnerOfGeneric.fir.txt @@ -4,23 +4,23 @@ public open class InnerOfGeneric : R|kotlin/Any| { public abstract inner class A : R|kotlin/Any| { public test/InnerOfGeneric.constructor(): R|test/InnerOfGeneric.A| - public abstract inner class Inner : R|test/InnerOfGeneric.S>| { + public abstract inner class Inner : R|test/InnerOfGeneric.S| { public test/InnerOfGeneric.A.constructor(): R|test/InnerOfGeneric.A.Inner| } } - public open inner class B : R|test/InnerOfGeneric.A>| { + public open inner class B : R|test/InnerOfGeneric.A| { public test/InnerOfGeneric.constructor(): R|test/InnerOfGeneric.B| - public open inner class SubInner : R|test/InnerOfGeneric.A.Inner>| { - @R|java/lang/Override|() public open operator fun iterator(): R|ft>, kotlin/collections/Iterator>?>| + public open inner class SubInner : R|test/InnerOfGeneric.A.Inner| { + @R|java/lang/Override|() public open operator fun iterator(): R|ft, kotlin/collections/Iterator?>| public test/InnerOfGeneric.B.constructor(): R|test/InnerOfGeneric.B.SubInner| } } public open inner class S : R|kotlin/Any| { - public open operator fun iterator(): R|ft>, kotlin/collections/Iterator>?>| + public open operator fun iterator(): R|ft, kotlin/collections/Iterator?>| public test/InnerOfGeneric.constructor(): R|test/InnerOfGeneric.S| diff --git a/compiler/testData/loadJava/compiledJava/MethodReferencesOuterClassTP.fir.txt b/compiler/testData/loadJava/compiledJava/MethodReferencesOuterClassTP.fir.txt index ced6ac2fdd1..240b76ff80a 100644 --- a/compiler/testData/loadJava/compiledJava/MethodReferencesOuterClassTP.fir.txt +++ b/compiler/testData/loadJava/compiledJava/MethodReferencesOuterClassTP.fir.txt @@ -2,7 +2,7 @@ public final class MethodReferencesOuterClassTP

: R|kotlin/A public constructor

(): R|test/MethodReferencesOuterClassTP

| public final inner class Inner : R|kotlin/Any| { - public final fun |> f(): R|kotlin/Unit| + public final fun f(): R|kotlin/Unit| public test/MethodReferencesOuterClassTP

.constructor(): R|test/MethodReferencesOuterClassTP.Inner

| diff --git a/compiler/testData/loadJava/compiledJava/MethodWithTypePP.fir.txt b/compiler/testData/loadJava/compiledJava/MethodWithTypePP.fir.txt index dc1522ddbf4..dcfb50b230a 100644 --- a/compiler/testData/loadJava/compiledJava/MethodWithTypePP.fir.txt +++ b/compiler/testData/loadJava/compiledJava/MethodWithTypePP.fir.txt @@ -1,5 +1,5 @@ public final class MethodWithTypePP : R|kotlin/Any| { - public final fun

|> f(): R|kotlin/Unit| + public final fun

f(): R|kotlin/Unit| public constructor(): R|test/MethodWithTypePP| diff --git a/compiler/testData/loadJava/compiledJava/MethodWithTypePRefClassP.fir.txt b/compiler/testData/loadJava/compiledJava/MethodWithTypePRefClassP.fir.txt index 6b194aa5779..10859bd05f1 100644 --- a/compiler/testData/loadJava/compiledJava/MethodWithTypePRefClassP.fir.txt +++ b/compiler/testData/loadJava/compiledJava/MethodWithTypePRefClassP.fir.txt @@ -1,5 +1,5 @@ public open class MethodWithTypePRefClassP

: R|kotlin/Any| { - public final fun |> f(): R|kotlin/Unit| + public final fun f(): R|kotlin/Unit| public constructor

(): R|test/MethodWithTypePRefClassP

| diff --git a/compiler/testData/loadJava/compiledJava/MethosWithPRefTP.fir.txt b/compiler/testData/loadJava/compiledJava/MethosWithPRefTP.fir.txt index 78467642eea..fa39fc806ac 100644 --- a/compiler/testData/loadJava/compiledJava/MethosWithPRefTP.fir.txt +++ b/compiler/testData/loadJava/compiledJava/MethosWithPRefTP.fir.txt @@ -1,5 +1,5 @@ public final class MethosWithPRefTP : R|kotlin/Any| { - public final fun

f(p: R|ft

|): R|kotlin/Unit| + public final fun

f(p: R|P!|): R|kotlin/Unit| public constructor(): R|test/MethosWithPRefTP| diff --git a/compiler/testData/loadJava/compiledJava/RawOverrides.fir.txt b/compiler/testData/loadJava/compiledJava/RawOverrides.fir.txt index 896aa8a303e..742abd19021 100644 --- a/compiler/testData/loadJava/compiledJava/RawOverrides.fir.txt +++ b/compiler/testData/loadJava/compiledJava/RawOverrides.fir.txt @@ -2,7 +2,7 @@ public open class RawOverrides : R|kotlin/Any| { public constructor(): R|test/RawOverrides| public abstract interface A : R|kotlin/Any| { - public abstract fun foo(x: R|ft|, y: R|ft>, kotlin/collections/List>?>|): R|ft| + public abstract fun foo(x: R|T!|, y: R|ft, kotlin/collections/List?>|): R|E!| } public open inner class B : R|kotlin/Any|, R|Raw type test/RawOverrides.A| { @@ -12,7 +12,7 @@ public open class RawOverrides : R|kotlin/Any| { } public open inner class C : R|kotlin/Any| { - public/*package*/ open fun |> bar(x: R|ft|, y: R|ft, ft>, kotlin/collections/Map, ft>?>>, kotlin/collections/List, ft>, kotlin/collections/Map, ft>?>>?>|): R|ft| + public/*package*/ open fun bar(x: R|F!|, y: R|ft, kotlin/collections/Map?>>, kotlin/collections/List, kotlin/collections/Map?>>?>|): R|E!| public test/RawOverrides.constructor(): R|test/RawOverrides.C| @@ -20,7 +20,7 @@ public open class RawOverrides : R|kotlin/Any| { public open inner class D : R|test/RawOverrides.C| { @R|java/lang/Override|() public open fun bar(x: R|kotlin/CharSequence!|, y: R|ft, kotlin/collections/List<*>?>|): R|kotlin/String!| - public/*package*/ open fun |> bar(x: R|ft|, y: R|ft, ft>, kotlin/collections/Map, ft>?>>, kotlin/collections/List, ft>, kotlin/collections/Map, ft>?>>?>|): R|ft| + public/*package*/ open fun bar(x: R|F!|, y: R|ft, kotlin/collections/Map?>>, kotlin/collections/List, kotlin/collections/Map?>>?>|): R|E!| public test/RawOverrides.constructor(): R|test/RawOverrides.D| diff --git a/compiler/testData/loadJava/compiledJava/ReferenceCycleThroughAnnotation.fir.txt b/compiler/testData/loadJava/compiledJava/ReferenceCycleThroughAnnotation.fir.txt index fd3ef291cf3..3dfb7e2a377 100644 --- a/compiler/testData/loadJava/compiledJava/ReferenceCycleThroughAnnotation.fir.txt +++ b/compiler/testData/loadJava/compiledJava/ReferenceCycleThroughAnnotation.fir.txt @@ -7,8 +7,8 @@ public open class ReferenceCycleThroughAnnotation : R|kotlin/Any| { public test/ReferenceCycleThroughAnnotation.constructor(): R|test/ReferenceCycleThroughAnnotation.A| } - public open inner class B>, test/ReferenceCycleThroughAnnotation.A>?>|> : R|kotlin/Any| { - public test/ReferenceCycleThroughAnnotation.constructor>, test/ReferenceCycleThroughAnnotation.A>?>|>(): R|test/ReferenceCycleThroughAnnotation.B| + public open inner class B, test/ReferenceCycleThroughAnnotation.A?>|> : R|kotlin/Any| { + public test/ReferenceCycleThroughAnnotation.constructor, test/ReferenceCycleThroughAnnotation.A?>|>(): R|test/ReferenceCycleThroughAnnotation.B| } public final annotation class C : R|kotlin/Annotation| { diff --git a/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericDeep.fir.txt b/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericDeep.fir.txt index 590e5f16283..8b4265e465b 100644 --- a/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericDeep.fir.txt +++ b/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericDeep.fir.txt @@ -1,4 +1,4 @@ public open class ConstructorGenericDeep : R|kotlin/Any| { - public constructor

(cl: R|ft>, java/lang/Class>?>|): R|test/ConstructorGenericDeep| + public constructor

(cl: R|ft, java/lang/Class?>|): R|test/ConstructorGenericDeep| } diff --git a/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericSimple.fir.txt b/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericSimple.fir.txt index 3e62258cf2d..30157ed624d 100644 --- a/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericSimple.fir.txt +++ b/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericSimple.fir.txt @@ -1,4 +1,4 @@ public open class ConstructorGenericSimple : R|kotlin/Any| { - public constructor

(p: R|ft

|): R|test/ConstructorGenericSimple| + public constructor

(p: R|P!|): R|test/ConstructorGenericSimple| } diff --git a/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericUpperBound.fir.txt b/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericUpperBound.fir.txt index b6b32231e1d..6baa25f87e3 100644 --- a/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericUpperBound.fir.txt +++ b/compiler/testData/loadJava/compiledJava/constructor/ConstructorGenericUpperBound.fir.txt @@ -1,4 +1,4 @@ public open class ConstructorGenericUpperBound : R|kotlin/Any| { - public constructor

(p: R|ft

|): R|test/ConstructorGenericUpperBound| + public constructor

(p: R|P!|): R|test/ConstructorGenericUpperBound| } diff --git a/compiler/testData/loadJava/compiledJava/javaBean/JavaBeanVarOfGenericType.fir.txt b/compiler/testData/loadJava/compiledJava/javaBean/JavaBeanVarOfGenericType.fir.txt index 2839e81ced7..98aefc59e4e 100644 --- a/compiler/testData/loadJava/compiledJava/javaBean/JavaBeanVarOfGenericType.fir.txt +++ b/compiler/testData/loadJava/compiledJava/javaBean/JavaBeanVarOfGenericType.fir.txt @@ -1,7 +1,7 @@ public open class JavaBeanVarOfGenericType

: R|kotlin/Any| { - public open fun getCharacters(): R|ft>, java/util/ArrayList>?>| + public open fun getCharacters(): R|ft, java/util/ArrayList?>| - public open fun setCharacters(characters: R|ft>, java/util/ArrayList>?>|): R|kotlin/Unit| + public open fun setCharacters(characters: R|ft, java/util/ArrayList?>|): R|kotlin/Unit| public constructor

(): R|test/JavaBeanVarOfGenericType

| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/ConstructorWithNewTypeParams.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/ConstructorWithNewTypeParams.fir.txt index d97040758ce..de648f0e95e 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/ConstructorWithNewTypeParams.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/ConstructorWithNewTypeParams.fir.txt @@ -1,4 +1,4 @@ public open class ConstructorWithNewTypeParams : R|kotlin/Any| { - public constructor(first: R|ft|): R|test/ConstructorWithNewTypeParams| + public constructor(first: R|U!|): R|test/ConstructorWithNewTypeParams| } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/ConstructorWithParentTypeParams.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/ConstructorWithParentTypeParams.fir.txt index 0cc29ba2615..dcb6464b55f 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/ConstructorWithParentTypeParams.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/ConstructorWithParentTypeParams.fir.txt @@ -1,4 +1,4 @@ public open class ConstructorWithParentTypeParams : R|kotlin/Any| { - public constructor(first: R|ft|): R|test/ConstructorWithParentTypeParams| + public constructor(first: R|T!|): R|test/ConstructorWithParentTypeParams| } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/MethodWithMappedClasses.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/MethodWithMappedClasses.fir.txt index 9e9fad820f5..5fbe1de64bf 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/MethodWithMappedClasses.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/MethodWithMappedClasses.fir.txt @@ -1,7 +1,7 @@ public open class MethodWithMappedClasses : R|kotlin/Any| { - public open fun copy(dest: R|ft>, kotlin/collections/MutableList>?>|, src: R|ft>, kotlin/collections/List>?>|): R|kotlin/Unit| + public open fun copy(dest: R|ft, kotlin/collections/MutableList?>|, src: R|ft, kotlin/collections/List?>|): R|kotlin/Unit| - public open fun copyMap(dest: R|ft>, kotlin/collections/MutableMap>?>|, src: R|ft>, kotlin/collections/Map>?>|): R|kotlin/Unit| + public open fun copyMap(dest: R|ft, kotlin/collections/MutableMap?>|, src: R|ft, kotlin/collections/Map?>|): R|kotlin/Unit| public constructor(): R|test/MethodWithMappedClasses| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/MethodWithTypeParameters.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/MethodWithTypeParameters.fir.txt index d1dd15c7ae0..14174a09e94 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/MethodWithTypeParameters.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/MethodWithTypeParameters.fir.txt @@ -1,5 +1,5 @@ public open class MethodWithTypeParameters : R|kotlin/Any| { - public open fun , kotlin/collections/List?>|> foo(a: R|ft|, b: R|ft>, kotlin/collections/List>?>|, list: R|ft, kotlin/collections/MutableList?>|): R|kotlin/Unit| + public open fun , kotlin/collections/List?>|> foo(a: R|A!|, b: R|ft, kotlin/collections/List?>|, list: R|ft, kotlin/collections/MutableList?>|): R|kotlin/Unit| public constructor(): R|test/MethodWithTypeParameters| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/PropertyArrayTypes.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/PropertyArrayTypes.fir.txt index e2c06b2270e..6f6240dd98a 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/PropertyArrayTypes.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/PropertyArrayTypes.fir.txt @@ -3,7 +3,7 @@ public open class PropertyArrayTypes : R|kotlin/Any| { public open field array: R|ft, kotlin/Array?>| - public open field genericArray: R|ft>, kotlin/Array>?>| + public open field genericArray: R|ft, kotlin/Array?>| public constructor(): R|test/PropertyArrayTypes| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/PropertyComplexTypes.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/PropertyComplexTypes.fir.txt index b6be986005d..101656bd5f9 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/PropertyComplexTypes.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/PropertyComplexTypes.fir.txt @@ -1,11 +1,11 @@ public open class PropertyComplexTypes : R|kotlin/Any| { - public open field genericType: R|ft| + public open field genericType: R|T!| public open field listDefinedGeneric: R|ft, java/util/ArrayList?>| - public open field listGeneric: R|ft>, java/util/ArrayList>?>| + public open field listGeneric: R|ft, java/util/ArrayList?>| - public open field listOfGenericList: R|ft>, java/util/ArrayList>?>>, java/util/ArrayList>, java/util/ArrayList>?>>?>| + public open field listOfGenericList: R|ft, java/util/ArrayList?>>, java/util/ArrayList, java/util/ArrayList?>>?>| public constructor(): R|test/PropertyComplexTypes| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/error/WrongTypeParameterBoundStructure1.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/error/WrongTypeParameterBoundStructure1.fir.txt index e47591c4335..8adf3661225 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/error/WrongTypeParameterBoundStructure1.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/error/WrongTypeParameterBoundStructure1.fir.txt @@ -1,5 +1,5 @@ public open class WrongTypeParameterBoundStructure1 : R|kotlin/Any| { - public open fun , kotlin/collections/List?>|> foo(a: R|ft|, b: R|ft>, kotlin/collections/List>?>|): R|kotlin/Unit| + public open fun , kotlin/collections/List?>|> foo(a: R|A!|, b: R|ft, kotlin/collections/List?>|): R|kotlin/Unit| public constructor(): R|test/WrongTypeParameterBoundStructure1| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter.fir.txt index f791c0e5636..b27bd114907 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter.fir.txt @@ -1,6 +1,6 @@ public abstract interface DeeplySubstitutedClassParameter : R|kotlin/Any| { - public abstract interface Middle : R|test/DeeplySubstitutedClassParameter.Super>| { - public abstract fun foo(p: R|ft|): R|kotlin/Unit| + public abstract interface Middle : R|test/DeeplySubstitutedClassParameter.Super| { + public abstract fun foo(p: R|E!|): R|kotlin/Unit| } public abstract interface Sub : R|test/DeeplySubstitutedClassParameter.Middle| { @@ -8,7 +8,7 @@ public abstract interface DeeplySubstitutedClassParameter : R|kotlin/Any| { } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(p: R|ft|): R|kotlin/Unit| + public abstract fun foo(p: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter2.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter2.fir.txt index e7a92063c93..03b597c1c10 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter2.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/DeeplySubstitutedClassParameter2.fir.txt @@ -1,12 +1,12 @@ public abstract interface DeeplySubstitutedClassParameter2 : R|kotlin/Any| { - public abstract interface Middle : R|test/DeeplySubstitutedClassParameter2.Super>| { + public abstract interface Middle : R|test/DeeplySubstitutedClassParameter2.Super| { } public abstract interface Sub : R|test/DeeplySubstitutedClassParameter2.Middle| { public abstract fun foo(p: R|kotlin/String!|): R|kotlin/Unit| } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(p: R|ft|): R|kotlin/Unit| + public abstract fun foo(p: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/Kt3302.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/Kt3302.fir.txt index 5a5729b224a..04baee35cda 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/Kt3302.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/Kt3302.fir.txt @@ -10,7 +10,7 @@ public abstract interface Kt3302 : R|kotlin/Any| { } public abstract interface LinkedHashMap : R|kotlin/Any| { - public abstract fun put(key: R|ft|, value: R|ft|): R|ft| + public abstract fun put(key: R|K!|, value: R|V!|): R|V!| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/OverrideWithErasedParameter.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/OverrideWithErasedParameter.fir.txt index 122863f5c3c..1afe704bbb9 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/OverrideWithErasedParameter.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/OverrideWithErasedParameter.fir.txt @@ -1,10 +1,10 @@ public abstract interface OverrideWithErasedParameter : R|kotlin/Any| { - public abstract interface Sub : R|test/OverrideWithErasedParameter.Super>| { + public abstract interface Sub : R|test/OverrideWithErasedParameter.Super| { public abstract fun foo(o: R|kotlin/Any!|): R|kotlin/Unit| } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(t: R|ft|): R|kotlin/Unit| + public abstract fun foo(t: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubclassFromGenericAndNot.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubclassFromGenericAndNot.fir.txt index 53a939edd82..1fb62a10bb0 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubclassFromGenericAndNot.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubclassFromGenericAndNot.fir.txt @@ -1,6 +1,6 @@ public abstract interface SubclassFromGenericAndNot : R|kotlin/Any| { public abstract interface Generic : R|kotlin/Any| { - public abstract fun foo(key: R|ft|): R|kotlin/Unit| + public abstract fun foo(key: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubstitutedClassParameter.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubstitutedClassParameter.fir.txt index 0e1a6aaefbf..9c0b128634d 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubstitutedClassParameter.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubstitutedClassParameter.fir.txt @@ -4,7 +4,7 @@ public abstract interface SubstitutedClassParameter : R|kotlin/Any| { } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(p: R|ft|): R|kotlin/Unit| + public abstract fun foo(p: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubstitutedClassParameters.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubstitutedClassParameters.fir.txt index b654dc36d6f..523babda252 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubstitutedClassParameters.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/parameter/SubstitutedClassParameters.fir.txt @@ -4,13 +4,13 @@ public abstract interface SubstitutedClassParameters : R|kotlin/Any| { } public abstract interface Super1 : R|kotlin/Any| { - public abstract fun foo(p: R|ft|): R|kotlin/Unit| + public abstract fun foo(p: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| } public abstract interface Super2 : R|kotlin/Any| { - public abstract fun foo(p: R|ft|): R|kotlin/Unit| + public abstract fun foo(p: R|E!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter.fir.txt index 845c0a768c5..451fd81930e 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter.fir.txt @@ -1,6 +1,6 @@ public abstract interface DeeplySubstitutedClassParameter : R|kotlin/Any| { - public abstract interface Middle : R|test/DeeplySubstitutedClassParameter.Super>| { - public abstract fun foo(): R|ft| + public abstract interface Middle : R|test/DeeplySubstitutedClassParameter.Super| { + public abstract fun foo(): R|E!| } public abstract interface Sub : R|test/DeeplySubstitutedClassParameter.Middle| { @@ -8,7 +8,7 @@ public abstract interface DeeplySubstitutedClassParameter : R|kotlin/Any| { } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(): R|ft| + public abstract fun foo(): R|T!| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter2.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter2.fir.txt index c939c4370e9..07c94f68115 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter2.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/DeeplySubstitutedClassParameter2.fir.txt @@ -1,12 +1,12 @@ public abstract interface DeeplySubstitutedClassParameter2 : R|kotlin/Any| { - public abstract interface Middle : R|test/DeeplySubstitutedClassParameter2.Super>| { + public abstract interface Middle : R|test/DeeplySubstitutedClassParameter2.Super| { } public abstract interface Sub : R|test/DeeplySubstitutedClassParameter2.Middle| { public abstract fun foo(): R|kotlin/String!| } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(): R|ft| + public abstract fun foo(): R|T!| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/HalfSubstitutedTypeParameters.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/HalfSubstitutedTypeParameters.fir.txt index 08835e0005d..79a448bc4f9 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/HalfSubstitutedTypeParameters.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/HalfSubstitutedTypeParameters.fir.txt @@ -9,6 +9,6 @@ public abstract interface HalfSubstitutedTypeParameters : R|kotlin/Any| { public abstract fun dummy(): R|kotlin/Unit| } - public abstract interface TrickyList : R|kotlin/collections/MutableList>| { + public abstract interface TrickyList : R|kotlin/collections/MutableList| { } } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassFromGenericAndNot.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassFromGenericAndNot.fir.txt index 71d2b8f67d1..94767dea000 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassFromGenericAndNot.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassFromGenericAndNot.fir.txt @@ -1,6 +1,6 @@ public abstract interface SubclassFromGenericAndNot : R|kotlin/Any| { public abstract interface Generic : R|kotlin/Any| { - public abstract fun foo(): R|ft| + public abstract fun foo(): R|T!| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassOfCollection.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassOfCollection.fir.txt index 44cf73571c4..00354166ebe 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassOfCollection.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassOfCollection.fir.txt @@ -1,4 +1,4 @@ -public abstract interface SubclassOfCollection : R|kotlin/collections/MutableCollection>| { - public abstract operator fun iterator(): R|@EnhancedNullability kotlin/collections/MutableIterator>| +public abstract interface SubclassOfCollection : R|kotlin/collections/MutableCollection| { + public abstract operator fun iterator(): R|@EnhancedNullability kotlin/collections/MutableIterator| } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassOfMapEntry.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassOfMapEntry.fir.txt index 2a506da0e53..814970ed7e7 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassOfMapEntry.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubclassOfMapEntry.fir.txt @@ -1,4 +1,4 @@ -public abstract interface SubclassOfMapEntry : R|kotlin/collections/MutableMap.MutableEntry, ft>| { - public abstract fun setValue(value: R|ft|): R|ft| +public abstract interface SubclassOfMapEntry : R|kotlin/collections/MutableMap.MutableEntry| { + public abstract fun setValue(value: R|V!|): R|V!| } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubstitutedClassParameter.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubstitutedClassParameter.fir.txt index 7fe74ec202f..55352c845ea 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubstitutedClassParameter.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubstitutedClassParameter.fir.txt @@ -4,7 +4,7 @@ public abstract interface SubstitutedClassParameter : R|kotlin/Any| { } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(): R|ft| + public abstract fun foo(): R|T!| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubstitutedClassParameters.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubstitutedClassParameters.fir.txt index fba31e6fdf3..c322252c5c6 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubstitutedClassParameters.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/SubstitutedClassParameters.fir.txt @@ -4,13 +4,13 @@ public abstract interface SubstitutedClassParameters : R|kotlin/Any| { } public abstract interface Super1 : R|kotlin/Any| { - public abstract fun foo(): R|ft| + public abstract fun foo(): R|T!| public abstract fun dummy(): R|kotlin/Unit| } public abstract interface Super2 : R|kotlin/Any| { - public abstract fun foo(): R|ft| + public abstract fun foo(): R|E!| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/TypeParamOfClass.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/TypeParamOfClass.fir.txt index 069bc172630..5eb6d32e0ec 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/TypeParamOfClass.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/return/TypeParamOfClass.fir.txt @@ -1,5 +1,5 @@ public abstract interface TypeParamOfClass : R|kotlin/Any| { - public abstract interface Sub : R|test/TypeParamOfClass.Super>| { + public abstract interface Sub : R|test/TypeParamOfClass.Super| { public abstract fun foo(): R|@EnhancedNullability T & Any| } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/InheritNullability.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/InheritNullability.fir.txt index 8235c92b707..96c5eb8bae2 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/InheritNullability.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/InheritNullability.fir.txt @@ -1,10 +1,10 @@ public abstract interface InheritNullability : R|kotlin/Any| { public abstract interface Sub : R|test/InheritNullability.Super| { - public abstract fun foo(b: R|ft|): R|kotlin/Unit| + public abstract fun foo(b: R|B!|): R|kotlin/Unit| } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(a: R|ft|): R|kotlin/Unit| + public abstract fun foo(a: R|A!|): R|kotlin/Unit| } } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoBounds.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoBounds.fir.txt index 44108a13f0b..82a60574024 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoBounds.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoBounds.fir.txt @@ -1,10 +1,10 @@ public abstract interface TwoBounds : R|kotlin/Any| { public abstract interface Sub : R|test/TwoBounds.Super| { - public abstract fun foo(b: R|ft|): R|kotlin/Unit| + public abstract fun foo(b: R|B!|): R|kotlin/Unit| } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(a: R|ft|): R|kotlin/Unit| + public abstract fun foo(a: R|A!|): R|kotlin/Unit| } } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoSuperclasses.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoSuperclasses.fir.txt index a1e70abbd5c..b8dfd8d4ad7 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoSuperclasses.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoSuperclasses.fir.txt @@ -1,14 +1,14 @@ public abstract interface TwoSuperclasses : R|kotlin/Any| { public abstract interface Sub : R|test/TwoSuperclasses.Super1|, R|test/TwoSuperclasses.Super2| { - public abstract fun foo(c: R|ft|): R|kotlin/Unit| + public abstract fun foo(c: R|C!|): R|kotlin/Unit| } public abstract interface Super1 : R|kotlin/Any| { - public abstract fun foo(a: R|ft|): R|kotlin/Unit| + public abstract fun foo(a: R|A!|): R|kotlin/Unit| } public abstract interface Super2 : R|kotlin/Any| { - public abstract fun foo(a: R|ft|): R|kotlin/Unit| + public abstract fun foo(a: R|B!|): R|kotlin/Unit| } } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoTypeParameters.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoTypeParameters.fir.txt index 138f56e6afa..66582c4facb 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoTypeParameters.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/TwoTypeParameters.fir.txt @@ -1,10 +1,10 @@ public abstract interface TwoTypeParameters : R|kotlin/Any| { public abstract interface Sub : R|test/TwoTypeParameters.Super| { - public abstract fun foo(b: R|ft|, a: R|ft|): R|kotlin/Unit| + public abstract fun foo(b: R|B!|, a: R|A!|): R|kotlin/Unit| } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(a: R|ft|, b: R|ft|): R|kotlin/Unit| + public abstract fun foo(a: R|A!|, b: R|B!|): R|kotlin/Unit| } } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterAsUpperBound.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterAsUpperBound.fir.txt index b0cf5262ba5..be97d847ad3 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterAsUpperBound.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterAsUpperBound.fir.txt @@ -1,12 +1,12 @@ public abstract interface UseParameterAsUpperBound : R|kotlin/Any| { public abstract interface Sub : R|test/UseParameterAsUpperBound.Super| { - public abstract fun |> foo(b: R|ft|, a: R|ft|): R|kotlin/Unit| + public abstract fun foo(b: R|B!|, a: R|A!|): R|kotlin/Unit| - public abstract fun |> foo(a: R|ft|, b: R|ft|): R|kotlin/Unit| + public abstract fun foo(a: R|A!|, b: R|B!|): R|kotlin/Unit| } public abstract interface Super : R|kotlin/Any| { - public abstract fun |> foo(a: R|ft|, b: R|ft|): R|kotlin/Unit| + public abstract fun foo(a: R|A!|, b: R|B!|): R|kotlin/Unit| } } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBound.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBound.fir.txt index 87ebaa41969..2ac95527fcf 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBound.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBound.fir.txt @@ -1,10 +1,10 @@ public abstract interface UseParameterInUpperBound : R|kotlin/Any| { public abstract interface Sub : R|test/UseParameterInUpperBound.Super| { - public abstract fun >, kotlin/collections/List>?>|> foo(b: R|ft|, a: R|ft|): R|kotlin/Unit| + public abstract fun , kotlin/collections/List?>|> foo(b: R|B!|, a: R|A!|): R|kotlin/Unit| } public abstract interface Super : R|kotlin/Any| { - public abstract fun >, kotlin/collections/List>?>|> foo(a: R|ft|, b: R|ft|): R|kotlin/Unit| + public abstract fun , kotlin/collections/List?>|> foo(a: R|A!|, b: R|B!|): R|kotlin/Unit| } } diff --git a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBoundWithKotlinSignature.fir.txt b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBoundWithKotlinSignature.fir.txt index 77437b1115c..7840f694549 100644 --- a/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBoundWithKotlinSignature.fir.txt +++ b/compiler/testData/loadJava/compiledJava/kotlinSignature/propagation/typeParameter/UseParameterInUpperBoundWithKotlinSignature.fir.txt @@ -1,10 +1,10 @@ public abstract interface UseParameterInUpperBoundWithKotlinSignature : R|kotlin/Any| { public abstract interface Sub : R|test/UseParameterInUpperBoundWithKotlinSignature.Super| { - public abstract fun >, kotlin/collections/List>?>|> foo(b: R|ft|, a: R|ft|): R|kotlin/Unit| + public abstract fun , kotlin/collections/List?>|> foo(b: R|B!|, a: R|A!|): R|kotlin/Unit| } public abstract interface Super : R|kotlin/Any| { - public abstract fun >, kotlin/collections/List>?>|> foo(a: R|ft|, b: R|ft|): R|kotlin/Unit| + public abstract fun , kotlin/collections/List?>|> foo(a: R|A!|, b: R|B!|): R|kotlin/Unit| } } diff --git a/compiler/testData/loadJava/compiledJava/library/LoadIterable.fir.txt b/compiler/testData/loadJava/compiledJava/library/LoadIterable.fir.txt index dfadafdc099..345e56439b7 100644 --- a/compiler/testData/loadJava/compiledJava/library/LoadIterable.fir.txt +++ b/compiler/testData/loadJava/compiledJava/library/LoadIterable.fir.txt @@ -1,6 +1,6 @@ public abstract interface LoadIterable : R|kotlin/Any| { - public abstract fun getIterable(): R|ft>, kotlin/collections/Iterable>?>| + public abstract fun getIterable(): R|ft, kotlin/collections/Iterable?>| - public abstract fun setIterable(Iterable: R|ft>, kotlin/collections/Iterable>?>|): R|kotlin/Unit| + public abstract fun setIterable(Iterable: R|ft, kotlin/collections/Iterable?>|): R|kotlin/Unit| } diff --git a/compiler/testData/loadJava/compiledJava/library/LoadIterator.fir.txt b/compiler/testData/loadJava/compiledJava/library/LoadIterator.fir.txt index 93362e1db58..b3ba9242261 100644 --- a/compiler/testData/loadJava/compiledJava/library/LoadIterator.fir.txt +++ b/compiler/testData/loadJava/compiledJava/library/LoadIterator.fir.txt @@ -1,6 +1,6 @@ public abstract interface LoadIterator : R|kotlin/Any| { - public abstract fun getIterator(): R|ft>, kotlin/collections/Iterator>?>| + public abstract fun getIterator(): R|ft, kotlin/collections/Iterator?>| - public abstract fun setIterator(iterator: R|ft>, kotlin/collections/Iterator>?>|): R|kotlin/Unit| + public abstract fun setIterator(iterator: R|ft, kotlin/collections/Iterator?>|): R|kotlin/Unit| } diff --git a/compiler/testData/loadJava/compiledJava/library/Max.fir.txt b/compiler/testData/loadJava/compiledJava/library/Max.fir.txt index 5c9ef202091..848d53ec541 100644 --- a/compiler/testData/loadJava/compiledJava/library/Max.fir.txt +++ b/compiler/testData/loadJava/compiledJava/library/Max.fir.txt @@ -1,5 +1,5 @@ public open class Max : R|kotlin/Any| { - public open fun >, kotlin/Comparable>?>|> max(coll: R|ft>, kotlin/collections/Collection>?>|): R|ft| + public open fun , kotlin/Comparable?>|> max(coll: R|ft, kotlin/collections/Collection?>|): R|T!| public constructor(): R|test/Max| diff --git a/compiler/testData/loadJava/compiledJava/mutability/LoadIterable.fir.txt b/compiler/testData/loadJava/compiledJava/mutability/LoadIterable.fir.txt index 11ae023d962..07279349619 100644 --- a/compiler/testData/loadJava/compiledJava/mutability/LoadIterable.fir.txt +++ b/compiler/testData/loadJava/compiledJava/mutability/LoadIterable.fir.txt @@ -1,10 +1,10 @@ public abstract interface LoadIterable : R|kotlin/Any| { - @R|kotlin/annotations/jvm/Mutable|() public abstract fun getIterable(): R|ft>, kotlin/collections/MutableIterable>?>| + @R|kotlin/annotations/jvm/Mutable|() public abstract fun getIterable(): R|ft, kotlin/collections/MutableIterable?>| - public abstract fun setIterable(@R|kotlin/annotations/jvm/Mutable|() Iterable: R|ft>, kotlin/collections/MutableIterable>?>|): R|kotlin/Unit| + public abstract fun setIterable(@R|kotlin/annotations/jvm/Mutable|() Iterable: R|ft, kotlin/collections/MutableIterable?>|): R|kotlin/Unit| - @R|kotlin/annotations/jvm/ReadOnly|() public abstract fun getReadOnlyIterable(): R|ft>, kotlin/collections/Iterable>?>| + @R|kotlin/annotations/jvm/ReadOnly|() public abstract fun getReadOnlyIterable(): R|ft, kotlin/collections/Iterable?>| - public abstract fun setReadOnlyIterable(@R|kotlin/annotations/jvm/ReadOnly|() Iterable: R|ft>, kotlin/collections/Iterable>?>|): R|kotlin/Unit| + public abstract fun setReadOnlyIterable(@R|kotlin/annotations/jvm/ReadOnly|() Iterable: R|ft, kotlin/collections/Iterable?>|): R|kotlin/Unit| } diff --git a/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithConflict.fir.txt b/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithConflict.fir.txt index cc197ba1b5e..31b95deb251 100644 --- a/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithConflict.fir.txt +++ b/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithConflict.fir.txt @@ -1,6 +1,6 @@ public abstract interface LoadIterableWithConflict : R|kotlin/Any| { - @R|kotlin/annotations/jvm/ReadOnly|() @R|kotlin/annotations/jvm/Mutable|() public abstract fun getIterable(): R|ft>, kotlin/collections/Iterable>?>| + @R|kotlin/annotations/jvm/ReadOnly|() @R|kotlin/annotations/jvm/Mutable|() public abstract fun getIterable(): R|ft, kotlin/collections/Iterable?>| - public abstract fun setIterable(@R|kotlin/annotations/jvm/ReadOnly|() @R|kotlin/annotations/jvm/Mutable|() Iterable: R|ft>, kotlin/collections/Iterable>?>|): R|kotlin/Unit| + public abstract fun setIterable(@R|kotlin/annotations/jvm/ReadOnly|() @R|kotlin/annotations/jvm/Mutable|() Iterable: R|ft, kotlin/collections/Iterable?>|): R|kotlin/Unit| } diff --git a/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithNullability.fir.txt b/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithNullability.fir.txt index 7a66753e270..7102c487619 100644 --- a/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithNullability.fir.txt +++ b/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithNullability.fir.txt @@ -1,10 +1,10 @@ public abstract interface LoadIterableWithNullability : R|kotlin/Any| { - @R|org/jetbrains/annotations/NotNull|() @R|kotlin/annotations/jvm/Mutable|() public abstract fun getIterable(): R|@EnhancedNullability kotlin/collections/MutableIterable>| + @R|org/jetbrains/annotations/NotNull|() @R|kotlin/annotations/jvm/Mutable|() public abstract fun getIterable(): R|@EnhancedNullability kotlin/collections/MutableIterable| - public abstract fun setIterable(@R|kotlin/annotations/jvm/Mutable|() @R|org/jetbrains/annotations/NotNull|() Iterable: R|@EnhancedNullability kotlin/collections/MutableIterable>|): R|kotlin/Unit| + public abstract fun setIterable(@R|kotlin/annotations/jvm/Mutable|() @R|org/jetbrains/annotations/NotNull|() Iterable: R|@EnhancedNullability kotlin/collections/MutableIterable|): R|kotlin/Unit| - @R|org/jetbrains/annotations/NotNull|() @R|kotlin/annotations/jvm/ReadOnly|() public abstract fun getReadOnlyIterable(): R|@EnhancedNullability kotlin/collections/Iterable>| + @R|org/jetbrains/annotations/NotNull|() @R|kotlin/annotations/jvm/ReadOnly|() public abstract fun getReadOnlyIterable(): R|@EnhancedNullability kotlin/collections/Iterable| - public abstract fun setReadOnlyIterable(@R|kotlin/annotations/jvm/ReadOnly|() @R|org/jetbrains/annotations/NotNull|() Iterable: R|@EnhancedNullability kotlin/collections/Iterable>|): R|kotlin/Unit| + public abstract fun setReadOnlyIterable(@R|kotlin/annotations/jvm/ReadOnly|() @R|org/jetbrains/annotations/NotNull|() Iterable: R|@EnhancedNullability kotlin/collections/Iterable|): R|kotlin/Unit| } diff --git a/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithPropagation.fir.txt b/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithPropagation.fir.txt index c0a8aeef4a7..54fcf581ee1 100644 --- a/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithPropagation.fir.txt +++ b/compiler/testData/loadJava/compiledJava/mutability/LoadIterableWithPropagation.fir.txt @@ -1,22 +1,22 @@ public abstract interface LoadIterableWithPropagation : R|kotlin/Any| { public abstract interface LoadIterable : R|kotlin/Any| { - @R|kotlin/annotations/jvm/Mutable|() public abstract fun getIterable(): R|ft>, kotlin/collections/MutableIterable>?>| + @R|kotlin/annotations/jvm/Mutable|() public abstract fun getIterable(): R|ft, kotlin/collections/MutableIterable?>| - public abstract fun setIterable(@R|kotlin/annotations/jvm/Mutable|() Iterable: R|ft>, kotlin/collections/MutableIterable>?>|): R|kotlin/Unit| + public abstract fun setIterable(@R|kotlin/annotations/jvm/Mutable|() Iterable: R|ft, kotlin/collections/MutableIterable?>|): R|kotlin/Unit| - @R|kotlin/annotations/jvm/ReadOnly|() public abstract fun getReadOnlyIterable(): R|ft>, kotlin/collections/Iterable>?>| + @R|kotlin/annotations/jvm/ReadOnly|() public abstract fun getReadOnlyIterable(): R|ft, kotlin/collections/Iterable?>| - public abstract fun setReadOnlyIterable(@R|kotlin/annotations/jvm/ReadOnly|() Iterable: R|ft>, kotlin/collections/Iterable>?>|): R|kotlin/Unit| + public abstract fun setReadOnlyIterable(@R|kotlin/annotations/jvm/ReadOnly|() Iterable: R|ft, kotlin/collections/Iterable?>|): R|kotlin/Unit| } - public open class LoadIterableImpl : R|kotlin/Any|, R|test/LoadIterableWithPropagation.LoadIterable>| { - public open fun getIterable(): R|ft>, kotlin/collections/MutableIterable>?>| + public open class LoadIterableImpl : R|kotlin/Any|, R|test/LoadIterableWithPropagation.LoadIterable| { + public open fun getIterable(): R|ft, kotlin/collections/MutableIterable?>| - public open fun setIterable(Iterable: R|ft>, kotlin/collections/MutableIterable>?>|): R|kotlin/Unit| + public open fun setIterable(Iterable: R|ft, kotlin/collections/MutableIterable?>|): R|kotlin/Unit| - public open fun getReadOnlyIterable(): R|ft>, kotlin/collections/Iterable>?>| + public open fun getReadOnlyIterable(): R|ft, kotlin/collections/Iterable?>| - public open fun setReadOnlyIterable(Iterable: R|ft>, kotlin/collections/Iterable>?>|): R|kotlin/Unit| + public open fun setReadOnlyIterable(Iterable: R|ft, kotlin/collections/Iterable?>|): R|kotlin/Unit| public constructor(): R|test/LoadIterableWithPropagation.LoadIterableImpl| diff --git a/compiler/testData/loadJava/compiledJava/sam/Comparator.fir.txt b/compiler/testData/loadJava/compiledJava/sam/Comparator.fir.txt index 88b80b3cc4d..c585be6eac2 100644 --- a/compiler/testData/loadJava/compiledJava/sam/Comparator.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/Comparator.fir.txt @@ -1,4 +1,4 @@ public abstract interface Comparator : R|kotlin/Any| { - public abstract fun compare(o1: R|ft|, o2: R|ft|): R|kotlin/Int| + public abstract fun compare(o1: R|T!|, o2: R|T!|): R|kotlin/Int| } diff --git a/compiler/testData/loadJava/compiledJava/sam/GenericInterfaceParameterWithSelfBound.fir.txt b/compiler/testData/loadJava/compiledJava/sam/GenericInterfaceParameterWithSelfBound.fir.txt index 56f7e68a396..95afb135d1b 100644 --- a/compiler/testData/loadJava/compiledJava/sam/GenericInterfaceParameterWithSelfBound.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/GenericInterfaceParameterWithSelfBound.fir.txt @@ -1,4 +1,4 @@ -public abstract interface GenericInterfaceParameterWithSelfBound>, test/GenericInterfaceParameterWithSelfBound>?>|> : R|kotlin/Any| { - public abstract fun method(t: R|ft|): R|ft| +public abstract interface GenericInterfaceParameterWithSelfBound, test/GenericInterfaceParameterWithSelfBound?>|> : R|kotlin/Any| { + public abstract fun method(t: R|T!|): R|T!| } diff --git a/compiler/testData/loadJava/compiledJava/sam/GenericInterfaceParametersWithBounds.fir.txt b/compiler/testData/loadJava/compiledJava/sam/GenericInterfaceParametersWithBounds.fir.txt index b1dcc13d19a..d52297e4933 100644 --- a/compiler/testData/loadJava/compiledJava/sam/GenericInterfaceParametersWithBounds.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/GenericInterfaceParametersWithBounds.fir.txt @@ -1,4 +1,4 @@ -public abstract interface GenericInterfaceParametersWithBounds>, kotlin/Comparable>?>|, R|kotlin/Cloneable!|, B : R|ft>, kotlin/collections/List>?>|> : R|kotlin/Any| { - public abstract fun method(a: R|ft>, kotlin/Array>?>|, b: R|ft|): R|kotlin/Unit| +public abstract interface GenericInterfaceParametersWithBounds, kotlin/Comparable?>|, R|kotlin/Cloneable!|, B : R|ft, kotlin/collections/List?>|> : R|kotlin/Any| { + public abstract fun method(a: R|ft, kotlin/Array?>|, b: R|B!|): R|kotlin/Unit| } diff --git a/compiler/testData/loadJava/compiledJava/sam/GenericMethodParameters.fir.txt b/compiler/testData/loadJava/compiledJava/sam/GenericMethodParameters.fir.txt index 262b69d88a1..ce00b72a772 100644 --- a/compiler/testData/loadJava/compiledJava/sam/GenericMethodParameters.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/GenericMethodParameters.fir.txt @@ -1,4 +1,4 @@ public abstract interface GenericMethodParameters : R|kotlin/Any| { - public abstract fun >, kotlin/collections/List>?>|> method(a: R|ft>, kotlin/Array>?>|, b: R|ft|): R|kotlin/Unit| + public abstract fun , kotlin/collections/List?>|> method(a: R|ft, kotlin/Array?>|, b: R|B!|): R|kotlin/Unit| } diff --git a/compiler/testData/loadJava/compiledJava/sam/SamSubinterfaceOfTwo.fir.txt b/compiler/testData/loadJava/compiledJava/sam/SamSubinterfaceOfTwo.fir.txt index 2546f72ad5d..c9257b2dac3 100644 --- a/compiler/testData/loadJava/compiledJava/sam/SamSubinterfaceOfTwo.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/SamSubinterfaceOfTwo.fir.txt @@ -6,7 +6,7 @@ public abstract interface SamSubinterfaceOfTwo : R|kotlin/Any| { } public abstract interface Super2 : R|kotlin/Any| { - public abstract fun f(): R|ft| + public abstract fun f(): R|T!| } } diff --git a/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfClass.fir.txt b/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfClass.fir.txt index 9503225c223..fba0899fc5e 100644 --- a/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfClass.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfClass.fir.txt @@ -1,5 +1,5 @@ public open class TypeParameterOfClass : R|kotlin/Any| { - public open fun foo(comparator: R|ft>, java/util/Comparator>?>|): R|kotlin/Unit| + public open fun foo(comparator: R|ft, java/util/Comparator?>|): R|kotlin/Unit| public constructor(): R|test/TypeParameterOfClass| diff --git a/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfMethod.fir.txt b/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfMethod.fir.txt index bb17c9d1b42..19860668254 100644 --- a/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfMethod.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfMethod.fir.txt @@ -1,9 +1,9 @@ public open class TypeParameterOfMethod : R|kotlin/Any| { - public open static fun max(comparator: R|ft>, java/util/Comparator>?>|, value1: R|ft|, value2: R|ft|): R|ft| + public open static fun max(comparator: R|ft, java/util/Comparator?>|, value1: R|T!|, value2: R|T!|): R|T!| - public open static fun max2(comparator: R|ft>, java/util/Comparator>?>|, value1: R|ft|, value2: R|ft|): R|ft| + public open static fun max2(comparator: R|ft, java/util/Comparator?>|, value1: R|T!|, value2: R|T!|): R|T!| - public open static fun >, kotlin/collections/List>?>|> method(a: R|ft>, java/util/Comparator>?>|, b: R|ft|): R|kotlin/Unit| + public open static fun , kotlin/collections/List?>|> method(a: R|ft, java/util/Comparator?>|, b: R|B!|): R|kotlin/Unit| public constructor(): R|test/TypeParameterOfMethod| diff --git a/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfOuterClass.fir.txt b/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfOuterClass.fir.txt index 85916bb1a27..126b8695263 100644 --- a/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfOuterClass.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/adapters/TypeParameterOfOuterClass.fir.txt @@ -2,7 +2,7 @@ public open class TypeParameterOfOuterClass : R|kotlin/Any| public constructor(): R|test/TypeParameterOfOuterClass| public open inner class Inner : R|kotlin/Any| { - public open fun foo(comparator: R|ft>, java/util/Comparator>?>|): R|kotlin/Unit| + public open fun foo(comparator: R|ft, java/util/Comparator?>|): R|kotlin/Unit| public test/TypeParameterOfOuterClass.constructor(): R|test/TypeParameterOfOuterClass.Inner| diff --git a/compiler/testData/loadJava/compiledJava/sam/adapters/inheritance/InheritedSameAdaptersWithSubstitution.fir.txt b/compiler/testData/loadJava/compiledJava/sam/adapters/inheritance/InheritedSameAdaptersWithSubstitution.fir.txt index c9638a12697..e2855142e03 100644 --- a/compiler/testData/loadJava/compiledJava/sam/adapters/inheritance/InheritedSameAdaptersWithSubstitution.fir.txt +++ b/compiler/testData/loadJava/compiledJava/sam/adapters/inheritance/InheritedSameAdaptersWithSubstitution.fir.txt @@ -6,7 +6,7 @@ public abstract interface InheritedSameAdaptersWithSubstitution : R|kotlin/Any| } public abstract interface Super2 : R|kotlin/Any| { - public abstract fun foo(r: R|ft>, java/util/Comparator>?>|): R|kotlin/Unit| + public abstract fun foo(r: R|ft, java/util/Comparator?>|): R|kotlin/Unit| } public abstract interface Super2Substituted : R|test/InheritedSameAdaptersWithSubstitution.Super2| { diff --git a/compiler/testData/loadJava/compiledJava/signaturePropagation/ArraysInSubtypes.fir.txt b/compiler/testData/loadJava/compiledJava/signaturePropagation/ArraysInSubtypes.fir.txt index ac04e3a66f9..3d42e5c2076 100644 --- a/compiler/testData/loadJava/compiledJava/signaturePropagation/ArraysInSubtypes.fir.txt +++ b/compiler/testData/loadJava/compiledJava/signaturePropagation/ArraysInSubtypes.fir.txt @@ -4,7 +4,7 @@ public abstract interface ArraysInSubtypes : R|kotlin/Any| { public abstract fun listOfArray(): R|ft, kotlin/Array?>>, kotlin/collections/List, kotlin/Array?>>?>| - public abstract fun objArray(): R|ft>, kotlin/Array>?>| + public abstract fun objArray(): R|ft, kotlin/Array?>| } public abstract interface Super : R|kotlin/Any| { diff --git a/compiler/testData/loadJava/compiledJava/signaturePropagation/MethodTypeParameterErased.fir.txt b/compiler/testData/loadJava/compiledJava/signaturePropagation/MethodTypeParameterErased.fir.txt index 50485d8c196..e457001544f 100644 --- a/compiler/testData/loadJava/compiledJava/signaturePropagation/MethodTypeParameterErased.fir.txt +++ b/compiler/testData/loadJava/compiledJava/signaturePropagation/MethodTypeParameterErased.fir.txt @@ -1,6 +1,6 @@ public abstract interface MethodTypeParameterErased : R|kotlin/Any| { public abstract interface Bug : R|kotlin/Any| { - public abstract fun >, test/MethodTypeParameterErased.Bug>?>|> save(): R|ft| + public abstract fun , test/MethodTypeParameterErased.Bug?>|> save(): R|RET!| } public open class SubBug : R|kotlin/Any|, R|test/MethodTypeParameterErased.Bug| { diff --git a/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperType.fir.txt b/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperType.fir.txt index ad8f3a5f696..54bf06cada8 100644 --- a/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperType.fir.txt +++ b/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperType.fir.txt @@ -10,7 +10,7 @@ public open class RawSuperType : R|kotlin/Any| { } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(t: R|ft|): R|kotlin/Unit| + public abstract fun foo(t: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithBound.fir.txt b/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithBound.fir.txt index e16187769eb..a9df239c4f4 100644 --- a/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithBound.fir.txt +++ b/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithBound.fir.txt @@ -14,7 +14,7 @@ public open class RawSuperTypeWithBound : R|kotlin/Any| { } public abstract interface Super : R|kotlin/Any| { - public abstract fun foo(t: R|ft|): R|kotlin/Unit| + public abstract fun foo(t: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithRecursiveBound.fir.txt b/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithRecursiveBound.fir.txt index 8231bc28d50..dddfd004981 100644 --- a/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithRecursiveBound.fir.txt +++ b/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithRecursiveBound.fir.txt @@ -11,8 +11,8 @@ public open class RawSuperTypeWithRecursiveBound : R|kotlin/Any| { public test/RawSuperTypeWithRecursiveBound.constructor(): R|test/RawSuperTypeWithRecursiveBound.Derived| } - public abstract interface Super>, test/RawSuperTypeWithRecursiveBound.Super>?>|> : R|kotlin/Any| { - public abstract fun foo(t: R|ft|): R|kotlin/Unit| + public abstract interface Super, test/RawSuperTypeWithRecursiveBound.Super?>|> : R|kotlin/Any| { + public abstract fun foo(t: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithRecursiveBoundMultipleParameters.fir.txt b/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithRecursiveBoundMultipleParameters.fir.txt index 7f40b5ae2a6..68fb75a92fe 100644 --- a/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithRecursiveBoundMultipleParameters.fir.txt +++ b/compiler/testData/loadJava/compiledJava/signaturePropagation/RawSuperTypeWithRecursiveBoundMultipleParameters.fir.txt @@ -11,8 +11,8 @@ public open class RawSuperTypeWithRecursiveBoundMultipleParameters : R|kotlin/An public test/RawSuperTypeWithRecursiveBoundMultipleParameters.constructor(): R|test/RawSuperTypeWithRecursiveBoundMultipleParameters.Derived| } - public abstract interface Super, ft>, test/RawSuperTypeWithRecursiveBoundMultipleParameters.Super, ft>?>|> : R|kotlin/Any| { - public abstract fun foo(r: R|ft|, t: R|ft|): R|kotlin/Unit| + public abstract interface Super, test/RawSuperTypeWithRecursiveBoundMultipleParameters.Super?>|> : R|kotlin/Any| { + public abstract fun foo(r: R|R!|, t: R|T!|): R|kotlin/Unit| public abstract fun dummy(): R|kotlin/Unit| diff --git a/compiler/testData/loadJava/compiledJava/signaturePropagation/ReturnInnerSubclassOfSupersInner.fir.txt b/compiler/testData/loadJava/compiledJava/signaturePropagation/ReturnInnerSubclassOfSupersInner.fir.txt index 4964d6e1dbf..837b5db514c 100644 --- a/compiler/testData/loadJava/compiledJava/signaturePropagation/ReturnInnerSubclassOfSupersInner.fir.txt +++ b/compiler/testData/loadJava/compiledJava/signaturePropagation/ReturnInnerSubclassOfSupersInner.fir.txt @@ -1,9 +1,9 @@ public abstract interface ReturnInnerSubclassOfSupersInner : R|kotlin/Any| { - public open class Sub : R|test/ReturnInnerSubclassOfSupersInner.Super>| { + public open class Sub : R|test/ReturnInnerSubclassOfSupersInner.Super| { public constructor(): R|test/ReturnInnerSubclassOfSupersInner.Sub| - public/*package*/ open inner class Inner : R|test/ReturnInnerSubclassOfSupersInner.Super.Inner>| { - public/*package*/ open fun get(): R|ft>, test/ReturnInnerSubclassOfSupersInner.Sub>?>| + public/*package*/ open inner class Inner : R|test/ReturnInnerSubclassOfSupersInner.Super.Inner| { + public/*package*/ open fun get(): R|ft, test/ReturnInnerSubclassOfSupersInner.Sub?>| public/*package*/ test/ReturnInnerSubclassOfSupersInner.Sub.constructor(): R|test/ReturnInnerSubclassOfSupersInner.Sub.Inner| @@ -13,7 +13,7 @@ public abstract interface ReturnInnerSubclassOfSupersInner : R|kotlin/Any| { public constructor(): R|test/ReturnInnerSubclassOfSupersInner.Super| public/*package*/ open inner class Inner : R|kotlin/Any| { - public/*package*/ open fun get(): R|ft>, test/ReturnInnerSubclassOfSupersInner.Super>?>| + public/*package*/ open fun get(): R|ft, test/ReturnInnerSubclassOfSupersInner.Super?>| public/*package*/ test/ReturnInnerSubclassOfSupersInner.Super.constructor(): R|test/ReturnInnerSubclassOfSupersInner.Super.Inner| diff --git a/compiler/tests-spec/testData/diagnostics/linked/expressions/conditional-expression/p-6/neg/1.1.fir.kt b/compiler/tests-spec/testData/diagnostics/linked/expressions/conditional-expression/p-6/neg/1.1.fir.kt index ad794c5449a..6062df8f151 100644 --- a/compiler/tests-spec/testData/diagnostics/linked/expressions/conditional-expression/p-6/neg/1.1.fir.kt +++ b/compiler/tests-spec/testData/diagnostics/linked/expressions/conditional-expression/p-6/neg/1.1.fir.kt @@ -62,8 +62,8 @@ public class JavaClassCase3{ // TESTCASE NUMBER: 3 fun case3() { val x = JavaClassCase3.id(null) // Nothing! - x - val a = if (x) { + x + val a = if (x) { "NOK" } else "NOK" }