Do not create KotlinTypeImpl with error scope while erasing

See assertion in KotlinTypeImpl init block
This commit is contained in:
Denis Zharkov
2015-11-30 19:08:19 +03:00
parent e2b51f30ed
commit 8838e46578
4 changed files with 37 additions and 0 deletions
@@ -114,6 +114,8 @@ internal object RawSubstitution : TypeSubstitution() {
)
}
if (type.isError) return ErrorUtils.createErrorType("Raw error type: ${type.constructor}")
val constructor = type.constructor
return KotlinTypeImpl.create(
type.annotations, constructor, type.isMarkedNullable,