6ca7b39f6a
This is not an ideal fix of the problem since the fact that
AbbreviatedType's classifier should be a TypeAliasDescriptor is a
reasonable assumption that might fail somewhere else, later in the
pipeline.
Previous attempts to fix this issue that were unsuccessful:
1) Do not load abbreviations for such types in deserialization at all.
Unfortunately, it broke quite a few things like reflection and
decompiler, where types frequently refer to symbols not reachable
from the point where they're requested, yet we have the FQ name of
the typealias, which is enough to render the abbreviation properly in
both these use cases.
2) Load classifiers for unresolved abbreviations as
MockTypeAliasDescriptor instead of MockClassDescriptor in
NotFoundClasses. Technically this was a revert of
e19c1b5364. But this failed because we
don't have enough information about such typealias to correctly set
its `expandedType`/`underlyingType` (just using nullable Any as
before that commit is not good enough). We only know its underlying
class (from one usage of such typealias), and even supporting that
would involve a major refactoring of TypeDeserializer which is
painful.
#KT-45308 Fixed