From 7e64054af761213a0ec638124ff01b9b13cd6f47 Mon Sep 17 00:00:00 2001 From: Dmitry Petrov Date: Fri, 3 Jun 2016 15:10:23 +0300 Subject: [PATCH] typeConstraintAdditionalResolve: do not throw CCE for incorrect code with type parameter bounds on type alias parameters --- .../org/jetbrains/kotlin/idea/project/ResolveElementCache.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/idea/idea-analysis/src/org/jetbrains/kotlin/idea/project/ResolveElementCache.kt b/idea/idea-analysis/src/org/jetbrains/kotlin/idea/project/ResolveElementCache.kt index e608ece0318..d47ce75c7ee 100644 --- a/idea/idea-analysis/src/org/jetbrains/kotlin/idea/project/ResolveElementCache.kt +++ b/idea/idea-analysis/src/org/jetbrains/kotlin/idea/project/ResolveElementCache.kt @@ -352,7 +352,7 @@ class ResolveElementCache( private fun typeConstraintAdditionalResolve(analyzer: KotlinCodeAnalyzer, jetTypeConstraint: KtTypeConstraint): BindingTrace { val declaration = jetTypeConstraint.getParentOfType(true)!! - val descriptor = analyzer.resolveToDescriptor(declaration) as ClassDescriptor + val descriptor = analyzer.resolveToDescriptor(declaration) as ClassifierDescriptorWithTypeParameters for (parameterDescriptor in descriptor.declaredTypeParameters) { ForceResolveUtil.forceResolveAllContents(parameterDescriptor)