You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/compiler/checker.ts
+7-4Lines changed: 7 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -10205,10 +10205,13 @@ namespace ts {
10205
10205
if (result = isRelatedTo(getTrueTypeFromConditionalType(<ConditionalType>source), getTrueTypeFromConditionalType(<ConditionalType>target), reportErrors)) {
10206
10206
result &= isRelatedTo(getFalseTypeFromConditionalType(<ConditionalType>source), getFalseTypeFromConditionalType(<ConditionalType>target), reportErrors);
10207
10207
}
10208
-
if (result) {
10209
-
errorInfo = saveErrorInfo;
10210
-
return result;
10211
-
}
10208
+
}
10209
+
else {
10210
+
result = isRelatedTo(getDefaultConstraintOfConditionalType(<ConditionalType>source), getDefaultConstraintOfConditionalType(<ConditionalType>target), reportErrors);
10211
+
}
10212
+
if (result) {
10213
+
errorInfo = saveErrorInfo;
10214
+
return result;
10212
10215
}
10213
10216
}
10214
10217
else if (relation !== definitelyAssignableRelation) {
0 commit comments