mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Fix printing of deferred mapped types' index signatures
This commit is contained in:
@@ -2860,7 +2860,7 @@ namespace ts {
|
||||
for (const signature of resolvedType.constructSignatures) {
|
||||
typeElements.push(<ConstructSignatureDeclaration>signatureToSignatureDeclarationHelper(signature, SyntaxKind.ConstructSignature, context));
|
||||
}
|
||||
if (resolvedType.stringIndexInfo && !(resolvedType.objectFlags & ObjectFlags.Deferred)) {
|
||||
if (resolvedType.stringIndexInfo) {
|
||||
const indexInfo = resolvedType.objectFlags & ObjectFlags.Deferred ?
|
||||
createIndexInfo(emptyObjectType, resolvedType.stringIndexInfo.isReadonly, resolvedType.stringIndexInfo.declaration) :
|
||||
resolvedType.stringIndexInfo;
|
||||
|
||||
@@ -391,15 +391,15 @@ function f6(s: string) {
|
||||
|
||||
});
|
||||
let v = unboxify(b);
|
||||
>v : {}
|
||||
>unboxify(b) : {}
|
||||
>v : { [x: string]: {}; }
|
||||
>unboxify(b) : { [x: string]: {}; }
|
||||
>unboxify : <T>(obj: Boxified<T>) => T
|
||||
>b : { [x: string]: Box<number> | Box<string> | Box<boolean>; }
|
||||
|
||||
let x: string | number | boolean = v[s];
|
||||
>x : string | number | boolean
|
||||
>v[s] : string | number | boolean
|
||||
>v : {}
|
||||
>v : { [x: string]: {}; }
|
||||
>s : string
|
||||
}
|
||||
|
||||
|
||||
@@ -71,37 +71,37 @@ declare let b: B;
|
||||
>B : B
|
||||
|
||||
const oub = foo(b);
|
||||
>oub : {}
|
||||
>foo(b) : {}
|
||||
>oub : { [x: string]: {}; }
|
||||
>foo(b) : { [x: string]: {}; }
|
||||
>foo : <T>(deep: Deep<T>) => T
|
||||
>b : B
|
||||
|
||||
oub.b
|
||||
>oub.b : {}
|
||||
>oub : {}
|
||||
>b : {}
|
||||
>oub.b : { [x: string]: {}; }
|
||||
>oub : { [x: string]: {}; }
|
||||
>b : { [x: string]: {}; }
|
||||
|
||||
oub.b.b
|
||||
>oub.b.b : {}
|
||||
>oub.b : {}
|
||||
>oub : {}
|
||||
>b : {}
|
||||
>b : {}
|
||||
>oub.b.b : { [x: string]: {}; }
|
||||
>oub.b : { [x: string]: {}; }
|
||||
>oub : { [x: string]: {}; }
|
||||
>b : { [x: string]: {}; }
|
||||
>b : { [x: string]: {}; }
|
||||
|
||||
oub.b.a.n.a.n.a
|
||||
>oub.b.a.n.a.n.a : {}
|
||||
>oub.b.a.n.a.n : {}
|
||||
>oub.b.a.n.a : {}
|
||||
>oub.b.a.n : {}
|
||||
>oub.b.a : {}
|
||||
>oub.b : {}
|
||||
>oub : {}
|
||||
>b : {}
|
||||
>a : {}
|
||||
>n : {}
|
||||
>a : {}
|
||||
>n : {}
|
||||
>a : {}
|
||||
>oub.b.a.n.a.n.a : { [x: string]: {}; }
|
||||
>oub.b.a.n.a.n : { [x: string]: {}; }
|
||||
>oub.b.a.n.a : { [x: string]: {}; }
|
||||
>oub.b.a.n : { [x: string]: {}; }
|
||||
>oub.b.a : { [x: string]: {}; }
|
||||
>oub.b : { [x: string]: {}; }
|
||||
>oub : { [x: string]: {}; }
|
||||
>b : { [x: string]: {}; }
|
||||
>a : { [x: string]: {}; }
|
||||
>n : { [x: string]: {}; }
|
||||
>a : { [x: string]: {}; }
|
||||
>n : { [x: string]: {}; }
|
||||
>a : { [x: string]: {}; }
|
||||
|
||||
let xhr: XMLHttpRequest;
|
||||
>xhr : XMLHttpRequest
|
||||
|
||||
Reference in New Issue
Block a user