(types, includes)
| 61469 | return includes; |
| 61470 | } |
| 61471 | function removeRedundantPrimitiveTypes(types, includes) { |
| 61472 | var i = types.length; |
| 61473 | while (i > 0) { |
| 61474 | i--; |
| 61475 | var t = types[i]; |
| 61476 | var remove = t.flags & 4 /* TypeFlags.String */ && includes & (128 /* TypeFlags.StringLiteral */ | 134217728 /* TypeFlags.TemplateLiteral */ | 268435456 /* TypeFlags.StringMapping */) || |
| 61477 | t.flags & 8 /* TypeFlags.Number */ && includes & 256 /* TypeFlags.NumberLiteral */ || |
| 61478 | t.flags & 64 /* TypeFlags.BigInt */ && includes & 2048 /* TypeFlags.BigIntLiteral */ || |
| 61479 | t.flags & 4096 /* TypeFlags.ESSymbol */ && includes & 8192 /* TypeFlags.UniqueESSymbol */; |
| 61480 | if (remove) { |
| 61481 | ts.orderedRemoveItemAt(types, i); |
| 61482 | } |
| 61483 | } |
| 61484 | } |
| 61485 | // Check that the given type has a match in every union. A given type is matched by |
| 61486 | // an identical type, and a literal type is additionally matched by its corresponding |
| 61487 | // primitive type. |
no outgoing calls
no test coverage detected