(type)
| 58929 | return undefined; |
| 58930 | } |
| 58931 | function getBaseConstraintOfType(type) { |
| 58932 | if (type.flags & (58982400 /* TypeFlags.InstantiableNonPrimitive */ | 3145728 /* TypeFlags.UnionOrIntersection */ | 134217728 /* TypeFlags.TemplateLiteral */ | 268435456 /* TypeFlags.StringMapping */)) { |
| 58933 | var constraint = getResolvedBaseConstraint(type); |
| 58934 | return constraint !== noConstraintType && constraint !== circularConstraintType ? constraint : undefined; |
| 58935 | } |
| 58936 | return type.flags & 4194304 /* TypeFlags.Index */ ? keyofConstraintType : undefined; |
| 58937 | } |
| 58938 | /** |
| 58939 | * This is similar to `getBaseConstraintOfType` except it returns the input type if there's no base constraint, instead of `undefined` |
| 58940 | * It also doesn't map indexes to `string`, as where this is used this would be unneeded (and likely undesirable) |
no test coverage detected
searching dependent graphs…