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 f33a6a6 commit ae470a1Copy full SHA for ae470a1
src/compiler/checker.ts
@@ -39329,6 +39329,13 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
39329
}
39330
39331
39332
+ if (type.flags & TypeFlags.TypeParameter) {
39333
+ // The type could be upper-bounded by (a subtype of) the kind.
39334
+ const upperBound = getConstraintOfType(type);
39335
+ if (upperBound !== undefined && maybeTypeOfKind(upperBound, kind)) {
39336
+ return true;
39337
+ }
39338
39339
return false;
39340
39341
0 commit comments