diff --git a/compiler/frontend.java/src/org/jetbrains/kotlin/load/java/structure/impl/annotationArgumentsImpl.kt b/compiler/frontend.java/src/org/jetbrains/kotlin/load/java/structure/impl/annotationArgumentsImpl.kt index 9162925e792..27fdf2a2c6e 100644 --- a/compiler/frontend.java/src/org/jetbrains/kotlin/load/java/structure/impl/annotationArgumentsImpl.kt +++ b/compiler/frontend.java/src/org/jetbrains/kotlin/load/java/structure/impl/annotationArgumentsImpl.kt @@ -26,6 +26,9 @@ abstract class JavaAnnotationArgumentImpl( class object { fun create(argument: PsiAnnotationMemberValue, name: Name?): JavaAnnotationArgument { val value = JavaPsiFacade.getInstance(argument.getProject()).getConstantEvaluationHelper().computeConstantExpression(argument) + if (value is Enum<*>) { + return JavaEnumValueAnnotationArgumentImpl(argument as PsiReferenceExpression, name) + } if (value != null || argument is PsiLiteralExpression) { return JavaLiteralAnnotationArgumentImpl(name, value) }