File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -13287,11 +13287,8 @@ namespace ts {
13287
13287
}
13288
13288
13289
13289
function getVariances(type: GenericType): Variance[] {
13290
- if (!strictFunctionTypes) {
13291
- return emptyArray;
13292
- }
13293
- if (type === globalArrayType || type === globalReadonlyArrayType) {
13294
- // Arrays are known to be covariant, no need to spend time computing this (emptyArray implies covariance for all parameters)
13290
+ // Arrays and tuples are known to be covariant, no need to spend time computing this (emptyArray implies covariance for all parameters)
13291
+ if (!strictFunctionTypes || type === globalArrayType || type === globalReadonlyArrayType || type.objectFlags & ObjectFlags.Tuple) {
13295
13292
return emptyArray;
13296
13293
}
13297
13294
return getVariancesWorker(type.typeParameters, type, getMarkerTypeReference);
You can’t perform that action at this time.
0 commit comments