We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 454b428 commit 5a567adCopy full SHA for 5a567ad
src/compiler/checker.ts
@@ -10383,7 +10383,7 @@ namespace ts {
10383
// We attempt to resolve the conditional type only when the check and extends types are non-generic
10384
if (!checkTypeInstantiable && !maybeTypeOfKind(inferredExtendsType, TypeFlags.Instantiable | TypeFlags.GenericMappedType)) {
10385
if (inferredExtendsType.flags & TypeFlags.AnyOrUnknown) {
10386
- return trueType;
+ return instantiateType(root.trueType, combinedMapper || mapper);
10387
}
10388
// Return union of trueType and falseType for 'any' since it matches anything
10389
if (checkType.flags & TypeFlags.Any) {
0 commit comments