Provide default implementation for Annotations.findExternalAnnotation

This commit is contained in:
Alexander Udalov
2017-07-04 13:28:42 +03:00
parent 5636318eb4
commit 9ee4b39e1b
7 changed files with 2 additions and 18 deletions
@@ -36,8 +36,6 @@ class DeserializedAnnotations(
override fun findAnnotation(fqName: FqName) =
annotations.firstOrNull { annotation -> annotation.annotationClass?.fqNameUnsafe == fqName.toUnsafe() }
override fun findExternalAnnotation(fqName: FqName) = null
override fun getUseSiteTargetedAnnotations(): List<AnnotationWithTarget> = emptyList()
override fun getAllAnnotations(): List<AnnotationWithTarget> = annotations.map { AnnotationWithTarget(it, null) }
@@ -58,8 +56,6 @@ class DeserializedAnnotationsWithPossibleTargets(
target == null && annotation.annotationClass?.fqNameUnsafe == fqName.toUnsafe()
}?.annotation
override fun findExternalAnnotation(fqName: FqName) = null
override fun getUseSiteTargetedAnnotations(): List<AnnotationWithTarget> = annotations.filter { it.target != null }
override fun getAllAnnotations(): List<AnnotationWithTarget> = annotations