Generate IR for annotation class constructors.
This commit is contained in:
+35
-11
@@ -1,15 +1,25 @@
|
||||
package ann
|
||||
|
||||
annotation class Test1<T : Any?> : Annotation {
|
||||
constructor(x: Int) /* primary */
|
||||
open annotation class Test1<T : Any?> : Annotation {
|
||||
constructor(x: Int) /* primary */ {
|
||||
super/*Any*/()
|
||||
/* <init>() */
|
||||
|
||||
}
|
||||
|
||||
val x: Int
|
||||
field = x
|
||||
get
|
||||
|
||||
}
|
||||
|
||||
annotation class Test2<T1 : Any, T2 : Any?> : Annotation {
|
||||
constructor(x: Int = 0) /* primary */
|
||||
open annotation class Test2<T1 : Any, T2 : Any?> : Annotation {
|
||||
constructor(x: Int = 0) /* primary */ {
|
||||
super/*Any*/()
|
||||
/* <init>() */
|
||||
|
||||
}
|
||||
|
||||
val x: Int
|
||||
field = x
|
||||
get
|
||||
@@ -20,8 +30,13 @@ interface I<T : Any?> {
|
||||
|
||||
}
|
||||
|
||||
annotation class Test3<T1 : Any?, T2 : I<T1>> : Annotation {
|
||||
constructor(x: Test1<I<T2>>) /* primary */
|
||||
open annotation class Test3<T1 : Any?, T2 : I<T1>> : Annotation {
|
||||
constructor(x: Test1<I<T2>>) /* primary */ {
|
||||
super/*Any*/()
|
||||
/* <init>() */
|
||||
|
||||
}
|
||||
|
||||
val x: Test1<I<T2>>
|
||||
field = x
|
||||
get
|
||||
@@ -37,8 +52,13 @@ class C<T : Any?> : I<T> {
|
||||
|
||||
}
|
||||
|
||||
annotation class Test4 : Annotation {
|
||||
constructor(x: Array<Test3<Int, C<Int>>>) /* primary */
|
||||
open annotation class Test4 : Annotation {
|
||||
constructor(x: Array<Test3<Int, C<Int>>>) /* primary */ {
|
||||
super/*Any*/()
|
||||
/* <init>() */
|
||||
|
||||
}
|
||||
|
||||
val x: Array<Test3<Int, C<Int>>>
|
||||
field = x
|
||||
get
|
||||
@@ -54,8 +74,13 @@ class ARG {
|
||||
|
||||
}
|
||||
|
||||
annotation class Test5<T : Any?> : Annotation {
|
||||
constructor(vararg xs: Test3<T, C<T>>) /* primary */
|
||||
open annotation class Test5<T : Any?> : Annotation {
|
||||
constructor(vararg xs: Test3<T, C<T>>) /* primary */ {
|
||||
super/*Any*/()
|
||||
/* <init>() */
|
||||
|
||||
}
|
||||
|
||||
val xs: Array<out Test3<T, C<T>>>
|
||||
field = xs
|
||||
get
|
||||
@@ -75,4 +100,3 @@ class CC {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user