More accurate check of repeated use-site annotations #KT-13859 Fixed

This commit is contained in:
Mikhail Glukhikh
2016-12-22 20:04:57 +03:00
parent 778289fefe
commit 5f3c1dfc41
5 changed files with 91 additions and 9 deletions
@@ -10,4 +10,12 @@ annotation class ann(val y: Int)
@ann(0) <!REPEATED_ANNOTATION!>@ann(1)<!> fun foo(@ann(7) <!REPEATED_ANNOTATION!>@ann(2)<!> x: Int): Int {
@annexpr <!REPEATED_ANNOTATION!>@annexpr<!> return x
}
}
@unrepann(0)
@get:unrepann(1)
var annotated = 1 // No errors should be here
@unrepann(0)
<!REPEATED_ANNOTATION!>@property:unrepann(1)<!>
var annotated2 = 2
@@ -1,5 +1,7 @@
package
@unrepann(x = 0) public var annotated: kotlin.Int
@unrepann(x = 0) @property:unrepann(x = 1) public var annotated2: kotlin.Int
@ann(y = 0) @ann(y = 1) public fun foo(/*0*/ @ann(y = 7) @ann(y = 2) x: kotlin.Int): kotlin.Int
@unrepann(x = 1) @unrepann(x = 2) public final class DoubleAnnotated {