New J2K: use PsiModifierListOwner instead of JvmAnnotatedElement for getting annotations from declaration while building AST as PsiLocalVariable is no longer a JvmAnnotatedElement in 192
#KT-31821 fixed
This commit is contained in:
@@ -639,7 +639,7 @@ class JavaToJKTreeBuilder constructor(
|
||||
}
|
||||
}
|
||||
|
||||
fun <T : JvmAnnotatedElement> T.annotationList(docCommentOwner: PsiDocCommentOwner?): JKAnnotationList {
|
||||
fun <T : PsiModifierListOwner> T.annotationList(docCommentOwner: PsiDocCommentOwner?): JKAnnotationList {
|
||||
val plainAnnotations = annotations.map { it.cast<PsiAnnotation>().toJK() }
|
||||
val deprecatedAnnotation = docCommentOwner?.docComment?.deprecatedAnnotation() ?: return JKAnnotationListImpl(plainAnnotations)
|
||||
return JKAnnotationListImpl(
|
||||
|
||||
Reference in New Issue
Block a user