Suppress TOPLEVEL_TYPEALIASES_ONLY in decompiler and stubBuilder tests.

This commit is contained in:
Dmitry Petrov
2016-11-23 19:39:55 +03:00
parent 03bbe875d4
commit f415050913
4 changed files with 24 additions and 3 deletions
@@ -4,9 +4,10 @@
package test
public final class TypeAliases public constructor() {
public final fun foo(a: dependency.A /* = () -> kotlin.Unit */, b: test.TypeAliases.B /* = (dependency.A /* = () -> kotlin.Unit */) -> kotlin.Unit */, ta: test.Outer<kotlin.String, kotlin.Double>.Inner<kotlin.Int>.TA<kotlin.Boolean> /* = kotlin.collections.Map<kotlin.collections.Map<kotlin.String, out kotlin.Double>, kotlin.collections.Map<kotlin.Int, out kotlin.Boolean>> */): kotlin.Unit { /* compiled code */ }
public final fun foo(a: dependency.A /* = () -> kotlin.Unit */, b: test.TypeAliases.B /* = (dependency.A /* = () -> kotlin.Unit */) -> kotlin.Unit */, ta: test.Outer<kotlin.String, kotlin.Double>.Inner<kotlin.Int>.TA<kotlin.Boolean> /* = kotlin.collections.Map<kotlin.collections.Map<kotlin.String, kotlin.Double>, kotlin.collections.Map<kotlin.Int, kotlin.Boolean>> */): kotlin.Unit { /* compiled code */ }
public typealias B = (dependency.A) -> kotlin.Unit
@kotlin.Suppress public typealias B = (dependency.A) -> kotlin.Unit
@test.Ann private typealias Parametrized<E, F> = kotlin.collections.Map<E, F>
@test.Ann @kotlin.Suppress private typealias Parametrized<E, F> = kotlin.collections.Map<E, F>
}
@@ -5,6 +5,7 @@ import kotlin.annotation.AnnotationTarget
class Outer<E, F> {
inner class Inner<G> {
@Suppress("TOPLEVEL_TYPEALIASES_ONLY")
typealias TA<H> = Map<Map<E, F>, Map<G, H>>
}
}
@@ -14,6 +15,7 @@ annotation class Ann(val value: String)
class TypeAliases {
@Suppress("TOPLEVEL_TYPEALIASES_ONLY")
typealias B = (A) -> Unit
fun foo(a: A, b: B, ta: Outer<String, Double>.Inner<Int>.TA<Boolean>) {
@@ -21,5 +23,6 @@ class TypeAliases {
}
@Ann("OK")
@Suppress("TOPLEVEL_TYPEALIASES_ONLY")
private typealias Parametrized<E, F> = Map<E, F>
}
@@ -5,6 +5,7 @@ import kotlin.annotation.AnnotationTarget
class Outer<E, F> {
inner class Inner<G> {
@Suppress("TOPLEVEL_TYPEALIASES_ONLY")
typealias TA<H> = Map<Map<E, F>, Map<G, H>>
}
}
@@ -14,6 +15,7 @@ annotation class Ann
class TypeAliases {
@Suppress("TOPLEVEL_TYPEALIASES_ONLY")
typealias B = (A) -> Unit
fun foo(a: A, b: B, ta: Outer<String, Double>.Inner<Int>.TA<Boolean>) {
@@ -21,5 +23,6 @@ class TypeAliases {
}
@Ann
@Suppress("TOPLEVEL_TYPEALIASES_ONLY")
private typealias Parametrized<E, F> = Map<E, F>
}
@@ -69,6 +69,13 @@ PsiJetFileStubImpl[package=test]
REFERENCE_EXPRESSION[referencedName=Unit]
TYPEALIAS[fqName=test.TypeAliases.B, isTopLevel=false, name=B]
MODIFIER_LIST[public]
ANNOTATION_ENTRY[hasValueArguments=false, shortName=Suppress]
CONSTRUCTOR_CALLEE
TYPE_REFERENCE
USER_TYPE
USER_TYPE
REFERENCE_EXPRESSION[referencedName=kotlin]
REFERENCE_EXPRESSION[referencedName=Suppress]
TYPE_REFERENCE
FUNCTION_TYPE
VALUE_PARAMETER_LIST
@@ -92,6 +99,13 @@ PsiJetFileStubImpl[package=test]
USER_TYPE
REFERENCE_EXPRESSION[referencedName=test]
REFERENCE_EXPRESSION[referencedName=Ann]
ANNOTATION_ENTRY[hasValueArguments=false, shortName=Suppress]
CONSTRUCTOR_CALLEE
TYPE_REFERENCE
USER_TYPE
USER_TYPE
REFERENCE_EXPRESSION[referencedName=kotlin]
REFERENCE_EXPRESSION[referencedName=Suppress]
TYPE_PARAMETER_LIST
TYPE_PARAMETER[fqName=null, isInVariance=false, isOutVariance=false, name=E]
TYPE_PARAMETER[fqName=null, isInVariance=false, isOutVariance=false, name=F]