(left, right)
| 58231 | return params; |
| 58232 | } |
| 58233 | function combineSignaturesOfUnionMembers(left, right) { |
| 58234 | var typeParams = left.typeParameters || right.typeParameters; |
| 58235 | var paramMapper; |
| 58236 | if (left.typeParameters && right.typeParameters) { |
| 58237 | paramMapper = createTypeMapper(right.typeParameters, left.typeParameters); |
| 58238 | // We just use the type parameter defaults from the first signature |
| 58239 | } |
| 58240 | var declaration = left.declaration; |
| 58241 | var params = combineUnionParameters(left, right, paramMapper); |
| 58242 | var thisParam = combineUnionThisParam(left.thisParameter, right.thisParameter, paramMapper); |
| 58243 | var minArgCount = Math.max(left.minArgumentCount, right.minArgumentCount); |
| 58244 | var result = createSignature(declaration, typeParams, thisParam, params, |
| 58245 | /*resolvedReturnType*/ undefined, |
| 58246 | /*resolvedTypePredicate*/ undefined, minArgCount, (left.flags | right.flags) & 39 /* SignatureFlags.PropagatingFlags */); |
| 58247 | result.compositeKind = 1048576 /* TypeFlags.Union */; |
| 58248 | result.compositeSignatures = ts.concatenate(left.compositeKind !== 2097152 /* TypeFlags.Intersection */ && left.compositeSignatures || [left], [right]); |
| 58249 | if (paramMapper) { |
| 58250 | result.mapper = left.compositeKind !== 2097152 /* TypeFlags.Intersection */ && left.mapper && left.compositeSignatures ? combineTypeMappers(left.mapper, paramMapper) : paramMapper; |
| 58251 | } |
| 58252 | return result; |
| 58253 | } |
| 58254 | function getUnionIndexInfos(types) { |
| 58255 | var sourceInfos = getIndexInfosOfType(types[0]); |
| 58256 | if (sourceInfos) { |
no test coverage detected