@@ -4494,7 +4494,6 @@ namespace ts {
44944494 function resolveMappedTypeMembers(type: MappedType) {
44954495 const members: SymbolTable = createMap<Symbol>();
44964496 let stringIndexInfo: IndexInfo;
4497- let numberIndexInfo: IndexInfo;
44984497 // Resolve upfront such that recursive references see an empty object type.
44994498 setStructuredTypeMembers(type, emptySymbols, emptyArray, emptyArray, undefined, undefined);
45004499 // In { [P in K]: T }, we refer to P as the type parameter type, K as the constraint type,
@@ -4529,16 +4528,8 @@ namespace ts {
45294528 else if (t.flags & TypeFlags.String) {
45304529 stringIndexInfo = createIndexInfo(propType, isReadonly);
45314530 }
4532- else if (t.flags & TypeFlags.Number) {
4533- numberIndexInfo = createIndexInfo(propType, isReadonly);
4534- }
45354531 });
4536- // If we created both a string and a numeric string index signature, and if the two index
4537- // signatures have identical types, discard the redundant numeric index signature.
4538- if (stringIndexInfo && numberIndexInfo && isTypeIdenticalTo(stringIndexInfo.type, numberIndexInfo.type)) {
4539- numberIndexInfo = undefined;
4540- }
4541- setStructuredTypeMembers(type, members, emptyArray, emptyArray, stringIndexInfo, numberIndexInfo);
4532+ setStructuredTypeMembers(type, members, emptyArray, emptyArray, stringIndexInfo, undefined);
45424533 }
45434534
45444535 function getTypeParameterFromMappedType(type: MappedType) {
0 commit comments