Allow to run additional resolve from KtFileAnnotationList

This commit is contained in:
Nikolay Krasko
2015-12-14 15:22:45 +03:00
committed by Nikolay Krasko
parent 0aa8d89b16
commit 5cd23daf4e
2 changed files with 36 additions and 0 deletions
@@ -225,6 +225,10 @@ public class ResolveElementCache(
return element
}
if (element is KtFileAnnotationList) {
return element
}
return null
}
@@ -279,6 +283,16 @@ public class ResolveElementCache(
resolveSession.trace
}
is KtFileAnnotationList -> {
val annotationEntry = resolveElement.annotationEntries.firstOrNull()
if (annotationEntry != null) {
annotationAdditionalResolve(resolveSession, annotationEntry)
}
else {
resolveSession.trace
}
}
is KtAnnotationEntry -> annotationAdditionalResolve(resolveSession, resolveElement)
is KtClass -> constructorAdditionalResolve(resolveSession, resolveElement, file)