Report error if repeated annotation is used with JVM target 1.6

#KT-12794
This commit is contained in:
Alexander Udalov
2021-07-23 22:30:27 +02:00
parent 26043f3968
commit b2550f69bc
12 changed files with 217 additions and 8 deletions
@@ -199,7 +199,9 @@ fun ValueParameterDescriptor.declaresOrInheritsDefaultValue(): Boolean {
)
}
fun Annotated.isRepeatableAnnotation(): Boolean =
// Note that on JVM, an annotation class is also considered repeatable if it's annotated with java.lang.annotation.Repeatable.
// See JvmPlatformAnnotationFeaturesSupport.
fun Annotated.isAnnotatedWithKotlinRepeatable(): Boolean =
annotations.findAnnotation(StandardNames.FqNames.repeatable) != null
fun Annotated.isDocumentedAnnotation(): Boolean =