Files
kotlin-fork/compiler/testData/klib/partial-linkage/classTransformations/main/m.kt
T
2023-08-16 19:11:34 +00:00

361 lines
60 KiB
Kotlin
Vendored

import abitestutils.abiTest
fun box() = abiTest {
/**
* `fun foo(): A.B`: In older version of the library `A` and `B` were classes. In newer version `B` is an entry of enum `A`.
*
* When no lazy IR is used, [IrCall.symbol.owner] is a function (most likely [IrFunctionImpl]) which has the stub [IrClass] (the one
* generated by [MissingDeclarationStubGenerator]) with "/A.B|null[0]" signature in the return type. So the function is formally
* detected as "referecing an unbound CLASS symbol" and the appropriate error message is constructed.
*
* When lazy IR is used, [IrCall.symbol.owner] is a lazy-IR function with the return type holding the lazy-IR class
* generated from [EnumEntrySyntheticClassDescriptor] for the enum entry and having a different signature: "/A.B.<EEC>|null[0]".
* This class is not detected as unbound, and the whole function is not considered as partially linked. But the [IrCall]
* still has its own expression type recorded that is deserialized without lazy-IR-distortion, so the [IrCall] expression
* is detected as "using an unbound CLASS symbol" with "/A.B|null[0]" signature.
*
* The [adjustForLazyIr] function is used to adjust tested error messages depending on whether lazy IR is used or not.
*/
fun adjustForLazyIr(declaration: String) =
if (testMode.lazyIr.usedEverywhere) "Expression" else declaration
fun adjustNoClassFoundForLazyIr(signature: String) =
if (testMode.lazyIr.usedEverywhere) "Expression uses unlinked class symbol '$signature'" else "No class found for symbol '$signature'"
expectFailure(linkage("Function 'getClassToEnumFoo' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ClassToEnum.Foo'")) { getClassToEnumFoo() }
expectFailure(linkage("Function 'getClassToEnumFooInline' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ClassToEnum.Foo'")) { getClassToEnumFooInline() }
expectFailure(linkage("Constructor 'Foo.<init>' can not be called: No constructor found for symbol '/ClassToEnum.Foo.<init>'")) { getClassToEnumFooAsAny() }
expectFailure(linkage("Constructor 'Foo.<init>' can not be called: No constructor found for symbol '/ClassToEnum.Foo.<init>'")) { getClassToEnumFooAsAnyInline() }
expectFailure(linkage("Function 'getClassToEnumBar' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ClassToEnum.Bar'")) { getClassToEnumBar() }
expectFailure(linkage("Function 'getClassToEnumBarInline' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ClassToEnum.Bar'")) { getClassToEnumBarInline() }
expectFailure(linkage("Can not get instance of singleton 'Bar': No class found for symbol '/ClassToEnum.Bar'")) { getClassToEnumBarAsAny() }
expectFailure(linkage("Can not get instance of singleton 'Bar': No class found for symbol '/ClassToEnum.Bar'")) { getClassToEnumBarAsAnyInline() }
expectFailure(linkage("Function 'getClassToEnumBaz' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ClassToEnum.Baz'")) { getClassToEnumBaz() }
expectFailure(linkage("Function 'getClassToEnumBazInline' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ClassToEnum.Baz'")) { getClassToEnumBazInline() }
expectFailure(linkage("Constructor 'ClassToEnum.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getClassToEnumBazAsAny() }
expectFailure(linkage("Constructor 'ClassToEnum.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getClassToEnumBazAsAnyInline() }
expectFailure(linkage("Function 'getObjectToEnumFoo' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ObjectToEnum.Foo'")) { getObjectToEnumFoo() }
expectFailure(linkage("Function 'getObjectToEnumFooInline' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ObjectToEnum.Foo'")) { getObjectToEnumFooInline() }
expectFailure(linkage("Constructor 'Foo.<init>' can not be called: No constructor found for symbol '/ObjectToEnum.Foo.<init>'")) { getObjectToEnumFooAsAny() }
expectFailure(linkage("Constructor 'Foo.<init>' can not be called: No constructor found for symbol '/ObjectToEnum.Foo.<init>'")) { getObjectToEnumFooAsAnyInline() }
expectFailure(linkage("Function 'getObjectToEnumBar' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ObjectToEnum.Bar'")) { getObjectToEnumBar() }
expectFailure(linkage("Function 'getObjectToEnumBarInline' can not be called: ${adjustForLazyIr("Function")} uses unlinked class symbol '/ObjectToEnum.Bar'")) { getObjectToEnumBarInline() }
expectFailure(linkage("Can not get instance of singleton 'Bar': No class found for symbol '/ObjectToEnum.Bar'")) { getObjectToEnumBarAsAny() }
expectFailure(linkage("Can not get instance of singleton 'Bar': No class found for symbol '/ObjectToEnum.Bar'")) { getObjectToEnumBarAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Foo': No enum entry found for symbol '/EnumToClass.Foo'")) { getEnumToClassFoo() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Foo': No enum entry found for symbol '/EnumToClass.Foo'")) { getEnumToClassFooInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Foo': No enum entry found for symbol '/EnumToClass.Foo'")) { getEnumToClassFooAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Foo': No enum entry found for symbol '/EnumToClass.Foo'")) { getEnumToClassFooAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Bar': No enum entry found for symbol '/EnumToClass.Bar'")) { getEnumToClassBar() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Bar': No enum entry found for symbol '/EnumToClass.Bar'")) { getEnumToClassBarInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Bar': No enum entry found for symbol '/EnumToClass.Bar'")) { getEnumToClassBarAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Bar': No enum entry found for symbol '/EnumToClass.Bar'")) { getEnumToClassBarAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Baz': No enum entry found for symbol '/EnumToClass.Baz'")) { getEnumToClassBaz() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Baz': No enum entry found for symbol '/EnumToClass.Baz'")) { getEnumToClassBazInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Baz': No enum entry found for symbol '/EnumToClass.Baz'")) { getEnumToClassBazAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumToClass.Baz': No enum entry found for symbol '/EnumToClass.Baz'")) { getEnumToClassBazAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToObject.Foo': No enum entry found for symbol '/EnumToObject.Foo'")) { getEnumToObjectFoo() }
expectFailure(linkage("Can not get instance of singleton 'EnumToObject.Foo': No enum entry found for symbol '/EnumToObject.Foo'")) { getEnumToObjectFooInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToObject.Foo': No enum entry found for symbol '/EnumToObject.Foo'")) { getEnumToObjectFooAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumToObject.Foo': No enum entry found for symbol '/EnumToObject.Foo'")) { getEnumToObjectFooAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToObject.Bar': No enum entry found for symbol '/EnumToObject.Bar'")) { getEnumToObjectBar() }
expectFailure(linkage("Can not get instance of singleton 'EnumToObject.Bar': No enum entry found for symbol '/EnumToObject.Bar'")) { getEnumToObjectBarInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumToObject.Bar': No enum entry found for symbol '/EnumToObject.Bar'")) { getEnumToObjectBarAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumToObject.Bar': No enum entry found for symbol '/EnumToObject.Bar'")) { getEnumToObjectBarAsAnyInline() }
expectFailure(linkage("Constructor 'ClassToObject.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getClassToObject() }
expectFailure(linkage("Constructor 'ClassToObject.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getClassToObjectInline() }
expectFailure(linkage("Constructor 'ClassToObject.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getClassToObjectAsAny() }
expectFailure(linkage("Constructor 'ClassToObject.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getClassToObjectAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'ObjectToClass': 'ObjectToClass' is class while object is expected")) { getObjectToClass() }
expectFailure(linkage("Can not get instance of singleton 'ObjectToClass': 'ObjectToClass' is class while object is expected")) { getObjectToClassInline() }
expectFailure(linkage("Can not get instance of singleton 'ObjectToClass': 'ObjectToClass' is class while object is expected")) { getObjectToClassAsAny() }
expectFailure(linkage("Can not get instance of singleton 'ObjectToClass': 'ObjectToClass' is class while object is expected")) { getObjectToClassAsAnyInline() }
expectFailure(linkage("Constructor 'ClassToInterface.<init>' can not be called: No constructor found for symbol '/ClassToInterface.<init>'")) { getClassToInterface() }
expectFailure(linkage("Constructor 'ClassToInterface.<init>' can not be called: No constructor found for symbol '/ClassToInterface.<init>'")) { getClassToInterfaceInline() }
expectFailure(linkage("Constructor 'ClassToInterface.<init>' can not be called: No constructor found for symbol '/ClassToInterface.<init>'")) { getClassToInterfaceAsAny() }
expectFailure(linkage("Constructor 'ClassToInterface.<init>' can not be called: No constructor found for symbol '/ClassToInterface.<init>'")) { getClassToInterfaceAsAnyInline() }
expectSuccess("NestedObjectToCompanion1.Companion") { getNestedObjectToCompanion1().toString() }
expectSuccess("NestedObjectToCompanion1.Companion") { getNestedObjectToCompanion1Inline().toString() }
expectSuccess("NestedObjectToCompanion1.Companion") { getNestedObjectToCompanion1AsAny().toString() }
expectSuccess("NestedObjectToCompanion1.Companion") { getNestedObjectToCompanion1AsAnyInline().toString() }
expectSuccess("NestedObjectToCompanion2.Foo") { getNestedObjectToCompanion2().toString() }
expectSuccess("NestedObjectToCompanion2.Foo") { getNestedObjectToCompanion2Inline().toString() }
expectSuccess("NestedObjectToCompanion2.Foo") { getNestedObjectToCompanion2AsAny().toString() }
expectSuccess("NestedObjectToCompanion2.Foo") { getNestedObjectToCompanion2AsAnyInline().toString() }
expectSuccess("CompanionToNestedObject1.Companion") { getCompanionToNestedObject1().toString() }
expectSuccess("CompanionToNestedObject1.Companion") { getCompanionToNestedObject1Inline().toString() }
expectSuccess("CompanionToNestedObject1.Companion") { getCompanionToNestedObject1AsAny().toString() }
expectSuccess("CompanionToNestedObject1.Companion") { getCompanionToNestedObject1AsAnyInline().toString() }
expectSuccess("CompanionToNestedObject1.Companion") { getCompanionToNestedObject1Name() }
expectSuccess("CompanionToNestedObject1.Companion") { getCompanionToNestedObject1NameShort() }
expectSuccess("CompanionToNestedObject1.Companion") { getCompanionToNestedObject1NameInline() }
expectSuccess("CompanionToNestedObject1.Companion") { getCompanionToNestedObject1NameShortInline() }
expectSuccess("CompanionToNestedObject2.Foo") { getCompanionToNestedObject2().toString() }
expectSuccess("CompanionToNestedObject2.Foo") { getCompanionToNestedObject2Inline().toString() }
expectSuccess("CompanionToNestedObject2.Foo") { getCompanionToNestedObject2AsAny().toString() }
expectSuccess("CompanionToNestedObject2.Foo") { getCompanionToNestedObject2AsAnyInline().toString() }
expectSuccess("CompanionToNestedObject2.Foo") { getCompanionToNestedObject2Name() }
expectSuccess("CompanionToNestedObject2.Foo") { getCompanionToNestedObject2NameShort() }
expectSuccess("CompanionToNestedObject2.Foo") { getCompanionToNestedObject2NameInline() }
expectSuccess("CompanionToNestedObject2.Foo") { getCompanionToNestedObject2NameShortInline() }
expectSuccess("Foo") { getCompanionAndNestedObjectsSwap() }
expectSuccess("Foo") { getCompanionAndNestedObjectsSwapInline() }
expectFailure(linkage("Constructor 'NestedToInner.<init>' can not be called: The call site does not provide a dispatch receiver parameter 'this' that the constructor requires")) { getNestedToInnerName() }
expectFailure(linkage("Constructor 'NestedToInner.<init>' can not be called: The call site does not provide a dispatch receiver parameter 'this' that the constructor requires")) { getNestedToInnerNameInline() }
expectFailure(linkage("Can not get instance of singleton 'Object': 'Object' is inner class while object is expected")) { getNestedToInnerObjectName() }
expectFailure(linkage("Can not get instance of singleton 'Object': 'Object' is inner class while object is expected")) { getNestedToInnerObjectNameInline() }
expectFailure(linkage("Can not get instance of singleton 'Companion': 'Companion' is inner class while object is expected")) { getNestedToInnerCompanionName() }
expectFailure(linkage("Can not get instance of singleton 'Companion': 'Companion' is inner class while object is expected")) { getNestedToInnerCompanionNameInline() }
expectFailure(linkage("Constructor 'Nested.<init>' can not be called: The call site does not provide a dispatch receiver parameter 'this' that the constructor requires")) { getNestedToInnerNestedName() }
expectFailure(linkage("Constructor 'Nested.<init>' can not be called: The call site does not provide a dispatch receiver parameter 'this' that the constructor requires")) { getNestedToInnerNestedNameInline() }
expectFailure(linkage("Constructor 'NestedToInner.<init>' can not be called: The call site does not provide a dispatch receiver parameter 'this' that the constructor requires")) { getNestedToInnerInnerName() }
expectFailure(linkage("Constructor 'NestedToInner.<init>' can not be called: The call site does not provide a dispatch receiver parameter 'this' that the constructor requires")) { getNestedToInnerInnerNameInline() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedName() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedNameInline() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedObjectName() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedObjectNameInline() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedCompanionName() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedCompanionNameInline() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedNestedName() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedNestedNameInline() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedInnerName() }
expectFailure(linkage("Constructor 'InnerToNested.<init>' can not be called: The call site provides excessive dispatch receiver parameter 'this' that is not needed for the constructor")) { getInnerToNestedInnerNameInline() }
expectFailure(linkage("Constructor 'AnnotationClassWithChangedParameterType.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithChangedParameterType.<init>'")) { getAnnotationClassWithChangedParameterType() }
expectFailure(linkage("Constructor 'AnnotationClassWithChangedParameterType.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithChangedParameterType.<init>'")) { getAnnotationClassWithChangedParameterTypeInline() }
expectFailure(linkage("Constructor 'AnnotationClassWithChangedParameterType.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithChangedParameterType.<init>'")) { getAnnotationClassWithChangedParameterTypeAsAny() }
expectFailure(linkage("Constructor 'AnnotationClassWithChangedParameterType.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithChangedParameterType.<init>'")) { getAnnotationClassWithChangedParameterTypeAsAnyInline() }
expectSuccess(105) { getAnnotationClassThatBecomesRegularClass().x }
expectSuccess(106) { getAnnotationClassThatBecomesRegularClassInline().x }
expectSuccess("AnnotationClassThatBecomesRegularClass[x=107]") { getAnnotationClassThatBecomesRegularClassAsAny().toString() }
expectSuccess("AnnotationClassThatBecomesRegularClass[x=108]") { getAnnotationClassThatBecomesRegularClassAsAnyInline().toString() }
expectFailure(linkage("Function 'getAnnotationClassWithParameterThatBecomesRegularClass' can not be called: Function uses annotation class 'AnnotationClassWithParameterThatBecomesRegularClass' that has non-annotation class 'AnnotationClassThatBecomesRegularClass' as a parameter")) { getAnnotationClassWithParameterThatBecomesRegularClass().x.x }
expectFailure(linkage("Function 'getAnnotationClassWithParameterThatBecomesRegularClassInline' can not be called: Function uses annotation class 'AnnotationClassWithParameterThatBecomesRegularClass' that has non-annotation class 'AnnotationClassThatBecomesRegularClass' as a parameter")) { getAnnotationClassWithParameterThatBecomesRegularClassInline().x.x }
expectFailure(linkage("Constructor 'AnnotationClassWithParameterThatBecomesRegularClass.<init>' can not be called: Annotation class 'AnnotationClassWithParameterThatBecomesRegularClass' uses non-annotation class 'AnnotationClassThatBecomesRegularClass' as a parameter")) { getAnnotationClassWithParameterThatBecomesRegularClassAsAny().toString() }
expectFailure(linkage("Constructor 'AnnotationClassWithParameterThatBecomesRegularClass.<init>' can not be called: Annotation class 'AnnotationClassWithParameterThatBecomesRegularClass' uses non-annotation class 'AnnotationClassThatBecomesRegularClass' as a parameter")) { getAnnotationClassWithParameterThatBecomesRegularClassAsAnyInline().toString() }
expectFailure(linkage("Function 'getAnnotationClassWithParameterOfParameterThatBecomesRegularClass' can not be called: Function uses annotation class 'AnnotationClassWithParameterThatBecomesRegularClass' (via annotation class 'AnnotationClassWithParameterOfParameterThatBecomesRegularClass') that has non-annotation class 'AnnotationClassThatBecomesRegularClass' as a parameter")) { getAnnotationClassWithParameterOfParameterThatBecomesRegularClass().x.x.x }
expectFailure(linkage("Function 'getAnnotationClassWithParameterOfParameterThatBecomesRegularClassInline' can not be called: Function uses annotation class 'AnnotationClassWithParameterThatBecomesRegularClass' (via annotation class 'AnnotationClassWithParameterOfParameterThatBecomesRegularClass') that has non-annotation class 'AnnotationClassThatBecomesRegularClass' as a parameter")) { getAnnotationClassWithParameterOfParameterThatBecomesRegularClassInline().x.x.x }
expectFailure(linkage("Constructor 'AnnotationClassWithParameterThatBecomesRegularClass.<init>' can not be called: Annotation class 'AnnotationClassWithParameterThatBecomesRegularClass' uses non-annotation class 'AnnotationClassThatBecomesRegularClass' as a parameter")) { getAnnotationClassWithParameterOfParameterThatBecomesRegularClassAsAny().toString() }
expectFailure(linkage("Constructor 'AnnotationClassWithParameterThatBecomesRegularClass.<init>' can not be called: Annotation class 'AnnotationClassWithParameterThatBecomesRegularClass' uses non-annotation class 'AnnotationClassThatBecomesRegularClass' as a parameter")) { getAnnotationClassWithParameterOfParameterThatBecomesRegularClassAsAnyInline().toString() }
expectFailure(linkage("Function 'getAnnotationClassThatDisappears' can not be called: Function uses unlinked class symbol '/AnnotationClassThatDisappears'")) { getAnnotationClassThatDisappears() }
expectFailure(linkage("Function 'getAnnotationClassThatDisappearsInline' can not be called: Function uses unlinked class symbol '/AnnotationClassThatDisappears'")) { getAnnotationClassThatDisappearsInline() }
expectFailure(linkage("Constructor 'AnnotationClassThatDisappears.<init>' can not be called: No constructor found for symbol '/AnnotationClassThatDisappears.<init>'")) { getAnnotationClassThatDisappearsAsAny() }
expectFailure(linkage("Constructor 'AnnotationClassThatDisappears.<init>' can not be called: No constructor found for symbol '/AnnotationClassThatDisappears.<init>'")) { getAnnotationClassThatDisappearsAsAnyInline() }
expectFailure(linkage("Function 'getAnnotationClassWithParameterThatDisappears' can not be called: Function uses unlinked class symbol '/AnnotationClassThatDisappears' (via annotation class 'AnnotationClassWithParameterThatDisappears')")) { getAnnotationClassWithParameterThatDisappears() }
expectFailure(linkage("Function 'getAnnotationClassWithParameterThatDisappearsInline' can not be called: Function uses unlinked class symbol '/AnnotationClassThatDisappears' (via annotation class 'AnnotationClassWithParameterThatDisappears')")) { getAnnotationClassWithParameterThatDisappearsInline() }
expectFailure(linkage("Function 'getAnnotationClassWithParameterOfParameterThatDisappears' can not be called: Function uses unlinked class symbol '/AnnotationClassThatDisappears' (via annotation class 'AnnotationClassWithParameterOfParameterThatDisappears')")) { getAnnotationClassWithParameterOfParameterThatDisappears() }
expectFailure(linkage("Function 'getAnnotationClassWithParameterOfParameterThatDisappearsInline' can not be called: Function uses unlinked class symbol '/AnnotationClassThatDisappears' (via annotation class 'AnnotationClassWithParameterOfParameterThatDisappears')")) { getAnnotationClassWithParameterOfParameterThatDisappearsInline() }
expectFailure(linkage("Constructor 'AnnotationClassThatDisappears.<init>' can not be called: No constructor found for symbol '/AnnotationClassThatDisappears.<init>'")) { getAnnotationClassWithParameterThatDisappearsAsAny() }
expectFailure(linkage("Constructor 'AnnotationClassThatDisappears.<init>' can not be called: No constructor found for symbol '/AnnotationClassThatDisappears.<init>'")) { getAnnotationClassWithParameterThatDisappearsAsAnyInline() }
expectSuccess("@AnnotationClassWithRenamedParameters(xi=129, xs=Banana)") { getAnnotationClassWithRenamedParameters().toString() }
expectSuccess("@AnnotationClassWithRenamedParameters(xi=130, xs=Pear)") { getAnnotationClassWithRenamedParametersInline().toString() }
expectSuccess("@AnnotationClassWithRenamedParameters(xi=131, xs=Orange)") { getAnnotationClassWithRenamedParametersAsAny().toString() }
expectSuccess("@AnnotationClassWithRenamedParameters(xi=132, xs=Peach)") { getAnnotationClassWithRenamedParametersAsAnyInline().toString() }
expectFailure(linkage("Constructor 'AnnotationClassWithReorderedParameters.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithReorderedParameters.<init>'")) { getAnnotationClassWithReorderedParameters() }
expectFailure(linkage("Constructor 'AnnotationClassWithReorderedParameters.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithReorderedParameters.<init>'")) { getAnnotationClassWithReorderedParametersInline() }
expectFailure(linkage("Constructor 'AnnotationClassWithReorderedParameters.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithReorderedParameters.<init>'")) { getAnnotationClassWithReorderedParametersAsAny() }
expectFailure(linkage("Constructor 'AnnotationClassWithReorderedParameters.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithReorderedParameters.<init>'")) { getAnnotationClassWithReorderedParametersAsAnyInline() }
expectFailure(linkage("Constructor 'AnnotationClassWithNewParameter.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithNewParameter.<init>'")) { getAnnotationClassWithNewParameter() }
expectFailure(linkage("Constructor 'AnnotationClassWithNewParameter.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithNewParameter.<init>'")) { getAnnotationClassWithNewParameterInline() }
expectFailure(linkage("Constructor 'AnnotationClassWithNewParameter.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithNewParameter.<init>'")) { getAnnotationClassWithNewParameterAsAny() }
expectFailure(linkage("Constructor 'AnnotationClassWithNewParameter.<init>' can not be called: No constructor found for symbol '/AnnotationClassWithNewParameter.<init>'")) { getAnnotationClassWithNewParameterAsAnyInline() }
expectFailure(linkage("Function 'getAnnotationClassWithClassReferenceParameterThatDisappears1' can not be called: Function uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterThatDisappears1')")) { getAnnotationClassWithClassReferenceParameterThatDisappears1() }
expectFailure(linkage("Function 'getAnnotationClassWithClassReferenceParameterThatDisappears1Inline' can not be called: Function uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterThatDisappears1')")) { getAnnotationClassWithClassReferenceParameterThatDisappears1Inline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithClassReferenceParameterThatDisappears1AsAny() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: ${adjustNoClassFoundForLazyIr("/RemovedClass")}")) { getAnnotationClassWithClassReferenceParameterThatDisappears1AsAnyInline() }
expectFailure(linkage("Function 'getAnnotationClassWithDefaultClassReferenceParameterThatDisappears1' can not be called: Function uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterThatDisappears1')")) { getAnnotationClassWithDefaultClassReferenceParameterThatDisappears1() }
expectFailure(linkage("Function 'getAnnotationClassWithDefaultClassReferenceParameterThatDisappears1Inline' can not be called: Function uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterThatDisappears1')")) { getAnnotationClassWithDefaultClassReferenceParameterThatDisappears1Inline() }
expectFailure(linkage("Constructor 'AnnotationClassWithClassReferenceParameterThatDisappears1.<init>' can not be called: Constructor uses unlinked class symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterThatDisappears1AsAny() }
expectFailure(linkage("Constructor 'AnnotationClassWithClassReferenceParameterThatDisappears1.<init>' can not be called: Constructor uses unlinked class symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterThatDisappears1AsAnyInline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithClassReferenceParameterThatDisappears2() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: ${adjustNoClassFoundForLazyIr("/RemovedClass")}")) { getAnnotationClassWithClassReferenceParameterThatDisappears2Inline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithClassReferenceParameterThatDisappears2AsAny() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: ${adjustNoClassFoundForLazyIr("/RemovedClass")}")) { getAnnotationClassWithClassReferenceParameterThatDisappears2AsAnyInline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterThatDisappears2() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterThatDisappears2Inline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterThatDisappears2AsAny() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterThatDisappears2AsAnyInline() }
expectFailure(linkage("Function 'getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1' can not be called: Function uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterOfParameterThatDisappears1')")) { getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1() }
expectFailure(linkage("Function 'getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1Inline' can not be called: Function uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterOfParameterThatDisappears1')")) { getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1Inline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1AsAny() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: ${adjustNoClassFoundForLazyIr("/RemovedClass")}")) { getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1AsAnyInline() }
expectFailure(linkage("Function 'getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1' can not be called: Function uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterOfParameterThatDisappears1')")) { getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1() }
expectFailure(linkage("Function 'getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1Inline' can not be called: Function uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterOfParameterThatDisappears1')")) { getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1Inline() }
expectFailure(linkage("Constructor 'AnnotationClassWithClassReferenceParameterOfParameterThatDisappears1.<init>' can not be called: Constructor uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterThatDisappears1')")) { getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1AsAny() }
expectFailure(linkage("Constructor 'AnnotationClassWithClassReferenceParameterOfParameterThatDisappears1.<init>' can not be called: Constructor uses unlinked class symbol '/RemovedClass' (via annotation class 'AnnotationClassWithClassReferenceParameterThatDisappears1')")) { getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1AsAnyInline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears2() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: ${adjustNoClassFoundForLazyIr("/RemovedClass")}")) { getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears2Inline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears2AsAny() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: ${adjustNoClassFoundForLazyIr("/RemovedClass")}")) { getAnnotationClassWithClassReferenceParameterOfParameterThatDisappears2AsAnyInline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears2() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears2Inline() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears2AsAny() }
expectFailure(linkage("Reference to class 'RemovedClass' can not be evaluated: No class found for symbol '/RemovedClass'")) { getAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears2AsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithRemovedEnumEntryParameter() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithRemovedEnumEntryParameterInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithRemovedEnumEntryParameterAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithRemovedEnumEntryParameterAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithDefaultRemovedEnumEntryParameter() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithDefaultRemovedEnumEntryParameterInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithDefaultRemovedEnumEntryParameterAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithDefaultRemovedEnumEntryParameterAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithRemovedEnumEntryParameterOfParameter() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithRemovedEnumEntryParameterOfParameterInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithRemovedEnumEntryParameterOfParameterAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithRemovedEnumEntryParameterOfParameterAsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithDefaultRemovedEnumEntryParameterOfParameter() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithDefaultRemovedEnumEntryParameterOfParameterInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithDefaultRemovedEnumEntryParameterOfParameterAsAny() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassWithDisappearingEntry.REMOVED': No enum entry found for symbol '/EnumClassWithDisappearingEntry.REMOVED'")) { getAnnotationClassWithDefaultRemovedEnumEntryParameterOfParameterAsAnyInline() }
expectFailure(linkage("Constructor 'AnnotationClassThatBecomesPrivate.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate1() }
expectFailure(linkage("Constructor 'AnnotationClassThatBecomesPrivate.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate1Inline() }
expectFailure(linkage("Constructor 'AnnotationClassThatBecomesPrivate.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate1AsAny() }
expectFailure(linkage("Constructor 'AnnotationClassThatBecomesPrivate.<init>' can not be called: Private constructor declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate1AsAnyInline() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate2() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate2Inline() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate2AsAny() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate2AsAnyInline() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate2() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate2Inline() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate2AsAny() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate2AsAnyInline() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate3() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate3Inline() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate3AsAny() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate3AsAnyInline() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate3() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate3Inline() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate3AsAny() }
expectFailure(linkage("Reference to class 'ClassThatBecomesPrivate' can not be evaluated: Private class declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate3AsAnyInline() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassThatBecomesPrivate.ENTRY': Private enum entry declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate4().toString() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassThatBecomesPrivate.ENTRY': Private enum entry declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate4Inline().toString() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassThatBecomesPrivate.ENTRY': Private enum entry declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate4AsAny().toString() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassThatBecomesPrivate.ENTRY': Private enum entry declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterThatBecomesPrivate4AsAnyInline().toString() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassThatBecomesPrivate.ENTRY': Private enum entry declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate4().toString() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassThatBecomesPrivate.ENTRY': Private enum entry declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate4Inline().toString() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassThatBecomesPrivate.ENTRY': Private enum entry declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate4AsAny().toString() }
expectFailure(linkage("Can not get instance of singleton 'EnumClassThatBecomesPrivate.ENTRY': Private enum entry declared in module <lib1> can not be accessed in module <lib2>")) { getAnnotationClassWithParameterOfParameterThatBecomesPrivate4AsAnyInline().toString() }
expectSuccess { getAnnotationClassWithParameterWithPrivateDefaultValue(); "OK" }
expectSuccess { getAnnotationClassWithParameterWithPrivateDefaultValueInline(); "OK" }
expectSuccess { getAnnotationClassWithParameterWithPrivateDefaultValueAsAny(); "OK" }
expectSuccess { getAnnotationClassWithParameterWithPrivateDefaultValueInlineAsAny(); "OK" }
expectSuccess { getAnnotationClassWithParameterOfParameterWithPrivateDefaultValue(); "OK" }
expectSuccess { getAnnotationClassWithParameterOfParameterWithPrivateDefaultValueInline(); "OK" }
expectSuccess { getAnnotationClassWithParameterOfParameterWithPrivateDefaultValueAsAny(); "OK" }
expectSuccess { getAnnotationClassWithParameterOfParameterWithPrivateDefaultValueInlineAsAny(); "OK" }
// Handle unlinked constructor call in annotation & non-annotation class appearing in annotation:
expectSuccess("HolderOfAnnotationClassWithChangedParameterType") { getHolderOfAnnotationClassWithChangedParameterType().toString() }
expectSuccess("HolderOfAnnotationClassWithChangedParameterType") { getHolderOfAnnotationClassWithChangedParameterTypeInline().toString() }
expectSuccess("HolderOfAnnotationClassThatBecomesRegularClass") { getHolderOfAnnotationClassThatBecomesRegularClass().toString() }
expectSuccess("HolderOfAnnotationClassThatBecomesRegularClass") { getHolderOfAnnotationClassThatBecomesRegularClassInline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesRegularClass") { getHolderOfAnnotationClassWithParameterThatBecomesRegularClass().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesRegularClass") { getHolderOfAnnotationClassWithParameterThatBecomesRegularClassInline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatBecomesRegularClass") { getHolderOfAnnotationClassWithParameterOfParameterThatBecomesRegularClass().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatBecomesRegularClass") { getHolderOfAnnotationClassWithParameterOfParameterThatBecomesRegularClassInline().toString() }
expectSuccess("HolderOfAnnotationClassThatDisappears") { getHolderOfAnnotationClassThatDisappears().toString() }
expectSuccess("HolderOfAnnotationClassThatDisappears") { getHolderOfAnnotationClassThatDisappearsInline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatDisappears") { getHolderOfAnnotationClassWithParameterThatDisappears().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatDisappears") { getHolderOfAnnotationClassWithParameterThatDisappearsInline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatDisappears") { getHolderOfAnnotationClassWithParameterOfParameterThatDisappears().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatDisappears") { getHolderOfAnnotationClassWithParameterOfParameterThatDisappearsInline().toString() }
expectSuccess("HolderOfAnnotationClassWithRenamedParameters") { getHolderOfAnnotationClassWithRenamedParameters().toString() }
expectSuccess("HolderOfAnnotationClassWithRenamedParameters") { getHolderOfAnnotationClassWithRenamedParametersInline().toString() }
expectSuccess("HolderOfAnnotationClassWithReorderedParameters") { getHolderOfAnnotationClassWithReorderedParameters().toString() }
expectSuccess("HolderOfAnnotationClassWithReorderedParameters") { getHolderOfAnnotationClassWithReorderedParametersInline().toString() }
expectSuccess("HolderOfAnnotationClassWithNewParameter") { getHolderOfAnnotationClassWithNewParameter().toString() }
expectSuccess("HolderOfAnnotationClassWithNewParameter") { getHolderOfAnnotationClassWithNewParameterInline().toString() }
expectSuccess("HolderOfAnnotationClassWithClassReferenceParameterThatDisappears1") { getHolderOfAnnotationClassWithClassReferenceParameterThatDisappears1().toString() }
expectSuccess("HolderOfAnnotationClassWithClassReferenceParameterThatDisappears1") { getHolderOfAnnotationClassWithClassReferenceParameterThatDisappears1Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultClassReferenceParameterThatDisappears1") { getHolderOfAnnotationClassWithDefaultClassReferenceParameterThatDisappears1().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultClassReferenceParameterThatDisappears1") { getHolderOfAnnotationClassWithDefaultClassReferenceParameterThatDisappears1Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithClassReferenceParameterThatDisappears2") { getHolderOfAnnotationClassWithClassReferenceParameterThatDisappears2().toString() }
expectSuccess("HolderOfAnnotationClassWithClassReferenceParameterThatDisappears2") { getHolderOfAnnotationClassWithClassReferenceParameterThatDisappears2Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultClassReferenceParameterThatDisappears2") { getHolderOfAnnotationClassWithDefaultClassReferenceParameterThatDisappears2().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultClassReferenceParameterThatDisappears2") { getHolderOfAnnotationClassWithDefaultClassReferenceParameterThatDisappears2Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1") { getHolderOfAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1().toString() }
expectSuccess("HolderOfAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1") { getHolderOfAnnotationClassWithClassReferenceParameterOfParameterThatDisappears1Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1") { getHolderOfAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1") { getHolderOfAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears1Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithClassReferenceParameterOfParameterThatDisappears2") { getHolderOfAnnotationClassWithClassReferenceParameterOfParameterThatDisappears2().toString() }
expectSuccess("HolderOfAnnotationClassWithClassReferenceParameterOfParameterThatDisappears2") { getHolderOfAnnotationClassWithClassReferenceParameterOfParameterThatDisappears2Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears2") { getHolderOfAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears2().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears2") { getHolderOfAnnotationClassWithDefaultClassReferenceParameterOfParameterThatDisappears2Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithRemovedEnumEntryParameter") { getHolderOfAnnotationClassWithRemovedEnumEntryParameter().toString() }
expectSuccess("HolderOfAnnotationClassWithRemovedEnumEntryParameter") { getHolderOfAnnotationClassWithRemovedEnumEntryParameterInline().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultRemovedEnumEntryParameter") { getHolderOfAnnotationClassWithDefaultRemovedEnumEntryParameter().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultRemovedEnumEntryParameter") { getHolderOfAnnotationClassWithDefaultRemovedEnumEntryParameterInline().toString() }
expectSuccess("HolderOfAnnotationClassWithRemovedEnumEntryParameterOfParameter") { getHolderOfAnnotationClassWithRemovedEnumEntryParameterOfParameter().toString() }
expectSuccess("HolderOfAnnotationClassWithRemovedEnumEntryParameterOfParameter") { getHolderOfAnnotationClassWithRemovedEnumEntryParameterOfParameterInline().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultRemovedEnumEntryParameterOfParameter") { getHolderOfAnnotationClassWithDefaultRemovedEnumEntryParameterOfParameter().toString() }
expectSuccess("HolderOfAnnotationClassWithDefaultRemovedEnumEntryParameterOfParameter") { getHolderOfAnnotationClassWithDefaultRemovedEnumEntryParameterOfParameterInline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesPrivate1") { getHolderOfAnnotationClassWithParameterThatBecomesPrivate1().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesPrivate1") { getHolderOfAnnotationClassWithParameterThatBecomesPrivate1Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesPrivate2") { getHolderOfAnnotationClassWithParameterThatBecomesPrivate2().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesPrivate2") { getHolderOfAnnotationClassWithParameterThatBecomesPrivate2Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate2") { getHolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate2().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate2") { getHolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate2Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesPrivate3") { getHolderOfAnnotationClassWithParameterThatBecomesPrivate3().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesPrivate3") { getHolderOfAnnotationClassWithParameterThatBecomesPrivate3Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate3") { getHolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate3().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate3") { getHolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate3Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesPrivate4") { getHolderOfAnnotationClassWithParameterThatBecomesPrivate4().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterThatBecomesPrivate4") { getHolderOfAnnotationClassWithParameterThatBecomesPrivate4Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate4") { getHolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate4().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate4") { getHolderOfAnnotationClassWithParameterOfParameterThatBecomesPrivate4Inline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterWithPrivateDefaultValue") { getHolderOfAnnotationClassWithParameterWithPrivateDefaultValue().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterWithPrivateDefaultValue") { getHolderOfAnnotationClassWithParameterWithPrivateDefaultValueInline().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterWithPrivateDefaultValue") { getHolderOfAnnotationClassWithParameterOfParameterWithPrivateDefaultValue().toString() }
expectSuccess("HolderOfAnnotationClassWithParameterOfParameterWithPrivateDefaultValue") { getHolderOfAnnotationClassWithParameterOfParameterWithPrivateDefaultValueInline().toString() }
expectSuccess { getValueToClass(); "OK" }
expectSuccess { getValueToClassInline(); "OK" }
expectSuccess { getValueToClassAsAny(); "OK" }
expectSuccess { getValueToClassAsAnyInline(); "OK" }
expectSuccess { getClassToValue(); "OK" }
expectSuccess { getClassToValueInline(); "OK" }
expectSuccess { getClassToValueAsAny(); "OK" }
expectSuccess { getClassToValueAsAnyInline(); "OK" }
expectFailure(linkage("Function 'component1' can not be called: No function found for symbol '/DataToClass.component1'")) { getSumFromDataClass() }
expectFailure(linkage("Constructor 'ClassToAbstractClass.<init>' can not be called: Can not instantiate abstract class 'ClassToAbstractClass'")) { instantiationOfAbstractClass() }
expectSuccess { StableEnum.FOO.test }
expectSuccess { StableEnum.BAR.test }
expectSuccess("01234") { testStableInheritorOfClassThatUsesPrivateTopLevelClass() }
expectSuccess(1) { getFunctionalInterfaceToInterface(1).answer() }
expectSuccess(2) { getFunctionalInterfaceToInterfaceAsObject(2).answer() }
expectSuccess(3) { getFunctionalInterfaceToInterfaceAnswer(3) }
expectSuccess(4) { getFunctionalInterfaceWith0AbstractFunctions(4).answer() }
expectSuccess(5) { getFunctionalInterfaceWith0AbstractFunctionsAsObject(5).answer() }
expectSuccess(6) { getFunctionalInterfaceWith0AbstractFunctionsAnswer(6) }
expectSuccess(7) { getFunctionalInterfaceWith1AbstractFunction(7).answer() }
expectSuccess(8) { getFunctionalInterfaceWith1AbstractFunctionAsObject(8).answer() }
expectSuccess(9) { getFunctionalInterfaceWith1AbstractFunctionAnswer(9) }
expectFailure(linkage("Single abstract method (SAM) conversion expression can not be evaluated: Fun interface 'FunctionalInterfaceWith2AbstractFunctions' has more than one abstract function: 'answer', 'function1'")) { getFunctionalInterfaceWith2AbstractFunctions(10).answer() }
expectSuccess(11) { getFunctionalInterfaceWith2AbstractFunctionsAsObject(11).answer() }
expectFailure(linkage("Single abstract method (SAM) conversion expression can not be evaluated: Fun interface 'FunctionalInterfaceWith2AbstractFunctions' has more than one abstract function: 'answer', 'function1'")) { getFunctionalInterfaceWith2AbstractFunctionsAnswer(12) }
expectFailure(linkage("Single abstract method (SAM) conversion expression can not be evaluated: Fun interface 'FunctionalInterfaceWith3AbstractFunctions' has more than one abstract function: 'answer', 'function1', 'function2'")) { getFunctionalInterfaceWith3AbstractFunctions(13).answer() }
expectSuccess(14) { getFunctionalInterfaceWith3AbstractFunctionsAsObject(14).answer() }
expectFailure(linkage("Single abstract method (SAM) conversion expression can not be evaluated: Fun interface 'FunctionalInterfaceWith3AbstractFunctions' has more than one abstract function: 'answer', 'function1', 'function2'")) { getFunctionalInterfaceWith3AbstractFunctionsAnswer(15) }
expectFailure(linkage("Single abstract method (SAM) conversion expression can not be evaluated: Fun interface 'FunctionalInterfaceWithAbstractProperty' has abstract property 'property1'")) { getFunctionalInterfaceWithAbstractProperty(16).answer() }
expectSuccess(17) { getFunctionalInterfaceWithAbstractPropertyAsObject(17).answer() }
expectFailure(linkage("Single abstract method (SAM) conversion expression can not be evaluated: Fun interface 'FunctionalInterfaceWithAbstractProperty' has abstract property 'property1'")) { getFunctionalInterfaceWithAbstractPropertyAnswer(18) }
}