From af3d0f0248cbc20366fd5591063958cd9f7ea391 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Tue, 9 Apr 2019 11:31:17 -0700 Subject: [PATCH 001/119] Start smart select API --- src/server/protocol.ts | 21 ++++- src/server/session.ts | 63 +++++++++++++- src/testRunner/tsconfig.json | 1 + .../unittests/tsserver/selectionRange.ts | 84 +++++++++++++++++++ src/testRunner/unittests/tsserver/session.ts | 1 + 5 files changed, 167 insertions(+), 3 deletions(-) create mode 100644 src/testRunner/unittests/tsserver/selectionRange.ts diff --git a/src/server/protocol.ts b/src/server/protocol.ts index e5580874369..1709c6196ef 100644 --- a/src/server/protocol.ts +++ b/src/server/protocol.ts @@ -130,7 +130,8 @@ namespace ts.server.protocol { GetEditsForFileRename = "getEditsForFileRename", /* @internal */ GetEditsForFileRenameFull = "getEditsForFileRename-full", - ConfigurePlugin = "configurePlugin" + ConfigurePlugin = "configurePlugin", + SelectionRange = "selectionRange", // NOTE: If updating this, be sure to also update `allCommandNames` in `harness/unittests/session.ts`. } @@ -1395,6 +1396,24 @@ namespace ts.server.protocol { export interface ConfigurePluginResponse extends Response { } + export interface SelectionRangeRequest extends FileRequest { + command: CommandTypes.SelectionRange; + arguments: SelectionRangeRequestArgs; + } + + export interface SelectionRangeRequestArgs extends FileRequestArgs { + locations: Location[]; + } + + export interface SelectionRangeResponse extends Response { + body?: SelectionRange[]; + } + + export interface SelectionRange { + textSpan: TextSpan; + parent?: SelectionRange; + } + /** * Information found in an "open" request. */ diff --git a/src/server/session.ts b/src/server/session.ts index 3c202c9aecd..f566340cb28 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -1318,11 +1318,11 @@ namespace ts.server { this.projectService.openClientFileWithNormalizedPath(fileName, fileContent, scriptKind, /*hasMixedContent*/ false, projectRootPath); } - private getPosition(args: protocol.FileLocationRequestArgs, scriptInfo: ScriptInfo): number { + private getPosition(args: protocol.Location & { position?: number }, scriptInfo: ScriptInfo): number { return args.position !== undefined ? args.position : scriptInfo.lineOffsetToPosition(args.line, args.offset); } - private getPositionInFile(args: protocol.FileLocationRequestArgs, file: NormalizedPath): number { + private getPositionInFile(args: protocol.Location & { position?: number }, file: NormalizedPath): number { const scriptInfo = this.projectService.getScriptInfoForNormalizedPath(file)!; return this.getPosition(args, scriptInfo); } @@ -2059,6 +2059,62 @@ namespace ts.server { this.projectService.configurePlugin(args); } + private getSelectionRange(args: protocol.SelectionRangeRequestArgs): protocol.SelectionRange[] { + const { locations } = args; + const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args); + + const sourceFile = languageService.getNonBoundSourceFile(file); + const scriptInfo = Debug.assertDefined(this.projectService.getScriptInfo(file)); + const fullTextSpan = this.toLocationTextSpan( + createTextSpan(sourceFile.getFullStart(), sourceFile.getEnd() - sourceFile.getFullStart()), + scriptInfo); + + return map(locations, location => { + const pos = this.getPosition(location, scriptInfo); + let selectionRange: protocol.SelectionRange = { textSpan: fullTextSpan }; + // Skip top-level SyntaxList + let current: Node | undefined = sourceFile.getChildAt(0); + while (true) { + const children = current && current.getChildren(sourceFile); + if (!children || !children.length) break; + for (let i = 0; i < children.length; i++) { + const prevNode: Node | undefined = children[i - 1]; + const node: Node = children[i]; + const nextNode: Node | undefined = children[i + 1]; + if (node.getStart(sourceFile) > pos) { + current = undefined; + break; + } + // Blocks are effectively redundant with SyntaxLists; dive in without adding to the list + if (isBlock(node)) { + current = node; + break; + } + if (positionBelongsToNode(node, pos, sourceFile)) { + // Blocks with braces should be selected from brace to brace, non-inclusive + const isBetweenBraces = isSyntaxList(node) + && prevNode && prevNode.kind === SyntaxKind.OpenBraceToken + && nextNode && nextNode.kind === SyntaxKind.CloseBraceToken; + const start = isBetweenBraces ? prevNode.getEnd() : node.getStart(); + const end = isBetweenBraces ? nextNode.getStart() : node.getEnd(); + const textSpan = this.toLocationTextSpan(createTextSpan(start, end - start), scriptInfo); + current = node; + // Skip ranges that are identical to the parent + if (selectionRange.textSpan.start !== textSpan.start || selectionRange.textSpan.end !== textSpan.end) { + selectionRange = { + textSpan, + parent: selectionRange, + }; + Object.defineProperty(selectionRange, "__debugKind", { value: formatSyntaxKind(node.kind) }); + } + break; + } + } + } + return selectionRange; + }); + } + getCanonicalFileName(fileName: string) { const name = this.host.useCaseSensitiveFileNames ? fileName : fileName.toLowerCase(); return normalizePath(name); @@ -2414,6 +2470,9 @@ namespace ts.server { this.configurePlugin(request.arguments); this.doOutput(/*info*/ undefined, CommandNames.ConfigurePlugin, request.seq, /*success*/ true); return this.notRequired(); + }, + [CommandNames.SelectionRange]: (request: protocol.SelectionRangeRequest) => { + return this.requiredResponse(this.getSelectionRange(request.arguments)); } }); diff --git a/src/testRunner/tsconfig.json b/src/testRunner/tsconfig.json index 6b73324e2f7..5ae94c80c23 100644 --- a/src/testRunner/tsconfig.json +++ b/src/testRunner/tsconfig.json @@ -141,6 +141,7 @@ "unittests/tsserver/reload.ts", "unittests/tsserver/rename.ts", "unittests/tsserver/resolutionCache.ts", + "unittests/tsserver/selectionRange.ts", "unittests/tsserver/session.ts", "unittests/tsserver/skipLibCheck.ts", "unittests/tsserver/symLinks.ts", diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts new file mode 100644 index 00000000000..ae67ea5de0a --- /dev/null +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -0,0 +1,84 @@ +namespace ts.projectSystem { + function setup(fileName: string, content: string) { + const file: File = { path: fileName, content }; + const host = createServerHost([file, libFile]); + const session = createSession(host); + openFilesForSession([file], session); + return function getSelectionRange(locations: protocol.SelectionRangeRequestArgs["locations"]) { + return executeSessionRequest( + session, + CommandNames.SelectionRange, + { file: fileName, locations }); + }; + } + + describe("unittests:: tsserver:: selectionRange", () => { + it("works for simple JavaScript", () => { + const getSelectionRange = setup("/file.js", ` +class Foo { + bar(a, b) { + if (a === b) { + return true; + } + return false; + } +}`); + + const locations = getSelectionRange([{ + line: 4, + offset: 13 + }]); + + assert.deepEqual(locations, [ + { + textSpan: { // a + start: { line: 4, offset: 13 }, + end: { line: 4, offset: 14 }, + }, + parent: { + textSpan: { // a === b + start: { line: 4, offset: 13 }, + end: { line: 4, offset: 20 }, + }, + parent: { + textSpan: { // IfStatement + start: { line: 4, offset: 9 }, + end: { line: 6, offset: 10 }, + }, + parent: { + textSpan: { // SyntaxList + whitespace (body of method) + start: { line: 3, offset: 16 }, + end: { line: 8, offset: 5 }, + }, + parent: { + textSpan: { // MethodDeclaration + start: { line: 3, offset: 5 }, + end: { line: 8, offset: 6 }, + }, + parent: { + textSpan: { // SyntaxList + whitespace (body of class) + start: { line: 2, offset: 12 }, + end: { line: 9, offset: 1 }, + }, + parent: { + textSpan: { // ClassDeclaration + start: { line: 2, offset: 1 }, + end: { line: 9, offset: 2 }, + }, + parent: { + textSpan: { // SourceFile (all text) + start: { line: 1, offset: 1 }, + end: { line: 9, offset: 2 }, + } + } + } + } + }, + }, + }, + }, + }, + ]); + }); + }); +} diff --git a/src/testRunner/unittests/tsserver/session.ts b/src/testRunner/unittests/tsserver/session.ts index 715c0ab3324..cf84ffce6e8 100644 --- a/src/testRunner/unittests/tsserver/session.ts +++ b/src/testRunner/unittests/tsserver/session.ts @@ -264,6 +264,7 @@ namespace ts.server { CommandNames.OrganizeImportsFull, CommandNames.GetEditsForFileRename, CommandNames.GetEditsForFileRenameFull, + CommandNames.SelectionRange, ]; it("should not throw when commands are executed with invalid arguments", () => { From f98c00ab9dbf9b37fbadb9a15b6a41f65b06d383 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Tue, 9 Apr 2019 15:32:38 -0700 Subject: [PATCH 002/119] Add more tests, special handling for mapped types --- src/server/session.ts | 59 ++++- .../unittests/tsserver/selectionRange.ts | 202 ++++++++++++++---- 2 files changed, 207 insertions(+), 54 deletions(-) diff --git a/src/server/session.ts b/src/server/session.ts index f566340cb28..307ee37cc1c 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -1744,6 +1744,14 @@ namespace ts.server { }; } + private locationsAreEqual(a: protocol.Location, b: protocol.Location): boolean { + return a.line === b.line && a.offset === b.offset; + } + + private locationTextSpansAreEqual(a: protocol.TextSpan, b: protocol.TextSpan): boolean { + return this.locationsAreEqual(a.start, b.start) && this.locationsAreEqual(a.end, b.end); + } + private getNavigationTree(args: protocol.FileRequestArgs, simplifiedResult: boolean): protocol.NavigationTree | NavigationTree | undefined { const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args); const tree = languageService.getNavigationTree(file); @@ -2066,12 +2074,22 @@ namespace ts.server { const sourceFile = languageService.getNonBoundSourceFile(file); const scriptInfo = Debug.assertDefined(this.projectService.getScriptInfo(file)); const fullTextSpan = this.toLocationTextSpan( - createTextSpan(sourceFile.getFullStart(), sourceFile.getEnd() - sourceFile.getFullStart()), + createTextSpanFromBounds(sourceFile.getFullStart(), sourceFile.getEnd()), scriptInfo); return map(locations, location => { const pos = this.getPosition(location, scriptInfo); let selectionRange: protocol.SelectionRange = { textSpan: fullTextSpan }; + const pushSelectionRange = (textSpan: protocol.TextSpan, syntaxKind?: SyntaxKind): void => { + // Skip ranges that are identical to the parent + if (!this.locationTextSpansAreEqual(textSpan, selectionRange.textSpan)) { + selectionRange = { textSpan, parent: selectionRange }; + if (syntaxKind) { + Object.defineProperty(selectionRange, "__debugKind", { value: formatSyntaxKind(syntaxKind) }); + } + } + }; + // Skip top-level SyntaxList let current: Node | undefined = sourceFile.getChildAt(0); while (true) { @@ -2097,16 +2115,37 @@ namespace ts.server { && nextNode && nextNode.kind === SyntaxKind.CloseBraceToken; const start = isBetweenBraces ? prevNode.getEnd() : node.getStart(); const end = isBetweenBraces ? nextNode.getStart() : node.getEnd(); - const textSpan = this.toLocationTextSpan(createTextSpan(start, end - start), scriptInfo); - current = node; - // Skip ranges that are identical to the parent - if (selectionRange.textSpan.start !== textSpan.start || selectionRange.textSpan.end !== textSpan.end) { - selectionRange = { - textSpan, - parent: selectionRange, - }; - Object.defineProperty(selectionRange, "__debugKind", { value: formatSyntaxKind(node.kind) }); + const textSpan = this.toLocationTextSpan(createTextSpanFromBounds(start, end), scriptInfo); + pushSelectionRange(textSpan, node.kind); + + // Mapped types _look_ like ObjectTypes with a single member, + // but in fact don’t contain a SyntaxList or a node containing + // the “key/value” pair like ObjectTypes do, but it seems intuitive + // that the selection would snap to those points. The philosophy + // of choosing a selection range is not so much about what the + // syntax currently _is_ as what the syntax might easily become + // if the user is making a selection; e.g., we synthesize a selection + // around the “key/value” pair not because there’s a node there, but + // because it allows the mapped type to become an object type with a + // few keystrokes. + if (isMappedTypeNode(node)) { + const openBraceToken = Debug.assertDefined(node.getFirstToken()); + const firstNonBraceToken = Debug.assertDefined(node.getChildAt(1)); + const closeBraceToken = Debug.assertDefined(node.getLastToken()); + Debug.assertEqual(openBraceToken.kind, SyntaxKind.OpenBraceToken); + Debug.assertEqual(closeBraceToken.kind, SyntaxKind.CloseBraceToken); + const spanWithoutBraces = this.toLocationTextSpan(createTextSpanFromBounds( + openBraceToken.getEnd(), + closeBraceToken.getStart(), + ), scriptInfo); + const spanWithoutBracesOrTrivia = this.toLocationTextSpan(createTextSpanFromBounds( + firstNonBraceToken.getStart(), + closeBraceToken.getFullStart(), + ), scriptInfo); + pushSelectionRange(spanWithoutBraces); + pushSelectionRange(spanWithoutBracesOrTrivia); } + current = node; break; } } diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index ae67ea5de0a..80b8b1971c0 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -24,61 +24,175 @@ class Foo { } }`); - const locations = getSelectionRange([{ - line: 4, - offset: 13 - }]); + const locations = getSelectionRange([ + { + line: 4, + offset: 13, + }, { + line: 5, + offset: 22, + }, + ]); + + // Common to results for both locations + const ifStatementUp: protocol.SelectionRange = { + textSpan: { // IfStatement + start: { line: 4, offset: 9 }, + end: { line: 6, offset: 10 } }, + parent: { + textSpan: { // SyntaxList + whitespace (body of method) + start: { line: 3, offset: 16 }, + end: { line: 8, offset: 5 } }, + parent: { + textSpan: { // MethodDeclaration + start: { line: 3, offset: 5 }, + end: { line: 8, offset: 6 } }, + parent: { + textSpan: { // SyntaxList + whitespace (body of class) + start: { line: 2, offset: 12 }, + end: { line: 9, offset: 1 } }, + parent: { + textSpan: { // ClassDeclaration + start: { line: 2, offset: 1 }, + end: { line: 9, offset: 2 } }, + parent: { + textSpan: { // SourceFile (all text) + start: { line: 1, offset: 1 }, + end: { line: 9, offset: 2 }, } } } } } } }; assert.deepEqual(locations, [ { textSpan: { // a start: { line: 4, offset: 13 }, - end: { line: 4, offset: 14 }, - }, + end: { line: 4, offset: 14 } }, parent: { textSpan: { // a === b start: { line: 4, offset: 13 }, - end: { line: 4, offset: 20 }, - }, + end: { line: 4, offset: 20 } }, + parent: ifStatementUp } }, + { + textSpan: { // true + start: { line: 5, offset: 20 }, + end: { line: 5, offset: 24 } }, + parent: { + textSpan: { // return true; + start: { line: 5, offset: 13 }, + end: { line: 5, offset: 25 } }, parent: { - textSpan: { // IfStatement - start: { line: 4, offset: 9 }, - end: { line: 6, offset: 10 }, - }, - parent: { - textSpan: { // SyntaxList + whitespace (body of method) - start: { line: 3, offset: 16 }, - end: { line: 8, offset: 5 }, - }, - parent: { - textSpan: { // MethodDeclaration - start: { line: 3, offset: 5 }, - end: { line: 8, offset: 6 }, - }, - parent: { - textSpan: { // SyntaxList + whitespace (body of class) - start: { line: 2, offset: 12 }, - end: { line: 9, offset: 1 }, - }, - parent: { - textSpan: { // ClassDeclaration - start: { line: 2, offset: 1 }, - end: { line: 9, offset: 2 }, - }, - parent: { - textSpan: { // SourceFile (all text) - start: { line: 1, offset: 1 }, - end: { line: 9, offset: 2 }, - } - } - } - } - }, - }, - }, - }, + textSpan: { // SyntaxList + whitespace (body of IfStatement) + start: { line: 4, offset: 23 }, + end: { line: 6, offset: 9 } }, + parent: ifStatementUp } } } + ]); + }); + + it("works for simple TypeScript", () => { + const getSelectionRange = setup("/file.ts", ` +export interface IService { + _serviceBrand: any; + + open(host: number, data: any): Promise; +}`); + const locations = getSelectionRange([ + { + line: 5, + offset: 12, }, ]); + + assert.deepEqual(locations, [ + { + textSpan: { // host + start: { line: 5, offset: 10 }, + end: { line: 5, offset: 14 } }, + parent: { + textSpan: { // host: number + start: { line: 5, offset: 10 }, + end: { line: 5, offset: 22 } }, + parent: { + textSpan: { // host: number, data: any + start: { line: 5, offset: 10 }, + end: { line: 5, offset: 33 } }, + parent: { + textSpan: { // open(host: number, data: any): Promise; + start: { line: 5, offset: 5 }, + end: { line: 5, offset: 49 } }, + parent: { + textSpan: { // SyntaxList + whitespace (body of interface) + start: { line: 2, offset: 28 }, + end: { line: 6, offset: 1 } }, + parent: { + textSpan: { // InterfaceDeclaration + start: { line: 2, offset: 1 }, + end: { line: 6, offset: 2 } }, + parent: { + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 6, offset: 2 } } } } } } } } }, + ]); + }); + + it("works for complex TypeScript", () => { + const getSelectionRange = setup("/file.ts", ` +type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; } & Pick>) +`); + const locations = getSelectionRange([ + { + line: 2, + offset: 133, + }, + ]); + + assert.deepEqual(locations, [ + { + textSpan: { // K + start: { line: 2, offset: 133 }, + end: { line: 2, offset: 134 } }, + parent: { + textSpan: { // P[K] + start: { line: 2, offset: 131 }, + end: { line: 2, offset: 135 } }, + parent: { + textSpan: { // K extends keyof T ? T[K] : P[K] + start: { line: 2, offset: 104 }, + end: { line: 2, offset: 135 } }, + parent: { + textSpan: { // IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K] + start: { line: 2, offset: 70 }, + end: { line: 2, offset: 142 } }, + parent: { + textSpan: { // [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; + start: { line: 2, offset: 54 }, + end: { line: 2, offset: 143 } }, + parent: { // same as above + whitespace + textSpan: { + start: { line: 2, offset: 53 }, + end: { line: 2, offset: 144 } }, + parent: { + textSpan: { // MappedType: same as above + braces + start: { line: 2, offset: 52 }, + end: { line: 2, offset: 145 } }, + parent: { + textSpan: { // IntersectionType: { [K in keyof P]: ... } & Pick> + start: { line: 2, offset: 52 }, + end: { line: 2, offset: 182 } }, + parent: { + textSpan: { // same as above + parens + start: { line: 2, offset: 51 }, + end: { line: 2, offset: 183 } }, + parent: { + textSpan: { // Whole TypeNode of TypeAliasDeclaration + start: { line: 2, offset: 16 }, + end: { line: 2, offset: 183 } }, + parent: { + textSpan: { // Whole TypeAliasDeclaration + start: { line: 2, offset: 1 }, + end: { line: 2, offset: 183 } }, + parent: { + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 2, offset: 184 } } } } } } } } } } } } } }, + ]); }); }); } From e62c2333eb3398ef835ba4cb561f8f168a8b3a75 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Wed, 10 Apr 2019 14:23:25 -0700 Subject: [PATCH 003/119] Add support for string literals --- src/server/session.ts | 46 +++++--- .../unittests/tsserver/selectionRange.ts | 107 ++++++++++++++++++ 2 files changed, 138 insertions(+), 15 deletions(-) diff --git a/src/server/session.ts b/src/server/session.ts index 307ee37cc1c..9f4fb2b24d6 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -2080,8 +2080,9 @@ namespace ts.server { return map(locations, location => { const pos = this.getPosition(location, scriptInfo); let selectionRange: protocol.SelectionRange = { textSpan: fullTextSpan }; - const pushSelectionRange = (textSpan: protocol.TextSpan, syntaxKind?: SyntaxKind): void => { + const pushSelectionRange = (start: number, end: number, syntaxKind?: SyntaxKind): void => { // Skip ranges that are identical to the parent + const textSpan = this.toLocationTextSpan(createTextSpanFromBounds(start, end), scriptInfo); if (!this.locationTextSpansAreEqual(textSpan, selectionRange.textSpan)) { selectionRange = { textSpan, parent: selectionRange }; if (syntaxKind) { @@ -2092,6 +2093,7 @@ namespace ts.server { // Skip top-level SyntaxList let current: Node | undefined = sourceFile.getChildAt(0); + let isInTemplateSpan = false; while (true) { const children = current && current.getChildren(sourceFile); if (!children || !children.length) break; @@ -2103,20 +2105,32 @@ namespace ts.server { current = undefined; break; } - // Blocks are effectively redundant with SyntaxLists; dive in without adding to the list - if (isBlock(node)) { + // Blocks are effectively redundant with SyntaxLists. + // TemplateSpans are an unintuitive grouping of two things which + // should be considered independently. + // Dive in without pushing a selection range. + const nodeIsTemplateSpan = isTemplateSpan(node); + const nodeIsTemplateSpanList = prevNode && isTemplateHead(prevNode); + if (isBlock(node) || nodeIsTemplateSpan || nodeIsTemplateSpanList) { + isInTemplateSpan = nodeIsTemplateSpan; current = node; break; } if (positionBelongsToNode(node, pos, sourceFile)) { + // Synthesize a stop for '${ ... }' since '${' and '}' actually belong to siblings. + if (isInTemplateSpan && nextNode && isTemplateMiddleOrTemplateTail(nextNode)) { + const start = node.getFullStart() - "${".length; + const end = nextNode.getStart() + "}".length; + pushSelectionRange(start, end, node.kind); + } + // Blocks with braces should be selected from brace to brace, non-inclusive const isBetweenBraces = isSyntaxList(node) && prevNode && prevNode.kind === SyntaxKind.OpenBraceToken && nextNode && nextNode.kind === SyntaxKind.CloseBraceToken; const start = isBetweenBraces ? prevNode.getEnd() : node.getStart(); const end = isBetweenBraces ? nextNode.getStart() : node.getEnd(); - const textSpan = this.toLocationTextSpan(createTextSpanFromBounds(start, end), scriptInfo); - pushSelectionRange(textSpan, node.kind); + pushSelectionRange(start, end, node.kind); // Mapped types _look_ like ObjectTypes with a single member, // but in fact don’t contain a SyntaxList or a node containing @@ -2134,17 +2148,19 @@ namespace ts.server { const closeBraceToken = Debug.assertDefined(node.getLastToken()); Debug.assertEqual(openBraceToken.kind, SyntaxKind.OpenBraceToken); Debug.assertEqual(closeBraceToken.kind, SyntaxKind.CloseBraceToken); - const spanWithoutBraces = this.toLocationTextSpan(createTextSpanFromBounds( - openBraceToken.getEnd(), - closeBraceToken.getStart(), - ), scriptInfo); - const spanWithoutBracesOrTrivia = this.toLocationTextSpan(createTextSpanFromBounds( - firstNonBraceToken.getStart(), - closeBraceToken.getFullStart(), - ), scriptInfo); - pushSelectionRange(spanWithoutBraces); - pushSelectionRange(spanWithoutBracesOrTrivia); + const spanWithoutBraces = [openBraceToken.getEnd(), closeBraceToken.getStart()] as const; + const spanWithoutBracesOrTrivia = [firstNonBraceToken.getStart(), closeBraceToken.getFullStart()] as const; + pushSelectionRange(...spanWithoutBraces); + pushSelectionRange(...spanWithoutBracesOrTrivia); } + + // String literals should have a stop both inside and outside their quotes. + if (isStringLiteral(node) || isTemplateLiteral(node)) { + pushSelectionRange(start + 1, end - 1); + } + + // If we’ve made it here, we’ve already used `isInTemplateSpan` as much as we need + isInTemplateSpan = false; current = node; break; } diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 80b8b1971c0..9166acecc40 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -194,5 +194,112 @@ type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAn end: { line: 2, offset: 184 } } } } } } } } } } } } } }, ]); }); + + it.skip("works for object types", () => { + const getSelectionRange = setup("/file.js", ` +type X = { + foo?: string; + readonly bar: number; +}`); + const locations = getSelectionRange([ + { + line: 3, + offset: 5, + }, + { + line: 4, + offset: 5, + }, + { + line: 4, + offset: 14, + }, + ]); + + const allMembersUp: protocol.SelectionRange = { + textSpan: { // all members + whitespace (just inside braces) + start: { line: 2, offset: 11 }, + end: { line: 5, offset: 1 } }, + parent: { + textSpan: { // add braces + start: { line: 2, offset: 10 }, + end: { line: 5, offset: 2 } }, + parent: { + textSpan: { // whole TypeAliasDeclaration + start: { line: 2, offset: 1 }, + end: { line: 5, offset: 2 } }, + parent: { + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 5, offset: 2 } } } } } }; + + const readonlyBarUp: protocol.SelectionRange = { + textSpan: { // readonly bar + start: { line: 4, offset: 5 }, + end: { line: 4, offset: 17 } }, + parent: { + textSpan: { // readonly bar: number; + start: { line: 4, offset: 5 }, + end: { line: 4, offset: 26 } }, + parent: allMembersUp } }; + + assert.deepEqual(locations, [ + { + textSpan: { // foo + start: { line: 3, offset: 5 }, + end: { line: 3, offset: 8 } }, + parent: { + textSpan: { // foo? + start: { line: 3, offset: 5 }, + end: { line: 3, offset: 9 } }, + parent: { + textSpan: { // foo?: string; + start: { line: 3, offset: 5 }, + end: { line: 3, offset: 18 } }, + parent: allMembersUp } } }, + { + textSpan: { // readonly + start: { line: 4, offset: 5 }, + end: { line: 4, offset: 13 } }, + parent: readonlyBarUp }, + { + textSpan: { // bar + start: { line: 4, offset: 14 }, + end: { line: 4, offset: 17 } }, + parent: readonlyBarUp }, + ]); + }); + + it("works for string literals and template strings", () => { + // tslint:disable-next-line:no-invalid-template-strings + const getSelectionRange = setup("/file.ts", "`a b ${\n 'c'\n} d`"); + const locations = getSelectionRange([{ line: 2, offset: 4 }]); + assert.deepEqual(locations, [ + { + textSpan: { // c + start: { line: 2, offset: 4 }, + end: { line: 2, offset: 5 } }, + parent: { + textSpan: { // 'c' + start: { line: 2, offset: 3 }, + end: { line: 2, offset: 6 } }, + // parent: { + // textSpan: { // just inside braces + // start: { line: 1, offset: 8 }, + // end: { line: 3, offset: 1 } }, + parent: { + textSpan: { // whole TemplateSpan: ${ ... } + start: { line: 1, offset: 6 }, + end: { line: 3, offset: 2 } }, + parent: { + textSpan: { // whole template string without backticks + start: { line: 1, offset: 2 }, + end: { line: 3, offset: 4 } }, + parent: { + textSpan: { // whole template string + start: { line: 1, offset: 1 }, + end: { line: 3, offset: 5 } } } } } } } + ]); + }); }); } From fd88e5225270121e949d4cff67b2a664f21dac07 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 11 Apr 2019 11:38:05 -0700 Subject: [PATCH 004/119] Start imports --- src/server/session.ts | 75 +++++++++++++------ .../unittests/tsserver/selectionRange.ts | 40 ++++++++++ 2 files changed, 92 insertions(+), 23 deletions(-) diff --git a/src/server/session.ts b/src/server/session.ts index 9f4fb2b24d6..90a8aa2f00f 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -112,6 +112,32 @@ namespace ts.server { return edits.every(edit => textSpanEnd(edit.span) < pos); } + function getGroupBounds(array: ArrayLike, index: number, predicate: (element: T) => boolean): [number, number] { + let first = index; + let last = index; + let i = index; + while (i > 0) { + const element = array[--i]; + if (predicate(element)) { + first = i; + } + else { + break; + } + } + i = index; + while (i < array.length - 1) { + const element = array[++i]; + if (predicate(element)) { + last = i; + } + else { + break; + } + } + return [first, last]; + } + // CommandNames used to be exposed before TS 2.4 as a namespace // In TS 2.4 we switched to an enum, keep this for backward compatibility // The var assignment ensures that even though CommandTypes are a const enum @@ -2071,6 +2097,7 @@ namespace ts.server { const { locations } = args; const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args); + const isImport = or(isImportDeclaration, isImportEqualsDeclaration); const sourceFile = languageService.getNonBoundSourceFile(file); const scriptInfo = Debug.assertDefined(this.projectService.getScriptInfo(file)); const fullTextSpan = this.toLocationTextSpan( @@ -2092,37 +2119,41 @@ namespace ts.server { }; // Skip top-level SyntaxList - let current: Node | undefined = sourceFile.getChildAt(0); - let isInTemplateSpan = false; - while (true) { - const children = current && current.getChildren(sourceFile); - if (!children || !children.length) break; + let parentNode = sourceFile.getChildAt(0); + outer: while (true) { + const children = parentNode.getChildren(sourceFile); + if (!children.length) break; for (let i = 0; i < children.length; i++) { const prevNode: Node | undefined = children[i - 1]; const node: Node = children[i]; const nextNode: Node | undefined = children[i + 1]; if (node.getStart(sourceFile) > pos) { - current = undefined; - break; - } - // Blocks are effectively redundant with SyntaxLists. - // TemplateSpans are an unintuitive grouping of two things which - // should be considered independently. - // Dive in without pushing a selection range. - const nodeIsTemplateSpan = isTemplateSpan(node); - const nodeIsTemplateSpanList = prevNode && isTemplateHead(prevNode); - if (isBlock(node) || nodeIsTemplateSpan || nodeIsTemplateSpanList) { - isInTemplateSpan = nodeIsTemplateSpan; - current = node; - break; + break outer; } + if (positionBelongsToNode(node, pos, sourceFile)) { + // Blocks are effectively redundant with SyntaxLists. + // TemplateSpans, along with the SyntaxLists containing them, + // are a somewhat unintuitive grouping of things that should be + // considered independently. Dive in without pushing a selection range. + if (isBlock(node) || isTemplateSpan(node) || prevNode && isTemplateHead(prevNode)) { + parentNode = node; + break; + } + // Synthesize a stop for '${ ... }' since '${' and '}' actually belong to siblings. - if (isInTemplateSpan && nextNode && isTemplateMiddleOrTemplateTail(nextNode)) { + if (isTemplateSpan(parentNode) && nextNode && isTemplateMiddleOrTemplateTail(nextNode)) { const start = node.getFullStart() - "${".length; const end = nextNode.getStart() + "}".length; pushSelectionRange(start, end, node.kind); } + // Synthesize a stop for group of adjacent imports + else if (isImport(node)) { + const [firstImportIndex, lastImportIndex] = getGroupBounds(children, i, isImport); + pushSelectionRange( + children[firstImportIndex].getStart(), + children[lastImportIndex].getEnd()); + } // Blocks with braces should be selected from brace to brace, non-inclusive const isBetweenBraces = isSyntaxList(node) @@ -2155,13 +2186,11 @@ namespace ts.server { } // String literals should have a stop both inside and outside their quotes. - if (isStringLiteral(node) || isTemplateLiteral(node)) { + else if (isStringLiteral(node) || isTemplateLiteral(node)) { pushSelectionRange(start + 1, end - 1); } - // If we’ve made it here, we’ve already used `isInTemplateSpan` as much as we need - isInTemplateSpan = false; - current = node; + parentNode = node; break; } } diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 9166acecc40..4b95f929bf9 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -301,5 +301,45 @@ type X = { end: { line: 3, offset: 5 } } } } } } } ]); }); + + it.skip("works for ES2015 import lists", () => { + const getSelectionRange = setup("/file.ts", ` +import { x as y, z } from './z'; +import { b } from './'; + +console.log(1);`); + + const locations = getSelectionRange([{ line: 2, offset: 10 }]); + assert.deepEqual(locations, [ + { + textSpan: { // x + start: { line: 2, offset: 10 }, + end: { line: 2, offset: 11 } }, + parent: { + textSpan: { // x as y + start: { line: 2, offset: 10 }, + end: { line: 2, offset: 16 } }, + parent: { + textSpan: { // x as y, z + start: { line: 2, offset: 10 }, + end: { line: 2, offset: 19 } }, + parent: { + textSpan: { // { x as y, z } + start: { line: 2, offset: 8 }, + end: { line: 2, offset: 21 } }, + parent: { + textSpan: { // import { x as y, z } from './z'; + start: { line: 2, offset: 1 }, + end: { line: 2, offset: 33 } }, + parent: { + textSpan: { // all imports + start: { line: 2, offset: 1 }, + end: { line: 3, offset: 24 } }, + parent: { + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 5, offset: 16 } } } } } } } } } + ]); + }); }); } From 039487c84e518cb6de798d1011dca7e9db624315 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 11 Apr 2019 12:47:10 -0700 Subject: [PATCH 005/119] Also skip TemplateHeads --- src/server/session.ts | 2 +- .../unittests/tsserver/selectionRange.ts | 15 +++++++++++++-- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/src/server/session.ts b/src/server/session.ts index 90a8aa2f00f..f64674b129a 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -2136,7 +2136,7 @@ namespace ts.server { // TemplateSpans, along with the SyntaxLists containing them, // are a somewhat unintuitive grouping of things that should be // considered independently. Dive in without pushing a selection range. - if (isBlock(node) || isTemplateSpan(node) || prevNode && isTemplateHead(prevNode)) { + if (isBlock(node) || isTemplateSpan(node) || isTemplateHead(node) || prevNode && isTemplateHead(prevNode)) { parentNode = node; break; } diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 4b95f929bf9..ce88b4072cc 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -273,7 +273,10 @@ type X = { it("works for string literals and template strings", () => { // tslint:disable-next-line:no-invalid-template-strings const getSelectionRange = setup("/file.ts", "`a b ${\n 'c'\n} d`"); - const locations = getSelectionRange([{ line: 2, offset: 4 }]); + const locations = getSelectionRange([ + { line: 2, offset: 4 }, + { line: 1, offset: 4 }, + ]); assert.deepEqual(locations, [ { textSpan: { // c @@ -298,7 +301,15 @@ type X = { parent: { textSpan: { // whole template string start: { line: 1, offset: 1 }, - end: { line: 3, offset: 5 } } } } } } } + end: { line: 3, offset: 5 } } } } } } }, + { + textSpan: { // whole template string without backticks + start: { line: 1, offset: 2 }, + end: { line: 3, offset: 4 } }, + parent: { + textSpan: { // whole template string + start: { line: 1, offset: 1 }, + end: { line: 3, offset: 5 } } } }, ]); }); From 0a4ef0f63069f29beac7689d4b9a579689d732dc Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 11 Apr 2019 13:02:49 -0700 Subject: [PATCH 006/119] Distinguish between same-line and different-line braces --- src/server/session.ts | 12 +++--- .../unittests/tsserver/selectionRange.ts | 37 +++++++++++-------- 2 files changed, 28 insertions(+), 21 deletions(-) diff --git a/src/server/session.ts b/src/server/session.ts index f64674b129a..ed9f4d8990a 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -2155,12 +2155,14 @@ namespace ts.server { children[lastImportIndex].getEnd()); } - // Blocks with braces should be selected from brace to brace, non-inclusive - const isBetweenBraces = isSyntaxList(node) + // Blocks with braces on separate lines should be selected from brace to brace, + // including whitespace but not including the braces themselves. + const isBetweenMultiLineBraces = isSyntaxList(node) && prevNode && prevNode.kind === SyntaxKind.OpenBraceToken - && nextNode && nextNode.kind === SyntaxKind.CloseBraceToken; - const start = isBetweenBraces ? prevNode.getEnd() : node.getStart(); - const end = isBetweenBraces ? nextNode.getStart() : node.getEnd(); + && nextNode && nextNode.kind === SyntaxKind.CloseBraceToken + && !positionsAreOnSameLine(prevNode.getStart(), nextNode.getStart(), sourceFile); + const start = isBetweenMultiLineBraces ? prevNode.getEnd() : node.getStart(); + const end = isBetweenMultiLineBraces ? nextNode.getStart() : node.getEnd(); pushSelectionRange(start, end, node.kind); // Mapped types _look_ like ObjectTypes with a single member, diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index ce88b4072cc..b4858407ee8 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -199,21 +199,13 @@ type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAn const getSelectionRange = setup("/file.js", ` type X = { foo?: string; - readonly bar: number; + readonly bar: { x: number }; }`); const locations = getSelectionRange([ - { - line: 3, - offset: 5, - }, - { - line: 4, - offset: 5, - }, - { - line: 4, - offset: 14, - }, + { line: 3, offset: 5 }, + { line: 4, offset: 5 }, + { line: 4, offset: 14 }, + { line: 4, offset: 27 }, ]); const allMembersUp: protocol.SelectionRange = { @@ -238,9 +230,9 @@ type X = { start: { line: 4, offset: 5 }, end: { line: 4, offset: 17 } }, parent: { - textSpan: { // readonly bar: number; + textSpan: { // readonly bar: { x: number }; start: { line: 4, offset: 5 }, - end: { line: 4, offset: 26 } }, + end: { line: 4, offset: 33 } }, parent: allMembersUp } }; assert.deepEqual(locations, [ @@ -267,6 +259,19 @@ type X = { start: { line: 4, offset: 14 }, end: { line: 4, offset: 17 } }, parent: readonlyBarUp }, + { + textSpan: { // number + start: { line: 4, offset: 24 }, + end: { line: 4, offset: 30 } }, + parent: { + textSpan: { // x: number + start: { line: 4, offset: 21 }, + end: { line: 4, offset: 30 } }, + parent: { + textSpan: { // { x: number } + start: { line: 4, offset: 19 }, + end: { line: 4, offset: 32 } }, + parent: readonlyBarUp } } }, ]); }); @@ -313,7 +318,7 @@ type X = { ]); }); - it.skip("works for ES2015 import lists", () => { + it("works for ES2015 import lists", () => { const getSelectionRange = setup("/file.ts", ` import { x as y, z } from './z'; import { b } from './'; From 61425cb3047bf7144d910dc710be10e7eb0fe45c Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 11 Apr 2019 15:15:17 -0700 Subject: [PATCH 007/119] Move most logic to separate file --- src/server/selectionRange.ts | 116 +++++++++++++++++ src/server/session.ts | 119 +----------------- src/server/tsconfig.json | 55 ++++---- .../unittests/tsserver/selectionRange.ts | 38 +++--- 4 files changed, 167 insertions(+), 161 deletions(-) create mode 100644 src/server/selectionRange.ts diff --git a/src/server/selectionRange.ts b/src/server/selectionRange.ts new file mode 100644 index 00000000000..60027e330dc --- /dev/null +++ b/src/server/selectionRange.ts @@ -0,0 +1,116 @@ +/* @internal */ +namespace ts.server { + const isImport = or(isImportDeclaration, isImportEqualsDeclaration); + + export function getSelectionRange(pos: number, sourceFile: SourceFile, pushSelectionRange: (start: number, end: number, kind?: SyntaxKind) => void) { + pushSelectionRange(sourceFile.getFullStart(), sourceFile.getEnd(), SyntaxKind.SourceFile); + + // Skip top-level SyntaxList + let parentNode = sourceFile.getChildAt(0); + outer: while (true) { + const children = parentNode.getChildren(sourceFile); + if (!children.length) break; + for (let i = 0; i < children.length; i++) { + const prevNode: Node | undefined = children[i - 1]; + const node: Node = children[i]; + const nextNode: Node | undefined = children[i + 1]; + if (node.getStart(sourceFile) > pos) { + break outer; + } + + if (positionBelongsToNode(node, pos, sourceFile)) { + // Blocks are effectively redundant with SyntaxLists. + // TemplateSpans, along with the SyntaxLists containing them, + // are a somewhat unintuitive grouping of things that should be + // considered independently. Dive in without pushing a selection range. + if (isBlock(node) || isTemplateSpan(node) || isTemplateHead(node) || prevNode && isTemplateHead(prevNode)) { + parentNode = node; + break; + } + + // Synthesize a stop for '${ ... }' since '${' and '}' actually belong to siblings. + if (isTemplateSpan(parentNode) && nextNode && isTemplateMiddleOrTemplateTail(nextNode)) { + const start = node.getFullStart() - "${".length; + const end = nextNode.getStart() + "}".length; + pushSelectionRange(start, end, node.kind); + } + // Synthesize a stop for group of adjacent imports + else if (isImport(node)) { + const [firstImportIndex, lastImportIndex] = getGroupBounds(children, i, isImport); + pushSelectionRange( + children[firstImportIndex].getStart(), + children[lastImportIndex].getEnd()); + } + + // Blocks with braces on separate lines should be selected from brace to brace, + // including whitespace but not including the braces themselves. + const isBetweenMultiLineBraces = isSyntaxList(node) + && prevNode && prevNode.kind === SyntaxKind.OpenBraceToken + && nextNode && nextNode.kind === SyntaxKind.CloseBraceToken + && !positionsAreOnSameLine(prevNode.getStart(), nextNode.getStart(), sourceFile); + const start = isBetweenMultiLineBraces ? prevNode.getEnd() : node.getStart(); + const end = isBetweenMultiLineBraces ? nextNode.getStart() : node.getEnd(); + pushSelectionRange(start, end, node.kind); + + // Mapped types _look_ like ObjectTypes with a single member, + // but in fact don’t contain a SyntaxList or a node containing + // the “key/value” pair like ObjectTypes do, but it seems intuitive + // that the selection would snap to those points. The philosophy + // of choosing a selection range is not so much about what the + // syntax currently _is_ as what the syntax might easily become + // if the user is making a selection; e.g., we synthesize a selection + // around the “key/value” pair not because there’s a node there, but + // because it allows the mapped type to become an object type with a + // few keystrokes. + if (isMappedTypeNode(node)) { + const openBraceToken = Debug.assertDefined(node.getFirstToken()); + const firstNonBraceToken = Debug.assertDefined(node.getChildAt(1)); + const closeBraceToken = Debug.assertDefined(node.getLastToken()); + Debug.assertEqual(openBraceToken.kind, SyntaxKind.OpenBraceToken); + Debug.assertEqual(closeBraceToken.kind, SyntaxKind.CloseBraceToken); + const spanWithoutBraces = [openBraceToken.getEnd(), closeBraceToken.getStart()] as const; + const spanWithoutBracesOrTrivia = [firstNonBraceToken.getStart(), closeBraceToken.getFullStart()] as const; + if (!positionsAreOnSameLine(openBraceToken.getStart(), closeBraceToken.getEnd(), sourceFile)) { + pushSelectionRange(...spanWithoutBraces); + } + pushSelectionRange(...spanWithoutBracesOrTrivia); + } + + // String literals should have a stop both inside and outside their quotes. + else if (isStringLiteral(node) || isTemplateLiteral(node)) { + pushSelectionRange(start + 1, end - 1); + } + + parentNode = node; + break; + } + } + } + } + + function getGroupBounds(array: ArrayLike, index: number, predicate: (element: T) => boolean): [number, number] { + let first = index; + let last = index; + let i = index; + while (i > 0) { + const element = array[--i]; + if (predicate(element)) { + first = i; + } + else { + break; + } + } + i = index; + while (i < array.length - 1) { + const element = array[++i]; + if (predicate(element)) { + last = i; + } + else { + break; + } + } + return [first, last]; + } +} diff --git a/src/server/session.ts b/src/server/session.ts index ed9f4d8990a..68c34d27b26 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -112,32 +112,6 @@ namespace ts.server { return edits.every(edit => textSpanEnd(edit.span) < pos); } - function getGroupBounds(array: ArrayLike, index: number, predicate: (element: T) => boolean): [number, number] { - let first = index; - let last = index; - let i = index; - while (i > 0) { - const element = array[--i]; - if (predicate(element)) { - first = i; - } - else { - break; - } - } - i = index; - while (i < array.length - 1) { - const element = array[++i]; - if (predicate(element)) { - last = i; - } - else { - break; - } - } - return [first, last]; - } - // CommandNames used to be exposed before TS 2.4 as a namespace // In TS 2.4 we switched to an enum, keep this for backward compatibility // The var assignment ensures that even though CommandTypes are a const enum @@ -2097,107 +2071,26 @@ namespace ts.server { const { locations } = args; const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args); - const isImport = or(isImportDeclaration, isImportEqualsDeclaration); + const sourceFile = languageService.getNonBoundSourceFile(file); const scriptInfo = Debug.assertDefined(this.projectService.getScriptInfo(file)); - const fullTextSpan = this.toLocationTextSpan( - createTextSpanFromBounds(sourceFile.getFullStart(), sourceFile.getEnd()), - scriptInfo); return map(locations, location => { const pos = this.getPosition(location, scriptInfo); - let selectionRange: protocol.SelectionRange = { textSpan: fullTextSpan }; + let selectionRange: protocol.SelectionRange | undefined; const pushSelectionRange = (start: number, end: number, syntaxKind?: SyntaxKind): void => { // Skip ranges that are identical to the parent const textSpan = this.toLocationTextSpan(createTextSpanFromBounds(start, end), scriptInfo); - if (!this.locationTextSpansAreEqual(textSpan, selectionRange.textSpan)) { - selectionRange = { textSpan, parent: selectionRange }; + if (!selectionRange || !this.locationTextSpansAreEqual(textSpan, selectionRange.textSpan)) { + selectionRange = { textSpan, ...selectionRange && { parent: selectionRange } }; if (syntaxKind) { Object.defineProperty(selectionRange, "__debugKind", { value: formatSyntaxKind(syntaxKind) }); } } }; - // Skip top-level SyntaxList - let parentNode = sourceFile.getChildAt(0); - outer: while (true) { - const children = parentNode.getChildren(sourceFile); - if (!children.length) break; - for (let i = 0; i < children.length; i++) { - const prevNode: Node | undefined = children[i - 1]; - const node: Node = children[i]; - const nextNode: Node | undefined = children[i + 1]; - if (node.getStart(sourceFile) > pos) { - break outer; - } - - if (positionBelongsToNode(node, pos, sourceFile)) { - // Blocks are effectively redundant with SyntaxLists. - // TemplateSpans, along with the SyntaxLists containing them, - // are a somewhat unintuitive grouping of things that should be - // considered independently. Dive in without pushing a selection range. - if (isBlock(node) || isTemplateSpan(node) || isTemplateHead(node) || prevNode && isTemplateHead(prevNode)) { - parentNode = node; - break; - } - - // Synthesize a stop for '${ ... }' since '${' and '}' actually belong to siblings. - if (isTemplateSpan(parentNode) && nextNode && isTemplateMiddleOrTemplateTail(nextNode)) { - const start = node.getFullStart() - "${".length; - const end = nextNode.getStart() + "}".length; - pushSelectionRange(start, end, node.kind); - } - // Synthesize a stop for group of adjacent imports - else if (isImport(node)) { - const [firstImportIndex, lastImportIndex] = getGroupBounds(children, i, isImport); - pushSelectionRange( - children[firstImportIndex].getStart(), - children[lastImportIndex].getEnd()); - } - - // Blocks with braces on separate lines should be selected from brace to brace, - // including whitespace but not including the braces themselves. - const isBetweenMultiLineBraces = isSyntaxList(node) - && prevNode && prevNode.kind === SyntaxKind.OpenBraceToken - && nextNode && nextNode.kind === SyntaxKind.CloseBraceToken - && !positionsAreOnSameLine(prevNode.getStart(), nextNode.getStart(), sourceFile); - const start = isBetweenMultiLineBraces ? prevNode.getEnd() : node.getStart(); - const end = isBetweenMultiLineBraces ? nextNode.getStart() : node.getEnd(); - pushSelectionRange(start, end, node.kind); - - // Mapped types _look_ like ObjectTypes with a single member, - // but in fact don’t contain a SyntaxList or a node containing - // the “key/value” pair like ObjectTypes do, but it seems intuitive - // that the selection would snap to those points. The philosophy - // of choosing a selection range is not so much about what the - // syntax currently _is_ as what the syntax might easily become - // if the user is making a selection; e.g., we synthesize a selection - // around the “key/value” pair not because there’s a node there, but - // because it allows the mapped type to become an object type with a - // few keystrokes. - if (isMappedTypeNode(node)) { - const openBraceToken = Debug.assertDefined(node.getFirstToken()); - const firstNonBraceToken = Debug.assertDefined(node.getChildAt(1)); - const closeBraceToken = Debug.assertDefined(node.getLastToken()); - Debug.assertEqual(openBraceToken.kind, SyntaxKind.OpenBraceToken); - Debug.assertEqual(closeBraceToken.kind, SyntaxKind.CloseBraceToken); - const spanWithoutBraces = [openBraceToken.getEnd(), closeBraceToken.getStart()] as const; - const spanWithoutBracesOrTrivia = [firstNonBraceToken.getStart(), closeBraceToken.getFullStart()] as const; - pushSelectionRange(...spanWithoutBraces); - pushSelectionRange(...spanWithoutBracesOrTrivia); - } - - // String literals should have a stop both inside and outside their quotes. - else if (isStringLiteral(node) || isTemplateLiteral(node)) { - pushSelectionRange(start + 1, end - 1); - } - - parentNode = node; - break; - } - } - } - return selectionRange; + getSelectionRange(pos, sourceFile, pushSelectionRange); + return selectionRange!; }); } diff --git a/src/server/tsconfig.json b/src/server/tsconfig.json index 3cf28ab40ee..d4f2edb39be 100644 --- a/src/server/tsconfig.json +++ b/src/server/tsconfig.json @@ -1,27 +1,28 @@ -{ - "extends": "../tsconfig-base", - "compilerOptions": { - "removeComments": false, - "outFile": "../../built/local/server.js", - "preserveConstEnums": true, - "types": [ - "node" - ] - }, - "references": [ - { "path": "../compiler" }, - { "path": "../jsTyping" }, - { "path": "../services" } - ], - "files": [ - "types.ts", - "utilities.ts", - "protocol.ts", - "scriptInfo.ts", - "typingsCache.ts", - "project.ts", - "editorServices.ts", - "session.ts", - "scriptVersionCache.ts" - ] -} +{ + "extends": "../tsconfig-base", + "compilerOptions": { + "removeComments": false, + "outFile": "../../built/local/server.js", + "preserveConstEnums": true, + "types": [ + "node" + ] + }, + "references": [ + { "path": "../compiler" }, + { "path": "../jsTyping" }, + { "path": "../services" } + ], + "files": [ + "types.ts", + "utilities.ts", + "protocol.ts", + "scriptInfo.ts", + "typingsCache.ts", + "project.ts", + "editorServices.ts", + "selectionRange.ts", + "session.ts", + "scriptVersionCache.ts" + ] +} diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index b4858407ee8..c2261e041e0 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -164,38 +164,34 @@ type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAn textSpan: { // [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; start: { line: 2, offset: 54 }, end: { line: 2, offset: 143 } }, - parent: { // same as above + whitespace - textSpan: { - start: { line: 2, offset: 53 }, - end: { line: 2, offset: 144 } }, + parent: { + textSpan: { // MappedType: same as above + braces + start: { line: 2, offset: 52 }, + end: { line: 2, offset: 145 } }, parent: { - textSpan: { // MappedType: same as above + braces + textSpan: { // IntersectionType: { [K in keyof P]: ... } & Pick> start: { line: 2, offset: 52 }, - end: { line: 2, offset: 145 } }, + end: { line: 2, offset: 182 } }, parent: { - textSpan: { // IntersectionType: { [K in keyof P]: ... } & Pick> - start: { line: 2, offset: 52 }, - end: { line: 2, offset: 182 } }, + textSpan: { // same as above + parens + start: { line: 2, offset: 51 }, + end: { line: 2, offset: 183 } }, parent: { - textSpan: { // same as above + parens - start: { line: 2, offset: 51 }, + textSpan: { // Whole TypeNode of TypeAliasDeclaration + start: { line: 2, offset: 16 }, end: { line: 2, offset: 183 } }, parent: { - textSpan: { // Whole TypeNode of TypeAliasDeclaration - start: { line: 2, offset: 16 }, + textSpan: { // Whole TypeAliasDeclaration + start: { line: 2, offset: 1 }, end: { line: 2, offset: 183 } }, parent: { - textSpan: { // Whole TypeAliasDeclaration - start: { line: 2, offset: 1 }, - end: { line: 2, offset: 183 } }, - parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 2, offset: 184 } } } } } } } } } } } } } }, + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 2, offset: 184 } } } } } } } } } } } } }, ]); }); - it.skip("works for object types", () => { + it("works for object types", () => { const getSelectionRange = setup("/file.js", ` type X = { foo?: string; From 0f7bc0289230a78a4ebc7b21005761034c87b665 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 11 Apr 2019 17:32:40 -0700 Subject: [PATCH 008/119] Move to language service --- src/harness/client.ts | 4 ++ src/harness/harnessLanguageService.ts | 3 ++ src/server/protocol.ts | 2 + src/server/session.ts | 46 +++++++++------------- src/server/tsconfig.json | 1 - src/{server => services}/selectionRange.ts | 31 +++++++++++++-- src/services/services.ts | 5 +++ src/services/shims.ts | 8 ++++ src/services/tsconfig.json | 1 + src/services/types.ts | 7 ++++ 10 files changed, 76 insertions(+), 32 deletions(-) rename src/{server => services}/selectionRange.ts (77%) diff --git a/src/harness/client.ts b/src/harness/client.ts index 03d53344616..bb9e674bbc6 100644 --- a/src/harness/client.ts +++ b/src/harness/client.ts @@ -424,6 +424,10 @@ namespace ts.server { return renameInfo; } + getSelectionRange() { + return notImplemented(); + } + findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean): RenameLocation[] { if (!this.lastRenameEntry || this.lastRenameEntry.inputs.fileName !== fileName || diff --git a/src/harness/harnessLanguageService.ts b/src/harness/harnessLanguageService.ts index b70afecb791..fff02e5b94a 100644 --- a/src/harness/harnessLanguageService.ts +++ b/src/harness/harnessLanguageService.ts @@ -472,6 +472,9 @@ namespace Harness.LanguageService { getRenameInfo(fileName: string, position: number, options?: ts.RenameInfoOptions): ts.RenameInfo { return unwrapJSONCallResult(this.shim.getRenameInfo(fileName, position, options)); } + getSelectionRange(fileName: string, position: number): ts.SelectionRange { + return unwrapJSONCallResult(this.shim.getSelectionRange(fileName, position)); + } findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean, providePrefixAndSuffixTextForRename?: boolean): ts.RenameLocation[] { return unwrapJSONCallResult(this.shim.findRenameLocations(fileName, position, findInStrings, findInComments, providePrefixAndSuffixTextForRename)); } diff --git a/src/server/protocol.ts b/src/server/protocol.ts index 1709c6196ef..02ebee1efc5 100644 --- a/src/server/protocol.ts +++ b/src/server/protocol.ts @@ -132,6 +132,8 @@ namespace ts.server.protocol { GetEditsForFileRenameFull = "getEditsForFileRename-full", ConfigurePlugin = "configurePlugin", SelectionRange = "selectionRange", + /* @internal */ + SelectionRangeFull = "selectionRange-full", // NOTE: If updating this, be sure to also update `allCommandNames` in `harness/unittests/session.ts`. } diff --git a/src/server/session.ts b/src/server/session.ts index 68c34d27b26..261356f2cd0 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -1744,14 +1744,6 @@ namespace ts.server { }; } - private locationsAreEqual(a: protocol.Location, b: protocol.Location): boolean { - return a.line === b.line && a.offset === b.offset; - } - - private locationTextSpansAreEqual(a: protocol.TextSpan, b: protocol.TextSpan): boolean { - return this.locationsAreEqual(a.start, b.start) && this.locationsAreEqual(a.end, b.end); - } - private getNavigationTree(args: protocol.FileRequestArgs, simplifiedResult: boolean): protocol.NavigationTree | NavigationTree | undefined { const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args); const tree = languageService.getNavigationTree(file); @@ -2067,33 +2059,28 @@ namespace ts.server { this.projectService.configurePlugin(args); } - private getSelectionRange(args: protocol.SelectionRangeRequestArgs): protocol.SelectionRange[] { + private getSelectionRange(args: protocol.SelectionRangeRequestArgs, simplifiedResult: boolean) { const { locations } = args; const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args); - - - const sourceFile = languageService.getNonBoundSourceFile(file); const scriptInfo = Debug.assertDefined(this.projectService.getScriptInfo(file)); return map(locations, location => { const pos = this.getPosition(location, scriptInfo); - let selectionRange: protocol.SelectionRange | undefined; - const pushSelectionRange = (start: number, end: number, syntaxKind?: SyntaxKind): void => { - // Skip ranges that are identical to the parent - const textSpan = this.toLocationTextSpan(createTextSpanFromBounds(start, end), scriptInfo); - if (!selectionRange || !this.locationTextSpansAreEqual(textSpan, selectionRange.textSpan)) { - selectionRange = { textSpan, ...selectionRange && { parent: selectionRange } }; - if (syntaxKind) { - Object.defineProperty(selectionRange, "__debugKind", { value: formatSyntaxKind(syntaxKind) }); - } - } - }; - - getSelectionRange(pos, sourceFile, pushSelectionRange); - return selectionRange!; + const selectionRange = languageService.getSelectionRange(file, pos); + return simplifiedResult ? this.mapSelectionRange(selectionRange, scriptInfo) : selectionRange; }); } + private mapSelectionRange(selectionRange: SelectionRange, scriptInfo: ScriptInfo): protocol.SelectionRange { + const result: protocol.SelectionRange = { + textSpan: this.toLocationTextSpan(selectionRange.textSpan, scriptInfo), + }; + if (selectionRange.parent) { + result.parent = this.mapSelectionRange(selectionRange.parent, scriptInfo); + } + return result; + } + getCanonicalFileName(fileName: string) { const name = this.host.useCaseSensitiveFileNames ? fileName : fileName.toLowerCase(); return normalizePath(name); @@ -2451,8 +2438,11 @@ namespace ts.server { return this.notRequired(); }, [CommandNames.SelectionRange]: (request: protocol.SelectionRangeRequest) => { - return this.requiredResponse(this.getSelectionRange(request.arguments)); - } + return this.requiredResponse(this.getSelectionRange(request.arguments, /*simplifiedResult*/ true)); + }, + [CommandNames.SelectionRangeFull]: (request: protocol.SelectionRangeRequest) => { + return this.requiredResponse(this.getSelectionRange(request.arguments, /*simplifiedResult*/ false)); + }, }); public addProtocolHandler(command: string, handler: (request: protocol.Request) => HandlerResponse) { diff --git a/src/server/tsconfig.json b/src/server/tsconfig.json index d4f2edb39be..1410440512b 100644 --- a/src/server/tsconfig.json +++ b/src/server/tsconfig.json @@ -21,7 +21,6 @@ "typingsCache.ts", "project.ts", "editorServices.ts", - "selectionRange.ts", "session.ts", "scriptVersionCache.ts" ] diff --git a/src/server/selectionRange.ts b/src/services/selectionRange.ts similarity index 77% rename from src/server/selectionRange.ts rename to src/services/selectionRange.ts index 60027e330dc..7abff8cda88 100644 --- a/src/server/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -1,9 +1,11 @@ /* @internal */ -namespace ts.server { +namespace ts.SelectionRange { const isImport = or(isImportDeclaration, isImportEqualsDeclaration); - export function getSelectionRange(pos: number, sourceFile: SourceFile, pushSelectionRange: (start: number, end: number, kind?: SyntaxKind) => void) { - pushSelectionRange(sourceFile.getFullStart(), sourceFile.getEnd(), SyntaxKind.SourceFile); + export function getSelectionRange(pos: number, sourceFile: SourceFile): ts.SelectionRange { + let selectionRange: SelectionRange = { + textSpan: createTextSpanFromBounds(sourceFile.getFullStart(), sourceFile.getEnd()) + }; // Skip top-level SyntaxList let parentNode = sourceFile.getChildAt(0); @@ -86,8 +88,31 @@ namespace ts.server { } } } + + return selectionRange; + + function pushSelectionRange(start: number, end: number, syntaxKind?: SyntaxKind): void { + // Skip ranges that are identical to the parent + const textSpan = createTextSpanFromBounds(start, end); + if (!selectionRange || !textSpansEqual(textSpan, selectionRange.textSpan)) { + selectionRange = { textSpan, ...selectionRange && { parent: selectionRange } }; + if (syntaxKind) { + Object.defineProperty(selectionRange, "__debugKind", { value: formatSyntaxKind(syntaxKind) }); + } + } + } } + // function getSiblingExpansionRule(parentNode: T): (SyntaxKind | SyntaxKind[])[] | undefined { + // switch (parentNode.kind) { + // case SyntaxKind.BindingElement: return [SyntaxKind.Identifier, SyntaxKind.DotDotDotToken]; + // case SyntaxKind.Parameter: return [SyntaxKind.Identifier, SyntaxKind.DotDotDotToken, SyntaxKind.QuestionToken]; + // case SyntaxKind.PropertySignature: return [SyntaxKind.Identifier, SyntaxKind.QuestionToken, SyntaxKind.SyntaxList]; + // case SyntaxKind.ElementAccessExpression: return [[SyntaxKind.OpenBracketToken, SyntaxKind.CloseBracketToken]]; + // case SyntaxKind.IndexedAccessType: return [[SyntaxKind.OpenBracketToken, SyntaxKind.CloseBracketToken]]; + // } + // } + function getGroupBounds(array: ArrayLike, index: number, predicate: (element: T) => boolean): [number, number] { let first = index; let last = index; diff --git a/src/services/services.ts b/src/services/services.ts index 5f0d3472a3e..721777c2bad 100644 --- a/src/services/services.ts +++ b/src/services/services.ts @@ -2087,6 +2087,10 @@ namespace ts { }; } + function getSelectionRange(fileName: string, position: number): SelectionRange { + return SelectionRange.getSelectionRange(position, syntaxTreeCache.getCurrentSourceFile(fileName)); + } + function getApplicableRefactors(fileName: string, positionOrRange: number | TextRange, preferences: UserPreferences = emptyOptions): ApplicableRefactorInfo[] { synchronizeHostData(); const file = getValidSourceFile(fileName); @@ -2134,6 +2138,7 @@ namespace ts { getBreakpointStatementAtPosition, getNavigateToItems, getRenameInfo, + getSelectionRange, findRenameLocations, getNavigationBarItems, getNavigationTree, diff --git a/src/services/shims.ts b/src/services/shims.ts index 208cf3dbc3c..3f3b3c2bef6 100644 --- a/src/services/shims.ts +++ b/src/services/shims.ts @@ -165,6 +165,7 @@ namespace ts { * { canRename: boolean, localizedErrorMessage: string, displayName: string, fullDisplayName: string, kind: string, kindModifiers: string, triggerSpan: { start; length } } */ getRenameInfo(fileName: string, position: number, options?: RenameInfoOptions): string; + getSelectionRange(fileName: string, position: number): string; /** * Returns a JSON-encoded value of the type: @@ -838,6 +839,13 @@ namespace ts { ); } + public getSelectionRange(fileName: string, position: number): string { + return this.forwardJSONCall( + `getSelectionRange('${fileName}', ${position})`, + () => this.languageService.getSelectionRange(fileName, position) + ); + } + public findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean, providePrefixAndSuffixTextForRename?: boolean): string { return this.forwardJSONCall( `findRenameLocations('${fileName}', ${position}, ${findInStrings}, ${findInComments}, ${providePrefixAndSuffixTextForRename})`, diff --git a/src/services/tsconfig.json b/src/services/tsconfig.json index e3f2358be10..a456fbb957f 100644 --- a/src/services/tsconfig.json +++ b/src/services/tsconfig.json @@ -28,6 +28,7 @@ "patternMatcher.ts", "preProcess.ts", "rename.ts", + "selectionRange.ts", "signatureHelp.ts", "sourcemaps.ts", "suggestionDiagnostics.ts", diff --git a/src/services/types.ts b/src/services/types.ts index 3502e3e0671..d3c9de0f332 100644 --- a/src/services/types.ts +++ b/src/services/types.ts @@ -297,6 +297,8 @@ namespace ts { getRenameInfo(fileName: string, position: number, options?: RenameInfoOptions): RenameInfo; findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean, providePrefixAndSuffixTextForRename?: boolean): ReadonlyArray | undefined; + getSelectionRange(fileName: string, position: number): SelectionRange; + getDefinitionAtPosition(fileName: string, position: number): ReadonlyArray | undefined; getDefinitionAndBoundSpan(fileName: string, position: number): DefinitionInfoAndBoundSpan | undefined; getTypeDefinitionAtPosition(fileName: string, position: number): ReadonlyArray | undefined; @@ -859,6 +861,11 @@ namespace ts { isOptional: boolean; } + export interface SelectionRange { + textSpan: TextSpan; + parent?: SelectionRange; + } + /** * Represents a single signature to show in signature help. * The id is used for subsequent calls into the language service to ask questions about the From 70e2672ab3b765672de00502ae8f6347669423ea Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Fri, 12 Apr 2019 10:53:20 -0700 Subject: [PATCH 009/119] Add rules for expanding selection to sibling nodes --- src/services/selectionRange.ts | 51 +++++++++++--- .../unittests/tsserver/selectionRange.ts | 67 ++++++++++--------- 2 files changed, 74 insertions(+), 44 deletions(-) diff --git a/src/services/selectionRange.ts b/src/services/selectionRange.ts index 7abff8cda88..3a3c0cba086 100644 --- a/src/services/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -13,9 +13,9 @@ namespace ts.SelectionRange { const children = parentNode.getChildren(sourceFile); if (!children.length) break; for (let i = 0; i < children.length; i++) { - const prevNode: Node | undefined = children[i - 1]; + let prevNode: Node | undefined = children[i - 1]; const node: Node = children[i]; - const nextNode: Node | undefined = children[i + 1]; + let nextNode: Node | undefined = children[i + 1]; if (node.getStart(sourceFile) > pos) { break outer; } @@ -30,6 +30,26 @@ namespace ts.SelectionRange { break; } + const siblingExpansionRule = getSiblingExpansionRule(parentNode); + let expansionCandidate: SyntaxKind | [SyntaxKind, SyntaxKind] | undefined; + while ((prevNode || nextNode) && (expansionCandidate = siblingExpansionRule.shift())) { + if (isArray(expansionCandidate) + && prevNode && prevNode.kind === expansionCandidate[0] + && nextNode && nextNode.kind === expansionCandidate[1]) { + pushSelectionRange(prevNode.getStart(), nextNode.getEnd()); + prevNode = children[children.indexOf(prevNode) - 1]; + nextNode = children[children.indexOf(nextNode) + 1]; + } + else if (prevNode && prevNode.kind === expansionCandidate) { + pushSelectionRange(prevNode.getStart(), node.getEnd()); + prevNode = children[children.indexOf(prevNode) - 1]; + } + else if (nextNode && nextNode.kind === expansionCandidate) { + pushSelectionRange(node.getStart(), nextNode.getEnd()); + nextNode = children[children.indexOf(nextNode) + 1]; + } + } + // Synthesize a stop for '${ ... }' since '${' and '}' actually belong to siblings. if (isTemplateSpan(parentNode) && nextNode && isTemplateMiddleOrTemplateTail(nextNode)) { const start = node.getFullStart() - "${".length; @@ -103,15 +123,24 @@ namespace ts.SelectionRange { } } - // function getSiblingExpansionRule(parentNode: T): (SyntaxKind | SyntaxKind[])[] | undefined { - // switch (parentNode.kind) { - // case SyntaxKind.BindingElement: return [SyntaxKind.Identifier, SyntaxKind.DotDotDotToken]; - // case SyntaxKind.Parameter: return [SyntaxKind.Identifier, SyntaxKind.DotDotDotToken, SyntaxKind.QuestionToken]; - // case SyntaxKind.PropertySignature: return [SyntaxKind.Identifier, SyntaxKind.QuestionToken, SyntaxKind.SyntaxList]; - // case SyntaxKind.ElementAccessExpression: return [[SyntaxKind.OpenBracketToken, SyntaxKind.CloseBracketToken]]; - // case SyntaxKind.IndexedAccessType: return [[SyntaxKind.OpenBracketToken, SyntaxKind.CloseBracketToken]]; - // } - // } + function getSiblingExpansionRule(parentNode: T): (SyntaxKind | [SyntaxKind, SyntaxKind])[] { + switch (parentNode.kind) { + case SyntaxKind.BindingElement: return [SyntaxKind.Identifier, SyntaxKind.DotDotDotToken]; + case SyntaxKind.Parameter: return [SyntaxKind.Identifier, SyntaxKind.DotDotDotToken, SyntaxKind.QuestionToken]; + case SyntaxKind.PropertySignature: return [SyntaxKind.Identifier, SyntaxKind.QuestionToken, SyntaxKind.SyntaxList]; + case SyntaxKind.ElementAccessExpression: return [[SyntaxKind.OpenBracketToken, SyntaxKind.CloseBracketToken]]; + case SyntaxKind.MappedType: return [ + SyntaxKind.TypeParameter, + [SyntaxKind.OpenBracketToken, SyntaxKind.CloseBracketToken], + SyntaxKind.MinusToken, + SyntaxKind.PlusToken, + SyntaxKind.ReadonlyKeyword, + SyntaxKind.MinusToken, + SyntaxKind.PlusToken, + ]; + default: return []; + } + } function getGroupBounds(array: ArrayLike, index: number, predicate: (element: T) => boolean): [number, number] { let first = index; diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index c2261e041e0..88bc0a6ad10 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -231,44 +231,45 @@ type X = { end: { line: 4, offset: 33 } }, parent: allMembersUp } }; - assert.deepEqual(locations, [ - { - textSpan: { // foo + assert.deepEqual(locations![0], { + textSpan: { // foo + start: { line: 3, offset: 5 }, + end: { line: 3, offset: 8 } }, + parent: { + textSpan: { // foo? start: { line: 3, offset: 5 }, - end: { line: 3, offset: 8 } }, + end: { line: 3, offset: 9 } }, parent: { - textSpan: { // foo? + textSpan: { // foo?: string; start: { line: 3, offset: 5 }, - end: { line: 3, offset: 9 } }, - parent: { - textSpan: { // foo?: string; - start: { line: 3, offset: 5 }, - end: { line: 3, offset: 18 } }, - parent: allMembersUp } } }, - { - textSpan: { // readonly - start: { line: 4, offset: 5 }, - end: { line: 4, offset: 13 } }, - parent: readonlyBarUp }, - { - textSpan: { // bar - start: { line: 4, offset: 14 }, - end: { line: 4, offset: 17 } }, - parent: readonlyBarUp }, - { - textSpan: { // number - start: { line: 4, offset: 24 }, + end: { line: 3, offset: 18 } }, + parent: allMembersUp } } }); + + assert.deepEqual(locations![1], { + textSpan: { // readonly + start: { line: 4, offset: 5 }, + end: { line: 4, offset: 13 } }, + parent: readonlyBarUp }); + + assert.deepEqual(locations![2], { + textSpan: { // bar + start: { line: 4, offset: 14 }, + end: { line: 4, offset: 17 } }, + parent: readonlyBarUp }); + + assert.deepEqual(locations![3], { + textSpan: { // number + start: { line: 4, offset: 24 }, + end: { line: 4, offset: 30 } }, + parent: { + textSpan: { // x: number + start: { line: 4, offset: 21 }, end: { line: 4, offset: 30 } }, parent: { - textSpan: { // x: number - start: { line: 4, offset: 21 }, - end: { line: 4, offset: 30 } }, - parent: { - textSpan: { // { x: number } - start: { line: 4, offset: 19 }, - end: { line: 4, offset: 32 } }, - parent: readonlyBarUp } } }, - ]); + textSpan: { // { x: number } + start: { line: 4, offset: 19 }, + end: { line: 4, offset: 32 } }, + parent: readonlyBarUp.parent } } }); }); it("works for string literals and template strings", () => { From fcb7f0152fc8d430510b6b94e52c49e341f0920d Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Sun, 14 Apr 2019 13:58:04 -0700 Subject: [PATCH 010/119] Rethink sibling expansion by creating fake subtrees --- src/compiler/utilities.ts | 1 + src/services/selectionRange.ts | 110 ++++++++---------- .../unittests/tsserver/selectionRange.ts | 50 +++++++- 3 files changed, 96 insertions(+), 65 deletions(-) diff --git a/src/compiler/utilities.ts b/src/compiler/utilities.ts index 2e6c3ae4f86..91f6e3b4218 100644 --- a/src/compiler/utilities.ts +++ b/src/compiler/utilities.ts @@ -7624,6 +7624,7 @@ namespace ts { return root + pathComponents.slice(1).join(directorySeparator); } + } /* @internal */ diff --git a/src/services/selectionRange.ts b/src/services/selectionRange.ts index 3a3c0cba086..631ec25fc09 100644 --- a/src/services/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -2,7 +2,7 @@ namespace ts.SelectionRange { const isImport = or(isImportDeclaration, isImportEqualsDeclaration); - export function getSelectionRange(pos: number, sourceFile: SourceFile): ts.SelectionRange { + export function getSelectionRange(pos: number, sourceFile: SourceFile): SelectionRange { let selectionRange: SelectionRange = { textSpan: createTextSpanFromBounds(sourceFile.getFullStart(), sourceFile.getEnd()) }; @@ -10,12 +10,12 @@ namespace ts.SelectionRange { // Skip top-level SyntaxList let parentNode = sourceFile.getChildAt(0); outer: while (true) { - const children = parentNode.getChildren(sourceFile); + const children = getSelectionChildren(parentNode); if (!children.length) break; for (let i = 0; i < children.length; i++) { - let prevNode: Node | undefined = children[i - 1]; + const prevNode: Node | undefined = children[i - 1]; const node: Node = children[i]; - let nextNode: Node | undefined = children[i + 1]; + const nextNode: Node | undefined = children[i + 1]; if (node.getStart(sourceFile) > pos) { break outer; } @@ -30,26 +30,6 @@ namespace ts.SelectionRange { break; } - const siblingExpansionRule = getSiblingExpansionRule(parentNode); - let expansionCandidate: SyntaxKind | [SyntaxKind, SyntaxKind] | undefined; - while ((prevNode || nextNode) && (expansionCandidate = siblingExpansionRule.shift())) { - if (isArray(expansionCandidate) - && prevNode && prevNode.kind === expansionCandidate[0] - && nextNode && nextNode.kind === expansionCandidate[1]) { - pushSelectionRange(prevNode.getStart(), nextNode.getEnd()); - prevNode = children[children.indexOf(prevNode) - 1]; - nextNode = children[children.indexOf(nextNode) + 1]; - } - else if (prevNode && prevNode.kind === expansionCandidate) { - pushSelectionRange(prevNode.getStart(), node.getEnd()); - prevNode = children[children.indexOf(prevNode) - 1]; - } - else if (nextNode && nextNode.kind === expansionCandidate) { - pushSelectionRange(node.getStart(), nextNode.getEnd()); - nextNode = children[children.indexOf(nextNode) + 1]; - } - } - // Synthesize a stop for '${ ... }' since '${' and '}' actually belong to siblings. if (isTemplateSpan(parentNode) && nextNode && isTemplateMiddleOrTemplateTail(nextNode)) { const start = node.getFullStart() - "${".length; @@ -74,32 +54,8 @@ namespace ts.SelectionRange { const end = isBetweenMultiLineBraces ? nextNode.getStart() : node.getEnd(); pushSelectionRange(start, end, node.kind); - // Mapped types _look_ like ObjectTypes with a single member, - // but in fact don’t contain a SyntaxList or a node containing - // the “key/value” pair like ObjectTypes do, but it seems intuitive - // that the selection would snap to those points. The philosophy - // of choosing a selection range is not so much about what the - // syntax currently _is_ as what the syntax might easily become - // if the user is making a selection; e.g., we synthesize a selection - // around the “key/value” pair not because there’s a node there, but - // because it allows the mapped type to become an object type with a - // few keystrokes. - if (isMappedTypeNode(node)) { - const openBraceToken = Debug.assertDefined(node.getFirstToken()); - const firstNonBraceToken = Debug.assertDefined(node.getChildAt(1)); - const closeBraceToken = Debug.assertDefined(node.getLastToken()); - Debug.assertEqual(openBraceToken.kind, SyntaxKind.OpenBraceToken); - Debug.assertEqual(closeBraceToken.kind, SyntaxKind.CloseBraceToken); - const spanWithoutBraces = [openBraceToken.getEnd(), closeBraceToken.getStart()] as const; - const spanWithoutBracesOrTrivia = [firstNonBraceToken.getStart(), closeBraceToken.getFullStart()] as const; - if (!positionsAreOnSameLine(openBraceToken.getStart(), closeBraceToken.getEnd(), sourceFile)) { - pushSelectionRange(...spanWithoutBraces); - } - pushSelectionRange(...spanWithoutBracesOrTrivia); - } - // String literals should have a stop both inside and outside their quotes. - else if (isStringLiteral(node) || isTemplateLiteral(node)) { + if (isStringLiteral(node) || isTemplateLiteral(node)) { pushSelectionRange(start + 1, end - 1); } @@ -123,23 +79,49 @@ namespace ts.SelectionRange { } } - function getSiblingExpansionRule(parentNode: T): (SyntaxKind | [SyntaxKind, SyntaxKind])[] { - switch (parentNode.kind) { - case SyntaxKind.BindingElement: return [SyntaxKind.Identifier, SyntaxKind.DotDotDotToken]; - case SyntaxKind.Parameter: return [SyntaxKind.Identifier, SyntaxKind.DotDotDotToken, SyntaxKind.QuestionToken]; - case SyntaxKind.PropertySignature: return [SyntaxKind.Identifier, SyntaxKind.QuestionToken, SyntaxKind.SyntaxList]; - case SyntaxKind.ElementAccessExpression: return [[SyntaxKind.OpenBracketToken, SyntaxKind.CloseBracketToken]]; - case SyntaxKind.MappedType: return [ - SyntaxKind.TypeParameter, - [SyntaxKind.OpenBracketToken, SyntaxKind.CloseBracketToken], - SyntaxKind.MinusToken, - SyntaxKind.PlusToken, - SyntaxKind.ReadonlyKeyword, - SyntaxKind.MinusToken, - SyntaxKind.PlusToken, + function getSelectionChildren(node: Node): ReadonlyArray { + // Mapped types _look_ like ObjectTypes with a single member, + // but in fact don’t contain a SyntaxList or a node containing + // the “key/value” pair like ObjectTypes do, but it seems intuitive + // that the selection would snap to those points. The philosophy + // of choosing a selection range is not so much about what the + // syntax currently _is_ as what the syntax might easily become + // if the user is making a selection; e.g., we synthesize a selection + // around the “key/value” pair not because there’s a node there, but + // because it allows the mapped type to become an object type with a + // few keystrokes. + if (isMappedTypeNode(node)) { + const [openBraceToken, ...children] = node.getChildren(); + const closeBraceToken = Debug.assertDefined(children.pop()); + Debug.assertEqual(openBraceToken.kind, SyntaxKind.OpenBraceToken); + Debug.assertEqual(closeBraceToken.kind, SyntaxKind.CloseBraceToken); + const colonTokenIndex = findIndex(children, child => child.kind === SyntaxKind.ColonToken); + const typeNodeIndex = node.type && children.indexOf(node.type); + const leftChildren = children.slice(0, colonTokenIndex); + const colonToken = Debug.assertDefined(children[colonTokenIndex]); + const rightChildren = children.slice(colonTokenIndex + 1, typeNodeIndex && (typeNodeIndex + 1)); + // Possible semicolon + const extraChildren = typeNodeIndex && typeNodeIndex > -1 ? children.slice(typeNodeIndex + 1) : []; + const syntaxList = createSyntaxList([ + createSyntaxList(leftChildren), + colonToken, + createSyntaxList(rightChildren), + createSyntaxList(extraChildren), + ]); + return [ + openBraceToken, + syntaxList, + closeBraceToken, ]; - default: return []; } + return node.getChildren(); + } + + function createSyntaxList(children: Node[]): SyntaxList { + Debug.assertGreaterThanOrEqual(children.length, 1); + const syntaxList = createNode(SyntaxKind.SyntaxList, children[0].pos, last(children).end) as SyntaxList; + syntaxList._children = children; + return syntaxList; } function getGroupBounds(array: ArrayLike, index: number, predicate: (element: T) => boolean): [number, number] { diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 88bc0a6ad10..837607a58f2 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -191,7 +191,7 @@ type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAn ]); }); - it("works for object types", () => { + it.skip("works for object types", () => { const getSelectionRange = setup("/file.js", ` type X = { foo?: string; @@ -354,5 +354,53 @@ console.log(1);`); end: { line: 5, offset: 16 } } } } } } } } } ]); }); + + it.skip("works for complex mapped types", () => { + const getSelectionRange = setup("/file.ts", ` +type M = { -readonly [K in keyof any]-?: any };`); + + const locations = getSelectionRange([ + { line: 2, offset: 12 }, // -readonly + { line: 2, offset: 14 }, // eadonly + { line: 2, offset: 22 }, // [ + { line: 2, offset: 30 }, // yof any + { line: 2, offset: 38 }, // -? + { line: 2, offset: 39 }, // ? + ]); + + assert.deepEqual(locations![0], { + textSpan: { // - + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 13 } }, + parent: { + textSpan: { // -readonly + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 21 } }, + parent: { + textSpan: { // -readonly [K in keyof any] + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 38 } }, + parent: { + textSpan: { // -readonly [K in keyof any]-? + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 40 } }, + parent: { + textSpan: { // -readonly [K in keyof any]-?: any + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 45 } }, + parent: { + textSpan: { // { -readonly [K in keyof any]-?: any } + start: { line: 2, offset: 10 }, + end: { line: 2, offset: 47 } }, + parent: { + textSpan: { // whole line + start: { line: 2, offset: 1 }, + end: { line: 2, offset: 48 } }, + parent: { + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 2, offset: 48 } } } } } } } } } + }); + }); }); } From 4ecdc82736ee45c539b6fd0ddaa16d9fc7a68f28 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Mon, 15 Apr 2019 14:51:52 -0700 Subject: [PATCH 011/119] Solidify fake tree approach --- src/services/selectionRange.ts | 157 ++++++++++++------ .../unittests/tsserver/selectionRange.ts | 127 ++++++++++---- 2 files changed, 204 insertions(+), 80 deletions(-) diff --git a/src/services/selectionRange.ts b/src/services/selectionRange.ts index 631ec25fc09..5cf92ec3d69 100644 --- a/src/services/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -1,14 +1,11 @@ /* @internal */ namespace ts.SelectionRange { - const isImport = or(isImportDeclaration, isImportEqualsDeclaration); - export function getSelectionRange(pos: number, sourceFile: SourceFile): SelectionRange { let selectionRange: SelectionRange = { textSpan: createTextSpanFromBounds(sourceFile.getFullStart(), sourceFile.getEnd()) }; - // Skip top-level SyntaxList - let parentNode = sourceFile.getChildAt(0); + let parentNode: Node = sourceFile; outer: while (true) { const children = getSelectionChildren(parentNode); if (!children.length) break; @@ -36,13 +33,6 @@ namespace ts.SelectionRange { const end = nextNode.getStart() + "}".length; pushSelectionRange(start, end, node.kind); } - // Synthesize a stop for group of adjacent imports - else if (isImport(node)) { - const [firstImportIndex, lastImportIndex] = getGroupBounds(children, i, isImport); - pushSelectionRange( - children[firstImportIndex].getStart(), - children[lastImportIndex].getEnd()); - } // Blocks with braces on separate lines should be selected from brace to brace, // including whitespace but not including the braces themselves. @@ -79,7 +69,22 @@ namespace ts.SelectionRange { } } + const isImport = or(isImportDeclaration, isImportEqualsDeclaration); + + /** + * Gets the children of a node to be considered for selection ranging, + * transforming them into an artificial tree according to their intuitive + * grouping where no grouping actually exists in the parse tree. For example, + * top-level imports are grouped into their own SyntaxList so they can be + * selected all together, even though in the AST they’re just siblings of each + * other as well as of other top-level statements and declarations. + */ function getSelectionChildren(node: Node): ReadonlyArray { + // Group top-level imports + if (isSourceFile(node)) { + return groupChildren(node.getChildAt(0).getChildren(), isImport); + } + // Mapped types _look_ like ObjectTypes with a single member, // but in fact don’t contain a SyntaxList or a node containing // the “key/value” pair like ObjectTypes do, but it seems intuitive @@ -95,58 +100,108 @@ namespace ts.SelectionRange { const closeBraceToken = Debug.assertDefined(children.pop()); Debug.assertEqual(openBraceToken.kind, SyntaxKind.OpenBraceToken); Debug.assertEqual(closeBraceToken.kind, SyntaxKind.CloseBraceToken); - const colonTokenIndex = findIndex(children, child => child.kind === SyntaxKind.ColonToken); - const typeNodeIndex = node.type && children.indexOf(node.type); - const leftChildren = children.slice(0, colonTokenIndex); - const colonToken = Debug.assertDefined(children[colonTokenIndex]); - const rightChildren = children.slice(colonTokenIndex + 1, typeNodeIndex && (typeNodeIndex + 1)); - // Possible semicolon - const extraChildren = typeNodeIndex && typeNodeIndex > -1 ? children.slice(typeNodeIndex + 1) : []; - const syntaxList = createSyntaxList([ - createSyntaxList(leftChildren), - colonToken, - createSyntaxList(rightChildren), - createSyntaxList(extraChildren), - ]); + const [leftOfColon, ...rest] = splitChildren(children, child => child.kind === SyntaxKind.ColonToken); + // Group `-/+readonly` and `-/+?` + const leftChildren = groupChildren(getChildrenOrSingleNode(leftOfColon), child => + child === node.readonlyToken || child.kind === SyntaxKind.ReadonlyKeyword || + child === node.questionToken || child.kind === SyntaxKind.QuestionToken); return [ openBraceToken, - syntaxList, + createSyntaxList([ + // Group type parameter with surrounding brackets + createSyntaxList(groupChildren(leftChildren, ({ kind }) => + kind === SyntaxKind.OpenBracketToken || + kind === SyntaxKind.TypeParameter || + kind === SyntaxKind.CloseBracketToken + )), + ...rest, + ]), closeBraceToken, ]; } + + // Split e.g. `readonly foo?: string` into left and right sides of the colon, + // the group `readonly foo` without the QuestionToken. + if (isPropertySignature(node)) { + const [leftOfColon, ...rest] = splitChildren(node.getChildren(), child => child.kind === SyntaxKind.ColonToken); + return [ + createSyntaxList(groupChildren(getChildrenOrSingleNode(leftOfColon), child => child !== node.questionToken)), + ...rest, + ]; + } + return node.getChildren(); } + /** + * Groups sibling nodes together into their own SyntaxList if they + * a) are adjacent, AND b) match a predicate function. + */ + function groupChildren(children: Node[], groupOn: (child: Node) => boolean): Node[] { + const result: Node[] = []; + let group: Node[] | undefined; + for (const child of children) { + if (groupOn(child)) { + group = group || []; + group.push(child); + } + else { + if (group) { + result.push(createSyntaxList(group)); + group = undefined; + } + result.push(child); + } + } + if (group) { + result.push(createSyntaxList(group)); + } + + return result; + } + + /** + * Splits sibling nodes into up to four partitions: + * 1) everything left of the first node matched by `pivotOn`, + * 2) the first node matched by `pivotOn`, + * 3) everything right of the first node matched by `pivotOn`, + * 4) a trailing semicolon, if `separateTrailingSemicolon` is enabled. + * The left and right groups, if not empty, will each be grouped into their own containing SyntaxList. + * @param children The sibling nodes to split. + * @param pivotOn The predicate function to match the node to be the pivot. The first node that matches + * the predicate will be used; any others that may match will be included into the right-hand group. + * @param separateTrailingSemicolon If the last token is a semicolon, it will be returned as a separate + * child rather than be included in the right-hand group. + */ + function splitChildren(children: Node[], pivotOn: (child: Node) => boolean, separateTrailingSemicolon = true): Node[] { + if (children.length < 2) { + return children; + } + const splitTokenIndex = findIndex(children, pivotOn); + if (splitTokenIndex === -1) { + return children; + } + const leftChildren = children.slice(0, splitTokenIndex); + const splitToken = children[splitTokenIndex]; + const lastToken = last(children); + const separateLastToken = separateTrailingSemicolon && lastToken.kind === SyntaxKind.SemicolonToken; + const rightChildren = children.slice(splitTokenIndex + 1, separateLastToken ? children.length - 1 : undefined); + const result = compact([ + leftChildren.length ? createSyntaxList(leftChildren) : undefined, + splitToken, + rightChildren.length ? createSyntaxList(rightChildren) : undefined, + ]); + return separateLastToken ? result.concat(lastToken) : result; + } + + function getChildrenOrSingleNode(node: Node): Node[] { + return isSyntaxList(node) ? node.getChildren() : [node]; + } + function createSyntaxList(children: Node[]): SyntaxList { Debug.assertGreaterThanOrEqual(children.length, 1); const syntaxList = createNode(SyntaxKind.SyntaxList, children[0].pos, last(children).end) as SyntaxList; syntaxList._children = children; return syntaxList; } - - function getGroupBounds(array: ArrayLike, index: number, predicate: (element: T) => boolean): [number, number] { - let first = index; - let last = index; - let i = index; - while (i > 0) { - const element = array[--i]; - if (predicate(element)) { - first = i; - } - else { - break; - } - } - i = index; - while (i < array.length - 1) { - const element = array[++i]; - if (predicate(element)) { - last = i; - } - else { - break; - } - } - return [first, last]; - } } diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 837607a58f2..0d36690713d 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -191,35 +191,37 @@ type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAn ]); }); - it.skip("works for object types", () => { + it("works for object types", () => { const getSelectionRange = setup("/file.js", ` type X = { foo?: string; readonly bar: { x: number }; + meh }`); const locations = getSelectionRange([ { line: 3, offset: 5 }, { line: 4, offset: 5 }, { line: 4, offset: 14 }, { line: 4, offset: 27 }, + { line: 5, offset: 5 }, ]); const allMembersUp: protocol.SelectionRange = { textSpan: { // all members + whitespace (just inside braces) start: { line: 2, offset: 11 }, - end: { line: 5, offset: 1 } }, + end: { line: 6, offset: 1 } }, parent: { textSpan: { // add braces start: { line: 2, offset: 10 }, - end: { line: 5, offset: 2 } }, + end: { line: 6, offset: 2 } }, parent: { textSpan: { // whole TypeAliasDeclaration start: { line: 2, offset: 1 }, - end: { line: 5, offset: 2 } }, + end: { line: 6, offset: 2 } }, parent: { textSpan: { // SourceFile start: { line: 1, offset: 1 }, - end: { line: 5, offset: 2 } } } } } }; + end: { line: 6, offset: 2 } } } } } }; const readonlyBarUp: protocol.SelectionRange = { textSpan: { // readonly bar @@ -270,6 +272,12 @@ type X = { start: { line: 4, offset: 19 }, end: { line: 4, offset: 32 } }, parent: readonlyBarUp.parent } } }); + + assert.deepEqual(locations![4], { + textSpan: { // meh + start: { line: 5, offset: 5 }, + end: { line: 5, offset: 8 } }, + parent: allMembersUp }); }); it("works for string literals and template strings", () => { @@ -355,7 +363,7 @@ console.log(1);`); ]); }); - it.skip("works for complex mapped types", () => { + it("works for complex mapped types", () => { const getSelectionRange = setup("/file.ts", ` type M = { -readonly [K in keyof any]-?: any };`); @@ -368,38 +376,99 @@ type M = { -readonly [K in keyof any]-?: any };`); { line: 2, offset: 39 }, // ? ]); + const leftOfColonUp: protocol.SelectionRange = { + textSpan: { // -readonly [K in keyof any]-? + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 40 } }, + parent: { + textSpan: { // -readonly [K in keyof any]-?: any + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 45 } }, + parent: { + textSpan: { // { -readonly [K in keyof any]-?: any } + start: { line: 2, offset: 10 }, + end: { line: 2, offset: 47 } }, + parent: { + textSpan: { // whole line + start: { line: 2, offset: 1 }, + end: { line: 2, offset: 48 } }, + parent: { + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 2, offset: 48 } } } } } } }; + assert.deepEqual(locations![0], { - textSpan: { // - + textSpan: { // - (in -readonly) start: { line: 2, offset: 12 }, end: { line: 2, offset: 13 } }, parent: { textSpan: { // -readonly start: { line: 2, offset: 12 }, end: { line: 2, offset: 21 } }, + parent: leftOfColonUp }, + }); + + assert.deepEqual(locations![1], { + textSpan: { // readonly + start: { line: 2, offset: 13 }, + end: { line: 2, offset: 21 } }, + parent: { + textSpan: { // -readonly + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 21 } }, + parent: leftOfColonUp }, + }); + + assert.deepEqual(locations![2], { + textSpan: { // [ + start: { line: 2, offset: 22 }, + end: { line: 2, offset: 23 } }, + parent: { + textSpan: { // [K in keyof any] + start: { line: 2, offset: 22 }, + end: { line: 2, offset: 38 } }, + parent: leftOfColonUp } + }); + + assert.deepEqual(locations![3], { + textSpan: { // keyof + start: { line: 2, offset: 28 }, + end: { line: 2, offset: 33 } }, + parent: { + textSpan: { // keyof any + start: { line: 2, offset: 28 }, + end: { line: 2, offset: 37 } }, parent: { - textSpan: { // -readonly [K in keyof any] - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 38 } }, + textSpan: { // K in keyof any + start: { line: 2, offset: 23 }, + end: { line: 2, offset: 37 } }, parent: { - textSpan: { // -readonly [K in keyof any]-? - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 40 } }, - parent: { - textSpan: { // -readonly [K in keyof any]-?: any - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 45 } }, - parent: { - textSpan: { // { -readonly [K in keyof any]-?: any } - start: { line: 2, offset: 10 }, - end: { line: 2, offset: 47 } }, - parent: { - textSpan: { // whole line - start: { line: 2, offset: 1 }, - end: { line: 2, offset: 48 } }, - parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 2, offset: 48 } } } } } } } } } + textSpan: { // [K in keyof any] + start: { line: 2, offset: 22 }, + end: { line: 2, offset: 38 } }, + parent: leftOfColonUp } } }, + }); + + assert.deepEqual(locations![4], { + textSpan: { // - (in -?) + start: { line: 2, offset: 38 }, + end: { line: 2, offset: 39 } }, + parent: { + textSpan: { // -? + start: { line: 2, offset: 38 }, + end: { line: 2, offset: 40 } }, + parent: leftOfColonUp }, + }); + + assert.deepEqual(locations![5], { + textSpan: { // ? + start: { line: 2, offset: 39 }, + end: { line: 2, offset: 40 } }, + parent: { + textSpan: { // -? + start: { line: 2, offset: 38 }, + end: { line: 2, offset: 40 } }, + parent: leftOfColonUp }, }); }); }); From 74fc84ff844c8e4b961b3b9e5dca1086e663b129 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Mon, 15 Apr 2019 17:07:38 -0700 Subject: [PATCH 012/119] Snap to nodes directly behind the cursor, create special rules for ParameterNodes --- src/services/selectionRange.ts | 68 ++++++++++++------ .../unittests/tsserver/selectionRange.ts | 70 +++++++++++++++++++ 2 files changed, 115 insertions(+), 23 deletions(-) diff --git a/src/services/selectionRange.ts b/src/services/selectionRange.ts index 5cf92ec3d69..07a7abd7d26 100644 --- a/src/services/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -17,7 +17,7 @@ namespace ts.SelectionRange { break outer; } - if (positionBelongsToNode(node, pos, sourceFile)) { + if (positionShouldSnapToNode(pos, node, nextNode, sourceFile)) { // Blocks are effectively redundant with SyntaxLists. // TemplateSpans, along with the SyntaxLists containing them, // are a somewhat unintuitive grouping of things that should be @@ -69,6 +69,28 @@ namespace ts.SelectionRange { } } + /** + * Like `ts.positionBelongsToNode`, except positions immediately after nodes + * count too, unless that position belongs to the next node. In effect, makes + * selections able to snap to preceding tokens when the cursor is on the tail + * end of them with only whitespace ahead. + * @param pos The position to check. + * @param node The candidate node to snap to. + * @param nextNode The next sibling node in the tree. + * @param sourceFile The source file containing the nodes. + */ + function positionShouldSnapToNode(pos: number, node: Node, nextNode: Node | undefined, sourceFile: SourceFile) { + if (positionBelongsToNode(node, pos, sourceFile)) { + return true; + } + const nodeEnd = node.getEnd(); + const nextNodeStart = nextNode && nextNode.getStart(); + if (nodeEnd === pos) { + return pos !== nextNodeStart; + } + return false; + } + const isImport = or(isImportDeclaration, isImportEqualsDeclaration); /** @@ -100,34 +122,38 @@ namespace ts.SelectionRange { const closeBraceToken = Debug.assertDefined(children.pop()); Debug.assertEqual(openBraceToken.kind, SyntaxKind.OpenBraceToken); Debug.assertEqual(closeBraceToken.kind, SyntaxKind.CloseBraceToken); - const [leftOfColon, ...rest] = splitChildren(children, child => child.kind === SyntaxKind.ColonToken); // Group `-/+readonly` and `-/+?` - const leftChildren = groupChildren(getChildrenOrSingleNode(leftOfColon), child => + const groupedWithPlusMinusTokens = groupChildren(children, child => child === node.readonlyToken || child.kind === SyntaxKind.ReadonlyKeyword || child === node.questionToken || child.kind === SyntaxKind.QuestionToken); + // Group type parameter with surrounding brackets + const groupedWithBrackets = groupChildren(groupedWithPlusMinusTokens, ({ kind }) => + kind === SyntaxKind.OpenBracketToken || + kind === SyntaxKind.TypeParameter || + kind === SyntaxKind.CloseBracketToken + ); return [ openBraceToken, - createSyntaxList([ - // Group type parameter with surrounding brackets - createSyntaxList(groupChildren(leftChildren, ({ kind }) => - kind === SyntaxKind.OpenBracketToken || - kind === SyntaxKind.TypeParameter || - kind === SyntaxKind.CloseBracketToken - )), - ...rest, - ]), + // Pivot on `:` + createSyntaxList(splitChildren(groupedWithBrackets, ({ kind }) => kind === SyntaxKind.ColonToken)), closeBraceToken, ]; } - // Split e.g. `readonly foo?: string` into left and right sides of the colon, - // the group `readonly foo` without the QuestionToken. + // Group modifiers and property name, then pivot on `:`. if (isPropertySignature(node)) { - const [leftOfColon, ...rest] = splitChildren(node.getChildren(), child => child.kind === SyntaxKind.ColonToken); - return [ - createSyntaxList(groupChildren(getChildrenOrSingleNode(leftOfColon), child => child !== node.questionToken)), - ...rest, - ]; + const children = groupChildren(node.getChildren(), child => + child === node.name || contains(node.modifiers, child)); + return splitChildren(children, ({ kind }) => kind === SyntaxKind.ColonToken); + } + + // Group the parameter name with its `...`, then that group with its `?`, then pivot on `=`. + if (isParameter(node)) { + const groupedDotDotDotAndName = groupChildren(node.getChildren(), child => + child === node.dotDotDotToken || child === node.name); + const groupedWithQuestionToken = groupChildren(groupedDotDotDotAndName, child => + child === groupedDotDotDotAndName[0] || child === node.questionToken); + return splitChildren(groupedWithQuestionToken, ({ kind }) => kind === SyntaxKind.EqualsToken); } return node.getChildren(); @@ -194,10 +220,6 @@ namespace ts.SelectionRange { return separateLastToken ? result.concat(lastToken) : result; } - function getChildrenOrSingleNode(node: Node): Node[] { - return isSyntaxList(node) ? node.getChildren() : [node]; - } - function createSyntaxList(children: Node[]): SyntaxList { Debug.assertGreaterThanOrEqual(children.length, 1); const syntaxList = createNode(SyntaxKind.SyntaxList, children[0].pos, last(children).end) as SyntaxList; diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 0d36690713d..5a4bbb41f19 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -471,5 +471,75 @@ type M = { -readonly [K in keyof any]-?: any };`); parent: leftOfColonUp }, }); }); + + it("works for parameters", () => { + const getSelectionRange = setup("/file.ts", ` +function f(p, q?, ...r: any[] = []) {}`); + + const locations = getSelectionRange([ + { line: 2, offset: 12 }, // p + { line: 2, offset: 15 }, // q + { line: 2, offset: 19 }, // ... + ]); + + const allParamsUp: protocol.SelectionRange = { + textSpan: { // just inside parens + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 35 } }, + parent: { + textSpan: { + start: { line: 2, offset: 1 }, + end: { line: 2, offset: 39 } }, + parent: { + textSpan: { + start: { line: 1, offset: 1 }, + end: { line: 2, offset: 39 } } } } }; + + assert.deepEqual(locations![0], { + textSpan: { // p + start: { line: 2, offset: 12 }, + end: { line: 2, offset: 13 } }, + parent: allParamsUp, + }); + + assert.deepEqual(locations![1], { + textSpan: { // q + start: { line: 2, offset: 15 }, + end: { line: 2, offset: 16 } }, + parent: { + textSpan: { // q? + start: { line: 2, offset: 15 }, + end: { line: 2, offset: 17 } }, + parent: allParamsUp }, + }); + + assert.deepEqual(locations![2], { + textSpan: { // ... + start: { line: 2, offset: 19 }, + end: { line: 2, offset: 22 } }, + parent: { + textSpan: { // ...r + start: { line: 2, offset: 19 }, + end: { line: 2, offset: 23 } }, + parent: { + textSpan: { // ...r: any[] + start: { line: 2, offset: 19 }, + end: { line: 2, offset: 30 } }, + parent: { + textSpan: { // ...r: any[] = [] + start: { line: 2, offset: 19 }, + end: { line: 2, offset: 35 } }, + parent: allParamsUp } } }, + }); + }); + + it("snaps to nodes directly behind the cursor instead of trivia ahead of the cursor", () => { + const getSelectionRange = setup("/file.ts", `let x: string`); + const locations = getSelectionRange([{ line: 1, offset: 4 }]); + assert.deepEqual(locations![0].textSpan, { + start: { line: 1, offset: 1 }, + end: { line: 1, offset: 4 }, + }); + }); }); } From d73eabd35ac852a7fd7532cafc8779bd0b128584 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Tue, 16 Apr 2019 11:23:57 -0700 Subject: [PATCH 013/119] Special rules for binding elements, extend brace/whitespace logic to other kinds of bookended lists --- src/services/selectionRange.ts | 44 +++++++++--- .../unittests/tsserver/selectionRange.ts | 72 +++++++++++++++++++ 2 files changed, 107 insertions(+), 9 deletions(-) diff --git a/src/services/selectionRange.ts b/src/services/selectionRange.ts index 07a7abd7d26..536efbfb8d1 100644 --- a/src/services/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -21,8 +21,13 @@ namespace ts.SelectionRange { // Blocks are effectively redundant with SyntaxLists. // TemplateSpans, along with the SyntaxLists containing them, // are a somewhat unintuitive grouping of things that should be - // considered independently. Dive in without pushing a selection range. - if (isBlock(node) || isTemplateSpan(node) || isTemplateHead(node) || prevNode && isTemplateHead(prevNode)) { + // considered independently. A VariableStatement’s children are just + // a VaraiableDeclarationList and a semicolon. + // Dive in without pushing a selection range. + if (isBlock(node) + || isTemplateSpan(node) || isTemplateHead(node) + || prevNode && isTemplateHead(prevNode) + || isVariableDeclarationList(node) && isVariableStatement(parentNode)) { parentNode = node; break; } @@ -34,14 +39,14 @@ namespace ts.SelectionRange { pushSelectionRange(start, end, node.kind); } - // Blocks with braces on separate lines should be selected from brace to brace, - // including whitespace but not including the braces themselves. - const isBetweenMultiLineBraces = isSyntaxList(node) - && prevNode && prevNode.kind === SyntaxKind.OpenBraceToken - && nextNode && nextNode.kind === SyntaxKind.CloseBraceToken + // Blocks with braces, brackets, parens, or JSX tags on separate lines should be + // selected from open to close, including whitespace but not including the braces/etc. themselves. + const isBetweenMultiLineBookends = isSyntaxList(node) + && isListOpener(prevNode) + && isListCloser(nextNode) && !positionsAreOnSameLine(prevNode.getStart(), nextNode.getStart(), sourceFile); - const start = isBetweenMultiLineBraces ? prevNode.getEnd() : node.getStart(); - const end = isBetweenMultiLineBraces ? nextNode.getStart() : node.getEnd(); + const start = isBetweenMultiLineBookends ? prevNode.getEnd() : node.getStart(); + const end = isBetweenMultiLineBookends ? nextNode.getStart() : node.getEnd(); pushSelectionRange(start, end, node.kind); // String literals should have a stop both inside and outside their quotes. @@ -156,6 +161,11 @@ namespace ts.SelectionRange { return splitChildren(groupedWithQuestionToken, ({ kind }) => kind === SyntaxKind.EqualsToken); } + // Pivot on '=' + if (isBindingElement(node)) { + return splitChildren(node.getChildren(), ({ kind }) => kind === SyntaxKind.EqualsToken); + } + return node.getChildren(); } @@ -226,4 +236,20 @@ namespace ts.SelectionRange { syntaxList._children = children; return syntaxList; } + + function isListOpener(token: Node | undefined): token is Node { + const kind = token && token.kind; + return kind === SyntaxKind.OpenBraceToken + || kind === SyntaxKind.OpenBracketToken + || kind === SyntaxKind.OpenParenToken + || kind === SyntaxKind.JsxOpeningElement; + } + + function isListCloser(token: Node | undefined): token is Node { + const kind = token && token.kind; + return kind === SyntaxKind.CloseBraceToken + || kind === SyntaxKind.CloseBracketToken + || kind === SyntaxKind.CloseParenToken + || kind === SyntaxKind.JsxClosingElement; + } } diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 5a4bbb41f19..759ae0dd254 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -533,6 +533,78 @@ function f(p, q?, ...r: any[] = []) {}`); }); }); + it("works for binding elements", () => { + const getSelectionRange = setup("/file.ts", ` +const { x, y: a, ...zs = {} } = {};`); + const locations = getSelectionRange([ + { line: 2, offset: 9 }, // x + { line: 2, offset: 15 }, // a + { line: 2, offset: 21 }, // zs + ]); + + // Don’t care about checking first two locations, because + // they’re pretty boring, just want to make sure they don’t cause a crash + assert.deepEqual(locations![2], { + textSpan: { // zs + start: { line: 2, offset: 21 }, + end: { line: 2, offset: 23 } }, + parent: { + textSpan: { // ...zs + start: { line: 2, offset: 18 }, + end: { line: 2, offset: 23 } }, + parent: { + textSpan: { // ...zs = {} + start: { line: 2, offset: 18 }, + end: { line: 2, offset: 28 } }, + parent: { + textSpan: { // x, y: a, ...zs = {} + start: { line: 2, offset: 9 }, + end: { line: 2, offset: 28 } }, + parent: { + textSpan: { // { x, y: a, ...zs = {} } + start: { line: 2, offset: 7 }, + end: { line: 2, offset: 30 } }, + parent: { + textSpan: { // { x, y: a, ...zs = {} } = {} + start: { line: 2, offset: 7 }, + end: { line: 2, offset: 35 } }, + parent: { + textSpan: { // whole line + start: { line: 2, offset: 1 }, + end: { line: 2, offset: 36 } }, + parent: { + textSpan: { + start: { line: 1, offset: 1 }, + end: { line: 2, offset: 36 } } } } } } } } }, + }); + }); + + it("consumes all whitespace in a multi-line function parameter list", () => { + const getSelectionRange = setup("/file.ts", ` +function f( + a, + b +) {}`); + const locations = getSelectionRange([{ line: 4, offset: 5 }]); // b + assert.deepEqual(locations, [{ + textSpan: { // b + start: { line: 4, offset: 5 }, + end: { line: 4, offset: 6 } }, + parent: { // all params and whitespace inside parens + textSpan: { + start: { line: 2, offset: 12 }, + end: { line: 5, offset: 1 } }, + parent: { + textSpan: { // whole function declaration + start: { line: 2, offset: 1 }, + end: { line: 5, offset: 5 } }, + parent: { + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 5, offset: 5 } } } } } + }]); + }); + it("snaps to nodes directly behind the cursor instead of trivia ahead of the cursor", () => { const getSelectionRange = setup("/file.ts", `let x: string`); const locations = getSelectionRange([{ line: 1, offset: 4 }]); From fed910fd0c9e911319dd492b51d410c1e655a090 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 18 Apr 2019 14:22:19 -0700 Subject: [PATCH 014/119] Add stop for JSDoc comments --- src/services/selectionRange.ts | 14 ++- .../unittests/tsserver/selectionRange.ts | 85 +++++++++++++------ 2 files changed, 69 insertions(+), 30 deletions(-) diff --git a/src/services/selectionRange.ts b/src/services/selectionRange.ts index 536efbfb8d1..1c2a525167a 100644 --- a/src/services/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -17,7 +17,7 @@ namespace ts.SelectionRange { break outer; } - if (positionShouldSnapToNode(pos, node, nextNode, sourceFile)) { + if (positionShouldSnapToNode(pos, node, nextNode)) { // Blocks are effectively redundant with SyntaxLists. // TemplateSpans, along with the SyntaxLists containing them, // are a somewhat unintuitive grouping of things that should be @@ -45,8 +45,12 @@ namespace ts.SelectionRange { && isListOpener(prevNode) && isListCloser(nextNode) && !positionsAreOnSameLine(prevNode.getStart(), nextNode.getStart(), sourceFile); + const jsDocCommentStart = hasJSDocNodes(node) && node.jsDoc![0].getStart(); const start = isBetweenMultiLineBookends ? prevNode.getEnd() : node.getStart(); const end = isBetweenMultiLineBookends ? nextNode.getStart() : node.getEnd(); + if (isNumber(jsDocCommentStart)) { + pushSelectionRange(jsDocCommentStart, end); + } pushSelectionRange(start, end, node.kind); // String literals should have a stop both inside and outside their quotes. @@ -84,8 +88,12 @@ namespace ts.SelectionRange { * @param nextNode The next sibling node in the tree. * @param sourceFile The source file containing the nodes. */ - function positionShouldSnapToNode(pos: number, node: Node, nextNode: Node | undefined, sourceFile: SourceFile) { - if (positionBelongsToNode(node, pos, sourceFile)) { + function positionShouldSnapToNode(pos: number, node: Node, nextNode: Node | undefined) { + // Can’t use 'ts.positionBelongsToNode()' here because it cleverly accounts + // for missing nodes, which can’t really be considered when deciding what + // to select. + Debug.assert(node.pos <= pos); + if (pos < node.end) { return true; } const nodeEnd = node.getEnd(); diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 759ae0dd254..3c0a12a58f7 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -92,44 +92,47 @@ export interface IService { _serviceBrand: any; open(host: number, data: any): Promise; + bar(): void }`); const locations = getSelectionRange([ - { - line: 5, - offset: 12, - }, + { line: 5, offset: 12 }, // ho/**/st + { line: 6, offset: 16 }, // void/**/ ]); - assert.deepEqual(locations, [ - { - textSpan: { // host + assert.deepEqual(locations![0], { + textSpan: { // host + start: { line: 5, offset: 10 }, + end: { line: 5, offset: 14 } }, + parent: { + textSpan: { // host: number start: { line: 5, offset: 10 }, - end: { line: 5, offset: 14 } }, + end: { line: 5, offset: 22 } }, parent: { - textSpan: { // host: number + textSpan: { // host: number, data: any start: { line: 5, offset: 10 }, - end: { line: 5, offset: 22 } }, + end: { line: 5, offset: 33 } }, parent: { - textSpan: { // host: number, data: any - start: { line: 5, offset: 10 }, - end: { line: 5, offset: 33 } }, + textSpan: { // open(host: number, data: any): Promise; + start: { line: 5, offset: 5 }, + end: { line: 5, offset: 49 } }, parent: { - textSpan: { // open(host: number, data: any): Promise; - start: { line: 5, offset: 5 }, - end: { line: 5, offset: 49 } }, + textSpan: { // SyntaxList + whitespace (body of interface) + start: { line: 2, offset: 28 }, + end: { line: 7, offset: 1 } }, parent: { - textSpan: { // SyntaxList + whitespace (body of interface) - start: { line: 2, offset: 28 }, - end: { line: 6, offset: 1 } }, + textSpan: { // InterfaceDeclaration + start: { line: 2, offset: 1 }, + end: { line: 7, offset: 2 } }, parent: { - textSpan: { // InterfaceDeclaration - start: { line: 2, offset: 1 }, - end: { line: 6, offset: 2 } }, - parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 6, offset: 2 } } } } } } } } }, - ]); + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 7, offset: 2 } } } } } } } } }); + + // Ensures positions after a zero-width node work, because ts.positionBelongsToNode + // treats them strangely. + assert.deepEqual(locations![1].textSpan, { // void + start: { line: 6, offset: 12 }, + end: { line: 6, offset: 16 }}); }); it("works for complex TypeScript", () => { @@ -613,5 +616,33 @@ function f( end: { line: 1, offset: 4 }, }); }); + + it("creates a stop for JSDoc ranges", () => { + const getSelectionRange = setup("/file.js", "" + +`// Not a JSDoc comment +/** + * @param {number} x The number to square + */ +function square(x) { + return x * x; +}`); + const locations = getSelectionRange([{ line: 5, offset: 10 }]); // square(x) + assert.deepEqual(locations, [{ + textSpan: { // square + start: { line: 5 , offset: 10 }, + end: { line: 5, offset: 16 } }, + parent: { // whole function declaration + textSpan: { + start: { line: 5, offset: 1 }, + end: { line: 7, offset: 2 } }, + parent: { + textSpan: { // add JSDoc + start: { line: 2, offset: 1 }, + end: { line: 7, offset: 2 } }, + parent: { + textSpan: { // SourceFile + start: { line: 1, offset: 1 }, + end: { line: 7, offset: 2 } } } } } }]); + }); }); } From 5479893f009bc92af33413170a0e99a175e5414d Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 18 Apr 2019 16:03:53 -0700 Subject: [PATCH 015/119] Skip lone variable declarations --- src/services/selectionRange.ts | 15 ++++++---- .../unittests/tsserver/selectionRange.ts | 30 ++++++++++++------- 2 files changed, 28 insertions(+), 17 deletions(-) diff --git a/src/services/selectionRange.ts b/src/services/selectionRange.ts index 1c2a525167a..63a65d42e3b 100644 --- a/src/services/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -18,16 +18,19 @@ namespace ts.SelectionRange { } if (positionShouldSnapToNode(pos, node, nextNode)) { - // Blocks are effectively redundant with SyntaxLists. - // TemplateSpans, along with the SyntaxLists containing them, - // are a somewhat unintuitive grouping of things that should be - // considered independently. A VariableStatement’s children are just - // a VaraiableDeclarationList and a semicolon. + // 1. Blocks are effectively redundant with SyntaxLists. + // 2. TemplateSpans, along with the SyntaxLists containing them, are a somewhat unintuitive grouping + // of things that should be considered independently. + // 3. A VariableStatement’s children are just a VaraiableDeclarationList and a semicolon. + // 4. A lone VariableDeclaration in a VaraibleDeclaration feels redundant with the VariableStatement. + // // Dive in without pushing a selection range. if (isBlock(node) || isTemplateSpan(node) || isTemplateHead(node) || prevNode && isTemplateHead(prevNode) - || isVariableDeclarationList(node) && isVariableStatement(parentNode)) { + || isVariableDeclarationList(node) && isVariableStatement(parentNode) + || isSyntaxList(node) && isVariableDeclarationList(parentNode) + || isVariableDeclaration(node) && isSyntaxList(parentNode) && children.length === 1) { parentNode = node; break; } diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 3c0a12a58f7..7940edcdebb 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -568,18 +568,13 @@ const { x, y: a, ...zs = {} } = {};`); start: { line: 2, offset: 7 }, end: { line: 2, offset: 30 } }, parent: { - textSpan: { // { x, y: a, ...zs = {} } = {} - start: { line: 2, offset: 7 }, - end: { line: 2, offset: 35 } }, + textSpan: { // whole line + start: { line: 2, offset: 1 }, + end: { line: 2, offset: 36 } }, parent: { - textSpan: { // whole line - start: { line: 2, offset: 1 }, - end: { line: 2, offset: 36 } }, - parent: { - textSpan: { - start: { line: 1, offset: 1 }, - end: { line: 2, offset: 36 } } } } } } } } }, - }); + textSpan: { + start: { line: 1, offset: 1 }, + end: { line: 2, offset: 36 } } } } } } } } }); }); it("consumes all whitespace in a multi-line function parameter list", () => { @@ -644,5 +639,18 @@ function square(x) { start: { line: 1, offset: 1 }, end: { line: 7, offset: 2 } } } } } }]); }); + + it("skips lone VariableDeclarations in a declaration list", () => { + const getSelectionRange = setup("/file.ts", `const x = 3;`); + const locations = getSelectionRange([{ line: 1, offset: 7 }]); // x + assert.deepEqual(locations, [{ + textSpan: { + start: { line: 1, offset: 7 }, + end: { line: 1, offset: 8 } }, + parent: { + textSpan: { + start: { line: 1, offset: 1 }, + end: { line: 1, offset: 13 } } } }]); + }); }); } From f0f7d82d7ac4f8091ca1ffdb3425a30017f12808 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 18 Apr 2019 16:04:47 -0700 Subject: [PATCH 016/119] Remove debug info --- src/services/selectionRange.ts | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/services/selectionRange.ts b/src/services/selectionRange.ts index 63a65d42e3b..0ec0641a8a2 100644 --- a/src/services/selectionRange.ts +++ b/src/services/selectionRange.ts @@ -39,7 +39,7 @@ namespace ts.SelectionRange { if (isTemplateSpan(parentNode) && nextNode && isTemplateMiddleOrTemplateTail(nextNode)) { const start = node.getFullStart() - "${".length; const end = nextNode.getStart() + "}".length; - pushSelectionRange(start, end, node.kind); + pushSelectionRange(start, end); } // Blocks with braces, brackets, parens, or JSX tags on separate lines should be @@ -54,7 +54,7 @@ namespace ts.SelectionRange { if (isNumber(jsDocCommentStart)) { pushSelectionRange(jsDocCommentStart, end); } - pushSelectionRange(start, end, node.kind); + pushSelectionRange(start, end); // String literals should have a stop both inside and outside their quotes. if (isStringLiteral(node) || isTemplateLiteral(node)) { @@ -69,14 +69,11 @@ namespace ts.SelectionRange { return selectionRange; - function pushSelectionRange(start: number, end: number, syntaxKind?: SyntaxKind): void { + function pushSelectionRange(start: number, end: number): void { // Skip ranges that are identical to the parent const textSpan = createTextSpanFromBounds(start, end); if (!selectionRange || !textSpansEqual(textSpan, selectionRange.textSpan)) { selectionRange = { textSpan, ...selectionRange && { parent: selectionRange } }; - if (syntaxKind) { - Object.defineProperty(selectionRange, "__debugKind", { value: formatSyntaxKind(syntaxKind) }); - } } } } From d8936fd2906c66c294420e35f1dce654eeac6a13 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 18 Apr 2019 16:23:06 -0700 Subject: [PATCH 017/119] Rename to be smarter --- src/harness/client.ts | 2 +- src/harness/harnessLanguageService.ts | 4 +- src/server/session.ts | 8 +-- src/services/services.ts | 6 +-- src/services/shims.ts | 8 +-- .../{selectionRange.ts => smartSelection.ts} | 4 +- src/services/tsconfig.json | 2 +- src/services/types.ts | 2 +- .../unittests/tsserver/selectionRange.ts | 54 +++++++++---------- .../reference/api/tsserverlibrary.d.ts | 24 ++++++++- tests/baselines/reference/api/typescript.d.ts | 5 ++ .../TypeScript-Node-Starter | 2 +- .../user/create-react-app/create-react-app | 2 +- tests/cases/user/prettier/prettier | 2 +- 14 files changed, 76 insertions(+), 49 deletions(-) rename src/services/{selectionRange.ts => smartSelection.ts} (97%) diff --git a/src/harness/client.ts b/src/harness/client.ts index bb9e674bbc6..d223f9f5fe3 100644 --- a/src/harness/client.ts +++ b/src/harness/client.ts @@ -424,7 +424,7 @@ namespace ts.server { return renameInfo; } - getSelectionRange() { + getSmartSelectionRange() { return notImplemented(); } diff --git a/src/harness/harnessLanguageService.ts b/src/harness/harnessLanguageService.ts index fff02e5b94a..03ccbb5d6de 100644 --- a/src/harness/harnessLanguageService.ts +++ b/src/harness/harnessLanguageService.ts @@ -472,8 +472,8 @@ namespace Harness.LanguageService { getRenameInfo(fileName: string, position: number, options?: ts.RenameInfoOptions): ts.RenameInfo { return unwrapJSONCallResult(this.shim.getRenameInfo(fileName, position, options)); } - getSelectionRange(fileName: string, position: number): ts.SelectionRange { - return unwrapJSONCallResult(this.shim.getSelectionRange(fileName, position)); + getSmartSelectionRange(fileName: string, position: number): ts.SelectionRange { + return unwrapJSONCallResult(this.shim.getSmartSelectionRange(fileName, position)); } findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean, providePrefixAndSuffixTextForRename?: boolean): ts.RenameLocation[] { return unwrapJSONCallResult(this.shim.findRenameLocations(fileName, position, findInStrings, findInComments, providePrefixAndSuffixTextForRename)); diff --git a/src/server/session.ts b/src/server/session.ts index 261356f2cd0..2e9d6948b1a 100644 --- a/src/server/session.ts +++ b/src/server/session.ts @@ -2059,14 +2059,14 @@ namespace ts.server { this.projectService.configurePlugin(args); } - private getSelectionRange(args: protocol.SelectionRangeRequestArgs, simplifiedResult: boolean) { + private getSmartSelectionRange(args: protocol.SelectionRangeRequestArgs, simplifiedResult: boolean) { const { locations } = args; const { file, languageService } = this.getFileAndLanguageServiceForSyntacticOperation(args); const scriptInfo = Debug.assertDefined(this.projectService.getScriptInfo(file)); return map(locations, location => { const pos = this.getPosition(location, scriptInfo); - const selectionRange = languageService.getSelectionRange(file, pos); + const selectionRange = languageService.getSmartSelectionRange(file, pos); return simplifiedResult ? this.mapSelectionRange(selectionRange, scriptInfo) : selectionRange; }); } @@ -2438,10 +2438,10 @@ namespace ts.server { return this.notRequired(); }, [CommandNames.SelectionRange]: (request: protocol.SelectionRangeRequest) => { - return this.requiredResponse(this.getSelectionRange(request.arguments, /*simplifiedResult*/ true)); + return this.requiredResponse(this.getSmartSelectionRange(request.arguments, /*simplifiedResult*/ true)); }, [CommandNames.SelectionRangeFull]: (request: protocol.SelectionRangeRequest) => { - return this.requiredResponse(this.getSelectionRange(request.arguments, /*simplifiedResult*/ false)); + return this.requiredResponse(this.getSmartSelectionRange(request.arguments, /*simplifiedResult*/ false)); }, }); diff --git a/src/services/services.ts b/src/services/services.ts index 721777c2bad..64fe3bca664 100644 --- a/src/services/services.ts +++ b/src/services/services.ts @@ -2087,8 +2087,8 @@ namespace ts { }; } - function getSelectionRange(fileName: string, position: number): SelectionRange { - return SelectionRange.getSelectionRange(position, syntaxTreeCache.getCurrentSourceFile(fileName)); + function getSmartSelectionRange(fileName: string, position: number): SelectionRange { + return SmartSelectionRange.getSmartSelectionRange(position, syntaxTreeCache.getCurrentSourceFile(fileName)); } function getApplicableRefactors(fileName: string, positionOrRange: number | TextRange, preferences: UserPreferences = emptyOptions): ApplicableRefactorInfo[] { @@ -2138,7 +2138,7 @@ namespace ts { getBreakpointStatementAtPosition, getNavigateToItems, getRenameInfo, - getSelectionRange, + getSmartSelectionRange, findRenameLocations, getNavigationBarItems, getNavigationTree, diff --git a/src/services/shims.ts b/src/services/shims.ts index 3f3b3c2bef6..e914a4acd42 100644 --- a/src/services/shims.ts +++ b/src/services/shims.ts @@ -165,7 +165,7 @@ namespace ts { * { canRename: boolean, localizedErrorMessage: string, displayName: string, fullDisplayName: string, kind: string, kindModifiers: string, triggerSpan: { start; length } } */ getRenameInfo(fileName: string, position: number, options?: RenameInfoOptions): string; - getSelectionRange(fileName: string, position: number): string; + getSmartSelectionRange(fileName: string, position: number): string; /** * Returns a JSON-encoded value of the type: @@ -839,10 +839,10 @@ namespace ts { ); } - public getSelectionRange(fileName: string, position: number): string { + public getSmartSelectionRange(fileName: string, position: number): string { return this.forwardJSONCall( - `getSelectionRange('${fileName}', ${position})`, - () => this.languageService.getSelectionRange(fileName, position) + `getSmartSelectionRange('${fileName}', ${position})`, + () => this.languageService.getSmartSelectionRange(fileName, position) ); } diff --git a/src/services/selectionRange.ts b/src/services/smartSelection.ts similarity index 97% rename from src/services/selectionRange.ts rename to src/services/smartSelection.ts index 0ec0641a8a2..ba2ec60e9c5 100644 --- a/src/services/selectionRange.ts +++ b/src/services/smartSelection.ts @@ -1,6 +1,6 @@ /* @internal */ -namespace ts.SelectionRange { - export function getSelectionRange(pos: number, sourceFile: SourceFile): SelectionRange { +namespace ts.SmartSelectionRange { + export function getSmartSelectionRange(pos: number, sourceFile: SourceFile): SelectionRange { let selectionRange: SelectionRange = { textSpan: createTextSpanFromBounds(sourceFile.getFullStart(), sourceFile.getEnd()) }; diff --git a/src/services/tsconfig.json b/src/services/tsconfig.json index a456fbb957f..d5977ee46bf 100644 --- a/src/services/tsconfig.json +++ b/src/services/tsconfig.json @@ -28,7 +28,7 @@ "patternMatcher.ts", "preProcess.ts", "rename.ts", - "selectionRange.ts", + "smartSelection.ts", "signatureHelp.ts", "sourcemaps.ts", "suggestionDiagnostics.ts", diff --git a/src/services/types.ts b/src/services/types.ts index d3c9de0f332..4e784e8160b 100644 --- a/src/services/types.ts +++ b/src/services/types.ts @@ -297,7 +297,7 @@ namespace ts { getRenameInfo(fileName: string, position: number, options?: RenameInfoOptions): RenameInfo; findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean, providePrefixAndSuffixTextForRename?: boolean): ReadonlyArray | undefined; - getSelectionRange(fileName: string, position: number): SelectionRange; + getSmartSelectionRange(fileName: string, position: number): SelectionRange; getDefinitionAtPosition(fileName: string, position: number): ReadonlyArray | undefined; getDefinitionAndBoundSpan(fileName: string, position: number): DefinitionInfoAndBoundSpan | undefined; diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/selectionRange.ts index 7940edcdebb..5d4113d3f97 100644 --- a/src/testRunner/unittests/tsserver/selectionRange.ts +++ b/src/testRunner/unittests/tsserver/selectionRange.ts @@ -4,7 +4,7 @@ namespace ts.projectSystem { const host = createServerHost([file, libFile]); const session = createSession(host); openFilesForSession([file], session); - return function getSelectionRange(locations: protocol.SelectionRangeRequestArgs["locations"]) { + return function getSmartSelectionRange(locations: protocol.SelectionRangeRequestArgs["locations"]) { return executeSessionRequest( session, CommandNames.SelectionRange, @@ -14,7 +14,7 @@ namespace ts.projectSystem { describe("unittests:: tsserver:: selectionRange", () => { it("works for simple JavaScript", () => { - const getSelectionRange = setup("/file.js", ` + const getSmartSelectionRange = setup("/file.js", ` class Foo { bar(a, b) { if (a === b) { @@ -24,7 +24,7 @@ class Foo { } }`); - const locations = getSelectionRange([ + const locations = getSmartSelectionRange([ { line: 4, offset: 13, @@ -87,14 +87,14 @@ class Foo { }); it("works for simple TypeScript", () => { - const getSelectionRange = setup("/file.ts", ` + const getSmartSelectionRange = setup("/file.ts", ` export interface IService { _serviceBrand: any; open(host: number, data: any): Promise; bar(): void }`); - const locations = getSelectionRange([ + const locations = getSmartSelectionRange([ { line: 5, offset: 12 }, // ho/**/st { line: 6, offset: 16 }, // void/**/ ]); @@ -136,10 +136,10 @@ export interface IService { }); it("works for complex TypeScript", () => { - const getSelectionRange = setup("/file.ts", ` + const getSmartSelectionRange = setup("/file.ts", ` type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; } & Pick>) `); - const locations = getSelectionRange([ + const locations = getSmartSelectionRange([ { line: 2, offset: 133, @@ -195,13 +195,13 @@ type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAn }); it("works for object types", () => { - const getSelectionRange = setup("/file.js", ` + const getSmartSelectionRange = setup("/file.js", ` type X = { foo?: string; readonly bar: { x: number }; meh }`); - const locations = getSelectionRange([ + const locations = getSmartSelectionRange([ { line: 3, offset: 5 }, { line: 4, offset: 5 }, { line: 4, offset: 14 }, @@ -285,8 +285,8 @@ type X = { it("works for string literals and template strings", () => { // tslint:disable-next-line:no-invalid-template-strings - const getSelectionRange = setup("/file.ts", "`a b ${\n 'c'\n} d`"); - const locations = getSelectionRange([ + const getSmartSelectionRange = setup("/file.ts", "`a b ${\n 'c'\n} d`"); + const locations = getSmartSelectionRange([ { line: 2, offset: 4 }, { line: 1, offset: 4 }, ]); @@ -327,13 +327,13 @@ type X = { }); it("works for ES2015 import lists", () => { - const getSelectionRange = setup("/file.ts", ` + const getSmartSelectionRange = setup("/file.ts", ` import { x as y, z } from './z'; import { b } from './'; console.log(1);`); - const locations = getSelectionRange([{ line: 2, offset: 10 }]); + const locations = getSmartSelectionRange([{ line: 2, offset: 10 }]); assert.deepEqual(locations, [ { textSpan: { // x @@ -367,10 +367,10 @@ console.log(1);`); }); it("works for complex mapped types", () => { - const getSelectionRange = setup("/file.ts", ` + const getSmartSelectionRange = setup("/file.ts", ` type M = { -readonly [K in keyof any]-?: any };`); - const locations = getSelectionRange([ + const locations = getSmartSelectionRange([ { line: 2, offset: 12 }, // -readonly { line: 2, offset: 14 }, // eadonly { line: 2, offset: 22 }, // [ @@ -476,10 +476,10 @@ type M = { -readonly [K in keyof any]-?: any };`); }); it("works for parameters", () => { - const getSelectionRange = setup("/file.ts", ` + const getSmartSelectionRange = setup("/file.ts", ` function f(p, q?, ...r: any[] = []) {}`); - const locations = getSelectionRange([ + const locations = getSmartSelectionRange([ { line: 2, offset: 12 }, // p { line: 2, offset: 15 }, // q { line: 2, offset: 19 }, // ... @@ -537,9 +537,9 @@ function f(p, q?, ...r: any[] = []) {}`); }); it("works for binding elements", () => { - const getSelectionRange = setup("/file.ts", ` + const getSmartSelectionRange = setup("/file.ts", ` const { x, y: a, ...zs = {} } = {};`); - const locations = getSelectionRange([ + const locations = getSmartSelectionRange([ { line: 2, offset: 9 }, // x { line: 2, offset: 15 }, // a { line: 2, offset: 21 }, // zs @@ -578,12 +578,12 @@ const { x, y: a, ...zs = {} } = {};`); }); it("consumes all whitespace in a multi-line function parameter list", () => { - const getSelectionRange = setup("/file.ts", ` + const getSmartSelectionRange = setup("/file.ts", ` function f( a, b ) {}`); - const locations = getSelectionRange([{ line: 4, offset: 5 }]); // b + const locations = getSmartSelectionRange([{ line: 4, offset: 5 }]); // b assert.deepEqual(locations, [{ textSpan: { // b start: { line: 4, offset: 5 }, @@ -604,8 +604,8 @@ function f( }); it("snaps to nodes directly behind the cursor instead of trivia ahead of the cursor", () => { - const getSelectionRange = setup("/file.ts", `let x: string`); - const locations = getSelectionRange([{ line: 1, offset: 4 }]); + const getSmartSelectionRange = setup("/file.ts", `let x: string`); + const locations = getSmartSelectionRange([{ line: 1, offset: 4 }]); assert.deepEqual(locations![0].textSpan, { start: { line: 1, offset: 1 }, end: { line: 1, offset: 4 }, @@ -613,7 +613,7 @@ function f( }); it("creates a stop for JSDoc ranges", () => { - const getSelectionRange = setup("/file.js", "" + + const getSmartSelectionRange = setup("/file.js", "" + `// Not a JSDoc comment /** * @param {number} x The number to square @@ -621,7 +621,7 @@ function f( function square(x) { return x * x; }`); - const locations = getSelectionRange([{ line: 5, offset: 10 }]); // square(x) + const locations = getSmartSelectionRange([{ line: 5, offset: 10 }]); // square(x) assert.deepEqual(locations, [{ textSpan: { // square start: { line: 5 , offset: 10 }, @@ -641,8 +641,8 @@ function square(x) { }); it("skips lone VariableDeclarations in a declaration list", () => { - const getSelectionRange = setup("/file.ts", `const x = 3;`); - const locations = getSelectionRange([{ line: 1, offset: 7 }]); // x + const getSmartSelectionRange = setup("/file.ts", `const x = 3;`); + const locations = getSmartSelectionRange([{ line: 1, offset: 7 }]); // x assert.deepEqual(locations, [{ textSpan: { start: { line: 1, offset: 7 }, diff --git a/tests/baselines/reference/api/tsserverlibrary.d.ts b/tests/baselines/reference/api/tsserverlibrary.d.ts index 1b4acd88ebf..0cf9780593d 100644 --- a/tests/baselines/reference/api/tsserverlibrary.d.ts +++ b/tests/baselines/reference/api/tsserverlibrary.d.ts @@ -4788,6 +4788,7 @@ declare namespace ts { getSignatureHelpItems(fileName: string, position: number, options: SignatureHelpItemsOptions | undefined): SignatureHelpItems | undefined; getRenameInfo(fileName: string, position: number, options?: RenameInfoOptions): RenameInfo; findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean, providePrefixAndSuffixTextForRename?: boolean): ReadonlyArray | undefined; + getSmartSelectionRange(fileName: string, position: number): SelectionRange; getDefinitionAtPosition(fileName: string, position: number): ReadonlyArray | undefined; getDefinitionAndBoundSpan(fileName: string, position: number): DefinitionInfoAndBoundSpan | undefined; getTypeDefinitionAtPosition(fileName: string, position: number): ReadonlyArray | undefined; @@ -5239,6 +5240,10 @@ declare namespace ts { displayParts: SymbolDisplayPart[]; isOptional: boolean; } + interface SelectionRange { + textSpan: TextSpan; + parent?: SelectionRange; + } /** * Represents a single signature to show in signature help. * The id is used for subsequent calls into the language service to ask questions about the @@ -5790,7 +5795,8 @@ declare namespace ts.server.protocol { GetEditsForRefactor = "getEditsForRefactor", OrganizeImports = "organizeImports", GetEditsForFileRename = "getEditsForFileRename", - ConfigurePlugin = "configurePlugin" + ConfigurePlugin = "configurePlugin", + SelectionRange = "selectionRange", } /** * A TypeScript Server message @@ -6753,6 +6759,20 @@ declare namespace ts.server.protocol { } interface ConfigurePluginResponse extends Response { } + interface SelectionRangeRequest extends FileRequest { + command: CommandTypes.SelectionRange; + arguments: SelectionRangeRequestArgs; + } + interface SelectionRangeRequestArgs extends FileRequestArgs { + locations: Location[]; + } + interface SelectionRangeResponse extends Response { + body?: SelectionRange[]; + } + interface SelectionRange { + textSpan: TextSpan; + parent?: SelectionRange; + } /** * Information found in an "open" request. */ @@ -9026,6 +9046,8 @@ declare namespace ts.server { private getBraceMatching; private getDiagnosticsForProject; private configurePlugin; + private getSmartSelectionRange; + private mapSelectionRange; getCanonicalFileName(fileName: string): string; exit(): void; private notRequired; diff --git a/tests/baselines/reference/api/typescript.d.ts b/tests/baselines/reference/api/typescript.d.ts index c25e1d733c0..db24e19b3d8 100644 --- a/tests/baselines/reference/api/typescript.d.ts +++ b/tests/baselines/reference/api/typescript.d.ts @@ -4788,6 +4788,7 @@ declare namespace ts { getSignatureHelpItems(fileName: string, position: number, options: SignatureHelpItemsOptions | undefined): SignatureHelpItems | undefined; getRenameInfo(fileName: string, position: number, options?: RenameInfoOptions): RenameInfo; findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean, providePrefixAndSuffixTextForRename?: boolean): ReadonlyArray | undefined; + getSmartSelectionRange(fileName: string, position: number): SelectionRange; getDefinitionAtPosition(fileName: string, position: number): ReadonlyArray | undefined; getDefinitionAndBoundSpan(fileName: string, position: number): DefinitionInfoAndBoundSpan | undefined; getTypeDefinitionAtPosition(fileName: string, position: number): ReadonlyArray | undefined; @@ -5239,6 +5240,10 @@ declare namespace ts { displayParts: SymbolDisplayPart[]; isOptional: boolean; } + interface SelectionRange { + textSpan: TextSpan; + parent?: SelectionRange; + } /** * Represents a single signature to show in signature help. * The id is used for subsequent calls into the language service to ask questions about the diff --git a/tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter b/tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter index 40bdb4eadab..46971a84547 160000 --- a/tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter +++ b/tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter @@ -1 +1 @@ -Subproject commit 40bdb4eadabc9fbed7d83e3f26817a931c0763b6 +Subproject commit 46971a8454761f1a11d8fde4d96ff8d29bc4e754 diff --git a/tests/cases/user/create-react-app/create-react-app b/tests/cases/user/create-react-app/create-react-app index 1a61db58d43..9514cb88ab9 160000 --- a/tests/cases/user/create-react-app/create-react-app +++ b/tests/cases/user/create-react-app/create-react-app @@ -1 +1 @@ -Subproject commit 1a61db58d434d33603f20e73ca643ec83c561b73 +Subproject commit 9514cb88ab92fec7f5df2914702ef23a62c0a249 diff --git a/tests/cases/user/prettier/prettier b/tests/cases/user/prettier/prettier index 1e471a00796..0b07e108333 160000 --- a/tests/cases/user/prettier/prettier +++ b/tests/cases/user/prettier/prettier @@ -1 +1 @@ -Subproject commit 1e471a007968b7490563b91ed6909ae6046f3fe8 +Subproject commit 0b07e1083339e28a8239df3f5245f530cc4fd7f8 From 12492a369e7d973cf89fd9301d0c452c12e218d7 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 18 Apr 2019 16:28:12 -0700 Subject: [PATCH 018/119] Rename test to match --- src/testRunner/tsconfig.json | 2 +- .../unittests/tsserver/{selectionRange.ts => smartSelection.ts} | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename src/testRunner/unittests/tsserver/{selectionRange.ts => smartSelection.ts} (100%) diff --git a/src/testRunner/tsconfig.json b/src/testRunner/tsconfig.json index 5ae94c80c23..c4fa16ba715 100644 --- a/src/testRunner/tsconfig.json +++ b/src/testRunner/tsconfig.json @@ -141,7 +141,7 @@ "unittests/tsserver/reload.ts", "unittests/tsserver/rename.ts", "unittests/tsserver/resolutionCache.ts", - "unittests/tsserver/selectionRange.ts", + "unittests/tsserver/smartSelection.ts", "unittests/tsserver/session.ts", "unittests/tsserver/skipLibCheck.ts", "unittests/tsserver/symLinks.ts", diff --git a/src/testRunner/unittests/tsserver/selectionRange.ts b/src/testRunner/unittests/tsserver/smartSelection.ts similarity index 100% rename from src/testRunner/unittests/tsserver/selectionRange.ts rename to src/testRunner/unittests/tsserver/smartSelection.ts From 511cc79642bed5e0a612a227e9458d8b55ff8b45 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 18 Apr 2019 17:21:52 -0700 Subject: [PATCH 019/119] Revert accidental line break added --- src/compiler/utilities.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/compiler/utilities.ts b/src/compiler/utilities.ts index 91f6e3b4218..2e6c3ae4f86 100644 --- a/src/compiler/utilities.ts +++ b/src/compiler/utilities.ts @@ -7624,7 +7624,6 @@ namespace ts { return root + pathComponents.slice(1).join(directorySeparator); } - } /* @internal */ From 99ace033bfdcf3155357e420f19281e0e7721abc Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 18 Apr 2019 17:23:54 -0700 Subject: [PATCH 020/119] Revert accidental line ending change --- src/server/tsconfig.json | 54 ++++++++++++++++++++-------------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/src/server/tsconfig.json b/src/server/tsconfig.json index 1410440512b..3cf28ab40ee 100644 --- a/src/server/tsconfig.json +++ b/src/server/tsconfig.json @@ -1,27 +1,27 @@ -{ - "extends": "../tsconfig-base", - "compilerOptions": { - "removeComments": false, - "outFile": "../../built/local/server.js", - "preserveConstEnums": true, - "types": [ - "node" - ] - }, - "references": [ - { "path": "../compiler" }, - { "path": "../jsTyping" }, - { "path": "../services" } - ], - "files": [ - "types.ts", - "utilities.ts", - "protocol.ts", - "scriptInfo.ts", - "typingsCache.ts", - "project.ts", - "editorServices.ts", - "session.ts", - "scriptVersionCache.ts" - ] -} +{ + "extends": "../tsconfig-base", + "compilerOptions": { + "removeComments": false, + "outFile": "../../built/local/server.js", + "preserveConstEnums": true, + "types": [ + "node" + ] + }, + "references": [ + { "path": "../compiler" }, + { "path": "../jsTyping" }, + { "path": "../services" } + ], + "files": [ + "types.ts", + "utilities.ts", + "protocol.ts", + "scriptInfo.ts", + "typingsCache.ts", + "project.ts", + "editorServices.ts", + "session.ts", + "scriptVersionCache.ts" + ] +} From 6177596c270274d18949106cf668254cdb5e0c90 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 18 Apr 2019 17:52:09 -0700 Subject: [PATCH 021/119] Revert accidental submodule change I guess --- .../cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter | 2 +- tests/cases/user/create-react-app/create-react-app | 2 +- tests/cases/user/prettier/prettier | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter b/tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter index 46971a84547..40bdb4eadab 160000 --- a/tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter +++ b/tests/cases/user/TypeScript-Node-Starter/TypeScript-Node-Starter @@ -1 +1 @@ -Subproject commit 46971a8454761f1a11d8fde4d96ff8d29bc4e754 +Subproject commit 40bdb4eadabc9fbed7d83e3f26817a931c0763b6 diff --git a/tests/cases/user/create-react-app/create-react-app b/tests/cases/user/create-react-app/create-react-app index 9514cb88ab9..1a61db58d43 160000 --- a/tests/cases/user/create-react-app/create-react-app +++ b/tests/cases/user/create-react-app/create-react-app @@ -1 +1 @@ -Subproject commit 9514cb88ab92fec7f5df2914702ef23a62c0a249 +Subproject commit 1a61db58d434d33603f20e73ca643ec83c561b73 diff --git a/tests/cases/user/prettier/prettier b/tests/cases/user/prettier/prettier index 0b07e108333..1e471a00796 160000 --- a/tests/cases/user/prettier/prettier +++ b/tests/cases/user/prettier/prettier @@ -1 +1 @@ -Subproject commit 0b07e1083339e28a8239df3f5245f530cc4fd7f8 +Subproject commit 1e471a007968b7490563b91ed6909ae6046f3fe8 From f0a3d2bf92cd59d3c068246109c5832f83d3d150 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Fri, 19 Apr 2019 09:44:42 -0700 Subject: [PATCH 022/119] Filter out zero-width selections --- src/services/smartSelection.ts | 11 ++++--- .../unittests/tsserver/smartSelection.ts | 33 ++++++++++++++++++- 2 files changed, 39 insertions(+), 5 deletions(-) diff --git a/src/services/smartSelection.ts b/src/services/smartSelection.ts index ba2ec60e9c5..ddd3c75c2c7 100644 --- a/src/services/smartSelection.ts +++ b/src/services/smartSelection.ts @@ -70,10 +70,13 @@ namespace ts.SmartSelectionRange { return selectionRange; function pushSelectionRange(start: number, end: number): void { - // Skip ranges that are identical to the parent - const textSpan = createTextSpanFromBounds(start, end); - if (!selectionRange || !textSpansEqual(textSpan, selectionRange.textSpan)) { - selectionRange = { textSpan, ...selectionRange && { parent: selectionRange } }; + // Skip empty ranges + if (start !== end) { + // Skip ranges that are identical to the parent + const textSpan = createTextSpanFromBounds(start, end); + if (!selectionRange || !textSpansEqual(textSpan, selectionRange.textSpan)) { + selectionRange = { textSpan, ...selectionRange && { parent: selectionRange } }; + } } } } diff --git a/src/testRunner/unittests/tsserver/smartSelection.ts b/src/testRunner/unittests/tsserver/smartSelection.ts index 5d4113d3f97..fca96ab848e 100644 --- a/src/testRunner/unittests/tsserver/smartSelection.ts +++ b/src/testRunner/unittests/tsserver/smartSelection.ts @@ -12,7 +12,7 @@ namespace ts.projectSystem { }; } - describe("unittests:: tsserver:: selectionRange", () => { + describe("unittests:: tsserver:: smartSelection", () => { it("works for simple JavaScript", () => { const getSmartSelectionRange = setup("/file.js", ` class Foo { @@ -652,5 +652,36 @@ function square(x) { start: { line: 1, offset: 1 }, end: { line: 1, offset: 13 } } } }]); }); + + it("never returns empty ranges", () => { + const getSmartSelectionRange = setup("/file.ts", ` +class HomePage { + componentDidMount() { + if (this.props.username) { + return ''; + } + } +}`); + const locations = getSmartSelectionRange([ + { line: 3, offset: 23 }, // componentDidMount(/**/) + { line: 4, offset: 32 }, // username/**/) + { line: 5, offset: 21 }, // return '/**/' + ]); + + assert.deepEqual(locations![0].textSpan, { // this.props.username + start: { line: 3, offset: 23 }, + end: { line: 3, offset: 24 }, + }); + + assert.deepEqual(locations![1].textSpan, { // this.props.username + start: { line: 4, offset: 32 }, + end: { line: 4, offset: 33 }, + }); + + assert.deepEqual(locations![2].textSpan, { // '' + start: { line: 5, offset: 20 }, + end: { line: 5, offset: 22 }, + }); + }); }); } From 6fc2e4a32e9da29bdf4e4b0fbc1616836d31db6a Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Tue, 23 Apr 2019 15:34:01 -0700 Subject: [PATCH 023/119] Add custom baseline format for smart selection --- src/harness/fourslash.ts | 52 +++++++++++++++++++++++++----- tests/cases/fourslash/fourslash.ts | 3 +- 2 files changed, 46 insertions(+), 9 deletions(-) diff --git a/src/harness/fourslash.ts b/src/harness/fourslash.ts index 9e117cdfd8f..b562f908a6c 100644 --- a/src/harness/fourslash.ts +++ b/src/harness/fourslash.ts @@ -1417,12 +1417,7 @@ Actual: ${stringify(fullActual)}`); } public baselineCurrentFileBreakpointLocations() { - let baselineFile = this.testData.globalOptions[MetadataOptionNames.baselineFile]; - if (!baselineFile) { - baselineFile = this.activeFile.fileName.replace(this.basePath + "/breakpointValidation", "bpSpan"); - baselineFile = baselineFile.replace(ts.Extension.Ts, ".baseline"); - - } + const baselineFile = this.getBaselineFileName().replace(this.basePath + "/breakpointValidation", "bpSpan"); Harness.Baseline.runBaseline(baselineFile, this.baselineCurrentFileLocations(pos => this.getBreakpointStatementLocation(pos)!)); } @@ -1497,8 +1492,7 @@ Actual: ${stringify(fullActual)}`); } public baselineQuickInfo() { - const baselineFile = this.testData.globalOptions[MetadataOptionNames.baselineFile] || - ts.getBaseFileName(this.activeFile.fileName).replace(ts.Extension.Ts, ".baseline"); + const baselineFile = this.getBaselineFileName(); Harness.Baseline.runBaseline( baselineFile, stringify( @@ -1508,6 +1502,39 @@ Actual: ${stringify(fullActual)}`); })))); } + public baselineSmartSelection() { + const n = ts.sys.newLine; + const baselineFile = this.getBaselineFileName(); + const markers = this.getMarkers(); + const fileContent = this.activeFile.content; + const text = markers.map(marker => { + const baselineContent = [fileContent.slice(0, marker.position) + "/**/" + fileContent.slice(marker.position) + n]; + let selectionRange: ts.SelectionRange | undefined = this.languageService.getSmartSelectionRange(this.activeFile.fileName, marker.position); + while (selectionRange) { + const { textSpan } = selectionRange; + let masked = Array.from(fileContent).map((char, index) => { + const charCode = char.charCodeAt(0); + if (index >= textSpan.start && index < ts.textSpanEnd(textSpan)) { + return char === " " ? "•" : ts.isLineBreak(charCode) ? `↲${n}` : char; + } + return ts.isLineBreak(charCode) ? char : " "; + }).join(""); + masked = masked.replace(/^\s*$\r?\n?/gm, ""); // Remove blank lines + const isRealCharacter = (char: string) => char !== "•" && char !== "↲" && !ts.isWhiteSpaceLike(char.charCodeAt(0)); + const leadingWidth = Array.from(masked).findIndex(isRealCharacter); + const trailingWidth = ts.findLastIndex(Array.from(masked), isRealCharacter); + masked = masked.slice(0, leadingWidth) + + masked.slice(leadingWidth, trailingWidth).replace(/•/g, " ").replace(/↲/g, "") + + masked.slice(trailingWidth); + baselineContent.push(masked); + selectionRange = selectionRange.parent; + } + return baselineContent.join(n); + }).join(n.repeat(2) + "=".repeat(80) + n.repeat(2)); + + Harness.Baseline.runBaseline(baselineFile, text); + } + public printBreakpointLocation(pos: number) { Harness.IO.log("\n**Pos: " + pos + " " + this.spanInfoToString(this.getBreakpointStatementLocation(pos)!, " ")); } @@ -1562,6 +1589,11 @@ Actual: ${stringify(fullActual)}`); Harness.IO.log(stringify(help.items[help.selectedItemIndex])); } + private getBaselineFileName() { + return this.testData.globalOptions[MetadataOptionNames.baselineFile] || + ts.getBaseFileName(this.activeFile.fileName).replace(ts.Extension.Ts, ".baseline"); + } + private getSignatureHelp({ triggerReason }: FourSlashInterface.VerifySignatureHelpOptions): ts.SignatureHelpItems | undefined { return this.languageService.getSignatureHelpItems(this.activeFile.fileName, this.currentCaretPosition, { triggerReason @@ -3973,6 +4005,10 @@ namespace FourSlashInterface { this.state.baselineQuickInfo(); } + public baselineSmartSelection() { + this.state.baselineSmartSelection(); + } + public nameOrDottedNameSpanTextIs(text: string) { this.state.verifyCurrentNameOrDottedNameSpanText(text); } diff --git a/tests/cases/fourslash/fourslash.ts b/tests/cases/fourslash/fourslash.ts index 6488748b728..4252296d5da 100644 --- a/tests/cases/fourslash/fourslash.ts +++ b/tests/cases/fourslash/fourslash.ts @@ -244,6 +244,7 @@ declare namespace FourSlashInterface { baselineGetEmitOutput(insertResultsIntoVfs?: boolean): void; getEmitOutput(expectedOutputFiles: ReadonlyArray): void; baselineQuickInfo(): void; + baselineSmartSelection(): void; nameOrDottedNameSpanTextIs(text: string): void; outliningSpansInCurrentFile(spans: Range[]): void; todoCommentsInCurrentFile(descriptors: string[]): void; @@ -508,7 +509,7 @@ declare namespace FourSlashInterface { readonly importModuleSpecifierEnding?: "minimal" | "index" | "js"; } interface CompletionsOptions { - readonly marker?: ArrayOrSingle, + readonly marker?: ArrayOrSingle; readonly isNewIdentifierLocation?: boolean; readonly isGlobalCompletion?: boolean; readonly exact?: ArrayOrSingle; From e28b9b2ba2f9b4857006293db5b9d567a2618754 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Tue, 23 Apr 2019 16:41:59 -0700 Subject: [PATCH 024/119] Copy smartSelect tests to fourslash --- src/harness/fourslash.ts | 2 +- .../reference/smartSelection_JSDoc.baseline | 30 +++ .../smartSelection_behindCaret.baseline | 4 + .../smartSelection_bindingPatterns.baseline | 27 +++ .../reference/smartSelection_complex.baseline | 12 ++ .../smartSelection_emptyRanges.baseline | 140 ++++++++++++++ .../smartSelection_functionParams1.baseline | 25 +++ .../smartSelection_functionParams2.baseline | 18 ++ .../reference/smartSelection_imports.baseline | 29 +++ ...Selection_loneVariableDeclaration.baseline | 4 + .../smartSelection_mappedTypes.baseline | 65 +++++++ .../smartSelection_objectTypes.baseline | 174 ++++++++++++++++++ .../reference/smartSelection_simple1.baseline | 116 ++++++++++++ .../reference/smartSelection_simple2.baseline | 63 +++++++ .../smartSelection_templateStrings.baseline | 37 ++++ tests/cases/fourslash/smartSelection_JSDoc.ts | 11 ++ .../fourslash/smartSelection_behindCaret.ts | 6 + .../smartSelection_bindingPatterns.ts | 5 + .../cases/fourslash/smartSelection_complex.ts | 5 + .../fourslash/smartSelection_emptyRanges.ts | 11 ++ .../smartSelection_functionParams1.ts | 5 + .../smartSelection_functionParams2.ts | 8 + .../cases/fourslash/smartSelection_imports.ts | 8 + .../smartSelection_loneVariableDeclaration.ts | 5 + .../fourslash/smartSelection_mappedTypes.ts | 5 + .../fourslash/smartSelection_objectTypes.ts | 9 + .../cases/fourslash/smartSelection_simple1.ts | 12 ++ .../cases/fourslash/smartSelection_simple2.ts | 10 + .../smartSelection_templateStrings.ts | 7 + 29 files changed, 852 insertions(+), 1 deletion(-) create mode 100644 tests/baselines/reference/smartSelection_JSDoc.baseline create mode 100644 tests/baselines/reference/smartSelection_behindCaret.baseline create mode 100644 tests/baselines/reference/smartSelection_bindingPatterns.baseline create mode 100644 tests/baselines/reference/smartSelection_complex.baseline create mode 100644 tests/baselines/reference/smartSelection_emptyRanges.baseline create mode 100644 tests/baselines/reference/smartSelection_functionParams1.baseline create mode 100644 tests/baselines/reference/smartSelection_functionParams2.baseline create mode 100644 tests/baselines/reference/smartSelection_imports.baseline create mode 100644 tests/baselines/reference/smartSelection_loneVariableDeclaration.baseline create mode 100644 tests/baselines/reference/smartSelection_mappedTypes.baseline create mode 100644 tests/baselines/reference/smartSelection_objectTypes.baseline create mode 100644 tests/baselines/reference/smartSelection_simple1.baseline create mode 100644 tests/baselines/reference/smartSelection_simple2.baseline create mode 100644 tests/baselines/reference/smartSelection_templateStrings.baseline create mode 100644 tests/cases/fourslash/smartSelection_JSDoc.ts create mode 100644 tests/cases/fourslash/smartSelection_behindCaret.ts create mode 100644 tests/cases/fourslash/smartSelection_bindingPatterns.ts create mode 100644 tests/cases/fourslash/smartSelection_complex.ts create mode 100644 tests/cases/fourslash/smartSelection_emptyRanges.ts create mode 100644 tests/cases/fourslash/smartSelection_functionParams1.ts create mode 100644 tests/cases/fourslash/smartSelection_functionParams2.ts create mode 100644 tests/cases/fourslash/smartSelection_imports.ts create mode 100644 tests/cases/fourslash/smartSelection_loneVariableDeclaration.ts create mode 100644 tests/cases/fourslash/smartSelection_mappedTypes.ts create mode 100644 tests/cases/fourslash/smartSelection_objectTypes.ts create mode 100644 tests/cases/fourslash/smartSelection_simple1.ts create mode 100644 tests/cases/fourslash/smartSelection_simple2.ts create mode 100644 tests/cases/fourslash/smartSelection_templateStrings.ts diff --git a/src/harness/fourslash.ts b/src/harness/fourslash.ts index b562f908a6c..66ea1ba38c4 100644 --- a/src/harness/fourslash.ts +++ b/src/harness/fourslash.ts @@ -1529,7 +1529,7 @@ Actual: ${stringify(fullActual)}`); baselineContent.push(masked); selectionRange = selectionRange.parent; } - return baselineContent.join(n); + return baselineContent.join(fileContent.includes("\n") ? n + n : n); }).join(n.repeat(2) + "=".repeat(80) + n.repeat(2)); Harness.Baseline.runBaseline(baselineFile, text); diff --git a/tests/baselines/reference/smartSelection_JSDoc.baseline b/tests/baselines/reference/smartSelection_JSDoc.baseline new file mode 100644 index 00000000000..6f223644e43 --- /dev/null +++ b/tests/baselines/reference/smartSelection_JSDoc.baseline @@ -0,0 +1,30 @@ +// Not a JSDoc comment +/** + * @param {number} x The number to square + */ +function /**/square(x) { + return x * x; +} + + + square + + +function square(x) { + return x * x; +} + +/** + * @param {number} x The number to square + */ +function square(x) { + return x * x; +} + +// Not a JSDoc comment +/** + * @param {number} x The number to square + */ +function square(x) { + return x * x; +} \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_behindCaret.baseline b/tests/baselines/reference/smartSelection_behindCaret.baseline new file mode 100644 index 00000000000..6b7b393f7ea --- /dev/null +++ b/tests/baselines/reference/smartSelection_behindCaret.baseline @@ -0,0 +1,4 @@ +let/**/ x: string + +let +let x: string \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_bindingPatterns.baseline b/tests/baselines/reference/smartSelection_bindingPatterns.baseline new file mode 100644 index 00000000000..78f3e4a10b7 --- /dev/null +++ b/tests/baselines/reference/smartSelection_bindingPatterns.baseline @@ -0,0 +1,27 @@ +const { /**/x, y: a, ...zs = {} } = {}; + + x + x, y: a, ...zs = {} + { x, y: a, ...zs = {} } +const { x, y: a, ...zs = {} } = {}; + +================================================================================ + +const { x, y: /**/a, ...zs = {} } = {}; + + a + y: a + x, y: a, ...zs = {} + { x, y: a, ...zs = {} } +const { x, y: a, ...zs = {} } = {}; + +================================================================================ + +const { x, y: a, .../**/zs = {} } = {}; + + zs + ...zs + ...zs = {} + x, y: a, ...zs = {} + { x, y: a, ...zs = {} } +const { x, y: a, ...zs = {} } = {}; \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_complex.baseline b/tests/baselines/reference/smartSelection_complex.baseline new file mode 100644 index 00000000000..c16b1912ae7 --- /dev/null +++ b/tests/baselines/reference/smartSelection_complex.baseline @@ -0,0 +1,12 @@ +type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[/**/K] : P[K]; } & Pick>) + + K + P[K] + K extends keyof T ? T[K] : P[K] + IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K] + [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; + { [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; } + { [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; } & Pick> + ({ [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; } & Pick>) + IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; } & Pick>) +type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; } & Pick>) \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_emptyRanges.baseline b/tests/baselines/reference/smartSelection_emptyRanges.baseline new file mode 100644 index 00000000000..8ec58d839ab --- /dev/null +++ b/tests/baselines/reference/smartSelection_emptyRanges.baseline @@ -0,0 +1,140 @@ +class HomePage { + componentDidMount(/**/) { + if (this.props.username) { + return ''; + } + } +} + + + ) + + + componentDidMount() { + if (this.props.username) { + return ''; + } + } + + + ↲ +••componentDidMount() { + if (this.props.username) { + return ''; + } + }↲ + + +class HomePage { + componentDidMount() { + if (this.props.username) { + return ''; + } + } +} + +================================================================================ + +class HomePage { + componentDidMount() { + if (this.props.username/**/) { + return ''; + } + } +} + + + ) + + + if (this.props.username) { + return ''; + } + + + ↲ +••••if (this.props.username) { + return ''; + }↲ +•• + + + componentDidMount() { + if (this.props.username) { + return ''; + } + } + + + ↲ +••componentDidMount() { + if (this.props.username) { + return ''; + } + }↲ + + +class HomePage { + componentDidMount() { + if (this.props.username) { + return ''; + } + } +} + +================================================================================ + +class HomePage { + componentDidMount() { + if (this.props.username) { + return '/**/'; + } + } +} + + + '' + + + return ''; + + + ↲ +••••••return '';↲ +•••• + + + if (this.props.username) { + return ''; + } + + + ↲ +••••if (this.props.username) { + return ''; + }↲ +•• + + + componentDidMount() { + if (this.props.username) { + return ''; + } + } + + + ↲ +••componentDidMount() { + if (this.props.username) { + return ''; + } + }↲ + + +class HomePage { + componentDidMount() { + if (this.props.username) { + return ''; + } + } +} \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_functionParams1.baseline b/tests/baselines/reference/smartSelection_functionParams1.baseline new file mode 100644 index 00000000000..1162ceb917a --- /dev/null +++ b/tests/baselines/reference/smartSelection_functionParams1.baseline @@ -0,0 +1,25 @@ +function f(/**/p, q?, ...r: any[] = []) {} + + p + p, q?, ...r: any[] = [] +function f(p, q?, ...r: any[] = []) {} + +================================================================================ + +function f(p, /**/q?, ...r: any[] = []) {} + + q + q? + p, q?, ...r: any[] = [] +function f(p, q?, ...r: any[] = []) {} + +================================================================================ + +function f(p, q?, /**/...r: any[] = []) {} + + ... + ...r + ...r: any[] + ...r: any[] = [] + p, q?, ...r: any[] = [] +function f(p, q?, ...r: any[] = []) {} \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_functionParams2.baseline b/tests/baselines/reference/smartSelection_functionParams2.baseline new file mode 100644 index 00000000000..5f355ff0f0e --- /dev/null +++ b/tests/baselines/reference/smartSelection_functionParams2.baseline @@ -0,0 +1,18 @@ +function f( + a, + /**/b +) {} + + + b + + + ↲ +••a, + b↲ + + +function f( + a, + b +) {} \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_imports.baseline b/tests/baselines/reference/smartSelection_imports.baseline new file mode 100644 index 00000000000..f3a449ee13e --- /dev/null +++ b/tests/baselines/reference/smartSelection_imports.baseline @@ -0,0 +1,29 @@ +import { /**/x as y, z } from './z'; +import { b } from './'; + +console.log(1); + + + x + + + x as y + + + x as y, z + + + { x as y, z } + + +import { x as y, z } from './z'; + + +import { x as y, z } from './z'; +import { b } from './'; + + +import { x as y, z } from './z'; +import { b } from './'; + +console.log(1); \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_loneVariableDeclaration.baseline b/tests/baselines/reference/smartSelection_loneVariableDeclaration.baseline new file mode 100644 index 00000000000..df2345bd20f --- /dev/null +++ b/tests/baselines/reference/smartSelection_loneVariableDeclaration.baseline @@ -0,0 +1,4 @@ +const /**/x = 3; + + x +const x = 3; \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_mappedTypes.baseline b/tests/baselines/reference/smartSelection_mappedTypes.baseline new file mode 100644 index 00000000000..5dd6b37d7fe --- /dev/null +++ b/tests/baselines/reference/smartSelection_mappedTypes.baseline @@ -0,0 +1,65 @@ +type M = { /**/-readonly [K in keyof any]-?: any }; + + - + -readonly + -readonly [K in keyof any]-? + -readonly [K in keyof any]-?: any + { -readonly [K in keyof any]-?: any } +type M = { -readonly [K in keyof any]-?: any }; + +================================================================================ + +type M = { -re/**/adonly [K in keyof any]-?: any }; + + readonly + -readonly + -readonly [K in keyof any]-? + -readonly [K in keyof any]-?: any + { -readonly [K in keyof any]-?: any } +type M = { -readonly [K in keyof any]-?: any }; + +================================================================================ + +type M = { -readonly /**/[K in keyof any]-?: any }; + + [ + [K in keyof any] + -readonly [K in keyof any]-? + -readonly [K in keyof any]-?: any + { -readonly [K in keyof any]-?: any } +type M = { -readonly [K in keyof any]-?: any }; + +================================================================================ + +type M = { -readonly [K in ke/**/yof any]-?: any }; + + keyof + keyof any + K in keyof any + [K in keyof any] + -readonly [K in keyof any]-? + -readonly [K in keyof any]-?: any + { -readonly [K in keyof any]-?: any } +type M = { -readonly [K in keyof any]-?: any }; + +================================================================================ + +type M = { -readonly [K in keyof any]/**/-?: any }; + + - + -? + -readonly [K in keyof any]-? + -readonly [K in keyof any]-?: any + { -readonly [K in keyof any]-?: any } +type M = { -readonly [K in keyof any]-?: any }; + +================================================================================ + +type M = { -readonly [K in keyof any]-/**/?: any }; + + ? + -? + -readonly [K in keyof any]-? + -readonly [K in keyof any]-?: any + { -readonly [K in keyof any]-?: any } +type M = { -readonly [K in keyof any]-?: any }; \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_objectTypes.baseline b/tests/baselines/reference/smartSelection_objectTypes.baseline new file mode 100644 index 00000000000..612d5df2faa --- /dev/null +++ b/tests/baselines/reference/smartSelection_objectTypes.baseline @@ -0,0 +1,174 @@ +type X = { + /**/foo?: string; + readonly bar: { x: number }; + meh +} + + + foo + + + foo? + + + foo?: string; + + + ↲ +••foo?: string; + readonly bar: { x: number }; + meh↲ + + + { + foo?: string; + readonly bar: { x: number }; + meh +} + +type X = { + foo?: string; + readonly bar: { x: number }; + meh +} + +================================================================================ + +type X = { + foo?: string; + /**/readonly bar: { x: number }; + meh +} + + + readonly + + + readonly bar + + + readonly bar: { x: number }; + + + ↲ +••foo?: string; + readonly bar: { x: number }; + meh↲ + + + { + foo?: string; + readonly bar: { x: number }; + meh +} + +type X = { + foo?: string; + readonly bar: { x: number }; + meh +} + +================================================================================ + +type X = { + foo?: string; + readonly /**/bar: { x: number }; + meh +} + + + bar + + + readonly bar + + + readonly bar: { x: number }; + + + ↲ +••foo?: string; + readonly bar: { x: number }; + meh↲ + + + { + foo?: string; + readonly bar: { x: number }; + meh +} + +type X = { + foo?: string; + readonly bar: { x: number }; + meh +} + +================================================================================ + +type X = { + foo?: string; + readonly bar: { x: num/**/ber }; + meh +} + + + number + + + x: number + + + { x: number } + + + readonly bar: { x: number }; + + + ↲ +••foo?: string; + readonly bar: { x: number }; + meh↲ + + + { + foo?: string; + readonly bar: { x: number }; + meh +} + +type X = { + foo?: string; + readonly bar: { x: number }; + meh +} + +================================================================================ + +type X = { + foo?: string; + readonly bar: { x: number }; + /**/meh +} + + + meh + + + ↲ +••foo?: string; + readonly bar: { x: number }; + meh↲ + + + { + foo?: string; + readonly bar: { x: number }; + meh +} + +type X = { + foo?: string; + readonly bar: { x: number }; + meh +} \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_simple1.baseline b/tests/baselines/reference/smartSelection_simple1.baseline new file mode 100644 index 00000000000..f28c607c524 --- /dev/null +++ b/tests/baselines/reference/smartSelection_simple1.baseline @@ -0,0 +1,116 @@ +class Foo { + bar(a, b) { + if (/**/a === b) { + return true; + } + return false; + } +} + + + a + + + a === b + + + if (a === b) { + return true; + } + + + ↲ +••••••if (a === b) { + return true; + } + return false;↲ +•• + + + bar(a, b) { + if (a === b) { + return true; + } + return false; + } + + + ↲ +••bar(a, b) { + if (a === b) { + return true; + } + return false; + }↲ + + +class Foo { + bar(a, b) { + if (a === b) { + return true; + } + return false; + } +} + +================================================================================ + +class Foo { + bar(a, b) { + if (a === b) { + return tr/**/ue; + } + return false; + } +} + + + true + + + return true; + + + ↲ +••••••••••return true;↲ +•••••• + + + if (a === b) { + return true; + } + + + ↲ +••••••if (a === b) { + return true; + } + return false;↲ +•• + + + bar(a, b) { + if (a === b) { + return true; + } + return false; + } + + + ↲ +••bar(a, b) { + if (a === b) { + return true; + } + return false; + }↲ + + +class Foo { + bar(a, b) { + if (a === b) { + return true; + } + return false; + } +} \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_simple2.baseline b/tests/baselines/reference/smartSelection_simple2.baseline new file mode 100644 index 00000000000..2c4b520d449 --- /dev/null +++ b/tests/baselines/reference/smartSelection_simple2.baseline @@ -0,0 +1,63 @@ +export interface IService { + _serviceBrand: any; + + open(ho/**/st: number, data: any): Promise; + bar(): void +} + + + host + + + host: number + + + host: number, data: any + + + open(host: number, data: any): Promise; + + + ↲ +••_serviceBrand: any; + + open(host: number, data: any): Promise; + bar(): void↲ + + +export interface IService { + _serviceBrand: any; + + open(host: number, data: any): Promise; + bar(): void +} + +================================================================================ + +export interface IService { + _serviceBrand: any; + + open(host: number, data: any): Promise; + bar(): void/**/ +} + + + void + + + bar(): void + + + ↲ +••_serviceBrand: any; + + open(host: number, data: any): Promise; + bar(): void↲ + + +export interface IService { + _serviceBrand: any; + + open(host: number, data: any): Promise; + bar(): void +} \ No newline at end of file diff --git a/tests/baselines/reference/smartSelection_templateStrings.baseline b/tests/baselines/reference/smartSelection_templateStrings.baseline new file mode 100644 index 00000000000..91fec157842 --- /dev/null +++ b/tests/baselines/reference/smartSelection_templateStrings.baseline @@ -0,0 +1,37 @@ +`a /**/b ${ + 'c' +} d` + + + a b ${ + 'c' +} d + +`a b ${ + 'c' +} d` + +================================================================================ + +`a b ${ + '/**/c' +} d` + + + c + + + 'c' + + + ${ + 'c' +} + + a b ${ + 'c' +} d + +`a b ${ + 'c' +} d` \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_JSDoc.ts b/tests/cases/fourslash/smartSelection_JSDoc.ts new file mode 100644 index 00000000000..2d50810a11e --- /dev/null +++ b/tests/cases/fourslash/smartSelection_JSDoc.ts @@ -0,0 +1,11 @@ +/// + +////// Not a JSDoc comment +/////** +//// * @param {number} x The number to square +//// */ +////function /**/square(x) { +//// return x * x; +////} + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_behindCaret.ts b/tests/cases/fourslash/smartSelection_behindCaret.ts new file mode 100644 index 00000000000..f7bb0ec169d --- /dev/null +++ b/tests/cases/fourslash/smartSelection_behindCaret.ts @@ -0,0 +1,6 @@ +/// + +////let/**/ x: string + +// Verifies that the selection goes to 'let' first even though it’s behind the caret +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_bindingPatterns.ts b/tests/cases/fourslash/smartSelection_bindingPatterns.ts new file mode 100644 index 00000000000..350f72bac25 --- /dev/null +++ b/tests/cases/fourslash/smartSelection_bindingPatterns.ts @@ -0,0 +1,5 @@ +/// + +////const { /*1*/x, y: /*2*/a, .../*3*/zs = {} } = {}; + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_complex.ts b/tests/cases/fourslash/smartSelection_complex.ts new file mode 100644 index 00000000000..28797e4833e --- /dev/null +++ b/tests/cases/fourslash/smartSelection_complex.ts @@ -0,0 +1,5 @@ +/// + +////type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[/**/K] : P[K]; } & Pick>) + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_emptyRanges.ts b/tests/cases/fourslash/smartSelection_emptyRanges.ts new file mode 100644 index 00000000000..6f2bfe7a2c0 --- /dev/null +++ b/tests/cases/fourslash/smartSelection_emptyRanges.ts @@ -0,0 +1,11 @@ +/// + +////class HomePage { +//// componentDidMount(/*1*/) { +//// if (this.props.username/*2*/) { +//// return '/*3*/'; +//// } +//// } +////} + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_functionParams1.ts b/tests/cases/fourslash/smartSelection_functionParams1.ts new file mode 100644 index 00000000000..d2e0350d73a --- /dev/null +++ b/tests/cases/fourslash/smartSelection_functionParams1.ts @@ -0,0 +1,5 @@ +/// + +////function f(/*1*/p, /*2*/q?, /*3*/...r: any[] = []) {} + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_functionParams2.ts b/tests/cases/fourslash/smartSelection_functionParams2.ts new file mode 100644 index 00000000000..0172763a70e --- /dev/null +++ b/tests/cases/fourslash/smartSelection_functionParams2.ts @@ -0,0 +1,8 @@ +/// + +////function f( +//// a, +//// /**/b +////) {} + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_imports.ts b/tests/cases/fourslash/smartSelection_imports.ts new file mode 100644 index 00000000000..4e800f6973b --- /dev/null +++ b/tests/cases/fourslash/smartSelection_imports.ts @@ -0,0 +1,8 @@ +/// + +////import { /**/x as y, z } from './z'; +////import { b } from './'; +//// +////console.log(1); + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_loneVariableDeclaration.ts b/tests/cases/fourslash/smartSelection_loneVariableDeclaration.ts new file mode 100644 index 00000000000..ae50d094ee7 --- /dev/null +++ b/tests/cases/fourslash/smartSelection_loneVariableDeclaration.ts @@ -0,0 +1,5 @@ +/// + +////const /**/x = 3; + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_mappedTypes.ts b/tests/cases/fourslash/smartSelection_mappedTypes.ts new file mode 100644 index 00000000000..0f76491a592 --- /dev/null +++ b/tests/cases/fourslash/smartSelection_mappedTypes.ts @@ -0,0 +1,5 @@ +/// + +////type M = { /*1*/-re/*2*/adonly /*3*/[K in ke/*4*/yof any]/*5*/-/*6*/?: any }; + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_objectTypes.ts b/tests/cases/fourslash/smartSelection_objectTypes.ts new file mode 100644 index 00000000000..3d458c43b4c --- /dev/null +++ b/tests/cases/fourslash/smartSelection_objectTypes.ts @@ -0,0 +1,9 @@ +/// + +////type X = { +//// /*1*/foo?: string; +//// /*2*/readonly /*3*/bar: { x: num/*4*/ber }; +//// /*5*/meh +////} + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_simple1.ts b/tests/cases/fourslash/smartSelection_simple1.ts new file mode 100644 index 00000000000..97d7249138b --- /dev/null +++ b/tests/cases/fourslash/smartSelection_simple1.ts @@ -0,0 +1,12 @@ +/// + +////class Foo { +//// bar(a, b) { +//// if (/*1*/a === b) { +//// return tr/*2*/ue; +//// } +//// return false; +//// } +////} + +verify.baselineSmartSelection(); diff --git a/tests/cases/fourslash/smartSelection_simple2.ts b/tests/cases/fourslash/smartSelection_simple2.ts new file mode 100644 index 00000000000..85d3252bca0 --- /dev/null +++ b/tests/cases/fourslash/smartSelection_simple2.ts @@ -0,0 +1,10 @@ +/// + +////export interface IService { +//// _serviceBrand: any; +//// +//// open(ho/*1*/st: number, data: any): Promise; +//// bar(): void/*2*/ +////} + +verify.baselineSmartSelection(); \ No newline at end of file diff --git a/tests/cases/fourslash/smartSelection_templateStrings.ts b/tests/cases/fourslash/smartSelection_templateStrings.ts new file mode 100644 index 00000000000..e3b311d20d9 --- /dev/null +++ b/tests/cases/fourslash/smartSelection_templateStrings.ts @@ -0,0 +1,7 @@ +/// + +////`a /*1*/b ${ +//// '/*2*/c' +////} d` + +verify.baselineSmartSelection(); \ No newline at end of file From 3e30a7c2ad44293111afbb0f86a4008d0848444e Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Tue, 23 Apr 2019 16:45:08 -0700 Subject: [PATCH 025/119] Remove all but one server unit test --- .../unittests/tsserver/smartSelection.ts | 669 +----------------- 1 file changed, 24 insertions(+), 645 deletions(-) diff --git a/src/testRunner/unittests/tsserver/smartSelection.ts b/src/testRunner/unittests/tsserver/smartSelection.ts index fca96ab848e..3c903d7da67 100644 --- a/src/testRunner/unittests/tsserver/smartSelection.ts +++ b/src/testRunner/unittests/tsserver/smartSelection.ts @@ -12,6 +12,7 @@ namespace ts.projectSystem { }; } + // More tests in fourslash/smartSelection_* describe("unittests:: tsserver:: smartSelection", () => { it("works for simple JavaScript", () => { const getSmartSelectionRange = setup("/file.js", ` @@ -25,663 +26,41 @@ class Foo { }`); const locations = getSmartSelectionRange([ - { - line: 4, - offset: 13, - }, { - line: 5, - offset: 22, - }, + { line: 4, offset: 13 }, // a === b ]); - // Common to results for both locations - const ifStatementUp: protocol.SelectionRange = { - textSpan: { // IfStatement - start: { line: 4, offset: 9 }, - end: { line: 6, offset: 10 } }, + assert.deepEqual(locations, [{ + textSpan: { // a + start: { line: 4, offset: 13 }, + end: { line: 4, offset: 14 } }, parent: { - textSpan: { // SyntaxList + whitespace (body of method) - start: { line: 3, offset: 16 }, - end: { line: 8, offset: 5 } }, - parent: { - textSpan: { // MethodDeclaration - start: { line: 3, offset: 5 }, - end: { line: 8, offset: 6 } }, - parent: { - textSpan: { // SyntaxList + whitespace (body of class) - start: { line: 2, offset: 12 }, - end: { line: 9, offset: 1 } }, - parent: { - textSpan: { // ClassDeclaration - start: { line: 2, offset: 1 }, - end: { line: 9, offset: 2 } }, - parent: { - textSpan: { // SourceFile (all text) - start: { line: 1, offset: 1 }, - end: { line: 9, offset: 2 }, } } } } } } }; - - assert.deepEqual(locations, [ - { - textSpan: { // a + textSpan: { // a === b start: { line: 4, offset: 13 }, - end: { line: 4, offset: 14 } }, + end: { line: 4, offset: 20 } }, parent: { - textSpan: { // a === b - start: { line: 4, offset: 13 }, - end: { line: 4, offset: 20 } }, - parent: ifStatementUp } }, - { - textSpan: { // true - start: { line: 5, offset: 20 }, - end: { line: 5, offset: 24 } }, - parent: { - textSpan: { // return true; - start: { line: 5, offset: 13 }, - end: { line: 5, offset: 25 } }, + textSpan: { // IfStatement + start: { line: 4, offset: 9 }, + end: { line: 6, offset: 10 } }, parent: { - textSpan: { // SyntaxList + whitespace (body of IfStatement) - start: { line: 4, offset: 23 }, - end: { line: 6, offset: 9 } }, - parent: ifStatementUp } } } - ]); - }); - - it("works for simple TypeScript", () => { - const getSmartSelectionRange = setup("/file.ts", ` -export interface IService { - _serviceBrand: any; - - open(host: number, data: any): Promise; - bar(): void -}`); - const locations = getSmartSelectionRange([ - { line: 5, offset: 12 }, // ho/**/st - { line: 6, offset: 16 }, // void/**/ - ]); - - assert.deepEqual(locations![0], { - textSpan: { // host - start: { line: 5, offset: 10 }, - end: { line: 5, offset: 14 } }, - parent: { - textSpan: { // host: number - start: { line: 5, offset: 10 }, - end: { line: 5, offset: 22 } }, - parent: { - textSpan: { // host: number, data: any - start: { line: 5, offset: 10 }, - end: { line: 5, offset: 33 } }, - parent: { - textSpan: { // open(host: number, data: any): Promise; - start: { line: 5, offset: 5 }, - end: { line: 5, offset: 49 } }, + textSpan: { // SyntaxList + whitespace (body of method) + start: { line: 3, offset: 16 }, + end: { line: 8, offset: 5 } }, parent: { - textSpan: { // SyntaxList + whitespace (body of interface) - start: { line: 2, offset: 28 }, - end: { line: 7, offset: 1 } }, + textSpan: { // MethodDeclaration + start: { line: 3, offset: 5 }, + end: { line: 8, offset: 6 } }, parent: { - textSpan: { // InterfaceDeclaration - start: { line: 2, offset: 1 }, - end: { line: 7, offset: 2 } }, + textSpan: { // SyntaxList + whitespace (body of class) + start: { line: 2, offset: 12 }, + end: { line: 9, offset: 1 } }, parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 7, offset: 2 } } } } } } } } }); - - // Ensures positions after a zero-width node work, because ts.positionBelongsToNode - // treats them strangely. - assert.deepEqual(locations![1].textSpan, { // void - start: { line: 6, offset: 12 }, - end: { line: 6, offset: 16 }}); - }); - - it("works for complex TypeScript", () => { - const getSmartSelectionRange = setup("/file.ts", ` -type X = IsExactlyAny

extends true ? T : ({ [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; } & Pick>) -`); - const locations = getSmartSelectionRange([ - { - line: 2, - offset: 133, - }, - ]); - - assert.deepEqual(locations, [ - { - textSpan: { // K - start: { line: 2, offset: 133 }, - end: { line: 2, offset: 134 } }, - parent: { - textSpan: { // P[K] - start: { line: 2, offset: 131 }, - end: { line: 2, offset: 135 } }, - parent: { - textSpan: { // K extends keyof T ? T[K] : P[K] - start: { line: 2, offset: 104 }, - end: { line: 2, offset: 135 } }, - parent: { - textSpan: { // IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K] - start: { line: 2, offset: 70 }, - end: { line: 2, offset: 142 } }, - parent: { - textSpan: { // [K in keyof P]: IsExactlyAny extends true ? K extends keyof T ? T[K] : P[K] : P[K]; - start: { line: 2, offset: 54 }, - end: { line: 2, offset: 143 } }, - parent: { - textSpan: { // MappedType: same as above + braces - start: { line: 2, offset: 52 }, - end: { line: 2, offset: 145 } }, - parent: { - textSpan: { // IntersectionType: { [K in keyof P]: ... } & Pick> - start: { line: 2, offset: 52 }, - end: { line: 2, offset: 182 } }, - parent: { - textSpan: { // same as above + parens - start: { line: 2, offset: 51 }, - end: { line: 2, offset: 183 } }, - parent: { - textSpan: { // Whole TypeNode of TypeAliasDeclaration - start: { line: 2, offset: 16 }, - end: { line: 2, offset: 183 } }, - parent: { - textSpan: { // Whole TypeAliasDeclaration - start: { line: 2, offset: 1 }, - end: { line: 2, offset: 183 } }, - parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 2, offset: 184 } } } } } } } } } } } } }, - ]); - }); - - it("works for object types", () => { - const getSmartSelectionRange = setup("/file.js", ` -type X = { - foo?: string; - readonly bar: { x: number }; - meh -}`); - const locations = getSmartSelectionRange([ - { line: 3, offset: 5 }, - { line: 4, offset: 5 }, - { line: 4, offset: 14 }, - { line: 4, offset: 27 }, - { line: 5, offset: 5 }, - ]); - - const allMembersUp: protocol.SelectionRange = { - textSpan: { // all members + whitespace (just inside braces) - start: { line: 2, offset: 11 }, - end: { line: 6, offset: 1 } }, - parent: { - textSpan: { // add braces - start: { line: 2, offset: 10 }, - end: { line: 6, offset: 2 } }, - parent: { - textSpan: { // whole TypeAliasDeclaration - start: { line: 2, offset: 1 }, - end: { line: 6, offset: 2 } }, - parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 6, offset: 2 } } } } } }; - - const readonlyBarUp: protocol.SelectionRange = { - textSpan: { // readonly bar - start: { line: 4, offset: 5 }, - end: { line: 4, offset: 17 } }, - parent: { - textSpan: { // readonly bar: { x: number }; - start: { line: 4, offset: 5 }, - end: { line: 4, offset: 33 } }, - parent: allMembersUp } }; - - assert.deepEqual(locations![0], { - textSpan: { // foo - start: { line: 3, offset: 5 }, - end: { line: 3, offset: 8 } }, - parent: { - textSpan: { // foo? - start: { line: 3, offset: 5 }, - end: { line: 3, offset: 9 } }, - parent: { - textSpan: { // foo?: string; - start: { line: 3, offset: 5 }, - end: { line: 3, offset: 18 } }, - parent: allMembersUp } } }); - - assert.deepEqual(locations![1], { - textSpan: { // readonly - start: { line: 4, offset: 5 }, - end: { line: 4, offset: 13 } }, - parent: readonlyBarUp }); - - assert.deepEqual(locations![2], { - textSpan: { // bar - start: { line: 4, offset: 14 }, - end: { line: 4, offset: 17 } }, - parent: readonlyBarUp }); - - assert.deepEqual(locations![3], { - textSpan: { // number - start: { line: 4, offset: 24 }, - end: { line: 4, offset: 30 } }, - parent: { - textSpan: { // x: number - start: { line: 4, offset: 21 }, - end: { line: 4, offset: 30 } }, - parent: { - textSpan: { // { x: number } - start: { line: 4, offset: 19 }, - end: { line: 4, offset: 32 } }, - parent: readonlyBarUp.parent } } }); - - assert.deepEqual(locations![4], { - textSpan: { // meh - start: { line: 5, offset: 5 }, - end: { line: 5, offset: 8 } }, - parent: allMembersUp }); - }); - - it("works for string literals and template strings", () => { - // tslint:disable-next-line:no-invalid-template-strings - const getSmartSelectionRange = setup("/file.ts", "`a b ${\n 'c'\n} d`"); - const locations = getSmartSelectionRange([ - { line: 2, offset: 4 }, - { line: 1, offset: 4 }, - ]); - assert.deepEqual(locations, [ - { - textSpan: { // c - start: { line: 2, offset: 4 }, - end: { line: 2, offset: 5 } }, - parent: { - textSpan: { // 'c' - start: { line: 2, offset: 3 }, - end: { line: 2, offset: 6 } }, - // parent: { - // textSpan: { // just inside braces - // start: { line: 1, offset: 8 }, - // end: { line: 3, offset: 1 } }, - parent: { - textSpan: { // whole TemplateSpan: ${ ... } - start: { line: 1, offset: 6 }, - end: { line: 3, offset: 2 } }, - parent: { - textSpan: { // whole template string without backticks - start: { line: 1, offset: 2 }, - end: { line: 3, offset: 4 } }, - parent: { - textSpan: { // whole template string - start: { line: 1, offset: 1 }, - end: { line: 3, offset: 5 } } } } } } }, - { - textSpan: { // whole template string without backticks - start: { line: 1, offset: 2 }, - end: { line: 3, offset: 4 } }, - parent: { - textSpan: { // whole template string - start: { line: 1, offset: 1 }, - end: { line: 3, offset: 5 } } } }, - ]); - }); - - it("works for ES2015 import lists", () => { - const getSmartSelectionRange = setup("/file.ts", ` -import { x as y, z } from './z'; -import { b } from './'; - -console.log(1);`); - - const locations = getSmartSelectionRange([{ line: 2, offset: 10 }]); - assert.deepEqual(locations, [ - { - textSpan: { // x - start: { line: 2, offset: 10 }, - end: { line: 2, offset: 11 } }, - parent: { - textSpan: { // x as y - start: { line: 2, offset: 10 }, - end: { line: 2, offset: 16 } }, - parent: { - textSpan: { // x as y, z - start: { line: 2, offset: 10 }, - end: { line: 2, offset: 19 } }, - parent: { - textSpan: { // { x as y, z } - start: { line: 2, offset: 8 }, - end: { line: 2, offset: 21 } }, - parent: { - textSpan: { // import { x as y, z } from './z'; - start: { line: 2, offset: 1 }, - end: { line: 2, offset: 33 } }, - parent: { - textSpan: { // all imports + textSpan: { // ClassDeclaration start: { line: 2, offset: 1 }, - end: { line: 3, offset: 24 } }, + end: { line: 9, offset: 2 } }, parent: { - textSpan: { // SourceFile + textSpan: { // SourceFile (all text) start: { line: 1, offset: 1 }, - end: { line: 5, offset: 16 } } } } } } } } } - ]); - }); - - it("works for complex mapped types", () => { - const getSmartSelectionRange = setup("/file.ts", ` -type M = { -readonly [K in keyof any]-?: any };`); - - const locations = getSmartSelectionRange([ - { line: 2, offset: 12 }, // -readonly - { line: 2, offset: 14 }, // eadonly - { line: 2, offset: 22 }, // [ - { line: 2, offset: 30 }, // yof any - { line: 2, offset: 38 }, // -? - { line: 2, offset: 39 }, // ? - ]); - - const leftOfColonUp: protocol.SelectionRange = { - textSpan: { // -readonly [K in keyof any]-? - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 40 } }, - parent: { - textSpan: { // -readonly [K in keyof any]-?: any - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 45 } }, - parent: { - textSpan: { // { -readonly [K in keyof any]-?: any } - start: { line: 2, offset: 10 }, - end: { line: 2, offset: 47 } }, - parent: { - textSpan: { // whole line - start: { line: 2, offset: 1 }, - end: { line: 2, offset: 48 } }, - parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 2, offset: 48 } } } } } } }; - - assert.deepEqual(locations![0], { - textSpan: { // - (in -readonly) - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 13 } }, - parent: { - textSpan: { // -readonly - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 21 } }, - parent: leftOfColonUp }, - }); - - assert.deepEqual(locations![1], { - textSpan: { // readonly - start: { line: 2, offset: 13 }, - end: { line: 2, offset: 21 } }, - parent: { - textSpan: { // -readonly - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 21 } }, - parent: leftOfColonUp }, - }); - - assert.deepEqual(locations![2], { - textSpan: { // [ - start: { line: 2, offset: 22 }, - end: { line: 2, offset: 23 } }, - parent: { - textSpan: { // [K in keyof any] - start: { line: 2, offset: 22 }, - end: { line: 2, offset: 38 } }, - parent: leftOfColonUp } - }); - - assert.deepEqual(locations![3], { - textSpan: { // keyof - start: { line: 2, offset: 28 }, - end: { line: 2, offset: 33 } }, - parent: { - textSpan: { // keyof any - start: { line: 2, offset: 28 }, - end: { line: 2, offset: 37 } }, - parent: { - textSpan: { // K in keyof any - start: { line: 2, offset: 23 }, - end: { line: 2, offset: 37 } }, - parent: { - textSpan: { // [K in keyof any] - start: { line: 2, offset: 22 }, - end: { line: 2, offset: 38 } }, - parent: leftOfColonUp } } }, - }); - - assert.deepEqual(locations![4], { - textSpan: { // - (in -?) - start: { line: 2, offset: 38 }, - end: { line: 2, offset: 39 } }, - parent: { - textSpan: { // -? - start: { line: 2, offset: 38 }, - end: { line: 2, offset: 40 } }, - parent: leftOfColonUp }, - }); - - assert.deepEqual(locations![5], { - textSpan: { // ? - start: { line: 2, offset: 39 }, - end: { line: 2, offset: 40 } }, - parent: { - textSpan: { // -? - start: { line: 2, offset: 38 }, - end: { line: 2, offset: 40 } }, - parent: leftOfColonUp }, - }); - }); - - it("works for parameters", () => { - const getSmartSelectionRange = setup("/file.ts", ` -function f(p, q?, ...r: any[] = []) {}`); - - const locations = getSmartSelectionRange([ - { line: 2, offset: 12 }, // p - { line: 2, offset: 15 }, // q - { line: 2, offset: 19 }, // ... - ]); - - const allParamsUp: protocol.SelectionRange = { - textSpan: { // just inside parens - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 35 } }, - parent: { - textSpan: { - start: { line: 2, offset: 1 }, - end: { line: 2, offset: 39 } }, - parent: { - textSpan: { - start: { line: 1, offset: 1 }, - end: { line: 2, offset: 39 } } } } }; - - assert.deepEqual(locations![0], { - textSpan: { // p - start: { line: 2, offset: 12 }, - end: { line: 2, offset: 13 } }, - parent: allParamsUp, - }); - - assert.deepEqual(locations![1], { - textSpan: { // q - start: { line: 2, offset: 15 }, - end: { line: 2, offset: 16 } }, - parent: { - textSpan: { // q? - start: { line: 2, offset: 15 }, - end: { line: 2, offset: 17 } }, - parent: allParamsUp }, - }); - - assert.deepEqual(locations![2], { - textSpan: { // ... - start: { line: 2, offset: 19 }, - end: { line: 2, offset: 22 } }, - parent: { - textSpan: { // ...r - start: { line: 2, offset: 19 }, - end: { line: 2, offset: 23 } }, - parent: { - textSpan: { // ...r: any[] - start: { line: 2, offset: 19 }, - end: { line: 2, offset: 30 } }, - parent: { - textSpan: { // ...r: any[] = [] - start: { line: 2, offset: 19 }, - end: { line: 2, offset: 35 } }, - parent: allParamsUp } } }, - }); - }); - - it("works for binding elements", () => { - const getSmartSelectionRange = setup("/file.ts", ` -const { x, y: a, ...zs = {} } = {};`); - const locations = getSmartSelectionRange([ - { line: 2, offset: 9 }, // x - { line: 2, offset: 15 }, // a - { line: 2, offset: 21 }, // zs - ]); - - // Don’t care about checking first two locations, because - // they’re pretty boring, just want to make sure they don’t cause a crash - assert.deepEqual(locations![2], { - textSpan: { // zs - start: { line: 2, offset: 21 }, - end: { line: 2, offset: 23 } }, - parent: { - textSpan: { // ...zs - start: { line: 2, offset: 18 }, - end: { line: 2, offset: 23 } }, - parent: { - textSpan: { // ...zs = {} - start: { line: 2, offset: 18 }, - end: { line: 2, offset: 28 } }, - parent: { - textSpan: { // x, y: a, ...zs = {} - start: { line: 2, offset: 9 }, - end: { line: 2, offset: 28 } }, - parent: { - textSpan: { // { x, y: a, ...zs = {} } - start: { line: 2, offset: 7 }, - end: { line: 2, offset: 30 } }, - parent: { - textSpan: { // whole line - start: { line: 2, offset: 1 }, - end: { line: 2, offset: 36 } }, - parent: { - textSpan: { - start: { line: 1, offset: 1 }, - end: { line: 2, offset: 36 } } } } } } } } }); - }); - - it("consumes all whitespace in a multi-line function parameter list", () => { - const getSmartSelectionRange = setup("/file.ts", ` -function f( - a, - b -) {}`); - const locations = getSmartSelectionRange([{ line: 4, offset: 5 }]); // b - assert.deepEqual(locations, [{ - textSpan: { // b - start: { line: 4, offset: 5 }, - end: { line: 4, offset: 6 } }, - parent: { // all params and whitespace inside parens - textSpan: { - start: { line: 2, offset: 12 }, - end: { line: 5, offset: 1 } }, - parent: { - textSpan: { // whole function declaration - start: { line: 2, offset: 1 }, - end: { line: 5, offset: 5 } }, - parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 5, offset: 5 } } } } } - }]); - }); - - it("snaps to nodes directly behind the cursor instead of trivia ahead of the cursor", () => { - const getSmartSelectionRange = setup("/file.ts", `let x: string`); - const locations = getSmartSelectionRange([{ line: 1, offset: 4 }]); - assert.deepEqual(locations![0].textSpan, { - start: { line: 1, offset: 1 }, - end: { line: 1, offset: 4 }, - }); - }); - - it("creates a stop for JSDoc ranges", () => { - const getSmartSelectionRange = setup("/file.js", "" + -`// Not a JSDoc comment -/** - * @param {number} x The number to square - */ -function square(x) { - return x * x; -}`); - const locations = getSmartSelectionRange([{ line: 5, offset: 10 }]); // square(x) - assert.deepEqual(locations, [{ - textSpan: { // square - start: { line: 5 , offset: 10 }, - end: { line: 5, offset: 16 } }, - parent: { // whole function declaration - textSpan: { - start: { line: 5, offset: 1 }, - end: { line: 7, offset: 2 } }, - parent: { - textSpan: { // add JSDoc - start: { line: 2, offset: 1 }, - end: { line: 7, offset: 2 } }, - parent: { - textSpan: { // SourceFile - start: { line: 1, offset: 1 }, - end: { line: 7, offset: 2 } } } } } }]); - }); - - it("skips lone VariableDeclarations in a declaration list", () => { - const getSmartSelectionRange = setup("/file.ts", `const x = 3;`); - const locations = getSmartSelectionRange([{ line: 1, offset: 7 }]); // x - assert.deepEqual(locations, [{ - textSpan: { - start: { line: 1, offset: 7 }, - end: { line: 1, offset: 8 } }, - parent: { - textSpan: { - start: { line: 1, offset: 1 }, - end: { line: 1, offset: 13 } } } }]); - }); - - it("never returns empty ranges", () => { - const getSmartSelectionRange = setup("/file.ts", ` -class HomePage { - componentDidMount() { - if (this.props.username) { - return ''; - } - } -}`); - const locations = getSmartSelectionRange([ - { line: 3, offset: 23 }, // componentDidMount(/**/) - { line: 4, offset: 32 }, // username/**/) - { line: 5, offset: 21 }, // return '/**/' - ]); - - assert.deepEqual(locations![0].textSpan, { // this.props.username - start: { line: 3, offset: 23 }, - end: { line: 3, offset: 24 }, - }); - - assert.deepEqual(locations![1].textSpan, { // this.props.username - start: { line: 4, offset: 32 }, - end: { line: 4, offset: 33 }, - }); - - assert.deepEqual(locations![2].textSpan, { // '' - start: { line: 5, offset: 20 }, - end: { line: 5, offset: 22 }, - }); + end: { line: 9, offset: 2 }, } } } } } } } } }]); }); }); } From eff39600207df4817b3dceb7848bf858c86f4ca3 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Wed, 24 Apr 2019 08:52:07 -0700 Subject: [PATCH 026/119] Fix baseline file name changes --- src/harness/fourslash.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/harness/fourslash.ts b/src/harness/fourslash.ts index 66ea1ba38c4..0dea2b1e7b0 100644 --- a/src/harness/fourslash.ts +++ b/src/harness/fourslash.ts @@ -1417,7 +1417,7 @@ Actual: ${stringify(fullActual)}`); } public baselineCurrentFileBreakpointLocations() { - const baselineFile = this.getBaselineFileName().replace(this.basePath + "/breakpointValidation", "bpSpan"); + const baselineFile = this.getBaselineFileName().replace("breakpointValidation", "bpSpan"); Harness.Baseline.runBaseline(baselineFile, this.baselineCurrentFileLocations(pos => this.getBreakpointStatementLocation(pos)!)); } From 60962a8709f0ef3587f489e15071b07ef3cec9a9 Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Wed, 1 May 2019 13:57:47 -0700 Subject: [PATCH 027/119] Added test. --- .../compiler/omitTypeHelperModifiers01.ts | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 tests/cases/compiler/omitTypeHelperModifiers01.ts diff --git a/tests/cases/compiler/omitTypeHelperModifiers01.ts b/tests/cases/compiler/omitTypeHelperModifiers01.ts new file mode 100644 index 00000000000..da76173d365 --- /dev/null +++ b/tests/cases/compiler/omitTypeHelperModifiers01.ts @@ -0,0 +1,22 @@ +// @strict: true + +type A = { + a: number; + b?: string; + readonly c: boolean; + d: unknown; +}; + +type B = Omit; + +function f(x: B) { + const b = x.b; + x.b = "hello"; + x.b = undefined; + + const c = x.c; + x.c = true; + + const d = x.d; + x.d = d; +} From d22cb0c56bbacee5fa07af60b02284806937527b Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Wed, 1 May 2019 13:57:53 -0700 Subject: [PATCH 028/119] Accepted baselines. --- .../reference/omitTypeHelperModifiers01.js | 34 +++++++++ .../omitTypeHelperModifiers01.symbols | 69 ++++++++++++++++++ .../reference/omitTypeHelperModifiers01.types | 72 +++++++++++++++++++ 3 files changed, 175 insertions(+) create mode 100644 tests/baselines/reference/omitTypeHelperModifiers01.js create mode 100644 tests/baselines/reference/omitTypeHelperModifiers01.symbols create mode 100644 tests/baselines/reference/omitTypeHelperModifiers01.types diff --git a/tests/baselines/reference/omitTypeHelperModifiers01.js b/tests/baselines/reference/omitTypeHelperModifiers01.js new file mode 100644 index 00000000000..4ddfbf0c682 --- /dev/null +++ b/tests/baselines/reference/omitTypeHelperModifiers01.js @@ -0,0 +1,34 @@ +//// [omitTypeHelperModifiers01.ts] +type A = { + a: number; + b?: string; + readonly c: boolean; + d: unknown; +}; + +type B = Omit; + +function f(x: B) { + const b = x.b; + x.b = "hello"; + x.b = undefined; + + const c = x.c; + x.c = true; + + const d = x.d; + x.d = d; +} + + +//// [omitTypeHelperModifiers01.js] +"use strict"; +function f(x) { + var b = x.b; + x.b = "hello"; + x.b = undefined; + var c = x.c; + x.c = true; + var d = x.d; + x.d = d; +} diff --git a/tests/baselines/reference/omitTypeHelperModifiers01.symbols b/tests/baselines/reference/omitTypeHelperModifiers01.symbols new file mode 100644 index 00000000000..a5cc8be34f3 --- /dev/null +++ b/tests/baselines/reference/omitTypeHelperModifiers01.symbols @@ -0,0 +1,69 @@ +=== tests/cases/compiler/omitTypeHelperModifiers01.ts === +type A = { +>A : Symbol(A, Decl(omitTypeHelperModifiers01.ts, 0, 0)) + + a: number; +>a : Symbol(a, Decl(omitTypeHelperModifiers01.ts, 0, 10)) + + b?: string; +>b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 1, 14)) + + readonly c: boolean; +>c : Symbol(c, Decl(omitTypeHelperModifiers01.ts, 2, 15)) + + d: unknown; +>d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 3, 24)) + +}; + +type B = Omit; +>B : Symbol(B, Decl(omitTypeHelperModifiers01.ts, 5, 2)) +>Omit : Symbol(Omit, Decl(lib.es5.d.ts, --, --)) +>A : Symbol(A, Decl(omitTypeHelperModifiers01.ts, 0, 0)) + +function f(x: B) { +>f : Symbol(f, Decl(omitTypeHelperModifiers01.ts, 7, 22)) +>x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) +>B : Symbol(B, Decl(omitTypeHelperModifiers01.ts, 5, 2)) + + const b = x.b; +>b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 10, 9)) +>x.b : Symbol(b) +>x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) +>b : Symbol(b) + + x.b = "hello"; +>x.b : Symbol(b) +>x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) +>b : Symbol(b) + + x.b = undefined; +>x.b : Symbol(b) +>x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) +>b : Symbol(b) +>undefined : Symbol(undefined) + + const c = x.c; +>c : Symbol(c, Decl(omitTypeHelperModifiers01.ts, 14, 9)) +>x.c : Symbol(c) +>x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) +>c : Symbol(c) + + x.c = true; +>x.c : Symbol(c) +>x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) +>c : Symbol(c) + + const d = x.d; +>d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 17, 9)) +>x.d : Symbol(d) +>x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) +>d : Symbol(d) + + x.d = d; +>x.d : Symbol(d) +>x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) +>d : Symbol(d) +>d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 17, 9)) +} + diff --git a/tests/baselines/reference/omitTypeHelperModifiers01.types b/tests/baselines/reference/omitTypeHelperModifiers01.types new file mode 100644 index 00000000000..1053648d6da --- /dev/null +++ b/tests/baselines/reference/omitTypeHelperModifiers01.types @@ -0,0 +1,72 @@ +=== tests/cases/compiler/omitTypeHelperModifiers01.ts === +type A = { +>A : A + + a: number; +>a : number + + b?: string; +>b : string | undefined + + readonly c: boolean; +>c : boolean + + d: unknown; +>d : unknown + +}; + +type B = Omit; +>B : Omit + +function f(x: B) { +>f : (x: Omit) => void +>x : Omit + + const b = x.b; +>b : string | undefined +>x.b : string | undefined +>x : Omit +>b : string | undefined + + x.b = "hello"; +>x.b = "hello" : "hello" +>x.b : string | undefined +>x : Omit +>b : string | undefined +>"hello" : "hello" + + x.b = undefined; +>x.b = undefined : undefined +>x.b : string | undefined +>x : Omit +>b : string | undefined +>undefined : undefined + + const c = x.c; +>c : boolean +>x.c : boolean +>x : Omit +>c : boolean + + x.c = true; +>x.c = true : true +>x.c : boolean +>x : Omit +>c : boolean +>true : true + + const d = x.d; +>d : unknown +>x.d : unknown +>x : Omit +>d : unknown + + x.d = d; +>x.d = d : unknown +>x.d : unknown +>x : Omit +>d : unknown +>d : unknown +} + From d9e82466e28412a22268f54897a50e9caef13594 Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Wed, 1 May 2019 14:00:11 -0700 Subject: [PATCH 029/119] Change `Omit` back to using `Pick>` in order to maintain modifiers. --- src/lib/es5.d.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/lib/es5.d.ts b/src/lib/es5.d.ts index 827c2aaddd5..f2be6716c72 100644 --- a/src/lib/es5.d.ts +++ b/src/lib/es5.d.ts @@ -1446,9 +1446,7 @@ type Extract = T extends U ? T : never; /** * Construct a type with the properties of T except for those in type K. */ -type Omit = { - [P in Exclude]: T[P] -}; +type Omit = Pick>; /** * Exclude null and undefined from T From d7434a01b248641907c1aed4ed97cf539adcd242 Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Wed, 1 May 2019 16:07:29 -0700 Subject: [PATCH 030/119] Accepted baselines. --- .../reference/genericIsNeverEmptyObject.types | 12 ++++---- .../reference/genericObjectRest.types | 16 +++++------ .../reference/literalTypeWidening.types | 6 ++-- .../reference/mappedTypeConstraints.symbols | 4 +-- .../reference/mappedTypeConstraints.types | 4 +-- .../reference/objectRestNegative.types | 6 ++-- .../omitTypeHelperModifiers01.errors.txt | 27 ++++++++++++++++++ .../omitTypeHelperModifiers01.symbols | 28 +++++++++---------- .../reference/omitTypeHelperModifiers01.types | 24 ++++++++-------- .../reference/omitTypeTestErrors01.errors.txt | 8 +++--- .../reference/omitTypeTestErrors01.types | 16 +++++------ .../reference/omitTypeTests01.symbols | 8 +++--- .../baselines/reference/omitTypeTests01.types | 16 +++++------ 13 files changed, 101 insertions(+), 74 deletions(-) create mode 100644 tests/baselines/reference/omitTypeHelperModifiers01.errors.txt diff --git a/tests/baselines/reference/genericIsNeverEmptyObject.types b/tests/baselines/reference/genericIsNeverEmptyObject.types index 3a49e723e76..5d2b4d9d57f 100644 --- a/tests/baselines/reference/genericIsNeverEmptyObject.types +++ b/tests/baselines/reference/genericIsNeverEmptyObject.types @@ -2,18 +2,18 @@ // Repro from #29067 function test(obj: T) { ->test : (obj: T) => Omit & { b: string; } +>test : (obj: T) => Pick> & { b: string; } >a : string >obj : T let { a, ...rest } = obj; >a : string ->rest : Omit +>rest : Pick> >obj : T return { ...rest, b: a }; ->{ ...rest, b: a } : Omit & { b: string; } ->rest : Omit +>{ ...rest, b: a } : Pick> & { b: string; } +>rest : Pick> >b : string >a : string } @@ -30,7 +30,7 @@ let o2: { b: string, x: number } = test(o1); >o2 : { b: string; x: number; } >b : string >x : number ->test(o1) : Omit<{ a: string; x: number; }, "a"> & { b: string; } ->test : (obj: T) => Omit & { b: string; } +>test(o1) : Pick<{ a: string; x: number; }, "x"> & { b: string; } +>test : (obj: T) => Pick> & { b: string; } >o1 : { a: string; x: number; } diff --git a/tests/baselines/reference/genericObjectRest.types b/tests/baselines/reference/genericObjectRest.types index ba5145dccba..c2fcaad7cb8 100644 --- a/tests/baselines/reference/genericObjectRest.types +++ b/tests/baselines/reference/genericObjectRest.types @@ -16,7 +16,7 @@ function f1(obj: T) { let { a: a1, ...r1 } = obj; >a : any >a1 : string ->r1 : Omit +>r1 : Pick> >obj : T let { a: a2, b: b2, ...r2 } = obj; @@ -24,24 +24,24 @@ function f1(obj: T) { >a2 : string >b : any >b2 : number ->r2 : Omit +>r2 : Pick> >obj : T let { 'a': a3, ...r3 } = obj; >a3 : string ->r3 : Omit +>r3 : Pick> >obj : T let { ['a']: a4, ...r4 } = obj; >'a' : "a" >a4 : string ->r4 : Omit +>r4 : Pick> >obj : T let { [a]: a5, ...r5 } = obj; >a : "a" >a5 : string ->r5 : Omit +>r5 : Pick> >obj : T } @@ -68,7 +68,7 @@ function f2(obj: T) { >a1 : string >sb : unique symbol >b1 : number ->r1 : Omit +>r1 : Pick> >obj : T } @@ -83,7 +83,7 @@ function f3(obj: T, k1: K1, k2: K2) { >a1 : T[K1] >k2 : K2 >a2 : T[K2] ->r1 : Omit +>r1 : Pick> >obj : T } @@ -104,7 +104,7 @@ function f4(obj: Item, k1: K1, k2: >a1 : Item[K1] >k2 : K2 >a2 : Item[K2] ->r1 : Omit +>r1 : Pick | Exclude<"b", K1 | K2> | Exclude<"c", K1 | K2>> >obj : Item } diff --git a/tests/baselines/reference/literalTypeWidening.types b/tests/baselines/reference/literalTypeWidening.types index 81db0bfc36f..95bde9a08ac 100644 --- a/tests/baselines/reference/literalTypeWidening.types +++ b/tests/baselines/reference/literalTypeWidening.types @@ -443,14 +443,14 @@ function test(obj: T): T { let { a, ...rest } = obj; >a : string ->rest : Omit +>rest : Pick> >obj : T return { a: 'hello', ...rest } as T; >{ a: 'hello', ...rest } as T : T ->{ a: 'hello', ...rest } : { a: string; } & Omit +>{ a: 'hello', ...rest } : { a: string; } & Pick> >a : string >'hello' : "hello" ->rest : Omit +>rest : Pick> } diff --git a/tests/baselines/reference/mappedTypeConstraints.symbols b/tests/baselines/reference/mappedTypeConstraints.symbols index 4a793fd0dc3..3601ffc3de8 100644 --- a/tests/baselines/reference/mappedTypeConstraints.symbols +++ b/tests/baselines/reference/mappedTypeConstraints.symbols @@ -132,9 +132,9 @@ const modifier = (targetProps: T) => { >targetProps : Symbol(targetProps, Decl(mappedTypeConstraints.ts, 30, 41)) rest.foo; ->rest.foo : Symbol(foo) +>rest.foo : Symbol(foo, Decl(mappedTypeConstraints.ts, 25, 20)) >rest : Symbol(rest, Decl(mappedTypeConstraints.ts, 31, 13)) ->foo : Symbol(foo) +>foo : Symbol(foo, Decl(mappedTypeConstraints.ts, 25, 20)) }; diff --git a/tests/baselines/reference/mappedTypeConstraints.types b/tests/baselines/reference/mappedTypeConstraints.types index 98ae325e6be..3e42e2a2e98 100644 --- a/tests/baselines/reference/mappedTypeConstraints.types +++ b/tests/baselines/reference/mappedTypeConstraints.types @@ -98,12 +98,12 @@ const modifier = (targetProps: T) => { let {bar, ...rest} = targetProps; >bar : string ->rest : Omit +>rest : Pick> >targetProps : T rest.foo; >rest.foo : T["foo"] ->rest : Omit +>rest : Pick> >foo : T["foo"] }; diff --git a/tests/baselines/reference/objectRestNegative.types b/tests/baselines/reference/objectRestNegative.types index 7cc174299e4..58ed1902f6d 100644 --- a/tests/baselines/reference/objectRestNegative.types +++ b/tests/baselines/reference/objectRestNegative.types @@ -36,18 +36,18 @@ function stillMustBeLast({ ...mustBeLast, a }: { a: number, b: string }): void { >b : string } function generic(t: T) { ->generic : (t: T) => Omit +>generic : (t: T) => Pick> >x : any >y : any >t : T let { x, ...rest } = t; >x : any ->rest : Omit +>rest : Pick> >t : T return rest; ->rest : Omit +>rest : Pick> } let rest: { b: string } diff --git a/tests/baselines/reference/omitTypeHelperModifiers01.errors.txt b/tests/baselines/reference/omitTypeHelperModifiers01.errors.txt new file mode 100644 index 00000000000..e175a537032 --- /dev/null +++ b/tests/baselines/reference/omitTypeHelperModifiers01.errors.txt @@ -0,0 +1,27 @@ +tests/cases/compiler/omitTypeHelperModifiers01.ts(16,7): error TS2540: Cannot assign to 'c' because it is a read-only property. + + +==== tests/cases/compiler/omitTypeHelperModifiers01.ts (1 errors) ==== + type A = { + a: number; + b?: string; + readonly c: boolean; + d: unknown; + }; + + type B = Omit; + + function f(x: B) { + const b = x.b; + x.b = "hello"; + x.b = undefined; + + const c = x.c; + x.c = true; + ~ +!!! error TS2540: Cannot assign to 'c' because it is a read-only property. + + const d = x.d; + x.d = d; + } + \ No newline at end of file diff --git a/tests/baselines/reference/omitTypeHelperModifiers01.symbols b/tests/baselines/reference/omitTypeHelperModifiers01.symbols index a5cc8be34f3..39a33606781 100644 --- a/tests/baselines/reference/omitTypeHelperModifiers01.symbols +++ b/tests/baselines/reference/omitTypeHelperModifiers01.symbols @@ -28,42 +28,42 @@ function f(x: B) { const b = x.b; >b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 10, 9)) ->x.b : Symbol(b) +>x.b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 1, 14)) >x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) ->b : Symbol(b) +>b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 1, 14)) x.b = "hello"; ->x.b : Symbol(b) +>x.b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 1, 14)) >x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) ->b : Symbol(b) +>b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 1, 14)) x.b = undefined; ->x.b : Symbol(b) +>x.b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 1, 14)) >x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) ->b : Symbol(b) +>b : Symbol(b, Decl(omitTypeHelperModifiers01.ts, 1, 14)) >undefined : Symbol(undefined) const c = x.c; >c : Symbol(c, Decl(omitTypeHelperModifiers01.ts, 14, 9)) ->x.c : Symbol(c) +>x.c : Symbol(c, Decl(omitTypeHelperModifiers01.ts, 2, 15)) >x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) ->c : Symbol(c) +>c : Symbol(c, Decl(omitTypeHelperModifiers01.ts, 2, 15)) x.c = true; ->x.c : Symbol(c) +>x.c : Symbol(c, Decl(omitTypeHelperModifiers01.ts, 2, 15)) >x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) ->c : Symbol(c) +>c : Symbol(c, Decl(omitTypeHelperModifiers01.ts, 2, 15)) const d = x.d; >d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 17, 9)) ->x.d : Symbol(d) +>x.d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 3, 24)) >x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) ->d : Symbol(d) +>d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 3, 24)) x.d = d; ->x.d : Symbol(d) +>x.d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 3, 24)) >x : Symbol(x, Decl(omitTypeHelperModifiers01.ts, 9, 11)) ->d : Symbol(d) +>d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 3, 24)) >d : Symbol(d, Decl(omitTypeHelperModifiers01.ts, 17, 9)) } diff --git a/tests/baselines/reference/omitTypeHelperModifiers01.types b/tests/baselines/reference/omitTypeHelperModifiers01.types index 1053648d6da..da5f61b6986 100644 --- a/tests/baselines/reference/omitTypeHelperModifiers01.types +++ b/tests/baselines/reference/omitTypeHelperModifiers01.types @@ -17,55 +17,55 @@ type A = { }; type B = Omit; ->B : Omit +>B : Pick function f(x: B) { ->f : (x: Omit) => void ->x : Omit +>f : (x: Pick) => void +>x : Pick const b = x.b; >b : string | undefined >x.b : string | undefined ->x : Omit +>x : Pick >b : string | undefined x.b = "hello"; >x.b = "hello" : "hello" >x.b : string | undefined ->x : Omit +>x : Pick >b : string | undefined >"hello" : "hello" x.b = undefined; >x.b = undefined : undefined >x.b : string | undefined ->x : Omit +>x : Pick >b : string | undefined >undefined : undefined const c = x.c; >c : boolean >x.c : boolean ->x : Omit +>x : Pick >c : boolean x.c = true; >x.c = true : true ->x.c : boolean ->x : Omit ->c : boolean +>x.c : any +>x : Pick +>c : any >true : true const d = x.d; >d : unknown >x.d : unknown ->x : Omit +>x : Pick >d : unknown x.d = d; >x.d = d : unknown >x.d : unknown ->x : Omit +>x : Pick >d : unknown >d : unknown } diff --git a/tests/baselines/reference/omitTypeTestErrors01.errors.txt b/tests/baselines/reference/omitTypeTestErrors01.errors.txt index 6b65e292b55..a66ab384b89 100644 --- a/tests/baselines/reference/omitTypeTestErrors01.errors.txt +++ b/tests/baselines/reference/omitTypeTestErrors01.errors.txt @@ -1,5 +1,5 @@ -tests/cases/compiler/omitTypeTestErrors01.ts(11,16): error TS2339: Property 'c' does not exist on type 'Omit'. -tests/cases/compiler/omitTypeTestErrors01.ts(15,16): error TS2339: Property 'b' does not exist on type 'Omit'. +tests/cases/compiler/omitTypeTestErrors01.ts(11,16): error TS2339: Property 'c' does not exist on type 'Pick'. +tests/cases/compiler/omitTypeTestErrors01.ts(15,16): error TS2339: Property 'b' does not exist on type 'Pick'. ==== tests/cases/compiler/omitTypeTestErrors01.ts (2 errors) ==== @@ -15,13 +15,13 @@ tests/cases/compiler/omitTypeTestErrors01.ts(15,16): error TS2339: Property 'b' export function getBarC(bar: Bar) { return bar.c; ~ -!!! error TS2339: Property 'c' does not exist on type 'Omit'. +!!! error TS2339: Property 'c' does not exist on type 'Pick'. } export function getBazB(baz: Baz) { return baz.b; ~ -!!! error TS2339: Property 'b' does not exist on type 'Omit'. +!!! error TS2339: Property 'b' does not exist on type 'Pick'. } \ No newline at end of file diff --git a/tests/baselines/reference/omitTypeTestErrors01.types b/tests/baselines/reference/omitTypeTestErrors01.types index 4b286c2c89c..e7282016868 100644 --- a/tests/baselines/reference/omitTypeTestErrors01.types +++ b/tests/baselines/reference/omitTypeTestErrors01.types @@ -11,28 +11,28 @@ interface Foo { } export type Bar = Omit; ->Bar : Omit +>Bar : Pick export type Baz = Omit; ->Baz : Omit +>Baz : Pick export function getBarC(bar: Bar) { ->getBarC : (bar: Omit) => any ->bar : Omit +>getBarC : (bar: Pick) => any +>bar : Pick return bar.c; >bar.c : any ->bar : Omit +>bar : Pick >c : any } export function getBazB(baz: Baz) { ->getBazB : (baz: Omit) => any ->baz : Omit +>getBazB : (baz: Pick) => any +>baz : Pick return baz.b; >baz.b : any ->baz : Omit +>baz : Pick >b : any } diff --git a/tests/baselines/reference/omitTypeTests01.symbols b/tests/baselines/reference/omitTypeTests01.symbols index 93b49291785..d614f65daff 100644 --- a/tests/baselines/reference/omitTypeTests01.symbols +++ b/tests/baselines/reference/omitTypeTests01.symbols @@ -28,9 +28,9 @@ export function getBarA(bar: Bar) { >Bar : Symbol(Bar, Decl(omitTypeTests01.ts, 4, 1)) return bar.a; ->bar.a : Symbol(a) +>bar.a : Symbol(a, Decl(omitTypeTests01.ts, 0, 15)) >bar : Symbol(bar, Decl(omitTypeTests01.ts, 9, 24)) ->a : Symbol(a) +>a : Symbol(a, Decl(omitTypeTests01.ts, 0, 15)) } export function getBazA(baz: Baz) { @@ -39,9 +39,9 @@ export function getBazA(baz: Baz) { >Baz : Symbol(Baz, Decl(omitTypeTests01.ts, 6, 33)) return baz.a; ->baz.a : Symbol(a) +>baz.a : Symbol(a, Decl(omitTypeTests01.ts, 0, 15)) >baz : Symbol(baz, Decl(omitTypeTests01.ts, 13, 24)) ->a : Symbol(a) +>a : Symbol(a, Decl(omitTypeTests01.ts, 0, 15)) } diff --git a/tests/baselines/reference/omitTypeTests01.types b/tests/baselines/reference/omitTypeTests01.types index 549fcccc0f2..c07894ee2dc 100644 --- a/tests/baselines/reference/omitTypeTests01.types +++ b/tests/baselines/reference/omitTypeTests01.types @@ -11,28 +11,28 @@ interface Foo { } export type Bar = Omit; ->Bar : Omit +>Bar : Pick export type Baz = Omit; ->Baz : Omit +>Baz : Pick export function getBarA(bar: Bar) { ->getBarA : (bar: Omit) => string ->bar : Omit +>getBarA : (bar: Pick) => string +>bar : Pick return bar.a; >bar.a : string ->bar : Omit +>bar : Pick >a : string } export function getBazA(baz: Baz) { ->getBazA : (baz: Omit) => string ->baz : Omit +>getBazA : (baz: Pick) => string +>baz : Pick return baz.a; >baz.a : string ->baz : Omit +>baz : Pick >a : string } From 8891d4f375e86ec897f1fad219d4d3804da2c7f6 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 2 May 2019 15:15:03 -0700 Subject: [PATCH 031/119] Permit reverse mapped types to be created from partially inferable types --- src/compiler/checker.ts | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index f9c87e94961..61607e9c904 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -14887,10 +14887,22 @@ namespace ts { return type; } + // We consider a type to be partially inferable if it isn't marked non-inferable or if it is + // an object literal type with at least one property of an inferable type. For example, an object + // literal { a: 123, b: x => true } is marked non-inferable because it contains a context sensitive + // arrow function, but is considered partially inferable because property 'a' has an inferable type. + function isPartiallyInferableType(type: Type): boolean { + return !(getObjectFlags(type) & ObjectFlags.NonInferrableType) || + isObjectLiteralType(type) && some(getPropertiesOfType(type), prop => isPartiallyInferableType(getTypeOfSymbol(prop))); + } + function createReverseMappedType(source: Type, target: MappedType, constraint: IndexType) { - // If any property contains context sensitive functions that have been skipped, the source type - // is incomplete and we can't infer a meaningful input type. - if (getObjectFlags(source) & ObjectFlags.NonInferrableType || getPropertiesOfType(source).length === 0 && !getIndexInfoOfType(source, IndexKind.String)) { + // We consider a source type reverse mappable if it has a string index signature or if + // it has one or more properties and all properties have inferable types. + const properties = getPropertiesOfType(source); + const isReverseMappable = getIndexInfoOfType(source, IndexKind.String) || + properties.length !== 0 && every(properties, prop => isPartiallyInferableType(getTypeOfSymbol(prop))); + if (!isReverseMappable) { return undefined; } // For arrays and tuples we infer new arrays and tuples where the reverse mapping has been From f73308b248d99a30a741314e2a8e5aba9415e311 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 2 May 2019 15:24:56 -0700 Subject: [PATCH 032/119] Add tests --- .../reverseMappedPartiallyInferableTypes.ts | 96 +++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 tests/cases/compiler/reverseMappedPartiallyInferableTypes.ts diff --git a/tests/cases/compiler/reverseMappedPartiallyInferableTypes.ts b/tests/cases/compiler/reverseMappedPartiallyInferableTypes.ts new file mode 100644 index 00000000000..799ff641c5a --- /dev/null +++ b/tests/cases/compiler/reverseMappedPartiallyInferableTypes.ts @@ -0,0 +1,96 @@ +// @strict: true + +// Repro from #30505 + +export type Prop = { (): T } +export type PropType = Prop; +export type PropDefaultValue = T; + + +export type PropValidatorFunction = (value: T) => boolean; +export type PropValidator = PropOptions; + + +export type PropOptions = { + type: PropType; + + value?: PropDefaultValue, + required?: boolean; + validator?: PropValidatorFunction; +} + +export type RecordPropsDefinition = { + [K in keyof T]: PropValidator +} +export type PropsDefinition = RecordPropsDefinition; + + +declare function extend({ props }: { props: PropsDefinition }): PropsDefinition; + +interface MyType { + valid: boolean; +} + +const r = extend({ + props: { + notResolved: { + type: Object as PropType, + validator: x => { + return x.valid; + } + }, + explicit: { + type: Object as PropType, + validator: (x: MyType) => { + return x.valid; + } + } + } +}) + +r.explicit +r.notResolved +r.explicit.required +r.notResolved.required + +// Modified repro from #30505 + +type Box = { + contents?: T; + contains?(content: T): boolean; +}; + +type Mapped = { + [K in keyof T]: Box; +} + +declare function id(arg: Mapped): Mapped; + +// All properties have inferable types + +const obj1 = id({ + foo: { + contents: "" + } +}); + +// Some properties have inferable types + +const obj2 = id({ + foo: { + contents: "", + contains(k) { + return k.length > 0; + } + } +}); + +// No properties have inferable types + +const obj3 = id({ + foo: { + contains(k) { + return k.length > 0; + } + } +}); From 6aaeb52c9235b23324ff8a5fd46555e991d3897a Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 2 May 2019 15:25:05 -0700 Subject: [PATCH 033/119] Accept new baselines --- ...seMappedPartiallyInferableTypes.errors.txt | 101 +++++++ .../reverseMappedPartiallyInferableTypes.js | 144 ++++++++++ ...verseMappedPartiallyInferableTypes.symbols | 259 ++++++++++++++++++ ...reverseMappedPartiallyInferableTypes.types | 231 ++++++++++++++++ 4 files changed, 735 insertions(+) create mode 100644 tests/baselines/reference/reverseMappedPartiallyInferableTypes.errors.txt create mode 100644 tests/baselines/reference/reverseMappedPartiallyInferableTypes.js create mode 100644 tests/baselines/reference/reverseMappedPartiallyInferableTypes.symbols create mode 100644 tests/baselines/reference/reverseMappedPartiallyInferableTypes.types diff --git a/tests/baselines/reference/reverseMappedPartiallyInferableTypes.errors.txt b/tests/baselines/reference/reverseMappedPartiallyInferableTypes.errors.txt new file mode 100644 index 00000000000..63ea9a9f279 --- /dev/null +++ b/tests/baselines/reference/reverseMappedPartiallyInferableTypes.errors.txt @@ -0,0 +1,101 @@ +tests/cases/compiler/reverseMappedPartiallyInferableTypes.ts(91,20): error TS2571: Object is of type 'unknown'. + + +==== tests/cases/compiler/reverseMappedPartiallyInferableTypes.ts (1 errors) ==== + // Repro from #30505 + + export type Prop = { (): T } + export type PropType = Prop; + export type PropDefaultValue = T; + + + export type PropValidatorFunction = (value: T) => boolean; + export type PropValidator = PropOptions; + + + export type PropOptions = { + type: PropType; + + value?: PropDefaultValue, + required?: boolean; + validator?: PropValidatorFunction; + } + + export type RecordPropsDefinition = { + [K in keyof T]: PropValidator + } + export type PropsDefinition = RecordPropsDefinition; + + + declare function extend({ props }: { props: PropsDefinition }): PropsDefinition; + + interface MyType { + valid: boolean; + } + + const r = extend({ + props: { + notResolved: { + type: Object as PropType, + validator: x => { + return x.valid; + } + }, + explicit: { + type: Object as PropType, + validator: (x: MyType) => { + return x.valid; + } + } + } + }) + + r.explicit + r.notResolved + r.explicit.required + r.notResolved.required + + // Modified repro from #30505 + + type Box = { + contents?: T; + contains?(content: T): boolean; + }; + + type Mapped = { + [K in keyof T]: Box; + } + + declare function id(arg: Mapped): Mapped; + + // All properties have inferable types + + const obj1 = id({ + foo: { + contents: "" + } + }); + + // Some properties have inferable types + + const obj2 = id({ + foo: { + contents: "", + contains(k) { + return k.length > 0; + } + } + }); + + // No properties have inferable types + + const obj3 = id({ + foo: { + contains(k) { + return k.length > 0; + ~ +!!! error TS2571: Object is of type 'unknown'. + } + } + }); + \ No newline at end of file diff --git a/tests/baselines/reference/reverseMappedPartiallyInferableTypes.js b/tests/baselines/reference/reverseMappedPartiallyInferableTypes.js new file mode 100644 index 00000000000..e5a9c2a57ae --- /dev/null +++ b/tests/baselines/reference/reverseMappedPartiallyInferableTypes.js @@ -0,0 +1,144 @@ +//// [reverseMappedPartiallyInferableTypes.ts] +// Repro from #30505 + +export type Prop = { (): T } +export type PropType = Prop; +export type PropDefaultValue = T; + + +export type PropValidatorFunction = (value: T) => boolean; +export type PropValidator = PropOptions; + + +export type PropOptions = { + type: PropType; + + value?: PropDefaultValue, + required?: boolean; + validator?: PropValidatorFunction; +} + +export type RecordPropsDefinition = { + [K in keyof T]: PropValidator +} +export type PropsDefinition = RecordPropsDefinition; + + +declare function extend({ props }: { props: PropsDefinition }): PropsDefinition; + +interface MyType { + valid: boolean; +} + +const r = extend({ + props: { + notResolved: { + type: Object as PropType, + validator: x => { + return x.valid; + } + }, + explicit: { + type: Object as PropType, + validator: (x: MyType) => { + return x.valid; + } + } + } +}) + +r.explicit +r.notResolved +r.explicit.required +r.notResolved.required + +// Modified repro from #30505 + +type Box = { + contents?: T; + contains?(content: T): boolean; +}; + +type Mapped = { + [K in keyof T]: Box; +} + +declare function id(arg: Mapped): Mapped; + +// All properties have inferable types + +const obj1 = id({ + foo: { + contents: "" + } +}); + +// Some properties have inferable types + +const obj2 = id({ + foo: { + contents: "", + contains(k) { + return k.length > 0; + } + } +}); + +// No properties have inferable types + +const obj3 = id({ + foo: { + contains(k) { + return k.length > 0; + } + } +}); + + +//// [reverseMappedPartiallyInferableTypes.js] +"use strict"; +// Repro from #30505 +exports.__esModule = true; +var r = extend({ + props: { + notResolved: { + type: Object, + validator: function (x) { + return x.valid; + } + }, + explicit: { + type: Object, + validator: function (x) { + return x.valid; + } + } + } +}); +r.explicit; +r.notResolved; +r.explicit.required; +r.notResolved.required; +// All properties have inferable types +var obj1 = id({ + foo: { + contents: "" + } +}); +// Some properties have inferable types +var obj2 = id({ + foo: { + contents: "", + contains: function (k) { + return k.length > 0; + } + } +}); +// No properties have inferable types +var obj3 = id({ + foo: { + contains: function (k) { + return k.length > 0; + } + } +}); diff --git a/tests/baselines/reference/reverseMappedPartiallyInferableTypes.symbols b/tests/baselines/reference/reverseMappedPartiallyInferableTypes.symbols new file mode 100644 index 00000000000..ac264a37e9e --- /dev/null +++ b/tests/baselines/reference/reverseMappedPartiallyInferableTypes.symbols @@ -0,0 +1,259 @@ +=== tests/cases/compiler/reverseMappedPartiallyInferableTypes.ts === +// Repro from #30505 + +export type Prop = { (): T } +>Prop : Symbol(Prop, Decl(reverseMappedPartiallyInferableTypes.ts, 0, 0)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 2, 17)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 2, 17)) + +export type PropType = Prop; +>PropType : Symbol(PropType, Decl(reverseMappedPartiallyInferableTypes.ts, 2, 31)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 3, 21)) +>Prop : Symbol(Prop, Decl(reverseMappedPartiallyInferableTypes.ts, 0, 0)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 3, 21)) + +export type PropDefaultValue = T; +>PropDefaultValue : Symbol(PropDefaultValue, Decl(reverseMappedPartiallyInferableTypes.ts, 3, 34)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 4, 29)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 4, 29)) + + +export type PropValidatorFunction = (value: T) => boolean; +>PropValidatorFunction : Symbol(PropValidatorFunction, Decl(reverseMappedPartiallyInferableTypes.ts, 4, 36)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 7, 34)) +>value : Symbol(value, Decl(reverseMappedPartiallyInferableTypes.ts, 7, 40)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 7, 34)) + +export type PropValidator = PropOptions; +>PropValidator : Symbol(PropValidator, Decl(reverseMappedPartiallyInferableTypes.ts, 7, 61)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 8, 26)) +>PropOptions : Symbol(PropOptions, Decl(reverseMappedPartiallyInferableTypes.ts, 8, 46)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 8, 26)) + + +export type PropOptions = { +>PropOptions : Symbol(PropOptions, Decl(reverseMappedPartiallyInferableTypes.ts, 8, 46)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 11, 24)) + + type: PropType; +>type : Symbol(type, Decl(reverseMappedPartiallyInferableTypes.ts, 11, 30)) +>PropType : Symbol(PropType, Decl(reverseMappedPartiallyInferableTypes.ts, 2, 31)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 11, 24)) + + value?: PropDefaultValue, +>value : Symbol(value, Decl(reverseMappedPartiallyInferableTypes.ts, 12, 22)) +>PropDefaultValue : Symbol(PropDefaultValue, Decl(reverseMappedPartiallyInferableTypes.ts, 3, 34)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 11, 24)) + + required?: boolean; +>required : Symbol(required, Decl(reverseMappedPartiallyInferableTypes.ts, 14, 32)) + + validator?: PropValidatorFunction; +>validator : Symbol(validator, Decl(reverseMappedPartiallyInferableTypes.ts, 15, 23)) +>PropValidatorFunction : Symbol(PropValidatorFunction, Decl(reverseMappedPartiallyInferableTypes.ts, 4, 36)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 11, 24)) +} + +export type RecordPropsDefinition = { +>RecordPropsDefinition : Symbol(RecordPropsDefinition, Decl(reverseMappedPartiallyInferableTypes.ts, 17, 1)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 19, 34)) + + [K in keyof T]: PropValidator +>K : Symbol(K, Decl(reverseMappedPartiallyInferableTypes.ts, 20, 5)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 19, 34)) +>PropValidator : Symbol(PropValidator, Decl(reverseMappedPartiallyInferableTypes.ts, 7, 61)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 19, 34)) +>K : Symbol(K, Decl(reverseMappedPartiallyInferableTypes.ts, 20, 5)) +} +export type PropsDefinition = RecordPropsDefinition; +>PropsDefinition : Symbol(PropsDefinition, Decl(reverseMappedPartiallyInferableTypes.ts, 21, 1)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 22, 28)) +>RecordPropsDefinition : Symbol(RecordPropsDefinition, Decl(reverseMappedPartiallyInferableTypes.ts, 17, 1)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 22, 28)) + + +declare function extend({ props }: { props: PropsDefinition }): PropsDefinition; +>extend : Symbol(extend, Decl(reverseMappedPartiallyInferableTypes.ts, 22, 58)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 24)) +>props : Symbol(props, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 28)) +>props : Symbol(props, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 39)) +>PropsDefinition : Symbol(PropsDefinition, Decl(reverseMappedPartiallyInferableTypes.ts, 21, 1)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 24)) +>PropsDefinition : Symbol(PropsDefinition, Decl(reverseMappedPartiallyInferableTypes.ts, 21, 1)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 24)) + +interface MyType { +>MyType : Symbol(MyType, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 90)) + + valid: boolean; +>valid : Symbol(MyType.valid, Decl(reverseMappedPartiallyInferableTypes.ts, 27, 18)) +} + +const r = extend({ +>r : Symbol(r, Decl(reverseMappedPartiallyInferableTypes.ts, 31, 5)) +>extend : Symbol(extend, Decl(reverseMappedPartiallyInferableTypes.ts, 22, 58)) + + props: { +>props : Symbol(props, Decl(reverseMappedPartiallyInferableTypes.ts, 31, 18)) + + notResolved: { +>notResolved : Symbol(notResolved, Decl(reverseMappedPartiallyInferableTypes.ts, 32, 12)) + + type: Object as PropType, +>type : Symbol(type, Decl(reverseMappedPartiallyInferableTypes.ts, 33, 22)) +>Object : Symbol(Object, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>PropType : Symbol(PropType, Decl(reverseMappedPartiallyInferableTypes.ts, 2, 31)) +>MyType : Symbol(MyType, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 90)) + + validator: x => { +>validator : Symbol(validator, Decl(reverseMappedPartiallyInferableTypes.ts, 34, 45)) +>x : Symbol(x, Decl(reverseMappedPartiallyInferableTypes.ts, 35, 22)) + + return x.valid; +>x.valid : Symbol(MyType.valid, Decl(reverseMappedPartiallyInferableTypes.ts, 27, 18)) +>x : Symbol(x, Decl(reverseMappedPartiallyInferableTypes.ts, 35, 22)) +>valid : Symbol(MyType.valid, Decl(reverseMappedPartiallyInferableTypes.ts, 27, 18)) + } + }, + explicit: { +>explicit : Symbol(explicit, Decl(reverseMappedPartiallyInferableTypes.ts, 38, 10)) + + type: Object as PropType, +>type : Symbol(type, Decl(reverseMappedPartiallyInferableTypes.ts, 39, 19)) +>Object : Symbol(Object, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>PropType : Symbol(PropType, Decl(reverseMappedPartiallyInferableTypes.ts, 2, 31)) +>MyType : Symbol(MyType, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 90)) + + validator: (x: MyType) => { +>validator : Symbol(validator, Decl(reverseMappedPartiallyInferableTypes.ts, 40, 45)) +>x : Symbol(x, Decl(reverseMappedPartiallyInferableTypes.ts, 41, 24)) +>MyType : Symbol(MyType, Decl(reverseMappedPartiallyInferableTypes.ts, 25, 90)) + + return x.valid; +>x.valid : Symbol(MyType.valid, Decl(reverseMappedPartiallyInferableTypes.ts, 27, 18)) +>x : Symbol(x, Decl(reverseMappedPartiallyInferableTypes.ts, 41, 24)) +>valid : Symbol(MyType.valid, Decl(reverseMappedPartiallyInferableTypes.ts, 27, 18)) + } + } + } +}) + +r.explicit +>r.explicit : Symbol(explicit, Decl(reverseMappedPartiallyInferableTypes.ts, 38, 10)) +>r : Symbol(r, Decl(reverseMappedPartiallyInferableTypes.ts, 31, 5)) +>explicit : Symbol(explicit, Decl(reverseMappedPartiallyInferableTypes.ts, 38, 10)) + +r.notResolved +>r.notResolved : Symbol(notResolved, Decl(reverseMappedPartiallyInferableTypes.ts, 32, 12)) +>r : Symbol(r, Decl(reverseMappedPartiallyInferableTypes.ts, 31, 5)) +>notResolved : Symbol(notResolved, Decl(reverseMappedPartiallyInferableTypes.ts, 32, 12)) + +r.explicit.required +>r.explicit.required : Symbol(required, Decl(reverseMappedPartiallyInferableTypes.ts, 14, 32)) +>r.explicit : Symbol(explicit, Decl(reverseMappedPartiallyInferableTypes.ts, 38, 10)) +>r : Symbol(r, Decl(reverseMappedPartiallyInferableTypes.ts, 31, 5)) +>explicit : Symbol(explicit, Decl(reverseMappedPartiallyInferableTypes.ts, 38, 10)) +>required : Symbol(required, Decl(reverseMappedPartiallyInferableTypes.ts, 14, 32)) + +r.notResolved.required +>r.notResolved.required : Symbol(required, Decl(reverseMappedPartiallyInferableTypes.ts, 14, 32)) +>r.notResolved : Symbol(notResolved, Decl(reverseMappedPartiallyInferableTypes.ts, 32, 12)) +>r : Symbol(r, Decl(reverseMappedPartiallyInferableTypes.ts, 31, 5)) +>notResolved : Symbol(notResolved, Decl(reverseMappedPartiallyInferableTypes.ts, 32, 12)) +>required : Symbol(required, Decl(reverseMappedPartiallyInferableTypes.ts, 14, 32)) + +// Modified repro from #30505 + +type Box = { +>Box : Symbol(Box, Decl(reverseMappedPartiallyInferableTypes.ts, 51, 22)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 55, 9)) + + contents?: T; +>contents : Symbol(contents, Decl(reverseMappedPartiallyInferableTypes.ts, 55, 15)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 55, 9)) + + contains?(content: T): boolean; +>contains : Symbol(contains, Decl(reverseMappedPartiallyInferableTypes.ts, 56, 17)) +>content : Symbol(content, Decl(reverseMappedPartiallyInferableTypes.ts, 57, 14)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 55, 9)) + +}; + +type Mapped = { +>Mapped : Symbol(Mapped, Decl(reverseMappedPartiallyInferableTypes.ts, 58, 2)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 60, 12)) + + [K in keyof T]: Box; +>K : Symbol(K, Decl(reverseMappedPartiallyInferableTypes.ts, 61, 5)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 60, 12)) +>Box : Symbol(Box, Decl(reverseMappedPartiallyInferableTypes.ts, 51, 22)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 60, 12)) +>K : Symbol(K, Decl(reverseMappedPartiallyInferableTypes.ts, 61, 5)) +} + +declare function id(arg: Mapped): Mapped; +>id : Symbol(id, Decl(reverseMappedPartiallyInferableTypes.ts, 62, 1)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 64, 20)) +>arg : Symbol(arg, Decl(reverseMappedPartiallyInferableTypes.ts, 64, 23)) +>Mapped : Symbol(Mapped, Decl(reverseMappedPartiallyInferableTypes.ts, 58, 2)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 64, 20)) +>Mapped : Symbol(Mapped, Decl(reverseMappedPartiallyInferableTypes.ts, 58, 2)) +>T : Symbol(T, Decl(reverseMappedPartiallyInferableTypes.ts, 64, 20)) + +// All properties have inferable types + +const obj1 = id({ +>obj1 : Symbol(obj1, Decl(reverseMappedPartiallyInferableTypes.ts, 68, 5)) +>id : Symbol(id, Decl(reverseMappedPartiallyInferableTypes.ts, 62, 1)) + + foo: { +>foo : Symbol(foo, Decl(reverseMappedPartiallyInferableTypes.ts, 68, 17)) + + contents: "" +>contents : Symbol(contents, Decl(reverseMappedPartiallyInferableTypes.ts, 69, 10)) + } +}); + +// Some properties have inferable types + +const obj2 = id({ +>obj2 : Symbol(obj2, Decl(reverseMappedPartiallyInferableTypes.ts, 76, 5)) +>id : Symbol(id, Decl(reverseMappedPartiallyInferableTypes.ts, 62, 1)) + + foo: { +>foo : Symbol(foo, Decl(reverseMappedPartiallyInferableTypes.ts, 76, 17)) + + contents: "", +>contents : Symbol(contents, Decl(reverseMappedPartiallyInferableTypes.ts, 77, 10)) + + contains(k) { +>contains : Symbol(contains, Decl(reverseMappedPartiallyInferableTypes.ts, 78, 21)) +>k : Symbol(k, Decl(reverseMappedPartiallyInferableTypes.ts, 79, 17)) + + return k.length > 0; +>k.length : Symbol(String.length, Decl(lib.es5.d.ts, --, --)) +>k : Symbol(k, Decl(reverseMappedPartiallyInferableTypes.ts, 79, 17)) +>length : Symbol(String.length, Decl(lib.es5.d.ts, --, --)) + } + } +}); + +// No properties have inferable types + +const obj3 = id({ +>obj3 : Symbol(obj3, Decl(reverseMappedPartiallyInferableTypes.ts, 87, 5)) +>id : Symbol(id, Decl(reverseMappedPartiallyInferableTypes.ts, 62, 1)) + + foo: { +>foo : Symbol(foo, Decl(reverseMappedPartiallyInferableTypes.ts, 87, 17)) + + contains(k) { +>contains : Symbol(contains, Decl(reverseMappedPartiallyInferableTypes.ts, 88, 10)) +>k : Symbol(k, Decl(reverseMappedPartiallyInferableTypes.ts, 89, 17)) + + return k.length > 0; +>k : Symbol(k, Decl(reverseMappedPartiallyInferableTypes.ts, 89, 17)) + } + } +}); + diff --git a/tests/baselines/reference/reverseMappedPartiallyInferableTypes.types b/tests/baselines/reference/reverseMappedPartiallyInferableTypes.types new file mode 100644 index 00000000000..49cd5cf8962 --- /dev/null +++ b/tests/baselines/reference/reverseMappedPartiallyInferableTypes.types @@ -0,0 +1,231 @@ +=== tests/cases/compiler/reverseMappedPartiallyInferableTypes.ts === +// Repro from #30505 + +export type Prop = { (): T } +>Prop : Prop + +export type PropType = Prop; +>PropType : Prop + +export type PropDefaultValue = T; +>PropDefaultValue : T + + +export type PropValidatorFunction = (value: T) => boolean; +>PropValidatorFunction : PropValidatorFunction +>value : T + +export type PropValidator = PropOptions; +>PropValidator : PropOptions + + +export type PropOptions = { +>PropOptions : PropOptions + + type: PropType; +>type : Prop + + value?: PropDefaultValue, +>value : T | undefined + + required?: boolean; +>required : boolean | undefined + + validator?: PropValidatorFunction; +>validator : PropValidatorFunction | undefined +} + +export type RecordPropsDefinition = { +>RecordPropsDefinition : RecordPropsDefinition + + [K in keyof T]: PropValidator +} +export type PropsDefinition = RecordPropsDefinition; +>PropsDefinition : RecordPropsDefinition + + +declare function extend({ props }: { props: PropsDefinition }): PropsDefinition; +>extend : ({ props }: { props: RecordPropsDefinition; }) => RecordPropsDefinition +>props : RecordPropsDefinition +>props : RecordPropsDefinition + +interface MyType { + valid: boolean; +>valid : boolean +} + +const r = extend({ +>r : RecordPropsDefinition<{ notResolved: MyType; explicit: MyType; }> +>extend({ props: { notResolved: { type: Object as PropType, validator: x => { return x.valid; } }, explicit: { type: Object as PropType, validator: (x: MyType) => { return x.valid; } } }}) : RecordPropsDefinition<{ notResolved: MyType; explicit: MyType; }> +>extend : ({ props }: { props: RecordPropsDefinition; }) => RecordPropsDefinition +>{ props: { notResolved: { type: Object as PropType, validator: x => { return x.valid; } }, explicit: { type: Object as PropType, validator: (x: MyType) => { return x.valid; } } }} : { props: { notResolved: { type: Prop; validator: (x: MyType) => boolean; }; explicit: { type: Prop; validator: (x: MyType) => boolean; }; }; } + + props: { +>props : { notResolved: { type: Prop; validator: (x: MyType) => boolean; }; explicit: { type: Prop; validator: (x: MyType) => boolean; }; } +>{ notResolved: { type: Object as PropType, validator: x => { return x.valid; } }, explicit: { type: Object as PropType, validator: (x: MyType) => { return x.valid; } } } : { notResolved: { type: Prop; validator: (x: MyType) => boolean; }; explicit: { type: Prop; validator: (x: MyType) => boolean; }; } + + notResolved: { +>notResolved : { type: Prop; validator: (x: MyType) => boolean; } +>{ type: Object as PropType, validator: x => { return x.valid; } } : { type: Prop; validator: (x: MyType) => boolean; } + + type: Object as PropType, +>type : Prop +>Object as PropType : Prop +>Object : ObjectConstructor + + validator: x => { +>validator : (x: MyType) => boolean +>x => { return x.valid; } : (x: MyType) => boolean +>x : MyType + + return x.valid; +>x.valid : boolean +>x : MyType +>valid : boolean + } + }, + explicit: { +>explicit : { type: Prop; validator: (x: MyType) => boolean; } +>{ type: Object as PropType, validator: (x: MyType) => { return x.valid; } } : { type: Prop; validator: (x: MyType) => boolean; } + + type: Object as PropType, +>type : Prop +>Object as PropType : Prop +>Object : ObjectConstructor + + validator: (x: MyType) => { +>validator : (x: MyType) => boolean +>(x: MyType) => { return x.valid; } : (x: MyType) => boolean +>x : MyType + + return x.valid; +>x.valid : boolean +>x : MyType +>valid : boolean + } + } + } +}) + +r.explicit +>r.explicit : PropOptions +>r : RecordPropsDefinition<{ notResolved: MyType; explicit: MyType; }> +>explicit : PropOptions + +r.notResolved +>r.notResolved : PropOptions +>r : RecordPropsDefinition<{ notResolved: MyType; explicit: MyType; }> +>notResolved : PropOptions + +r.explicit.required +>r.explicit.required : boolean | undefined +>r.explicit : PropOptions +>r : RecordPropsDefinition<{ notResolved: MyType; explicit: MyType; }> +>explicit : PropOptions +>required : boolean | undefined + +r.notResolved.required +>r.notResolved.required : boolean | undefined +>r.notResolved : PropOptions +>r : RecordPropsDefinition<{ notResolved: MyType; explicit: MyType; }> +>notResolved : PropOptions +>required : boolean | undefined + +// Modified repro from #30505 + +type Box = { +>Box : Box + + contents?: T; +>contents : T | undefined + + contains?(content: T): boolean; +>contains : ((content: T) => boolean) | undefined +>content : T + +}; + +type Mapped = { +>Mapped : Mapped + + [K in keyof T]: Box; +} + +declare function id(arg: Mapped): Mapped; +>id : (arg: Mapped) => Mapped +>arg : Mapped + +// All properties have inferable types + +const obj1 = id({ +>obj1 : Mapped<{ foo: string; }> +>id({ foo: { contents: "" }}) : Mapped<{ foo: string; }> +>id : (arg: Mapped) => Mapped +>{ foo: { contents: "" }} : { foo: { contents: string; }; } + + foo: { +>foo : { contents: string; } +>{ contents: "" } : { contents: string; } + + contents: "" +>contents : string +>"" : "" + } +}); + +// Some properties have inferable types + +const obj2 = id({ +>obj2 : Mapped<{ foo: string; }> +>id({ foo: { contents: "", contains(k) { return k.length > 0; } }}) : Mapped<{ foo: string; }> +>id : (arg: Mapped) => Mapped +>{ foo: { contents: "", contains(k) { return k.length > 0; } }} : { foo: { contents: string; contains(k: string): boolean; }; } + + foo: { +>foo : { contents: string; contains(k: string): boolean; } +>{ contents: "", contains(k) { return k.length > 0; } } : { contents: string; contains(k: string): boolean; } + + contents: "", +>contents : string +>"" : "" + + contains(k) { +>contains : (k: string) => boolean +>k : string + + return k.length > 0; +>k.length > 0 : boolean +>k.length : number +>k : string +>length : number +>0 : 0 + } + } +}); + +// No properties have inferable types + +const obj3 = id({ +>obj3 : Mapped +>id({ foo: { contains(k) { return k.length > 0; } }}) : Mapped +>id : (arg: Mapped) => Mapped +>{ foo: { contains(k) { return k.length > 0; } }} : { foo: { contains(k: unknown): boolean; }; } + + foo: { +>foo : { contains(k: unknown): boolean; } +>{ contains(k) { return k.length > 0; } } : { contains(k: unknown): boolean; } + + contains(k) { +>contains : (k: unknown) => boolean +>k : unknown + + return k.length > 0; +>k.length > 0 : boolean +>k.length : any +>k : unknown +>length : any +>0 : 0 + } + } +}); + From 578013b65cbc78930279388a810fbb0d12b67c73 Mon Sep 17 00:00:00 2001 From: rpgeeganage Date: Sun, 5 May 2019 18:59:45 +0200 Subject: [PATCH 034/119] modified the service file --- src/services/services.ts | 28 ++++++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-) diff --git a/src/services/services.ts b/src/services/services.ts index 42d2278bcba..ab5138fb489 100644 --- a/src/services/services.ts +++ b/src/services/services.ts @@ -1467,33 +1467,49 @@ namespace ts { } const typeChecker = program.getTypeChecker(); - const symbol = getSymbolAtLocationForQuickInfo(node, typeChecker); + const nodeForQuickInfo = getNodeForQuickInfo(node, typeChecker); + const symbol = getSymbolAtLocationForQuickInfo(nodeForQuickInfo, typeChecker); if (!symbol || typeChecker.isUnknownSymbol(symbol)) { - const type = shouldGetType(sourceFile, node, position) ? typeChecker.getTypeAtLocation(node) : undefined; + const type = shouldGetType(sourceFile, nodeForQuickInfo, position) ? typeChecker.getTypeAtLocation(nodeForQuickInfo) : undefined; return type && { kind: ScriptElementKind.unknown, kindModifiers: ScriptElementKindModifier.none, - textSpan: createTextSpanFromNode(node, sourceFile), - displayParts: typeChecker.runWithCancellationToken(cancellationToken, typeChecker => typeToDisplayParts(typeChecker, type, getContainerNode(node))), + textSpan: createTextSpanFromNode(nodeForQuickInfo, sourceFile), + displayParts: typeChecker.runWithCancellationToken(cancellationToken, typeChecker => typeToDisplayParts(typeChecker, type, getContainerNode(nodeForQuickInfo))), documentation: type.symbol ? type.symbol.getDocumentationComment(typeChecker) : undefined, tags: type.symbol ? type.symbol.getJsDocTags() : undefined }; } const { symbolKind, displayParts, documentation, tags } = typeChecker.runWithCancellationToken(cancellationToken, typeChecker => - SymbolDisplay.getSymbolDisplayPartsDocumentationAndSymbolKind(typeChecker, symbol, sourceFile, getContainerNode(node), node) + SymbolDisplay.getSymbolDisplayPartsDocumentationAndSymbolKind(typeChecker, symbol, sourceFile, getContainerNode(nodeForQuickInfo), nodeForQuickInfo) ); return { kind: symbolKind, kindModifiers: SymbolDisplay.getSymbolModifiers(symbol), - textSpan: createTextSpanFromNode(node, sourceFile), + textSpan: createTextSpanFromNode(nodeForQuickInfo, sourceFile), displayParts, documentation, tags, }; } + function getNodeForQuickInfo(node: Node, typeChecker: TypeChecker): Node { + const firstParentNode = node.parent.getFirstToken(); + const firstNodeSyntaxKind = firstParentNode ? firstParentNode.kind : undefined; + + if (node.kind === SyntaxKind.NewKeyword || firstNodeSyntaxKind === SyntaxKind.NewKeyword) { + for (const singleNode of node.parent.getChildren()) { + const symbol = getSymbolAtLocationForQuickInfo(singleNode, typeChecker); + if (symbol) { + return singleNode; + } + } + } + return node; + } + function shouldGetType(sourceFile: SourceFile, node: Node, position: number): boolean { switch (node.kind) { case SyntaxKind.Identifier: From 9959ce449e6ef9dcb047572f7e670811f5447206 Mon Sep 17 00:00:00 2001 From: rpgeeganage Date: Sun, 5 May 2019 19:00:01 +0200 Subject: [PATCH 035/119] added test --- .../fourslash/quickInfoOnNewKeyword01.ts | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 tests/cases/fourslash/quickInfoOnNewKeyword01.ts diff --git a/tests/cases/fourslash/quickInfoOnNewKeyword01.ts b/tests/cases/fourslash/quickInfoOnNewKeyword01.ts new file mode 100644 index 00000000000..21ccb8a6502 --- /dev/null +++ b/tests/cases/fourslash/quickInfoOnNewKeyword01.ts @@ -0,0 +1,21 @@ +/// + +////class Cat { +//// /** +//// * NOTE: this constructor is private! Please use the factory function +//// */ +//// private constructor() { } +//// +//// static makeCat() { new Cat(); } +////} +//// +////ne/*1*/w Ca/*2*/t(/*3*/); + +verify.quickInfoAt('1', 'constructor Cat(): Cat', +'NOTE: this constructor is private! Please use the factory function'); + +verify.quickInfoAt('2', 'constructor Cat(): Cat', +'NOTE: this constructor is private! Please use the factory function'); + +verify.quickInfoAt('3', 'constructor Cat(): Cat', +'NOTE: this constructor is private! Please use the factory function'); From ca749b107cbd4b467904c51d3b6dc78d30a43d6b Mon Sep 17 00:00:00 2001 From: rpgeeganage Date: Sun, 5 May 2019 21:58:31 +0200 Subject: [PATCH 036/119] updated the baseline files --- tests/baselines/reference/jsDocTags.baseline | 70 +++++ ...oDisplayPartsTypeParameterInClass.baseline | 84 +++++- ...playPartsTypeParameterInInterface.baseline | 260 +++++++++++++++++- 3 files changed, 402 insertions(+), 12 deletions(-) diff --git a/tests/baselines/reference/jsDocTags.baseline b/tests/baselines/reference/jsDocTags.baseline index f316a9c4245..2d89c183ab3 100644 --- a/tests/baselines/reference/jsDocTags.baseline +++ b/tests/baselines/reference/jsDocTags.baseline @@ -79,6 +79,76 @@ "marker": { "fileName": "/tests/cases/fourslash/jsDocTags.ts", "position": 981 + }, + "quickInfo": { + "kind": "constructor", + "kindModifiers": "", + "textSpan": { + "start": 977, + "length": 3 + }, + "displayParts": [ + { + "text": "constructor", + "kind": "keyword" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "Foo", + "kind": "className" + }, + { + "text": "(", + "kind": "punctuation" + }, + { + "text": "value", + "kind": "parameterName" + }, + { + "text": ":", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "number", + "kind": "keyword" + }, + { + "text": ")", + "kind": "punctuation" + }, + { + "text": ":", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "Foo", + "kind": "className" + } + ], + "documentation": [ + { + "text": "This is the constructor.", + "kind": "text" + } + ], + "tags": [ + { + "name": "myjsdoctag", + "text": "this is a comment" + } + ] } }, { diff --git a/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInClass.baseline b/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInClass.baseline index 48bd280a1b5..68e48ff9b68 100644 --- a/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInClass.baseline +++ b/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInClass.baseline @@ -2991,15 +2991,15 @@ "position": 337 }, "quickInfo": { - "kind": "var", + "kind": "constructor", "kindModifiers": "", "textSpan": { - "start": 337, - "length": 9 + "start": 334, + "length": 2 }, "displayParts": [ { - "text": "var", + "text": "constructor", "kind": "keyword" }, { @@ -3007,8 +3007,40 @@ "kind": "space" }, { - "text": "cInstance", - "kind": "localName" + "text": "c2", + "kind": "className" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "c", + "kind": "className" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "string", + "kind": "keyword" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": "(", + "kind": "punctuation" + }, + { + "text": "a", + "kind": "parameterName" }, { "text": ":", @@ -3030,6 +3062,46 @@ "text": "string", "kind": "keyword" }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": ")", + "kind": "punctuation" + }, + { + "text": ":", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "c2", + "kind": "className" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "c", + "kind": "className" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "string", + "kind": "keyword" + }, + { + "text": ">", + "kind": "punctuation" + }, { "text": ">", "kind": "punctuation" diff --git a/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInInterface.baseline b/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInInterface.baseline index 715811f9918..6830394801c 100644 --- a/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInInterface.baseline +++ b/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInInterface.baseline @@ -5568,8 +5568,8 @@ "kind": "var", "kindModifiers": "", "textSpan": { - "start": 415, - "length": 4 + "start": 409, + "length": 5 }, "displayParts": [ { @@ -5581,7 +5581,7 @@ "kind": "space" }, { - "text": "iVal", + "text": "iVal1", "kind": "localName" }, { @@ -5592,6 +5592,130 @@ "text": " ", "kind": "space" }, + { + "text": "I1", + "kind": "interfaceName" + }, + { + "text": "\n", + "kind": "lineBreak" + }, + { + "text": "new", + "kind": "keyword" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "I", + "kind": "interfaceName" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "string", + "kind": "keyword" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": "(", + "kind": "punctuation" + }, + { + "text": "a", + "kind": "parameterName" + }, + { + "text": ":", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "I", + "kind": "interfaceName" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "string", + "kind": "keyword" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": ",", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "b", + "kind": "parameterName" + }, + { + "text": ":", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "I", + "kind": "interfaceName" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "string", + "kind": "keyword" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": ")", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "=>", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, { "text": "I", "kind": "interfaceName" @@ -5621,8 +5745,8 @@ "kind": "var", "kindModifiers": "", "textSpan": { - "start": 421, - "length": 4 + "start": 409, + "length": 5 }, "displayParts": [ { @@ -5634,7 +5758,7 @@ "kind": "space" }, { - "text": "iVal", + "text": "iVal1", "kind": "localName" }, { @@ -5645,6 +5769,130 @@ "text": " ", "kind": "space" }, + { + "text": "I1", + "kind": "interfaceName" + }, + { + "text": "\n", + "kind": "lineBreak" + }, + { + "text": "new", + "kind": "keyword" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "I", + "kind": "interfaceName" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "string", + "kind": "keyword" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": "(", + "kind": "punctuation" + }, + { + "text": "a", + "kind": "parameterName" + }, + { + "text": ":", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "I", + "kind": "interfaceName" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "string", + "kind": "keyword" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": ",", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "b", + "kind": "parameterName" + }, + { + "text": ":", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "I", + "kind": "interfaceName" + }, + { + "text": "<", + "kind": "punctuation" + }, + { + "text": "string", + "kind": "keyword" + }, + { + "text": ">", + "kind": "punctuation" + }, + { + "text": ")", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, + { + "text": "=>", + "kind": "punctuation" + }, + { + "text": " ", + "kind": "space" + }, { "text": "I", "kind": "interfaceName" From 8f209be149ec626f40031a5b0f904ae5ea74479d Mon Sep 17 00:00:00 2001 From: rpgeeganage Date: Mon, 6 May 2019 21:21:37 +0200 Subject: [PATCH 037/119] fixed the comments --- src/services/services.ts | 16 +- tests/baselines/reference/jsDocTags.baseline | 70 ----- ...oDisplayPartsTypeParameterInClass.baseline | 84 +----- ...playPartsTypeParameterInInterface.baseline | 260 +----------------- .../fourslash/quickInfoOnNewKeyword01.ts | 5 +- 5 files changed, 17 insertions(+), 418 deletions(-) diff --git a/src/services/services.ts b/src/services/services.ts index ab5138fb489..628ec395437 100644 --- a/src/services/services.ts +++ b/src/services/services.ts @@ -1467,7 +1467,7 @@ namespace ts { } const typeChecker = program.getTypeChecker(); - const nodeForQuickInfo = getNodeForQuickInfo(node, typeChecker); + const nodeForQuickInfo = getNodeForQuickInfo(node); const symbol = getSymbolAtLocationForQuickInfo(nodeForQuickInfo, typeChecker); if (!symbol || typeChecker.isUnknownSymbol(symbol)) { @@ -1495,17 +1495,9 @@ namespace ts { }; } - function getNodeForQuickInfo(node: Node, typeChecker: TypeChecker): Node { - const firstParentNode = node.parent.getFirstToken(); - const firstNodeSyntaxKind = firstParentNode ? firstParentNode.kind : undefined; - - if (node.kind === SyntaxKind.NewKeyword || firstNodeSyntaxKind === SyntaxKind.NewKeyword) { - for (const singleNode of node.parent.getChildren()) { - const symbol = getSymbolAtLocationForQuickInfo(singleNode, typeChecker); - if (symbol) { - return singleNode; - } - } + function getNodeForQuickInfo(node: Node): Node { + if (isNewExpression(node.parent) && node.pos === node.parent.pos) { + return node.parent.expression; } return node; } diff --git a/tests/baselines/reference/jsDocTags.baseline b/tests/baselines/reference/jsDocTags.baseline index 2d89c183ab3..f316a9c4245 100644 --- a/tests/baselines/reference/jsDocTags.baseline +++ b/tests/baselines/reference/jsDocTags.baseline @@ -79,76 +79,6 @@ "marker": { "fileName": "/tests/cases/fourslash/jsDocTags.ts", "position": 981 - }, - "quickInfo": { - "kind": "constructor", - "kindModifiers": "", - "textSpan": { - "start": 977, - "length": 3 - }, - "displayParts": [ - { - "text": "constructor", - "kind": "keyword" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "Foo", - "kind": "className" - }, - { - "text": "(", - "kind": "punctuation" - }, - { - "text": "value", - "kind": "parameterName" - }, - { - "text": ":", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "number", - "kind": "keyword" - }, - { - "text": ")", - "kind": "punctuation" - }, - { - "text": ":", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "Foo", - "kind": "className" - } - ], - "documentation": [ - { - "text": "This is the constructor.", - "kind": "text" - } - ], - "tags": [ - { - "name": "myjsdoctag", - "text": "this is a comment" - } - ] } }, { diff --git a/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInClass.baseline b/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInClass.baseline index 68e48ff9b68..48bd280a1b5 100644 --- a/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInClass.baseline +++ b/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInClass.baseline @@ -2991,15 +2991,15 @@ "position": 337 }, "quickInfo": { - "kind": "constructor", + "kind": "var", "kindModifiers": "", "textSpan": { - "start": 334, - "length": 2 + "start": 337, + "length": 9 }, "displayParts": [ { - "text": "constructor", + "text": "var", "kind": "keyword" }, { @@ -3007,40 +3007,8 @@ "kind": "space" }, { - "text": "c2", - "kind": "className" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "c", - "kind": "className" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "string", - "kind": "keyword" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": "(", - "kind": "punctuation" - }, - { - "text": "a", - "kind": "parameterName" + "text": "cInstance", + "kind": "localName" }, { "text": ":", @@ -3062,46 +3030,6 @@ "text": "string", "kind": "keyword" }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": ")", - "kind": "punctuation" - }, - { - "text": ":", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "c2", - "kind": "className" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "c", - "kind": "className" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "string", - "kind": "keyword" - }, - { - "text": ">", - "kind": "punctuation" - }, { "text": ">", "kind": "punctuation" diff --git a/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInInterface.baseline b/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInInterface.baseline index 6830394801c..715811f9918 100644 --- a/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInInterface.baseline +++ b/tests/baselines/reference/quickInfoDisplayPartsTypeParameterInInterface.baseline @@ -5568,8 +5568,8 @@ "kind": "var", "kindModifiers": "", "textSpan": { - "start": 409, - "length": 5 + "start": 415, + "length": 4 }, "displayParts": [ { @@ -5581,7 +5581,7 @@ "kind": "space" }, { - "text": "iVal1", + "text": "iVal", "kind": "localName" }, { @@ -5592,130 +5592,6 @@ "text": " ", "kind": "space" }, - { - "text": "I1", - "kind": "interfaceName" - }, - { - "text": "\n", - "kind": "lineBreak" - }, - { - "text": "new", - "kind": "keyword" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "I", - "kind": "interfaceName" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "string", - "kind": "keyword" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": "(", - "kind": "punctuation" - }, - { - "text": "a", - "kind": "parameterName" - }, - { - "text": ":", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "I", - "kind": "interfaceName" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "string", - "kind": "keyword" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": ",", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "b", - "kind": "parameterName" - }, - { - "text": ":", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "I", - "kind": "interfaceName" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "string", - "kind": "keyword" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": ")", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "=>", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, { "text": "I", "kind": "interfaceName" @@ -5745,8 +5621,8 @@ "kind": "var", "kindModifiers": "", "textSpan": { - "start": 409, - "length": 5 + "start": 421, + "length": 4 }, "displayParts": [ { @@ -5758,7 +5634,7 @@ "kind": "space" }, { - "text": "iVal1", + "text": "iVal", "kind": "localName" }, { @@ -5769,130 +5645,6 @@ "text": " ", "kind": "space" }, - { - "text": "I1", - "kind": "interfaceName" - }, - { - "text": "\n", - "kind": "lineBreak" - }, - { - "text": "new", - "kind": "keyword" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "I", - "kind": "interfaceName" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "string", - "kind": "keyword" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": "(", - "kind": "punctuation" - }, - { - "text": "a", - "kind": "parameterName" - }, - { - "text": ":", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "I", - "kind": "interfaceName" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "string", - "kind": "keyword" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": ",", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "b", - "kind": "parameterName" - }, - { - "text": ":", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "I", - "kind": "interfaceName" - }, - { - "text": "<", - "kind": "punctuation" - }, - { - "text": "string", - "kind": "keyword" - }, - { - "text": ">", - "kind": "punctuation" - }, - { - "text": ")", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, - { - "text": "=>", - "kind": "punctuation" - }, - { - "text": " ", - "kind": "space" - }, { "text": "I", "kind": "interfaceName" diff --git a/tests/cases/fourslash/quickInfoOnNewKeyword01.ts b/tests/cases/fourslash/quickInfoOnNewKeyword01.ts index 21ccb8a6502..f7d1e359b8d 100644 --- a/tests/cases/fourslash/quickInfoOnNewKeyword01.ts +++ b/tests/cases/fourslash/quickInfoOnNewKeyword01.ts @@ -9,13 +9,10 @@ //// static makeCat() { new Cat(); } ////} //// -////ne/*1*/w Ca/*2*/t(/*3*/); +////ne/*1*/w Ca/*2*/t(); verify.quickInfoAt('1', 'constructor Cat(): Cat', 'NOTE: this constructor is private! Please use the factory function'); verify.quickInfoAt('2', 'constructor Cat(): Cat', 'NOTE: this constructor is private! Please use the factory function'); - -verify.quickInfoAt('3', 'constructor Cat(): Cat', -'NOTE: this constructor is private! Please use the factory function'); From 4af3a3b54113b50db727b2a392e31f3a2b8d812e Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 8 May 2019 14:11:51 -0700 Subject: [PATCH 038/119] Lower priority for inferences made from partial reverse mapped types --- src/compiler/checker.ts | 13 +++++++------ src/compiler/types.ts | 17 +++++++++-------- 2 files changed, 16 insertions(+), 14 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 61607e9c904..e8299a89c4e 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -14898,11 +14898,8 @@ namespace ts { function createReverseMappedType(source: Type, target: MappedType, constraint: IndexType) { // We consider a source type reverse mappable if it has a string index signature or if - // it has one or more properties and all properties have inferable types. - const properties = getPropertiesOfType(source); - const isReverseMappable = getIndexInfoOfType(source, IndexKind.String) || - properties.length !== 0 && every(properties, prop => isPartiallyInferableType(getTypeOfSymbol(prop))); - if (!isReverseMappable) { + // it has one or more properties and is of a partially inferable type. + if (!(getIndexInfoOfType(source, IndexKind.String) || getPropertiesOfType(source).length !== 0 && isPartiallyInferableType(source))) { return undefined; } // For arrays and tuples we infer new arrays and tuples where the reverse mapping has been @@ -15287,7 +15284,11 @@ namespace ts { const inferredType = inferTypeForHomomorphicMappedType(source, target, constraintType); if (inferredType) { const savePriority = priority; - priority |= InferencePriority.HomomorphicMappedType; + // We assign a lower priority to inferences made from types containing non-inferrable + // types because we may only have a partial result (i.e. we may have failed to make + // reverse inferences for some properties). + priority |= getObjectFlags(source) & ObjectFlags.NonInferrableType ? + InferencePriority.PartialHomomorphicMappedType : InferencePriority.HomomorphicMappedType; inferFromTypes(inferredType, inference.typeParameter); priority = savePriority; } diff --git a/src/compiler/types.ts b/src/compiler/types.ts index 5e2d6aba474..6c6e585d492 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -4405,15 +4405,16 @@ namespace ts { export type TypeMapper = (t: TypeParameter) => Type; export const enum InferencePriority { - NakedTypeVariable = 1 << 0, // Naked type variable in union or intersection type - HomomorphicMappedType = 1 << 1, // Reverse inference for homomorphic mapped type - MappedTypeConstraint = 1 << 2, // Reverse inference for mapped type - ReturnType = 1 << 3, // Inference made from return type of generic function - LiteralKeyof = 1 << 4, // Inference made from a string literal to a keyof T - NoConstraints = 1 << 5, // Don't infer from constraints of instantiable types - AlwaysStrict = 1 << 6, // Always use strict rules for contravariant inferences + NakedTypeVariable = 1 << 0, // Naked type variable in union or intersection type + HomomorphicMappedType = 1 << 1, // Reverse inference for homomorphic mapped type + PartialHomomorphicMappedType = 1 << 2, // Partial reverse inference for homomorphic mapped type + MappedTypeConstraint = 1 << 3, // Reverse inference for mapped type + ReturnType = 1 << 4, // Inference made from return type of generic function + LiteralKeyof = 1 << 5, // Inference made from a string literal to a keyof T + NoConstraints = 1 << 6, // Don't infer from constraints of instantiable types + AlwaysStrict = 1 << 7, // Always use strict rules for contravariant inferences - PriorityImpliesCombination = ReturnType | MappedTypeConstraint | LiteralKeyof, // These priorities imply that the resulting type should be a combination of all candidates + PriorityImpliesCombination = ReturnType | MappedTypeConstraint | LiteralKeyof, // These priorities imply that the resulting type should be a combination of all candidates } /* @internal */ From c104aa162ebcc976ad7983edbe90e32f5f6d9828 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 8 May 2019 14:22:34 -0700 Subject: [PATCH 039/119] Accept new baselines --- tests/baselines/reference/api/tsserverlibrary.d.ts | 13 +++++++------ tests/baselines/reference/api/typescript.d.ts | 13 +++++++------ .../reference/mappedTypeInferenceErrors.errors.txt | 2 +- 3 files changed, 15 insertions(+), 13 deletions(-) diff --git a/tests/baselines/reference/api/tsserverlibrary.d.ts b/tests/baselines/reference/api/tsserverlibrary.d.ts index fb95102e791..98a8f05d418 100644 --- a/tests/baselines/reference/api/tsserverlibrary.d.ts +++ b/tests/baselines/reference/api/tsserverlibrary.d.ts @@ -2413,12 +2413,13 @@ declare namespace ts { enum InferencePriority { NakedTypeVariable = 1, HomomorphicMappedType = 2, - MappedTypeConstraint = 4, - ReturnType = 8, - LiteralKeyof = 16, - NoConstraints = 32, - AlwaysStrict = 64, - PriorityImpliesCombination = 28 + PartialHomomorphicMappedType = 4, + MappedTypeConstraint = 8, + ReturnType = 16, + LiteralKeyof = 32, + NoConstraints = 64, + AlwaysStrict = 128, + PriorityImpliesCombination = 56 } /** @deprecated Use FileExtensionInfo instead. */ type JsFileExtensionInfo = FileExtensionInfo; diff --git a/tests/baselines/reference/api/typescript.d.ts b/tests/baselines/reference/api/typescript.d.ts index 170cb00b9e8..592c99936f9 100644 --- a/tests/baselines/reference/api/typescript.d.ts +++ b/tests/baselines/reference/api/typescript.d.ts @@ -2413,12 +2413,13 @@ declare namespace ts { enum InferencePriority { NakedTypeVariable = 1, HomomorphicMappedType = 2, - MappedTypeConstraint = 4, - ReturnType = 8, - LiteralKeyof = 16, - NoConstraints = 32, - AlwaysStrict = 64, - PriorityImpliesCombination = 28 + PartialHomomorphicMappedType = 4, + MappedTypeConstraint = 8, + ReturnType = 16, + LiteralKeyof = 32, + NoConstraints = 64, + AlwaysStrict = 128, + PriorityImpliesCombination = 56 } /** @deprecated Use FileExtensionInfo instead. */ type JsFileExtensionInfo = FileExtensionInfo; diff --git a/tests/baselines/reference/mappedTypeInferenceErrors.errors.txt b/tests/baselines/reference/mappedTypeInferenceErrors.errors.txt index f83f01f77bf..0c5e835db96 100644 --- a/tests/baselines/reference/mappedTypeInferenceErrors.errors.txt +++ b/tests/baselines/reference/mappedTypeInferenceErrors.errors.txt @@ -20,7 +20,7 @@ tests/cases/conformance/types/mapped/mappedTypeInferenceErrors.ts(16,9): error T baz: 42 ~~~ !!! error TS2322: Type 'number' is not assignable to type '() => unknown'. -!!! related TS6500 tests/cases/conformance/types/mapped/mappedTypeInferenceErrors.ts:16:9: The expected type comes from property 'baz' which is declared here on type 'ComputedOf<{ bar: number; baz: unknown; }>' +!!! related TS6500 tests/cases/conformance/types/mapped/mappedTypeInferenceErrors.ts:16:9: The expected type comes from property 'baz' which is declared here on type 'ComputedOf<{ bar: unknown; baz: unknown; }>' } }); \ No newline at end of file From 46a278d449a064c49e2a398126c357c62d4cc536 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Fri, 10 May 2019 09:48:33 -0700 Subject: [PATCH 040/119] Consistently check conditional extends type for type parameter references --- src/compiler/checker.ts | 24 ++++++------------------ 1 file changed, 6 insertions(+), 18 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 764f926ecdb..5341821d91e 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -10480,21 +10480,6 @@ namespace ts { return result; } - function isPossiblyReferencedInConditionalType(tp: TypeParameter, node: Node) { - if (isTypeParameterPossiblyReferenced(tp, node)) { - return true; - } - while (node) { - if (node.kind === SyntaxKind.ConditionalType) { - if (isTypeParameterPossiblyReferenced(tp, (node).extendsType)) { - return true; - } - } - node = node.parent; - } - return false; - } - function getTypeFromConditionalTypeNode(node: ConditionalTypeNode): Type { const links = getNodeLinks(node); if (!links.resolvedType) { @@ -10502,7 +10487,7 @@ namespace ts { const aliasSymbol = getAliasSymbolForTypeNode(node); const aliasTypeArguments = getTypeArgumentsForAliasSymbol(aliasSymbol); const allOuterTypeParameters = getOuterTypeParameters(node, /*includeThisTypes*/ true); - const outerTypeParameters = aliasTypeArguments ? allOuterTypeParameters : filter(allOuterTypeParameters, tp => isPossiblyReferencedInConditionalType(tp, node)); + const outerTypeParameters = aliasTypeArguments ? allOuterTypeParameters : filter(allOuterTypeParameters, tp => isTypeParameterPossiblyReferenced(tp, node)); const root: ConditionalRoot = { node, checkType, @@ -11196,9 +11181,12 @@ namespace ts { // type parameter, or if the node contains type queries, we consider the type parameter possibly referenced. if (tp.symbol && tp.symbol.declarations && tp.symbol.declarations.length === 1) { const container = tp.symbol.declarations[0].parent; - if (findAncestor(node, n => n.kind === SyntaxKind.Block ? "quit" : n === container)) { - return !!forEachChild(node, containsReference); + for (let n = node; n !== container; n = n.parent) { + if (!n || n.kind === SyntaxKind.Block || n.kind === SyntaxKind.ConditionalType && forEachChild((n).extendsType, containsReference)) { + return true; + } } + return !!forEachChild(node, containsReference); } return true; function containsReference(node: Node): boolean { From ee59cee381ff1a114634da192abcf0606b74ba29 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Fri, 10 May 2019 09:56:17 -0700 Subject: [PATCH 041/119] Add regression test --- .../conformance/types/conditional/conditionalTypes2.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/cases/conformance/types/conditional/conditionalTypes2.ts b/tests/cases/conformance/types/conditional/conditionalTypes2.ts index 4b65b5ddeb2..bb70093f233 100644 --- a/tests/cases/conformance/types/conditional/conditionalTypes2.ts +++ b/tests/cases/conformance/types/conditional/conditionalTypes2.ts @@ -190,3 +190,9 @@ type ProductComplementComplement = { }; type PCCA = ProductComplementComplement['a']; type PCCB = ProductComplementComplement['b']; + +// Repro from #31326 + +type Hmm = U extends T ? { [K in keyof U]: number } : never; +type What = Hmm<{}, { a: string }> +const w: What = { a: 4 }; From 1366cc7d2b60f24eda964766d6951640b9264276 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Fri, 10 May 2019 09:56:23 -0700 Subject: [PATCH 042/119] Accept new baselines --- .../reference/conditionalTypes2.errors.txt | 6 +++++ .../baselines/reference/conditionalTypes2.js | 14 ++++++++++++ .../reference/conditionalTypes2.symbols | 22 +++++++++++++++++++ .../reference/conditionalTypes2.types | 15 +++++++++++++ 4 files changed, 57 insertions(+) diff --git a/tests/baselines/reference/conditionalTypes2.errors.txt b/tests/baselines/reference/conditionalTypes2.errors.txt index f17a55dd61c..4093bf46fb0 100644 --- a/tests/baselines/reference/conditionalTypes2.errors.txt +++ b/tests/baselines/reference/conditionalTypes2.errors.txt @@ -267,4 +267,10 @@ tests/cases/conformance/types/conditional/conditionalTypes2.ts(75,12): error TS2 }; type PCCA = ProductComplementComplement['a']; type PCCB = ProductComplementComplement['b']; + + // Repro from #31326 + + type Hmm = U extends T ? { [K in keyof U]: number } : never; + type What = Hmm<{}, { a: string }> + const w: What = { a: 4 }; \ No newline at end of file diff --git a/tests/baselines/reference/conditionalTypes2.js b/tests/baselines/reference/conditionalTypes2.js index 4f4f35e821a..cb35ac6cc2d 100644 --- a/tests/baselines/reference/conditionalTypes2.js +++ b/tests/baselines/reference/conditionalTypes2.js @@ -188,6 +188,12 @@ type ProductComplementComplement = { }; type PCCA = ProductComplementComplement['a']; type PCCB = ProductComplementComplement['b']; + +// Repro from #31326 + +type Hmm = U extends T ? { [K in keyof U]: number } : never; +type What = Hmm<{}, { a: string }> +const w: What = { a: 4 }; //// [conditionalTypes2.js] @@ -265,6 +271,7 @@ function foo(value) { toString2(value); } } +var w = { a: 4 }; //// [conditionalTypes2.d.ts] @@ -392,3 +399,10 @@ declare type ProductComplementComplement = { }; declare type PCCA = ProductComplementComplement['a']; declare type PCCB = ProductComplementComplement['b']; +declare type Hmm = U extends T ? { + [K in keyof U]: number; +} : never; +declare type What = Hmm<{}, { + a: string; +}>; +declare const w: What; diff --git a/tests/baselines/reference/conditionalTypes2.symbols b/tests/baselines/reference/conditionalTypes2.symbols index b164d26e450..f665cbc3c71 100644 --- a/tests/baselines/reference/conditionalTypes2.symbols +++ b/tests/baselines/reference/conditionalTypes2.symbols @@ -685,3 +685,25 @@ type PCCB = ProductComplementComplement['b']; >PCCB : Symbol(PCCB, Decl(conditionalTypes2.ts, 187, 45)) >ProductComplementComplement : Symbol(ProductComplementComplement, Decl(conditionalTypes2.ts, 181, 34)) +// Repro from #31326 + +type Hmm = U extends T ? { [K in keyof U]: number } : never; +>Hmm : Symbol(Hmm, Decl(conditionalTypes2.ts, 188, 45)) +>T : Symbol(T, Decl(conditionalTypes2.ts, 192, 9)) +>U : Symbol(U, Decl(conditionalTypes2.ts, 192, 11)) +>T : Symbol(T, Decl(conditionalTypes2.ts, 192, 9)) +>U : Symbol(U, Decl(conditionalTypes2.ts, 192, 11)) +>T : Symbol(T, Decl(conditionalTypes2.ts, 192, 9)) +>K : Symbol(K, Decl(conditionalTypes2.ts, 192, 44)) +>U : Symbol(U, Decl(conditionalTypes2.ts, 192, 11)) + +type What = Hmm<{}, { a: string }> +>What : Symbol(What, Decl(conditionalTypes2.ts, 192, 76)) +>Hmm : Symbol(Hmm, Decl(conditionalTypes2.ts, 188, 45)) +>a : Symbol(a, Decl(conditionalTypes2.ts, 193, 21)) + +const w: What = { a: 4 }; +>w : Symbol(w, Decl(conditionalTypes2.ts, 194, 5)) +>What : Symbol(What, Decl(conditionalTypes2.ts, 192, 76)) +>a : Symbol(a, Decl(conditionalTypes2.ts, 194, 17)) + diff --git a/tests/baselines/reference/conditionalTypes2.types b/tests/baselines/reference/conditionalTypes2.types index aac6ba47475..e3d949f268e 100644 --- a/tests/baselines/reference/conditionalTypes2.types +++ b/tests/baselines/reference/conditionalTypes2.types @@ -431,3 +431,18 @@ type PCCA = ProductComplementComplement['a']; type PCCB = ProductComplementComplement['b']; >PCCB : Product<"b", 1> +// Repro from #31326 + +type Hmm = U extends T ? { [K in keyof U]: number } : never; +>Hmm : Hmm + +type What = Hmm<{}, { a: string }> +>What : { a: number; } +>a : string + +const w: What = { a: 4 }; +>w : { a: number; } +>{ a: 4 } : { a: number; } +>a : number +>4 : 4 + From d8f2702a5d67d39e5e7396f4914a191e210d4d30 Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Fri, 10 May 2019 11:48:44 -0700 Subject: [PATCH 043/119] Cache control flow results across invocations (#31003) * Modify flow loop cache key to include all inputs * Add test case, cache similarly to loop cache, reuse loop cache key (now corrected) * Use simpler singleton key and type cache for FlowAssignment nodes --- src/compiler/checker.ts | 43 +- src/compiler/types.ts | 2 + ...ryArithmeticControlFlowGraphNotTooLarge.js | 2562 +++ ...thmeticControlFlowGraphNotTooLarge.symbols | 7408 +++++++ ...rithmeticControlFlowGraphNotTooLarge.types | 16864 ++++++++++++++++ ...ryArithmeticControlFlowGraphNotTooLarge.ts | 1298 ++ 6 files changed, 28169 insertions(+), 8 deletions(-) create mode 100644 tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.js create mode 100644 tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.symbols create mode 100644 tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.types create mode 100644 tests/cases/compiler/binaryArithmeticControlFlowGraphNotTooLarge.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 764f926ecdb..a297646d887 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -559,6 +559,8 @@ namespace ts { const symbolLinks: SymbolLinks[] = []; const nodeLinks: NodeLinks[] = []; const flowLoopCaches: Map[] = []; + const flowAssignmentKeys: string[] = []; + const flowAssignmentTypes: FlowType[] = []; const flowLoopNodes: FlowNode[] = []; const flowLoopKeys: string[] = []; const flowLoopTypes: Type[][] = []; @@ -15666,21 +15668,21 @@ namespace ts { // The result is undefined if the reference isn't a dotted name. We prefix nodes // occurring in an apparent type position with '@' because the control flow type // of such nodes may be based on the apparent type instead of the declared type. - function getFlowCacheKey(node: Node): string | undefined { + function getFlowCacheKey(node: Node, declaredType: Type, initialType: Type, flowContainer: Node | undefined): string | undefined { switch (node.kind) { case SyntaxKind.Identifier: const symbol = getResolvedSymbol(node); - return symbol !== unknownSymbol ? (isConstraintPosition(node) ? "@" : "") + getSymbolId(symbol) : undefined; + return symbol !== unknownSymbol ? `${flowContainer ? getNodeId(flowContainer) : "-1"}|${getTypeId(declaredType)}|${getTypeId(initialType)}|${isConstraintPosition(node) ? "@" : ""}${getSymbolId(symbol)}` : undefined; case SyntaxKind.ThisKeyword: return "0"; case SyntaxKind.NonNullExpression: case SyntaxKind.ParenthesizedExpression: - return getFlowCacheKey((node).expression); + return getFlowCacheKey((node).expression, declaredType, initialType, flowContainer); case SyntaxKind.PropertyAccessExpression: case SyntaxKind.ElementAccessExpression: const propName = getAccessedPropertyName(node); if (propName !== undefined) { - const key = getFlowCacheKey((node).expression); + const key = getFlowCacheKey((node).expression, declaredType, initialType, flowContainer); return key && key + "." + propName; } } @@ -16345,6 +16347,7 @@ namespace ts { function getFlowTypeOfReference(reference: Node, declaredType: Type, initialType = declaredType, flowContainer?: Node, couldBeUninitialized?: boolean) { let key: string | undefined; + let keySet = false; let flowDepth = 0; if (flowAnalysisDisabled) { return errorType; @@ -16365,6 +16368,14 @@ namespace ts { } return resultType; + function getOrSetCacheKey() { + if (keySet) { + return key; + } + keySet = true; + return key = getFlowCacheKey(reference, declaredType, initialType, flowContainer); + } + function getTypeAtFlowNode(flow: FlowNode): FlowType { if (flowDepth === 2000) { // We have made 2000 recursive invocations. To avoid overflowing the call stack we report an error @@ -16376,6 +16387,15 @@ namespace ts { flowDepth++; while (true) { const flags = flow.flags; + if (flags & FlowFlags.Cached) { + const key = getOrSetCacheKey(); + if (key) { + const id = getFlowNodeId(flow); + if (flowAssignmentKeys[id] === key) { + return flowAssignmentTypes[id]; + } + } + } if (flags & FlowFlags.Shared) { // We cache results of flow type resolution for shared nodes that were previously visited in // the same getFlowTypeOfReference invocation. A node is considered shared when it is the @@ -16406,6 +16426,15 @@ namespace ts { flow = (flow).antecedent; continue; } + else if (flowLoopCount === flowLoopStart) { // Only cache assignments when not within loop analysis + const key = getOrSetCacheKey(); + if (key && !isIncomplete(type)) { + flow.flags |= FlowFlags.Cached; + const id = getFlowNodeId(flow); + flowAssignmentKeys[id] = key; + flowAssignmentTypes[id] = type; + } + } } else if (flags & FlowFlags.Condition) { type = getTypeAtFlowCondition(flow); @@ -16618,12 +16647,10 @@ namespace ts { // this flow loop junction, return the cached type. const id = getFlowNodeId(flow); const cache = flowLoopCaches[id] || (flowLoopCaches[id] = createMap()); + const key = getOrSetCacheKey(); if (!key) { - key = getFlowCacheKey(reference); // No cache key is generated when binding patterns are in unnarrowable situations - if (!key) { - return declaredType; - } + return declaredType; } const cached = cache.get(key); if (cached) { diff --git a/src/compiler/types.ts b/src/compiler/types.ts index 0e3ab5bec24..53b3d82bc27 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -2546,6 +2546,8 @@ namespace ts { Shared = 1 << 10, // Referenced as antecedent more than once PreFinally = 1 << 11, // Injected edge that links pre-finally label and pre-try flow AfterFinally = 1 << 12, // Injected edge that links post-finally flow with the rest of the graph + /** @internal */ + Cached = 1 << 13, // Indicates that at least one cross-call cache entry exists for this node, even if not a loop participant Label = BranchLabel | LoopLabel, Condition = TrueCondition | FalseCondition } diff --git a/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.js b/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.js new file mode 100644 index 00000000000..ab5cd46e599 --- /dev/null +++ b/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.js @@ -0,0 +1,2562 @@ +//// [binaryArithmeticControlFlowGraphNotTooLarge.ts] +// Repro from #29926 (expanded 10x for good measure) + +const foo = function (this: any) { + var a, b, c, d, ab, bc, cd, da, blocks = this.blocks; + + if (this.first) { + a = blocks[0] - 1; + a = (a << 3) | (a >>> 29); + d = ((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] + 271733878; + d = (d << 7) | (d >>> 25); + c = ((d & a) | (~d & 0xefcdab89)) + blocks[2] - 1732584194; + c = (c << 11) | (c >>> 21); + b = ((c & d) | (~c & a)) + blocks[3] - 271733879; + b = (b << 19) | (b >>> 13); + } else { + a = this.h0; + b = this.h1; + c = this.h2; + d = this.h3; + a += ((b & c) | (~b & d)) + blocks[0]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[1]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[2]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[3]; + b = (b << 19) | (b >>> 13); + } + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + if (this.first) { + this.h0 = a + 1732584193 << 0; + this.h1 = b - 271733879 << 0; + this.h2 = c - 1732584194 << 0; + this.h3 = d + 271733878 << 0; + this.first = false; + } else { + this.h0 = this.h0 + a << 0; + this.h1 = this.h1 + b << 0; + this.h2 = this.h2 + c << 0; + this.h3 = this.h3 + d << 0; + } +}; + +//// [binaryArithmeticControlFlowGraphNotTooLarge.js] +"use strict"; +// Repro from #29926 (expanded 10x for good measure) +var foo = function () { + var a, b, c, d, ab, bc, cd, da, blocks = this.blocks; + if (this.first) { + a = blocks[0] - 1; + a = (a << 3) | (a >>> 29); + d = ((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] + 271733878; + d = (d << 7) | (d >>> 25); + c = ((d & a) | (~d & 0xefcdab89)) + blocks[2] - 1732584194; + c = (c << 11) | (c >>> 21); + b = ((c & d) | (~c & a)) + blocks[3] - 271733879; + b = (b << 19) | (b >>> 13); + } + else { + a = this.h0; + b = this.h1; + c = this.h2; + d = this.h3; + a += ((b & c) | (~b & d)) + blocks[0]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[1]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[2]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[3]; + b = (b << 19) | (b >>> 13); + } + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + if (this.first) { + this.h0 = a + 1732584193 << 0; + this.h1 = b - 271733879 << 0; + this.h2 = c - 1732584194 << 0; + this.h3 = d + 271733878 << 0; + this.first = false; + } + else { + this.h0 = this.h0 + a << 0; + this.h1 = this.h1 + b << 0; + this.h2 = this.h2 + c << 0; + this.h3 = this.h3 + d << 0; + } +}; diff --git a/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.symbols b/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.symbols new file mode 100644 index 00000000000..66da14318d6 --- /dev/null +++ b/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.symbols @@ -0,0 +1,7408 @@ +=== tests/cases/compiler/binaryArithmeticControlFlowGraphNotTooLarge.ts === +// Repro from #29926 (expanded 10x for good measure) + +const foo = function (this: any) { +>foo : Symbol(foo, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 5)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + var a, b, c, d, ab, bc, cd, da, blocks = this.blocks; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + if (this.first) { +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + a = blocks[0] - 1; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d = ((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] + 271733878; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c = ((d & a) | (~d & 0xefcdab89)) + blocks[2] - 1732584194; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b = ((c & d) | (~c & a)) + blocks[3] - 271733879; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + } else { + a = this.h0; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + b = this.h1; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + c = this.h2; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + d = this.h3; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + a += ((b & c) | (~b & d)) + blocks[0]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[1]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[2]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[3]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + } + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[4]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[5]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[6]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[7]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[8]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[9]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[10]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[11]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + a += ((b & c) | (~b & d)) + blocks[12]; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += ((a & b) | (~a & c)) + blocks[13]; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 7) | (d >>> 25); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + c += ((d & a) | (~d & b)) + blocks[14]; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (~c & a)) + blocks[15]; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 19) | (b >>> 13); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + cd = c & d; +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b & c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>cd : Symbol(cd, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 27)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + ab = a & b; +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 5) | (d >>> 27); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d & a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>ab : Symbol(ab, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 19)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 9) | (c >>> 23); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 13) | (b >>> 19); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[0] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[8] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[4] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[12] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[2] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[10] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[6] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[14] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[1] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[9] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[5] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[13] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + bc = b ^ c; +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + a += (bc ^ d) + blocks[3] + 1859775393; +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + a = (a << 3) | (a >>> 29); +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + d += (bc ^ a) + blocks[11] + 1859775393; +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>bc : Symbol(bc, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 23)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + d = (d << 9) | (d >>> 23); +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + da = d ^ a; +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + c += (da ^ b) + blocks[7] + 1859775393; +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + c = (c << 11) | (c >>> 21); +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + b += (da ^ c) + blocks[15] + 1859775393; +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>da : Symbol(da, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 31)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) +>blocks : Symbol(blocks, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 35)) + + b = (b << 15) | (b >>> 17); +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + if (this.first) { +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + this.h0 = a + 1732584193 << 0; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + this.h1 = b - 271733879 << 0; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + this.h2 = c - 1732584194 << 0; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + this.h3 = d + 271733878 << 0; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + + this.first = false; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) + + } else { + this.h0 = this.h0 + a << 0; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>a : Symbol(a, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 7)) + + this.h1 = this.h1 + b << 0; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>b : Symbol(b, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 10)) + + this.h2 = this.h2 + c << 0; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>c : Symbol(c, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 13)) + + this.h3 = this.h3 + d << 0; +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>this : Symbol(this, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 2, 22)) +>d : Symbol(d, Decl(binaryArithmeticControlFlowGraphNotTooLarge.ts, 3, 16)) + } +}; diff --git a/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.types b/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.types new file mode 100644 index 00000000000..73618259b5b --- /dev/null +++ b/tests/baselines/reference/binaryArithmeticControlFlowGraphNotTooLarge.types @@ -0,0 +1,16864 @@ +=== tests/cases/compiler/binaryArithmeticControlFlowGraphNotTooLarge.ts === +// Repro from #29926 (expanded 10x for good measure) + +const foo = function (this: any) { +>foo : (this: any) => void +>function (this: any) { var a, b, c, d, ab, bc, cd, da, blocks = this.blocks; if (this.first) { a = blocks[0] - 1; a = (a << 3) | (a >>> 29); d = ((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] + 271733878; d = (d << 7) | (d >>> 25); c = ((d & a) | (~d & 0xefcdab89)) + blocks[2] - 1732584194; c = (c << 11) | (c >>> 21); b = ((c & d) | (~c & a)) + blocks[3] - 271733879; b = (b << 19) | (b >>> 13); } else { a = this.h0; b = this.h1; c = this.h2; d = this.h3; a += ((b & c) | (~b & d)) + blocks[0]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[1]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[2]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[3]; b = (b << 19) | (b >>> 13); } a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); a += ((b & c) | (~b & d)) + blocks[4]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[5]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[6]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[7]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[8]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[9]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[10]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[11]; b = (b << 19) | (b >>> 13); a += ((b & c) | (~b & d)) + blocks[12]; a = (a << 3) | (a >>> 29); d += ((a & b) | (~a & c)) + blocks[13]; d = (d << 7) | (d >>> 25); c += ((d & a) | (~d & b)) + blocks[14]; c = (c << 11) | (c >>> 21); b += ((c & d) | (~c & a)) + blocks[15]; b = (b << 19) | (b >>> 13); bc = b & c; a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[4] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[8] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[12] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[1] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[5] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[9] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[13] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[2] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[6] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[10] + 1518500249; c = (c << 9) | (c >>> 23); cd = c & d; b += (cd | (c & a) | da) + blocks[14] + 1518500249; b = (b << 13) | (b >>> 19); bc = b & c; a += (bc | (b & d) | cd) + blocks[3] + 1518500249; a = (a << 3) | (a >>> 29); ab = a & b; d += (ab | (a & c) | bc) + blocks[7] + 1518500249; d = (d << 5) | (d >>> 27); da = d & a; c += (da | (d & b) | ab) + blocks[11] + 1518500249; c = (c << 9) | (c >>> 23); b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; b = (b << 13) | (b >>> 19); bc = b ^ c; a += (bc ^ d) + blocks[0] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[8] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[4] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[12] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[2] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[10] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[6] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[14] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[1] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[9] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[5] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[13] + 1859775393; b = (b << 15) | (b >>> 17); bc = b ^ c; a += (bc ^ d) + blocks[3] + 1859775393; a = (a << 3) | (a >>> 29); d += (bc ^ a) + blocks[11] + 1859775393; d = (d << 9) | (d >>> 23); da = d ^ a; c += (da ^ b) + blocks[7] + 1859775393; c = (c << 11) | (c >>> 21); b += (da ^ c) + blocks[15] + 1859775393; b = (b << 15) | (b >>> 17); if (this.first) { this.h0 = a + 1732584193 << 0; this.h1 = b - 271733879 << 0; this.h2 = c - 1732584194 << 0; this.h3 = d + 271733878 << 0; this.first = false; } else { this.h0 = this.h0 + a << 0; this.h1 = this.h1 + b << 0; this.h2 = this.h2 + c << 0; this.h3 = this.h3 + d << 0; }} : (this: any) => void +>this : any + + var a, b, c, d, ab, bc, cd, da, blocks = this.blocks; +>a : any +>b : any +>c : any +>d : any +>ab : any +>bc : any +>cd : any +>da : any +>blocks : any +>this.blocks : any +>this : any +>blocks : any + + if (this.first) { +>this.first : any +>this : any +>first : any + + a = blocks[0] - 1; +>a = blocks[0] - 1 : number +>a : any +>blocks[0] - 1 : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1 : 1 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d = ((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] + 271733878; +>d = ((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] + 271733878 : any +>d : any +>((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] + 271733878 : any +>((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] : any +>((a & 0xefcdab89) | (~a & 0x98badcfe)) : number +>(a & 0xefcdab89) | (~a & 0x98badcfe) : number +>(a & 0xefcdab89) : number +>a & 0xefcdab89 : number +>a : number +>0xefcdab89 : 4023233417 +>(~a & 0x98badcfe) : number +>~a & 0x98badcfe : number +>~a : number +>a : number +>0x98badcfe : 2562383102 +>blocks[1] : any +>blocks : any +>1 : 1 +>271733878 : 271733878 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : any +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : any +>25 : 25 + + c = ((d & a) | (~d & 0xefcdab89)) + blocks[2] - 1732584194; +>c = ((d & a) | (~d & 0xefcdab89)) + blocks[2] - 1732584194 : number +>c : any +>((d & a) | (~d & 0xefcdab89)) + blocks[2] - 1732584194 : number +>((d & a) | (~d & 0xefcdab89)) + blocks[2] : any +>((d & a) | (~d & 0xefcdab89)) : number +>(d & a) | (~d & 0xefcdab89) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & 0xefcdab89) : number +>~d & 0xefcdab89 : number +>~d : number +>d : number +>0xefcdab89 : 4023233417 +>blocks[2] : any +>blocks : any +>2 : 2 +>1732584194 : 1732584194 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b = ((c & d) | (~c & a)) + blocks[3] - 271733879; +>b = ((c & d) | (~c & a)) + blocks[3] - 271733879 : number +>b : any +>((c & d) | (~c & a)) + blocks[3] - 271733879 : number +>((c & d) | (~c & a)) + blocks[3] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[3] : any +>blocks : any +>3 : 3 +>271733879 : 271733879 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + } else { + a = this.h0; +>a = this.h0 : any +>a : any +>this.h0 : any +>this : any +>h0 : any + + b = this.h1; +>b = this.h1 : any +>b : any +>this.h1 : any +>this : any +>h1 : any + + c = this.h2; +>c = this.h2 : any +>c : any +>this.h2 : any +>this : any +>h2 : any + + d = this.h3; +>d = this.h3 : any +>d : any +>this.h3 : any +>this : any +>h3 : any + + a += ((b & c) | (~b & d)) + blocks[0]; +>a += ((b & c) | (~b & d)) + blocks[0] : any +>a : any +>((b & c) | (~b & d)) + blocks[0] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : any +>c : any +>(~b & d) : number +>~b & d : number +>~b : number +>b : any +>d : any +>blocks[0] : any +>blocks : any +>0 : 0 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : any +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : any +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[1]; +>d += ((a & b) | (~a & c)) + blocks[1] : any +>d : any +>((a & b) | (~a & c)) + blocks[1] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : any +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : any +>blocks[1] : any +>blocks : any +>1 : 1 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : any +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : any +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[2]; +>c += ((d & a) | (~d & b)) + blocks[2] : any +>c : any +>((d & a) | (~d & b)) + blocks[2] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : any +>blocks[2] : any +>blocks : any +>2 : 2 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : any +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : any +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[3]; +>b += ((c & d) | (~c & a)) + blocks[3] : any +>b : any +>((c & d) | (~c & a)) + blocks[3] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[3] : any +>blocks : any +>3 : 3 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : any +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : any +>13 : 13 + } + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + a += ((b & c) | (~b & d)) + blocks[4]; +>a += ((b & c) | (~b & d)) + blocks[4] : any +>a : number +>((b & c) | (~b & d)) + blocks[4] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[4] : any +>blocks : any +>4 : 4 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[5]; +>d += ((a & b) | (~a & c)) + blocks[5] : any +>d : number +>((a & b) | (~a & c)) + blocks[5] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[5] : any +>blocks : any +>5 : 5 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[6]; +>c += ((d & a) | (~d & b)) + blocks[6] : any +>c : number +>((d & a) | (~d & b)) + blocks[6] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[7]; +>b += ((c & d) | (~c & a)) + blocks[7] : any +>b : number +>((c & d) | (~c & a)) + blocks[7] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[7] : any +>blocks : any +>7 : 7 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[8]; +>a += ((b & c) | (~b & d)) + blocks[8] : any +>a : number +>((b & c) | (~b & d)) + blocks[8] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[8] : any +>blocks : any +>8 : 8 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[9]; +>d += ((a & b) | (~a & c)) + blocks[9] : any +>d : number +>((a & b) | (~a & c)) + blocks[9] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[9] : any +>blocks : any +>9 : 9 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[10]; +>c += ((d & a) | (~d & b)) + blocks[10] : any +>c : number +>((d & a) | (~d & b)) + blocks[10] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[10] : any +>blocks : any +>10 : 10 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[11]; +>b += ((c & d) | (~c & a)) + blocks[11] : any +>b : number +>((c & d) | (~c & a)) + blocks[11] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + a += ((b & c) | (~b & d)) + blocks[12]; +>a += ((b & c) | (~b & d)) + blocks[12] : any +>a : number +>((b & c) | (~b & d)) + blocks[12] : any +>((b & c) | (~b & d)) : number +>(b & c) | (~b & d) : number +>(b & c) : number +>b & c : number +>b : number +>c : number +>(~b & d) : number +>~b & d : number +>~b : number +>b : number +>d : number +>blocks[12] : any +>blocks : any +>12 : 12 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += ((a & b) | (~a & c)) + blocks[13]; +>d += ((a & b) | (~a & c)) + blocks[13] : any +>d : number +>((a & b) | (~a & c)) + blocks[13] : any +>((a & b) | (~a & c)) : number +>(a & b) | (~a & c) : number +>(a & b) : number +>a & b : number +>a : number +>b : number +>(~a & c) : number +>~a & c : number +>~a : number +>a : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 + + d = (d << 7) | (d >>> 25); +>d = (d << 7) | (d >>> 25) : number +>d : any +>(d << 7) | (d >>> 25) : number +>(d << 7) : number +>d << 7 : number +>d : number +>7 : 7 +>(d >>> 25) : number +>d >>> 25 : number +>d : number +>25 : 25 + + c += ((d & a) | (~d & b)) + blocks[14]; +>c += ((d & a) | (~d & b)) + blocks[14] : any +>c : number +>((d & a) | (~d & b)) + blocks[14] : any +>((d & a) | (~d & b)) : number +>(d & a) | (~d & b) : number +>(d & a) : number +>d & a : number +>d : number +>a : number +>(~d & b) : number +>~d & b : number +>~d : number +>d : number +>b : number +>blocks[14] : any +>blocks : any +>14 : 14 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += ((c & d) | (~c & a)) + blocks[15]; +>b += ((c & d) | (~c & a)) + blocks[15] : any +>b : number +>((c & d) | (~c & a)) + blocks[15] : any +>((c & d) | (~c & a)) : number +>(c & d) | (~c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(~c & a) : number +>~c & a : number +>~c : number +>c : number +>a : number +>blocks[15] : any +>blocks : any +>15 : 15 + + b = (b << 19) | (b >>> 13); +>b = (b << 19) | (b >>> 13) : number +>b : any +>(b << 19) | (b >>> 13) : number +>(b << 19) : number +>b << 19 : number +>b : number +>19 : 19 +>(b >>> 13) : number +>b >>> 13 : number +>b : number +>13 : 13 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; +>a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>a : number +>(bc | (b & d) | (c & d)) + blocks[0] + 1518500249 : any +>(bc | (b & d) | (c & d)) + blocks[0] : any +>(bc | (b & d) | (c & d)) : number +>bc | (b & d) | (c & d) : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[4] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[4] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[8] + 1518500249; +>c += (da | (d & b) | ab) + blocks[8] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[8] + 1518500249 : any +>(da | (d & b) | ab) + blocks[8] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[12] + 1518500249; +>b += (cd | (c & a) | da) + blocks[12] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[12] + 1518500249 : any +>(cd | (c & a) | da) + blocks[12] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[1] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[1] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[5] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[5] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[9] + 1518500249; +>c += (da | (d & b) | ab) + blocks[9] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[9] + 1518500249 : any +>(da | (d & b) | ab) + blocks[9] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[13] + 1518500249; +>b += (cd | (c & a) | da) + blocks[13] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[13] + 1518500249 : any +>(cd | (c & a) | da) + blocks[13] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[2] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[2] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[6] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[6] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[10] + 1518500249; +>c += (da | (d & b) | ab) + blocks[10] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[10] + 1518500249 : any +>(da | (d & b) | ab) + blocks[10] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + cd = c & d; +>cd = c & d : number +>cd : any +>c & d : number +>c : number +>d : number + + b += (cd | (c & a) | da) + blocks[14] + 1518500249; +>b += (cd | (c & a) | da) + blocks[14] + 1518500249 : any +>b : number +>(cd | (c & a) | da) + blocks[14] + 1518500249 : any +>(cd | (c & a) | da) + blocks[14] : any +>(cd | (c & a) | da) : number +>cd | (c & a) | da : number +>cd | (c & a) : number +>cd : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b & c; +>bc = b & c : number +>bc : any +>b & c : number +>b : number +>c : number + + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; +>a += (bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>a : number +>(bc | (b & d) | cd) + blocks[3] + 1518500249 : any +>(bc | (b & d) | cd) + blocks[3] : any +>(bc | (b & d) | cd) : number +>bc | (b & d) | cd : number +>bc | (b & d) : number +>bc : number +>(b & d) : number +>b & d : number +>b : number +>d : number +>cd : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1518500249 : 1518500249 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + ab = a & b; +>ab = a & b : number +>ab : any +>a & b : number +>a : number +>b : number + + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; +>d += (ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>d : number +>(ab | (a & c) | bc) + blocks[7] + 1518500249 : any +>(ab | (a & c) | bc) + blocks[7] : any +>(ab | (a & c) | bc) : number +>ab | (a & c) | bc : number +>ab | (a & c) : number +>ab : number +>(a & c) : number +>a & c : number +>a : number +>c : number +>bc : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1518500249 : 1518500249 + + d = (d << 5) | (d >>> 27); +>d = (d << 5) | (d >>> 27) : number +>d : any +>(d << 5) | (d >>> 27) : number +>(d << 5) : number +>d << 5 : number +>d : number +>5 : 5 +>(d >>> 27) : number +>d >>> 27 : number +>d : number +>27 : 27 + + da = d & a; +>da = d & a : number +>da : any +>d & a : number +>d : number +>a : number + + c += (da | (d & b) | ab) + blocks[11] + 1518500249; +>c += (da | (d & b) | ab) + blocks[11] + 1518500249 : any +>c : number +>(da | (d & b) | ab) + blocks[11] + 1518500249 : any +>(da | (d & b) | ab) + blocks[11] : any +>(da | (d & b) | ab) : number +>da | (d & b) | ab : number +>da | (d & b) : number +>da : number +>(d & b) : number +>d & b : number +>d : number +>b : number +>ab : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1518500249 : 1518500249 + + c = (c << 9) | (c >>> 23); +>c = (c << 9) | (c >>> 23) : number +>c : any +>(c << 9) | (c >>> 23) : number +>(c << 9) : number +>c << 9 : number +>c : number +>9 : 9 +>(c >>> 23) : number +>c >>> 23 : number +>c : number +>23 : 23 + + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; +>b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>b : number +>((c & d) | (c & a) | da) + blocks[15] + 1518500249 : any +>((c & d) | (c & a) | da) + blocks[15] : any +>((c & d) | (c & a) | da) : number +>(c & d) | (c & a) | da : number +>(c & d) | (c & a) : number +>(c & d) : number +>c & d : number +>c : number +>d : number +>(c & a) : number +>c & a : number +>c : number +>a : number +>da : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1518500249 : 1518500249 + + b = (b << 13) | (b >>> 19); +>b = (b << 13) | (b >>> 19) : number +>b : any +>(b << 13) | (b >>> 19) : number +>(b << 13) : number +>b << 13 : number +>b : number +>13 : 13 +>(b >>> 19) : number +>b >>> 19 : number +>b : number +>19 : 19 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[0] + 1859775393; +>a += (bc ^ d) + blocks[0] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[0] + 1859775393 : any +>(bc ^ d) + blocks[0] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[0] : any +>blocks : any +>0 : 0 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[8] + 1859775393; +>d += (bc ^ a) + blocks[8] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[8] + 1859775393 : any +>(bc ^ a) + blocks[8] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[8] : any +>blocks : any +>8 : 8 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[4] + 1859775393; +>c += (da ^ b) + blocks[4] + 1859775393 : any +>c : number +>(da ^ b) + blocks[4] + 1859775393 : any +>(da ^ b) + blocks[4] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[4] : any +>blocks : any +>4 : 4 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[12] + 1859775393; +>b += (da ^ c) + blocks[12] + 1859775393 : any +>b : number +>(da ^ c) + blocks[12] + 1859775393 : any +>(da ^ c) + blocks[12] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[12] : any +>blocks : any +>12 : 12 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[2] + 1859775393; +>a += (bc ^ d) + blocks[2] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[2] + 1859775393 : any +>(bc ^ d) + blocks[2] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[2] : any +>blocks : any +>2 : 2 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[10] + 1859775393; +>d += (bc ^ a) + blocks[10] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[10] + 1859775393 : any +>(bc ^ a) + blocks[10] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[10] : any +>blocks : any +>10 : 10 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[6] + 1859775393; +>c += (da ^ b) + blocks[6] + 1859775393 : any +>c : number +>(da ^ b) + blocks[6] + 1859775393 : any +>(da ^ b) + blocks[6] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[6] : any +>blocks : any +>6 : 6 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[14] + 1859775393; +>b += (da ^ c) + blocks[14] + 1859775393 : any +>b : number +>(da ^ c) + blocks[14] + 1859775393 : any +>(da ^ c) + blocks[14] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[14] : any +>blocks : any +>14 : 14 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[1] + 1859775393; +>a += (bc ^ d) + blocks[1] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[1] + 1859775393 : any +>(bc ^ d) + blocks[1] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[1] : any +>blocks : any +>1 : 1 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[9] + 1859775393; +>d += (bc ^ a) + blocks[9] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[9] + 1859775393 : any +>(bc ^ a) + blocks[9] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[9] : any +>blocks : any +>9 : 9 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[5] + 1859775393; +>c += (da ^ b) + blocks[5] + 1859775393 : any +>c : number +>(da ^ b) + blocks[5] + 1859775393 : any +>(da ^ b) + blocks[5] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[5] : any +>blocks : any +>5 : 5 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[13] + 1859775393; +>b += (da ^ c) + blocks[13] + 1859775393 : any +>b : number +>(da ^ c) + blocks[13] + 1859775393 : any +>(da ^ c) + blocks[13] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[13] : any +>blocks : any +>13 : 13 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + bc = b ^ c; +>bc = b ^ c : number +>bc : any +>b ^ c : number +>b : number +>c : number + + a += (bc ^ d) + blocks[3] + 1859775393; +>a += (bc ^ d) + blocks[3] + 1859775393 : any +>a : number +>(bc ^ d) + blocks[3] + 1859775393 : any +>(bc ^ d) + blocks[3] : any +>(bc ^ d) : number +>bc ^ d : number +>bc : number +>d : number +>blocks[3] : any +>blocks : any +>3 : 3 +>1859775393 : 1859775393 + + a = (a << 3) | (a >>> 29); +>a = (a << 3) | (a >>> 29) : number +>a : any +>(a << 3) | (a >>> 29) : number +>(a << 3) : number +>a << 3 : number +>a : number +>3 : 3 +>(a >>> 29) : number +>a >>> 29 : number +>a : number +>29 : 29 + + d += (bc ^ a) + blocks[11] + 1859775393; +>d += (bc ^ a) + blocks[11] + 1859775393 : any +>d : number +>(bc ^ a) + blocks[11] + 1859775393 : any +>(bc ^ a) + blocks[11] : any +>(bc ^ a) : number +>bc ^ a : number +>bc : number +>a : number +>blocks[11] : any +>blocks : any +>11 : 11 +>1859775393 : 1859775393 + + d = (d << 9) | (d >>> 23); +>d = (d << 9) | (d >>> 23) : number +>d : any +>(d << 9) | (d >>> 23) : number +>(d << 9) : number +>d << 9 : number +>d : number +>9 : 9 +>(d >>> 23) : number +>d >>> 23 : number +>d : number +>23 : 23 + + da = d ^ a; +>da = d ^ a : number +>da : any +>d ^ a : number +>d : number +>a : number + + c += (da ^ b) + blocks[7] + 1859775393; +>c += (da ^ b) + blocks[7] + 1859775393 : any +>c : number +>(da ^ b) + blocks[7] + 1859775393 : any +>(da ^ b) + blocks[7] : any +>(da ^ b) : number +>da ^ b : number +>da : number +>b : number +>blocks[7] : any +>blocks : any +>7 : 7 +>1859775393 : 1859775393 + + c = (c << 11) | (c >>> 21); +>c = (c << 11) | (c >>> 21) : number +>c : any +>(c << 11) | (c >>> 21) : number +>(c << 11) : number +>c << 11 : number +>c : number +>11 : 11 +>(c >>> 21) : number +>c >>> 21 : number +>c : number +>21 : 21 + + b += (da ^ c) + blocks[15] + 1859775393; +>b += (da ^ c) + blocks[15] + 1859775393 : any +>b : number +>(da ^ c) + blocks[15] + 1859775393 : any +>(da ^ c) + blocks[15] : any +>(da ^ c) : number +>da ^ c : number +>da : number +>c : number +>blocks[15] : any +>blocks : any +>15 : 15 +>1859775393 : 1859775393 + + b = (b << 15) | (b >>> 17); +>b = (b << 15) | (b >>> 17) : number +>b : any +>(b << 15) | (b >>> 17) : number +>(b << 15) : number +>b << 15 : number +>b : number +>15 : 15 +>(b >>> 17) : number +>b >>> 17 : number +>b : number +>17 : 17 + + if (this.first) { +>this.first : any +>this : any +>first : any + + this.h0 = a + 1732584193 << 0; +>this.h0 = a + 1732584193 << 0 : number +>this.h0 : any +>this : any +>h0 : any +>a + 1732584193 << 0 : number +>a + 1732584193 : number +>a : number +>1732584193 : 1732584193 +>0 : 0 + + this.h1 = b - 271733879 << 0; +>this.h1 = b - 271733879 << 0 : number +>this.h1 : any +>this : any +>h1 : any +>b - 271733879 << 0 : number +>b - 271733879 : number +>b : number +>271733879 : 271733879 +>0 : 0 + + this.h2 = c - 1732584194 << 0; +>this.h2 = c - 1732584194 << 0 : number +>this.h2 : any +>this : any +>h2 : any +>c - 1732584194 << 0 : number +>c - 1732584194 : number +>c : number +>1732584194 : 1732584194 +>0 : 0 + + this.h3 = d + 271733878 << 0; +>this.h3 = d + 271733878 << 0 : number +>this.h3 : any +>this : any +>h3 : any +>d + 271733878 << 0 : number +>d + 271733878 : number +>d : number +>271733878 : 271733878 +>0 : 0 + + this.first = false; +>this.first = false : false +>this.first : any +>this : any +>first : any +>false : false + + } else { + this.h0 = this.h0 + a << 0; +>this.h0 = this.h0 + a << 0 : number +>this.h0 : any +>this : any +>h0 : any +>this.h0 + a << 0 : number +>this.h0 + a : any +>this.h0 : any +>this : any +>h0 : any +>a : number +>0 : 0 + + this.h1 = this.h1 + b << 0; +>this.h1 = this.h1 + b << 0 : number +>this.h1 : any +>this : any +>h1 : any +>this.h1 + b << 0 : number +>this.h1 + b : any +>this.h1 : any +>this : any +>h1 : any +>b : number +>0 : 0 + + this.h2 = this.h2 + c << 0; +>this.h2 = this.h2 + c << 0 : number +>this.h2 : any +>this : any +>h2 : any +>this.h2 + c << 0 : number +>this.h2 + c : any +>this.h2 : any +>this : any +>h2 : any +>c : number +>0 : 0 + + this.h3 = this.h3 + d << 0; +>this.h3 = this.h3 + d << 0 : number +>this.h3 : any +>this : any +>h3 : any +>this.h3 + d << 0 : number +>this.h3 + d : any +>this.h3 : any +>this : any +>h3 : any +>d : number +>0 : 0 + } +}; diff --git a/tests/cases/compiler/binaryArithmeticControlFlowGraphNotTooLarge.ts b/tests/cases/compiler/binaryArithmeticControlFlowGraphNotTooLarge.ts new file mode 100644 index 00000000000..9368fc4c34e --- /dev/null +++ b/tests/cases/compiler/binaryArithmeticControlFlowGraphNotTooLarge.ts @@ -0,0 +1,1298 @@ +// @strict: true + +// Repro from #29926 (expanded 10x for good measure) + +const foo = function (this: any) { + var a, b, c, d, ab, bc, cd, da, blocks = this.blocks; + + if (this.first) { + a = blocks[0] - 1; + a = (a << 3) | (a >>> 29); + d = ((a & 0xefcdab89) | (~a & 0x98badcfe)) + blocks[1] + 271733878; + d = (d << 7) | (d >>> 25); + c = ((d & a) | (~d & 0xefcdab89)) + blocks[2] - 1732584194; + c = (c << 11) | (c >>> 21); + b = ((c & d) | (~c & a)) + blocks[3] - 271733879; + b = (b << 19) | (b >>> 13); + } else { + a = this.h0; + b = this.h1; + c = this.h2; + d = this.h3; + a += ((b & c) | (~b & d)) + blocks[0]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[1]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[2]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[3]; + b = (b << 19) | (b >>> 13); + } + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + a += ((b & c) | (~b & d)) + blocks[4]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[5]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[6]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[7]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[8]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[9]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[10]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[11]; + b = (b << 19) | (b >>> 13); + a += ((b & c) | (~b & d)) + blocks[12]; + a = (a << 3) | (a >>> 29); + d += ((a & b) | (~a & c)) + blocks[13]; + d = (d << 7) | (d >>> 25); + c += ((d & a) | (~d & b)) + blocks[14]; + c = (c << 11) | (c >>> 21); + b += ((c & d) | (~c & a)) + blocks[15]; + b = (b << 19) | (b >>> 13); + + bc = b & c; + a += (bc | (b & d) | (c & d)) + blocks[0] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[4] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[8] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[12] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[1] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[5] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[9] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[13] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[2] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[6] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[10] + 1518500249; + c = (c << 9) | (c >>> 23); + cd = c & d; + b += (cd | (c & a) | da) + blocks[14] + 1518500249; + b = (b << 13) | (b >>> 19); + bc = b & c; + a += (bc | (b & d) | cd) + blocks[3] + 1518500249; + a = (a << 3) | (a >>> 29); + ab = a & b; + d += (ab | (a & c) | bc) + blocks[7] + 1518500249; + d = (d << 5) | (d >>> 27); + da = d & a; + c += (da | (d & b) | ab) + blocks[11] + 1518500249; + c = (c << 9) | (c >>> 23); + b += ((c & d) | (c & a) | da) + blocks[15] + 1518500249; + b = (b << 13) | (b >>> 19); + + bc = b ^ c; + a += (bc ^ d) + blocks[0] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[8] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[4] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[12] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[2] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[10] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[6] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[14] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[1] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[9] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[5] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[13] + 1859775393; + b = (b << 15) | (b >>> 17); + bc = b ^ c; + a += (bc ^ d) + blocks[3] + 1859775393; + a = (a << 3) | (a >>> 29); + d += (bc ^ a) + blocks[11] + 1859775393; + d = (d << 9) | (d >>> 23); + da = d ^ a; + c += (da ^ b) + blocks[7] + 1859775393; + c = (c << 11) | (c >>> 21); + b += (da ^ c) + blocks[15] + 1859775393; + b = (b << 15) | (b >>> 17); + + if (this.first) { + this.h0 = a + 1732584193 << 0; + this.h1 = b - 271733879 << 0; + this.h2 = c - 1732584194 << 0; + this.h3 = d + 271733878 << 0; + this.first = false; + } else { + this.h0 = this.h0 + a << 0; + this.h1 = this.h1 + b << 0; + this.h2 = this.h2 + c << 0; + this.h3 = this.h3 + d << 0; + } +}; \ No newline at end of file From 71fe8e824e30b9bb71d9e2b3f0cc5f6b0199bcb6 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Sat, 11 May 2019 09:39:06 -0700 Subject: [PATCH 044/119] Defer resolution of the true and false branches of conditional types --- src/compiler/checker.ts | 69 ++++++++++++++++++----------------------- src/compiler/types.ts | 4 +-- 2 files changed, 32 insertions(+), 41 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index cc4c8476de6..5d3bc864a50 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -394,7 +394,6 @@ namespace ts { const intersectionTypes = createMap(); const literalTypes = createMap(); const indexedAccessTypes = createMap(); - const conditionalTypes = createMap(); const substitutionTypes = createMap(); const evolvingArrayTypes: EvolvingArrayType[] = []; const undefinedProperties = createMap() as UnderscoreEscapedMap; @@ -3648,8 +3647,8 @@ namespace ts { context.inferTypeParameters = (type).root.inferTypeParameters; const extendsTypeNode = typeToTypeNodeHelper((type).extendsType, context); context.inferTypeParameters = saveInferTypeParameters; - const trueTypeNode = typeToTypeNodeHelper((type).trueType, context); - const falseTypeNode = typeToTypeNodeHelper((type).falseType, context); + const trueTypeNode = typeToTypeNodeHelper(getTrueTypeFromConditionalType(type), context); + const falseTypeNode = typeToTypeNodeHelper(getFalseTypeFromConditionalType(type), context); context.approximateLength += 15; return createConditionalTypeNode(checkTypeNode, extendsTypeNode, trueTypeNode, falseTypeNode); } @@ -7674,7 +7673,7 @@ namespace ts { // just `any`. This result is _usually_ unwanted - so instead here we elide an `any` branch from the constraint type, // in effect treating `any` like `never` rather than `unknown` in this location. const trueConstraint = getInferredTrueTypeFromConditionalType(type); - const falseConstraint = type.falseType; + const falseConstraint = getFalseTypeFromConditionalType(type); type.resolvedDefaultConstraint = isTypeAny(trueConstraint) ? falseConstraint : isTypeAny(falseConstraint) ? trueConstraint : getUnionType([trueConstraint, falseConstraint]); } return type.resolvedDefaultConstraint; @@ -10377,37 +10376,23 @@ namespace ts { if (checkType === wildcardType || extendsType === wildcardType) { return wildcardType; } - const trueType = instantiateType(root.trueType, mapper); - const falseType = instantiateType(root.falseType, mapper); - const instantiationId = `${root.isDistributive ? "d" : ""}${getTypeId(checkType)}>${getTypeId(extendsType)}?${getTypeId(trueType)}:${getTypeId(falseType)}`; - const result = conditionalTypes.get(instantiationId); - if (result) { - return result; - } - const newResult = getConditionalTypeWorker(root, mapper, checkType, extendsType, trueType, falseType); - conditionalTypes.set(instantiationId, newResult); - return newResult; - } - - function getConditionalTypeWorker(root: ConditionalRoot, mapper: TypeMapper | undefined, checkType: Type, extendsType: Type, trueType: Type, falseType: Type) { // Simplifications for types of the form `T extends U ? T : never` and `T extends U ? never : T`. - if (falseType.flags & TypeFlags.Never && getActualTypeVariable(trueType) === getActualTypeVariable(checkType)) { + if (root.falseType.flags & TypeFlags.Never && getActualTypeVariable(root.trueType) === getActualTypeVariable(root.checkType)) { if (checkType.flags & TypeFlags.Any || isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(extendsType))) { // Always true - return trueType; + return instantiateType(root.trueType, mapper); } else if (isIntersectionEmpty(checkType, extendsType)) { // Always false return neverType; } } - else if (trueType.flags & TypeFlags.Never && getActualTypeVariable(falseType) === getActualTypeVariable(checkType)) { + else if (root.trueType.flags & TypeFlags.Never && getActualTypeVariable(root.falseType) === getActualTypeVariable(root.checkType)) { if (!(checkType.flags & TypeFlags.Any) && isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(extendsType))) { // Always true return neverType; } else if (checkType.flags & TypeFlags.Any || isIntersectionEmpty(checkType, extendsType)) { // Always false - return falseType; + return instantiateType(root.falseType, mapper); } } - const checkTypeInstantiable = maybeTypeOfKind(checkType, TypeFlags.Instantiable | TypeFlags.GenericMappedType); let combinedMapper: TypeMapper | undefined; if (root.inferTypeParameters) { @@ -10425,18 +10410,18 @@ namespace ts { // We attempt to resolve the conditional type only when the check and extends types are non-generic if (!checkTypeInstantiable && !maybeTypeOfKind(inferredExtendsType, TypeFlags.Instantiable | TypeFlags.GenericMappedType)) { if (inferredExtendsType.flags & TypeFlags.AnyOrUnknown) { - return combinedMapper ? instantiateType(root.trueType, combinedMapper) : trueType; + return instantiateType(root.trueType, combinedMapper || mapper); } // Return union of trueType and falseType for 'any' since it matches anything if (checkType.flags & TypeFlags.Any) { - return getUnionType([combinedMapper ? instantiateType(root.trueType, combinedMapper) : trueType, falseType]); + return getUnionType([instantiateType(root.trueType, combinedMapper || mapper), instantiateType(root.falseType, mapper)]); } // Return falseType for a definitely false extends check. We check an instantiations of the two // types with type parameters mapped to the wildcard type, the most permissive instantiations // possible (the wildcard type is assignable to and from all types). If those are not related, // then no instantiations will be and we can just return the false branch type. if (!isTypeAssignableTo(getPermissiveInstantiation(checkType), getPermissiveInstantiation(inferredExtendsType))) { - return falseType; + return instantiateType(root.falseType, mapper); } // Return trueType for a definitely true extends check. We check instantiations of the two // types with type parameters mapped to their restrictive form, i.e. a form of the type parameter @@ -10444,14 +10429,14 @@ namespace ts { // type Foo = T extends { x: string } ? string : number // doesn't immediately resolve to 'string' instead of being deferred. if (isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(inferredExtendsType))) { - return combinedMapper ? instantiateType(root.trueType, combinedMapper) : trueType; + return instantiateType(root.trueType, combinedMapper || mapper); } } // Return a deferred type for a check that is neither definitely true nor definitely false - return getDeferredConditionalType(root, mapper, combinedMapper, checkType, extendsType, trueType, falseType); + return getDeferredConditionalType(root, mapper, combinedMapper, checkType, extendsType); } - function getDeferredConditionalType(root: ConditionalRoot, mapper: TypeMapper | undefined, combinedMapper: TypeMapper | undefined, checkType: Type, extendsType: Type, trueType: Type, falseType: Type) { + function getDeferredConditionalType(root: ConditionalRoot, mapper: TypeMapper | undefined, combinedMapper: TypeMapper | undefined, checkType: Type, extendsType: Type) { const erasedCheckType = getActualTypeVariable(checkType); const result = createType(TypeFlags.Conditional); result.root = root; @@ -10459,15 +10444,21 @@ namespace ts { result.extendsType = extendsType; result.mapper = mapper; result.combinedMapper = combinedMapper; - result.trueType = trueType; - result.falseType = falseType; result.aliasSymbol = root.aliasSymbol; result.aliasTypeArguments = instantiateTypes(root.aliasTypeArguments, mapper!); // TODO: GH#18217 return result; } + function getTrueTypeFromConditionalType(type: ConditionalType) { + return type.resolvedTrueType || (type.resolvedTrueType = instantiateType(type.root.trueType, type.mapper)); + } + + function getFalseTypeFromConditionalType(type: ConditionalType) { + return type.resolvedFalseType || (type.resolvedFalseType = instantiateType(type.root.falseType, type.mapper)); + } + function getInferredTrueTypeFromConditionalType(type: ConditionalType) { - return type.resolvedInferredTrueType || (type.resolvedInferredTrueType = instantiateType(type.root.trueType, type.combinedMapper || type.mapper)); + return type.resolvedInferredTrueType || (type.resolvedInferredTrueType = type.combinedMapper ? instantiateType(type.root.trueType, type.combinedMapper) : getTrueTypeFromConditionalType(type)); } function getInferTypeParameters(node: ConditionalTypeNode): TypeParameter[] | undefined { @@ -12987,8 +12978,8 @@ namespace ts { if ((source).root.isDistributive === (target).root.isDistributive) { if (result = isRelatedTo((source).checkType, (target).checkType, /*reportErrors*/ false)) { if (result &= isRelatedTo((source).extendsType, (target).extendsType, /*reportErrors*/ false)) { - if (result &= isRelatedTo((source).trueType, (target).trueType, /*reportErrors*/ false)) { - if (result &= isRelatedTo((source).falseType, (target).falseType, /*reportErrors*/ false)) { + if (result &= isRelatedTo(getTrueTypeFromConditionalType(source), getTrueTypeFromConditionalType(target), /*reportErrors*/ false)) { + if (result &= isRelatedTo(getFalseTypeFromConditionalType(source), getFalseTypeFromConditionalType(target), /*reportErrors*/ false)) { return result; } } @@ -13147,8 +13138,8 @@ namespace ts { // and Y1 is related to Y2. if (isTypeIdenticalTo((source).extendsType, (target).extendsType) && (isRelatedTo((source).checkType, (target).checkType) || isRelatedTo((target).checkType, (source).checkType))) { - if (result = isRelatedTo((source).trueType, (target).trueType, reportErrors)) { - result &= isRelatedTo((source).falseType, (target).falseType, reportErrors); + if (result = isRelatedTo(getTrueTypeFromConditionalType(source), getTrueTypeFromConditionalType(target), reportErrors)) { + result &= isRelatedTo(getFalseTypeFromConditionalType(source), getFalseTypeFromConditionalType(target), reportErrors); } if (result) { errorInfo = saveErrorInfo; @@ -15181,12 +15172,12 @@ namespace ts { else if (source.flags & TypeFlags.Conditional && target.flags & TypeFlags.Conditional) { inferFromTypes((source).checkType, (target).checkType); inferFromTypes((source).extendsType, (target).extendsType); - inferFromTypes((source).trueType, (target).trueType); - inferFromTypes((source).falseType, (target).falseType); + inferFromTypes(getTrueTypeFromConditionalType(source), getTrueTypeFromConditionalType(target)); + inferFromTypes(getFalseTypeFromConditionalType(source), getFalseTypeFromConditionalType(target)); } else if (target.flags & TypeFlags.Conditional && !contravariant) { - inferFromTypes(source, (target).trueType); - inferFromTypes(source, (target).falseType); + inferFromTypes(source, getTrueTypeFromConditionalType(target)); + inferFromTypes(source, getFalseTypeFromConditionalType(target)); } else if (target.flags & TypeFlags.UnionOrIntersection) { // We infer from types that are not naked type variables first so that inferences we diff --git a/src/compiler/types.ts b/src/compiler/types.ts index e33d0f44785..ecb569bd9b0 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -4338,8 +4338,8 @@ namespace ts { root: ConditionalRoot; checkType: Type; extendsType: Type; - trueType: Type; - falseType: Type; + resolvedTrueType: Type; + resolvedFalseType: Type; /* @internal */ resolvedInferredTrueType?: Type; // The `trueType` instantiated with the `combinedMapper`, if present /* @internal */ From 33c7e7fd2c1d0b64c040603fc24188b2d9cb15a8 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Sat, 11 May 2019 09:39:51 -0700 Subject: [PATCH 045/119] Accept new baselines --- .../reference/api/tsserverlibrary.d.ts | 4 +- tests/baselines/reference/api/typescript.d.ts | 4 +- ...nalNoInfiniteInstantiationDepth.errors.txt | 76 +++++++------ .../baselines/reference/conditionalTypes1.js | 2 +- .../reference/conditionalTypes1.types | 6 +- ...itionalTypesSimplifyWhenTrivial.errors.txt | 100 ++++++++++++++++++ .../conditionalTypesSimplifyWhenTrivial.types | 64 +++++------ ...iasAssignableToConstraintSameAsAlias.types | 2 +- ...ferredInferenceAllowsAssignment.errors.txt | 76 +++++++------ 9 files changed, 229 insertions(+), 105 deletions(-) create mode 100644 tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.errors.txt diff --git a/tests/baselines/reference/api/tsserverlibrary.d.ts b/tests/baselines/reference/api/tsserverlibrary.d.ts index 4bdfa84ca49..ca97395891a 100644 --- a/tests/baselines/reference/api/tsserverlibrary.d.ts +++ b/tests/baselines/reference/api/tsserverlibrary.d.ts @@ -2390,8 +2390,8 @@ declare namespace ts { root: ConditionalRoot; checkType: Type; extendsType: Type; - trueType: Type; - falseType: Type; + resolvedTrueType: Type; + resolvedFalseType: Type; } interface SubstitutionType extends InstantiableType { typeVariable: TypeVariable; diff --git a/tests/baselines/reference/api/typescript.d.ts b/tests/baselines/reference/api/typescript.d.ts index 7f0e63cfc03..e136f2c96e4 100644 --- a/tests/baselines/reference/api/typescript.d.ts +++ b/tests/baselines/reference/api/typescript.d.ts @@ -2390,8 +2390,8 @@ declare namespace ts { root: ConditionalRoot; checkType: Type; extendsType: Type; - trueType: Type; - falseType: Type; + resolvedTrueType: Type; + resolvedFalseType: Type; } interface SubstitutionType extends InstantiableType { typeVariable: TypeVariable; diff --git a/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt b/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt index 04a88a4b1e5..74835c4a55b 100644 --- a/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt +++ b/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt @@ -11,22 +11,28 @@ tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfin Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. ==== tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.ts (1 errors) ==== @@ -107,20 +113,26 @@ tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfin !!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. !!! error TS2344: Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. !!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. \ No newline at end of file diff --git a/tests/baselines/reference/conditionalTypes1.js b/tests/baselines/reference/conditionalTypes1.js index 5dc48518384..7ce19ce17e7 100644 --- a/tests/baselines/reference/conditionalTypes1.js +++ b/tests/baselines/reference/conditionalTypes1.js @@ -645,7 +645,7 @@ declare type T82 = Eq2; declare type T83 = Eq2; declare type Foo = T extends string ? boolean : number; declare type Bar = T extends string ? boolean : number; -declare const convert: (value: Foo) => Foo; +declare const convert: (value: Foo) => Bar; declare type Baz = Foo; declare const convert2: (value: Foo) => Foo; declare function f31(): void; diff --git a/tests/baselines/reference/conditionalTypes1.types b/tests/baselines/reference/conditionalTypes1.types index bc70e68f0ca..234fc071d74 100644 --- a/tests/baselines/reference/conditionalTypes1.types +++ b/tests/baselines/reference/conditionalTypes1.types @@ -779,8 +779,8 @@ type Bar = T extends string ? boolean : number; >Bar : Bar const convert = (value: Foo): Bar => value; ->convert : (value: Foo) => Foo ->(value: Foo): Bar => value : (value: Foo) => Foo +>convert : (value: Foo) => Bar +>(value: Foo): Bar => value : (value: Foo) => Bar >value : Foo >value : Foo @@ -832,7 +832,7 @@ function f33() { >T1 : Foo type T2 = Bar; ->T2 : Foo +>T2 : Bar var z: T1; >z : Foo diff --git a/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.errors.txt b/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.errors.txt new file mode 100644 index 00000000000..ca38e867e4f --- /dev/null +++ b/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.errors.txt @@ -0,0 +1,100 @@ +tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(27,14): error TS2322: Type 'Pick>' is not assignable to type 'Params'. + 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. +tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(31,5): error TS2322: Type 'T' is not assignable to type 'ExcludeWithDefault'. +tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(36,14): error TS2322: Type 'Pick>' is not assignable to type 'Params'. + 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. +tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(40,5): error TS2322: Type 'T' is not assignable to type 'ExtractWithDefault'. +tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(47,14): error TS2322: Type 'Pick>' is not assignable to type 'Params'. + 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. +tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(51,5): error TS2322: Type 'T' is not assignable to type 'TemplatedConditional'. +tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(56,14): error TS2322: Type 'Pick>' is not assignable to type 'Params'. + 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. +tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(60,5): error TS2322: Type 'T' is not assignable to type 'TemplatedConditional'. + + +==== tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts (8 errors) ==== + const fn1 = ( + params: Pick>, + ): Params => params; + + function fn2(x: Exclude) { + var y: T = x; + x = y; + } + + const fn3 = ( + params: Pick>, + ): Params => params; + + function fn4(x: Extract) { + var y: T = x; + x = y; + } + + declare var x: Extract; // Should be `numebr | string` and not `any` + + type ExtractWithDefault = T extends U ? T : D; + + type ExcludeWithDefault = T extends U ? D : T; + + const fn5 = ( + params: Pick>, + ): Params => params; + ~~~~~~ +!!! error TS2322: Type 'Pick>' is not assignable to type 'Params'. +!!! error TS2322: 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. + + function fn6(x: ExcludeWithDefault) { + var y: T = x; + x = y; + ~ +!!! error TS2322: Type 'T' is not assignable to type 'ExcludeWithDefault'. + } + + const fn7 = ( + params: Pick>, + ): Params => params; + ~~~~~~ +!!! error TS2322: Type 'Pick>' is not assignable to type 'Params'. +!!! error TS2322: 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. + + function fn8(x: ExtractWithDefault) { + var y: T = x; + x = y; + ~ +!!! error TS2322: Type 'T' is not assignable to type 'ExtractWithDefault'. + } + + type TemplatedConditional = TCheck extends TExtends ? TTrue : TFalse; + + const fn9 = ( + params: Pick>, + ): Params => params; + ~~~~~~ +!!! error TS2322: Type 'Pick>' is not assignable to type 'Params'. +!!! error TS2322: 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. + + function fn10(x: TemplatedConditional) { + var y: T = x; + x = y; + ~ +!!! error TS2322: Type 'T' is not assignable to type 'TemplatedConditional'. + } + + const fn11 = ( + params: Pick>, + ): Params => params; + ~~~~~~ +!!! error TS2322: Type 'Pick>' is not assignable to type 'Params'. +!!! error TS2322: 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. + + function fn12(x: TemplatedConditional) { + var y: T = x; + x = y; + ~ +!!! error TS2322: Type 'T' is not assignable to type 'TemplatedConditional'. + } + + declare var z: any; + const zee = z!!!; // since x is `any`, `x extends null | undefined` should be both true and false - and thus yield `any` + \ No newline at end of file diff --git a/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.types b/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.types index 5f513153560..27ac10ff161 100644 --- a/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.types +++ b/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.types @@ -57,50 +57,50 @@ type ExcludeWithDefault = T extends U ? D : T; >ExcludeWithDefault : ExcludeWithDefault const fn5 = ( ->fn5 : (params: Pick) => Params ->( params: Pick>,): Params => params : (params: Pick) => Params +>fn5 : (params: Pick>) => Params +>( params: Pick>,): Params => params : (params: Pick>) => Params params: Pick>, ->params : Pick +>params : Pick> ): Params => params; ->params : Pick +>params : Pick> function fn6(x: ExcludeWithDefault) { ->fn6 : (x: T) => void ->x : T +>fn6 : (x: ExcludeWithDefault) => void +>x : ExcludeWithDefault var y: T = x; >y : T ->x : T +>x : ExcludeWithDefault x = y; >x = y : T ->x : T +>x : ExcludeWithDefault >y : T } const fn7 = ( ->fn7 : (params: Pick) => Params ->( params: Pick>,): Params => params : (params: Pick) => Params +>fn7 : (params: Pick>) => Params +>( params: Pick>,): Params => params : (params: Pick>) => Params params: Pick>, ->params : Pick +>params : Pick> ): Params => params; ->params : Pick +>params : Pick> function fn8(x: ExtractWithDefault) { ->fn8 : (x: T) => void ->x : T +>fn8 : (x: ExtractWithDefault) => void +>x : ExtractWithDefault var y: T = x; >y : T ->x : T +>x : ExtractWithDefault x = y; >x = y : T ->x : T +>x : ExtractWithDefault >y : T } @@ -108,50 +108,50 @@ type TemplatedConditional = TCheck extends TExt >TemplatedConditional : TemplatedConditional const fn9 = ( ->fn9 : (params: Pick) => Params ->( params: Pick>,): Params => params : (params: Pick) => Params +>fn9 : (params: Pick>) => Params +>( params: Pick>,): Params => params : (params: Pick>) => Params params: Pick>, ->params : Pick +>params : Pick> ): Params => params; ->params : Pick +>params : Pick> function fn10(x: TemplatedConditional) { ->fn10 : (x: T) => void ->x : T +>fn10 : (x: TemplatedConditional) => void +>x : TemplatedConditional var y: T = x; >y : T ->x : T +>x : TemplatedConditional x = y; >x = y : T ->x : T +>x : TemplatedConditional >y : T } const fn11 = ( ->fn11 : (params: Pick) => Params ->( params: Pick>,): Params => params : (params: Pick) => Params +>fn11 : (params: Pick>) => Params +>( params: Pick>,): Params => params : (params: Pick>) => Params params: Pick>, ->params : Pick +>params : Pick> ): Params => params; ->params : Pick +>params : Pick> function fn12(x: TemplatedConditional) { ->fn12 : (x: T) => void ->x : T +>fn12 : (x: TemplatedConditional) => void +>x : TemplatedConditional var y: T = x; >y : T ->x : T +>x : TemplatedConditional x = y; >x = y : T ->x : T +>x : TemplatedConditional >y : T } diff --git a/tests/baselines/reference/inlinedAliasAssignableToConstraintSameAsAlias.types b/tests/baselines/reference/inlinedAliasAssignableToConstraintSameAsAlias.types index 086aa5c976e..d337fbc718a 100644 --- a/tests/baselines/reference/inlinedAliasAssignableToConstraintSameAsAlias.types +++ b/tests/baselines/reference/inlinedAliasAssignableToConstraintSameAsAlias.types @@ -31,7 +31,7 @@ class A { >z : A[] whereRelated< // Works // Type is same as A1, but is not assignable to type A ->whereRelated : () => number +>whereRelated : >() => number RF extends RelationFields = RelationFields, N extends Name = Name, diff --git a/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt b/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt index a480d4f3e4e..8c7e2f57eda 100644 --- a/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt +++ b/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt @@ -11,22 +11,28 @@ tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts(76,50): Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. ==== tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts (1 errors) ==== @@ -120,22 +126,28 @@ tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts(76,50): !!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. !!! error TS2344: Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. !!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. >; declare const connect: { From bb9c5c96c80126a0ff78e1d3524b10adcfd1bed1 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Sat, 11 May 2019 11:15:37 -0700 Subject: [PATCH 046/119] Reuse existing type instantiations --- src/compiler/checker.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 5d3bc864a50..f016a8d3723 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -10379,7 +10379,7 @@ namespace ts { // Simplifications for types of the form `T extends U ? T : never` and `T extends U ? never : T`. if (root.falseType.flags & TypeFlags.Never && getActualTypeVariable(root.trueType) === getActualTypeVariable(root.checkType)) { if (checkType.flags & TypeFlags.Any || isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(extendsType))) { // Always true - return instantiateType(root.trueType, mapper); + return checkType; } else if (isIntersectionEmpty(checkType, extendsType)) { // Always false return neverType; @@ -10390,7 +10390,7 @@ namespace ts { return neverType; } else if (checkType.flags & TypeFlags.Any || isIntersectionEmpty(checkType, extendsType)) { // Always false - return instantiateType(root.falseType, mapper); + return checkType; } } const checkTypeInstantiable = maybeTypeOfKind(checkType, TypeFlags.Instantiable | TypeFlags.GenericMappedType); From b7fe99a88c59bd652029bdfe5b6ba8709a677838 Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Sat, 11 May 2019 16:40:23 -0700 Subject: [PATCH 047/119] Instantiate constraint with default upon comparison (#31240) --- src/compiler/checker.ts | 2 +- ...tantiatedWithDefaultWhenCheckingDefault.js | 42 +++++++++ ...atedWithDefaultWhenCheckingDefault.symbols | 87 +++++++++++++++++++ ...tiatedWithDefaultWhenCheckingDefault.types | 49 +++++++++++ ...tantiatedWithDefaultWhenCheckingDefault.ts | 24 +++++ 5 files changed, 203 insertions(+), 1 deletion(-) create mode 100644 tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.js create mode 100644 tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.symbols create mode 100644 tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.types create mode 100644 tests/cases/compiler/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index cc4c8476de6..64834befee1 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -24441,7 +24441,7 @@ namespace ts { const constraintType = getConstraintOfTypeParameter(typeParameter); const defaultType = getDefaultFromTypeParameter(typeParameter); if (constraintType && defaultType) { - checkTypeAssignableTo(defaultType, getTypeWithThisArgument(constraintType, defaultType), node.default, Diagnostics.Type_0_does_not_satisfy_the_constraint_1); + checkTypeAssignableTo(defaultType, getTypeWithThisArgument(instantiateType(constraintType, makeUnaryTypeMapper(typeParameter, defaultType)), defaultType), node.default, Diagnostics.Type_0_does_not_satisfy_the_constraint_1); } if (produceDiagnostics) { checkTypeNameIsReserved(node.name, Diagnostics.Type_parameter_name_cannot_be_0); diff --git a/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.js b/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.js new file mode 100644 index 00000000000..fc3922448e9 --- /dev/null +++ b/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.js @@ -0,0 +1,42 @@ +//// [typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts] +// tricky interface +interface Settable { + set(value: V): T; +} + +// implement +class Identity implements Settable, V> { + readonly item: V; + constructor(value: V) { + this.item = value; + } + public set(value: V): Identity { + return new Identity(value); + } +} + +// generic parameter default +interface Test1 = Identity> { }; +let test1: Test1; + +// not generic parameter default +interface Test2Base> { }; +type Test2 = Test2Base>; +let test2: Test2; + + +//// [typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.js] +// implement +var Identity = /** @class */ (function () { + function Identity(value) { + this.item = value; + } + Identity.prototype.set = function (value) { + return new Identity(value); + }; + return Identity; +}()); +; +var test1; +; +var test2; diff --git a/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.symbols b/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.symbols new file mode 100644 index 00000000000..3462a11d800 --- /dev/null +++ b/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.symbols @@ -0,0 +1,87 @@ +=== tests/cases/compiler/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts === +// tricky interface +interface Settable { +>Settable : Symbol(Settable, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 0, 0)) +>T : Symbol(T, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 1, 19)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 1, 21)) + + set(value: V): T; +>set : Symbol(Settable.set, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 1, 26)) +>value : Symbol(value, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 2, 8)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 1, 21)) +>T : Symbol(T, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 1, 19)) +} + +// implement +class Identity implements Settable, V> { +>Identity : Symbol(Identity, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 3, 1)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 15)) +>Settable : Symbol(Settable, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 0, 0)) +>Identity : Symbol(Identity, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 3, 1)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 15)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 15)) + + readonly item: V; +>item : Symbol(Identity.item, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 55)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 15)) + + constructor(value: V) { +>value : Symbol(value, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 8, 16)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 15)) + + this.item = value; +>this.item : Symbol(Identity.item, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 55)) +>this : Symbol(Identity, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 3, 1)) +>item : Symbol(Identity.item, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 55)) +>value : Symbol(value, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 8, 16)) + } + public set(value: V): Identity { +>set : Symbol(Identity.set, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 10, 5)) +>value : Symbol(value, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 11, 15)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 15)) +>Identity : Symbol(Identity, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 3, 1)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 15)) + + return new Identity(value); +>Identity : Symbol(Identity, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 3, 1)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 6, 15)) +>value : Symbol(value, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 11, 15)) + } +} + +// generic parameter default +interface Test1 = Identity> { }; +>Test1 : Symbol(Test1, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 14, 1)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 17, 16)) +>T : Symbol(T, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 17, 18)) +>Settable : Symbol(Settable, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 0, 0)) +>T : Symbol(T, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 17, 18)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 17, 16)) +>Identity : Symbol(Identity, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 3, 1)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 17, 16)) + +let test1: Test1; +>test1 : Symbol(test1, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 18, 3)) +>Test1 : Symbol(Test1, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 14, 1)) + +// not generic parameter default +interface Test2Base> { }; +>Test2Base : Symbol(Test2Base, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 18, 25)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 21, 20)) +>T : Symbol(T, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 21, 22)) +>Settable : Symbol(Settable, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 0, 0)) +>T : Symbol(T, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 21, 22)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 21, 20)) + +type Test2 = Test2Base>; +>Test2 : Symbol(Test2, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 21, 53)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 22, 11)) +>Test2Base : Symbol(Test2Base, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 18, 25)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 22, 11)) +>Identity : Symbol(Identity, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 3, 1)) +>V : Symbol(V, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 22, 11)) + +let test2: Test2; +>test2 : Symbol(test2, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 23, 3)) +>Test2 : Symbol(Test2, Decl(typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts, 21, 53)) + diff --git a/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.types b/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.types new file mode 100644 index 00000000000..cb3394962c6 --- /dev/null +++ b/tests/baselines/reference/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.types @@ -0,0 +1,49 @@ +=== tests/cases/compiler/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts === +// tricky interface +interface Settable { + set(value: V): T; +>set : (value: V) => T +>value : V +} + +// implement +class Identity implements Settable, V> { +>Identity : Identity + + readonly item: V; +>item : V + + constructor(value: V) { +>value : V + + this.item = value; +>this.item = value : V +>this.item : V +>this : this +>item : V +>value : V + } + public set(value: V): Identity { +>set : (value: V) => Identity +>value : V + + return new Identity(value); +>new Identity(value) : Identity +>Identity : typeof Identity +>value : V + } +} + +// generic parameter default +interface Test1 = Identity> { }; +let test1: Test1; +>test1 : Test1> + +// not generic parameter default +interface Test2Base> { }; +type Test2 = Test2Base>; +>Test2 : Test2Base> + +let test2: Test2; +>test2 : Test2Base> + diff --git a/tests/cases/compiler/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts b/tests/cases/compiler/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts new file mode 100644 index 00000000000..3f4e3e19c8c --- /dev/null +++ b/tests/cases/compiler/typePartameterConstraintInstantiatedWithDefaultWhenCheckingDefault.ts @@ -0,0 +1,24 @@ +// tricky interface +interface Settable { + set(value: V): T; +} + +// implement +class Identity implements Settable, V> { + readonly item: V; + constructor(value: V) { + this.item = value; + } + public set(value: V): Identity { + return new Identity(value); + } +} + +// generic parameter default +interface Test1 = Identity> { }; +let test1: Test1; + +// not generic parameter default +interface Test2Base> { }; +type Test2 = Test2Base>; +let test2: Test2; From c610b98621d3428e9ac4a1c055075de96264f109 Mon Sep 17 00:00:00 2001 From: Anix Date: Mon, 13 May 2019 00:12:52 +0530 Subject: [PATCH 048/119] Moved the badges below the Typescript Header Moved all the badges below the Typescript Heading as its nice to keep all badges together. Earlier it gitter badge was below only. --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 52e35c16f79..04c8c7dbbcc 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,13 @@ + +# TypeScript + +[![Join the chat at https://gitter.im/Microsoft/TypeScript](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/Microsoft/TypeScript?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Build Status](https://travis-ci.org/microsoft/TypeScript.svg?branch=master)](https://travis-ci.org/Microsoft/TypeScript) [![VSTS Build Status](https://dev.azure.com/typescript/TypeScript/_apis/build/status/Typescript/node10)](https://dev.azure.com/typescript/TypeScript/_build/latest?definitionId=4&view=logs) [![npm version](https://badge.fury.io/js/typescript.svg)](https://www.npmjs.com/package/typescript) [![Downloads](https://img.shields.io/npm/dm/typescript.svg)](https://www.npmjs.com/package/typescript) -# TypeScript -[![Join the chat at https://gitter.im/Microsoft/TypeScript](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/Microsoft/TypeScript?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [TypeScript](https://www.typescriptlang.org/) is a language for application-scale JavaScript. TypeScript adds optional types to JavaScript that support tools for large-scale JavaScript applications for any browser, for any host, on any OS. TypeScript compiles to readable, standards-based JavaScript. Try it out at the [playground](https://www.typescriptlang.org/play/), and stay up to date via [our blog](https://blogs.msdn.microsoft.com/typescript) and [Twitter account](https://twitter.com/typescript). From 8965650bc332a8b86db77c8183098c9d8b511df1 Mon Sep 17 00:00:00 2001 From: Alexander Date: Sun, 12 May 2019 23:14:18 +0300 Subject: [PATCH 049/119] ignore trigger chars within a string literal --- src/services/completions.ts | 4 ++- .../completionsStringsWithTriggerCharacter.ts | 30 +++++++++++++++++++ 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 tests/cases/fourslash/completionsStringsWithTriggerCharacter.ts diff --git a/src/services/completions.ts b/src/services/completions.ts index 9d569fbedde..0d69f5951f8 100644 --- a/src/services/completions.ts +++ b/src/services/completions.ts @@ -40,7 +40,9 @@ namespace ts.Completions { const compilerOptions = program.getCompilerOptions(); const contextToken = findPrecedingToken(position, sourceFile); - if (triggerCharacter && !isValidTrigger(sourceFile, triggerCharacter, contextToken, position)) return undefined; + if (triggerCharacter && !isInString(sourceFile, position, contextToken) && !isValidTrigger(sourceFile, triggerCharacter, contextToken, position)) { + return undefined; + } const stringCompletions = StringCompletions.getStringLiteralCompletions(sourceFile, position, contextToken, typeChecker, compilerOptions, host, log, preferences); if (stringCompletions) { diff --git a/tests/cases/fourslash/completionsStringsWithTriggerCharacter.ts b/tests/cases/fourslash/completionsStringsWithTriggerCharacter.ts new file mode 100644 index 00000000000..277218305f4 --- /dev/null +++ b/tests/cases/fourslash/completionsStringsWithTriggerCharacter.ts @@ -0,0 +1,30 @@ +/// + +//// type A = "a/b" | "b/a"; +//// const a: A = "a/*1*/"; +//// +//// type B = "a@b" | "b@a"; +//// const a: B = "a@/*2*/"; +//// +//// type C = "a.b" | "b.a"; +//// const c: C = "a./*3*/"; +//// +//// type D = "a'b" | "b'a"; +//// const d: D = "a'/*4*/"; +//// +//// type E = "a`b" | "b`a"; +//// const e: E = "a`/*5*/"; +//// +//// type F = 'a"b' | 'b"a'; +//// const f: F = 'a"/*6*/'; +//// +//// type G = "a Date: Mon, 13 May 2019 08:33:12 -0700 Subject: [PATCH 050/119] Update user baselines (#31371) --- tests/baselines/reference/user/uglify-js.log | 52 ++++++++++---------- 1 file changed, 26 insertions(+), 26 deletions(-) diff --git a/tests/baselines/reference/user/uglify-js.log b/tests/baselines/reference/user/uglify-js.log index 4a98daf3f2a..eccbc070b89 100644 --- a/tests/baselines/reference/user/uglify-js.log +++ b/tests/baselines/reference/user/uglify-js.log @@ -34,33 +34,33 @@ node_modules/uglify-js/lib/compress.js(3525,33): error TS2554: Expected 0 argume node_modules/uglify-js/lib/compress.js(3578,29): error TS2554: Expected 0 arguments, but got 1. node_modules/uglify-js/lib/compress.js(3595,29): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. node_modules/uglify-js/lib/compress.js(3620,75): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3693,63): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3878,38): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3899,24): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. -node_modules/uglify-js/lib/compress.js(3909,28): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. -node_modules/uglify-js/lib/compress.js(4068,21): error TS2403: Subsequent variable declarations must have the same type. Variable 'defs' must be of type 'Dictionary & { set: (key: any, val: any) => Dictionary & { set: ...; add: (key: any, val: any) => Dictionary & { set: ...; add: ...; get: (key: any) => any; del: (key: any) => Dictionary & { set: ...; ... 8 more ...; toObject: () => any; }; ... 5 more ...; toObject: () => any; }; ... 7 more ...; toObject: () => any;...', but here has type 'any'. -node_modules/uglify-js/lib/compress.js(4120,17): error TS2447: The '|=' operator is not allowed for boolean types. Consider using '||' instead. -node_modules/uglify-js/lib/compress.js(4181,45): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(4291,33): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(4588,17): error TS2403: Subsequent variable declarations must have the same type. Variable 'body' must be of type 'any[]', but here has type 'any'. -node_modules/uglify-js/lib/compress.js(4672,37): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(4880,57): error TS2345: Argument of type 'any[]' is not assignable to parameter of type '[RegExp, (string | undefined)?]'. +node_modules/uglify-js/lib/compress.js(3694,63): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3879,38): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3900,24): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(3910,28): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(4069,21): error TS2403: Subsequent variable declarations must have the same type. Variable 'defs' must be of type 'Dictionary & { set: (key: any, val: any) => Dictionary & { set: ...; add: (key: any, val: any) => Dictionary & { set: ...; add: ...; get: (key: any) => any; del: (key: any) => Dictionary & { set: ...; ... 8 more ...; toObject: () => any; }; ... 5 more ...; toObject: () => any; }; ... 7 more ...; toObject: () => any;...', but here has type 'any'. +node_modules/uglify-js/lib/compress.js(4121,17): error TS2447: The '|=' operator is not allowed for boolean types. Consider using '||' instead. +node_modules/uglify-js/lib/compress.js(4182,45): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(4292,33): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(4589,17): error TS2403: Subsequent variable declarations must have the same type. Variable 'body' must be of type 'any[]', but here has type 'any'. +node_modules/uglify-js/lib/compress.js(4673,37): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(4881,57): error TS2345: Argument of type 'any[]' is not assignable to parameter of type '[RegExp, (string | undefined)?]'. Property '0' is missing in type 'any[]' but required in type '[RegExp, (string | undefined)?]'. -node_modules/uglify-js/lib/compress.js(5044,45): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(5051,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'code' must be of type 'string', but here has type '{ get: () => string; toString: () => string; indent: () => void; indentation: () => number; current_width: () => number; should_break: () => boolean; has_parens: () => boolean; newline: () => void; print: (str: any) => void; ... 24 more ...; parent: (n: any) => any; }'. -node_modules/uglify-js/lib/compress.js(5055,36): error TS2532: Object is possibly 'undefined'. -node_modules/uglify-js/lib/compress.js(5060,41): error TS2339: Property 'get' does not exist on type 'string'. -node_modules/uglify-js/lib/compress.js(5563,18): error TS2454: Variable 'is_strict_comparison' is used before being assigned. -node_modules/uglify-js/lib/compress.js(6058,25): error TS2367: This condition will always return 'false' since the types 'boolean' and '"f"' have no overlap. -node_modules/uglify-js/lib/compress.js(6085,47): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(6159,39): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(6231,39): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(6237,41): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(6670,43): error TS2454: Variable 'property' is used before being assigned. -node_modules/uglify-js/lib/compress.js(6685,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'value' must be of type 'number', but here has type 'any'. -node_modules/uglify-js/lib/compress.js(6688,46): error TS2339: Property 'has_side_effects' does not exist on type 'number'. -node_modules/uglify-js/lib/compress.js(6694,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'value' must be of type 'number', but here has type 'any'. -node_modules/uglify-js/lib/compress.js(6722,34): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(5045,45): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(5052,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'code' must be of type 'string', but here has type '{ get: () => string; toString: () => string; indent: () => void; indentation: () => number; current_width: () => number; should_break: () => boolean; has_parens: () => boolean; newline: () => void; print: (str: any) => void; ... 24 more ...; parent: (n: any) => any; }'. +node_modules/uglify-js/lib/compress.js(5056,36): error TS2532: Object is possibly 'undefined'. +node_modules/uglify-js/lib/compress.js(5061,41): error TS2339: Property 'get' does not exist on type 'string'. +node_modules/uglify-js/lib/compress.js(5565,18): error TS2454: Variable 'is_strict_comparison' is used before being assigned. +node_modules/uglify-js/lib/compress.js(6060,25): error TS2367: This condition will always return 'false' since the types 'boolean' and '"f"' have no overlap. +node_modules/uglify-js/lib/compress.js(6087,47): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(6160,39): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(6232,39): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(6238,41): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(6676,43): error TS2454: Variable 'property' is used before being assigned. +node_modules/uglify-js/lib/compress.js(6691,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'value' must be of type 'number', but here has type 'any'. +node_modules/uglify-js/lib/compress.js(6694,46): error TS2339: Property 'has_side_effects' does not exist on type 'number'. +node_modules/uglify-js/lib/compress.js(6700,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'value' must be of type 'number', but here has type 'any'. +node_modules/uglify-js/lib/compress.js(6728,34): error TS2554: Expected 0 arguments, but got 1. node_modules/uglify-js/lib/minify.js(167,75): error TS2339: Property 'compress' does not exist on type 'Compressor'. node_modules/uglify-js/lib/mozilla-ast.js(566,33): error TS2554: Expected 0 arguments, but got 1. node_modules/uglify-js/lib/output.js(235,25): error TS2554: Expected 0 arguments, but got 2. From 8ba53b6fd540a3533fe9e34d2d4f2d2eb0ae969b Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Mon, 13 May 2019 11:18:28 -0700 Subject: [PATCH 051/119] Simplify conditionals upon comparison, rather than instantiation --- src/compiler/checker.ts | 36 ++++++- src/compiler/types.ts | 2 + ...nalNoInfiniteInstantiationDepth.errors.txt | 82 +++++++------- ...itionalTypesSimplifyWhenTrivial.errors.txt | 100 ------------------ ...ferredInferenceAllowsAssignment.errors.txt | 82 +++++++------- 5 files changed, 110 insertions(+), 192 deletions(-) delete mode 100644 tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.errors.txt diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index f016a8d3723..ccca2c436da 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -9044,7 +9044,7 @@ namespace ts { } function getSubstitutionType(typeVariable: TypeVariable, substitute: Type) { - if (substitute.flags & TypeFlags.AnyOrUnknown) { + if (substitute.flags & TypeFlags.AnyOrUnknown || substitute === typeVariable) { return typeVariable; } const id = `${getTypeId(typeVariable)}>${getTypeId(substitute)}`; @@ -10194,7 +10194,9 @@ namespace ts { } function getSimplifiedType(type: Type, writing: boolean): Type { - return type.flags & TypeFlags.IndexedAccess ? getSimplifiedIndexedAccessType(type, writing) : type; + return type.flags & TypeFlags.IndexedAccess ? getSimplifiedIndexedAccessType(type, writing) : + type.flags & TypeFlags.Conditional ? getSimplifiedConditionalType(type, writing) : + type; } function distributeIndexOverObjectType(objectType: Type, indexType: Type, writing: boolean) { @@ -10257,6 +10259,32 @@ namespace ts { return type[cache] = type; } + function getSimplifiedConditionalType(type: ConditionalType, writing: boolean) { + const falseType = getFalseTypeFromConditionalType(type); + const trueType = getTrueTypeFromConditionalType(type); + const checkType = type.checkType; + const extendsType = type.extendsType; + // Simplifications for types of the form `T extends U ? T : never` and `T extends U ? never : T`. + if (falseType.flags & TypeFlags.Never && getActualTypeVariable(trueType) === getActualTypeVariable(checkType)) { + if (checkType.flags & TypeFlags.Any || isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(extendsType))) { // Always true + return getSimplifiedType(trueType, writing); + } + else if (isIntersectionEmpty(checkType, extendsType)) { // Always false + return neverType; + } + } + else if (trueType.flags & TypeFlags.Never && getActualTypeVariable(falseType) === getActualTypeVariable(checkType)) { + if (!(checkType.flags & TypeFlags.Any) && isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(extendsType))) { // Always true + return neverType; + } + else if (checkType.flags & TypeFlags.Any || isIntersectionEmpty(checkType, extendsType)) { // Always false + return getSimplifiedType(falseType, writing); + } + } + + return type; + } + function substituteIndexedMappedType(objectType: MappedType, index: Type) { const mapper = createTypeMapper([getTypeParameterFromMappedType(objectType)], [index]); const templateMapper = combineTypeMappers(objectType.mapper, mapper); @@ -12431,10 +12459,10 @@ namespace ts { if (target.flags & TypeFlags.Substitution) { target = (target).typeVariable; } - if (source.flags & TypeFlags.IndexedAccess) { + if (source.flags & TypeFlags.Simplifiable) { source = getSimplifiedType(source, /*writing*/ false); } - if (target.flags & TypeFlags.IndexedAccess) { + if (target.flags & TypeFlags.Simplifiable) { target = getSimplifiedType(target, /*writing*/ true); } diff --git a/src/compiler/types.ts b/src/compiler/types.ts index ecb569bd9b0..db1a62937e6 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -3966,6 +3966,8 @@ namespace ts { StructuredOrInstantiable = StructuredType | Instantiable, /* @internal */ ObjectFlagsType = Nullable | Never | Object | Union | Intersection, + /* @internal */ + Simplifiable = IndexedAccess | Conditional, // 'Narrowable' types are types where narrowing actually narrows. // This *should* be every type other than null, undefined, void, and never Narrowable = Any | Unknown | StructuredOrInstantiable | StringLike | NumberLike | BigIntLike | BooleanLike | ESSymbol | UniqueESSymbol | NonPrimitive, diff --git a/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt b/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt index 74835c4a55b..e73908f20f4 100644 --- a/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt +++ b/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt @@ -11,28 +11,25 @@ tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfin Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. ==== tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.ts (1 errors) ==== @@ -113,26 +110,23 @@ tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfin !!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. !!! error TS2344: Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. !!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. \ No newline at end of file diff --git a/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.errors.txt b/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.errors.txt deleted file mode 100644 index ca38e867e4f..00000000000 --- a/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.errors.txt +++ /dev/null @@ -1,100 +0,0 @@ -tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(27,14): error TS2322: Type 'Pick>' is not assignable to type 'Params'. - 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. -tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(31,5): error TS2322: Type 'T' is not assignable to type 'ExcludeWithDefault'. -tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(36,14): error TS2322: Type 'Pick>' is not assignable to type 'Params'. - 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. -tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(40,5): error TS2322: Type 'T' is not assignable to type 'ExtractWithDefault'. -tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(47,14): error TS2322: Type 'Pick>' is not assignable to type 'Params'. - 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. -tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(51,5): error TS2322: Type 'T' is not assignable to type 'TemplatedConditional'. -tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(56,14): error TS2322: Type 'Pick>' is not assignable to type 'Params'. - 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. -tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts(60,5): error TS2322: Type 'T' is not assignable to type 'TemplatedConditional'. - - -==== tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts (8 errors) ==== - const fn1 = ( - params: Pick>, - ): Params => params; - - function fn2(x: Exclude) { - var y: T = x; - x = y; - } - - const fn3 = ( - params: Pick>, - ): Params => params; - - function fn4(x: Extract) { - var y: T = x; - x = y; - } - - declare var x: Extract; // Should be `numebr | string` and not `any` - - type ExtractWithDefault = T extends U ? T : D; - - type ExcludeWithDefault = T extends U ? D : T; - - const fn5 = ( - params: Pick>, - ): Params => params; - ~~~~~~ -!!! error TS2322: Type 'Pick>' is not assignable to type 'Params'. -!!! error TS2322: 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. - - function fn6(x: ExcludeWithDefault) { - var y: T = x; - x = y; - ~ -!!! error TS2322: Type 'T' is not assignable to type 'ExcludeWithDefault'. - } - - const fn7 = ( - params: Pick>, - ): Params => params; - ~~~~~~ -!!! error TS2322: Type 'Pick>' is not assignable to type 'Params'. -!!! error TS2322: 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. - - function fn8(x: ExtractWithDefault) { - var y: T = x; - x = y; - ~ -!!! error TS2322: Type 'T' is not assignable to type 'ExtractWithDefault'. - } - - type TemplatedConditional = TCheck extends TExtends ? TTrue : TFalse; - - const fn9 = ( - params: Pick>, - ): Params => params; - ~~~~~~ -!!! error TS2322: Type 'Pick>' is not assignable to type 'Params'. -!!! error TS2322: 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. - - function fn10(x: TemplatedConditional) { - var y: T = x; - x = y; - ~ -!!! error TS2322: Type 'T' is not assignable to type 'TemplatedConditional'. - } - - const fn11 = ( - params: Pick>, - ): Params => params; - ~~~~~~ -!!! error TS2322: Type 'Pick>' is not assignable to type 'Params'. -!!! error TS2322: 'Pick>' is assignable to the constraint of type 'Params', but 'Params' could be instantiated with a different subtype of constraint '{}'. - - function fn12(x: TemplatedConditional) { - var y: T = x; - x = y; - ~ -!!! error TS2322: Type 'T' is not assignable to type 'TemplatedConditional'. - } - - declare var z: any; - const zee = z!!!; // since x is `any`, `x extends null | undefined` should be both true and false - and thus yield `any` - \ No newline at end of file diff --git a/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt b/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt index 8c7e2f57eda..61ef3863a15 100644 --- a/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt +++ b/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt @@ -11,28 +11,25 @@ tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts(76,50): Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. ==== tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts (1 errors) ==== @@ -126,28 +123,25 @@ tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts(76,50): !!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. !!! error TS2344: Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. !!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. >; declare const connect: { From 90667e104df18bce0e0457d90393b54f2b9a9730 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Mon, 13 May 2019 12:42:33 -0700 Subject: [PATCH 052/119] Remove this-parameter filtering in statement completion --- src/compiler/checker.ts | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 64834befee1..b730f382db3 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -20386,25 +20386,7 @@ namespace ts { } function isValidPropertyAccessForCompletions(node: PropertyAccessExpression | ImportTypeNode | QualifiedName, type: Type, property: Symbol): boolean { - return isValidPropertyAccessWithType(node, node.kind === SyntaxKind.PropertyAccessExpression && node.expression.kind === SyntaxKind.SuperKeyword, property.escapedName, type) - && (!(property.flags & SymbolFlags.Method) || isValidMethodAccess(property, type)); - } - function isValidMethodAccess(method: Symbol, actualThisType: Type): boolean { - const propType = getTypeOfPropertyOfType(actualThisType, method.escapedName)!; - const signatures = getSignaturesOfType(getNonNullableType(propType), SignatureKind.Call); - Debug.assert(signatures.length !== 0); - return signatures.some(sig => { - const signatureThisType = getThisTypeOfSignature(sig); - return !signatureThisType || isTypeAssignableTo(actualThisType, getInstantiatedSignatureThisType(sig, signatureThisType, actualThisType)); - }); - } - function getInstantiatedSignatureThisType(sig: Signature, signatureThisType: Type, actualThisType: Type): Type { - if (!sig.typeParameters) { - return signatureThisType; - } - const context = createInferenceContext(sig.typeParameters, sig, InferenceFlags.None); - inferTypes(context.inferences, actualThisType, signatureThisType); - return instantiateType(signatureThisType, createSignatureTypeMapper(sig, getInferredTypes(context))); + return isValidPropertyAccessWithType(node, node.kind === SyntaxKind.PropertyAccessExpression && node.expression.kind === SyntaxKind.SuperKeyword, property.escapedName, type); } function isValidPropertyAccessWithType( From a65f35b5fb4c1bc0d56724258a051b7e6f85bfce Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Mon, 13 May 2019 12:42:44 -0700 Subject: [PATCH 053/119] Remove fourslash test --- .../completionsMethodWithThisParameter.ts | 20 ------------------- 1 file changed, 20 deletions(-) delete mode 100644 tests/cases/fourslash/completionsMethodWithThisParameter.ts diff --git a/tests/cases/fourslash/completionsMethodWithThisParameter.ts b/tests/cases/fourslash/completionsMethodWithThisParameter.ts deleted file mode 100644 index d746f3626dc..00000000000 --- a/tests/cases/fourslash/completionsMethodWithThisParameter.ts +++ /dev/null @@ -1,20 +0,0 @@ -/// - -////class A { -//// value: T; // Make the type parameter actually matter -//// ms(this: A) {} -//// mo(this: A<{}>) {} -//// mt(this: A) {} -//// mp

(this: A

) {} -//// mps

(this: A

) {} -////} -//// -////const s = new A(); -////const n = new A(); -////s./*s*/; -////n./*n*/; - -verify.completions( - { marker: "s", exact: ["value", "ms", "mo", "mt", "mp", "mps"] }, - { marker: "n", exact: ["value", "mo", "mt", "mp"] }, -); From f140dfc30b9395a4aa5ee82e752d5012e4b9c7de Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Mon, 13 May 2019 14:41:33 -0700 Subject: [PATCH 054/119] Chain RHS narrowing and truthiness narrowing in assignment expression narrowing (#31348) --- src/compiler/checker.ts | 2 +- ...olFlowForCompoundAssignmentToThisMember.js | 36 ++++++++++ ...wForCompoundAssignmentToThisMember.symbols | 57 ++++++++++++++++ ...lowForCompoundAssignmentToThisMember.types | 67 +++++++++++++++++++ .../reference/controlFlowTruthiness.types | 2 +- .../typeGuardsInConditionalExpression.types | 10 +-- ...GuardsInRightOperandOfAndAndOperator.types | 14 ++-- ...peGuardsInRightOperandOfOrOrOperator.types | 2 +- ...olFlowForCompoundAssignmentToThisMember.ts | 19 ++++++ 9 files changed, 194 insertions(+), 15 deletions(-) create mode 100644 tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.js create mode 100644 tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.symbols create mode 100644 tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.types create mode 100644 tests/cases/compiler/controlFlowForCompoundAssignmentToThisMember.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 64834befee1..e07ae989383 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -16773,7 +16773,7 @@ namespace ts { function narrowTypeByBinaryExpression(type: Type, expr: BinaryExpression, assumeTrue: boolean): Type { switch (expr.operatorToken.kind) { case SyntaxKind.EqualsToken: - return narrowTypeByTruthiness(type, expr.left, assumeTrue); + return narrowTypeByTruthiness(narrowType(type, expr.right, assumeTrue), expr.left, assumeTrue); case SyntaxKind.EqualsEqualsToken: case SyntaxKind.ExclamationEqualsToken: case SyntaxKind.EqualsEqualsEqualsToken: diff --git a/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.js b/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.js new file mode 100644 index 00000000000..cdf74a58996 --- /dev/null +++ b/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.js @@ -0,0 +1,36 @@ +//// [controlFlowForCompoundAssignmentToThisMember.ts] +class DatasourceCommandWidgetElement { + _commandBased: boolean; + _commandElement: unknown; + commandElement: unknown; + + constructor(target: unknown) { + if (target instanceof DatasourceCommandWidgetElement) { + this._commandBased = true; + this._commandElement = target.commandElement; + } else { + this._commandBased = false; + } + + if (this._commandBased = (target instanceof DatasourceCommandWidgetElement)) { + this._commandElement = target.commandElement; + } + } +} + +//// [controlFlowForCompoundAssignmentToThisMember.js] +var DatasourceCommandWidgetElement = /** @class */ (function () { + function DatasourceCommandWidgetElement(target) { + if (target instanceof DatasourceCommandWidgetElement) { + this._commandBased = true; + this._commandElement = target.commandElement; + } + else { + this._commandBased = false; + } + if (this._commandBased = (target instanceof DatasourceCommandWidgetElement)) { + this._commandElement = target.commandElement; + } + } + return DatasourceCommandWidgetElement; +}()); diff --git a/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.symbols b/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.symbols new file mode 100644 index 00000000000..4da7454f312 --- /dev/null +++ b/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.symbols @@ -0,0 +1,57 @@ +=== tests/cases/compiler/controlFlowForCompoundAssignmentToThisMember.ts === +class DatasourceCommandWidgetElement { +>DatasourceCommandWidgetElement : Symbol(DatasourceCommandWidgetElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 0)) + + _commandBased: boolean; +>_commandBased : Symbol(DatasourceCommandWidgetElement._commandBased, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 38)) + + _commandElement: unknown; +>_commandElement : Symbol(DatasourceCommandWidgetElement._commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 1, 27)) + + commandElement: unknown; +>commandElement : Symbol(DatasourceCommandWidgetElement.commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 2, 29)) + + constructor(target: unknown) { +>target : Symbol(target, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 5, 16)) + + if (target instanceof DatasourceCommandWidgetElement) { +>target : Symbol(target, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 5, 16)) +>DatasourceCommandWidgetElement : Symbol(DatasourceCommandWidgetElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 0)) + + this._commandBased = true; +>this._commandBased : Symbol(DatasourceCommandWidgetElement._commandBased, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 38)) +>this : Symbol(DatasourceCommandWidgetElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 0)) +>_commandBased : Symbol(DatasourceCommandWidgetElement._commandBased, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 38)) + + this._commandElement = target.commandElement; +>this._commandElement : Symbol(DatasourceCommandWidgetElement._commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 1, 27)) +>this : Symbol(DatasourceCommandWidgetElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 0)) +>_commandElement : Symbol(DatasourceCommandWidgetElement._commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 1, 27)) +>target.commandElement : Symbol(DatasourceCommandWidgetElement.commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 2, 29)) +>target : Symbol(target, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 5, 16)) +>commandElement : Symbol(DatasourceCommandWidgetElement.commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 2, 29)) + + } else { + this._commandBased = false; +>this._commandBased : Symbol(DatasourceCommandWidgetElement._commandBased, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 38)) +>this : Symbol(DatasourceCommandWidgetElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 0)) +>_commandBased : Symbol(DatasourceCommandWidgetElement._commandBased, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 38)) + } + + if (this._commandBased = (target instanceof DatasourceCommandWidgetElement)) { +>this._commandBased : Symbol(DatasourceCommandWidgetElement._commandBased, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 38)) +>this : Symbol(DatasourceCommandWidgetElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 0)) +>_commandBased : Symbol(DatasourceCommandWidgetElement._commandBased, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 38)) +>target : Symbol(target, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 5, 16)) +>DatasourceCommandWidgetElement : Symbol(DatasourceCommandWidgetElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 0)) + + this._commandElement = target.commandElement; +>this._commandElement : Symbol(DatasourceCommandWidgetElement._commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 1, 27)) +>this : Symbol(DatasourceCommandWidgetElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 0, 0)) +>_commandElement : Symbol(DatasourceCommandWidgetElement._commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 1, 27)) +>target.commandElement : Symbol(DatasourceCommandWidgetElement.commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 2, 29)) +>target : Symbol(target, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 5, 16)) +>commandElement : Symbol(DatasourceCommandWidgetElement.commandElement, Decl(controlFlowForCompoundAssignmentToThisMember.ts, 2, 29)) + } + } +} diff --git a/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.types b/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.types new file mode 100644 index 00000000000..7c289daa2e0 --- /dev/null +++ b/tests/baselines/reference/controlFlowForCompoundAssignmentToThisMember.types @@ -0,0 +1,67 @@ +=== tests/cases/compiler/controlFlowForCompoundAssignmentToThisMember.ts === +class DatasourceCommandWidgetElement { +>DatasourceCommandWidgetElement : DatasourceCommandWidgetElement + + _commandBased: boolean; +>_commandBased : boolean + + _commandElement: unknown; +>_commandElement : unknown + + commandElement: unknown; +>commandElement : unknown + + constructor(target: unknown) { +>target : unknown + + if (target instanceof DatasourceCommandWidgetElement) { +>target instanceof DatasourceCommandWidgetElement : boolean +>target : unknown +>DatasourceCommandWidgetElement : typeof DatasourceCommandWidgetElement + + this._commandBased = true; +>this._commandBased = true : true +>this._commandBased : boolean +>this : this +>_commandBased : boolean +>true : true + + this._commandElement = target.commandElement; +>this._commandElement = target.commandElement : unknown +>this._commandElement : unknown +>this : this +>_commandElement : unknown +>target.commandElement : unknown +>target : DatasourceCommandWidgetElement +>commandElement : unknown + + } else { + this._commandBased = false; +>this._commandBased = false : false +>this._commandBased : boolean +>this : this +>_commandBased : boolean +>false : false + } + + if (this._commandBased = (target instanceof DatasourceCommandWidgetElement)) { +>this._commandBased = (target instanceof DatasourceCommandWidgetElement) : boolean +>this._commandBased : boolean +>this : this +>_commandBased : boolean +>(target instanceof DatasourceCommandWidgetElement) : boolean +>target instanceof DatasourceCommandWidgetElement : boolean +>target : unknown +>DatasourceCommandWidgetElement : typeof DatasourceCommandWidgetElement + + this._commandElement = target.commandElement; +>this._commandElement = target.commandElement : unknown +>this._commandElement : unknown +>this : this +>_commandElement : unknown +>target.commandElement : unknown +>target : DatasourceCommandWidgetElement +>commandElement : unknown + } + } +} diff --git a/tests/baselines/reference/controlFlowTruthiness.types b/tests/baselines/reference/controlFlowTruthiness.types index 454d094f406..17f497267ee 100644 --- a/tests/baselines/reference/controlFlowTruthiness.types +++ b/tests/baselines/reference/controlFlowTruthiness.types @@ -111,7 +111,7 @@ function f5() { >x : string y; // string | undefined ->y : string | undefined +>y : string } else { x; // string | undefined diff --git a/tests/baselines/reference/typeGuardsInConditionalExpression.types b/tests/baselines/reference/typeGuardsInConditionalExpression.types index 19e11e2e888..f3b0a045e6b 100644 --- a/tests/baselines/reference/typeGuardsInConditionalExpression.types +++ b/tests/baselines/reference/typeGuardsInConditionalExpression.types @@ -211,11 +211,11 @@ function foo8(x: number | string | boolean) { >typeof x === "boolean" ? x // boolean : x == 10 : boolean >typeof x === "boolean" : boolean >typeof x : "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function" ->x : number | boolean +>x : number | true >"boolean" : "boolean" ? x // boolean ->x : boolean +>x : true : x == 10)); // boolean >x == 10 : boolean @@ -286,7 +286,7 @@ function foo10(x: number | string | boolean) { && typeof x === "number" >typeof x === "number" : boolean >typeof x : "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function" ->x : number | boolean +>x : number | true >"number" : "number" && x.toString()); // x is number @@ -326,7 +326,7 @@ function foo11(x: number | string | boolean) { && typeof x === "number" >typeof x === "number" : boolean >typeof x : "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function" ->x : number | boolean +>x : number | true >"number" : "number" && (x = 10) // assignment to x @@ -379,7 +379,7 @@ function foo12(x: number | string | boolean) { && typeof x === "number" >typeof x === "number" : boolean >typeof x : "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function" ->x : number | boolean +>x : number | true >"number" : "number" && x); // x is number diff --git a/tests/baselines/reference/typeGuardsInRightOperandOfAndAndOperator.types b/tests/baselines/reference/typeGuardsInRightOperandOfAndAndOperator.types index 166dd9ac0e1..43766b1db12 100644 --- a/tests/baselines/reference/typeGuardsInRightOperandOfAndAndOperator.types +++ b/tests/baselines/reference/typeGuardsInRightOperandOfAndAndOperator.types @@ -102,11 +102,11 @@ function foo5(x: number | string | boolean) { >typeof x !== "number" // number | boolean && x : boolean >typeof x !== "number" : boolean >typeof x : "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function" ->x : number | boolean +>x : number | true >"number" : "number" && x)); // boolean ->x : boolean +>x : true } function foo6(x: number | string | boolean) { >foo6 : (x: string | number | boolean) => boolean @@ -167,7 +167,7 @@ function foo7(x: number | string | boolean) { >typeof x === "number" // change value of x ? ((x = 10) && x.toString()) // x is number // do not change value : ((y = x) && x.toString()) : string >typeof x === "number" : boolean >typeof x : "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function" ->x : number | boolean +>x : number | true >"number" : "number" // change value of x @@ -187,13 +187,13 @@ function foo7(x: number | string | boolean) { : ((y = x) && x.toString()))); // x is boolean >((y = x) && x.toString()) : string >(y = x) && x.toString() : string ->(y = x) : boolean ->y = x : boolean +>(y = x) : true +>y = x : true >y : string | number | boolean ->x : boolean +>x : true >x.toString() : string >x.toString : () => string ->x : boolean +>x : true >toString : () => string } diff --git a/tests/baselines/reference/typeGuardsInRightOperandOfOrOrOperator.types b/tests/baselines/reference/typeGuardsInRightOperandOfOrOrOperator.types index d3335cd75be..8f381e115f5 100644 --- a/tests/baselines/reference/typeGuardsInRightOperandOfOrOrOperator.types +++ b/tests/baselines/reference/typeGuardsInRightOperandOfOrOrOperator.types @@ -194,7 +194,7 @@ function foo7(x: number | string | boolean) { >x : boolean >x.toString() : string >x.toString : () => string ->x : boolean +>x : true >toString : () => string } diff --git a/tests/cases/compiler/controlFlowForCompoundAssignmentToThisMember.ts b/tests/cases/compiler/controlFlowForCompoundAssignmentToThisMember.ts new file mode 100644 index 00000000000..2ed77e8ed5f --- /dev/null +++ b/tests/cases/compiler/controlFlowForCompoundAssignmentToThisMember.ts @@ -0,0 +1,19 @@ + +class DatasourceCommandWidgetElement { + _commandBased: boolean; + _commandElement: unknown; + commandElement: unknown; + + constructor(target: unknown) { + if (target instanceof DatasourceCommandWidgetElement) { + this._commandBased = true; + this._commandElement = target.commandElement; + } else { + this._commandBased = false; + } + + if (this._commandBased = (target instanceof DatasourceCommandWidgetElement)) { + this._commandElement = target.commandElement; + } + } +} \ No newline at end of file From 1b3589ba27b90dcf749582395951697d8fb97958 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Mon, 13 May 2019 16:23:51 -0700 Subject: [PATCH 055/119] Remove simplification logic from getConditionalType + simplify substitution types --- src/compiler/checker.ts | 47 +++++++++-------------------------------- src/compiler/types.ts | 2 +- 2 files changed, 11 insertions(+), 38 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index ccca2c436da..7aa8c0ddd68 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -10196,6 +10196,7 @@ namespace ts { function getSimplifiedType(type: Type, writing: boolean): Type { return type.flags & TypeFlags.IndexedAccess ? getSimplifiedIndexedAccessType(type, writing) : type.flags & TypeFlags.Conditional ? getSimplifiedConditionalType(type, writing) : + type.flags & TypeFlags.Substitution ? writing ? (type).typeVariable : (type).substitute : type; } @@ -10260,10 +10261,10 @@ namespace ts { } function getSimplifiedConditionalType(type: ConditionalType, writing: boolean) { - const falseType = getFalseTypeFromConditionalType(type); - const trueType = getTrueTypeFromConditionalType(type); const checkType = type.checkType; const extendsType = type.extendsType; + const trueType = getTrueTypeFromConditionalType(type); + const falseType = getFalseTypeFromConditionalType(type); // Simplifications for types of the form `T extends U ? T : never` and `T extends U ? never : T`. if (falseType.flags & TypeFlags.Never && getActualTypeVariable(trueType) === getActualTypeVariable(checkType)) { if (checkType.flags & TypeFlags.Any || isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(extendsType))) { // Always true @@ -10281,10 +10282,16 @@ namespace ts { return getSimplifiedType(falseType, writing); } } - return type; } + /** + * Invokes union simplification logic to determine if an intersection is considered empty as a union constituent + */ + function isIntersectionEmpty(type1: Type, type2: Type) { + return !!(getUnionType([intersectTypes(type1, type2), neverType]).flags & TypeFlags.Never); + } + function substituteIndexedMappedType(objectType: MappedType, index: Type) { const mapper = createTypeMapper([getTypeParameterFromMappedType(objectType)], [index]); const templateMapper = combineTypeMappers(objectType.mapper, mapper); @@ -10391,36 +10398,12 @@ namespace ts { return type; } - /** - * Invokes union simplification logic to determine if an intersection is considered empty as a union constituent - */ - function isIntersectionEmpty(type1: Type, type2: Type) { - return !!(getUnionType([intersectTypes(type1, type2), neverType]).flags & TypeFlags.Never); - } - function getConditionalType(root: ConditionalRoot, mapper: TypeMapper | undefined): Type { const checkType = instantiateType(root.checkType, mapper); const extendsType = instantiateType(root.extendsType, mapper); if (checkType === wildcardType || extendsType === wildcardType) { return wildcardType; } - // Simplifications for types of the form `T extends U ? T : never` and `T extends U ? never : T`. - if (root.falseType.flags & TypeFlags.Never && getActualTypeVariable(root.trueType) === getActualTypeVariable(root.checkType)) { - if (checkType.flags & TypeFlags.Any || isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(extendsType))) { // Always true - return checkType; - } - else if (isIntersectionEmpty(checkType, extendsType)) { // Always false - return neverType; - } - } - else if (root.trueType.flags & TypeFlags.Never && getActualTypeVariable(root.falseType) === getActualTypeVariable(root.checkType)) { - if (!(checkType.flags & TypeFlags.Any) && isTypeAssignableTo(getRestrictiveInstantiation(checkType), getRestrictiveInstantiation(extendsType))) { // Always true - return neverType; - } - else if (checkType.flags & TypeFlags.Any || isIntersectionEmpty(checkType, extendsType)) { // Always false - return checkType; - } - } const checkTypeInstantiable = maybeTypeOfKind(checkType, TypeFlags.Instantiable | TypeFlags.GenericMappedType); let combinedMapper: TypeMapper | undefined; if (root.inferTypeParameters) { @@ -10461,10 +10444,6 @@ namespace ts { } } // Return a deferred type for a check that is neither definitely true nor definitely false - return getDeferredConditionalType(root, mapper, combinedMapper, checkType, extendsType); - } - - function getDeferredConditionalType(root: ConditionalRoot, mapper: TypeMapper | undefined, combinedMapper: TypeMapper | undefined, checkType: Type, extendsType: Type) { const erasedCheckType = getActualTypeVariable(checkType); const result = createType(TypeFlags.Conditional); result.root = root; @@ -12453,12 +12432,6 @@ namespace ts { if (isFreshLiteralType(target)) { target = (target).regularType; } - if (source.flags & TypeFlags.Substitution) { - source = (source).substitute; - } - if (target.flags & TypeFlags.Substitution) { - target = (target).typeVariable; - } if (source.flags & TypeFlags.Simplifiable) { source = getSimplifiedType(source, /*writing*/ false); } diff --git a/src/compiler/types.ts b/src/compiler/types.ts index db1a62937e6..75fb702609b 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -3967,7 +3967,7 @@ namespace ts { /* @internal */ ObjectFlagsType = Nullable | Never | Object | Union | Intersection, /* @internal */ - Simplifiable = IndexedAccess | Conditional, + Simplifiable = IndexedAccess | Conditional | Substitution, // 'Narrowable' types are types where narrowing actually narrows. // This *should* be every type other than null, undefined, void, and never Narrowable = Any | Unknown | StructuredOrInstantiable | StringLike | NumberLike | BigIntLike | BooleanLike | ESSymbol | UniqueESSymbol | NonPrimitive, From 066e4b6f89f6da09629f9d84b9577b14c0fd7d3c Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Mon, 13 May 2019 16:24:20 -0700 Subject: [PATCH 056/119] Accept new baselines --- ...nalNoInfiniteInstantiationDepth.errors.txt | 82 ++++++++++--------- .../reference/conditionalTypes2.errors.txt | 28 +++---- .../conditionalTypesSimplifyWhenTrivial.types | 32 ++++---- ...ferredInferenceAllowsAssignment.errors.txt | 82 ++++++++++--------- 4 files changed, 118 insertions(+), 106 deletions(-) diff --git a/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt b/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt index e73908f20f4..74835c4a55b 100644 --- a/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt +++ b/tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt @@ -11,25 +11,28 @@ tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfin Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. ==== tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.ts (1 errors) ==== @@ -110,23 +113,26 @@ tests/cases/compiler/circularlyConstrainedMappedTypeContainingConditionalNoInfin !!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. !!! error TS2344: Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. !!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. \ No newline at end of file diff --git a/tests/baselines/reference/conditionalTypes2.errors.txt b/tests/baselines/reference/conditionalTypes2.errors.txt index 4093bf46fb0..1cf5b0eca44 100644 --- a/tests/baselines/reference/conditionalTypes2.errors.txt +++ b/tests/baselines/reference/conditionalTypes2.errors.txt @@ -10,13 +10,13 @@ tests/cases/conformance/types/conditional/conditionalTypes2.ts(24,5): error TS23 Type 'keyof B' is not assignable to type 'keyof A'. Type 'string | number | symbol' is not assignable to type 'keyof A'. Type 'string' is not assignable to type 'keyof A'. - Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. - Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. - Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. - Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. - Type 'keyof B' is not assignable to type '"valueOf"'. - Type 'string | number | symbol' is not assignable to type '"valueOf"'. - Type 'string' is not assignable to type '"valueOf"'. + Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. + Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. + Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. + Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. + Type 'keyof B' is not assignable to type 'keyof A'. + Type 'string | number | symbol' is not assignable to type 'keyof A'. + Type 'string' is not assignable to type 'keyof A'. tests/cases/conformance/types/conditional/conditionalTypes2.ts(25,5): error TS2322: Type 'Invariant' is not assignable to type 'Invariant'. Types of property 'foo' are incompatible. Type 'A extends string ? keyof A : A' is not assignable to type 'B extends string ? keyof B : B'. @@ -73,13 +73,13 @@ tests/cases/conformance/types/conditional/conditionalTypes2.ts(75,12): error TS2 !!! error TS2322: Type 'keyof B' is not assignable to type 'keyof A'. !!! error TS2322: Type 'string | number | symbol' is not assignable to type 'keyof A'. !!! error TS2322: Type 'string' is not assignable to type 'keyof A'. -!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. -!!! error TS2322: Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. -!!! error TS2322: Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. -!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. -!!! error TS2322: Type 'keyof B' is not assignable to type '"valueOf"'. -!!! error TS2322: Type 'string | number | symbol' is not assignable to type '"valueOf"'. -!!! error TS2322: Type 'string' is not assignable to type '"valueOf"'. +!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. +!!! error TS2322: Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. +!!! error TS2322: Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. +!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. +!!! error TS2322: Type 'keyof B' is not assignable to type 'keyof A'. +!!! error TS2322: Type 'string | number | symbol' is not assignable to type 'keyof A'. +!!! error TS2322: Type 'string' is not assignable to type 'keyof A'. b = a; // Error ~ !!! error TS2322: Type 'Invariant' is not assignable to type 'Invariant'. diff --git a/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.types b/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.types index 27ac10ff161..27ac357703a 100644 --- a/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.types +++ b/tests/baselines/reference/conditionalTypesSimplifyWhenTrivial.types @@ -1,49 +1,49 @@ === tests/cases/compiler/conditionalTypesSimplifyWhenTrivial.ts === const fn1 = ( ->fn1 : (params: Pick) => Params ->( params: Pick>,): Params => params : (params: Pick) => Params +>fn1 : (params: Pick>) => Params +>( params: Pick>,): Params => params : (params: Pick>) => Params params: Pick>, ->params : Pick +>params : Pick> ): Params => params; ->params : Pick +>params : Pick> function fn2(x: Exclude) { ->fn2 : (x: T) => void ->x : T +>fn2 : (x: Exclude) => void +>x : Exclude var y: T = x; >y : T ->x : T +>x : Exclude x = y; >x = y : T ->x : T +>x : Exclude >y : T } const fn3 = ( ->fn3 : (params: Pick) => Params ->( params: Pick>,): Params => params : (params: Pick) => Params +>fn3 : (params: Pick>) => Params +>( params: Pick>,): Params => params : (params: Pick>) => Params params: Pick>, ->params : Pick +>params : Pick> ): Params => params; ->params : Pick +>params : Pick> function fn4(x: Extract) { ->fn4 : (x: T) => void ->x : T +>fn4 : (x: Extract) => void +>x : Extract var y: T = x; >y : T ->x : T +>x : Extract x = y; >x = y : T ->x : T +>x : Extract >y : T } diff --git a/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt b/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt index 61ef3863a15..8c7e2f57eda 100644 --- a/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt +++ b/tests/baselines/reference/reactReduxLikeDeferredInferenceAllowsAssignment.errors.txt @@ -11,25 +11,28 @@ tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts(76,50): Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. - Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. - Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. + Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. + Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. ==== tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts (1 errors) ==== @@ -123,25 +126,28 @@ tests/cases/compiler/reactReduxLikeDeferredInferenceAllowsAssignment.ts(76,50): !!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. !!! error TS2344: Type '(Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]) | (Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. !!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>] | (TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. -!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. -!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type '(TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]) | GetProps[Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] | GetProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string] | (TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string] | (TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string])' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type '(TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never) | undefined'. +!!! error TS2344: Type 'GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & string] extends GetProps[keyof TInjectedProps & string] ? GetProps[keyof TInjectedProps & string] : TInjectedProps[keyof TInjectedProps & string] : GetProps[string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'keyof GetProps & string extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & keyof GetProps & string] extends GetProps[keyof TInjectedProps & keyof GetProps & string] ? GetProps[keyof TInjectedProps & keyof GetProps & string] : TInjectedProps[keyof TInjectedProps & keyof GetProps & string] : GetProps[keyof GetProps & string]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[keyof TInjectedProps & Extract>] extends GetProps[keyof TInjectedProps & Extract>] ? GetProps[keyof TInjectedProps & Extract>] : TInjectedProps[keyof TInjectedProps & Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'Extract> extends keyof TInjectedProps ? TInjectedProps[Extract>] extends GetProps[Extract>] ? GetProps[Extract>] : TInjectedProps[Extract>] : GetProps[Extract>]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. +!!! error TS2344: Type 'P extends keyof TInjectedProps ? TInjectedProps[P] extends GetProps[P] ? GetProps[P] : TInjectedProps[P] : GetProps[P]' is not assignable to type 'TInjectedProps[P] extends GetProps[P] ? GetProps[P] : never'. >; declare const connect: { From d2923460e967d9bd58057ce1570e24e62c08c62b Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Mon, 13 May 2019 16:34:09 -0700 Subject: [PATCH 057/119] Add comment providing context on the change --- src/compiler/checker.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index b730f382db3..cdd873cd0bc 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -20387,6 +20387,7 @@ namespace ts { function isValidPropertyAccessForCompletions(node: PropertyAccessExpression | ImportTypeNode | QualifiedName, type: Type, property: Symbol): boolean { return isValidPropertyAccessWithType(node, node.kind === SyntaxKind.PropertyAccessExpression && node.expression.kind === SyntaxKind.SuperKeyword, property.escapedName, type); + // Previously we validated the 'this' type of methods but this adversely affected performance. See #31377 for more context. } function isValidPropertyAccessWithType( From 4b5968eb6d8a64794b51d48fd67fd28e7cd34e28 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Tue, 14 May 2019 07:45:29 -0700 Subject: [PATCH 058/119] Revert change to substitution type simplification --- src/compiler/checker.ts | 7 ++++++- src/compiler/types.ts | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 9a64dce1255..e37da1fd678 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -10196,7 +10196,6 @@ namespace ts { function getSimplifiedType(type: Type, writing: boolean): Type { return type.flags & TypeFlags.IndexedAccess ? getSimplifiedIndexedAccessType(type, writing) : type.flags & TypeFlags.Conditional ? getSimplifiedConditionalType(type, writing) : - type.flags & TypeFlags.Substitution ? writing ? (type).typeVariable : (type).substitute : type; } @@ -12432,6 +12431,12 @@ namespace ts { if (isFreshLiteralType(target)) { target = (target).regularType; } + if (source.flags & TypeFlags.Substitution) { + source = (source).substitute; + } + if (target.flags & TypeFlags.Substitution) { + target = (target).typeVariable; + } if (source.flags & TypeFlags.Simplifiable) { source = getSimplifiedType(source, /*writing*/ false); } diff --git a/src/compiler/types.ts b/src/compiler/types.ts index 75fb702609b..db1a62937e6 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -3967,7 +3967,7 @@ namespace ts { /* @internal */ ObjectFlagsType = Nullable | Never | Object | Union | Intersection, /* @internal */ - Simplifiable = IndexedAccess | Conditional | Substitution, + Simplifiable = IndexedAccess | Conditional, // 'Narrowable' types are types where narrowing actually narrows. // This *should* be every type other than null, undefined, void, and never Narrowable = Any | Unknown | StructuredOrInstantiable | StringLike | NumberLike | BigIntLike | BooleanLike | ESSymbol | UniqueESSymbol | NonPrimitive, From 92a1547efff8ce62a14e160cb007f4eb653f160d Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Tue, 14 May 2019 08:41:29 -0700 Subject: [PATCH 059/119] Accept new baselines --- .../reference/conditionalTypes2.errors.txt | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/tests/baselines/reference/conditionalTypes2.errors.txt b/tests/baselines/reference/conditionalTypes2.errors.txt index 1cf5b0eca44..4093bf46fb0 100644 --- a/tests/baselines/reference/conditionalTypes2.errors.txt +++ b/tests/baselines/reference/conditionalTypes2.errors.txt @@ -10,13 +10,13 @@ tests/cases/conformance/types/conditional/conditionalTypes2.ts(24,5): error TS23 Type 'keyof B' is not assignable to type 'keyof A'. Type 'string | number | symbol' is not assignable to type 'keyof A'. Type 'string' is not assignable to type 'keyof A'. - Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. - Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. - Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. - Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. - Type 'keyof B' is not assignable to type 'keyof A'. - Type 'string | number | symbol' is not assignable to type 'keyof A'. - Type 'string' is not assignable to type 'keyof A'. + Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. + Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. + Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. + Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. + Type 'keyof B' is not assignable to type '"valueOf"'. + Type 'string | number | symbol' is not assignable to type '"valueOf"'. + Type 'string' is not assignable to type '"valueOf"'. tests/cases/conformance/types/conditional/conditionalTypes2.ts(25,5): error TS2322: Type 'Invariant' is not assignable to type 'Invariant'. Types of property 'foo' are incompatible. Type 'A extends string ? keyof A : A' is not assignable to type 'B extends string ? keyof B : B'. @@ -73,13 +73,13 @@ tests/cases/conformance/types/conditional/conditionalTypes2.ts(75,12): error TS2 !!! error TS2322: Type 'keyof B' is not assignable to type 'keyof A'. !!! error TS2322: Type 'string | number | symbol' is not assignable to type 'keyof A'. !!! error TS2322: Type 'string' is not assignable to type 'keyof A'. -!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. -!!! error TS2322: Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. -!!! error TS2322: Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. -!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf" | keyof A'. -!!! error TS2322: Type 'keyof B' is not assignable to type 'keyof A'. -!!! error TS2322: Type 'string | number | symbol' is not assignable to type 'keyof A'. -!!! error TS2322: Type 'string' is not assignable to type 'keyof A'. +!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. +!!! error TS2322: Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. +!!! error TS2322: Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. +!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'. +!!! error TS2322: Type 'keyof B' is not assignable to type '"valueOf"'. +!!! error TS2322: Type 'string | number | symbol' is not assignable to type '"valueOf"'. +!!! error TS2322: Type 'string' is not assignable to type '"valueOf"'. b = a; // Error ~ !!! error TS2322: Type 'Invariant' is not assignable to type 'Invariant'. From 3885e3fcda213ec8c5f21849d6b8ddf8a5357fa7 Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Tue, 14 May 2019 16:58:06 -0700 Subject: [PATCH 060/119] Fix error message regressed by #30916 (#31276) --- src/compiler/checker.ts | 20 +++++++++++++++---- ...gningFunctionToTupleIssuesError.errors.txt | 8 ++++++++ .../assigningFunctionToTupleIssuesError.js | 6 ++++++ ...ssigningFunctionToTupleIssuesError.symbols | 8 ++++++++ .../assigningFunctionToTupleIssuesError.types | 8 ++++++++ .../assigningFunctionToTupleIssuesError.ts | 2 ++ 6 files changed, 48 insertions(+), 4 deletions(-) create mode 100644 tests/baselines/reference/assigningFunctionToTupleIssuesError.errors.txt create mode 100644 tests/baselines/reference/assigningFunctionToTupleIssuesError.js create mode 100644 tests/baselines/reference/assigningFunctionToTupleIssuesError.symbols create mode 100644 tests/baselines/reference/assigningFunctionToTupleIssuesError.types create mode 100644 tests/cases/compiler/assigningFunctionToTupleIssuesError.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 9a64dce1255..0f18afa7741 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -12290,7 +12290,7 @@ namespace ts { let depth = 0; let expandingFlags = ExpandingFlags.None; let overflow = false; - let suppressNextError = false; + let overrideNextErrorInfo: DiagnosticMessageChain | undefined; Debug.assert(relation !== identityRelation || !errorNode, "no error reporting in identity checking"); @@ -12571,10 +12571,14 @@ namespace ts { } if (!result && reportErrors) { - const maybeSuppress = suppressNextError; - suppressNextError = false; + let maybeSuppress = overrideNextErrorInfo; + overrideNextErrorInfo = undefined; if (source.flags & TypeFlags.Object && target.flags & TypeFlags.Object) { + const currentError = errorInfo; tryElaborateArrayLikeErrors(source, target, reportErrors); + if (errorInfo !== currentError) { + maybeSuppress = errorInfo; + } } if (source.flags & TypeFlags.Object && target.flags & TypeFlags.Primitive) { tryElaborateErrorsForPrimitivesAndObjects(source, target); @@ -13506,9 +13510,10 @@ namespace ts { if (unmatchedProperty) { if (reportErrors) { const props = arrayFrom(getUnmatchedProperties(source, target, requireOptionalProperties, /*matchDiscriminantProperties*/ false)); + let shouldSkipElaboration = false; if (!headMessage || (headMessage.code !== Diagnostics.Class_0_incorrectly_implements_interface_1.code && headMessage.code !== Diagnostics.Class_0_incorrectly_implements_class_1_Did_you_mean_to_extend_1_and_inherit_its_members_as_a_subclass.code)) { - suppressNextError = true; // Retain top-level error for interface implementing issues, otherwise omit it + shouldSkipElaboration = true; // Retain top-level error for interface implementing issues, otherwise omit it } if (props.length === 1) { const propName = symbolToString(unmatchedProperty); @@ -13516,6 +13521,9 @@ namespace ts { if (length(unmatchedProperty.declarations)) { associateRelatedInfo(createDiagnosticForNode(unmatchedProperty.declarations[0], Diagnostics._0_is_declared_here, propName)); } + if (shouldSkipElaboration) { + overrideNextErrorInfo = errorInfo; + } } else if (tryElaborateArrayLikeErrors(source, target, /*reportErrors*/ false)) { if (props.length > 5) { // arbitrary cutoff for too-long list form @@ -13524,7 +13532,11 @@ namespace ts { else { reportError(Diagnostics.Type_0_is_missing_the_following_properties_from_type_1_Colon_2, typeToString(source), typeToString(target), map(props, p => symbolToString(p)).join(", ")); } + if (shouldSkipElaboration) { + overrideNextErrorInfo = errorInfo; + } } + // ELSE: No array like or unmatched property error - just issue top level error (errorInfo = undefined) } return Ternary.False; } diff --git a/tests/baselines/reference/assigningFunctionToTupleIssuesError.errors.txt b/tests/baselines/reference/assigningFunctionToTupleIssuesError.errors.txt new file mode 100644 index 00000000000..ca1af66c087 --- /dev/null +++ b/tests/baselines/reference/assigningFunctionToTupleIssuesError.errors.txt @@ -0,0 +1,8 @@ +tests/cases/compiler/assigningFunctionToTupleIssuesError.ts(2,5): error TS2322: Type '() => void' is not assignable to type '[string]'. + + +==== tests/cases/compiler/assigningFunctionToTupleIssuesError.ts (1 errors) ==== + declare let a: () => void; + let b: [string] = a; + ~ +!!! error TS2322: Type '() => void' is not assignable to type '[string]'. \ No newline at end of file diff --git a/tests/baselines/reference/assigningFunctionToTupleIssuesError.js b/tests/baselines/reference/assigningFunctionToTupleIssuesError.js new file mode 100644 index 00000000000..3de3da7b3cc --- /dev/null +++ b/tests/baselines/reference/assigningFunctionToTupleIssuesError.js @@ -0,0 +1,6 @@ +//// [assigningFunctionToTupleIssuesError.ts] +declare let a: () => void; +let b: [string] = a; + +//// [assigningFunctionToTupleIssuesError.js] +var b = a; diff --git a/tests/baselines/reference/assigningFunctionToTupleIssuesError.symbols b/tests/baselines/reference/assigningFunctionToTupleIssuesError.symbols new file mode 100644 index 00000000000..7a499662aef --- /dev/null +++ b/tests/baselines/reference/assigningFunctionToTupleIssuesError.symbols @@ -0,0 +1,8 @@ +=== tests/cases/compiler/assigningFunctionToTupleIssuesError.ts === +declare let a: () => void; +>a : Symbol(a, Decl(assigningFunctionToTupleIssuesError.ts, 0, 11)) + +let b: [string] = a; +>b : Symbol(b, Decl(assigningFunctionToTupleIssuesError.ts, 1, 3)) +>a : Symbol(a, Decl(assigningFunctionToTupleIssuesError.ts, 0, 11)) + diff --git a/tests/baselines/reference/assigningFunctionToTupleIssuesError.types b/tests/baselines/reference/assigningFunctionToTupleIssuesError.types new file mode 100644 index 00000000000..6c7d57f8483 --- /dev/null +++ b/tests/baselines/reference/assigningFunctionToTupleIssuesError.types @@ -0,0 +1,8 @@ +=== tests/cases/compiler/assigningFunctionToTupleIssuesError.ts === +declare let a: () => void; +>a : () => void + +let b: [string] = a; +>b : [string] +>a : () => void + diff --git a/tests/cases/compiler/assigningFunctionToTupleIssuesError.ts b/tests/cases/compiler/assigningFunctionToTupleIssuesError.ts new file mode 100644 index 00000000000..befea50f81d --- /dev/null +++ b/tests/cases/compiler/assigningFunctionToTupleIssuesError.ts @@ -0,0 +1,2 @@ +declare let a: () => void; +let b: [string] = a; \ No newline at end of file From f4b83ef8d38844ea8f6a51599938aa47796b3b6b Mon Sep 17 00:00:00 2001 From: Ron Buckton Date: Thu, 16 May 2019 20:39:47 -0700 Subject: [PATCH 061/119] Fix newlines in smartSelection baselines to not be platform dependent (#31437) --- src/harness/fourslash.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/harness/fourslash.ts b/src/harness/fourslash.ts index e306d2e338b..df7f0051f3f 100644 --- a/src/harness/fourslash.ts +++ b/src/harness/fourslash.ts @@ -1503,7 +1503,7 @@ Actual: ${stringify(fullActual)}`); } public baselineSmartSelection() { - const n = ts.sys.newLine; + const n = "\n"; const baselineFile = this.getBaselineFileName(); const markers = this.getMarkers(); const fileContent = this.activeFile.content; From eeba30afc81e2c7c8a34a2deb0d4d2375a1c21f6 Mon Sep 17 00:00:00 2001 From: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com> Date: Fri, 17 May 2019 12:50:39 -0700 Subject: [PATCH 062/119] Fix infinite loop: module.exports alias detection (#31436) * Fix infinite loop: module.exports alias detection Previously, module.exports alias detection in the binder could enter an infinite recursion. Now it does not. Notably, there are *two* safeguards: a counter limiter that I set at 100, and an already-seen set. I actually prefer the counter limiter code because it's foolproof and uses less memory. But it takes 100 iterations to escape from loops. * fix space lint * Remove already-seen map --- src/compiler/binder.ts | 38 +++++++++++-------- ...initializedModuleExportsAssignment.symbols | 15 ++++++++ ...UninitializedModuleExportsAssignment.types | 16 ++++++++ ...derUninitializedModuleExportsAssignment.ts | 8 ++++ 4 files changed, 61 insertions(+), 16 deletions(-) create mode 100644 tests/baselines/reference/binderUninitializedModuleExportsAssignment.symbols create mode 100644 tests/baselines/reference/binderUninitializedModuleExportsAssignment.types create mode 100644 tests/cases/conformance/salsa/binderUninitializedModuleExportsAssignment.ts diff --git a/src/compiler/binder.ts b/src/compiler/binder.ts index 96db98d337a..cb6f67d66b1 100644 --- a/src/compiler/binder.ts +++ b/src/compiler/binder.ts @@ -2581,7 +2581,7 @@ namespace ts { // Fix up parent pointers since we're going to use these nodes before we bind into them node.left.parent = node; node.right.parent = node; - if (isIdentifier(lhs.expression) && container === file && isNameOfExportsOrModuleExportsAliasDeclaration(file, lhs.expression)) { + if (isIdentifier(lhs.expression) && container === file && isExportsOrModuleExportsOrAlias(file, lhs.expression)) { // This can be an alias for the 'exports' or 'module.exports' names, e.g. // var util = module.exports; // util.property = function ... @@ -2975,21 +2975,27 @@ namespace ts { } export function isExportsOrModuleExportsOrAlias(sourceFile: SourceFile, node: Expression): boolean { - return isExportsIdentifier(node) || - isModuleExportsPropertyAccessExpression(node) || - isIdentifier(node) && isNameOfExportsOrModuleExportsAliasDeclaration(sourceFile, node); - } - - function isNameOfExportsOrModuleExportsAliasDeclaration(sourceFile: SourceFile, node: Identifier): boolean { - const symbol = lookupSymbolForNameWorker(sourceFile, node.escapedText); - return !!symbol && !!symbol.valueDeclaration && isVariableDeclaration(symbol.valueDeclaration) && - !!symbol.valueDeclaration.initializer && isExportsOrModuleExportsOrAliasOrAssignment(sourceFile, symbol.valueDeclaration.initializer); - } - - function isExportsOrModuleExportsOrAliasOrAssignment(sourceFile: SourceFile, node: Expression): boolean { - return isExportsOrModuleExportsOrAlias(sourceFile, node) || - (isAssignmentExpression(node, /*excludeCompoundAssignment*/ true) && ( - isExportsOrModuleExportsOrAliasOrAssignment(sourceFile, node.left) || isExportsOrModuleExportsOrAliasOrAssignment(sourceFile, node.right))); + let i = 0; + const q = [node]; + while (q.length && i < 100) { + i++; + node = q.shift()!; + if (isExportsIdentifier(node) || isModuleExportsPropertyAccessExpression(node)) { + return true; + } + else if (isIdentifier(node)) { + const symbol = lookupSymbolForNameWorker(sourceFile, node.escapedText); + if (!!symbol && !!symbol.valueDeclaration && isVariableDeclaration(symbol.valueDeclaration) && !!symbol.valueDeclaration.initializer) { + const init = symbol.valueDeclaration.initializer; + q.push(init); + if (isAssignmentExpression(init, /*excludeCompoundAssignment*/ true)) { + q.push(init.left); + q.push(init.right); + } + } + } + } + return false; } function lookupSymbolForNameWorker(container: Node, name: __String): Symbol | undefined { diff --git a/tests/baselines/reference/binderUninitializedModuleExportsAssignment.symbols b/tests/baselines/reference/binderUninitializedModuleExportsAssignment.symbols new file mode 100644 index 00000000000..73777fb2299 --- /dev/null +++ b/tests/baselines/reference/binderUninitializedModuleExportsAssignment.symbols @@ -0,0 +1,15 @@ +=== tests/cases/conformance/salsa/loop.js === +var loop1 = loop2; +>loop1 : Symbol(loop1, Decl(loop.js, 0, 3)) +>loop2 : Symbol(loop2, Decl(loop.js, 1, 3)) + +var loop2 = loop1; +>loop2 : Symbol(loop2, Decl(loop.js, 1, 3)) +>loop1 : Symbol(loop1, Decl(loop.js, 0, 3)) + +module.exports = loop2; +>module.exports : Symbol("tests/cases/conformance/salsa/loop", Decl(loop.js, 0, 0)) +>module : Symbol(export=, Decl(loop.js, 1, 18)) +>exports : Symbol(export=, Decl(loop.js, 1, 18)) +>loop2 : Symbol(loop2, Decl(loop.js, 1, 3)) + diff --git a/tests/baselines/reference/binderUninitializedModuleExportsAssignment.types b/tests/baselines/reference/binderUninitializedModuleExportsAssignment.types new file mode 100644 index 00000000000..c8b8540cc56 --- /dev/null +++ b/tests/baselines/reference/binderUninitializedModuleExportsAssignment.types @@ -0,0 +1,16 @@ +=== tests/cases/conformance/salsa/loop.js === +var loop1 = loop2; +>loop1 : any +>loop2 : any + +var loop2 = loop1; +>loop2 : any +>loop1 : any + +module.exports = loop2; +>module.exports = loop2 : any +>module.exports : any +>module : { "tests/cases/conformance/salsa/loop": any; } +>exports : any +>loop2 : any + diff --git a/tests/cases/conformance/salsa/binderUninitializedModuleExportsAssignment.ts b/tests/cases/conformance/salsa/binderUninitializedModuleExportsAssignment.ts new file mode 100644 index 00000000000..ef3ef213d36 --- /dev/null +++ b/tests/cases/conformance/salsa/binderUninitializedModuleExportsAssignment.ts @@ -0,0 +1,8 @@ +// @noEmit: true +// @allowJs: true +// @checkJs: true +// @Filename: loop.js +var loop1 = loop2; +var loop2 = loop1; + +module.exports = loop2; From d67fe13e3088dbd78f849ec5595c86551b4a2b00 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Fri, 17 May 2019 13:10:09 -0700 Subject: [PATCH 063/119] Don't ignore index signatures in this type constraints --- src/compiler/checker.ts | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 9f5673af3ee..18c1f42f838 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -3563,7 +3563,7 @@ namespace ts { context.approximateLength += 6; return createKeywordTypeNode(SyntaxKind.ObjectKeyword); } - if (type.flags & TypeFlags.TypeParameter && (type as TypeParameter).isThisType) { + if (isThisTypeParameter(type)) { if (context.flags & NodeBuilderFlags.InObjectTypeLiteral) { if (!context.encounteredError && !(context.flags & NodeBuilderFlags.AllowThisInObjectLiteral)) { context.encounteredError = true; @@ -10193,6 +10193,10 @@ namespace ts { return maybeTypeOfKind(type, TypeFlags.InstantiableNonPrimitive | TypeFlags.Index); } + function isThisTypeParameter(type: Type): boolean { + return !!(type.flags & TypeFlags.TypeParameter && (type).isThisType); + } + function getSimplifiedType(type: Type, writing: boolean): Type { return type.flags & TypeFlags.IndexedAccess ? getSimplifiedIndexedAccessType(type, writing) : type.flags & TypeFlags.Conditional ? getSimplifiedConditionalType(type, writing) : @@ -16772,7 +16776,7 @@ namespace ts { } function narrowByInKeyword(type: Type, literal: LiteralExpression, assumeTrue: boolean) { - if ((type.flags & (TypeFlags.Union | TypeFlags.Object)) || (type.flags & TypeFlags.TypeParameter && (type as TypeParameter).isThisType)) { + if (type.flags & (TypeFlags.Union | TypeFlags.Object) || isThisTypeParameter(type)) { const propName = escapeLeadingUnderscores(literal.text); return filterType(type, t => isTypePresencePossible(t, propName, assumeTrue)); } @@ -20092,7 +20096,7 @@ namespace ts { return anyType; } if (right.escapedText && !checkAndReportErrorForExtendingInterface(node)) { - reportNonexistentProperty(right, leftType.flags & TypeFlags.TypeParameter && (leftType as TypeParameter).isThisType ? apparentType : leftType); + reportNonexistentProperty(right, isThisTypeParameter(leftType) ? apparentType : leftType); } return errorType; } @@ -20496,7 +20500,7 @@ namespace ts { const effectiveIndexType = isForInVariableForNumericPropertyNames(indexExpression) ? numberType : indexType; const accessFlags = isAssignmentTarget(node) ? - AccessFlags.Writing | (isGenericObjectType(objectType) ? AccessFlags.NoIndexSignatures : 0) : + AccessFlags.Writing | (isGenericObjectType(objectType) && !isThisTypeParameter(objectType) ? AccessFlags.NoIndexSignatures : 0) : AccessFlags.None; const indexedAccessType = getIndexedAccessTypeOrUndefined(objectType, effectiveIndexType, node, accessFlags) || errorType; return checkIndexedAccessIndexType(indexedAccessType, node); From c6a670d26cddfe97790e2f3c2d4c1670860b2b2f Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Fri, 17 May 2019 15:59:01 -0700 Subject: [PATCH 064/119] Add regression test --- .../conformance/types/keyof/keyofAndIndexedAccess2.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts b/tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts index 5251a83bb06..a99c2b0a7a1 100644 --- a/tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts +++ b/tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts @@ -138,3 +138,12 @@ function fn4() { let x: Array[K] = 'abc'; let y: ReadonlyArray[K] = 'abc'; } + +// Repro from #31439 + +export class c { + [x: string]: string; + constructor() { + this["a"] = "b"; + } +} From 41a3f83b4e8e4ebbfe77446f08d5c1fadf56eee1 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Fri, 17 May 2019 15:59:07 -0700 Subject: [PATCH 065/119] Accept new baselines --- .../keyofAndIndexedAccess2.errors.txt | 9 +++++++++ .../reference/keyofAndIndexedAccess2.js | 15 +++++++++++++++ .../reference/keyofAndIndexedAccess2.symbols | 14 ++++++++++++++ .../reference/keyofAndIndexedAccess2.types | 18 ++++++++++++++++++ 4 files changed, 56 insertions(+) diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt b/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt index 5b749df2cab..9ebf28f1857 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt +++ b/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt @@ -219,4 +219,13 @@ tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(108,5): error TS23 let x: Array[K] = 'abc'; let y: ReadonlyArray[K] = 'abc'; } + + // Repro from #31439 + + export class c { + [x: string]: string; + constructor() { + this["a"] = "b"; + } + } \ No newline at end of file diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.js b/tests/baselines/reference/keyofAndIndexedAccess2.js index 7bf53b9fba4..374b13b5a64 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.js +++ b/tests/baselines/reference/keyofAndIndexedAccess2.js @@ -136,6 +136,15 @@ function fn4() { let x: Array[K] = 'abc'; let y: ReadonlyArray[K] = 'abc'; } + +// Repro from #31439 + +export class c { + [x: string]: string; + constructor() { + this["a"] = "b"; + } +} //// [keyofAndIndexedAccess2.js] @@ -226,3 +235,9 @@ function fn4() { let x = 'abc'; let y = 'abc'; } +// Repro from #31439 +export class c { + constructor() { + this["a"] = "b"; + } +} diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.symbols b/tests/baselines/reference/keyofAndIndexedAccess2.symbols index 2155451ef74..a3412e8a47d 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.symbols +++ b/tests/baselines/reference/keyofAndIndexedAccess2.symbols @@ -503,3 +503,17 @@ function fn4() { >K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 133, 13)) } +// Repro from #31439 + +export class c { +>c : Symbol(c, Decl(keyofAndIndexedAccess2.ts, 136, 1)) + + [x: string]: string; +>x : Symbol(x, Decl(keyofAndIndexedAccess2.ts, 141, 3)) + + constructor() { + this["a"] = "b"; +>this : Symbol(c, Decl(keyofAndIndexedAccess2.ts, 136, 1)) + } +} + diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.types b/tests/baselines/reference/keyofAndIndexedAccess2.types index af43ed0f4eb..b7b71ba4f9f 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.types +++ b/tests/baselines/reference/keyofAndIndexedAccess2.types @@ -499,3 +499,21 @@ function fn4() { >'abc' : "abc" } +// Repro from #31439 + +export class c { +>c : c + + [x: string]: string; +>x : string + + constructor() { + this["a"] = "b"; +>this["a"] = "b" : "b" +>this["a"] : string +>this : this +>"a" : "a" +>"b" : "b" + } +} + From 309ae224f0cd0c98eb3497b082aa39acd0d796ab Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Mon, 20 May 2019 06:23:30 -0700 Subject: [PATCH 066/119] Cache unnormalized intersection types --- src/compiler/checker.ts | 57 ++++++++++++++++++++++++----------------- 1 file changed, 33 insertions(+), 24 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 18c1f42f838..4a1089ff114 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -391,7 +391,7 @@ namespace ts { const tupleTypes = createMap(); const unionTypes = createMap(); - const intersectionTypes = createMap(); + const intersectionTypes = createMap(); const literalTypes = createMap(); const indexedAccessTypes = createMap(); const substitutionTypes = createMap(); @@ -9838,6 +9838,15 @@ namespace ts { return true; } + function createIntersectionType(types: Type[], aliasSymbol?: Symbol, aliasTypeArguments?: ReadonlyArray) { + const result = createType(TypeFlags.Intersection); + result.objectFlags = getPropagatingFlagsOfTypes(types, /*excludeKinds*/ TypeFlags.Nullable); + result.types = types; + result.aliasSymbol = aliasSymbol; // See comment in `getUnionTypeFromSortedList`. + result.aliasTypeArguments = aliasTypeArguments; + return result; + } + // We normalize combinations of intersection and union types based on the distributive property of the '&' // operator. Specifically, because X & (A | B) is equivalent to X & A | X & B, we can transform intersection // types with union type constituents into equivalent union types with intersection type constituents and @@ -9875,31 +9884,31 @@ namespace ts { if (typeSet.length === 1) { return typeSet[0]; } - if (includes & TypeFlags.Union) { - if (intersectUnionsOfPrimitiveTypes(typeSet)) { - // When the intersection creates a reduced set (which might mean that *all* union types have - // disappeared), we restart the operation to get a new set of combined flags. Once we have - // reduced we'll never reduce again, so this occurs at most once. - return getIntersectionType(typeSet, aliasSymbol, aliasTypeArguments); - } - // We are attempting to construct a type of the form X & (A | B) & Y. Transform this into a type of - // the form X & A & Y | X & B & Y and recursively reduce until no union type constituents remain. - const unionIndex = findIndex(typeSet, t => (t.flags & TypeFlags.Union) !== 0); - const unionType = typeSet[unionIndex]; - return getUnionType(map(unionType.types, t => getIntersectionType(replaceElement(typeSet, unionIndex, t))), - UnionReduction.Literal, aliasSymbol, aliasTypeArguments); - } const id = getTypeListId(typeSet); - let type = intersectionTypes.get(id); - if (!type) { - type = createType(TypeFlags.Intersection); - intersectionTypes.set(id, type); - type.objectFlags = getPropagatingFlagsOfTypes(typeSet, /*excludeKinds*/ TypeFlags.Nullable); - type.types = typeSet; - type.aliasSymbol = aliasSymbol; // See comment in `getUnionTypeFromSortedList`. - type.aliasTypeArguments = aliasTypeArguments; + let result = intersectionTypes.get(id); + if (!result) { + if (includes & TypeFlags.Union) { + if (intersectUnionsOfPrimitiveTypes(typeSet)) { + // When the intersection creates a reduced set (which might mean that *all* union types have + // disappeared), we restart the operation to get a new set of combined flags. Once we have + // reduced we'll never reduce again, so this occurs at most once. + result = getIntersectionType(typeSet, aliasSymbol, aliasTypeArguments); + } + else { + // We are attempting to construct a type of the form X & (A | B) & Y. Transform this into a type of + // the form X & A & Y | X & B & Y and recursively reduce until no union type constituents remain. + const unionIndex = findIndex(typeSet, t => (t.flags & TypeFlags.Union) !== 0); + const unionType = typeSet[unionIndex]; + result = getUnionType(map(unionType.types, t => getIntersectionType(replaceElement(typeSet, unionIndex, t))), + UnionReduction.Literal, aliasSymbol, aliasTypeArguments); + } + } + else { + result = createIntersectionType(typeSet, aliasSymbol, aliasTypeArguments); + } + intersectionTypes.set(id, result); } - return type; + return result; } function getTypeFromIntersectionTypeNode(node: IntersectionTypeNode): Type { From 9052804576cefbc239df539e3ddad522568cfb71 Mon Sep 17 00:00:00 2001 From: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com> Date: Mon, 20 May 2019 12:50:29 -0700 Subject: [PATCH 067/119] Test docCommentTemplate for prototype methods (#31477) This works in 3.5, but didn't in 3.2. Adding a test to make sure it stays working. --- .../docCommentTemplatePrototypeMethod.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 tests/cases/fourslash/docCommentTemplatePrototypeMethod.ts diff --git a/tests/cases/fourslash/docCommentTemplatePrototypeMethod.ts b/tests/cases/fourslash/docCommentTemplatePrototypeMethod.ts new file mode 100644 index 00000000000..9031898d52a --- /dev/null +++ b/tests/cases/fourslash/docCommentTemplatePrototypeMethod.ts @@ -0,0 +1,15 @@ +/// +// @Filename: foo.js + +/////** @class */ +////function C() { } +/////*above*/ +////C.prototype.method = /*next*/ function (p) {} + +for (const marker of test.markerNames()) { + verify.docCommentTemplateAt(marker, 8, +`/** + * + * @param {any} p + */`); +} From 0f15bda45fa00f7b0b69305cb4161d2dc4379f1b Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Mon, 20 May 2019 13:31:44 -0700 Subject: [PATCH 068/119] Add failing test --- .../unittests/services/organizeImports.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/testRunner/unittests/services/organizeImports.ts b/src/testRunner/unittests/services/organizeImports.ts index 8116b1e268a..9216a7adf88 100644 --- a/src/testRunner/unittests/services/organizeImports.ts +++ b/src/testRunner/unittests/services/organizeImports.ts @@ -343,6 +343,19 @@ import { } from "lib"; }, libFile); + testOrganizeImports("Unused_false_positive_module_augmentation", + { + path: "/test.d.ts", + content: ` +import { Caseless } from 'caseless'; + +declare module 'caseless' { + interface Caseless { + test(name: KeyType): boolean; + } +}` + }); + testOrganizeImports("Unused_false_positive_shorthand_assignment", { path: "/test.ts", From 6faeee449d0395529ff7cddc37cf00b988f3c6bf Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Mon, 20 May 2019 14:49:28 -0700 Subject: [PATCH 069/119] =?UTF-8?q?Don=E2=80=99t=20remove=20imports=20that?= =?UTF-8?q?=20are=20used=20for=20module=20augmentation,=20just=20remove=20?= =?UTF-8?q?their=20import=20clauses?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/services/organizeImports.ts | 18 ++++++++++++++- .../unittests/services/organizeImports.ts | 4 +++- ...used_false_positive_module_augmentation.ts | 22 +++++++++++++++++++ 3 files changed, 42 insertions(+), 2 deletions(-) create mode 100644 tests/baselines/reference/organizeImports/Unused_false_positive_module_augmentation.ts diff --git a/src/services/organizeImports.ts b/src/services/organizeImports.ts index 5bfa0c74ab1..b6be92fbf9c 100644 --- a/src/services/organizeImports.ts +++ b/src/services/organizeImports.ts @@ -89,7 +89,7 @@ namespace ts.OrganizeImports { const usedImports: ImportDeclaration[] = []; for (const importDecl of oldImports) { - const {importClause} = importDecl; + const { importClause, moduleSpecifier } = importDecl; if (!importClause) { // Imports without import clauses are assumed to be included for their side effects and are not removed. @@ -125,6 +125,14 @@ namespace ts.OrganizeImports { if (name || namedBindings) { usedImports.push(updateImportDeclarationAndClause(importDecl, name, namedBindings)); } + // If a module is imported to be augmented, keep the import declaration, but without an import clause + else if (hasModuleDeclarationMatchingSpecifier(sourceFile, moduleSpecifier)) { + usedImports.push(createImportDeclaration( + importDecl.decorators, + importDecl.modifiers, + /*importClause*/ undefined, + moduleSpecifier)); + } } return usedImports; @@ -135,6 +143,14 @@ namespace ts.OrganizeImports { } } + function hasModuleDeclarationMatchingSpecifier(sourceFile: SourceFile, moduleSpecifier: Expression) { + const moduleSpecifierText = isStringLiteral(moduleSpecifier) && moduleSpecifier.text; + return isString(moduleSpecifierText) && some(sourceFile.statements, statement => + isModuleDeclaration(statement) + && isStringLiteral(statement.name) + && statement.name.text === moduleSpecifierText); + } + function getExternalModuleName(specifier: Expression) { return specifier !== undefined && isStringLiteralLike(specifier) ? specifier.text diff --git a/src/testRunner/unittests/services/organizeImports.ts b/src/testRunner/unittests/services/organizeImports.ts index 9216a7adf88..8003e1867cd 100644 --- a/src/testRunner/unittests/services/organizeImports.ts +++ b/src/testRunner/unittests/services/organizeImports.ts @@ -1,5 +1,5 @@ namespace ts { - describe("unittests:: services:: Organize imports", () => { + describe("unittests:: services:: organizeImports", () => { describe("Sort imports", () => { it("Sort - non-relative vs non-relative", () => { assertSortsBefore( @@ -347,8 +347,10 @@ import { } from "lib"; { path: "/test.d.ts", content: ` +import foo from 'foo'; import { Caseless } from 'caseless'; +declare module 'foo' {} declare module 'caseless' { interface Caseless { test(name: KeyType): boolean; diff --git a/tests/baselines/reference/organizeImports/Unused_false_positive_module_augmentation.ts b/tests/baselines/reference/organizeImports/Unused_false_positive_module_augmentation.ts new file mode 100644 index 00000000000..4eaf184d493 --- /dev/null +++ b/tests/baselines/reference/organizeImports/Unused_false_positive_module_augmentation.ts @@ -0,0 +1,22 @@ +// ==ORIGINAL== + +import foo from 'foo'; +import { Caseless } from 'caseless'; + +declare module 'foo' {} +declare module 'caseless' { + interface Caseless { + test(name: KeyType): boolean; + } +} +// ==ORGANIZED== + +import 'caseless'; +import 'foo'; + +declare module 'foo' {} +declare module 'caseless' { + interface Caseless { + test(name: KeyType): boolean; + } +} \ No newline at end of file From 00cea41b6545ef7405bf8a5709fa9275b154c8a4 Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Thu, 16 May 2019 14:46:10 -0700 Subject: [PATCH 070/119] Add sortText depending scope of symbols Fixes #15024 --- src/harness/fourslash.ts | 112 ++++++++++++---- src/services/completions.ts | 124 ++++++++++++++---- src/services/stringCompletions.ts | 14 +- .../unittests/tsserver/completions.ts | 2 +- .../cases/fourslash/codeCompletionEscaping.ts | 4 +- .../fourslash/completionAfterGlobalThis.ts | 6 +- .../completionEntryForClassMembers.ts | 8 +- .../fourslash/completionEntryInJsFile.ts | 22 +++- .../fourslash/completionInFunctionLikeBody.ts | 4 +- .../fourslash/completionInJSDocFunctionNew.ts | 2 +- .../completionInJSDocFunctionThis.ts | 2 +- tests/cases/fourslash/completionInJsDoc.ts | 2 +- ...pletionListAtEndOfWordInArrowFunction02.ts | 6 +- ...pletionListAtEndOfWordInArrowFunction03.ts | 2 +- ...tInClosedObjectTypeLiteralInSignature04.ts | 6 +- .../completionListInNamedClassExpression.ts | 6 +- ...nUnclosedObjectTypeLiteralInSignature04.ts | 6 +- .../completionListIsGlobalCompletion.ts | 2 +- .../cases/fourslash/completionListKeywords.ts | 9 +- .../fourslash/completionListWithMeanings.ts | 6 +- .../completionListWithModulesFromModule.ts | 12 +- ...pletionListWithModulesInsideModuleScope.ts | 11 +- ...letionListWithModulesOutsideModuleScope.ts | 2 +- .../completionListWithUnresolvedModule.ts | 8 +- .../completionsGeneratorFunctions.ts | 2 +- .../fourslash/completionsImportBaseUrl.ts | 1 + .../completionsImport_augmentation.ts | 2 + ...completionsImport_compilerOptionsModule.ts | 17 ++- .../completionsImport_defaultFalsePositive.ts | 1 + ...letionsImport_default_addToNamedImports.ts | 1 + ...ionsImport_default_addToNamespaceImport.ts | 1 + ...Import_default_alreadyExistedWithRename.ts | 1 + .../completionsImport_default_anonymous.ts | 20 ++- ...letionsImport_default_didNotExistBefore.ts | 1 + ...sImport_default_exportDefaultIdentifier.ts | 10 +- ...nsImport_default_fromMergedDeclarations.ts | 1 + .../completionsImport_exportEquals.ts | 14 +- ...mport_exportEqualsNamespace_noDuplicate.ts | 2 +- ...ompletionsImport_exportEquals_anonymous.ts | 21 ++- .../fourslash/completionsImport_importType.ts | 2 + .../fourslash/completionsImport_keywords.ts | 13 +- .../fourslash/completionsImport_matching.ts | 11 +- .../completionsImport_multipleWithSameName.ts | 14 +- ...mpletionsImport_named_addToNamedImports.ts | 1 + ...mpletionsImport_named_didNotExistBefore.ts | 21 ++- ...tionsImport_named_exportEqualsNamespace.ts | 1 + ...port_named_exportEqualsNamespace_merged.ts | 1 + ...tionsImport_named_namespaceImportExists.ts | 1 + .../completionsImport_notFromIndex.ts | 1 + .../fourslash/completionsImport_ofAlias.ts | 12 +- ...mpletionsImport_ofAlias_preferShortPath.ts | 15 ++- ...pletionsImport_previousTokenIsSemicolon.ts | 1 + .../completionsImport_reExportDefault.ts | 6 +- .../completionsImport_reExport_wrongName.ts | 18 ++- .../fourslash/completionsImport_require.ts | 1 + .../completionsImport_shadowedByLocal.ts | 40 +++--- .../cases/fourslash/completionsImport_tsx.ts | 2 +- .../fourslash/completionsInterfaceElement.ts | 9 +- .../fourslash/completionsJsdocTypeTagCast.ts | 8 +- .../completionsJsxAttributeInitializer.ts | 4 +- .../fourslash/completionsKeywordsExtends.ts | 2 +- .../completionsRecommended_import.ts | 1 + .../completionsRecommended_namespace.ts | 1 + tests/cases/fourslash/completionsThisType.ts | 6 +- .../fourslash/completionsTypeKeywords.ts | 2 +- .../fourslash/doubleUnderscoreCompletions.ts | 4 +- tests/cases/fourslash/fourslash.ts | 10 ++ .../fourslash/getJavaScriptCompletions12.ts | 2 +- .../fourslash/getJavaScriptCompletions13.ts | 21 ++- .../fourslash/getJavaScriptCompletions15.ts | 12 +- .../fourslash/getJavaScriptCompletions20.ts | 9 +- .../getJavaScriptGlobalCompletions1.ts | 2 +- tests/cases/fourslash/importJsNodeModule2.ts | 2 +- .../fourslash/indirectClassInstantiation.ts | 13 +- tests/cases/fourslash/javaScriptClass1.ts | 10 +- tests/cases/fourslash/javaScriptModules12.ts | 44 ++++++- tests/cases/fourslash/javaScriptModules13.ts | 6 +- tests/cases/fourslash/javaScriptModules14.ts | 6 +- tests/cases/fourslash/javaScriptModules16.ts | 2 +- tests/cases/fourslash/javaScriptModules19.ts | 6 +- tests/cases/fourslash/javaScriptPrototype2.ts | 2 +- tests/cases/fourslash/javaScriptPrototype3.ts | 6 +- tests/cases/fourslash/javaScriptPrototype4.ts | 5 +- tests/cases/fourslash/javascriptModules20.ts | 6 +- tests/cases/fourslash/javascriptModules21.ts | 8 +- ...JsdocTypedefTagTypeExpressionCompletion.ts | 2 +- ...sdocTypedefTagTypeExpressionCompletion2.ts | 4 +- ...sdocTypedefTagTypeExpressionCompletion3.ts | 2 +- ...oImportCompletionsInOtherJavaScriptFile.ts | 2 + .../server/jsdocTypedefTagNamespace.ts | 2 +- tests/cases/fourslash/tsxCompletion9.ts | 2 +- .../fourslash/tsxCompletionNonTagLessThan.ts | 19 ++- .../tsxCompletionOnOpeningTagWithoutJSX1.ts | 2 +- 93 files changed, 700 insertions(+), 178 deletions(-) diff --git a/src/harness/fourslash.ts b/src/harness/fourslash.ts index df7f0051f3f..8a0a2bffbd4 100644 --- a/src/harness/fourslash.ts +++ b/src/harness/fourslash.ts @@ -798,8 +798,8 @@ namespace FourSlash { } private verifyCompletionEntry(actual: ts.CompletionEntry, expected: FourSlashInterface.ExpectedCompletionEntry) { - const { insertText, replacementSpan, hasAction, isRecommended, kind, kindModifiers, text, documentation, tags, source, sourceDisplay } = typeof expected === "string" - ? { insertText: undefined, replacementSpan: undefined, hasAction: undefined, isRecommended: undefined, kind: undefined, kindModifiers: undefined, text: undefined, documentation: undefined, tags: undefined, source: undefined, sourceDisplay: undefined } + const { insertText, replacementSpan, hasAction, isRecommended, kind, kindModifiers, text, documentation, tags, source, sourceDisplay, sortText } = typeof expected === "string" + ? { insertText: undefined, replacementSpan: undefined, hasAction: undefined, isRecommended: undefined, kind: undefined, kindModifiers: undefined, text: undefined, documentation: undefined, tags: undefined, source: undefined, sourceDisplay: undefined, sortText: undefined } : expected; if (actual.insertText !== insertText) { @@ -825,6 +825,7 @@ namespace FourSlash { assert.equal(actual.hasAction, hasAction); assert.equal(actual.isRecommended, isRecommended); assert.equal(actual.source, source); + assert.equal(actual.sortText, sortText || ts.Completions.SortText.LocationPriority, this.messageAtLastKnownMarker(`Actual entry: ${JSON.stringify(actual)}`)); if (text !== undefined) { const actualDetails = this.getCompletionEntryDetails(actual.name, actual.source)!; @@ -4434,18 +4435,63 @@ namespace FourSlashInterface { } } export namespace Completion { - const functionEntry = (name: string): ExpectedCompletionEntryObject => ({ name, kind: "function", kindModifiers: "declare" }); - const varEntry = (name: string): ExpectedCompletionEntryObject => ({ name, kind: "var", kindModifiers: "declare" }); - const moduleEntry = (name: string): ExpectedCompletionEntryObject => ({ name, kind: "module", kindModifiers: "declare" }); - const keywordEntry = (name: string): ExpectedCompletionEntryObject => ({ name, kind: "keyword" }); - const methodEntry = (name: string): ExpectedCompletionEntryObject => ({ name, kind: "method", kindModifiers: "declare" }); - const propertyEntry = (name: string): ExpectedCompletionEntryObject => ({ name, kind: "property", kindModifiers: "declare" }); - const interfaceEntry = (name: string): ExpectedCompletionEntryObject => ({ name, kind: "interface", kindModifiers: "declare" }); - const typeEntry = (name: string): ExpectedCompletionEntryObject => ({ name, kind: "type", kindModifiers: "declare" }); + export import SortText = ts.Completions.SortText; + + const functionEntry = (name: string): ExpectedCompletionEntryObject => ({ + name, + kind: "function", + kindModifiers: "declare", + sortText: SortText.GlobalsOrKeywords + }); + const varEntry = (name: string): ExpectedCompletionEntryObject => ({ + name, + kind: "var", + kindModifiers: "declare", + sortText: SortText.GlobalsOrKeywords + }); + const moduleEntry = (name: string): ExpectedCompletionEntryObject => ({ + name, + kind: "module", + kindModifiers: "declare", + sortText: SortText.GlobalsOrKeywords + }); + const keywordEntry = (name: string): ExpectedCompletionEntryObject => ({ + name, + kind: "keyword", + sortText: SortText.GlobalsOrKeywords + }); + const methodEntry = (name: string): ExpectedCompletionEntryObject => ({ + name, + kind: "method", + kindModifiers: "declare", + sortText: SortText.LocationPriority + }); + const propertyEntry = (name: string): ExpectedCompletionEntryObject => ({ + name, + kind: "property", + kindModifiers: "declare", + sortText: SortText.LocationPriority + }); + const interfaceEntry = (name: string): ExpectedCompletionEntryObject => ({ + name, + kind: "interface", + kindModifiers: "declare", + sortText: SortText.GlobalsOrKeywords + }); + const typeEntry = (name: string): ExpectedCompletionEntryObject => ({ + name, + kind: "type", + kindModifiers: "declare", + sortText: SortText.GlobalsOrKeywords + }); const res: ExpectedCompletionEntryObject[] = []; for (let i = ts.SyntaxKind.FirstKeyword; i <= ts.SyntaxKind.LastKeyword; i++) { - res.push({ name: ts.Debug.assertDefined(ts.tokenToString(i)), kind: "keyword" }); + res.push({ + name: ts.Debug.assertDefined(ts.tokenToString(i)), + kind: "keyword", + sortText: SortText.GlobalsOrKeywords + }); } export const keywordsWithUndefined: ReadonlyArray = res; export const keywords: ReadonlyArray = keywordsWithUndefined.filter(k => k.name !== "undefined"); @@ -4552,11 +4598,15 @@ namespace FourSlashInterface { moduleEntry("Intl"), ]; + export const globalThisEntry: ExpectedCompletionEntry = { + name: "globalThis", + kind: "module", + sortText: SortText.GlobalsOrKeywords + }; export const globalTypes = globalTypesPlus([]); - export function globalTypesPlus(plus: ReadonlyArray): ReadonlyArray { return [ - { name: "globalThis", kind: "module" }, + globalThisEntry, ...globalTypeDecls, ...plus, ...typeKeywords, @@ -4605,7 +4655,11 @@ namespace FourSlashInterface { export const classElementInJsKeywords = getInJsKeywords(classElementKeywords); export const constructorParameterKeywords: ReadonlyArray = - ["private", "protected", "public", "readonly"].map((name): ExpectedCompletionEntryObject => ({ name, kind: "keyword" })); + ["private", "protected", "public", "readonly"].map((name): ExpectedCompletionEntryObject => ({ + name, + kind: "keyword", + sortText: SortText.GlobalsOrKeywords + })); export const functionMembers: ReadonlyArray = [ methodEntry("apply"), @@ -4834,13 +4888,18 @@ namespace FourSlashInterface { "await", ].map(keywordEntry); + export const undefinedVarEntry: ExpectedCompletionEntry = { + name: "undefined", + kind: "var", + sortText: SortText.GlobalsOrKeywords + }; // TODO: many of these are inappropriate to always provide export const globalsInsideFunction = (plus: ReadonlyArray): ReadonlyArray => [ { name: "arguments", kind: "local var" }, ...plus, - { name: "globalThis", kind: "module" }, + globalThisEntry, ...globalsVars, - { name: "undefined", kind: "var" }, + undefinedVarEntry, ...globalKeywordsInsideFunction, ]; @@ -4849,10 +4908,10 @@ namespace FourSlashInterface { // TODO: many of these are inappropriate to always provide export const globalsInJsInsideFunction = (plus: ReadonlyArray): ReadonlyArray => [ { name: "arguments", kind: "local var" }, - { name: "globalThis", kind: "module" }, + globalThisEntry, ...globalsVars, ...plus, - { name: "undefined", kind: "var" }, + undefinedVarEntry, ...globalInJsKeywordsInsideFunction, ]; @@ -4990,34 +5049,34 @@ namespace FourSlashInterface { })(); export const globals: ReadonlyArray = [ - { name: "globalThis", kind: "module" }, + globalThisEntry, ...globalsVars, - { name: "undefined", kind: "var" }, + undefinedVarEntry, ...globalKeywords ]; export const globalsInJs: ReadonlyArray = [ - { name: "globalThis", kind: "module" }, + globalThisEntry, ...globalsVars, - { name: "undefined", kind: "var" }, + undefinedVarEntry, ...globalInJsKeywords ]; export function globalsPlus(plus: ReadonlyArray): ReadonlyArray { return [ - { name: "globalThis", kind: "module" }, + globalThisEntry, ...globalsVars, ...plus, - { name: "undefined", kind: "var" }, + undefinedVarEntry, ...globalKeywords]; } export function globalsInJsPlus(plus: ReadonlyArray): ReadonlyArray { return [ - { name: "globalThis", kind: "module" }, + globalThisEntry, ...globalsVars, ...plus, - { name: "undefined", kind: "var" }, + undefinedVarEntry, ...globalInJsKeywords]; } } @@ -5050,6 +5109,7 @@ namespace FourSlashInterface { readonly documentation?: string; readonly sourceDisplay?: string; readonly tags?: ReadonlyArray; + readonly sortText?: ts.Completions.SortText; } export interface VerifyCompletionsOptions { diff --git a/src/services/completions.ts b/src/services/completions.ts index 9d569fbedde..1adfc1e480f 100644 --- a/src/services/completions.ts +++ b/src/services/completions.ts @@ -1,5 +1,12 @@ /* @internal */ namespace ts.Completions { + export enum SortText { + LocationPriority = "0", + SuggestedClassMembers = "1", + GlobalsOrKeywords = "2", + AutoImportSuggestions = "3", + JavascriptIdentifiers = "4" + } export type Log = (message: string) => void; const enum SymbolOriginInfoKind { ThisType, SymbolMemberNoExport, SymbolMemberExport, Export } @@ -22,6 +29,8 @@ namespace ts.Completions { */ type SymbolOriginInfoMap = (SymbolOriginInfo | undefined)[]; + type SymbolSortTextMap = (SortText | undefined)[]; + const enum KeywordCompletionFilters { None, // No keywords All, // Every possible keyword (TODO: This is never appropriate) @@ -78,7 +87,21 @@ namespace ts.Completions { } function completionInfoFromData(sourceFile: SourceFile, typeChecker: TypeChecker, compilerOptions: CompilerOptions, log: Log, completionData: CompletionData, preferences: UserPreferences): CompletionInfo | undefined { - const { symbols, completionKind, isInSnippetScope, isNewIdentifierLocation, location, propertyAccessToConvert, keywordFilters, literals, symbolToOriginInfoMap, recommendedCompletion, isJsxInitializer, insideJsDocTagTypeExpression } = completionData; + const { + symbols, + completionKind, + isInSnippetScope, + isNewIdentifierLocation, + location, + propertyAccessToConvert, + keywordFilters, + literals, + symbolToOriginInfoMap, + recommendedCompletion, + isJsxInitializer, + insideJsDocTagTypeExpression, + symbolToSortTextMap, + } = completionData; if (location && location.parent && isJsxClosingElement(location.parent)) { // In the TypeScript JSX element, if such element is not defined. When users query for completion at closing tag, @@ -93,7 +116,7 @@ namespace ts.Completions { name: tagName.getFullText(sourceFile) + (hasClosingAngleBracket ? "" : ">"), kind: ScriptElementKind.classElement, kindModifiers: undefined, - sortText: "0", + sortText: SortText.LocationPriority, }; return { isGlobalCompletion: false, isMemberCompletion: true, isNewIdentifierLocation: false, entries: [entry] }; } @@ -101,7 +124,22 @@ namespace ts.Completions { const entries: CompletionEntry[] = []; if (isUncheckedFile(sourceFile, compilerOptions)) { - const uniqueNames = getCompletionEntriesFromSymbols(symbols, entries, location, sourceFile, typeChecker, compilerOptions.target!, log, completionKind, preferences, propertyAccessToConvert, isJsxInitializer, recommendedCompletion, symbolToOriginInfoMap); + const uniqueNames = getCompletionEntriesFromSymbols( + symbols, + entries, + location, + sourceFile, + typeChecker, + compilerOptions.target!, + log, + completionKind, + preferences, + propertyAccessToConvert, + isJsxInitializer, + recommendedCompletion, + symbolToOriginInfoMap, + symbolToSortTextMap + ); getJSCompletionEntries(sourceFile, location!.pos, uniqueNames, compilerOptions.target!, entries); // TODO: GH#18217 } else { @@ -109,7 +147,22 @@ namespace ts.Completions { return undefined; } - getCompletionEntriesFromSymbols(symbols, entries, location, sourceFile, typeChecker, compilerOptions.target!, log, completionKind, preferences, propertyAccessToConvert, isJsxInitializer, recommendedCompletion, symbolToOriginInfoMap); + getCompletionEntriesFromSymbols( + symbols, + entries, + location, + sourceFile, + typeChecker, + compilerOptions.target!, + log, + completionKind, + preferences, + propertyAccessToConvert, + isJsxInitializer, + recommendedCompletion, + symbolToOriginInfoMap, + symbolToSortTextMap + ); } if (keywordFilters !== KeywordCompletionFilters.None) { @@ -160,7 +213,7 @@ namespace ts.Completions { name: realName, kind: ScriptElementKind.warning, kindModifiers: "", - sortText: "1" + sortText: SortText.JavascriptIdentifiers }); } }); @@ -169,28 +222,23 @@ namespace ts.Completions { const completionNameForLiteral = (literal: string | number | PseudoBigInt) => typeof literal === "object" ? pseudoBigIntToString(literal) + "n" : JSON.stringify(literal); function createCompletionEntryForLiteral(literal: string | number | PseudoBigInt): CompletionEntry { - return { name: completionNameForLiteral(literal), kind: ScriptElementKind.string, kindModifiers: ScriptElementKindModifier.none, sortText: "0" }; + return { name: completionNameForLiteral(literal), kind: ScriptElementKind.string, kindModifiers: ScriptElementKindModifier.none, sortText: SortText.LocationPriority }; } function createCompletionEntry( symbol: Symbol, + sortText: SortText, location: Node | undefined, sourceFile: SourceFile, typeChecker: TypeChecker, - target: ScriptTarget, - kind: CompletionKind, + name: string, + needsConvertPropertyAccess: boolean, origin: SymbolOriginInfo | undefined, recommendedCompletion: Symbol | undefined, propertyAccessToConvert: PropertyAccessExpression | undefined, isJsxInitializer: IsJsxInitializer | undefined, preferences: UserPreferences, ): CompletionEntry | undefined { - const info = getCompletionEntryDisplayNameForSymbol(symbol, target, origin, kind); - if (!info) { - return undefined; - } - const { name, needsConvertPropertyAccess } = info; - let insertText: string | undefined; let replacementSpan: TextSpan | undefined; if (origin && origin.kind === SymbolOriginInfoKind.ThisType) { @@ -230,7 +278,7 @@ namespace ts.Completions { name, kind: SymbolDisplay.getSymbolKind(typeChecker, symbol, location!), // TODO: GH#18217 kindModifiers: SymbolDisplay.getSymbolModifiers(symbol), - sortText: "0", + sortText, source: getSourceFromOrigin(origin), hasAction: trueOrUndefined(!!origin && originIsExport(origin)), isRecommended: trueOrUndefined(isRecommendedCompletionMatch(symbol, recommendedCompletion, typeChecker)), @@ -266,6 +314,7 @@ namespace ts.Completions { isJsxInitializer?: IsJsxInitializer, recommendedCompletion?: Symbol, symbolToOriginInfoMap?: SymbolOriginInfoMap, + symbolToSortTextMap?: SymbolSortTextMap, ): Map { const start = timestamp(); // Tracks unique names. @@ -275,13 +324,30 @@ namespace ts.Completions { const uniques = createMap(); for (const symbol of symbols) { const origin = symbolToOriginInfoMap ? symbolToOriginInfoMap[getSymbolId(symbol)] : undefined; - const entry = createCompletionEntry(symbol, location, sourceFile, typeChecker, target, kind, origin, recommendedCompletion, propertyAccessToConvert, isJsxInitializer, preferences); - if (!entry) { + const info = getCompletionEntryDisplayNameForSymbol(symbol, target, origin, kind); + if (!info) { + continue; + } + const { name, needsConvertPropertyAccess } = info; + if (uniques.has(name)) { continue; } - const { name } = entry; - if (uniques.has(name)) { + const entry = createCompletionEntry( + symbol, + symbolToSortTextMap && symbolToSortTextMap[getSymbolId(symbol)] || SortText.LocationPriority, + location, + sourceFile, + typeChecker, + name, + needsConvertPropertyAccess, + origin, + recommendedCompletion, + propertyAccessToConvert, + isJsxInitializer, + preferences + ); + if (!entry) { continue; } @@ -321,7 +387,7 @@ namespace ts.Completions { name, kindModifiers: ScriptElementKindModifier.none, kind: ScriptElementKind.label, - sortText: "0" + sortText: SortText.LocationPriority }); } } @@ -358,7 +424,7 @@ namespace ts.Completions { // We don't need to perform character checks here because we're only comparing the // name against 'entryName' (which is known to be good), not building a new // completion entry. - return firstDefined(symbols, (symbol): SymbolCompletion | undefined => { // TODO: Shouldn't need return type annotation (GH#12632) + return firstDefined(symbols, (symbol): SymbolCompletion | undefined => { const origin = symbolToOriginInfoMap[getSymbolId(symbol)]; const info = getCompletionEntryDisplayNameForSymbol(symbol, compilerOptions.target!, origin, completionKind); return info && info.name === entryId.name && getSourceFromOrigin(origin) === entryId.source @@ -512,6 +578,7 @@ namespace ts.Completions { readonly previousToken: Node | undefined; readonly isJsxInitializer: IsJsxInitializer; readonly insideJsDocTagTypeExpression: boolean; + readonly symbolToSortTextMap: SymbolSortTextMap; } type Request = { readonly kind: CompletionDataKind.JsDocTagName | CompletionDataKind.JsDocTag } | { readonly kind: CompletionDataKind.JsDocParameterName, tag: JSDocParameterTag }; @@ -804,6 +871,7 @@ namespace ts.Completions { let keywordFilters = KeywordCompletionFilters.None; let symbols: Symbol[] = []; const symbolToOriginInfoMap: SymbolOriginInfoMap = []; + const symbolToSortTextMap: SymbolSortTextMap = []; if (isRightOfDot) { getTypeScriptMemberSymbols(); @@ -853,7 +921,8 @@ namespace ts.Completions { recommendedCompletion, previousToken, isJsxInitializer, - insideJsDocTagTypeExpression + insideJsDocTagTypeExpression, + symbolToSortTextMap }; type JSDocTagWithTypeExpression = JSDocParameterTag | JSDocPropertyTag | JSDocReturnTag | JSDocTypeTag | JSDocTypedefTag; @@ -1054,6 +1123,12 @@ namespace ts.Completions { const symbolMeanings = (isTypeOnly ? SymbolFlags.None : SymbolFlags.Value) | SymbolFlags.Type | SymbolFlags.Namespace | SymbolFlags.Alias; symbols = Debug.assertEachDefined(typeChecker.getSymbolsInScope(scopeNode, symbolMeanings), "getSymbolsInScope() should all be defined"); + for (const symbol of symbols) { + if (!typeChecker.isArgumentsSymbol(symbol) && + !some(symbol.declarations, d => d.getSourceFile() === sourceFile)) { + symbolToSortTextMap[getSymbolId(symbol)] = SortText.GlobalsOrKeywords; + } + } // Need to insert 'this.' before properties of `this` type, so only do that if `includeInsertTextCompletions` if (preferences.includeCompletionsWithInsertText && scopeNode.kind !== SyntaxKind.SourceFile) { @@ -1062,6 +1137,7 @@ namespace ts.Completions { for (const symbol of getPropertiesForCompletion(thisType, typeChecker)) { symbolToOriginInfoMap[getSymbolId(symbol)] = { kind: SymbolOriginInfoKind.ThisType }; symbols.push(symbol); + symbolToSortTextMap[getSymbolId(symbol)] = SortText.SuggestedClassMembers; } } } @@ -1195,6 +1271,7 @@ namespace ts.Completions { // So in `declare namespace foo {} declare module "foo" { export = foo; }`, there will just be the global completion for `foo`. some(resolvedModuleSymbol.declarations, d => !!d.getSourceFile().externalModuleIndicator)) { symbols.push(resolvedModuleSymbol); + symbolToSortTextMap[getSymbolId(resolvedModuleSymbol)] = SortText.AutoImportSuggestions; symbolToOriginInfoMap[getSymbolId(resolvedModuleSymbol)] = { kind: SymbolOriginInfoKind.Export, moduleSymbol, isDefaultExport: false }; } @@ -1220,6 +1297,7 @@ namespace ts.Completions { const origin: SymbolOriginInfoExport = { kind: SymbolOriginInfoKind.Export, moduleSymbol, isDefaultExport }; if (detailsEntryId || stringContainsCharactersInOrder(getSymbolName(symbol, origin, target).toLowerCase(), tokenTextLowerCase)) { symbols.push(symbol); + symbolToSortTextMap[getSymbolId(symbol)] = SortText.AutoImportSuggestions; symbolToOriginInfoMap[getSymbolId(symbol)] = origin; } } @@ -1941,7 +2019,7 @@ namespace ts.Completions { name: tokenToString(i)!, kind: ScriptElementKind.keyword, kindModifiers: ScriptElementKindModifier.none, - sortText: "0" + sortText: SortText.GlobalsOrKeywords }); } return res; diff --git a/src/services/stringCompletions.ts b/src/services/stringCompletions.ts index aafe9076056..b287ebdb406 100644 --- a/src/services/stringCompletions.ts +++ b/src/services/stringCompletions.ts @@ -21,7 +21,17 @@ namespace ts.Completions.StringCompletions { return convertPathCompletions(completion.paths); case StringLiteralCompletionKind.Properties: { const entries: CompletionEntry[] = []; - getCompletionEntriesFromSymbols(completion.symbols, entries, sourceFile, sourceFile, checker, ScriptTarget.ESNext, log, CompletionKind.String, preferences); // Target will not be used, so arbitrary + getCompletionEntriesFromSymbols( + completion.symbols, + entries, + sourceFile, + sourceFile, + checker, + ScriptTarget.ESNext, + log, + CompletionKind.String, + preferences + ); // Target will not be used, so arbitrary return { isGlobalCompletion: false, isMemberCompletion: true, isNewIdentifierLocation: completion.hasIndexSignature, entries }; } case StringLiteralCompletionKind.Types: { @@ -60,7 +70,7 @@ namespace ts.Completions.StringCompletions { const isGlobalCompletion = false; // We don't want the editor to offer any other completions, such as snippets, inside a comment. const isNewIdentifierLocation = true; // The user may type in a path that doesn't yet exist, creating a "new identifier" with respect to the collection of identifiers the server is aware of. const entries = pathCompletions.map(({ name, kind, span, extension }): CompletionEntry => - ({ name, kind, kindModifiers: kindModifiersFromExtension(extension), sortText: "0", replacementSpan: span })); + ({ name, kind, kindModifiers: kindModifiersFromExtension(extension), sortText: SortText.LocationPriority, replacementSpan: span })); return { isGlobalCompletion, isMemberCompletion: false, isNewIdentifierLocation, entries }; } function kindModifiersFromExtension(extension: Extension | undefined): ScriptElementKindModifier { diff --git a/src/testRunner/unittests/tsserver/completions.ts b/src/testRunner/unittests/tsserver/completions.ts index 0a62f74dc7d..1cd44539d68 100644 --- a/src/testRunner/unittests/tsserver/completions.ts +++ b/src/testRunner/unittests/tsserver/completions.ts @@ -36,7 +36,7 @@ namespace ts.projectSystem { kindModifiers: ScriptElementKindModifier.exportedModifier, name: "foo", replacementSpan: undefined, - sortText: "0", + sortText: Completions.SortText.AutoImportSuggestions, source: "/a", }; assert.deepEqual(response, { diff --git a/tests/cases/fourslash/codeCompletionEscaping.ts b/tests/cases/fourslash/codeCompletionEscaping.ts index e582171575f..bc1ae9662a0 100644 --- a/tests/cases/fourslash/codeCompletionEscaping.ts +++ b/tests/cases/fourslash/codeCompletionEscaping.ts @@ -7,7 +7,7 @@ verify.completions({ marker: "", includes: [ - { name: "__foo", kind: "warning" }, - { name: "___foo", kind: "warning" }, + { name: "__foo", kind: "warning", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "___foo", kind: "warning", sortText: completion.SortText.JavascriptIdentifiers }, ], }); diff --git a/tests/cases/fourslash/completionAfterGlobalThis.ts b/tests/cases/fourslash/completionAfterGlobalThis.ts index f5241d93c6a..bda57b9e0bd 100644 --- a/tests/cases/fourslash/completionAfterGlobalThis.ts +++ b/tests/cases/fourslash/completionAfterGlobalThis.ts @@ -5,8 +5,8 @@ verify.completions({ marker: "", exact: [ - { name: "globalThis", kind: "module" }, + completion.globalThisEntry, ...completion.globalsVars, - { name: "undefined", kind: "var" } - ] + completion.undefinedVarEntry + ].map(e => ({ ...e, sortText: completion.SortText.LocationPriority })) }); diff --git a/tests/cases/fourslash/completionEntryForClassMembers.ts b/tests/cases/fourslash/completionEntryForClassMembers.ts index 6dcfd059c46..d40a8d273bc 100644 --- a/tests/cases/fourslash/completionEntryForClassMembers.ts +++ b/tests/cases/fourslash/completionEntryForClassMembers.ts @@ -130,9 +130,9 @@ verify.completions( marker: "InsideMethod", exact: [ "arguments", - "globalThis", + completion.globalThisEntry, "B", "C", "D", "D1", "D2", "D3", "D4", "D5", "D6", "E", "F", "F2", "G", "G2", "H", "I", "J", "K", "L", "L2", "M", "N", "O", - "undefined", + completion.undefinedVarEntry, ...completion.insideMethodKeywords, ], }, @@ -146,7 +146,9 @@ verify.completions( "classThatStartedWritingIdentifierAfterPrivateModifier", "classThatStartedWritingIdentifierAfterPrivateStaticModifier", ], - exact: ["private", "protected", "public", "static", "abstract", "async", "constructor", "get", "readonly", "set"], + exact: ["private", "protected", "public", "static", "abstract", "async", "constructor", "get", "readonly", "set"].map( + name => ({ name, sortText: completion.SortText.GlobalsOrKeywords }) + ), isNewIdentifierLocation: true, }, { diff --git a/tests/cases/fourslash/completionEntryInJsFile.ts b/tests/cases/fourslash/completionEntryInJsFile.ts index a3492d9de3e..cf460f6fcc9 100644 --- a/tests/cases/fourslash/completionEntryInJsFile.ts +++ b/tests/cases/fourslash/completionEntryInJsFile.ts @@ -12,9 +12,25 @@ ////function foo() { /////*insideFunction*/ ////} +const warnings = [ + { name: "classA", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "Test7", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "foo", sortText: completion.SortText.JavascriptIdentifiers } +]; verify.completions( { marker: "global", exact: completion.globalsInJsPlus(["foo", "classA", "Test7"]) }, - { marker: "class", isNewIdentifierLocation: true, exact: ["classA", "Test7", "foo", ...completion.classElementInJsKeywords] }, - { marker: "constructorParameter", isNewIdentifierLocation: true, exact: ["classA", "Test7", "foo"] }, + { + marker: "class", + isNewIdentifierLocation: true, + exact: [ + ...warnings, + ...completion.classElementInJsKeywords + ] + }, + { + marker: "constructorParameter", + isNewIdentifierLocation: true, + exact: warnings + }, { marker: "insideFunction", exact: completion.globalsInJsInsideFunction(["foo", "classA", "Test7"]) }, -); +); \ No newline at end of file diff --git a/tests/cases/fourslash/completionInFunctionLikeBody.ts b/tests/cases/fourslash/completionInFunctionLikeBody.ts index 8c163ccb3b0..cf3b32ccb39 100644 --- a/tests/cases/fourslash/completionInFunctionLikeBody.ts +++ b/tests/cases/fourslash/completionInFunctionLikeBody.ts @@ -16,7 +16,9 @@ verify.completions( { marker: ["1", "2"], - includes: ["async", "await"], + includes: ["async", "await"].map( + name => ({ name, sortText: completion.SortText.GlobalsOrKeywords }) + ), excludes: ["public", "private", "protected", "constructor", "readonly", "static", "abstract", "get", "set"], }, { marker: ["3", "4"], exact: completion.classElementKeywords, isNewIdentifierLocation: true }, diff --git a/tests/cases/fourslash/completionInJSDocFunctionNew.ts b/tests/cases/fourslash/completionInJSDocFunctionNew.ts index 8cf8502aa20..b343104c328 100644 --- a/tests/cases/fourslash/completionInJSDocFunctionNew.ts +++ b/tests/cases/fourslash/completionInJSDocFunctionNew.ts @@ -5,4 +5,4 @@ /////** @type {function (new: string, string): string} */ ////var f = function () { return new/**/; } -verify.completions({ marker: "", includes: "new" }); +verify.completions({ marker: "", includes: { name: "new", sortText: completion.SortText.JavascriptIdentifiers } }); diff --git a/tests/cases/fourslash/completionInJSDocFunctionThis.ts b/tests/cases/fourslash/completionInJSDocFunctionThis.ts index 4f732fdcec1..8dd1c545e30 100644 --- a/tests/cases/fourslash/completionInJSDocFunctionThis.ts +++ b/tests/cases/fourslash/completionInJSDocFunctionThis.ts @@ -4,4 +4,4 @@ /////** @type {function (this: string, string): string} */ ////var f = function (s) { return this/**/; } -verify.completions({ marker: "", includes: "this" }); +verify.completions({ marker: "", includes: { name: "this", sortText: completion.SortText.JavascriptIdentifiers } }); diff --git a/tests/cases/fourslash/completionInJsDoc.ts b/tests/cases/fourslash/completionInJsDoc.ts index ef438b8f4be..d30a92fe114 100644 --- a/tests/cases/fourslash/completionInJsDoc.ts +++ b/tests/cases/fourslash/completionInJsDoc.ts @@ -57,7 +57,7 @@ verify.completions( { marker: ["1", "2"], includes: ["constructor", "param", "type", "method", "template"] }, { marker: ["3", "15", "16"], exact: [] }, - { marker: ["4", "5", "8"], includes: "number" }, + { marker: ["4", "5", "8"], includes: { name: "number", sortText: completion.SortText.GlobalsOrKeywords } }, { marker: ["6", "7", "14"], exact: undefined }, { marker: ["9", "10", "11", "12", "13"], includes: ["@argument", "@returns"] }, ); diff --git a/tests/cases/fourslash/completionListAtEndOfWordInArrowFunction02.ts b/tests/cases/fourslash/completionListAtEndOfWordInArrowFunction02.ts index 73cd0c29be9..690f01ab793 100644 --- a/tests/cases/fourslash/completionListAtEndOfWordInArrowFunction02.ts +++ b/tests/cases/fourslash/completionListAtEndOfWordInArrowFunction02.ts @@ -5,5 +5,9 @@ verify.completions({ marker: "1", // TODO: should not include 'default' keyword at an expression location - includes: ["d", "defaultIsAnInvalidParameterName", "default"] + includes: [ + "d", + "defaultIsAnInvalidParameterName", + { name: "default", sortText: completion.SortText.GlobalsOrKeywords } + ] }); diff --git a/tests/cases/fourslash/completionListAtEndOfWordInArrowFunction03.ts b/tests/cases/fourslash/completionListAtEndOfWordInArrowFunction03.ts index 0487107d3af..7aea1a726e2 100644 --- a/tests/cases/fourslash/completionListAtEndOfWordInArrowFunction03.ts +++ b/tests/cases/fourslash/completionListAtEndOfWordInArrowFunction03.ts @@ -7,6 +7,6 @@ verify.completions({ includes: [ "defaultIsAnInvalidParameterName", // This should probably stop working in the future. - { name: "default", text: "default", kind: "keyword" }, + { name: "default", text: "default", kind: "keyword", sortText: completion.SortText.GlobalsOrKeywords }, ], }); diff --git a/tests/cases/fourslash/completionListInClosedObjectTypeLiteralInSignature04.ts b/tests/cases/fourslash/completionListInClosedObjectTypeLiteralInSignature04.ts index 2f07107e057..94f109d787a 100644 --- a/tests/cases/fourslash/completionListInClosedObjectTypeLiteralInSignature04.ts +++ b/tests/cases/fourslash/completionListInClosedObjectTypeLiteralInSignature04.ts @@ -7,4 +7,8 @@ //// ////declare function foo(obj: I): { /*1*/ } -verify.completions({ marker: "1", exact: "readonly", isNewIdentifierLocation: true }); +verify.completions({ + marker: "1", + exact: { name: "readonly", sortText: completion.SortText.GlobalsOrKeywords }, + isNewIdentifierLocation: true +}); diff --git a/tests/cases/fourslash/completionListInNamedClassExpression.ts b/tests/cases/fourslash/completionListInNamedClassExpression.ts index 466342ab630..503051310c9 100644 --- a/tests/cases/fourslash/completionListInNamedClassExpression.ts +++ b/tests/cases/fourslash/completionListInNamedClassExpression.ts @@ -11,7 +11,9 @@ verify.completions( { marker: "0", includes: { name: "myClass", text: "(local class) myClass", kind: "local class" } }, { marker: "1", - exact: ["private", "protected", "public", "static", "abstract", "async", "constructor", "get", "readonly", "set"], + exact: ["private", "protected", "public", "static", "abstract", "async", "constructor", "get", "readonly", "set"].map( + name => ({ name, sortText: completion.SortText.GlobalsOrKeywords }) + ), isNewIdentifierLocation: true, - }, + } ); diff --git a/tests/cases/fourslash/completionListInUnclosedObjectTypeLiteralInSignature04.ts b/tests/cases/fourslash/completionListInUnclosedObjectTypeLiteralInSignature04.ts index 587db09d267..52b73aa1f1e 100644 --- a/tests/cases/fourslash/completionListInUnclosedObjectTypeLiteralInSignature04.ts +++ b/tests/cases/fourslash/completionListInUnclosedObjectTypeLiteralInSignature04.ts @@ -7,4 +7,8 @@ //// ////declare function foo(obj: I): { /*1*/ -verify.completions({ marker: "1", exact: "readonly", isNewIdentifierLocation: true }); +verify.completions({ + marker: "1", + exact: { name: "readonly", sortText: completion.SortText.GlobalsOrKeywords } , + isNewIdentifierLocation: true +}); diff --git a/tests/cases/fourslash/completionListIsGlobalCompletion.ts b/tests/cases/fourslash/completionListIsGlobalCompletion.ts index 2a37849c2b8..ea89155a771 100644 --- a/tests/cases/fourslash/completionListIsGlobalCompletion.ts +++ b/tests/cases/fourslash/completionListIsGlobalCompletion.ts @@ -47,6 +47,6 @@ verify.completions( { marker: "10", exact: completion.classElementKeywords, isGlobalCompletion: false, isNewIdentifierLocation: true }, { marker: "13", exact: globals, isGlobalCompletion: false }, { marker: "15", exact: globals, isGlobalCompletion: true, isNewIdentifierLocation: true }, - { marker: "16", exact: [...x, "globalThis", ...completion.globalsVars, "undefined"], isGlobalCompletion: false }, + { marker: "16", exact: [...x, completion.globalThisEntry, ...completion.globalsVars, completion.undefinedVarEntry], isGlobalCompletion: false }, { marker: "17", exact: completion.globalKeywordsPlusUndefined, isGlobalCompletion: false }, ); diff --git a/tests/cases/fourslash/completionListKeywords.ts b/tests/cases/fourslash/completionListKeywords.ts index ed489487b3c..287e5326a90 100644 --- a/tests/cases/fourslash/completionListKeywords.ts +++ b/tests/cases/fourslash/completionListKeywords.ts @@ -4,4 +4,11 @@ /////**/ -verify.completions({ marker: "", exact: ["globalThis", "undefined", ...completion.statementKeywordsWithTypes] }); +verify.completions({ + marker: "", + exact: [ + completion.globalThisEntry, + completion.undefinedVarEntry, + ...completion.statementKeywordsWithTypes + ] +}); diff --git a/tests/cases/fourslash/completionListWithMeanings.ts b/tests/cases/fourslash/completionListWithMeanings.ts index 41df1ed3816..034607d08c0 100644 --- a/tests/cases/fourslash/completionListWithMeanings.ts +++ b/tests/cases/fourslash/completionListWithMeanings.ts @@ -16,7 +16,7 @@ ////var zz = { x: 4, y: 3 }; const values: ReadonlyArray = [ - "globalThis", + completion.globalThisEntry, { name: "m2", text: "namespace m2" }, // With no type side, allowed only in value { name: "m3", text: "namespace m3" }, { name: "xx", text: "var xx: number" }, @@ -24,12 +24,12 @@ const values: ReadonlyArray = [ { name: "yy", text: "var yy: point" }, { name: "kk", text: "var kk: m3.point3" }, { name: "zz", text: "var zz: point" }, - "undefined", + completion.undefinedVarEntry, ...completion.statementKeywordsWithTypes, ]; const types: ReadonlyArray = [ - "globalThis", + completion.globalThisEntry, { name: "m", text: "namespace m" }, { name: "m3", text: "namespace m3" }, { name: "point", text: "interface point" }, diff --git a/tests/cases/fourslash/completionListWithModulesFromModule.ts b/tests/cases/fourslash/completionListWithModulesFromModule.ts index dbcbdd79783..fb5f49b1abf 100644 --- a/tests/cases/fourslash/completionListWithModulesFromModule.ts +++ b/tests/cases/fourslash/completionListWithModulesFromModule.ts @@ -263,9 +263,9 @@ verify.completions( { name: "shwvar", text: "var shwvar: string" }, { name: "shwcls", text: "class shwcls" }, "tmp", - "globalThis", + completion.globalThisEntry, ...commonValues, - "undefined", + completion.undefinedVarEntry, ...completion.statementKeywordsWithTypes, ], }, { @@ -273,7 +273,7 @@ verify.completions( exact: [ { name: "shwcls", text: "class shwcls" }, { name: "shwint", text: "interface shwint" }, - "globalThis", + completion.globalThisEntry, ...commonTypes, ...completion.typeKeywords, ] @@ -284,12 +284,12 @@ verify.completions( "Mod1", "iMod1", "tmp", - "globalThis", + completion.globalThisEntry, { name: "shwfn", text: "function shwfn(): void" }, ...commonValues, { name: "shwcls", text: "class shwcls" }, { name: "shwvar", text: "var shwvar: number" }, - "undefined", + completion.undefinedVarEntry, ...completion.statementKeywordsWithTypes, ], }, @@ -298,7 +298,7 @@ verify.completions( exact: [ "Mod1", "iMod1", - "globalThis", + completion.globalThisEntry, ...commonTypes, { name: "shwcls", text: "class shwcls" }, { name: "shwint", text: "interface shwint" }, diff --git a/tests/cases/fourslash/completionListWithModulesInsideModuleScope.ts b/tests/cases/fourslash/completionListWithModulesInsideModuleScope.ts index d1bc6233f72..ad0f2531f86 100644 --- a/tests/cases/fourslash/completionListWithModulesInsideModuleScope.ts +++ b/tests/cases/fourslash/completionListWithModulesInsideModuleScope.ts @@ -328,7 +328,7 @@ verifyGeneral('class', { // from interface in mod1 verify.completions({ marker: "interface", - exact: "readonly", + exact: { name: "readonly", sortText: completion.SortText.GlobalsOrKeywords }, isNewIdentifierLocation: true, }); @@ -376,7 +376,14 @@ verifyGeneral('exportedClass', { }); // from exported interface in mod1 -verify.completions({ marker: "exportedInterface", exact: ["readonly"], isNewIdentifierLocation: true }); +verify.completions({ + marker: "exportedInterface", + exact: [{ + name: "readonly", + sortText: completion.SortText.GlobalsOrKeywords + }], + isNewIdentifierLocation: true +}); // from exported namespace in mod1 verifyExportedNamespace('exportedNamespace'); diff --git a/tests/cases/fourslash/completionListWithModulesOutsideModuleScope.ts b/tests/cases/fourslash/completionListWithModulesOutsideModuleScope.ts index 8b9a13fc5b2..c811316ee82 100644 --- a/tests/cases/fourslash/completionListWithModulesOutsideModuleScope.ts +++ b/tests/cases/fourslash/completionListWithModulesOutsideModuleScope.ts @@ -256,7 +256,7 @@ verify.completions( // from interface scope { marker: "interface", - exact: ["readonly"], + exact: [{ name: "readonly", sortText: completion.SortText.GlobalsOrKeywords }], isNewIdentifierLocation: true, } ); diff --git a/tests/cases/fourslash/completionListWithUnresolvedModule.ts b/tests/cases/fourslash/completionListWithUnresolvedModule.ts index 73c6c52a937..1ef421af7f6 100644 --- a/tests/cases/fourslash/completionListWithUnresolvedModule.ts +++ b/tests/cases/fourslash/completionListWithUnresolvedModule.ts @@ -5,4 +5,10 @@ //// var n: num/**/ ////} -verify.completions({ marker: "", includes: "number" }); +verify.completions({ + marker: "", + includes: { + name: "number", + sortText: completion.SortText.GlobalsOrKeywords + } +}); diff --git a/tests/cases/fourslash/completionsGeneratorFunctions.ts b/tests/cases/fourslash/completionsGeneratorFunctions.ts index 1aea1eb6e4d..b2abd148646 100644 --- a/tests/cases/fourslash/completionsGeneratorFunctions.ts +++ b/tests/cases/fourslash/completionsGeneratorFunctions.ts @@ -18,5 +18,5 @@ verify.completions( { marker: ["a", "b"], exact: undefined, isNewIdentifierLocation: true }, { marker: ["c", "d"], exact: ["baseMethod"], isNewIdentifierLocation: true }, { marker: "e", exact: ["baseMethod"] }, - { marker: "f", includes: ["Number"] }, + { marker: "f", includes: [{ name: "Number", sortText: completion.SortText.GlobalsOrKeywords }] }, ); diff --git a/tests/cases/fourslash/completionsImportBaseUrl.ts b/tests/cases/fourslash/completionsImportBaseUrl.ts index d3fa4d7033e..5f67a7d4d63 100644 --- a/tests/cases/fourslash/completionsImportBaseUrl.ts +++ b/tests/cases/fourslash/completionsImportBaseUrl.ts @@ -25,6 +25,7 @@ verify.completions({ kind: "const", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_augmentation.ts b/tests/cases/fourslash/completionsImport_augmentation.ts index 701af24537f..f01f7f43df1 100644 --- a/tests/cases/fourslash/completionsImport_augmentation.ts +++ b/tests/cases/fourslash/completionsImport_augmentation.ts @@ -21,6 +21,7 @@ verify.completions({ source: "/a", sourceDisplay: "./a", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, { name: "bar", @@ -28,6 +29,7 @@ verify.completions({ source: "/a", sourceDisplay: "./a", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, ], preferences: { diff --git a/tests/cases/fourslash/completionsImport_compilerOptionsModule.ts b/tests/cases/fourslash/completionsImport_compilerOptionsModule.ts index 27ae94d4172..56d4ca9e27d 100644 --- a/tests/cases/fourslash/completionsImport_compilerOptionsModule.ts +++ b/tests/cases/fourslash/completionsImport_compilerOptionsModule.ts @@ -33,9 +33,22 @@ ////const a = import("./a"); // Does not make this an external module ////fo/*dts*/ -verify.completions({ marker: ["b"], excludes: "foo", preferences: { includeCompletionsForModuleExports: true } }); +verify.completions({ + marker: ["b"], + excludes: "foo", + preferences: { includeCompletionsForModuleExports: true } +}); verify.completions({ marker: ["c", "ccheck", "cts", "d", "dcheck", "dts"], - includes: [{ name: "foo", source: "/node_modules/a/index", text: "const foo: 0", kind: "const", kindModifiers: "export,declare", hasAction: true, sourceDisplay: "a" }], + includes: [{ + name: "foo", + source: "/node_modules/a/index", + text: "const foo: 0", + kind: "const", + kindModifiers: "export,declare", + hasAction: true, + sourceDisplay: "a", + sortText: completion.SortText.AutoImportSuggestions + }], preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_defaultFalsePositive.ts b/tests/cases/fourslash/completionsImport_defaultFalsePositive.ts index e077e18105b..28babd929c9 100644 --- a/tests/cases/fourslash/completionsImport_defaultFalsePositive.ts +++ b/tests/cases/fourslash/completionsImport_defaultFalsePositive.ts @@ -22,6 +22,7 @@ verify.completions({ kind: "const", kindModifiers: "export,declare", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_default_addToNamedImports.ts b/tests/cases/fourslash/completionsImport_default_addToNamedImports.ts index 8bd9f194758..c81b93e34b1 100644 --- a/tests/cases/fourslash/completionsImport_default_addToNamedImports.ts +++ b/tests/cases/fourslash/completionsImport_default_addToNamedImports.ts @@ -18,6 +18,7 @@ verify.completions({ kind: "function", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_default_addToNamespaceImport.ts b/tests/cases/fourslash/completionsImport_default_addToNamespaceImport.ts index 8debd787641..1752d00d1b6 100644 --- a/tests/cases/fourslash/completionsImport_default_addToNamespaceImport.ts +++ b/tests/cases/fourslash/completionsImport_default_addToNamespaceImport.ts @@ -17,6 +17,7 @@ verify.completions({ kind: "function", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_default_alreadyExistedWithRename.ts b/tests/cases/fourslash/completionsImport_default_alreadyExistedWithRename.ts index b04a7cacffe..2e1fd6003ba 100644 --- a/tests/cases/fourslash/completionsImport_default_alreadyExistedWithRename.ts +++ b/tests/cases/fourslash/completionsImport_default_alreadyExistedWithRename.ts @@ -17,6 +17,7 @@ verify.completions({ kind: "function", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_default_anonymous.ts b/tests/cases/fourslash/completionsImport_default_anonymous.ts index 720bb3f1c6b..a1eb5da6490 100644 --- a/tests/cases/fourslash/completionsImport_default_anonymous.ts +++ b/tests/cases/fourslash/completionsImport_default_anonymous.ts @@ -14,10 +14,26 @@ goTo.marker("0"); const preferences: FourSlashInterface.UserPreferences = { includeCompletionsForModuleExports: true }; verify.completions( - { marker: "0", exact: ["globalThis", "undefined", ...completion.statementKeywordsWithTypes], preferences }, + { + marker: "0", + exact: [ + completion.globalThisEntry, + completion.undefinedVarEntry, + ...completion.statementKeywordsWithTypes + ], + preferences + }, { marker: "1", - includes: { name: "fooBar", source: "/src/foo-bar", sourceDisplay: "./foo-bar", text: "(property) default: 0", kind: "property", hasAction: true }, + includes: { + name: "fooBar", + source: "/src/foo-bar", + sourceDisplay: "./foo-bar", + text: "(property) default: 0", + kind: "property", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, preferences, }, ); diff --git a/tests/cases/fourslash/completionsImport_default_didNotExistBefore.ts b/tests/cases/fourslash/completionsImport_default_didNotExistBefore.ts index 259a22d637b..333159ae493 100644 --- a/tests/cases/fourslash/completionsImport_default_didNotExistBefore.ts +++ b/tests/cases/fourslash/completionsImport_default_didNotExistBefore.ts @@ -18,6 +18,7 @@ verify.completions({ kind: "function", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_default_exportDefaultIdentifier.ts b/tests/cases/fourslash/completionsImport_default_exportDefaultIdentifier.ts index 766f50fb9e9..ea332cd7ff7 100644 --- a/tests/cases/fourslash/completionsImport_default_exportDefaultIdentifier.ts +++ b/tests/cases/fourslash/completionsImport_default_exportDefaultIdentifier.ts @@ -14,7 +14,15 @@ goTo.marker(""); verify.completions({ marker: "", - includes: { name: "foo", source: "/a", sourceDisplay: "./a", text: "(alias) const foo: 0\nexport default foo", kind: "alias", hasAction: true }, + includes: { + name: "foo", + source: "/a", + sourceDisplay: "./a", + text: "(alias) const foo: 0\nexport default foo", + kind: "alias", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, preferences: { includeCompletionsForModuleExports: true }, }); verify.applyCodeActionFromCompletion("", { diff --git a/tests/cases/fourslash/completionsImport_default_fromMergedDeclarations.ts b/tests/cases/fourslash/completionsImport_default_fromMergedDeclarations.ts index 551cfb54e75..6c86fc18fa5 100644 --- a/tests/cases/fourslash/completionsImport_default_fromMergedDeclarations.ts +++ b/tests/cases/fourslash/completionsImport_default_fromMergedDeclarations.ts @@ -25,6 +25,7 @@ verify.completions({ kind: "class", kindModifiers: "export,declare", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_exportEquals.ts b/tests/cases/fourslash/completionsImport_exportEquals.ts index 37e78e09f38..1ea3e7e637e 100644 --- a/tests/cases/fourslash/completionsImport_exportEquals.ts +++ b/tests/cases/fourslash/completionsImport_exportEquals.ts @@ -17,12 +17,22 @@ const preferences: FourSlashInterface.UserPreferences = { includeCompletionsForM verify.completions( { marker: "0", - includes: { name: "a", source: "/a", hasAction: true, }, + includes: { + name: "a", + source: "/a", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, preferences, }, { marker: "1", - includes: { name: "b", source: "/a", hasAction: true }, + includes: { + name: "b", + source: "/a", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, preferences, } ); diff --git a/tests/cases/fourslash/completionsImport_exportEqualsNamespace_noDuplicate.ts b/tests/cases/fourslash/completionsImport_exportEqualsNamespace_noDuplicate.ts index 8a687f5a191..798c70b2827 100644 --- a/tests/cases/fourslash/completionsImport_exportEqualsNamespace_noDuplicate.ts +++ b/tests/cases/fourslash/completionsImport_exportEqualsNamespace_noDuplicate.ts @@ -18,7 +18,7 @@ verify.completions({ marker: "", // Tester will assert that it is only included once - includes: [{ name: "foo", source: "a", hasAction: true }], + includes: [{ name: "foo", source: "a", hasAction: true, sortText: completion.SortText.AutoImportSuggestions }], preferences: { includeCompletionsForModuleExports: true, } diff --git a/tests/cases/fourslash/completionsImport_exportEquals_anonymous.ts b/tests/cases/fourslash/completionsImport_exportEquals_anonymous.ts index 8fc73457117..b28de47c69d 100644 --- a/tests/cases/fourslash/completionsImport_exportEquals_anonymous.ts +++ b/tests/cases/fourslash/completionsImport_exportEquals_anonymous.ts @@ -12,9 +12,26 @@ goTo.marker("0"); const preferences: FourSlashInterface.UserPreferences = { includeCompletionsForModuleExports: true }; -const exportEntry: FourSlashInterface.ExpectedCompletionEntryObject = { name: "fooBar", source: "/src/foo-bar", sourceDisplay: "./foo-bar", text: "(property) export=: 0", kind: "property", hasAction: true }; +const exportEntry: FourSlashInterface.ExpectedCompletionEntryObject = { + name: "fooBar", + source: "/src/foo-bar", + sourceDisplay: "./foo-bar", + text: "(property) export=: 0", + kind: "property", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions +}; verify.completions( - { marker: "0", exact: ["globalThis", "undefined", exportEntry, ...completion.statementKeywordsWithTypes], preferences }, + { + marker: "0", + exact: [ + completion.globalThisEntry, + completion.undefinedVarEntry, + exportEntry, + ...completion.statementKeywordsWithTypes + ], + preferences + }, { marker: "1", includes: exportEntry, preferences } ); verify.applyCodeActionFromCompletion("0", { diff --git a/tests/cases/fourslash/completionsImport_importType.ts b/tests/cases/fourslash/completionsImport_importType.ts index 3c371980b90..3f4bfa38c3b 100644 --- a/tests/cases/fourslash/completionsImport_importType.ts +++ b/tests/cases/fourslash/completionsImport_importType.ts @@ -21,6 +21,7 @@ verify.completions({ sourceDisplay: "./a", text: "class C", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, { name: "T", @@ -28,6 +29,7 @@ verify.completions({ sourceDisplay: "./a", text: "type T = number", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, ], excludes: "x", diff --git a/tests/cases/fourslash/completionsImport_keywords.ts b/tests/cases/fourslash/completionsImport_keywords.ts index 64bab64c7a8..31d2e1cc6f3 100644 --- a/tests/cases/fourslash/completionsImport_keywords.ts +++ b/tests/cases/fourslash/completionsImport_keywords.ts @@ -34,8 +34,17 @@ verify.completions( { marker: "unique", exact: [ - "globalThis", ...completion.globalsVars, "undefined", - { name: "unique", source: "/a", sourceDisplay: "./a", text: "(alias) const unique: 0\nexport unique", hasAction: true }, + completion.globalThisEntry, + ...completion.globalsVars, + completion.undefinedVarEntry, + { + name: "unique", + source: "/a", + sourceDisplay: "./a", + text: "(alias) const unique: 0\nexport unique", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, ...completion.globalKeywords.filter(e => e.name !== "unique"), ], preferences, diff --git a/tests/cases/fourslash/completionsImport_matching.ts b/tests/cases/fourslash/completionsImport_matching.ts index c6dbac369b9..5282d5b3d3c 100644 --- a/tests/cases/fourslash/completionsImport_matching.ts +++ b/tests/cases/fourslash/completionsImport_matching.ts @@ -17,7 +17,16 @@ verify.completions({ marker: "", includes: ["bdf", "abcdef", "BDF"].map(name => - ({ name, source: "/a", text: `function ${name}(): void`, hasAction: true, kind: "function", kindModifiers: "export", sourceDisplay: "./a" })), + ({ + name, + source: "/a", + text: `function ${name}(): void`, + hasAction: true, + kind: "function", + kindModifiers: "export", + sourceDisplay: "./a", + sortText: completion.SortText.AutoImportSuggestions + })), excludes: ["abcde", "dbf"], preferences: { includeCompletionsForModuleExports: true }, }) diff --git a/tests/cases/fourslash/completionsImport_multipleWithSameName.ts b/tests/cases/fourslash/completionsImport_multipleWithSameName.ts index 5893f6f0fdc..d00a7e0bebb 100644 --- a/tests/cases/fourslash/completionsImport_multipleWithSameName.ts +++ b/tests/cases/fourslash/completionsImport_multipleWithSameName.ts @@ -20,9 +20,15 @@ goTo.marker(""); verify.completions({ marker: "", exact: [ - "globalThis", - { name: "foo", text: "var foo: number", kind: "var", kindModifiers: "declare" }, - "undefined", + completion.globalThisEntry, + { + name: "foo", + text: "var foo: number", + kind: "var", + kindModifiers: "declare", + sortText: completion.SortText.GlobalsOrKeywords + }, + completion.undefinedVarEntry, { name: "foo", source: "/a", @@ -31,6 +37,7 @@ verify.completions({ kind: "const", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, { name: "foo", @@ -40,6 +47,7 @@ verify.completions({ kind: "const", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, ...completion.statementKeywordsWithTypes, ], diff --git a/tests/cases/fourslash/completionsImport_named_addToNamedImports.ts b/tests/cases/fourslash/completionsImport_named_addToNamedImports.ts index 78df2659ade..8e1ec13df79 100644 --- a/tests/cases/fourslash/completionsImport_named_addToNamedImports.ts +++ b/tests/cases/fourslash/completionsImport_named_addToNamedImports.ts @@ -18,6 +18,7 @@ verify.completions({ kind: "function", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_named_didNotExistBefore.ts b/tests/cases/fourslash/completionsImport_named_didNotExistBefore.ts index 5f21db1e376..cb55f859cca 100644 --- a/tests/cases/fourslash/completionsImport_named_didNotExistBefore.ts +++ b/tests/cases/fourslash/completionsImport_named_didNotExistBefore.ts @@ -13,10 +13,23 @@ verify.completions({ marker: "", exact: [ - { name: "Test2", text: "(alias) function Test2(): void\nimport Test2", kind: "alias" }, - "globalThis", - "undefined", - { name: "Test1", source: "/a", sourceDisplay: "./a", text: "function Test1(): void", kind: "function", kindModifiers: "export", hasAction: true }, + { + name: "Test2", + text: "(alias) function Test2(): void\nimport Test2", + kind: "alias" + }, + completion.globalThisEntry, + completion.undefinedVarEntry, + { + name: "Test1", + source: "/a", + sourceDisplay: "./a", + text: "function Test1(): void", + kind: "function", + kindModifiers: "export", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, ...completion.statementKeywordsWithTypes, ], preferences: { includeCompletionsForModuleExports: true }, diff --git a/tests/cases/fourslash/completionsImport_named_exportEqualsNamespace.ts b/tests/cases/fourslash/completionsImport_named_exportEqualsNamespace.ts index 4f4b579fe49..ca866d838fc 100644 --- a/tests/cases/fourslash/completionsImport_named_exportEqualsNamespace.ts +++ b/tests/cases/fourslash/completionsImport_named_exportEqualsNamespace.ts @@ -21,6 +21,7 @@ verify.completions({ kind: "const", kindModifiers: "export,declare", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_named_exportEqualsNamespace_merged.ts b/tests/cases/fourslash/completionsImport_named_exportEqualsNamespace_merged.ts index ec70d205479..bc1d56cfb6a 100644 --- a/tests/cases/fourslash/completionsImport_named_exportEqualsNamespace_merged.ts +++ b/tests/cases/fourslash/completionsImport_named_exportEqualsNamespace_merged.ts @@ -26,6 +26,7 @@ verify.completions({ kind: "const", kindModifiers: "export,declare", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_named_namespaceImportExists.ts b/tests/cases/fourslash/completionsImport_named_namespaceImportExists.ts index 52c33209ca3..c3e254521de 100644 --- a/tests/cases/fourslash/completionsImport_named_namespaceImportExists.ts +++ b/tests/cases/fourslash/completionsImport_named_namespaceImportExists.ts @@ -17,6 +17,7 @@ verify.completions({ kind: "function", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_notFromIndex.ts b/tests/cases/fourslash/completionsImport_notFromIndex.ts index e6aa3e680b1..3df542daeb4 100644 --- a/tests/cases/fourslash/completionsImport_notFromIndex.ts +++ b/tests/cases/fourslash/completionsImport_notFromIndex.ts @@ -26,6 +26,7 @@ for (const [marker, sourceDisplay] of [["0", "./src"], ["1", "./a"], ["2", "../a kind: "const", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_ofAlias.ts b/tests/cases/fourslash/completionsImport_ofAlias.ts index cb6af7910ba..9a9cb4a2b18 100644 --- a/tests/cases/fourslash/completionsImport_ofAlias.ts +++ b/tests/cases/fourslash/completionsImport_ofAlias.ts @@ -22,8 +22,16 @@ verify.completions({ marker: "", includes: [ - "undefined", - { name: "foo", source: "/a", sourceDisplay: "./a", text: "(alias) const foo: 0\nexport foo", kind: "alias", hasAction: true }, + completion.undefinedVarEntry, + { + name: "foo", + source: "/a", + sourceDisplay: "./a", + text: "(alias) const foo: 0\nexport foo", + kind: "alias", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, ...completion.statementKeywordsWithTypes, ], preferences: { includeCompletionsForModuleExports: true }, diff --git a/tests/cases/fourslash/completionsImport_ofAlias_preferShortPath.ts b/tests/cases/fourslash/completionsImport_ofAlias_preferShortPath.ts index 71242bc240a..494b871238f 100644 --- a/tests/cases/fourslash/completionsImport_ofAlias_preferShortPath.ts +++ b/tests/cases/fourslash/completionsImport_ofAlias_preferShortPath.ts @@ -19,9 +19,18 @@ verify.completions({ marker: "", exact: [ - "globalThis", - "undefined", - { name: "foo", source: "/foo/lib/foo", sourceDisplay: "./foo", text: "const foo: 0", kind: "const", kindModifiers: "export", hasAction: true }, + completion.globalThisEntry, + completion.undefinedVarEntry, + { + name: "foo", + source: "/foo/lib/foo", + sourceDisplay: "./foo", + text: "const foo: 0", + kind: "const", + kindModifiers: "export", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, ...completion.statementKeywordsWithTypes, ], preferences: { includeCompletionsForModuleExports: true }, diff --git a/tests/cases/fourslash/completionsImport_previousTokenIsSemicolon.ts b/tests/cases/fourslash/completionsImport_previousTokenIsSemicolon.ts index 7099c4b3072..23924ad3300 100644 --- a/tests/cases/fourslash/completionsImport_previousTokenIsSemicolon.ts +++ b/tests/cases/fourslash/completionsImport_previousTokenIsSemicolon.ts @@ -17,6 +17,7 @@ verify.completions({ kind: "function", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_reExportDefault.ts b/tests/cases/fourslash/completionsImport_reExportDefault.ts index 7f6639c3f13..b67daf7132e 100644 --- a/tests/cases/fourslash/completionsImport_reExportDefault.ts +++ b/tests/cases/fourslash/completionsImport_reExportDefault.ts @@ -15,9 +15,9 @@ verify.completions({ marker: "", exact: [ - "globalThis", + completion.globalThisEntry, ...completion.globalsVars, - "undefined", + completion.undefinedVarEntry, { name: "foo", source: "/a/b/impl", @@ -26,6 +26,7 @@ verify.completions({ kind: "function", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, { name: "foo", @@ -34,6 +35,7 @@ verify.completions({ text: "(alias) function foo(): void\nexport foo", kind: "alias", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, ...completion.globalKeywords, ], diff --git a/tests/cases/fourslash/completionsImport_reExport_wrongName.ts b/tests/cases/fourslash/completionsImport_reExport_wrongName.ts index 31de7ef7d8d..4080fe5cdb7 100644 --- a/tests/cases/fourslash/completionsImport_reExport_wrongName.ts +++ b/tests/cases/fourslash/completionsImport_reExport_wrongName.ts @@ -15,8 +15,22 @@ goTo.marker(""); verify.completions({ marker: "", includes: [ - { name: "x", source: "/a", sourceDisplay: "./a", text: "const x: 0", hasAction: true }, - { name: "y", source: "/index", sourceDisplay: ".", text: "(alias) const y: 0\nexport y", hasAction: true }, + { + name: "x", + source: "/a", + sourceDisplay: "./a", + text: "const x: 0", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, + { + name: "y", + source: "/index", + sourceDisplay: ".", + text: "(alias) const y: 0\nexport y", + hasAction: true, + sortText: completion.SortText.AutoImportSuggestions + }, ], preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_require.ts b/tests/cases/fourslash/completionsImport_require.ts index 892a2495485..836a0e2439e 100644 --- a/tests/cases/fourslash/completionsImport_require.ts +++ b/tests/cases/fourslash/completionsImport_require.ts @@ -19,6 +19,7 @@ verify.completions({ kind: "const", kindModifiers: "export", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/completionsImport_shadowedByLocal.ts b/tests/cases/fourslash/completionsImport_shadowedByLocal.ts index 711386816c0..504702b6cc3 100644 --- a/tests/cases/fourslash/completionsImport_shadowedByLocal.ts +++ b/tests/cases/fourslash/completionsImport_shadowedByLocal.ts @@ -1,16 +1,24 @@ -/// - -// @noLib: true - -// @Filename: /a.ts -////export const foo = 0; - -// @Filename: /b.ts -////const foo = 1; -////fo/**/ - -verify.completions({ - marker: "", - exact: ["globalThis", { name: "foo", text: "const foo: 1" }, "undefined", ...completion.statementKeywordsWithTypes], - preferences: { includeCompletionsForModuleExports: true }, -}); +/// + +// @noLib: true + +// @Filename: /a.ts +////export const foo = 0; + +// @Filename: /b.ts +////const foo = 1; +////fo/**/ + +verify.completions({ + marker: "", + exact: [ + completion.globalThisEntry, + { + name: "foo", + text: "const foo: 1", + }, + completion.undefinedVarEntry, + ...completion.statementKeywordsWithTypes + ], + preferences: { includeCompletionsForModuleExports: true }, +}); diff --git a/tests/cases/fourslash/completionsImport_tsx.ts b/tests/cases/fourslash/completionsImport_tsx.ts index 9fb4d239223..3a495f1a0ce 100644 --- a/tests/cases/fourslash/completionsImport_tsx.ts +++ b/tests/cases/fourslash/completionsImport_tsx.ts @@ -12,7 +12,7 @@ verify.completions({ marker: "", - includes: { name: "Foo", source: "/a", hasAction: true }, + includes: { name: "Foo", source: "/a", hasAction: true, sortText: completion.SortText.AutoImportSuggestions }, excludes: "Bar", preferences: { includeCompletionsForModuleExports: true, diff --git a/tests/cases/fourslash/completionsInterfaceElement.ts b/tests/cases/fourslash/completionsInterfaceElement.ts index 65b1627c8f3..5a00473ce56 100644 --- a/tests/cases/fourslash/completionsInterfaceElement.ts +++ b/tests/cases/fourslash/completionsInterfaceElement.ts @@ -13,4 +13,11 @@ ////interface EndOfFile { f; /*e*/ -verify.completions({ marker: test.markers(), exact: "readonly", isNewIdentifierLocation: true }); +verify.completions({ + marker: test.markers(), + exact: { + name: "readonly", + sortText: completion.SortText.GlobalsOrKeywords + }, + isNewIdentifierLocation: true +}); diff --git a/tests/cases/fourslash/completionsJsdocTypeTagCast.ts b/tests/cases/fourslash/completionsJsdocTypeTagCast.ts index 5eff16bb278..fe9d8b496e2 100644 --- a/tests/cases/fourslash/completionsJsdocTypeTagCast.ts +++ b/tests/cases/fourslash/completionsJsdocTypeTagCast.ts @@ -4,4 +4,10 @@ // @Filename: /a.js ////const x = /** @type {{ s: string }} */ ({ /**/ }); -verify.completions({ marker: "", exact: ["s", "x"] }); +verify.completions({ + marker: "", + exact: [ + "s", + { name: "x", sortText: completion.SortText.JavascriptIdentifiers } + ] +}); diff --git a/tests/cases/fourslash/completionsJsxAttributeInitializer.ts b/tests/cases/fourslash/completionsJsxAttributeInitializer.ts index 44d79b059a6..0d6c2f25123 100644 --- a/tests/cases/fourslash/completionsJsxAttributeInitializer.ts +++ b/tests/cases/fourslash/completionsJsxAttributeInitializer.ts @@ -9,8 +9,8 @@ verify.completions({ marker: "", includes: [ { name: "x", text: "(parameter) x: number", kind: "parameter", insertText: "{x}" }, - { name: "p", text: "(JSX attribute) p: number", kind: "JSX attribute", insertText: "{this.p}" }, - { name: "a b", text: '(JSX attribute) "a b": number', kind: "JSX attribute", insertText: '{this["a b"]}' }, + { name: "p", text: "(JSX attribute) p: number", kind: "JSX attribute", insertText: "{this.p}", sortText: completion.SortText.SuggestedClassMembers }, + { name: "a b", text: '(JSX attribute) "a b": number', kind: "JSX attribute", insertText: '{this["a b"]}', sortText: completion.SortText.SuggestedClassMembers }, ], preferences: { includeInsertTextCompletions: true, diff --git a/tests/cases/fourslash/completionsKeywordsExtends.ts b/tests/cases/fourslash/completionsKeywordsExtends.ts index bd88311b46c..8f0b97a56ea 100644 --- a/tests/cases/fourslash/completionsKeywordsExtends.ts +++ b/tests/cases/fourslash/completionsKeywordsExtends.ts @@ -7,5 +7,5 @@ verify.completions( { marker: "a", exact: undefined }, - { marker: ["b", "c"], includes: "extends" }, + { marker: ["b", "c"], includes: { name: "extends", sortText: completion.SortText.GlobalsOrKeywords } }, ); diff --git a/tests/cases/fourslash/completionsRecommended_import.ts b/tests/cases/fourslash/completionsRecommended_import.ts index 50e3c7b00aa..ccd77136afc 100644 --- a/tests/cases/fourslash/completionsRecommended_import.ts +++ b/tests/cases/fourslash/completionsRecommended_import.ts @@ -28,6 +28,7 @@ const classEntry = (isConstructor: boolean): FourSlashInterface.ExpectedCompleti text: isConstructor ? "constructor Cls(): Cls" : "class Cls", hasAction: true, isRecommended: true, + sortText: completion.SortText.AutoImportSuggestions }); verify.completions( { marker: "b0", includes: classEntry(true), preferences }, diff --git a/tests/cases/fourslash/completionsRecommended_namespace.ts b/tests/cases/fourslash/completionsRecommended_namespace.ts index 0d6e19e7106..1b3d8c56726 100644 --- a/tests/cases/fourslash/completionsRecommended_namespace.ts +++ b/tests/cases/fourslash/completionsRecommended_namespace.ts @@ -38,6 +38,7 @@ verify.completions( kindModifiers: "export", hasAction: true, isRecommended: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }, diff --git a/tests/cases/fourslash/completionsThisType.ts b/tests/cases/fourslash/completionsThisType.ts index 9923f937afc..ec181335cb7 100644 --- a/tests/cases/fourslash/completionsThisType.ts +++ b/tests/cases/fourslash/completionsThisType.ts @@ -14,15 +14,15 @@ verify.completions( { marker: "", includes: [ - { name: "xyz", text: "(method) C.xyz(): any", kind: "method", insertText: "this.xyz" }, - { name: "foo bar", text: '(property) C["foo bar"]: number', kind: "property", insertText: 'this["foo bar"]' }, + { name: "xyz", text: "(method) C.xyz(): any", kind: "method", insertText: "this.xyz", sortText: completion.SortText.SuggestedClassMembers }, + { name: "foo bar", text: '(property) C["foo bar"]: number', kind: "property", insertText: 'this["foo bar"]', sortText: completion.SortText.SuggestedClassMembers }, ], isNewIdentifierLocation: true, preferences, }, { marker: "f", - includes: { name: "x", text: "(property) x: number", kind: "property", insertText: "this.x" }, + includes: { name: "x", text: "(property) x: number", kind: "property", insertText: "this.x", sortText: completion.SortText.SuggestedClassMembers }, preferences, }, ); diff --git a/tests/cases/fourslash/completionsTypeKeywords.ts b/tests/cases/fourslash/completionsTypeKeywords.ts index 4c26e13932e..6817523bc26 100644 --- a/tests/cases/fourslash/completionsTypeKeywords.ts +++ b/tests/cases/fourslash/completionsTypeKeywords.ts @@ -6,5 +6,5 @@ verify.completions({ marker: "", - exact: ["globalThis", "T", ...completion.typeKeywords], + exact: [completion.globalThisEntry, "T", ...completion.typeKeywords], }); diff --git a/tests/cases/fourslash/doubleUnderscoreCompletions.ts b/tests/cases/fourslash/doubleUnderscoreCompletions.ts index 007842edc1b..8d07cdf333f 100644 --- a/tests/cases/fourslash/doubleUnderscoreCompletions.ts +++ b/tests/cases/fourslash/doubleUnderscoreCompletions.ts @@ -12,7 +12,7 @@ verify.completions({ marker: "1", exact: [ { name: "__property", text: "(property) MyObject.__property: number" }, - "MyObject", - "instance", + { name: "MyObject", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "instance", sortText: completion.SortText.JavascriptIdentifiers }, ], }); diff --git a/tests/cases/fourslash/fourslash.ts b/tests/cases/fourslash/fourslash.ts index 4252296d5da..fa9cdd61c2f 100644 --- a/tests/cases/fourslash/fourslash.ts +++ b/tests/cases/fourslash/fourslash.ts @@ -528,6 +528,7 @@ declare namespace FourSlashInterface { readonly isRecommended?: boolean; readonly kind?: string; readonly kindModifiers?: string; + readonly sortText?: completion.SortText; // details readonly text?: string; @@ -650,6 +651,15 @@ declare var cancellation: FourSlashInterface.cancellation; declare var classification: typeof FourSlashInterface.classification; declare namespace completion { type Entry = FourSlashInterface.ExpectedCompletionEntryObject; + export const enum SortText { + LocationPriority = "0", + SuggestedClassMembers = "1", + GlobalsOrKeywords = "2", + AutoImportSuggestions = "3", + JavascriptIdentifiers = "4" + } + export const globalThisEntry: Entry; + export const undefinedVarEntry: Entry; export const globals: ReadonlyArray; export const globalsInJs: ReadonlyArray; export const globalKeywords: ReadonlyArray; diff --git a/tests/cases/fourslash/getJavaScriptCompletions12.ts b/tests/cases/fourslash/getJavaScriptCompletions12.ts index 5534b20b8ea..2848ee27c54 100644 --- a/tests/cases/fourslash/getJavaScriptCompletions12.ts +++ b/tests/cases/fourslash/getJavaScriptCompletions12.ts @@ -26,5 +26,5 @@ verify.completions( { marker: "1", includes: { name: "charCodeAt", kind: "method", kindModifiers: "declare" } }, { marker: ["2", "3", "4"], includes: { name: "toExponential", kind: "method", kindModifiers: "declare" } }, - { marker: "5", includes: { name: "test1", kind: "warning" } }, + { marker: "5", includes: { name: "test1", kind: "warning", sortText: completion.SortText.JavascriptIdentifiers } }, ); diff --git a/tests/cases/fourslash/getJavaScriptCompletions13.ts b/tests/cases/fourslash/getJavaScriptCompletions13.ts index 8c8b4942779..3b8f984cefe 100644 --- a/tests/cases/fourslash/getJavaScriptCompletions13.ts +++ b/tests/cases/fourslash/getJavaScriptCompletions13.ts @@ -14,6 +14,21 @@ ////file2Identifier2./*2*/ verify.completions( - { marker: "1", includes: ["file2Identifier1", "file2Identifier2", "file1Identifier"], excludes: "FooProp" }, - { marker: "2", includes: ["file2Identifier1", "file2Identifier2"], excludes: ["file1Identifier", "FooProp"] }, -) + { + marker: "1", + includes: [ + "file2Identifier1", + "file2Identifier2", + { name: "file1Identifier", sortText: completion.SortText.GlobalsOrKeywords } + ], + excludes: "FooProp" + }, + { + marker: "2", + includes: [ + { name: "file2Identifier1", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "file2Identifier2", sortText: completion.SortText.JavascriptIdentifiers } + ], + excludes: ["file1Identifier", "FooProp"] + }, +); diff --git a/tests/cases/fourslash/getJavaScriptCompletions15.ts b/tests/cases/fourslash/getJavaScriptCompletions15.ts index e46b0780d42..bcbd6ecbf97 100644 --- a/tests/cases/fourslash/getJavaScriptCompletions15.ts +++ b/tests/cases/fourslash/getJavaScriptCompletions15.ts @@ -22,6 +22,16 @@ verify.completions( { marker: "1", includes: "toExponential" }, { marker: "2", includes: "toLowerCase" }, - { marker: "3", exact: ["V", "ref1", "ref2", "require", "v", "x"] }, + { + marker: "3", + exact: [ + "V", + { name: "ref1", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "ref2", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "require", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "v", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "x", sortText: completion.SortText.JavascriptIdentifiers } + ] + }, { marker: "4", includes: "toLowerCase" }, ); diff --git a/tests/cases/fourslash/getJavaScriptCompletions20.ts b/tests/cases/fourslash/getJavaScriptCompletions20.ts index cbe74a4b392..901ac4522c5 100644 --- a/tests/cases/fourslash/getJavaScriptCompletions20.ts +++ b/tests/cases/fourslash/getJavaScriptCompletions20.ts @@ -19,5 +19,12 @@ verify.completions({ marker: "", - exact: ["getName", "getNa", ...completion.functionMembersWithPrototype, "Person", "name", "age"], + exact: [ + "getName", + "getNa", + ...completion.functionMembersWithPrototype, + { name: "Person", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "name", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "age", sortText: completion.SortText.JavascriptIdentifiers } + ], }); diff --git a/tests/cases/fourslash/getJavaScriptGlobalCompletions1.ts b/tests/cases/fourslash/getJavaScriptGlobalCompletions1.ts index 478d472217e..118ca30faeb 100644 --- a/tests/cases/fourslash/getJavaScriptGlobalCompletions1.ts +++ b/tests/cases/fourslash/getJavaScriptGlobalCompletions1.ts @@ -12,4 +12,4 @@ //// //// hello/**/ -verify.completions({ includes: "helloWorld" }); +verify.completions({ includes: { name: "helloWorld", sortText: completion.SortText.JavascriptIdentifiers } }); diff --git a/tests/cases/fourslash/importJsNodeModule2.ts b/tests/cases/fourslash/importJsNodeModule2.ts index 0ceae59b215..1c4cf77926a 100644 --- a/tests/cases/fourslash/importJsNodeModule2.ts +++ b/tests/cases/fourslash/importJsNodeModule2.ts @@ -19,7 +19,7 @@ edit.insert('.'); verify.completions({ exact: [ ...["n", "s", "b"].map(name => ({ name, kind: "property" })), - ...["x", "require"].map(name => ({ name, kind: "warning" })), + ...["x", "require"].map(name => ({ name, kind: "warning", sortText: completion.SortText.JavascriptIdentifiers })), ], }); edit.insert('n.'); diff --git a/tests/cases/fourslash/indirectClassInstantiation.ts b/tests/cases/fourslash/indirectClassInstantiation.ts index 198515dd806..5a871364465 100644 --- a/tests/cases/fourslash/indirectClassInstantiation.ts +++ b/tests/cases/fourslash/indirectClassInstantiation.ts @@ -14,7 +14,18 @@ //// inst2.blah/*b*/; goTo.marker('a'); -verify.completions({ exact: ["property", "TestObj", "constructor", "instance", "class2", "prototype", "blah", "inst2"] }); +verify.completions({ + exact: [ + "property", + { name: "TestObj", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "constructor", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "instance", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "class2", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "prototype", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "blah", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "inst2", sortText: completion.SortText.JavascriptIdentifiers } + ] +}); edit.backspace(); goTo.marker('b'); diff --git a/tests/cases/fourslash/javaScriptClass1.ts b/tests/cases/fourslash/javaScriptClass1.ts index dd4ed33f718..ec3bc3b5ea6 100644 --- a/tests/cases/fourslash/javaScriptClass1.ts +++ b/tests/cases/fourslash/javaScriptClass1.ts @@ -19,7 +19,15 @@ goTo.marker(); edit.insert('.'); -verify.completions({ exact: ["bar", "thing", "union", "Foo", "x"] }); +verify.completions({ + exact: [ + "bar", + "thing", + "union", + { name: "Foo", sortText: completion.SortText.JavascriptIdentifiers }, + { name: "x", sortText: completion.SortText.JavascriptIdentifiers } + ] +}); edit.insert('bar.'); verify.completions({ includes: ["substr"] }); diff --git a/tests/cases/fourslash/javaScriptModules12.ts b/tests/cases/fourslash/javaScriptModules12.ts index 5ca58bc4dc7..0ae594f77c5 100644 --- a/tests/cases/fourslash/javaScriptModules12.ts +++ b/tests/cases/fourslash/javaScriptModules12.ts @@ -27,7 +27,45 @@ //// /*5*/ verify.completions( - { marker: "1", includes: ["x", "a", "b"], excludes: "y" }, - { marker: "2", includes: ["y", "a", "b"], excludes: "x" }, - { marker: ["3", "4", "5"], includes: ["a", "b"], excludes: ["x", "y"] }, + { + marker: "1", + includes: [ + "x", + { name: "a", sortText: completion.SortText.GlobalsOrKeywords }, + { name: "b", sortText: completion.SortText.GlobalsOrKeywords } + ], excludes: "y" + }, + { + marker: "2", + includes: [ + "y", + { name: "a", sortText: completion.SortText.GlobalsOrKeywords }, + { name: "b", sortText: completion.SortText.GlobalsOrKeywords } + ], + excludes: "x" + }, + { + marker: "3", + includes: [ + "a", + { name: "b", sortText: completion.SortText.GlobalsOrKeywords } + ], + excludes: ["x", "y"] + }, + { + marker: "4", + includes: [ + { name: "a", sortText: completion.SortText.GlobalsOrKeywords }, + "b" + ], + excludes: ["x", "y"] + }, + { + marker: ["5"], + includes: [ + { name: "a", sortText: completion.SortText.GlobalsOrKeywords }, + { name: "b", sortText: completion.SortText.GlobalsOrKeywords } + ], + excludes: ["x", "y"] + }, ); diff --git a/tests/cases/fourslash/javaScriptModules13.ts b/tests/cases/fourslash/javaScriptModules13.ts index 62987047862..69fa87157c8 100644 --- a/tests/cases/fourslash/javaScriptModules13.ts +++ b/tests/cases/fourslash/javaScriptModules13.ts @@ -19,7 +19,11 @@ goTo.file('consumer.js'); goTo.marker(); -verify.completions({ marker: "", includes: "y", excludes: "invisible" }); +verify.completions({ + marker: "", + includes: { name: "y", sortText: completion.SortText.GlobalsOrKeywords }, + excludes: "invisible" +}); edit.insert('x.'); verify.completions({ includes: { name: "a", kind: "property" } }); diff --git a/tests/cases/fourslash/javaScriptModules14.ts b/tests/cases/fourslash/javaScriptModules14.ts index 1b564c09636..9f3546625b3 100644 --- a/tests/cases/fourslash/javaScriptModules14.ts +++ b/tests/cases/fourslash/javaScriptModules14.ts @@ -21,4 +21,8 @@ //// var x = require('myMod'); //// /**/; -verify.completions({ marker: "", includes: "y", excludes: "invisible" }); +verify.completions({ + marker: "", + includes: { name: "y", sortText: completion.SortText.GlobalsOrKeywords }, + excludes: "invisible" +}); diff --git a/tests/cases/fourslash/javaScriptModules16.ts b/tests/cases/fourslash/javaScriptModules16.ts index 7c3bb31436d..51107934fb1 100644 --- a/tests/cases/fourslash/javaScriptModules16.ts +++ b/tests/cases/fourslash/javaScriptModules16.ts @@ -18,7 +18,7 @@ edit.insert('.'); verify.completions({ exact: [ ...["n", "s", "b"].map(name => ({ name, kind: "property" })), - ...["x", "require"].map(name => ({ name, kind: "warning" })), + ...["x", "require"].map(name => ({ name, kind: "warning", sortText: completion.SortText.JavascriptIdentifiers })), ], }); edit.insert('n.'); diff --git a/tests/cases/fourslash/javaScriptModules19.ts b/tests/cases/fourslash/javaScriptModules19.ts index 1fe4ae3cfd1..85735b1f092 100644 --- a/tests/cases/fourslash/javaScriptModules19.ts +++ b/tests/cases/fourslash/javaScriptModules19.ts @@ -17,7 +17,11 @@ goTo.file('consumer.js'); goTo.marker(); -verify.completions({ marker: "", includes: "y", excludes: "invisible" }); +verify.completions({ + marker: "", + includes: { name: "y", sortText: completion.SortText.GlobalsOrKeywords }, + excludes: "invisible" +}); edit.insert('x.'); verify.completions({ includes: { name: "a", kind: "property" } }); diff --git a/tests/cases/fourslash/javaScriptPrototype2.ts b/tests/cases/fourslash/javaScriptPrototype2.ts index f8c2e56e1a9..17afc1ed0aa 100644 --- a/tests/cases/fourslash/javaScriptPrototype2.ts +++ b/tests/cases/fourslash/javaScriptPrototype2.ts @@ -31,4 +31,4 @@ verify.completions({ includes: { name: "toFixed", kind: "method", kindModifiers: goTo.marker('3'); edit.insert('.'); // Make sure symbols don't leak out into the constructor -verify.completions({ includes: ["qua", "foo", "bar"].map(name => ({ name, kind: "warning" })) }); +verify.completions({ includes: ["qua", "foo", "bar"].map(name => ({ name, kind: "warning", sortText: completion.SortText.JavascriptIdentifiers })) }); diff --git a/tests/cases/fourslash/javaScriptPrototype3.ts b/tests/cases/fourslash/javaScriptPrototype3.ts index 627f5c39977..72d22b969b2 100644 --- a/tests/cases/fourslash/javaScriptPrototype3.ts +++ b/tests/cases/fourslash/javaScriptPrototype3.ts @@ -22,6 +22,10 @@ verify.completions({ { name: "qua", kind: "property" }, { name: "foo", kind: "method" }, { name: "bar", kind: "method" }, - ...["myCtor", "x", "prototype"].map(name => ({ name, kind: "warning" })), + ...["myCtor", "x", "prototype"].map(name => ({ + name, + kind: "warning", + sortText: completion.SortText.JavascriptIdentifiers + })), ], }); diff --git a/tests/cases/fourslash/javaScriptPrototype4.ts b/tests/cases/fourslash/javaScriptPrototype4.ts index 98deee4f22a..783cea8b9dd 100644 --- a/tests/cases/fourslash/javaScriptPrototype4.ts +++ b/tests/cases/fourslash/javaScriptPrototype4.ts @@ -16,4 +16,7 @@ goTo.marker('1'); edit.insert('.'); // Check members of the function -verify.completions({ includes: ["foo", "bar", "qua"].map(name => ({ name, kind: "warning" })) }); +verify.completions({ + includes: ["foo", "bar", "qua"].map( + name => ({ name, kind: "warning", sortText: completion.SortText.JavascriptIdentifiers })) +}); diff --git a/tests/cases/fourslash/javascriptModules20.ts b/tests/cases/fourslash/javascriptModules20.ts index 8b8f0095959..0135ccea758 100644 --- a/tests/cases/fourslash/javascriptModules20.ts +++ b/tests/cases/fourslash/javascriptModules20.ts @@ -9,4 +9,8 @@ //// import * as mod from "./mod" //// mod./**/ -verify.completions({ marker: "", exact: [{ name: "a", kind: "property" }, { name: "mod", kind: "warning" }] }); +verify.completions({ + marker: "", exact: [ + { name: "a", kind: "property" }, + { name: "mod", kind: "warning", sortText: completion.SortText.JavascriptIdentifiers }] +}); diff --git a/tests/cases/fourslash/javascriptModules21.ts b/tests/cases/fourslash/javascriptModules21.ts index 5a8dd6b872b..9788f3e3ed7 100644 --- a/tests/cases/fourslash/javascriptModules21.ts +++ b/tests/cases/fourslash/javascriptModules21.ts @@ -10,4 +10,10 @@ //// import mod from "./mod" //// mod./**/ -verify.completions({ marker: "", exact: [{ name: "a", kind: "property" }, { name: "mod", kind: "warning" }] }); +verify.completions({ + marker: "", + exact: [ + { name: "a", kind: "property" }, + { name: "mod", kind: "warning", sortText: completion.SortText.JavascriptIdentifiers } + ] +}); diff --git a/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion.ts b/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion.ts index a117bae1b11..5e0247b64a5 100644 --- a/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion.ts +++ b/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion.ts @@ -29,7 +29,7 @@ const typeMembers: ReadonlyArray): ReadonlyArray { - return entries.map(e => ({ ...e, kind: "warning", kindModifiers: undefined })); + return entries.map(e => ({ ...e, kind: "warning", kindModifiers: undefined, sortText: completion.SortText.JavascriptIdentifiers })); } verify.completions( diff --git a/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion2.ts b/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion2.ts index 9cb94689b76..57802d84b44 100644 --- a/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion2.ts +++ b/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion2.ts @@ -28,10 +28,10 @@ function getCompletions(nonWarnings: ReadonlyArray): ReadonlyArray entry.name === name)); - return withKinds.map(entry => nonWarnings.includes(entry.name) ? entry : ({ name: entry.name, kind: "warning" })); + return withKinds.map(entry => nonWarnings.includes(entry.name) ? entry : ({ name: entry.name, kind: "warning", sortText: completion.SortText.JavascriptIdentifiers })); } verify.completions( diff --git a/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion3.ts b/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion3.ts index efe73d9c023..82b0dd9f5e3 100644 --- a/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion3.ts +++ b/tests/cases/fourslash/jsFileJsdocTypedefTagTypeExpressionCompletion3.ts @@ -31,7 +31,7 @@ ////Foo./*valueMemberOfFoo*/; const warnings = (names: ReadonlyArray): ReadonlyArray => - names.map(name => ({ name, kind: "warning" })); + names.map(name => ({ name, kind: "warning", sortText: completion.SortText.JavascriptIdentifiers })); verify.completions( { diff --git a/tests/cases/fourslash/noImportCompletionsInOtherJavaScriptFile.ts b/tests/cases/fourslash/noImportCompletionsInOtherJavaScriptFile.ts index 0848b3e7cc2..6051a5d80fc 100644 --- a/tests/cases/fourslash/noImportCompletionsInOtherJavaScriptFile.ts +++ b/tests/cases/fourslash/noImportCompletionsInOtherJavaScriptFile.ts @@ -32,6 +32,7 @@ goTo.eachMarker(() => { kind: "const", kindModifiers: "export,declare", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); @@ -45,6 +46,7 @@ goTo.eachMarker(() => { kind: "const", kindModifiers: "export,declare", hasAction: true, + sortText: completion.SortText.AutoImportSuggestions }, preferences: { includeCompletionsForModuleExports: true }, }); diff --git a/tests/cases/fourslash/server/jsdocTypedefTagNamespace.ts b/tests/cases/fourslash/server/jsdocTypedefTagNamespace.ts index 0d04b58606f..297238530f0 100644 --- a/tests/cases/fourslash/server/jsdocTypedefTagNamespace.ts +++ b/tests/cases/fourslash/server/jsdocTypedefTagNamespace.ts @@ -17,5 +17,5 @@ verify.completions( { marker: ["1", "3"], includes: ["charAt", "toExponential"] }, - { marker: "2", includes: "age" }, + { marker: "2", includes: { name: "age", sortText: completion.SortText.JavascriptIdentifiers } }, ); diff --git a/tests/cases/fourslash/tsxCompletion9.ts b/tests/cases/fourslash/tsxCompletion9.ts index 21d2c43f676..21261090b4e 100644 --- a/tests/cases/fourslash/tsxCompletion9.ts +++ b/tests/cases/fourslash/tsxCompletion9.ts @@ -18,4 +18,4 @@ for (var i = 1; i <= 10; i++) { verify.completions({ marker: String(i), exact: undefined }); } -verify.completions({ marker: "end", includes: "null" }); +verify.completions({ marker: "end", includes: { name: "null", sortText: completion.SortText.GlobalsOrKeywords } }); diff --git a/tests/cases/fourslash/tsxCompletionNonTagLessThan.ts b/tests/cases/fourslash/tsxCompletionNonTagLessThan.ts index b2b6a046e6b..a0b1f8ffdc3 100644 --- a/tests/cases/fourslash/tsxCompletionNonTagLessThan.ts +++ b/tests/cases/fourslash/tsxCompletionNonTagLessThan.ts @@ -5,7 +5,20 @@ ////[].map Date: Mon, 20 May 2019 16:43:55 -0700 Subject: [PATCH 071/119] Prevent type parameter printing from recuring on the same symbol (#31453) --- src/compiler/checker.ts | 6 ++++++ ...amespaceMergeWithClassConstrainedToSelf.ts | 21 +++++++++++++++++++ 2 files changed, 27 insertions(+) create mode 100644 tests/cases/fourslash/quickinfoForNamespaceMergeWithClassConstrainedToSelf.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 18c1f42f838..e47855ca63c 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -4302,6 +4302,11 @@ namespace ts { function lookupTypeParameterNodes(chain: Symbol[], index: number, context: NodeBuilderContext) { Debug.assert(chain && 0 <= index && index < chain.length); const symbol = chain[index]; + const symbolId = "" + getSymbolId(symbol); + if (context.typeParameterSymbolList && context.typeParameterSymbolList.get(symbolId)) { + return undefined; + } + (context.typeParameterSymbolList || (context.typeParameterSymbolList = createMap())).set(symbolId, true); let typeParameterNodes: ReadonlyArray | ReadonlyArray | undefined; if (context.flags & NodeBuilderFlags.WriteTypeParametersInQualifiedName && index < (chain.length - 1)) { const parentSymbol = symbol; @@ -4628,6 +4633,7 @@ namespace ts { inferTypeParameters: TypeParameter[] | undefined; approximateLength: number; truncating?: boolean; + typeParameterSymbolList?: Map; } function isDefaultBindingContext(location: Node) { diff --git a/tests/cases/fourslash/quickinfoForNamespaceMergeWithClassConstrainedToSelf.ts b/tests/cases/fourslash/quickinfoForNamespaceMergeWithClassConstrainedToSelf.ts new file mode 100644 index 00000000000..e3c982a1203 --- /dev/null +++ b/tests/cases/fourslash/quickinfoForNamespaceMergeWithClassConstrainedToSelf.ts @@ -0,0 +1,21 @@ +/// + + +//// declare namespace AMap { +//// namespace MassMarks { +//// interface Data { +//// style?: number; +//// } +//// } +//// class MassMarks { +//// constructor(data: D[] | string); +//// clear(): void; +//// } +//// } +//// +//// interface MassMarksCustomData extends AMap.MassMarks./*1*/Data { +//// name: string; +//// id: string; +//// } + +verify.quickInfoAt("1", "interface AMap.MassMarks.Data"); From db150517d7fa6261ee9362ba58fec42dd5a2f816 Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Tue, 21 May 2019 09:32:17 -0700 Subject: [PATCH 072/119] Ignore drive letters when comparing casings of the files with forceConsistentCasingInFileNames Fixes #31327 --- src/compiler/program.ts | 5 ++++- src/compiler/utilities.ts | 8 ++++++++ src/testRunner/unittests/moduleResolution.ts | 18 +++++++++++++++++- 3 files changed, 29 insertions(+), 2 deletions(-) diff --git a/src/compiler/program.ts b/src/compiler/program.ts index 2fda6ea49a5..6313cc19902 100644 --- a/src/compiler/program.ts +++ b/src/compiler/program.ts @@ -2232,7 +2232,10 @@ namespace ts { if (isRedirect) { inputName = getProjectReferenceRedirect(fileName) || fileName; } - if (getNormalizedAbsolutePath(checkedName, currentDirectory) !== getNormalizedAbsolutePath(inputName, currentDirectory)) { + // Check if it differs only in drive letters its ok to ignore that error: + const checkedAbsolutePath = getNormalizedAbsolutePathWithoutRoot(checkedName, currentDirectory); + const inputAbsolutePath = getNormalizedAbsolutePathWithoutRoot(inputName, currentDirectory); + if (checkedAbsolutePath !== inputAbsolutePath) { reportFileNamesDifferOnlyInCasingError(inputName, checkedName, refFile, refPos, refEnd); } } diff --git a/src/compiler/utilities.ts b/src/compiler/utilities.ts index 45dc980296b..ac3be6d434b 100644 --- a/src/compiler/utilities.ts +++ b/src/compiler/utilities.ts @@ -7646,6 +7646,14 @@ namespace ts { return root + pathComponents.slice(1).join(directorySeparator); } + export function getNormalizedAbsolutePathWithoutRoot(fileName: string, currentDirectory: string | undefined) { + return getPathWithoutRoot(getNormalizedPathComponents(fileName, currentDirectory)); + } + + function getPathWithoutRoot(pathComponents: ReadonlyArray) { + if (pathComponents.length === 0) return ""; + return pathComponents.slice(1).join(directorySeparator); + } } /* @internal */ diff --git a/src/testRunner/unittests/moduleResolution.ts b/src/testRunner/unittests/moduleResolution.ts index 69560e5449c..4fecc6c09f3 100644 --- a/src/testRunner/unittests/moduleResolution.ts +++ b/src/testRunner/unittests/moduleResolution.ts @@ -530,7 +530,7 @@ export = C; }); }); - describe("unittests:: moduleResolution:: Files with different casing", () => { + describe("unittests:: moduleResolution:: Files with different casing with forceConsistentCasingInFileNames", () => { let library: SourceFile; function test(files: Map, options: CompilerOptions, currentDirectory: string, useCaseSensitiveFileNames: boolean, rootFiles: string[], diagnosticCodes: number[]): void { const getCanonicalFileName = createGetCanonicalFileName(useCaseSensitiveFileNames); @@ -649,6 +649,22 @@ import b = require("./moduleB"); }); test(files, { module: ModuleKind.CommonJS, forceConsistentCasingInFileNames: true }, "/a/B/c", /*useCaseSensitiveFileNames*/ false, ["moduleD.ts"], []); }); + + it("should succeed when the two files in program differ only in drive letter in their names", () => { + const files = createMapFromTemplate({ + "d:/someFolder/moduleA.ts": `import a = require("D:/someFolder/moduleC")`, + "d:/someFolder/moduleB.ts": `import a = require("./moduleC")`, + "D:/someFolder/moduleC.ts": "export const x = 10", + }); + test( + files, + { module: ModuleKind.CommonJS, forceConsistentCasingInFileNames: true }, + "d:/someFolder", + /*useCaseSensitiveFileNames*/ false, + ["d:/someFolder/moduleA.ts", "d:/someFolder/moduleB.ts"], + [] + ); + }); }); describe("unittests:: moduleResolution:: baseUrl augmented module resolution", () => { From 43c7eb77e17e738958bee7b7b9d6fd82c2108655 Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Tue, 21 May 2019 09:38:14 -0700 Subject: [PATCH 073/119] Switch to using File not found message instead of trace message file does not exit Fixes #30872 --- src/compiler/commandLineParser.ts | 4 ++-- .../unittests/config/configurationExtension.ts | 14 +++++--------- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/src/compiler/commandLineParser.ts b/src/compiler/commandLineParser.ts index fbc6d8d6fea..3aaa217fbd0 100644 --- a/src/compiler/commandLineParser.ts +++ b/src/compiler/commandLineParser.ts @@ -2361,7 +2361,7 @@ namespace ts { if (!host.fileExists(extendedConfigPath) && !endsWith(extendedConfigPath, Extension.Json)) { extendedConfigPath = `${extendedConfigPath}.json`; if (!host.fileExists(extendedConfigPath)) { - errors.push(createDiagnostic(Diagnostics.File_0_does_not_exist, extendedConfig)); + errors.push(createDiagnostic(Diagnostics.File_0_not_found, extendedConfig)); return undefined; } } @@ -2372,7 +2372,7 @@ namespace ts { if (resolved.resolvedModule) { return resolved.resolvedModule.resolvedFileName; } - errors.push(createDiagnostic(Diagnostics.File_0_does_not_exist, extendedConfig)); + errors.push(createDiagnostic(Diagnostics.File_0_not_found, extendedConfig)); return undefined; } diff --git a/src/testRunner/unittests/config/configurationExtension.ts b/src/testRunner/unittests/config/configurationExtension.ts index 25e975c0fb2..6c1fc952295 100644 --- a/src/testRunner/unittests/config/configurationExtension.ts +++ b/src/testRunner/unittests/config/configurationExtension.ts @@ -197,13 +197,13 @@ namespace ts { const caseSensitiveBasePath = "/dev/"; const caseSensitiveHost = new fakes.ParseConfigHost(createFileSystem(/*ignoreCase*/ false, caseSensitiveBasePath, "/")); - function verifyDiagnostics(actual: Diagnostic[], expected: {code: number, category: DiagnosticCategory, messageText: string}[]) { + function verifyDiagnostics(actual: Diagnostic[], expected: { code: number; messageText: string; }[]) { assert.isTrue(expected.length === actual.length, `Expected error: ${JSON.stringify(expected)}. Actual error: ${JSON.stringify(actual)}.`); for (let i = 0; i < actual.length; i++) { const actualError = actual[i]; const expectedError = expected[i]; assert.equal(actualError.code, expectedError.code, "Error code mismatch"); - assert.equal(actualError.category, expectedError.category, "Category mismatch"); + assert.equal(actualError.category, DiagnosticCategory.Error, "Category mismatch"); // Should always be error assert.equal(flattenDiagnosticMessageText(actualError.messageText, "\n"), expectedError.messageText); } } @@ -246,7 +246,7 @@ namespace ts { }); } - function testFailure(name: string, entry: string, expectedDiagnostics: { code: number, category: DiagnosticCategory, messageText: string }[]) { + function testFailure(name: string, entry: string, expectedDiagnostics: { code: number; messageText: string; }[]) { it(name, () => { const parsed = getParseCommandLine(entry); verifyDiagnostics(parsed.errors, expectedDiagnostics); @@ -280,26 +280,22 @@ namespace ts { testFailure("can report errors on circular imports", "circular.json", [ { code: 18000, - category: DiagnosticCategory.Error, messageText: `Circularity detected while resolving configuration: ${[combinePaths(basePath, "circular.json"), combinePaths(basePath, "circular2.json"), combinePaths(basePath, "circular.json")].join(" -> ")}` } ]); testFailure("can report missing configurations", "missing.json", [{ - code: 6096, - category: DiagnosticCategory.Message, - messageText: `File './missing2' does not exist.` + code: 6053, + messageText: `File './missing2' not found.` }]); testFailure("can report errors in extended configs", "failure.json", [{ code: 6114, - category: DiagnosticCategory.Error, messageText: `Unknown option 'excludes'. Did you mean 'exclude'?` }]); testFailure("can error when 'extends' is not a string", "extends.json", [{ code: 5024, - category: DiagnosticCategory.Error, messageText: `Compiler option 'extends' requires a value of type string.` }]); From c71423edd6dfc7bf357c9c16f7ef4eae2184d9b7 Mon Sep 17 00:00:00 2001 From: TypeScript Bot Date: Tue, 21 May 2019 13:22:02 -0700 Subject: [PATCH 074/119] Update user baselines (#31496) --- .../user/chrome-devtools-frontend.log | 4 +- tests/baselines/reference/user/uglify-js.log | 113 +++++++++--------- 2 files changed, 58 insertions(+), 59 deletions(-) diff --git a/tests/baselines/reference/user/chrome-devtools-frontend.log b/tests/baselines/reference/user/chrome-devtools-frontend.log index 4fd3354a2bb..bdde6b918c0 100644 --- a/tests/baselines/reference/user/chrome-devtools-frontend.log +++ b/tests/baselines/reference/user/chrome-devtools-frontend.log @@ -4484,9 +4484,7 @@ node_modules/chrome-devtools-frontend/front_end/coverage/CoverageModel.js(175,64 node_modules/chrome-devtools-frontend/front_end/coverage/CoverageModel.js(190,48): error TS2694: Namespace 'Coverage' has no exported member 'RangeUseCount'. node_modules/chrome-devtools-frontend/front_end/coverage/CoverageModel.js(191,11): error TS2403: Subsequent variable declarations must have the same type. Variable 'entry' must be of type '[CSSStyleSheetHeader, any[]]', but here has type 'CoverageInfo'. node_modules/chrome-devtools-frontend/front_end/coverage/CoverageModel.js(197,5): error TS2322: Type '[CSSStyleSheetHeader, any[]][]' is not assignable to type 'CoverageInfo[]'. - Types of property 'pop' are incompatible. - Type '() => [CSSStyleSheetHeader, any[]]' is not assignable to type '() => CoverageInfo'. - Type '[CSSStyleSheetHeader, any[]]' is not assignable to type 'CoverageInfo'. + Type '[CSSStyleSheetHeader, any[]]' is not assignable to type 'CoverageInfo'. node_modules/chrome-devtools-frontend/front_end/coverage/CoverageModel.js(201,31): error TS2694: Namespace 'Coverage' has no exported member 'RangeUseCount'. node_modules/chrome-devtools-frontend/front_end/coverage/CoverageModel.js(202,32): error TS2694: Namespace 'Coverage' has no exported member 'CoverageSegment'. node_modules/chrome-devtools-frontend/front_end/coverage/CoverageModel.js(210,23): error TS2339: Property 'peekLast' does not exist on type 'any[]'. diff --git a/tests/baselines/reference/user/uglify-js.log b/tests/baselines/reference/user/uglify-js.log index eccbc070b89..3c98006c52f 100644 --- a/tests/baselines/reference/user/uglify-js.log +++ b/tests/baselines/reference/user/uglify-js.log @@ -1,66 +1,67 @@ Exit Code: 1 Standard output: node_modules/uglify-js/lib/ast.js(223,38): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/ast.js(894,5): error TS2322: Type '{ _visit: (node: any, descend: any) => any; parent: (n: any) => any; push: typeof push; pop: typeof pop; self: () => any; find_parent: (type: any) => any; has_directive: (type: any) => any; loopcontrol_target: (node: any) => any; in_boolean_context: () => boolean | undefined; }' is not assignable to type 'TreeWalker'. +node_modules/uglify-js/lib/ast.js(906,5): error TS2322: Type '{ _visit: (node: any, descend: any) => any; parent: (n: any) => any; push: typeof push; pop: typeof pop; self: () => any; find_parent: (type: any) => any; has_directive: (type: any) => any; loopcontrol_target: (node: any) => any; in_boolean_context: () => boolean | undefined; }' is not assignable to type 'TreeWalker'. Object literal may only specify known properties, but '_visit' does not exist in type 'TreeWalker'. Did you mean to write 'visit'? -node_modules/uglify-js/lib/ast.js(895,14): error TS2339: Property 'push' does not exist on type 'TreeWalker'. -node_modules/uglify-js/lib/ast.js(902,14): error TS2339: Property 'pop' does not exist on type 'TreeWalker'. -node_modules/uglify-js/lib/ast.js(957,25): error TS2339: Property 'self' does not exist on type 'TreeWalker'. -node_modules/uglify-js/lib/ast.js(958,37): error TS2339: Property 'parent' does not exist on type 'TreeWalker'. -node_modules/uglify-js/lib/compress.js(173,42): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(512,41): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(838,33): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(1094,38): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. -node_modules/uglify-js/lib/compress.js(1108,51): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type 'true | ((node: any) => any)' has no compatible call signatures. -node_modules/uglify-js/lib/compress.js(1172,53): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. -node_modules/uglify-js/lib/compress.js(1213,112): error TS2454: Variable 'args' is used before being assigned. -node_modules/uglify-js/lib/compress.js(1214,29): error TS2532: Object is possibly 'undefined'. -node_modules/uglify-js/lib/compress.js(1223,87): error TS2322: Type 'false' is not assignable to type 'number'. -node_modules/uglify-js/lib/compress.js(1231,29): error TS2322: Type 'false' is not assignable to type 'never'. -node_modules/uglify-js/lib/compress.js(1339,53): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(1440,38): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. -node_modules/uglify-js/lib/compress.js(1550,42): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(1582,41): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(1694,49): error TS2345: Argument of type 'number[]' is not assignable to parameter of type '[number, number, ...never[]]'. +node_modules/uglify-js/lib/ast.js(907,14): error TS2339: Property 'push' does not exist on type 'TreeWalker'. +node_modules/uglify-js/lib/ast.js(914,14): error TS2339: Property 'pop' does not exist on type 'TreeWalker'. +node_modules/uglify-js/lib/ast.js(969,25): error TS2339: Property 'self' does not exist on type 'TreeWalker'. +node_modules/uglify-js/lib/ast.js(970,37): error TS2339: Property 'parent' does not exist on type 'TreeWalker'. +node_modules/uglify-js/lib/compress.js(184,42): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(535,41): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(861,33): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(1121,38): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(1135,51): error TS2349: Cannot invoke an expression whose type lacks a call signature. Type 'true | ((node: any) => any)' has no compatible call signatures. +node_modules/uglify-js/lib/compress.js(1199,53): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(1240,112): error TS2454: Variable 'args' is used before being assigned. +node_modules/uglify-js/lib/compress.js(1241,29): error TS2532: Object is possibly 'undefined'. +node_modules/uglify-js/lib/compress.js(1250,87): error TS2322: Type 'false' is not assignable to type 'number'. +node_modules/uglify-js/lib/compress.js(1258,29): error TS2322: Type 'false' is not assignable to type 'never'. +node_modules/uglify-js/lib/compress.js(1366,53): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(1467,38): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(1577,42): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(1609,41): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(1721,49): error TS2345: Argument of type 'number[]' is not assignable to parameter of type '[number, number, ...never[]]'. Type 'number[]' is missing the following properties from type '[number, number, ...never[]]': 0, 1 -node_modules/uglify-js/lib/compress.js(2017,59): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(2055,53): error TS2345: Argument of type 'any[]' is not assignable to parameter of type '[number, number, ...never[]]'. +node_modules/uglify-js/lib/compress.js(2044,59): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(2082,53): error TS2345: Argument of type 'any[]' is not assignable to parameter of type '[number, number, ...never[]]'. Type 'any[]' is missing the following properties from type '[number, number, ...never[]]': 0, 1 -node_modules/uglify-js/lib/compress.js(2203,34): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(2925,42): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3378,38): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3391,33): error TS2322: Type '"f"' is not assignable to type 'boolean'. -node_modules/uglify-js/lib/compress.js(3525,33): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3578,29): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3595,29): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. -node_modules/uglify-js/lib/compress.js(3620,75): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3694,63): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3879,38): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(3900,24): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. -node_modules/uglify-js/lib/compress.js(3910,28): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. -node_modules/uglify-js/lib/compress.js(4069,21): error TS2403: Subsequent variable declarations must have the same type. Variable 'defs' must be of type 'Dictionary & { set: (key: any, val: any) => Dictionary & { set: ...; add: (key: any, val: any) => Dictionary & { set: ...; add: ...; get: (key: any) => any; del: (key: any) => Dictionary & { set: ...; ... 8 more ...; toObject: () => any; }; ... 5 more ...; toObject: () => any; }; ... 7 more ...; toObject: () => any;...', but here has type 'any'. -node_modules/uglify-js/lib/compress.js(4121,17): error TS2447: The '|=' operator is not allowed for boolean types. Consider using '||' instead. -node_modules/uglify-js/lib/compress.js(4182,45): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(4292,33): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(4589,17): error TS2403: Subsequent variable declarations must have the same type. Variable 'body' must be of type 'any[]', but here has type 'any'. -node_modules/uglify-js/lib/compress.js(4673,37): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(4881,57): error TS2345: Argument of type 'any[]' is not assignable to parameter of type '[RegExp, (string | undefined)?]'. +node_modules/uglify-js/lib/compress.js(2230,34): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(2942,42): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3395,38): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3408,33): error TS2322: Type '"f"' is not assignable to type 'boolean'. +node_modules/uglify-js/lib/compress.js(3542,33): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3595,29): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3612,29): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(3637,75): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3711,63): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3832,12): error TS2339: Property 'push' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(3897,38): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(3918,24): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(3928,28): error TS2339: Property 'parent' does not exist on type 'TreeTransformer'. +node_modules/uglify-js/lib/compress.js(4097,21): error TS2403: Subsequent variable declarations must have the same type. Variable 'defs' must be of type 'Dictionary & { set: (key: any, val: any) => Dictionary & { set: ...; add: (key: any, val: any) => Dictionary & { set: ...; add: ...; get: (key: any) => any; del: (key: any) => Dictionary & { set: ...; ... 8 more ...; toObject: () => any; }; ... 5 more ...; toObject: () => any; }; ... 7 more ...; toObject: () => any;...', but here has type 'any'. +node_modules/uglify-js/lib/compress.js(4149,17): error TS2447: The '|=' operator is not allowed for boolean types. Consider using '||' instead. +node_modules/uglify-js/lib/compress.js(4210,45): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(4320,33): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(4618,17): error TS2403: Subsequent variable declarations must have the same type. Variable 'body' must be of type 'any[]', but here has type 'any'. +node_modules/uglify-js/lib/compress.js(4702,37): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(4910,57): error TS2345: Argument of type 'any[]' is not assignable to parameter of type '[RegExp, (string | undefined)?]'. Property '0' is missing in type 'any[]' but required in type '[RegExp, (string | undefined)?]'. -node_modules/uglify-js/lib/compress.js(5045,45): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(5052,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'code' must be of type 'string', but here has type '{ get: () => string; toString: () => string; indent: () => void; indentation: () => number; current_width: () => number; should_break: () => boolean; has_parens: () => boolean; newline: () => void; print: (str: any) => void; ... 24 more ...; parent: (n: any) => any; }'. -node_modules/uglify-js/lib/compress.js(5056,36): error TS2532: Object is possibly 'undefined'. -node_modules/uglify-js/lib/compress.js(5061,41): error TS2339: Property 'get' does not exist on type 'string'. -node_modules/uglify-js/lib/compress.js(5565,18): error TS2454: Variable 'is_strict_comparison' is used before being assigned. -node_modules/uglify-js/lib/compress.js(6060,25): error TS2367: This condition will always return 'false' since the types 'boolean' and '"f"' have no overlap. -node_modules/uglify-js/lib/compress.js(6087,47): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(6160,39): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(6232,39): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(6238,41): error TS2554: Expected 0 arguments, but got 1. -node_modules/uglify-js/lib/compress.js(6676,43): error TS2454: Variable 'property' is used before being assigned. -node_modules/uglify-js/lib/compress.js(6691,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'value' must be of type 'number', but here has type 'any'. -node_modules/uglify-js/lib/compress.js(6694,46): error TS2339: Property 'has_side_effects' does not exist on type 'number'. -node_modules/uglify-js/lib/compress.js(6700,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'value' must be of type 'number', but here has type 'any'. -node_modules/uglify-js/lib/compress.js(6728,34): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(5074,45): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(5081,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'code' must be of type 'string', but here has type '{ get: () => string; toString: () => string; indent: () => void; indentation: () => number; current_width: () => number; should_break: () => boolean; has_parens: () => boolean; newline: () => void; print: (str: any) => void; ... 24 more ...; parent: (n: any) => any; }'. +node_modules/uglify-js/lib/compress.js(5085,36): error TS2532: Object is possibly 'undefined'. +node_modules/uglify-js/lib/compress.js(5090,41): error TS2339: Property 'get' does not exist on type 'string'. +node_modules/uglify-js/lib/compress.js(5594,18): error TS2454: Variable 'is_strict_comparison' is used before being assigned. +node_modules/uglify-js/lib/compress.js(6105,25): error TS2367: This condition will always return 'false' since the types 'boolean' and '"f"' have no overlap. +node_modules/uglify-js/lib/compress.js(6132,47): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(6205,39): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(6277,39): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(6283,41): error TS2554: Expected 0 arguments, but got 1. +node_modules/uglify-js/lib/compress.js(6728,43): error TS2454: Variable 'property' is used before being assigned. +node_modules/uglify-js/lib/compress.js(6743,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'value' must be of type 'number', but here has type 'any'. +node_modules/uglify-js/lib/compress.js(6746,46): error TS2339: Property 'has_side_effects' does not exist on type 'number'. +node_modules/uglify-js/lib/compress.js(6752,25): error TS2403: Subsequent variable declarations must have the same type. Variable 'value' must be of type 'number', but here has type 'any'. +node_modules/uglify-js/lib/compress.js(6790,34): error TS2554: Expected 0 arguments, but got 1. node_modules/uglify-js/lib/minify.js(167,75): error TS2339: Property 'compress' does not exist on type 'Compressor'. node_modules/uglify-js/lib/mozilla-ast.js(566,33): error TS2554: Expected 0 arguments, but got 1. node_modules/uglify-js/lib/output.js(235,25): error TS2554: Expected 0 arguments, but got 2. From 3f5912995b4fb845ff7ec436dcb40ebfe3816b42 Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Tue, 21 May 2019 14:38:34 -0700 Subject: [PATCH 075/119] Add related span to original declaration on disagreeing variable/property types. --- src/compiler/checker.ts | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index e9dddff64af..9e5c864f6b9 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -5352,7 +5352,7 @@ namespace ts { return type; } else if (declaredType !== errorType && type !== errorType && !isTypeIdenticalTo(declaredType, type)) { - errorNextVariableOrPropertyDeclarationMustHaveSameType(declaredType, declaration, type); + errorNextVariableOrPropertyDeclarationMustHaveSameType(/*firstDeclaration*/ undefined, declaredType, declaration, type); } } return declaredType; @@ -26839,7 +26839,7 @@ namespace ts { if (type !== errorType && declarationType !== errorType && !isTypeIdenticalTo(type, declarationType) && !(symbol.flags & SymbolFlags.Assignment)) { - errorNextVariableOrPropertyDeclarationMustHaveSameType(type, node, declarationType); + errorNextVariableOrPropertyDeclarationMustHaveSameType(symbol.valueDeclaration, type, node, declarationType); } if (node.initializer) { checkTypeAssignableToAndOptionallyElaborate(checkExpressionCached(node.initializer), declarationType, node, node.initializer, /*headMessage*/ undefined); @@ -26859,17 +26859,24 @@ namespace ts { } } - function errorNextVariableOrPropertyDeclarationMustHaveSameType(firstType: Type, nextDeclaration: Declaration, nextType: Type): void { + function errorNextVariableOrPropertyDeclarationMustHaveSameType(firstDeclaration: Declaration | undefined, firstType: Type, nextDeclaration: Declaration, nextType: Type): void { const nextDeclarationName = getNameOfDeclaration(nextDeclaration); const message = nextDeclaration.kind === SyntaxKind.PropertyDeclaration || nextDeclaration.kind === SyntaxKind.PropertySignature ? Diagnostics.Subsequent_property_declarations_must_have_the_same_type_Property_0_must_be_of_type_1_but_here_has_type_2 : Diagnostics.Subsequent_variable_declarations_must_have_the_same_type_Variable_0_must_be_of_type_1_but_here_has_type_2; - error( + const declName = declarationNameToString(nextDeclarationName); + const err = error( nextDeclarationName, message, - declarationNameToString(nextDeclarationName), + declName, typeToString(firstType), - typeToString(nextType)); + typeToString(nextType) + ); + if (firstDeclaration) { + addRelatedInfo(err, + createDiagnosticForNode(firstDeclaration, Diagnostics._0_was_also_declared_here, declName) + ); + } } function areDeclarationFlagsIdentical(left: Declaration, right: Declaration) { From 81d3595058be3ff808ebdc8417f1d206881f7fae Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Tue, 21 May 2019 14:39:11 -0700 Subject: [PATCH 076/119] Accepted baselines. --- tests/baselines/reference/ES5For-of7.errors.txt | 1 + ...onAndModuleWithSameNameAndCommonRoot.errors.txt | 2 ++ .../asyncArrowFunction5_es2017.errors.txt | 1 + .../reference/asyncArrowFunction5_es5.errors.txt | 1 + .../reference/asyncArrowFunction5_es6.errors.txt | 1 + .../asyncArrowFunction9_es2017.errors.txt | 1 + .../reference/asyncArrowFunction9_es5.errors.txt | 1 + .../reference/asyncArrowFunction9_es6.errors.txt | 1 + .../reference/augmentedTypesVar.errors.txt | 1 + tests/baselines/reference/castingTuple.errors.txt | 1 + .../checkMergedGlobalUMDSymbol.errors.txt | 1 + .../classWithDuplicateIdentifier.errors.txt | 2 ++ .../reference/conditionalTypes1.errors.txt | 1 + .../declarationsAndAssignments.errors.txt | 1 + .../reference/duplicateClassElements.errors.txt | 1 + .../duplicateIdentifierInCatchBlock.errors.txt | 1 + .../reference/duplicateLocalVariable1.errors.txt | 1 + .../reference/duplicateLocalVariable2.errors.txt | 1 + .../reference/duplicateLocalVariable3.errors.txt | 1 + .../reference/duplicateLocalVariable4.errors.txt | 3 ++- .../reference/duplicateVariablesWithAny.errors.txt | 4 ++++ .../duplicateVarsAcrossFileBoundaries.errors.txt | 4 ++++ .../reference/dynamicNamesErrors.errors.txt | 1 + .../enumAssignabilityInInheritance.errors.txt | 4 +++- .../reference/for-inStatements.errors.txt | 2 ++ .../for-inStatementsArrayErrors.errors.txt | 2 ++ .../reference/for-inStatementsInvalid.errors.txt | 2 ++ .../forStatementsMultipleInvalidDecl.errors.txt | 14 +++++++++++++- .../reference/functionArgShadowing.errors.txt | 2 ++ .../reference/gettersAndSettersErrors.errors.txt | 1 + ...orSignaturesWithTypeParametersAndAny.errors.txt | 6 +++++- .../reference/interfaceDeclaration1.errors.txt | 1 + .../invalidMultipleVariableDeclarations.errors.txt | 14 +++++++++++++- ...lationDuplicateVariableErrorReported.errors.txt | 3 ++- .../reference/mappedTypeErrors.errors.txt | 4 ++++ ...terfacesWithConflictingPropertyNames.errors.txt | 3 +++ ...atureHandledDeclarationKindForSymbol.errors.txt | 1 + .../missingAndExcessProperties.errors.txt | 4 ++++ .../negateOperatorInvalidOperations.errors.txt | 1 + ...umericStringNamedPropertyEquivalence.errors.txt | 1 + .../objectLiteralContextualTyping.errors.txt | 1 + tests/baselines/reference/objectRest.errors.txt | 1 + ...ionalParamterAndVariableDeclaration2.errors.txt | 1 + ...rderMattersForSignatureGroupIdentity.errors.txt | 1 + .../reference/overloadResolution.errors.txt | 1 + .../overloadResolutionConstructors.errors.txt | 1 + .../parserCastVersusArrowFunction1.errors.txt | 3 +++ .../reference/promiseIdentity2.errors.txt | 3 ++- .../reference/promiseIdentityWithAny2.errors.txt | 4 +++- .../baselines/reference/propertyAccess.errors.txt | 1 + .../propertyIdentityWithPrivacyMismatch.errors.txt | 2 ++ .../reference/reassignStaticProp.errors.txt | 1 + tests/baselines/reference/spreadUnion2.errors.txt | 6 ++++++ .../reference/strictTupleLength.errors.txt | 2 ++ ...TemplateStringsTypeArgumentInference.errors.txt | 1 + ...plateStringsTypeArgumentInferenceES6.errors.txt | 1 + tests/baselines/reference/tupleTypes.errors.txt | 2 ++ .../reference/typeArgumentInference.errors.txt | 1 + ...ArgumentInferenceConstructSignatures.errors.txt | 1 + ...typeArgumentInferenceWithConstraints.errors.txt | 1 + ...ardOfFormTypeOfEqualEqualHasNoEffect.errors.txt | 4 ++++ ...GuardOfFormTypeOfNotEqualHasNoEffect.errors.txt | 4 ++++ .../typeOfEnumAndVarRedeclarations.errors.txt | 2 ++ tests/baselines/reference/typeOfThis.errors.txt | 10 ++++++++++ .../reference/unionTypeEquivalence.errors.txt | 1 + .../reference/unionTypeIdentity.errors.txt | 5 ++++- .../reference/unionTypeLiterals.errors.txt | 4 +++- tests/baselines/reference/varBlock.errors.txt | 1 + tests/baselines/reference/witness.errors.txt | 7 +++++++ 69 files changed, 161 insertions(+), 10 deletions(-) diff --git a/tests/baselines/reference/ES5For-of7.errors.txt b/tests/baselines/reference/ES5For-of7.errors.txt index a3d40f38814..460c7bf4680 100644 --- a/tests/baselines/reference/ES5For-of7.errors.txt +++ b/tests/baselines/reference/ES5For-of7.errors.txt @@ -10,4 +10,5 @@ tests/cases/conformance/statements/for-ofStatements/ES5For-of7.ts(6,9): error TS var x = [w, v]; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'any', but here has type 'any[]'. +!!! related TS6203 tests/cases/conformance/statements/for-ofStatements/ES5For-of7.ts:2:9: 'x' was also declared here. } \ No newline at end of file diff --git a/tests/baselines/reference/FunctionAndModuleWithSameNameAndCommonRoot.errors.txt b/tests/baselines/reference/FunctionAndModuleWithSameNameAndCommonRoot.errors.txt index 20f8e09248a..0a72e6b641d 100644 --- a/tests/baselines/reference/FunctionAndModuleWithSameNameAndCommonRoot.errors.txt +++ b/tests/baselines/reference/FunctionAndModuleWithSameNameAndCommonRoot.errors.txt @@ -24,6 +24,7 @@ tests/cases/conformance/internalModules/DeclarationMerging/test.ts(2,5): error T var fn = A.Point; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'fn' must be of type '() => { x: number; y: number; }', but here has type 'typeof Point'. +!!! related TS6203 tests/cases/conformance/internalModules/DeclarationMerging/test.ts:1:5: 'fn' was also declared here. var cl: { x: number; y: number; } var cl = A.Point(); @@ -46,6 +47,7 @@ tests/cases/conformance/internalModules/DeclarationMerging/test.ts(2,5): error T var fn = B.Point; // not expected to be an error. bug 840000: [corelang] Function of fundule not assignalbe as expected ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'fn' must be of type '() => { x: number; y: number; }', but here has type 'typeof Point'. +!!! related TS6203 tests/cases/conformance/internalModules/DeclarationMerging/test.ts:1:5: 'fn' was also declared here. var cl: { x: number; y: number; } var cl = B.Point(); diff --git a/tests/baselines/reference/asyncArrowFunction5_es2017.errors.txt b/tests/baselines/reference/asyncArrowFunction5_es2017.errors.txt index 28ddb3bb9b9..26601467324 100644 --- a/tests/baselines/reference/asyncArrowFunction5_es2017.errors.txt +++ b/tests/baselines/reference/asyncArrowFunction5_es2017.errors.txt @@ -16,6 +16,7 @@ tests/cases/conformance/async/es2017/asyncArrowFunction/asyncArrowFunction5_es20 !!! error TS1005: ',' expected. ~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'Promise' must be of type 'PromiseConstructor', but here has type 'any'. +!!! related TS6203 /.ts/lib.es2015.promise.d.ts:152:13: 'Promise' was also declared here. ~ !!! error TS1005: ',' expected. ~~ diff --git a/tests/baselines/reference/asyncArrowFunction5_es5.errors.txt b/tests/baselines/reference/asyncArrowFunction5_es5.errors.txt index f132abff235..cf82d765a56 100644 --- a/tests/baselines/reference/asyncArrowFunction5_es5.errors.txt +++ b/tests/baselines/reference/asyncArrowFunction5_es5.errors.txt @@ -16,6 +16,7 @@ tests/cases/conformance/async/es5/asyncArrowFunction/asyncArrowFunction5_es5.ts( !!! error TS1005: ',' expected. ~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'Promise' must be of type 'PromiseConstructor', but here has type 'any'. +!!! related TS6203 /.ts/lib.es2015.promise.d.ts:152:13: 'Promise' was also declared here. ~ !!! error TS1005: ',' expected. ~~ diff --git a/tests/baselines/reference/asyncArrowFunction5_es6.errors.txt b/tests/baselines/reference/asyncArrowFunction5_es6.errors.txt index a2f6f441252..909efc3c97e 100644 --- a/tests/baselines/reference/asyncArrowFunction5_es6.errors.txt +++ b/tests/baselines/reference/asyncArrowFunction5_es6.errors.txt @@ -16,6 +16,7 @@ tests/cases/conformance/async/es6/asyncArrowFunction/asyncArrowFunction5_es6.ts( !!! error TS1005: ',' expected. ~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'Promise' must be of type 'PromiseConstructor', but here has type 'any'. +!!! related TS6203 /.ts/lib.es2015.promise.d.ts:152:13: 'Promise' was also declared here. ~ !!! error TS1005: ',' expected. ~~ diff --git a/tests/baselines/reference/asyncArrowFunction9_es2017.errors.txt b/tests/baselines/reference/asyncArrowFunction9_es2017.errors.txt index cd2bb9c8858..0be88de2868 100644 --- a/tests/baselines/reference/asyncArrowFunction9_es2017.errors.txt +++ b/tests/baselines/reference/asyncArrowFunction9_es2017.errors.txt @@ -16,6 +16,7 @@ tests/cases/conformance/async/es2017/asyncArrowFunction/asyncArrowFunction9_es20 !!! error TS1005: ',' expected. ~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'Promise' must be of type 'PromiseConstructor', but here has type 'any'. +!!! related TS6203 /.ts/lib.es2015.promise.d.ts:152:13: 'Promise' was also declared here. ~ !!! error TS1005: ',' expected. ~~ diff --git a/tests/baselines/reference/asyncArrowFunction9_es5.errors.txt b/tests/baselines/reference/asyncArrowFunction9_es5.errors.txt index be561eab72c..085b3b50884 100644 --- a/tests/baselines/reference/asyncArrowFunction9_es5.errors.txt +++ b/tests/baselines/reference/asyncArrowFunction9_es5.errors.txt @@ -16,6 +16,7 @@ tests/cases/conformance/async/es5/asyncArrowFunction/asyncArrowFunction9_es5.ts( !!! error TS1005: ',' expected. ~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'Promise' must be of type 'PromiseConstructor', but here has type 'any'. +!!! related TS6203 /.ts/lib.es2015.promise.d.ts:152:13: 'Promise' was also declared here. ~ !!! error TS1005: ',' expected. ~~ diff --git a/tests/baselines/reference/asyncArrowFunction9_es6.errors.txt b/tests/baselines/reference/asyncArrowFunction9_es6.errors.txt index 84177f28292..6949aad5cea 100644 --- a/tests/baselines/reference/asyncArrowFunction9_es6.errors.txt +++ b/tests/baselines/reference/asyncArrowFunction9_es6.errors.txt @@ -16,6 +16,7 @@ tests/cases/conformance/async/es6/asyncArrowFunction/asyncArrowFunction9_es6.ts( !!! error TS1005: ',' expected. ~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'Promise' must be of type 'PromiseConstructor', but here has type 'any'. +!!! related TS6203 /.ts/lib.es2015.promise.d.ts:152:13: 'Promise' was also declared here. ~ !!! error TS1005: ',' expected. ~~ diff --git a/tests/baselines/reference/augmentedTypesVar.errors.txt b/tests/baselines/reference/augmentedTypesVar.errors.txt index 261686f3659..ae910b4f5be 100644 --- a/tests/baselines/reference/augmentedTypesVar.errors.txt +++ b/tests/baselines/reference/augmentedTypesVar.errors.txt @@ -30,6 +30,7 @@ tests/cases/compiler/augmentedTypesVar.ts(31,8): error TS2300: Duplicate identif var x3 = () => { } // error ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x3' must be of type 'number', but here has type '() => void'. +!!! related TS6203 tests/cases/compiler/augmentedTypesVar.ts:9:5: 'x3' was also declared here. // var then class var x4 = 1; // error diff --git a/tests/baselines/reference/castingTuple.errors.txt b/tests/baselines/reference/castingTuple.errors.txt index 4ddb42ed2d9..0a1d592e8b1 100644 --- a/tests/baselines/reference/castingTuple.errors.txt +++ b/tests/baselines/reference/castingTuple.errors.txt @@ -71,6 +71,7 @@ tests/cases/conformance/types/tuple/castingTuple.ts(33,1): error TS2304: Cannot var array1 = numStrTuple; ~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'array1' must be of type '{}[]', but here has type 'number[]'. +!!! related TS6203 tests/cases/conformance/types/tuple/castingTuple.ts:23:5: 'array1' was also declared here. t4[2] = 10; ~~ !!! error TS2304: Cannot find name 't4'. diff --git a/tests/baselines/reference/checkMergedGlobalUMDSymbol.errors.txt b/tests/baselines/reference/checkMergedGlobalUMDSymbol.errors.txt index f3d21e26b6e..f4b889131f1 100644 --- a/tests/baselines/reference/checkMergedGlobalUMDSymbol.errors.txt +++ b/tests/baselines/reference/checkMergedGlobalUMDSymbol.errors.txt @@ -15,6 +15,7 @@ tests/cases/compiler/global.d.ts(6,16): error TS2403: Subsequent variable declar export const THREE: typeof _three; ~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'THREE' must be of type 'typeof import("tests/cases/compiler/global")', but here has type 'typeof import("tests/cases/compiler/three")'. +!!! related TS6203 tests/cases/compiler/global.d.ts:1:1: 'THREE' was also declared here. } ==== tests/cases/compiler/test.ts (0 errors) ==== diff --git a/tests/baselines/reference/classWithDuplicateIdentifier.errors.txt b/tests/baselines/reference/classWithDuplicateIdentifier.errors.txt index db48c48078c..60390e8a843 100644 --- a/tests/baselines/reference/classWithDuplicateIdentifier.errors.txt +++ b/tests/baselines/reference/classWithDuplicateIdentifier.errors.txt @@ -14,6 +14,7 @@ tests/cases/compiler/classWithDuplicateIdentifier.ts(11,5): error TS2717: Subseq !!! error TS2300: Duplicate identifier 'a'. ~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'a' must be of type '() => number', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/classWithDuplicateIdentifier.ts:2:5: 'a' was also declared here. } class K { b: number; // error: duplicate identifier @@ -30,5 +31,6 @@ tests/cases/compiler/classWithDuplicateIdentifier.ts(11,5): error TS2717: Subseq !!! error TS2300: Duplicate identifier 'c'. ~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'c' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/compiler/classWithDuplicateIdentifier.ts:10:5: 'c' was also declared here. } \ No newline at end of file diff --git a/tests/baselines/reference/conditionalTypes1.errors.txt b/tests/baselines/reference/conditionalTypes1.errors.txt index 7abcf55b8e7..45d3b1f99cb 100644 --- a/tests/baselines/reference/conditionalTypes1.errors.txt +++ b/tests/baselines/reference/conditionalTypes1.errors.txt @@ -391,6 +391,7 @@ tests/cases/conformance/types/conditional/conditionalTypes1.ts(288,43): error TS var z: T2; // Error, T2 is distributive, T1 isn't ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'z' must be of type 'T1', but here has type 'Foo'. +!!! related TS6203 tests/cases/conformance/types/conditional/conditionalTypes1.ts:262:9: 'z' was also declared here. } function f33() { diff --git a/tests/baselines/reference/declarationsAndAssignments.errors.txt b/tests/baselines/reference/declarationsAndAssignments.errors.txt index 312a0ed626c..b13aacbfbc3 100644 --- a/tests/baselines/reference/declarationsAndAssignments.errors.txt +++ b/tests/baselines/reference/declarationsAndAssignments.errors.txt @@ -97,6 +97,7 @@ tests/cases/conformance/es6/destructuring/declarationsAndAssignments.ts(138,9): var y: string; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'string | number', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/es6/destructuring/declarationsAndAssignments.ts:56:17: 'y' was also declared here. } function f8() { diff --git a/tests/baselines/reference/duplicateClassElements.errors.txt b/tests/baselines/reference/duplicateClassElements.errors.txt index 4ac91767768..397ee445459 100644 --- a/tests/baselines/reference/duplicateClassElements.errors.txt +++ b/tests/baselines/reference/duplicateClassElements.errors.txt @@ -97,6 +97,7 @@ tests/cases/compiler/duplicateClassElements.ts(41,12): error TS2300: Duplicate i !!! error TS2300: Duplicate identifier 'x2'. ~~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'x2' must be of type 'number', but here has type 'any'. +!!! related TS6203 tests/cases/compiler/duplicateClassElements.ts:29:9: 'x2' was also declared here. get z2() { ~~ diff --git a/tests/baselines/reference/duplicateIdentifierInCatchBlock.errors.txt b/tests/baselines/reference/duplicateIdentifierInCatchBlock.errors.txt index d8065df27c8..d2216efc6e6 100644 --- a/tests/baselines/reference/duplicateIdentifierInCatchBlock.errors.txt +++ b/tests/baselines/reference/duplicateIdentifierInCatchBlock.errors.txt @@ -38,4 +38,5 @@ tests/cases/compiler/duplicateIdentifierInCatchBlock.ts(16,9): error TS2403: Sub var p: number; // error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'p' must be of type 'string', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/duplicateIdentifierInCatchBlock.ts:15:9: 'p' was also declared here. } \ No newline at end of file diff --git a/tests/baselines/reference/duplicateLocalVariable1.errors.txt b/tests/baselines/reference/duplicateLocalVariable1.errors.txt index 6f521565862..a31ca844a86 100644 --- a/tests/baselines/reference/duplicateLocalVariable1.errors.txt +++ b/tests/baselines/reference/duplicateLocalVariable1.errors.txt @@ -201,6 +201,7 @@ tests/cases/compiler/duplicateLocalVariable1.ts(186,37): error TS2356: An arithm for (var i = 0; i < 14; i++) { ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'i' must be of type 'string', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/duplicateLocalVariable1.ts:181:22: 'i' was also declared here. ~~~~~~ !!! error TS2365: Operator '<' cannot be applied to types 'string' and 'number'. ~ diff --git a/tests/baselines/reference/duplicateLocalVariable2.errors.txt b/tests/baselines/reference/duplicateLocalVariable2.errors.txt index 0258e7e8460..f25de4a7047 100644 --- a/tests/baselines/reference/duplicateLocalVariable2.errors.txt +++ b/tests/baselines/reference/duplicateLocalVariable2.errors.txt @@ -33,6 +33,7 @@ tests/cases/compiler/duplicateLocalVariable2.ts(27,37): error TS2356: An arithme for (var i = 0; i < 14; i++) { ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'i' must be of type 'string', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/duplicateLocalVariable2.ts:22:22: 'i' was also declared here. ~~~~~~ !!! error TS2365: Operator '<' cannot be applied to types 'string' and 'number'. ~ diff --git a/tests/baselines/reference/duplicateLocalVariable3.errors.txt b/tests/baselines/reference/duplicateLocalVariable3.errors.txt index 5dda5872da0..2255776c75c 100644 --- a/tests/baselines/reference/duplicateLocalVariable3.errors.txt +++ b/tests/baselines/reference/duplicateLocalVariable3.errors.txt @@ -15,4 +15,5 @@ tests/cases/compiler/duplicateLocalVariable3.ts(11,9): error TS2403: Subsequent var z = ""; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'z' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/compiler/duplicateLocalVariable3.ts:10:9: 'z' was also declared here. } \ No newline at end of file diff --git a/tests/baselines/reference/duplicateLocalVariable4.errors.txt b/tests/baselines/reference/duplicateLocalVariable4.errors.txt index 3209c23e39e..67da21962b1 100644 --- a/tests/baselines/reference/duplicateLocalVariable4.errors.txt +++ b/tests/baselines/reference/duplicateLocalVariable4.errors.txt @@ -9,4 +9,5 @@ tests/cases/compiler/duplicateLocalVariable4.ts(6,5): error TS2403: Subsequent v var x = E; var x = E.a; ~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'typeof E', but here has type 'E'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'typeof E', but here has type 'E'. +!!! related TS6203 tests/cases/compiler/duplicateLocalVariable4.ts:5:5: 'x' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/duplicateVariablesWithAny.errors.txt b/tests/baselines/reference/duplicateVariablesWithAny.errors.txt index 787e118ca37..0d71fde12e2 100644 --- a/tests/baselines/reference/duplicateVariablesWithAny.errors.txt +++ b/tests/baselines/reference/duplicateVariablesWithAny.errors.txt @@ -10,22 +10,26 @@ tests/cases/compiler/duplicateVariablesWithAny.ts(13,9): error TS2403: Subsequen var x = 2; //error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/duplicateVariablesWithAny.ts:2:5: 'x' was also declared here. var y = ""; var y; //error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'string', but here has type 'any'. +!!! related TS6203 tests/cases/compiler/duplicateVariablesWithAny.ts:5:5: 'y' was also declared here. module N { var x: any; var x = 2; //error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/duplicateVariablesWithAny.ts:9:9: 'x' was also declared here. var y = ""; var y; //error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'string', but here has type 'any'. +!!! related TS6203 tests/cases/compiler/duplicateVariablesWithAny.ts:12:9: 'y' was also declared here. } var z: any; diff --git a/tests/baselines/reference/duplicateVarsAcrossFileBoundaries.errors.txt b/tests/baselines/reference/duplicateVarsAcrossFileBoundaries.errors.txt index d4222483212..2f5e9f09634 100644 --- a/tests/baselines/reference/duplicateVarsAcrossFileBoundaries.errors.txt +++ b/tests/baselines/reference/duplicateVarsAcrossFileBoundaries.errors.txt @@ -12,18 +12,22 @@ tests/cases/compiler/duplicateVarsAcrossFileBoundaries_2.ts(3,5): error TS2403: var x = true; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'number', but here has type 'boolean'. +!!! related TS6203 tests/cases/compiler/duplicateVarsAcrossFileBoundaries_0.ts:1:5: 'x' was also declared here. var z = 3; ==== tests/cases/compiler/duplicateVarsAcrossFileBoundaries_2.ts (3 errors) ==== var x = ""; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/compiler/duplicateVarsAcrossFileBoundaries_0.ts:1:5: 'x' was also declared here. var y = 3; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'string', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/duplicateVarsAcrossFileBoundaries_0.ts:2:5: 'y' was also declared here. var z = false; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'z' must be of type 'number', but here has type 'boolean'. +!!! related TS6203 tests/cases/compiler/duplicateVarsAcrossFileBoundaries_1.ts:2:5: 'z' was also declared here. ==== tests/cases/compiler/duplicateVarsAcrossFileBoundaries_3.ts (0 errors) ==== var x = 0; diff --git a/tests/baselines/reference/dynamicNamesErrors.errors.txt b/tests/baselines/reference/dynamicNamesErrors.errors.txt index c39140dbd52..43ca55db4ea 100644 --- a/tests/baselines/reference/dynamicNamesErrors.errors.txt +++ b/tests/baselines/reference/dynamicNamesErrors.errors.txt @@ -35,6 +35,7 @@ tests/cases/compiler/dynamicNamesErrors.ts(25,1): error TS2322: Type 'T1' is not [c1]: string; ~~~~ !!! error TS2717: Subsequent property declarations must have the same type. Property '[c1]' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/compiler/dynamicNamesErrors.ts:18:5: '[c1]' was also declared here. } let t1: T1; diff --git a/tests/baselines/reference/enumAssignabilityInInheritance.errors.txt b/tests/baselines/reference/enumAssignabilityInInheritance.errors.txt index e7c1297e1fd..e76c053a0af 100644 --- a/tests/baselines/reference/enumAssignabilityInInheritance.errors.txt +++ b/tests/baselines/reference/enumAssignabilityInInheritance.errors.txt @@ -109,10 +109,12 @@ tests/cases/conformance/types/typeRelationships/assignmentCompatibility/enumAssi var r4 = foo16(E.A); ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r4' must be of type 'E', but here has type 'Object'. +!!! related TS6203 tests/cases/conformance/types/typeRelationships/assignmentCompatibility/enumAssignabilityInInheritance.ts:22:5: 'r4' was also declared here. declare function foo17(x: {}): {}; declare function foo17(x: E): E; var r4 = foo16(E.A); ~~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r4' must be of type 'E', but here has type 'Object'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r4' must be of type 'E', but here has type 'Object'. +!!! related TS6203 tests/cases/conformance/types/typeRelationships/assignmentCompatibility/enumAssignabilityInInheritance.ts:22:5: 'r4' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/for-inStatements.errors.txt b/tests/baselines/reference/for-inStatements.errors.txt index 50f31d669cd..03e11ff1115 100644 --- a/tests/baselines/reference/for-inStatements.errors.txt +++ b/tests/baselines/reference/for-inStatements.errors.txt @@ -39,6 +39,7 @@ tests/cases/conformance/statements/for-inStatements/for-inStatements.ts(79,15): for (var x in this) { } ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'string', but here has type 'Extract'. +!!! related TS6203 tests/cases/conformance/statements/for-inStatements/for-inStatements.ts:31:18: 'x' was also declared here. return null; } @@ -58,6 +59,7 @@ tests/cases/conformance/statements/for-inStatements/for-inStatements.ts(79,15): for (var x in this) { } ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'string', but here has type 'Extract'. +!!! related TS6203 tests/cases/conformance/statements/for-inStatements/for-inStatements.ts:48:18: 'x' was also declared here. for (var x in super.biz) { } for (var x in super.biz()) { } diff --git a/tests/baselines/reference/for-inStatementsArrayErrors.errors.txt b/tests/baselines/reference/for-inStatementsArrayErrors.errors.txt index 3ba7a73367f..2eb08a8b1f3 100644 --- a/tests/baselines/reference/for-inStatementsArrayErrors.errors.txt +++ b/tests/baselines/reference/for-inStatementsArrayErrors.errors.txt @@ -29,11 +29,13 @@ tests/cases/conformance/statements/for-inStatements/for-inStatementsArrayErrors. for (var i in a ) { ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'i' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/statements/for-inStatements/for-inStatementsArrayErrors.ts:11:5: 'i' was also declared here. } var j: any; for (var j in a ) { ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'j' must be of type 'any', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/statements/for-inStatements/for-inStatementsArrayErrors.ts:15:5: 'j' was also declared here. } \ No newline at end of file diff --git a/tests/baselines/reference/for-inStatementsInvalid.errors.txt b/tests/baselines/reference/for-inStatementsInvalid.errors.txt index 8e1bb29d083..e8e29b37c4e 100644 --- a/tests/baselines/reference/for-inStatementsInvalid.errors.txt +++ b/tests/baselines/reference/for-inStatementsInvalid.errors.txt @@ -73,6 +73,7 @@ tests/cases/conformance/statements/for-inStatements/for-inStatementsInvalid.ts(6 for (var x in this) { } ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'string', but here has type 'Extract'. +!!! related TS6203 tests/cases/conformance/statements/for-inStatements/for-inStatementsInvalid.ts:29:18: 'x' was also declared here. return null; } @@ -96,6 +97,7 @@ tests/cases/conformance/statements/for-inStatements/for-inStatementsInvalid.ts(6 for (var x in this) { } ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'string', but here has type 'Extract'. +!!! related TS6203 tests/cases/conformance/statements/for-inStatements/for-inStatementsInvalid.ts:46:18: 'x' was also declared here. for (var x in super.biz) { } for (var x in super.biz()) { } diff --git a/tests/baselines/reference/forStatementsMultipleInvalidDecl.errors.txt b/tests/baselines/reference/forStatementsMultipleInvalidDecl.errors.txt index 53ecb88363d..f0de0ce954b 100644 --- a/tests/baselines/reference/forStatementsMultipleInvalidDecl.errors.txt +++ b/tests/baselines/reference/forStatementsMultipleInvalidDecl.errors.txt @@ -47,46 +47,58 @@ tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDec for( var a = 1;;){} ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:31:10: 'a' was also declared here. for( var a = 'a string';;){} ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:31:10: 'a' was also declared here. for( var a = new C();;){} ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'C'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:31:10: 'a' was also declared here. for( var a = new D();;){} ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'D'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:31:10: 'a' was also declared here. for( var a = M;;){} ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'typeof M'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:31:10: 'a' was also declared here. for( var b: I;;){} for( var b = new C();;){} ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'b' must be of type 'I', but here has type 'C'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:38:10: 'b' was also declared here. for( var b = new C2();;){} ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'b' must be of type 'I', but here has type 'C2'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:38:10: 'b' was also declared here. for(var f = F;;){} for( var f = (x: number) => '';;){} ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'f' must be of type '(x: string) => number', but here has type '(x: number) => string'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:42:9: 'f' was also declared here. for(var arr: string[];;){} for( var arr = [1, 2, 3, 4];;){} ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'arr' must be of type 'string[]', but here has type 'number[]'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:45:9: 'arr' was also declared here. for( var arr = [new C(), new C2(), new D()];;){} ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'arr' must be of type 'string[]', but here has type '(C | D)[]'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:45:9: 'arr' was also declared here. for(var arr2 = [new D()];;){} for( var arr2 = new Array>();;){} ~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'arr2' must be of type 'D[]', but here has type 'D[]'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:49:9: 'arr2' was also declared here. for(var m: typeof M;;){} for( var m = M.A;;){} ~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'm' must be of type 'typeof M', but here has type 'typeof A'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'm' must be of type 'typeof M', but here has type 'typeof A'. +!!! related TS6203 tests/cases/conformance/statements/forStatements/forStatementsMultipleInvalidDecl.ts:52:9: 'm' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/functionArgShadowing.errors.txt b/tests/baselines/reference/functionArgShadowing.errors.txt index 93022178452..c3ba60a80cd 100644 --- a/tests/baselines/reference/functionArgShadowing.errors.txt +++ b/tests/baselines/reference/functionArgShadowing.errors.txt @@ -10,6 +10,7 @@ tests/cases/compiler/functionArgShadowing.ts(10,7): error TS2403: Subsequent var var x: B = new B(); ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'A', but here has type 'B'. +!!! related TS6203 tests/cases/compiler/functionArgShadowing.ts:3:14: 'x' was also declared here. x.bar(); // the property bar does not exist on a value of type A ~~~ !!! error TS2339: Property 'bar' does not exist on type 'A'. @@ -20,6 +21,7 @@ tests/cases/compiler/functionArgShadowing.ts(10,7): error TS2403: Subsequent var var p: string; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'p' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/compiler/functionArgShadowing.ts:9:14: 'p' was also declared here. var n: number = p; } diff --git a/tests/baselines/reference/gettersAndSettersErrors.errors.txt b/tests/baselines/reference/gettersAndSettersErrors.errors.txt index e2a4bb3a146..013e195876e 100644 --- a/tests/baselines/reference/gettersAndSettersErrors.errors.txt +++ b/tests/baselines/reference/gettersAndSettersErrors.errors.txt @@ -24,6 +24,7 @@ tests/cases/compiler/gettersAndSettersErrors.ts(12,16): error TS2379: Getter and !!! error TS2300: Duplicate identifier 'Foo'. ~~~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'Foo' must be of type 'string', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/gettersAndSettersErrors.ts:2:16: 'Foo' was also declared here. public get Goo(v:string):string {return null;} // error - getters must not have a parameter ~~~ !!! error TS1056: Accessors are only available when targeting ECMAScript 5 and higher. diff --git a/tests/baselines/reference/identityForSignaturesWithTypeParametersAndAny.errors.txt b/tests/baselines/reference/identityForSignaturesWithTypeParametersAndAny.errors.txt index 60239280226..092bfaaeeb3 100644 --- a/tests/baselines/reference/identityForSignaturesWithTypeParametersAndAny.errors.txt +++ b/tests/baselines/reference/identityForSignaturesWithTypeParametersAndAny.errors.txt @@ -12,18 +12,22 @@ tests/cases/compiler/identityForSignaturesWithTypeParametersAndAny.ts(14,5): err var g: (x: any, y: any) => any; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'g' must be of type '(x: T, y: U) => T', but here has type '(x: any, y: any) => any'. +!!! related TS6203 tests/cases/compiler/identityForSignaturesWithTypeParametersAndAny.ts:4:5: 'g' was also declared here. var h: (x: T, y: U) => T; var h: (x: any, y: any) => any; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'h' must be of type '(x: T, y: U) => T', but here has type '(x: any, y: any) => any'. +!!! related TS6203 tests/cases/compiler/identityForSignaturesWithTypeParametersAndAny.ts:7:5: 'h' was also declared here. var i: (x: T, y: U) => T; var i: (x: any, y: string) => any; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'i' must be of type '(x: T, y: U) => T', but here has type '(x: any, y: string) => any'. +!!! related TS6203 tests/cases/compiler/identityForSignaturesWithTypeParametersAndAny.ts:10:5: 'i' was also declared here. var j: (x: T, y: U) => T; var j: (x: any, y: any) => string; ~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'j' must be of type '(x: T, y: U) => T', but here has type '(x: any, y: any) => string'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'j' must be of type '(x: T, y: U) => T', but here has type '(x: any, y: any) => string'. +!!! related TS6203 tests/cases/compiler/identityForSignaturesWithTypeParametersAndAny.ts:13:5: 'j' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/interfaceDeclaration1.errors.txt b/tests/baselines/reference/interfaceDeclaration1.errors.txt index 64410b44c55..b4c41ca350e 100644 --- a/tests/baselines/reference/interfaceDeclaration1.errors.txt +++ b/tests/baselines/reference/interfaceDeclaration1.errors.txt @@ -30,6 +30,7 @@ tests/cases/compiler/interfaceDeclaration1.ts(52,11): error TS2320: Interface 'i !!! error TS2300: Duplicate identifier 'item'. ~~~~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'item' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/interfaceDeclaration1.ts:7:5: 'item' was also declared here. } interface I3 { diff --git a/tests/baselines/reference/invalidMultipleVariableDeclarations.errors.txt b/tests/baselines/reference/invalidMultipleVariableDeclarations.errors.txt index 3ec718f3b25..a43b9b0c271 100644 --- a/tests/baselines/reference/invalidMultipleVariableDeclarations.errors.txt +++ b/tests/baselines/reference/invalidMultipleVariableDeclarations.errors.txt @@ -47,46 +47,58 @@ tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDec var a = 1; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:31:5: 'a' was also declared here. var a = 'a string'; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:31:5: 'a' was also declared here. var a = new C(); ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'C'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:31:5: 'a' was also declared here. var a = new D(); ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'D'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:31:5: 'a' was also declared here. var a = M; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a' must be of type 'any', but here has type 'typeof M'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:31:5: 'a' was also declared here. var b: I; var b = new C(); ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'b' must be of type 'I', but here has type 'C'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:38:5: 'b' was also declared here. var b = new C2(); ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'b' must be of type 'I', but here has type 'C2'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:38:5: 'b' was also declared here. var f = F; var f = (x: number) => ''; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'f' must be of type '(x: string) => number', but here has type '(x: number) => string'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:42:5: 'f' was also declared here. var arr: string[]; var arr = [1, 2, 3, 4]; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'arr' must be of type 'string[]', but here has type 'number[]'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:45:5: 'arr' was also declared here. var arr = [new C(), new C2(), new D()]; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'arr' must be of type 'string[]', but here has type '(C | D)[]'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:45:5: 'arr' was also declared here. var arr2 = [new D()]; var arr2 = new Array>(); ~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'arr2' must be of type 'D[]', but here has type 'D[]'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:49:5: 'arr2' was also declared here. var m: typeof M; var m = M.A; ~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'm' must be of type 'typeof M', but here has type 'typeof A'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'm' must be of type 'typeof M', but here has type 'typeof A'. +!!! related TS6203 tests/cases/conformance/statements/VariableStatements/invalidMultipleVariableDeclarations.ts:52:5: 'm' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/jsFileCompilationDuplicateVariableErrorReported.errors.txt b/tests/baselines/reference/jsFileCompilationDuplicateVariableErrorReported.errors.txt index f1374d95767..9e46d6225a2 100644 --- a/tests/baselines/reference/jsFileCompilationDuplicateVariableErrorReported.errors.txt +++ b/tests/baselines/reference/jsFileCompilationDuplicateVariableErrorReported.errors.txt @@ -9,4 +9,5 @@ tests/cases/compiler/a.ts(1,5): error TS2403: Subsequent variable declarations m ==== tests/cases/compiler/a.ts (1 errors) ==== var x = 10; // Error reported so no declaration file generated? ~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'string', but here has type 'number'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'string', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/b.js:1:5: 'x' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/mappedTypeErrors.errors.txt b/tests/baselines/reference/mappedTypeErrors.errors.txt index 254d1cca1a8..0dc68732e81 100644 --- a/tests/baselines/reference/mappedTypeErrors.errors.txt +++ b/tests/baselines/reference/mappedTypeErrors.errors.txt @@ -133,12 +133,15 @@ tests/cases/conformance/types/mapped/mappedTypeErrors.ts(152,17): error TS2339: var x: { [P in keyof T]?: T[P] }; // Error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type '{ [P in keyof T]: T[P]; }', but here has type '{ [P in keyof T]?: T[P] | undefined; }'. +!!! related TS6203 tests/cases/conformance/types/mapped/mappedTypeErrors.ts:58:9: 'x' was also declared here. var x: { readonly [P in keyof T]: T[P] }; // Error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type '{ [P in keyof T]: T[P]; }', but here has type '{ readonly [P in keyof T]: T[P]; }'. +!!! related TS6203 tests/cases/conformance/types/mapped/mappedTypeErrors.ts:58:9: 'x' was also declared here. var x: { readonly [P in keyof T]?: T[P] }; // Error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type '{ [P in keyof T]: T[P]; }', but here has type '{ readonly [P in keyof T]?: T[P] | undefined; }'. +!!! related TS6203 tests/cases/conformance/types/mapped/mappedTypeErrors.ts:58:9: 'x' was also declared here. } function f12() { @@ -146,6 +149,7 @@ tests/cases/conformance/types/mapped/mappedTypeErrors.ts(152,17): error TS2339: var x: { [P in keyof T]: T[P][] }; // Error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type '{ [P in keyof T]: T[P]; }', but here has type '{ [P in keyof T]: T[P][]; }'. +!!! related TS6203 tests/cases/conformance/types/mapped/mappedTypeErrors.ts:65:9: 'x' was also declared here. } // Check that inferences to mapped types are secondary diff --git a/tests/baselines/reference/mergedInterfacesWithConflictingPropertyNames.errors.txt b/tests/baselines/reference/mergedInterfacesWithConflictingPropertyNames.errors.txt index 523cad05465..6bb0e02f4eb 100644 --- a/tests/baselines/reference/mergedInterfacesWithConflictingPropertyNames.errors.txt +++ b/tests/baselines/reference/mergedInterfacesWithConflictingPropertyNames.errors.txt @@ -12,6 +12,7 @@ tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConfli x: number; ~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'x' must be of type 'string', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts:2:5: 'x' was also declared here. } module M { @@ -23,6 +24,7 @@ tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConfli x: number; // error ~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'x' must be of type 'T', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts:11:9: 'x' was also declared here. } } @@ -49,5 +51,6 @@ tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConfli x: number; // error ~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'x' must be of type 'T', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts:33:9: 'x' was also declared here. } } \ No newline at end of file diff --git a/tests/baselines/reference/methodSignatureHandledDeclarationKindForSymbol.errors.txt b/tests/baselines/reference/methodSignatureHandledDeclarationKindForSymbol.errors.txt index 99fd038bbb9..edb66f56dd3 100644 --- a/tests/baselines/reference/methodSignatureHandledDeclarationKindForSymbol.errors.txt +++ b/tests/baselines/reference/methodSignatureHandledDeclarationKindForSymbol.errors.txt @@ -10,6 +10,7 @@ tests/cases/compiler/methodSignatureHandledDeclarationKindForSymbol.ts(6,5): err bold: string; ~~~~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'bold' must be of type '() => string', but here has type 'string'. +!!! related TS6203 tests/cases/compiler/methodSignatureHandledDeclarationKindForSymbol.ts:2:5: 'bold' was also declared here. } \ No newline at end of file diff --git a/tests/baselines/reference/missingAndExcessProperties.errors.txt b/tests/baselines/reference/missingAndExcessProperties.errors.txt index 0ee69d9af30..7972d770320 100644 --- a/tests/baselines/reference/missingAndExcessProperties.errors.txt +++ b/tests/baselines/reference/missingAndExcessProperties.errors.txt @@ -31,6 +31,7 @@ tests/cases/conformance/es6/destructuring/missingAndExcessProperties.ts(31,16): var { x = 1, y } = {}; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/es6/destructuring/missingAndExcessProperties.ts:3:11: 'x' was also declared here. ~ !!! error TS2525: Initializer provides no value for this binding element and the binding element has no default value. var { x, y = 1 } = {}; @@ -38,11 +39,14 @@ tests/cases/conformance/es6/destructuring/missingAndExcessProperties.ts(31,16): !!! error TS2525: Initializer provides no value for this binding element and the binding element has no default value. ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/es6/destructuring/missingAndExcessProperties.ts:3:14: 'y' was also declared here. var { x = 1, y = 1 } = {}; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/es6/destructuring/missingAndExcessProperties.ts:3:11: 'x' was also declared here. ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/es6/destructuring/missingAndExcessProperties.ts:3:14: 'y' was also declared here. } // Missing properties diff --git a/tests/baselines/reference/negateOperatorInvalidOperations.errors.txt b/tests/baselines/reference/negateOperatorInvalidOperations.errors.txt index 105a1af9efe..0792565f063 100644 --- a/tests/baselines/reference/negateOperatorInvalidOperations.errors.txt +++ b/tests/baselines/reference/negateOperatorInvalidOperations.errors.txt @@ -44,5 +44,6 @@ tests/cases/conformance/expressions/unaryOperators/negateOperator/negateOperator var NUMBER =-; ~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'NUMBER' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/expressions/unaryOperators/negateOperator/negateOperatorInvalidOperations.ts:4:19: 'NUMBER' was also declared here. ~ !!! error TS1109: Expression expected. \ No newline at end of file diff --git a/tests/baselines/reference/numericStringNamedPropertyEquivalence.errors.txt b/tests/baselines/reference/numericStringNamedPropertyEquivalence.errors.txt index 8f0a27e03d9..7d3ff163300 100644 --- a/tests/baselines/reference/numericStringNamedPropertyEquivalence.errors.txt +++ b/tests/baselines/reference/numericStringNamedPropertyEquivalence.errors.txt @@ -37,6 +37,7 @@ tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericString !!! error TS2300: Duplicate identifier '1'. ~~~ !!! error TS2717: Subsequent property declarations must have the same type. Property '1.0' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericStringNamedPropertyEquivalence.ts:16:5: '1.0' was also declared here. } var b = { diff --git a/tests/baselines/reference/objectLiteralContextualTyping.errors.txt b/tests/baselines/reference/objectLiteralContextualTyping.errors.txt index b73b7b43a89..2ff2a7287f8 100644 --- a/tests/baselines/reference/objectLiteralContextualTyping.errors.txt +++ b/tests/baselines/reference/objectLiteralContextualTyping.errors.txt @@ -33,4 +33,5 @@ tests/cases/conformance/expressions/contextualTyping/objectLiteralContextualTypi var b: {}; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'b' must be of type 'unknown', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/expressions/contextualTyping/objectLiteralContextualTyping.ts:28:5: 'b' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/objectRest.errors.txt b/tests/baselines/reference/objectRest.errors.txt index 02f64fbd4e2..f6fd179d28d 100644 --- a/tests/baselines/reference/objectRest.errors.txt +++ b/tests/baselines/reference/objectRest.errors.txt @@ -62,6 +62,7 @@ tests/cases/conformance/types/rest/objectRest.ts(44,53): error TS2739: Type '{}' !!! error TS2537: Type '{ a: number; b: string; }' has no matching index signature for type 'string'. ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'o' must be of type '{ a: number; b: string; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/types/rest/objectRest.ts:1:5: 'o' was also declared here. ({ [computed]: stillNotGreat, [computed2]: soSo, ...o } = o); ~~~~~~~~ !!! error TS2537: Type '{ a: number; b: string; }' has no matching index signature for type 'string'. diff --git a/tests/baselines/reference/optionalParamterAndVariableDeclaration2.errors.txt b/tests/baselines/reference/optionalParamterAndVariableDeclaration2.errors.txt index 982318d2f25..df38f7d2051 100644 --- a/tests/baselines/reference/optionalParamterAndVariableDeclaration2.errors.txt +++ b/tests/baselines/reference/optionalParamterAndVariableDeclaration2.errors.txt @@ -7,6 +7,7 @@ tests/cases/compiler/optionalParamterAndVariableDeclaration2.ts(3,13): error TS2 var options = (options || 0); ~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'options' must be of type 'number | undefined', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/optionalParamterAndVariableDeclaration2.ts:2:17: 'options' was also declared here. } } \ No newline at end of file diff --git a/tests/baselines/reference/orderMattersForSignatureGroupIdentity.errors.txt b/tests/baselines/reference/orderMattersForSignatureGroupIdentity.errors.txt index f108f0ea92d..fc8d68f1af8 100644 --- a/tests/baselines/reference/orderMattersForSignatureGroupIdentity.errors.txt +++ b/tests/baselines/reference/orderMattersForSignatureGroupIdentity.errors.txt @@ -33,6 +33,7 @@ tests/cases/compiler/orderMattersForSignatureGroupIdentity.ts(24,5): error TS234 var w: C; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'w' must be of type 'A', but here has type 'C'. +!!! related TS6203 tests/cases/compiler/orderMattersForSignatureGroupIdentity.ts:21:5: 'w' was also declared here. w({ s: "", n: 0 }).toLowerCase(); ~~~~~ diff --git a/tests/baselines/reference/overloadResolution.errors.txt b/tests/baselines/reference/overloadResolution.errors.txt index 27d0392ca8d..fde241d62cc 100644 --- a/tests/baselines/reference/overloadResolution.errors.txt +++ b/tests/baselines/reference/overloadResolution.errors.txt @@ -120,6 +120,7 @@ tests/cases/conformance/expressions/functionCalls/overloadResolution.ts(91,22): var n = fn5((n) => n.toFixed()); ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'n' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/expressions/functionCalls/overloadResolution.ts:54:5: 'n' was also declared here. ~~~~~~~ !!! error TS2339: Property 'toFixed' does not exist on type 'string'. var s = fn5((n) => n.substr(0)); diff --git a/tests/baselines/reference/overloadResolutionConstructors.errors.txt b/tests/baselines/reference/overloadResolutionConstructors.errors.txt index 2e09a84d138..40b660c7eaf 100644 --- a/tests/baselines/reference/overloadResolutionConstructors.errors.txt +++ b/tests/baselines/reference/overloadResolutionConstructors.errors.txt @@ -129,6 +129,7 @@ tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors var n = new fn5((n) => n.toFixed()); ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'n' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/expressions/functionCalls/overloadResolutionConstructors.ts:58:5: 'n' was also declared here. ~~~~~~~ !!! error TS2339: Property 'toFixed' does not exist on type 'string'. var s = new fn5((n) => n.substr(0)); diff --git a/tests/baselines/reference/parserCastVersusArrowFunction1.errors.txt b/tests/baselines/reference/parserCastVersusArrowFunction1.errors.txt index e2d90538b8c..9a34f75ce40 100644 --- a/tests/baselines/reference/parserCastVersusArrowFunction1.errors.txt +++ b/tests/baselines/reference/parserCastVersusArrowFunction1.errors.txt @@ -25,12 +25,15 @@ tests/cases/conformance/parser/ecmascript5/Generics/parserCastVersusArrowFunctio var v = (a) => 1; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'v' must be of type '() => number', but here has type '(a: any) => number'. +!!! related TS6203 tests/cases/conformance/parser/ecmascript5/Generics/parserCastVersusArrowFunction1.ts:1:5: 'v' was also declared here. var v = (a, b) => 1; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'v' must be of type '() => number', but here has type '(a: any, b: any) => number'. +!!! related TS6203 tests/cases/conformance/parser/ecmascript5/Generics/parserCastVersusArrowFunction1.ts:1:5: 'v' was also declared here. var v = (a = 1, b = 2) => 1; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'v' must be of type '() => number', but here has type '(a?: number, b?: number) => number'. +!!! related TS6203 tests/cases/conformance/parser/ecmascript5/Generics/parserCastVersusArrowFunction1.ts:1:5: 'v' was also declared here. var v = (a); ~ diff --git a/tests/baselines/reference/promiseIdentity2.errors.txt b/tests/baselines/reference/promiseIdentity2.errors.txt index edfba2f42bc..0b5ba8d0ff0 100644 --- a/tests/baselines/reference/promiseIdentity2.errors.txt +++ b/tests/baselines/reference/promiseIdentity2.errors.txt @@ -14,4 +14,5 @@ tests/cases/compiler/promiseIdentity2.ts(11,5): error TS2403: Subsequent variabl var x: IPromise; var x: Promise; ~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'IPromise', but here has type 'Promise'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'IPromise', but here has type 'Promise'. +!!! related TS6203 tests/cases/compiler/promiseIdentity2.ts:10:5: 'x' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/promiseIdentityWithAny2.errors.txt b/tests/baselines/reference/promiseIdentityWithAny2.errors.txt index 9d01438b88c..bedb948b078 100644 --- a/tests/baselines/reference/promiseIdentityWithAny2.errors.txt +++ b/tests/baselines/reference/promiseIdentityWithAny2.errors.txt @@ -15,6 +15,7 @@ tests/cases/compiler/promiseIdentityWithAny2.ts(22,5): error TS2403: Subsequent var x: Promise; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'IPromise', but here has type 'Promise'. +!!! related TS6203 tests/cases/compiler/promiseIdentityWithAny2.ts:9:5: 'x' was also declared here. interface IPromise2 { @@ -28,4 +29,5 @@ tests/cases/compiler/promiseIdentityWithAny2.ts(22,5): error TS2403: Subsequent var y: IPromise2; var y: Promise2; ~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'IPromise2', but here has type 'Promise2'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'IPromise2', but here has type 'Promise2'. +!!! related TS6203 tests/cases/compiler/promiseIdentityWithAny2.ts:21:5: 'y' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/propertyAccess.errors.txt b/tests/baselines/reference/propertyAccess.errors.txt index a183ad79c11..1351a46e099 100644 --- a/tests/baselines/reference/propertyAccess.errors.txt +++ b/tests/baselines/reference/propertyAccess.errors.txt @@ -170,4 +170,5 @@ tests/cases/conformance/expressions/propertyAccess/propertyAccess.ts(149,5): err var x3: A; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x3' must be of type 'A | B', but here has type 'A'. +!!! related TS6203 tests/cases/conformance/expressions/propertyAccess/propertyAccess.ts:148:5: 'x3' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/propertyIdentityWithPrivacyMismatch.errors.txt b/tests/baselines/reference/propertyIdentityWithPrivacyMismatch.errors.txt index 4c5644f6b76..f2ac54f6e7c 100644 --- a/tests/baselines/reference/propertyIdentityWithPrivacyMismatch.errors.txt +++ b/tests/baselines/reference/propertyIdentityWithPrivacyMismatch.errors.txt @@ -10,6 +10,7 @@ tests/cases/compiler/propertyIdentityWithPrivacyMismatch_1.ts(13,5): error TS240 var x: m2.Foo; // Should be error (mod1.Foo !== mod2.Foo) ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'Foo', but here has type 'Foo'. +!!! related TS6203 tests/cases/compiler/propertyIdentityWithPrivacyMismatch_1.ts:4:5: 'x' was also declared here. class Foo1 { private n; } @@ -20,6 +21,7 @@ tests/cases/compiler/propertyIdentityWithPrivacyMismatch_1.ts(13,5): error TS240 var y: Foo2; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'Foo1', but here has type 'Foo2'. +!!! related TS6203 tests/cases/compiler/propertyIdentityWithPrivacyMismatch_1.ts:12:5: 'y' was also declared here. ==== tests/cases/compiler/propertyIdentityWithPrivacyMismatch_0.ts (0 errors) ==== declare module 'mod1' { class Foo { diff --git a/tests/baselines/reference/reassignStaticProp.errors.txt b/tests/baselines/reference/reassignStaticProp.errors.txt index b1bfb869d68..bd62f1aa80d 100644 --- a/tests/baselines/reference/reassignStaticProp.errors.txt +++ b/tests/baselines/reference/reassignStaticProp.errors.txt @@ -12,6 +12,7 @@ tests/cases/compiler/reassignStaticProp.ts(5,12): error TS2717: Subsequent prope !!! error TS2300: Duplicate identifier 'bar'. ~~~ !!! error TS2717: Subsequent property declarations must have the same type. Property 'bar' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/compiler/reassignStaticProp.ts:3:12: 'bar' was also declared here. } diff --git a/tests/baselines/reference/spreadUnion2.errors.txt b/tests/baselines/reference/spreadUnion2.errors.txt index 0115c449930..f2c1bc75778 100644 --- a/tests/baselines/reference/spreadUnion2.errors.txt +++ b/tests/baselines/reference/spreadUnion2.errors.txt @@ -14,28 +14,34 @@ tests/cases/conformance/types/spread/spreadUnion2.ts(18,5): error TS2403: Subseq var o1 = { ...undefinedUnion }; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'o1' must be of type '{} | { a: number; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/types/spread/spreadUnion2.ts:4:5: 'o1' was also declared here. var o2: {} | { b: number }; var o2 = { ...nullUnion }; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'o2' must be of type '{} | { b: number; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/types/spread/spreadUnion2.ts:7:5: 'o2' was also declared here. var o3: {} | { a: number } | { b: number } | { a: number, b: number }; var o3 = { ...undefinedUnion, ...nullUnion }; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'o3' must be of type '{} | { a: number; } | { b: number; } | { a: number; b: number; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/types/spread/spreadUnion2.ts:10:5: 'o3' was also declared here. var o3 = { ...nullUnion, ...undefinedUnion }; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'o3' must be of type '{} | { a: number; } | { b: number; } | { a: number; b: number; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/types/spread/spreadUnion2.ts:10:5: 'o3' was also declared here. var o4: {} | { a: number }; var o4 = { ...undefinedUnion, ...undefinedUnion }; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'o4' must be of type '{} | { a: number; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/types/spread/spreadUnion2.ts:14:5: 'o4' was also declared here. var o5: {} | { b: number }; var o5 = { ...nullUnion, ...nullUnion }; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'o5' must be of type '{} | { b: number; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/types/spread/spreadUnion2.ts:17:5: 'o5' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/strictTupleLength.errors.txt b/tests/baselines/reference/strictTupleLength.errors.txt index 933c6e4dcdb..78cf7b47e97 100644 --- a/tests/baselines/reference/strictTupleLength.errors.txt +++ b/tests/baselines/reference/strictTupleLength.errors.txt @@ -17,9 +17,11 @@ tests/cases/conformance/types/tuple/strictTupleLength.ts(18,1): error TS2741: Pr var t1 = t2; // error ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 't1' must be of type '[number]', but here has type '[number, number]'. +!!! related TS6203 tests/cases/conformance/types/tuple/strictTupleLength.ts:2:5: 't1' was also declared here. var t2 = t1; // error ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 't2' must be of type '[number, number]', but here has type '[number]'. +!!! related TS6203 tests/cases/conformance/types/tuple/strictTupleLength.ts:3:5: 't2' was also declared here. type A = T['length']; var b: A<[boolean]>; diff --git a/tests/baselines/reference/taggedTemplateStringsTypeArgumentInference.errors.txt b/tests/baselines/reference/taggedTemplateStringsTypeArgumentInference.errors.txt index b7018031a69..c678337cfc9 100644 --- a/tests/baselines/reference/taggedTemplateStringsTypeArgumentInference.errors.txt +++ b/tests/baselines/reference/taggedTemplateStringsTypeArgumentInference.errors.txt @@ -83,6 +83,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsTypeArgumentInference var a9e: {}; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a9e' must be of type '{ x: number; z: Date; y?: undefined; } | { x: number; y: string; z?: undefined; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/es6/templates/taggedTemplateStringsTypeArgumentInference.ts:75:5: 'a9e' was also declared here. // Generic tag with multiple parameters of generic type passed arguments with a single best common type var a9d = someGenerics9 `${ { x: 3 }}${ { x: 6 }}${ { x: 6 } }`; diff --git a/tests/baselines/reference/taggedTemplateStringsTypeArgumentInferenceES6.errors.txt b/tests/baselines/reference/taggedTemplateStringsTypeArgumentInferenceES6.errors.txt index ae63e6fd04d..e03b06d72e0 100644 --- a/tests/baselines/reference/taggedTemplateStringsTypeArgumentInferenceES6.errors.txt +++ b/tests/baselines/reference/taggedTemplateStringsTypeArgumentInferenceES6.errors.txt @@ -83,6 +83,7 @@ tests/cases/conformance/es6/templates/taggedTemplateStringsTypeArgumentInference var a9e: {}; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a9e' must be of type '{ x: number; z: Date; y?: undefined; } | { x: number; y: string; z?: undefined; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/es6/templates/taggedTemplateStringsTypeArgumentInferenceES6.ts:75:5: 'a9e' was also declared here. // Generic tag with multiple parameters of generic type passed arguments with a single best common type var a9d = someGenerics9 `${ { x: 3 }}${ { x: 6 }}${ { x: 6 } }`; diff --git a/tests/baselines/reference/tupleTypes.errors.txt b/tests/baselines/reference/tupleTypes.errors.txt index 1cf2f113d14..af76c872a6f 100644 --- a/tests/baselines/reference/tupleTypes.errors.txt +++ b/tests/baselines/reference/tupleTypes.errors.txt @@ -39,6 +39,7 @@ tests/cases/compiler/tupleTypes.ts(51,1): error TS2322: Type '[number, {}]' is n var t2: number|string; ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 't2' must be of type 'undefined', but here has type 'string | number'. +!!! related TS6203 tests/cases/compiler/tupleTypes.ts:11:5: 't2' was also declared here. t = []; // Error ~ @@ -79,6 +80,7 @@ tests/cases/compiler/tupleTypes.ts(51,1): error TS2322: Type '[number, {}]' is n var tt2: number | string; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'tt2' must be of type 'undefined', but here has type 'string | number'. +!!! related TS6203 tests/cases/compiler/tupleTypes.ts:35:5: 'tt2' was also declared here. tt = tuple2(1, undefined); tt = [1, undefined]; diff --git a/tests/baselines/reference/typeArgumentInference.errors.txt b/tests/baselines/reference/typeArgumentInference.errors.txt index 95e47ab583f..fd4bd90771e 100644 --- a/tests/baselines/reference/typeArgumentInference.errors.txt +++ b/tests/baselines/reference/typeArgumentInference.errors.txt @@ -92,6 +92,7 @@ tests/cases/conformance/expressions/functionCalls/typeArgumentInference.ts(84,74 var a9e: {}; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a9e' must be of type '{ x: number; z: Date; y?: undefined; } | { x: number; y: string; z?: undefined; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/expressions/functionCalls/typeArgumentInference.ts:82:5: 'a9e' was also declared here. var a9f = someGenerics9(undefined, { x: 6, z: new Date() }, { x: 6, y: '' }); ~~~~~ !!! error TS2345: Argument of type '{ x: number; y: string; }' is not assignable to parameter of type 'A92'. diff --git a/tests/baselines/reference/typeArgumentInferenceConstructSignatures.errors.txt b/tests/baselines/reference/typeArgumentInferenceConstructSignatures.errors.txt index 8707ff26ef0..e40f1210487 100644 --- a/tests/baselines/reference/typeArgumentInferenceConstructSignatures.errors.txt +++ b/tests/baselines/reference/typeArgumentInferenceConstructSignatures.errors.txt @@ -154,6 +154,7 @@ tests/cases/conformance/expressions/functionCalls/typeArgumentInferenceConstruct var a9e: {}; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a9e' must be of type '{ x: number; z: Window; y?: undefined; } | { x: number; y: string; z?: undefined; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/expressions/functionCalls/typeArgumentInferenceConstructSignatures.ts:120:5: 'a9e' was also declared here. var a9f = new someGenerics9(undefined, { x: 6, z: window }, { x: 6, y: '' }); ~~~~~ !!! error TS2345: Argument of type '{ x: number; y: string; }' is not assignable to parameter of type 'A92'. diff --git a/tests/baselines/reference/typeArgumentInferenceWithConstraints.errors.txt b/tests/baselines/reference/typeArgumentInferenceWithConstraints.errors.txt index 3b7750f23f0..e07a0be74cb 100644 --- a/tests/baselines/reference/typeArgumentInferenceWithConstraints.errors.txt +++ b/tests/baselines/reference/typeArgumentInferenceWithConstraints.errors.txt @@ -140,6 +140,7 @@ tests/cases/conformance/expressions/functionCalls/typeArgumentInferenceWithConst var a9e: {}; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'a9e' must be of type '{ x: number; z: Window; y?: undefined; } | { x: number; y: string; z?: undefined; }', but here has type '{}'. +!!! related TS6203 tests/cases/conformance/expressions/functionCalls/typeArgumentInferenceWithConstraints.ts:87:5: 'a9e' was also declared here. var a9f = someGenerics9(undefined, { x: 6, z: window }, { x: 6, y: '' }); ~~~~~ !!! error TS2345: Argument of type '{ x: number; y: string; }' is not assignable to parameter of type 'A92'. diff --git a/tests/baselines/reference/typeGuardOfFormTypeOfEqualEqualHasNoEffect.errors.txt b/tests/baselines/reference/typeGuardOfFormTypeOfEqualEqualHasNoEffect.errors.txt index e10cf2d1a78..52c312ae7c0 100644 --- a/tests/baselines/reference/typeGuardOfFormTypeOfEqualEqualHasNoEffect.errors.txt +++ b/tests/baselines/reference/typeGuardOfFormTypeOfEqualEqualHasNoEffect.errors.txt @@ -21,6 +21,7 @@ tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfEqualEqualHa var r1 = strOrNum; // string | number ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r1' must be of type 'string', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfEqualEqualHasNoEffect.ts:10:9: 'r1' was also declared here. } if (typeof strOrBool == "boolean") { @@ -30,6 +31,7 @@ tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfEqualEqualHa var r2 = strOrBool; // string | boolean ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r2' must be of type 'boolean', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfEqualEqualHasNoEffect.ts:17:9: 'r2' was also declared here. } if (typeof numOrBool == "number") { @@ -39,6 +41,7 @@ tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfEqualEqualHa var r3 = numOrBool; // number | boolean ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r3' must be of type 'number', but here has type 'boolean'. +!!! related TS6203 tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfEqualEqualHasNoEffect.ts:24:9: 'r3' was also declared here. } if (typeof strOrC == "Object") { @@ -50,4 +53,5 @@ tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfEqualEqualHa var r4 = strOrC; // string | C ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r4' must be of type 'C', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfEqualEqualHasNoEffect.ts:31:9: 'r4' was also declared here. } \ No newline at end of file diff --git a/tests/baselines/reference/typeGuardOfFormTypeOfNotEqualHasNoEffect.errors.txt b/tests/baselines/reference/typeGuardOfFormTypeOfNotEqualHasNoEffect.errors.txt index a0e9cd0f7bf..46b10e75b87 100644 --- a/tests/baselines/reference/typeGuardOfFormTypeOfNotEqualHasNoEffect.errors.txt +++ b/tests/baselines/reference/typeGuardOfFormTypeOfNotEqualHasNoEffect.errors.txt @@ -21,6 +21,7 @@ tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfNotEqualHasN var r1 = strOrNum; // string | number ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r1' must be of type 'number', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfNotEqualHasNoEffect.ts:10:9: 'r1' was also declared here. } if (typeof strOrBool != "boolean") { @@ -30,6 +31,7 @@ tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfNotEqualHasN var r2 = strOrBool; // string | boolean ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r2' must be of type 'string', but here has type 'boolean'. +!!! related TS6203 tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfNotEqualHasNoEffect.ts:17:9: 'r2' was also declared here. } if (typeof numOrBool != "number") { @@ -39,6 +41,7 @@ tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfNotEqualHasN var r3 = numOrBool; // number | boolean ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r3' must be of type 'boolean', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfNotEqualHasNoEffect.ts:24:9: 'r3' was also declared here. } if (typeof strOrC != "Object") { @@ -50,4 +53,5 @@ tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfNotEqualHasN var r4 = strOrC; // string | C ~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'r4' must be of type 'string', but here has type 'C'. +!!! related TS6203 tests/cases/conformance/expressions/typeGuards/typeGuardOfFormTypeOfNotEqualHasNoEffect.ts:31:9: 'r4' was also declared here. } \ No newline at end of file diff --git a/tests/baselines/reference/typeOfEnumAndVarRedeclarations.errors.txt b/tests/baselines/reference/typeOfEnumAndVarRedeclarations.errors.txt index 89849d3a614..43035121212 100644 --- a/tests/baselines/reference/typeOfEnumAndVarRedeclarations.errors.txt +++ b/tests/baselines/reference/typeOfEnumAndVarRedeclarations.errors.txt @@ -14,9 +14,11 @@ tests/cases/compiler/typeOfEnumAndVarRedeclarations.ts(10,70): error TS2375: Dup var x: { readonly a: E; readonly b: E; readonly [x: number]: string; }; // Shouldnt error ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'typeof E', but here has type '{ readonly [x: number]: string; readonly a: E; readonly b: E; }'. +!!! related TS6203 tests/cases/compiler/typeOfEnumAndVarRedeclarations.ts:7:5: 'x' was also declared here. var y = E; var y: { readonly a: E; readonly b: E; readonly [x: number]: string; readonly [x: number]: string } // two errors: the types are not identical and duplicate signatures ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'y' must be of type 'typeof E', but here has type '{ readonly [x: number]: string; readonly a: E; readonly b: E; }'. +!!! related TS6203 tests/cases/compiler/typeOfEnumAndVarRedeclarations.ts:9:5: 'y' was also declared here. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ !!! error TS2375: Duplicate number index signature. \ No newline at end of file diff --git a/tests/baselines/reference/typeOfThis.errors.txt b/tests/baselines/reference/typeOfThis.errors.txt index b47207670cc..adba7ba2f9f 100644 --- a/tests/baselines/reference/typeOfThis.errors.txt +++ b/tests/baselines/reference/typeOfThis.errors.txt @@ -27,12 +27,14 @@ tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts(106,13): error TS2 var t: MyTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 't' must be of type 'this', but here has type 'MyTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:13:16: 't' was also declared here. //type of 'this' in member function body is the class instance type var p = this; var p: MyTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'p' must be of type 'this', but here has type 'MyTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:17:13: 'p' was also declared here. } //type of 'this' in member accessor(get and set) body is the class instance type @@ -41,6 +43,7 @@ tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts(106,13): error TS2 var p: MyTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'p' must be of type 'this', but here has type 'MyTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:23:13: 'p' was also declared here. return this; } set prop(v) { @@ -48,6 +51,7 @@ tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts(106,13): error TS2 var p: MyTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'p' must be of type 'this', but here has type 'MyTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:28:13: 'p' was also declared here. p = v; v = p; } @@ -58,6 +62,7 @@ tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts(106,13): error TS2 var t: MyTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 't' must be of type 'this', but here has type 'MyTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:36:13: 't' was also declared here. }; //type of 'this' in static function param list is constructor function type @@ -106,12 +111,14 @@ tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts(106,13): error TS2 var t: MyGenericTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 't' must be of type 'this', but here has type 'MyGenericTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:82:16: 't' was also declared here. //type of 'this' in member function body is the class instance type var p = this; var p: MyGenericTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'p' must be of type 'this', but here has type 'MyGenericTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:86:13: 'p' was also declared here. } //type of 'this' in member accessor(get and set) body is the class instance type @@ -120,6 +127,7 @@ tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts(106,13): error TS2 var p: MyGenericTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'p' must be of type 'this', but here has type 'MyGenericTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:92:13: 'p' was also declared here. return this; } set prop(v) { @@ -127,6 +135,7 @@ tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts(106,13): error TS2 var p: MyGenericTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'p' must be of type 'this', but here has type 'MyGenericTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:97:13: 'p' was also declared here. p = v; v = p; } @@ -137,6 +146,7 @@ tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts(106,13): error TS2 var t: MyGenericTestClass; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 't' must be of type 'this', but here has type 'MyGenericTestClass'. +!!! related TS6203 tests/cases/conformance/expressions/thisKeyword/typeOfThis.ts:105:13: 't' was also declared here. }; //type of 'this' in static function param list is constructor function type diff --git a/tests/baselines/reference/unionTypeEquivalence.errors.txt b/tests/baselines/reference/unionTypeEquivalence.errors.txt index d561a96f97e..3a50459e925 100644 --- a/tests/baselines/reference/unionTypeEquivalence.errors.txt +++ b/tests/baselines/reference/unionTypeEquivalence.errors.txt @@ -9,6 +9,7 @@ tests/cases/conformance/types/union/unionTypeEquivalence.ts(5,5): error TS2403: var x : C | D; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'C', but here has type 'C | D'. +!!! related TS6203 tests/cases/conformance/types/union/unionTypeEquivalence.ts:4:5: 'x' was also declared here. // A | B is equivalent to B | A. var y: string | number; diff --git a/tests/baselines/reference/unionTypeIdentity.errors.txt b/tests/baselines/reference/unionTypeIdentity.errors.txt index 77d25bd78d1..4acb5895d41 100644 --- a/tests/baselines/reference/unionTypeIdentity.errors.txt +++ b/tests/baselines/reference/unionTypeIdentity.errors.txt @@ -12,9 +12,12 @@ tests/cases/conformance/types/typeRelationships/typeAndMemberIdentity/unionTypeI var strOrNum: string; // error ~~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'strOrNum' must be of type 'string | boolean', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/types/typeRelationships/typeAndMemberIdentity/unionTypeIdentity.ts:3:5: 'strOrNum' was also declared here. var strOrNum: boolean; // error ~~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'strOrNum' must be of type 'string | boolean', but here has type 'boolean'. +!!! related TS6203 tests/cases/conformance/types/typeRelationships/typeAndMemberIdentity/unionTypeIdentity.ts:3:5: 'strOrNum' was also declared here. var strOrNum: number; // error ~~~~~~~~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'strOrNum' must be of type 'string | boolean', but here has type 'number'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'strOrNum' must be of type 'string | boolean', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/types/typeRelationships/typeAndMemberIdentity/unionTypeIdentity.ts:3:5: 'strOrNum' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/unionTypeLiterals.errors.txt b/tests/baselines/reference/unionTypeLiterals.errors.txt index d976d769f59..197f4e23647 100644 --- a/tests/baselines/reference/unionTypeLiterals.errors.txt +++ b/tests/baselines/reference/unionTypeLiterals.errors.txt @@ -16,9 +16,11 @@ tests/cases/conformance/types/specifyingTypes/typeLiterals/unionTypeLiterals.ts( var unionOfFunctionType: () => string | number; ~~~~~~~~~~~~~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'unionOfFunctionType' must be of type '(() => string) | (() => number)', but here has type '() => string | number'. +!!! related TS6203 tests/cases/conformance/types/specifyingTypes/typeLiterals/unionTypeLiterals.ts:9:5: 'unionOfFunctionType' was also declared here. var unionOfConstructorType: (new () => string) | (new () => number); var unionOfConstructorType: { new (): string } | { new (): number }; var unionOfConstructorType: new () => string | number; ~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'unionOfConstructorType' must be of type '(new () => string) | (new () => number)', but here has type 'new () => string | number'. \ No newline at end of file +!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'unionOfConstructorType' must be of type '(new () => string) | (new () => number)', but here has type 'new () => string | number'. +!!! related TS6203 tests/cases/conformance/types/specifyingTypes/typeLiterals/unionTypeLiterals.ts:13:5: 'unionOfConstructorType' was also declared here. \ No newline at end of file diff --git a/tests/baselines/reference/varBlock.errors.txt b/tests/baselines/reference/varBlock.errors.txt index 12e3fc6a629..bcdb58f5979 100644 --- a/tests/baselines/reference/varBlock.errors.txt +++ b/tests/baselines/reference/varBlock.errors.txt @@ -98,5 +98,6 @@ tests/cases/compiler/varBlock.ts(39,17): error TS1039: Initializers are not allo declare var c = 10; ~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'c' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/compiler/varBlock.ts:38:13: 'c' was also declared here. ~~ !!! error TS1039: Initializers are not allowed in ambient contexts. \ No newline at end of file diff --git a/tests/baselines/reference/witness.errors.txt b/tests/baselines/reference/witness.errors.txt index cf21a8b2ed2..efaed3cc43c 100644 --- a/tests/baselines/reference/witness.errors.txt +++ b/tests/baselines/reference/witness.errors.txt @@ -56,6 +56,7 @@ tests/cases/conformance/types/witness/witness.ts(128,19): error TS2729: Property var co1: number; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'co1' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/types/witness/witness.ts:28:5: 'co1' was also declared here. var co2 = (3, 4, co2); ~ !!! error TS2695: Left side of comma operator is unused and has no side effects. @@ -72,22 +73,26 @@ tests/cases/conformance/types/witness/witness.ts(128,19): error TS2729: Property var co3: number; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'co3' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/types/witness/witness.ts:32:5: 'co3' was also declared here. // Assignment var as1 = (as1 = 2); var as1: number; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'as1' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/types/witness/witness.ts:36:5: 'as1' was also declared here. var as2 = (as2 = as2 = 2); var as2: number; ~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'as2' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/types/witness/witness.ts:38:5: 'as2' was also declared here. // Conditional var cnd1 = cnd1 ? 0 : 1; var cnd1: number; ~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'cnd1' must be of type 'any', but here has type 'number'. +!!! related TS6203 tests/cases/conformance/types/witness/witness.ts:42:5: 'cnd1' was also declared here. var cnd2 = cnd1 ? cnd1 ? '' : "" : ''; var cnd2: string; @@ -104,6 +109,7 @@ tests/cases/conformance/types/witness/witness.ts(128,19): error TS2729: Property var and1: string; ~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'and1' must be of type 'any', but here has type 'string'. +!!! related TS6203 tests/cases/conformance/types/witness/witness.ts:56:5: 'and1' was also declared here. var and2 = '' && and2; var and2: any; var and3 = and3 && and3; @@ -159,6 +165,7 @@ tests/cases/conformance/types/witness/witness.ts(128,19): error TS2729: Property var propAcc1: { m: any; } ~~~~~~~~ !!! error TS2403: Subsequent variable declarations must have the same type. Variable 'propAcc1' must be of type 'any', but here has type '{ m: any; }'. +!!! related TS6203 tests/cases/conformance/types/witness/witness.ts:107:5: 'propAcc1' was also declared here. // Property access of module member module M2 { From 8120094c81236651da967c33d7bd5ca185188faf Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 22 May 2019 06:49:49 -0700 Subject: [PATCH 077/119] Simplify index and object types when obtaining indexed access constraint --- src/compiler/checker.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index e9dddff64af..bd8d4c05901 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -7657,15 +7657,20 @@ namespace ts { return hasNonCircularBaseConstraint(type) ? getConstraintFromIndexedAccess(type) : undefined; } + function getSimplifiedTypeOrConstraint(type: Type) { + const simplified = getSimplifiedType(type, /*writing*/ false); + return simplified !== type ? simplified : getConstraintOfType(type); + } + function getConstraintFromIndexedAccess(type: IndexedAccessType) { - const indexConstraint = getConstraintOfType(type.indexType); + const indexConstraint = getSimplifiedTypeOrConstraint(type.indexType); if (indexConstraint && indexConstraint !== type.indexType) { const indexedAccess = getIndexedAccessTypeOrUndefined(type.objectType, indexConstraint); if (indexedAccess) { return indexedAccess; } } - const objectConstraint = getConstraintOfType(type.objectType); + const objectConstraint = getSimplifiedTypeOrConstraint(type.objectType); if (objectConstraint && objectConstraint !== type.objectType) { return getIndexedAccessTypeOrUndefined(objectConstraint, type.indexType); } From 2fd4aaee92a17318ad1c45c6f6590bbb8b82d33d Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 22 May 2019 06:54:16 -0700 Subject: [PATCH 078/119] Add regression test --- .../conformance/types/keyof/keyofAndIndexedAccess2.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts b/tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts index a99c2b0a7a1..898648cea44 100644 --- a/tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts +++ b/tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts @@ -147,3 +147,13 @@ export class c { this["a"] = "b"; } } + +// Repro from #31385 + +type Foo = { [key: string]: { [K in keyof T]: K }[keyof T] }; + +type Bar = { [key: string]: { [K in keyof T]: [K] }[keyof T] }; + +type Baz> = { [K in keyof Q]: T[Q[K]] }; + +type Qux> = { [K in keyof Q]: T[Q[K]["0"]] }; From b7012b577a6e755215f80d3166e90f60aa50b98e Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 22 May 2019 06:54:23 -0700 Subject: [PATCH 079/119] Accept new baselines --- .../keyofAndIndexedAccess2.errors.txt | 10 +++++ .../reference/keyofAndIndexedAccess2.js | 10 +++++ .../reference/keyofAndIndexedAccess2.symbols | 44 +++++++++++++++++++ .../reference/keyofAndIndexedAccess2.types | 16 +++++++ 4 files changed, 80 insertions(+) diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt b/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt index 9ebf28f1857..1cad297c52d 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt +++ b/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt @@ -228,4 +228,14 @@ tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(108,5): error TS23 this["a"] = "b"; } } + + // Repro from #31385 + + type Foo = { [key: string]: { [K in keyof T]: K }[keyof T] }; + + type Bar = { [key: string]: { [K in keyof T]: [K] }[keyof T] }; + + type Baz> = { [K in keyof Q]: T[Q[K]] }; + + type Qux> = { [K in keyof Q]: T[Q[K]["0"]] }; \ No newline at end of file diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.js b/tests/baselines/reference/keyofAndIndexedAccess2.js index 374b13b5a64..7547a3f84c5 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.js +++ b/tests/baselines/reference/keyofAndIndexedAccess2.js @@ -145,6 +145,16 @@ export class c { this["a"] = "b"; } } + +// Repro from #31385 + +type Foo = { [key: string]: { [K in keyof T]: K }[keyof T] }; + +type Bar = { [key: string]: { [K in keyof T]: [K] }[keyof T] }; + +type Baz> = { [K in keyof Q]: T[Q[K]] }; + +type Qux> = { [K in keyof Q]: T[Q[K]["0"]] }; //// [keyofAndIndexedAccess2.js] diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.symbols b/tests/baselines/reference/keyofAndIndexedAccess2.symbols index a3412e8a47d..91602f93e1d 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.symbols +++ b/tests/baselines/reference/keyofAndIndexedAccess2.symbols @@ -517,3 +517,47 @@ export class c { } } +// Repro from #31385 + +type Foo = { [key: string]: { [K in keyof T]: K }[keyof T] }; +>Foo : Symbol(Foo, Decl(keyofAndIndexedAccess2.ts, 145, 1)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 149, 9)) +>key : Symbol(key, Decl(keyofAndIndexedAccess2.ts, 149, 17)) +>K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 149, 34)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 149, 9)) +>K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 149, 34)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 149, 9)) + +type Bar = { [key: string]: { [K in keyof T]: [K] }[keyof T] }; +>Bar : Symbol(Bar, Decl(keyofAndIndexedAccess2.ts, 149, 64)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 151, 9)) +>key : Symbol(key, Decl(keyofAndIndexedAccess2.ts, 151, 17)) +>K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 151, 34)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 151, 9)) +>K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 151, 34)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 151, 9)) + +type Baz> = { [K in keyof Q]: T[Q[K]] }; +>Baz : Symbol(Baz, Decl(keyofAndIndexedAccess2.ts, 151, 66)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 153, 9)) +>Q : Symbol(Q, Decl(keyofAndIndexedAccess2.ts, 153, 11)) +>Foo : Symbol(Foo, Decl(keyofAndIndexedAccess2.ts, 145, 1)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 153, 9)) +>K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 153, 35)) +>Q : Symbol(Q, Decl(keyofAndIndexedAccess2.ts, 153, 11)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 153, 9)) +>Q : Symbol(Q, Decl(keyofAndIndexedAccess2.ts, 153, 11)) +>K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 153, 35)) + +type Qux> = { [K in keyof Q]: T[Q[K]["0"]] }; +>Qux : Symbol(Qux, Decl(keyofAndIndexedAccess2.ts, 153, 60)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 155, 9)) +>Q : Symbol(Q, Decl(keyofAndIndexedAccess2.ts, 155, 11)) +>Bar : Symbol(Bar, Decl(keyofAndIndexedAccess2.ts, 149, 64)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 155, 9)) +>K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 155, 35)) +>Q : Symbol(Q, Decl(keyofAndIndexedAccess2.ts, 155, 11)) +>T : Symbol(T, Decl(keyofAndIndexedAccess2.ts, 155, 9)) +>Q : Symbol(Q, Decl(keyofAndIndexedAccess2.ts, 155, 11)) +>K : Symbol(K, Decl(keyofAndIndexedAccess2.ts, 155, 35)) + diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.types b/tests/baselines/reference/keyofAndIndexedAccess2.types index b7b71ba4f9f..45cf1d4bad5 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.types +++ b/tests/baselines/reference/keyofAndIndexedAccess2.types @@ -517,3 +517,19 @@ export class c { } } +// Repro from #31385 + +type Foo = { [key: string]: { [K in keyof T]: K }[keyof T] }; +>Foo : Foo +>key : string + +type Bar = { [key: string]: { [K in keyof T]: [K] }[keyof T] }; +>Bar : Bar +>key : string + +type Baz> = { [K in keyof Q]: T[Q[K]] }; +>Baz : Baz + +type Qux> = { [K in keyof Q]: T[Q[K]["0"]] }; +>Qux : Qux + From b36c8a06902ca47da1568167991bd0bc28ced80e Mon Sep 17 00:00:00 2001 From: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com> Date: Wed, 22 May 2019 09:45:41 -0700 Subject: [PATCH 080/119] Make anyArray.filter(Boolean) return any[], not unknown[] (#31515) * Add this-parameter workaround to Array.filter Allows anys.filter(Boolean) to once again return any[], not unknown[]. * Add any constraint to Boolean factory function I want to test how well this works. * Remove Boolean factory type guard * Remove typeGuardBoolean test --- src/lib/es5.d.ts | 2 +- .../reference/booleanFilterAnyArray.js | 37 ++++++ .../reference/booleanFilterAnyArray.symbols | 108 ++++++++++++++++++ .../reference/booleanFilterAnyArray.types | 94 +++++++++++++++ tests/baselines/reference/typeGuardBoolean.js | 30 ----- .../reference/typeGuardBoolean.symbols | 35 ------ .../reference/typeGuardBoolean.types | 44 ------- tests/cases/compiler/booleanFilterAnyArray.ts | 24 ++++ .../typeGuards/typeGuardBoolean.ts | 14 --- 9 files changed, 264 insertions(+), 124 deletions(-) create mode 100644 tests/baselines/reference/booleanFilterAnyArray.js create mode 100644 tests/baselines/reference/booleanFilterAnyArray.symbols create mode 100644 tests/baselines/reference/booleanFilterAnyArray.types delete mode 100644 tests/baselines/reference/typeGuardBoolean.js delete mode 100644 tests/baselines/reference/typeGuardBoolean.symbols delete mode 100644 tests/baselines/reference/typeGuardBoolean.types create mode 100644 tests/cases/compiler/booleanFilterAnyArray.ts delete mode 100644 tests/cases/conformance/expressions/typeGuards/typeGuardBoolean.ts diff --git a/src/lib/es5.d.ts b/src/lib/es5.d.ts index f2be6716c72..0d1481dd7d2 100644 --- a/src/lib/es5.d.ts +++ b/src/lib/es5.d.ts @@ -513,7 +513,7 @@ interface Boolean { interface BooleanConstructor { new(value?: any): Boolean; - (value?: T): value is Exclude; + (value?: T): boolean; readonly prototype: Boolean; } diff --git a/tests/baselines/reference/booleanFilterAnyArray.js b/tests/baselines/reference/booleanFilterAnyArray.js new file mode 100644 index 00000000000..2cd319ca440 --- /dev/null +++ b/tests/baselines/reference/booleanFilterAnyArray.js @@ -0,0 +1,37 @@ +//// [booleanFilterAnyArray.ts] +interface Bullean { } +interface BulleanConstructor { + new(v1?: any): Bullean; + (v2?: T): v2 is T; +} + +interface Ari { + filter(cb1: (value: T) => value is S): T extends any ? Ari : Ari; + filter(cb2: (value: T) => unknown): Ari; +} +declare var Bullean: BulleanConstructor; +declare let anys: Ari; +var xs: Ari; +var xs = anys.filter(Bullean) + +declare let realanys: any[]; +var ys: any[]; +var ys = realanys.filter(Boolean) + +var foo = [{ name: 'x' }] +var foor: Array<{name: string}> +var foor = foo.filter(x => x.name) +var foos: Array +var foos = [true, true, false, null].filter((thing): thing is boolean => thing !== null) + + +//// [booleanFilterAnyArray.js] +var xs; +var xs = anys.filter(Bullean); +var ys; +var ys = realanys.filter(Boolean); +var foo = [{ name: 'x' }]; +var foor; +var foor = foo.filter(function (x) { return x.name; }); +var foos; +var foos = [true, true, false, null].filter(function (thing) { return thing !== null; }); diff --git a/tests/baselines/reference/booleanFilterAnyArray.symbols b/tests/baselines/reference/booleanFilterAnyArray.symbols new file mode 100644 index 00000000000..1e0207fdf80 --- /dev/null +++ b/tests/baselines/reference/booleanFilterAnyArray.symbols @@ -0,0 +1,108 @@ +=== tests/cases/compiler/booleanFilterAnyArray.ts === +interface Bullean { } +>Bullean : Symbol(Bullean, Decl(booleanFilterAnyArray.ts, 0, 0), Decl(booleanFilterAnyArray.ts, 10, 11)) + +interface BulleanConstructor { +>BulleanConstructor : Symbol(BulleanConstructor, Decl(booleanFilterAnyArray.ts, 0, 21)) + + new(v1?: any): Bullean; +>v1 : Symbol(v1, Decl(booleanFilterAnyArray.ts, 2, 8)) +>Bullean : Symbol(Bullean, Decl(booleanFilterAnyArray.ts, 0, 0), Decl(booleanFilterAnyArray.ts, 10, 11)) + + (v2?: T): v2 is T; +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 3, 5)) +>v2 : Symbol(v2, Decl(booleanFilterAnyArray.ts, 3, 8)) +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 3, 5)) +>v2 : Symbol(v2, Decl(booleanFilterAnyArray.ts, 3, 8)) +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 3, 5)) +} + +interface Ari { +>Ari : Symbol(Ari, Decl(booleanFilterAnyArray.ts, 4, 1)) +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 6, 14)) + + filter(cb1: (value: T) => value is S): T extends any ? Ari : Ari; +>filter : Symbol(Ari.filter, Decl(booleanFilterAnyArray.ts, 6, 18), Decl(booleanFilterAnyArray.ts, 7, 90)) +>S : Symbol(S, Decl(booleanFilterAnyArray.ts, 7, 11)) +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 6, 14)) +>cb1 : Symbol(cb1, Decl(booleanFilterAnyArray.ts, 7, 24)) +>value : Symbol(value, Decl(booleanFilterAnyArray.ts, 7, 30)) +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 6, 14)) +>value : Symbol(value, Decl(booleanFilterAnyArray.ts, 7, 30)) +>S : Symbol(S, Decl(booleanFilterAnyArray.ts, 7, 11)) +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 6, 14)) +>Ari : Symbol(Ari, Decl(booleanFilterAnyArray.ts, 4, 1)) +>Ari : Symbol(Ari, Decl(booleanFilterAnyArray.ts, 4, 1)) +>S : Symbol(S, Decl(booleanFilterAnyArray.ts, 7, 11)) + + filter(cb2: (value: T) => unknown): Ari; +>filter : Symbol(Ari.filter, Decl(booleanFilterAnyArray.ts, 6, 18), Decl(booleanFilterAnyArray.ts, 7, 90)) +>cb2 : Symbol(cb2, Decl(booleanFilterAnyArray.ts, 8, 11)) +>value : Symbol(value, Decl(booleanFilterAnyArray.ts, 8, 17)) +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 6, 14)) +>Ari : Symbol(Ari, Decl(booleanFilterAnyArray.ts, 4, 1)) +>T : Symbol(T, Decl(booleanFilterAnyArray.ts, 6, 14)) +} +declare var Bullean: BulleanConstructor; +>Bullean : Symbol(Bullean, Decl(booleanFilterAnyArray.ts, 0, 0), Decl(booleanFilterAnyArray.ts, 10, 11)) +>BulleanConstructor : Symbol(BulleanConstructor, Decl(booleanFilterAnyArray.ts, 0, 21)) + +declare let anys: Ari; +>anys : Symbol(anys, Decl(booleanFilterAnyArray.ts, 11, 11)) +>Ari : Symbol(Ari, Decl(booleanFilterAnyArray.ts, 4, 1)) + +var xs: Ari; +>xs : Symbol(xs, Decl(booleanFilterAnyArray.ts, 12, 3), Decl(booleanFilterAnyArray.ts, 13, 3)) +>Ari : Symbol(Ari, Decl(booleanFilterAnyArray.ts, 4, 1)) + +var xs = anys.filter(Bullean) +>xs : Symbol(xs, Decl(booleanFilterAnyArray.ts, 12, 3), Decl(booleanFilterAnyArray.ts, 13, 3)) +>anys.filter : Symbol(Ari.filter, Decl(booleanFilterAnyArray.ts, 6, 18), Decl(booleanFilterAnyArray.ts, 7, 90)) +>anys : Symbol(anys, Decl(booleanFilterAnyArray.ts, 11, 11)) +>filter : Symbol(Ari.filter, Decl(booleanFilterAnyArray.ts, 6, 18), Decl(booleanFilterAnyArray.ts, 7, 90)) +>Bullean : Symbol(Bullean, Decl(booleanFilterAnyArray.ts, 0, 0), Decl(booleanFilterAnyArray.ts, 10, 11)) + +declare let realanys: any[]; +>realanys : Symbol(realanys, Decl(booleanFilterAnyArray.ts, 15, 11)) + +var ys: any[]; +>ys : Symbol(ys, Decl(booleanFilterAnyArray.ts, 16, 3), Decl(booleanFilterAnyArray.ts, 17, 3)) + +var ys = realanys.filter(Boolean) +>ys : Symbol(ys, Decl(booleanFilterAnyArray.ts, 16, 3), Decl(booleanFilterAnyArray.ts, 17, 3)) +>realanys.filter : Symbol(Array.filter, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>realanys : Symbol(realanys, Decl(booleanFilterAnyArray.ts, 15, 11)) +>filter : Symbol(Array.filter, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>Boolean : Symbol(Boolean, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) + +var foo = [{ name: 'x' }] +>foo : Symbol(foo, Decl(booleanFilterAnyArray.ts, 19, 3)) +>name : Symbol(name, Decl(booleanFilterAnyArray.ts, 19, 12)) + +var foor: Array<{name: string}> +>foor : Symbol(foor, Decl(booleanFilterAnyArray.ts, 20, 3), Decl(booleanFilterAnyArray.ts, 21, 3)) +>Array : Symbol(Array, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>name : Symbol(name, Decl(booleanFilterAnyArray.ts, 20, 17)) + +var foor = foo.filter(x => x.name) +>foor : Symbol(foor, Decl(booleanFilterAnyArray.ts, 20, 3), Decl(booleanFilterAnyArray.ts, 21, 3)) +>foo.filter : Symbol(Array.filter, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>foo : Symbol(foo, Decl(booleanFilterAnyArray.ts, 19, 3)) +>filter : Symbol(Array.filter, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>x : Symbol(x, Decl(booleanFilterAnyArray.ts, 21, 22)) +>x.name : Symbol(name, Decl(booleanFilterAnyArray.ts, 19, 12)) +>x : Symbol(x, Decl(booleanFilterAnyArray.ts, 21, 22)) +>name : Symbol(name, Decl(booleanFilterAnyArray.ts, 19, 12)) + +var foos: Array +>foos : Symbol(foos, Decl(booleanFilterAnyArray.ts, 22, 3), Decl(booleanFilterAnyArray.ts, 23, 3)) +>Array : Symbol(Array, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) + +var foos = [true, true, false, null].filter((thing): thing is boolean => thing !== null) +>foos : Symbol(foos, Decl(booleanFilterAnyArray.ts, 22, 3), Decl(booleanFilterAnyArray.ts, 23, 3)) +>[true, true, false, null].filter : Symbol(Array.filter, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>filter : Symbol(Array.filter, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) +>thing : Symbol(thing, Decl(booleanFilterAnyArray.ts, 23, 45)) +>thing : Symbol(thing, Decl(booleanFilterAnyArray.ts, 23, 45)) +>thing : Symbol(thing, Decl(booleanFilterAnyArray.ts, 23, 45)) + diff --git a/tests/baselines/reference/booleanFilterAnyArray.types b/tests/baselines/reference/booleanFilterAnyArray.types new file mode 100644 index 00000000000..a1d4303ef8e --- /dev/null +++ b/tests/baselines/reference/booleanFilterAnyArray.types @@ -0,0 +1,94 @@ +=== tests/cases/compiler/booleanFilterAnyArray.ts === +interface Bullean { } +interface BulleanConstructor { + new(v1?: any): Bullean; +>v1 : any + + (v2?: T): v2 is T; +>v2 : T +} + +interface Ari { + filter(cb1: (value: T) => value is S): T extends any ? Ari : Ari; +>filter : { (cb1: (value: T) => value is S): T extends any ? Ari : Ari; (cb2: (value: T) => unknown): Ari; } +>cb1 : (value: T) => value is S +>value : T + + filter(cb2: (value: T) => unknown): Ari; +>filter : { (cb1: (value: T) => value is S): T extends any ? Ari : Ari; (cb2: (value: T) => unknown): Ari; } +>cb2 : (value: T) => unknown +>value : T +} +declare var Bullean: BulleanConstructor; +>Bullean : BulleanConstructor + +declare let anys: Ari; +>anys : Ari + +var xs: Ari; +>xs : Ari + +var xs = anys.filter(Bullean) +>xs : Ari +>anys.filter(Bullean) : Ari +>anys.filter : { (cb1: (value: any) => value is S): Ari; (cb2: (value: any) => unknown): Ari; } +>anys : Ari +>filter : { (cb1: (value: any) => value is S): Ari; (cb2: (value: any) => unknown): Ari; } +>Bullean : BulleanConstructor + +declare let realanys: any[]; +>realanys : any[] + +var ys: any[]; +>ys : any[] + +var ys = realanys.filter(Boolean) +>ys : any[] +>realanys.filter(Boolean) : any[] +>realanys.filter : { (callbackfn: (value: any, index: number, array: any[]) => value is S, thisArg?: any): S[]; (callbackfn: (value: any, index: number, array: any[]) => unknown, thisArg?: any): any[]; } +>realanys : any[] +>filter : { (callbackfn: (value: any, index: number, array: any[]) => value is S, thisArg?: any): S[]; (callbackfn: (value: any, index: number, array: any[]) => unknown, thisArg?: any): any[]; } +>Boolean : BooleanConstructor + +var foo = [{ name: 'x' }] +>foo : { name: string; }[] +>[{ name: 'x' }] : { name: string; }[] +>{ name: 'x' } : { name: string; } +>name : string +>'x' : "x" + +var foor: Array<{name: string}> +>foor : { name: string; }[] +>name : string + +var foor = foo.filter(x => x.name) +>foor : { name: string; }[] +>foo.filter(x => x.name) : { name: string; }[] +>foo.filter : { (callbackfn: (value: { name: string; }, index: number, array: { name: string; }[]) => value is S, thisArg?: any): S[]; (callbackfn: (value: { name: string; }, index: number, array: { name: string; }[]) => unknown, thisArg?: any): { name: string; }[]; } +>foo : { name: string; }[] +>filter : { (callbackfn: (value: { name: string; }, index: number, array: { name: string; }[]) => value is S, thisArg?: any): S[]; (callbackfn: (value: { name: string; }, index: number, array: { name: string; }[]) => unknown, thisArg?: any): { name: string; }[]; } +>x => x.name : (x: { name: string; }) => string +>x : { name: string; } +>x.name : string +>x : { name: string; } +>name : string + +var foos: Array +>foos : boolean[] + +var foos = [true, true, false, null].filter((thing): thing is boolean => thing !== null) +>foos : boolean[] +>[true, true, false, null].filter((thing): thing is boolean => thing !== null) : boolean[] +>[true, true, false, null].filter : { (callbackfn: (value: boolean, index: number, array: boolean[]) => value is S, thisArg?: any): S[]; (callbackfn: (value: boolean, index: number, array: boolean[]) => unknown, thisArg?: any): boolean[]; } +>[true, true, false, null] : boolean[] +>true : true +>true : true +>false : false +>null : null +>filter : { (callbackfn: (value: boolean, index: number, array: boolean[]) => value is S, thisArg?: any): S[]; (callbackfn: (value: boolean, index: number, array: boolean[]) => unknown, thisArg?: any): boolean[]; } +>(thing): thing is boolean => thing !== null : (thing: boolean) => thing is boolean +>thing : boolean +>thing !== null : boolean +>thing : boolean +>null : null + diff --git a/tests/baselines/reference/typeGuardBoolean.js b/tests/baselines/reference/typeGuardBoolean.js deleted file mode 100644 index 1bfe41983d8..00000000000 --- a/tests/baselines/reference/typeGuardBoolean.js +++ /dev/null @@ -1,30 +0,0 @@ -//// [typeGuardBoolean.ts] -function test(strOrNull: string | null, strOrUndefined: string | undefined) { - var str: string = "original"; - var nil: null; - if (!Boolean(strOrNull)) { - nil = strOrNull; - } - else { - str = strOrNull; - } - if (Boolean(strOrUndefined)) { - str = strOrUndefined; - } -} - - -//// [typeGuardBoolean.js] -function test(strOrNull, strOrUndefined) { - var str = "original"; - var nil; - if (!Boolean(strOrNull)) { - nil = strOrNull; - } - else { - str = strOrNull; - } - if (Boolean(strOrUndefined)) { - str = strOrUndefined; - } -} diff --git a/tests/baselines/reference/typeGuardBoolean.symbols b/tests/baselines/reference/typeGuardBoolean.symbols deleted file mode 100644 index 6a08dcbda8a..00000000000 --- a/tests/baselines/reference/typeGuardBoolean.symbols +++ /dev/null @@ -1,35 +0,0 @@ -=== tests/cases/conformance/expressions/typeGuards/typeGuardBoolean.ts === -function test(strOrNull: string | null, strOrUndefined: string | undefined) { ->test : Symbol(test, Decl(typeGuardBoolean.ts, 0, 0)) ->strOrNull : Symbol(strOrNull, Decl(typeGuardBoolean.ts, 0, 14)) ->strOrUndefined : Symbol(strOrUndefined, Decl(typeGuardBoolean.ts, 0, 39)) - - var str: string = "original"; ->str : Symbol(str, Decl(typeGuardBoolean.ts, 1, 5)) - - var nil: null; ->nil : Symbol(nil, Decl(typeGuardBoolean.ts, 2, 5)) - - if (!Boolean(strOrNull)) { ->Boolean : Symbol(Boolean, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) ->strOrNull : Symbol(strOrNull, Decl(typeGuardBoolean.ts, 0, 14)) - - nil = strOrNull; ->nil : Symbol(nil, Decl(typeGuardBoolean.ts, 2, 5)) ->strOrNull : Symbol(strOrNull, Decl(typeGuardBoolean.ts, 0, 14)) - } - else { - str = strOrNull; ->str : Symbol(str, Decl(typeGuardBoolean.ts, 1, 5)) ->strOrNull : Symbol(strOrNull, Decl(typeGuardBoolean.ts, 0, 14)) - } - if (Boolean(strOrUndefined)) { ->Boolean : Symbol(Boolean, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) ->strOrUndefined : Symbol(strOrUndefined, Decl(typeGuardBoolean.ts, 0, 39)) - - str = strOrUndefined; ->str : Symbol(str, Decl(typeGuardBoolean.ts, 1, 5)) ->strOrUndefined : Symbol(strOrUndefined, Decl(typeGuardBoolean.ts, 0, 39)) - } -} - diff --git a/tests/baselines/reference/typeGuardBoolean.types b/tests/baselines/reference/typeGuardBoolean.types deleted file mode 100644 index db3d6f39cd8..00000000000 --- a/tests/baselines/reference/typeGuardBoolean.types +++ /dev/null @@ -1,44 +0,0 @@ -=== tests/cases/conformance/expressions/typeGuards/typeGuardBoolean.ts === -function test(strOrNull: string | null, strOrUndefined: string | undefined) { ->test : (strOrNull: string | null, strOrUndefined: string | undefined) => void ->strOrNull : string | null ->null : null ->strOrUndefined : string | undefined - - var str: string = "original"; ->str : string ->"original" : "original" - - var nil: null; ->nil : null ->null : null - - if (!Boolean(strOrNull)) { ->!Boolean(strOrNull) : boolean ->Boolean(strOrNull) : boolean ->Boolean : BooleanConstructor ->strOrNull : string | null - - nil = strOrNull; ->nil = strOrNull : null ->nil : null ->strOrNull : null - } - else { - str = strOrNull; ->str = strOrNull : string ->str : string ->strOrNull : string - } - if (Boolean(strOrUndefined)) { ->Boolean(strOrUndefined) : boolean ->Boolean : BooleanConstructor ->strOrUndefined : string | undefined - - str = strOrUndefined; ->str = strOrUndefined : string ->str : string ->strOrUndefined : string - } -} - diff --git a/tests/cases/compiler/booleanFilterAnyArray.ts b/tests/cases/compiler/booleanFilterAnyArray.ts new file mode 100644 index 00000000000..db5f38e78f9 --- /dev/null +++ b/tests/cases/compiler/booleanFilterAnyArray.ts @@ -0,0 +1,24 @@ +interface Bullean { } +interface BulleanConstructor { + new(v1?: any): Bullean; + (v2?: T): v2 is T; +} + +interface Ari { + filter(cb1: (value: T) => value is S): T extends any ? Ari : Ari; + filter(cb2: (value: T) => unknown): Ari; +} +declare var Bullean: BulleanConstructor; +declare let anys: Ari; +var xs: Ari; +var xs = anys.filter(Bullean) + +declare let realanys: any[]; +var ys: any[]; +var ys = realanys.filter(Boolean) + +var foo = [{ name: 'x' }] +var foor: Array<{name: string}> +var foor = foo.filter(x => x.name) +var foos: Array +var foos = [true, true, false, null].filter((thing): thing is boolean => thing !== null) diff --git a/tests/cases/conformance/expressions/typeGuards/typeGuardBoolean.ts b/tests/cases/conformance/expressions/typeGuards/typeGuardBoolean.ts deleted file mode 100644 index 3f2dde227ba..00000000000 --- a/tests/cases/conformance/expressions/typeGuards/typeGuardBoolean.ts +++ /dev/null @@ -1,14 +0,0 @@ -// @strictNullChecks: true -function test(strOrNull: string | null, strOrUndefined: string | undefined) { - var str: string = "original"; - var nil: null; - if (!Boolean(strOrNull)) { - nil = strOrNull; - } - else { - str = strOrNull; - } - if (Boolean(strOrUndefined)) { - str = strOrUndefined; - } -} From 7611c5b9315b56c665121ae85ed5b20163399658 Mon Sep 17 00:00:00 2001 From: Ron Buckton Date: Wed, 22 May 2019 11:17:54 -0700 Subject: [PATCH 081/119] Fix for computed properties in instance initializers (#31517) --- src/compiler/emitter.ts | 2 ++ .../instanceMemberWithComputedPropertyName.js | 22 ++++++++++++++++ ...anceMemberWithComputedPropertyName.symbols | 20 +++++++++++++++ ...stanceMemberWithComputedPropertyName.types | 25 +++++++++++++++++++ .../instanceMemberWithComputedPropertyName.ts | 8 ++++++ 5 files changed, 77 insertions(+) create mode 100644 tests/baselines/reference/instanceMemberWithComputedPropertyName.js create mode 100644 tests/baselines/reference/instanceMemberWithComputedPropertyName.symbols create mode 100644 tests/baselines/reference/instanceMemberWithComputedPropertyName.types create mode 100644 tests/cases/conformance/classes/propertyMemberDeclarations/instanceMemberWithComputedPropertyName.ts diff --git a/src/compiler/emitter.ts b/src/compiler/emitter.ts index d335ceb1b60..07b1208688f 100644 --- a/src/compiler/emitter.ts +++ b/src/compiler/emitter.ts @@ -4527,6 +4527,8 @@ namespace ts { case SyntaxKind.GetAccessor: case SyntaxKind.SetAccessor: return generateNameForMethodOrAccessor(node); + case SyntaxKind.ComputedPropertyName: + return makeTempVariableName(TempFlags.Auto, /*reserveInNestedScopes*/ true); default: return makeTempVariableName(TempFlags.Auto); } diff --git a/tests/baselines/reference/instanceMemberWithComputedPropertyName.js b/tests/baselines/reference/instanceMemberWithComputedPropertyName.js new file mode 100644 index 00000000000..eba55c9899e --- /dev/null +++ b/tests/baselines/reference/instanceMemberWithComputedPropertyName.js @@ -0,0 +1,22 @@ +//// [instanceMemberWithComputedPropertyName.ts] +// https://github.com/microsoft/TypeScript/issues/30953 +const x = 1; +class C { + [x] = true; + constructor() { + const { a, b } = { a: 1, b: 2 }; + } +} + +//// [instanceMemberWithComputedPropertyName.js] +var _a; +// https://github.com/microsoft/TypeScript/issues/30953 +var x = 1; +var C = /** @class */ (function () { + function C() { + this[_a] = true; + var _b = { a: 1, b: 2 }, a = _b.a, b = _b.b; + } + return C; +}()); +_a = x; diff --git a/tests/baselines/reference/instanceMemberWithComputedPropertyName.symbols b/tests/baselines/reference/instanceMemberWithComputedPropertyName.symbols new file mode 100644 index 00000000000..3d405c89cc8 --- /dev/null +++ b/tests/baselines/reference/instanceMemberWithComputedPropertyName.symbols @@ -0,0 +1,20 @@ +=== tests/cases/conformance/classes/propertyMemberDeclarations/instanceMemberWithComputedPropertyName.ts === +// https://github.com/microsoft/TypeScript/issues/30953 +const x = 1; +>x : Symbol(x, Decl(instanceMemberWithComputedPropertyName.ts, 1, 5)) + +class C { +>C : Symbol(C, Decl(instanceMemberWithComputedPropertyName.ts, 1, 12)) + + [x] = true; +>[x] : Symbol(C[x], Decl(instanceMemberWithComputedPropertyName.ts, 2, 9)) +>x : Symbol(x, Decl(instanceMemberWithComputedPropertyName.ts, 1, 5)) + + constructor() { + const { a, b } = { a: 1, b: 2 }; +>a : Symbol(a, Decl(instanceMemberWithComputedPropertyName.ts, 5, 15)) +>b : Symbol(b, Decl(instanceMemberWithComputedPropertyName.ts, 5, 18)) +>a : Symbol(a, Decl(instanceMemberWithComputedPropertyName.ts, 5, 26)) +>b : Symbol(b, Decl(instanceMemberWithComputedPropertyName.ts, 5, 32)) + } +} diff --git a/tests/baselines/reference/instanceMemberWithComputedPropertyName.types b/tests/baselines/reference/instanceMemberWithComputedPropertyName.types new file mode 100644 index 00000000000..f98cc7bb80a --- /dev/null +++ b/tests/baselines/reference/instanceMemberWithComputedPropertyName.types @@ -0,0 +1,25 @@ +=== tests/cases/conformance/classes/propertyMemberDeclarations/instanceMemberWithComputedPropertyName.ts === +// https://github.com/microsoft/TypeScript/issues/30953 +const x = 1; +>x : 1 +>1 : 1 + +class C { +>C : C + + [x] = true; +>[x] : boolean +>x : 1 +>true : true + + constructor() { + const { a, b } = { a: 1, b: 2 }; +>a : number +>b : number +>{ a: 1, b: 2 } : { a: number; b: number; } +>a : number +>1 : 1 +>b : number +>2 : 2 + } +} diff --git a/tests/cases/conformance/classes/propertyMemberDeclarations/instanceMemberWithComputedPropertyName.ts b/tests/cases/conformance/classes/propertyMemberDeclarations/instanceMemberWithComputedPropertyName.ts new file mode 100644 index 00000000000..31aec681445 --- /dev/null +++ b/tests/cases/conformance/classes/propertyMemberDeclarations/instanceMemberWithComputedPropertyName.ts @@ -0,0 +1,8 @@ +// https://github.com/microsoft/TypeScript/issues/30953 +const x = 1; +class C { + [x] = true; + constructor() { + const { a, b } = { a: 1, b: 2 }; + } +} \ No newline at end of file From b3dc32fec7ebc2ed3bd6dc88f28be26f1479e854 Mon Sep 17 00:00:00 2001 From: Ron Buckton Date: Wed, 22 May 2019 11:18:07 -0700 Subject: [PATCH 082/119] Reset error record in downlevel for-of (#31519) --- src/compiler/transformers/es2015.ts | 42 ++++++------ tests/baselines/reference/ES5For-of37.js | 64 +++++++++++++++++++ tests/baselines/reference/ES5For-of37.symbols | 35 ++++++++++ tests/baselines/reference/ES5For-of37.types | 52 +++++++++++++++ .../for-ofStatements/ES5For-of37.ts | 16 +++++ 5 files changed, 191 insertions(+), 18 deletions(-) create mode 100644 tests/baselines/reference/ES5For-of37.js create mode 100644 tests/baselines/reference/ES5For-of37.symbols create mode 100644 tests/baselines/reference/ES5For-of37.types create mode 100644 tests/cases/conformance/statements/for-ofStatements/ES5For-of37.ts diff --git a/src/compiler/transformers/es2015.ts b/src/compiler/transformers/es2015.ts index cdeae5dbf54..9849d72f14a 100644 --- a/src/compiler/transformers/es2015.ts +++ b/src/compiler/transformers/es2015.ts @@ -145,7 +145,7 @@ namespace ts { loopOutParameters: LoopOutParameter[]; } - type LoopConverter = (node: IterationStatement, outermostLabeledStatement: LabeledStatement | undefined, convertedLoopBodyStatements: Statement[] | undefined) => Statement; + type LoopConverter = (node: IterationStatement, outermostLabeledStatement: LabeledStatement | undefined, convertedLoopBodyStatements: Statement[] | undefined, ancestorFacts: HierarchyFacts) => Statement; // Facts we track as we traverse the tree const enum HierarchyFacts { @@ -163,11 +163,12 @@ namespace ts { ExportedVariableStatement = 1 << 5, // Enclosed in an exported variable statement in the current scope TopLevel = 1 << 6, // Enclosing block-scoped container is a top-level container Block = 1 << 7, // Enclosing block-scoped container is a Block - IterationStatement = 1 << 8, // Enclosed in an IterationStatement + IterationStatement = 1 << 8, // Immediately enclosed in an IterationStatement IterationStatementBlock = 1 << 9, // Enclosing Block is enclosed in an IterationStatement - ForStatement = 1 << 10, // Enclosing block-scoped container is a ForStatement - ForInOrForOfStatement = 1 << 11, // Enclosing block-scoped container is a ForInStatement or ForOfStatement - ConstructorWithCapturedSuper = 1 << 12, // Enclosed in a constructor that captures 'this' for use with 'super' + IterationContainer = 1 << 10, // Enclosed in an outer IterationStatement + ForStatement = 1 << 11, // Enclosing block-scoped container is a ForStatement + ForInOrForOfStatement = 1 << 12, // Enclosing block-scoped container is a ForInStatement or ForOfStatement + ConstructorWithCapturedSuper = 1 << 13, // Enclosed in a constructor that captures 'this' for use with 'super' // NOTE: do not add more ancestor flags without also updating AncestorFactsMask below. // NOTE: when adding a new ancestor flag, be sure to update the subtree flags below. @@ -184,11 +185,11 @@ namespace ts { // A source file is a top-level block scope. SourceFileIncludes = TopLevel, - SourceFileExcludes = BlockScopeExcludes & ~TopLevel, + SourceFileExcludes = BlockScopeExcludes & ~TopLevel | IterationContainer, // Functions, methods, and accessors are both new lexical scopes and new block scopes. FunctionIncludes = Function | TopLevel, - FunctionExcludes = BlockScopeExcludes & ~TopLevel | ArrowFunction | AsyncFunctionBody | CapturesThis | NonStaticClassElement | ConstructorWithCapturedSuper, + FunctionExcludes = BlockScopeExcludes & ~TopLevel | ArrowFunction | AsyncFunctionBody | CapturesThis | NonStaticClassElement | ConstructorWithCapturedSuper | IterationContainer, AsyncFunctionBodyIncludes = FunctionIncludes | AsyncFunctionBody, AsyncFunctionBodyExcludes = FunctionExcludes & ~NonStaticClassElement, @@ -205,16 +206,16 @@ namespace ts { // 'do' and 'while' statements are not block scopes. We track that the subtree is contained // within an IterationStatement to indicate whether the embedded statement is an // IterationStatementBlock. - DoOrWhileStatementIncludes = IterationStatement, + DoOrWhileStatementIncludes = IterationStatement | IterationContainer, DoOrWhileStatementExcludes = None, // 'for' statements are new block scopes and have special handling for 'let' declarations. - ForStatementIncludes = IterationStatement | ForStatement, + ForStatementIncludes = IterationStatement | ForStatement | IterationContainer, ForStatementExcludes = BlockScopeExcludes & ~ForStatement, // 'for-in' and 'for-of' statements are new block scopes and have special handling for // 'let' declarations. - ForInOrForOfStatementIncludes = IterationStatement | ForInOrForOfStatement, + ForInOrForOfStatementIncludes = IterationStatement | ForInOrForOfStatement | IterationContainer, ForInOrForOfStatementExcludes = BlockScopeExcludes & ~ForInOrForOfStatement, // Blocks (other than function bodies) are new block scopes. @@ -228,8 +229,8 @@ namespace ts { // Subtree facts // - NewTarget = 1 << 13, // Contains a 'new.target' meta-property - CapturedLexicalThis = 1 << 14, // Contains a lexical `this` reference captured by an arrow function. + NewTarget = 1 << 14, // Contains a 'new.target' meta-property + CapturedLexicalThis = 1 << 15, // Contains a lexical `this` reference captured by an arrow function. // // Subtree masks @@ -2227,7 +2228,7 @@ namespace ts { function visitIterationStatementWithFacts(excludeFacts: HierarchyFacts, includeFacts: HierarchyFacts, node: IterationStatement, outermostLabeledStatement: LabeledStatement | undefined, convert?: LoopConverter) { const ancestorFacts = enterSubtree(excludeFacts, includeFacts); - const updated = convertIterationStatementBodyIfNecessary(node, outermostLabeledStatement, convert); + const updated = convertIterationStatementBodyIfNecessary(node, outermostLabeledStatement, ancestorFacts, convert); exitSubtree(ancestorFacts, HierarchyFacts.None, HierarchyFacts.None); return updated; } @@ -2434,7 +2435,7 @@ namespace ts { return restoreEnclosingLabel(forStatement, outermostLabeledStatement, convertedLoopState && resetLabel); } - function convertForOfStatementForIterable(node: ForOfStatement, outermostLabeledStatement: LabeledStatement, convertedLoopBodyStatements: Statement[]): Statement { + function convertForOfStatementForIterable(node: ForOfStatement, outermostLabeledStatement: LabeledStatement, convertedLoopBodyStatements: Statement[], ancestorFacts: HierarchyFacts): Statement { const expression = visitNode(node.expression, visitor, isExpression); const iterator = isIdentifier(expression) ? getGeneratedNameForNode(expression) : createTempVariable(/*recordTempVariable*/ undefined); const result = isIdentifier(expression) ? getGeneratedNameForNode(iterator) : createTempVariable(/*recordTempVariable*/ undefined); @@ -2447,13 +2448,18 @@ namespace ts { hoistVariableDeclaration(errorRecord); hoistVariableDeclaration(returnMethod); + // if we are enclosed in an outer loop ensure we reset 'errorRecord' per each iteration + const initializer = ancestorFacts & HierarchyFacts.IterationContainer + ? inlineExpressions([createAssignment(errorRecord, createVoidZero()), values]) + : values; + const forStatement = setEmitFlags( setTextRange( createFor( /*initializer*/ setEmitFlags( setTextRange( createVariableDeclarationList([ - setTextRange(createVariableDeclaration(iterator, /*type*/ undefined, values), node.expression), + setTextRange(createVariableDeclaration(iterator, /*type*/ undefined, initializer), node.expression), createVariableDeclaration(result, /*type*/ undefined, next) ]), node.expression @@ -2665,7 +2671,7 @@ namespace ts { } } - function convertIterationStatementBodyIfNecessary(node: IterationStatement, outermostLabeledStatement: LabeledStatement | undefined, convert?: LoopConverter): VisitResult { + function convertIterationStatementBodyIfNecessary(node: IterationStatement, outermostLabeledStatement: LabeledStatement | undefined, ancestorFacts: HierarchyFacts, convert?: LoopConverter): VisitResult { if (!shouldConvertIterationStatement(node)) { let saveAllowedNonLabeledJumps: Jump | undefined; if (convertedLoopState) { @@ -2676,7 +2682,7 @@ namespace ts { } const result = convert - ? convert(node, outermostLabeledStatement, /*convertedLoopBodyStatements*/ undefined) + ? convert(node, outermostLabeledStatement, /*convertedLoopBodyStatements*/ undefined, ancestorFacts) : restoreEnclosingLabel(visitEachChild(node, visitor, context), outermostLabeledStatement, convertedLoopState && resetLabel); if (convertedLoopState) { @@ -2708,7 +2714,7 @@ namespace ts { let loop: Statement; if (bodyFunction) { if (convert) { - loop = convert(node, outermostLabeledStatement, bodyFunction.part); + loop = convert(node, outermostLabeledStatement, bodyFunction.part, ancestorFacts); } else { const clone = convertIterationStatementCore(node, initializerFunction, createBlock(bodyFunction.part, /*multiLine*/ true)); diff --git a/tests/baselines/reference/ES5For-of37.js b/tests/baselines/reference/ES5For-of37.js new file mode 100644 index 00000000000..c9ea0236187 --- /dev/null +++ b/tests/baselines/reference/ES5For-of37.js @@ -0,0 +1,64 @@ +//// [ES5For-of37.ts] +// https://github.com/microsoft/TypeScript/issues/30083 + +for (const i of [0, 1, 2, 3, 4]) { + try { + // Ensure catch binding for the following loop is reset per iteration: + for (const j of [1, 2, 3]) { + if (i === 2) { + throw new Error('ERR'); + } + } + console.log(i); + } catch (err) { + console.log('E %s %s', i, err); + } +} + +//// [ES5For-of37.js] +// https://github.com/microsoft/TypeScript/issues/30083 +var __values = (this && this.__values) || function (o) { + var m = typeof Symbol === "function" && o[Symbol.iterator], i = 0; + if (m) return m.call(o); + return { + next: function () { + if (o && i >= o.length) o = void 0; + return { value: o && o[i++], done: !o }; + } + }; +}; +var e_1, _a, e_2, _b; +try { + for (var _c = __values([0, 1, 2, 3, 4]), _d = _c.next(); !_d.done; _d = _c.next()) { + var i = _d.value; + try { + try { + // Ensure catch binding for the following loop is reset per iteration: + for (var _e = (e_2 = void 0, __values([1, 2, 3])), _f = _e.next(); !_f.done; _f = _e.next()) { + var j = _f.value; + if (i === 2) { + throw new Error('ERR'); + } + } + } + catch (e_2_1) { e_2 = { error: e_2_1 }; } + finally { + try { + if (_f && !_f.done && (_b = _e["return"])) _b.call(_e); + } + finally { if (e_2) throw e_2.error; } + } + console.log(i); + } + catch (err) { + console.log('E %s %s', i, err); + } + } +} +catch (e_1_1) { e_1 = { error: e_1_1 }; } +finally { + try { + if (_d && !_d.done && (_a = _c["return"])) _a.call(_c); + } + finally { if (e_1) throw e_1.error; } +} diff --git a/tests/baselines/reference/ES5For-of37.symbols b/tests/baselines/reference/ES5For-of37.symbols new file mode 100644 index 00000000000..5c36b441706 --- /dev/null +++ b/tests/baselines/reference/ES5For-of37.symbols @@ -0,0 +1,35 @@ +=== tests/cases/conformance/statements/for-ofStatements/ES5For-of37.ts === +// https://github.com/microsoft/TypeScript/issues/30083 + +for (const i of [0, 1, 2, 3, 4]) { +>i : Symbol(i, Decl(ES5For-of37.ts, 2, 10)) + + try { + // Ensure catch binding for the following loop is reset per iteration: + for (const j of [1, 2, 3]) { +>j : Symbol(j, Decl(ES5For-of37.ts, 5, 18)) + + if (i === 2) { +>i : Symbol(i, Decl(ES5For-of37.ts, 2, 10)) + + throw new Error('ERR'); +>Error : Symbol(Error, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) + } + } + console.log(i); +>console.log : Symbol(Console.log, Decl(lib.dom.d.ts, --, --)) +>console : Symbol(console, Decl(lib.dom.d.ts, --, --)) +>log : Symbol(Console.log, Decl(lib.dom.d.ts, --, --)) +>i : Symbol(i, Decl(ES5For-of37.ts, 2, 10)) + + } catch (err) { +>err : Symbol(err, Decl(ES5For-of37.ts, 11, 13)) + + console.log('E %s %s', i, err); +>console.log : Symbol(Console.log, Decl(lib.dom.d.ts, --, --)) +>console : Symbol(console, Decl(lib.dom.d.ts, --, --)) +>log : Symbol(Console.log, Decl(lib.dom.d.ts, --, --)) +>i : Symbol(i, Decl(ES5For-of37.ts, 2, 10)) +>err : Symbol(err, Decl(ES5For-of37.ts, 11, 13)) + } +} diff --git a/tests/baselines/reference/ES5For-of37.types b/tests/baselines/reference/ES5For-of37.types new file mode 100644 index 00000000000..2488857382e --- /dev/null +++ b/tests/baselines/reference/ES5For-of37.types @@ -0,0 +1,52 @@ +=== tests/cases/conformance/statements/for-ofStatements/ES5For-of37.ts === +// https://github.com/microsoft/TypeScript/issues/30083 + +for (const i of [0, 1, 2, 3, 4]) { +>i : number +>[0, 1, 2, 3, 4] : number[] +>0 : 0 +>1 : 1 +>2 : 2 +>3 : 3 +>4 : 4 + + try { + // Ensure catch binding for the following loop is reset per iteration: + for (const j of [1, 2, 3]) { +>j : number +>[1, 2, 3] : number[] +>1 : 1 +>2 : 2 +>3 : 3 + + if (i === 2) { +>i === 2 : boolean +>i : number +>2 : 2 + + throw new Error('ERR'); +>new Error('ERR') : Error +>Error : ErrorConstructor +>'ERR' : "ERR" + } + } + console.log(i); +>console.log(i) : void +>console.log : (message?: any, ...optionalParams: any[]) => void +>console : Console +>log : (message?: any, ...optionalParams: any[]) => void +>i : number + + } catch (err) { +>err : any + + console.log('E %s %s', i, err); +>console.log('E %s %s', i, err) : void +>console.log : (message?: any, ...optionalParams: any[]) => void +>console : Console +>log : (message?: any, ...optionalParams: any[]) => void +>'E %s %s' : "E %s %s" +>i : number +>err : any + } +} diff --git a/tests/cases/conformance/statements/for-ofStatements/ES5For-of37.ts b/tests/cases/conformance/statements/for-ofStatements/ES5For-of37.ts new file mode 100644 index 00000000000..6ac37924016 --- /dev/null +++ b/tests/cases/conformance/statements/for-ofStatements/ES5For-of37.ts @@ -0,0 +1,16 @@ +// @downlevelIteration: true +// https://github.com/microsoft/TypeScript/issues/30083 + +for (const i of [0, 1, 2, 3, 4]) { + try { + // Ensure catch binding for the following loop is reset per iteration: + for (const j of [1, 2, 3]) { + if (i === 2) { + throw new Error('ERR'); + } + } + console.log(i); + } catch (err) { + console.log('E %s %s', i, err); + } +} \ No newline at end of file From c3055e585d014a65319a548b52a0b01c0cfbbe83 Mon Sep 17 00:00:00 2001 From: Ron Buckton Date: Wed, 22 May 2019 11:20:07 -0700 Subject: [PATCH 083/119] Fix compiler crash with object rest in catch binding (#31522) --- src/compiler/checker.ts | 7 +++++- src/compiler/transformers/es2018.ts | 24 +++++++++++++++++++ .../baselines/reference/objectRestCatchES5.js | 21 ++++++++++++++++ .../reference/objectRestCatchES5.symbols | 9 +++++++ .../reference/objectRestCatchES5.types | 11 +++++++++ .../types/rest/objectRestCatchES5.ts | 2 ++ 6 files changed, 73 insertions(+), 1 deletion(-) create mode 100644 tests/baselines/reference/objectRestCatchES5.js create mode 100644 tests/baselines/reference/objectRestCatchES5.symbols create mode 100644 tests/baselines/reference/objectRestCatchES5.types create mode 100644 tests/cases/conformance/types/rest/objectRestCatchES5.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 9e5c864f6b9..fe17a6fbfed 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -30169,12 +30169,17 @@ namespace ts { return undefined; } + function isSymbolOfDestructuredElementOfCatchBinding(symbol: Symbol) { + return isBindingElement(symbol.valueDeclaration) + && walkUpBindingElementsAndPatterns(symbol.valueDeclaration).parent.kind === SyntaxKind.CatchClause; + } + function isSymbolOfDeclarationWithCollidingName(symbol: Symbol): boolean { if (symbol.flags & SymbolFlags.BlockScoped && !isSourceFile(symbol.valueDeclaration)) { const links = getSymbolLinks(symbol); if (links.isDeclarationWithCollidingName === undefined) { const container = getEnclosingBlockScopeContainer(symbol.valueDeclaration); - if (isStatementWithLocals(container)) { + if (isStatementWithLocals(container) || isSymbolOfDestructuredElementOfCatchBinding(symbol)) { const nodeLinks = getNodeLinks(symbol.valueDeclaration); if (resolveName(container.parent, symbol.escapedName, SymbolFlags.Value, /*nameNotFoundMessage*/ undefined, /*nameArg*/ undefined, /*isUse*/ false)) { // redeclaration - always should be renamed diff --git a/src/compiler/transformers/es2018.ts b/src/compiler/transformers/es2018.ts index 504870b4ff7..89c43dcf599 100644 --- a/src/compiler/transformers/es2018.ts +++ b/src/compiler/transformers/es2018.ts @@ -77,6 +77,8 @@ namespace ts { return visitObjectLiteralExpression(node as ObjectLiteralExpression); case SyntaxKind.BinaryExpression: return visitBinaryExpression(node as BinaryExpression, noDestructuringValue); + case SyntaxKind.CatchClause: + return visitCatchClause(node as CatchClause); case SyntaxKind.VariableDeclaration: return visitVariableDeclaration(node as VariableDeclaration); case SyntaxKind.ForOfStatement: @@ -272,6 +274,28 @@ namespace ts { return visitEachChild(node, visitor, context); } + function visitCatchClause(node: CatchClause) { + if (node.variableDeclaration && + isBindingPattern(node.variableDeclaration.name) && + node.variableDeclaration.name.transformFlags & TransformFlags.ContainsObjectRestOrSpread) { + const name = getGeneratedNameForNode(node.variableDeclaration.name); + const updatedDecl = updateVariableDeclaration(node.variableDeclaration, node.variableDeclaration.name, /*type*/ undefined, name); + const visitedBindings = flattenDestructuringBinding(updatedDecl, visitor, context, FlattenLevel.ObjectRest); + let block = visitNode(node.block, visitor, isBlock); + if (some(visitedBindings)) { + block = updateBlock(block, [ + createVariableStatement(/*modifiers*/ undefined, visitedBindings), + ...block.statements, + ]); + } + return updateCatchClause( + node, + updateVariableDeclaration(node.variableDeclaration, name, /*type*/ undefined, /*initializer*/ undefined), + block); + } + return visitEachChild(node, visitor, context); + } + /** * Visits a VariableDeclaration node with a binding pattern. * diff --git a/tests/baselines/reference/objectRestCatchES5.js b/tests/baselines/reference/objectRestCatchES5.js new file mode 100644 index 00000000000..210e8cec3bf --- /dev/null +++ b/tests/baselines/reference/objectRestCatchES5.js @@ -0,0 +1,21 @@ +//// [objectRestCatchES5.ts] +let a = 1, b = 2; +try {} catch ({ a, ...b }) {} + +//// [objectRestCatchES5.js] +var __rest = (this && this.__rest) || function (s, e) { + var t = {}; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) + t[p] = s[p]; + if (s != null && typeof Object.getOwnPropertySymbols === "function") + for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { + if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) + t[p[i]] = s[p[i]]; + } + return t; +}; +var a = 1, b = 2; +try { } +catch (_a) { + var a_1 = _a.a, b_1 = __rest(_a, ["a"]); +} diff --git a/tests/baselines/reference/objectRestCatchES5.symbols b/tests/baselines/reference/objectRestCatchES5.symbols new file mode 100644 index 00000000000..007424bd6c3 --- /dev/null +++ b/tests/baselines/reference/objectRestCatchES5.symbols @@ -0,0 +1,9 @@ +=== tests/cases/conformance/types/rest/objectRestCatchES5.ts === +let a = 1, b = 2; +>a : Symbol(a, Decl(objectRestCatchES5.ts, 0, 3)) +>b : Symbol(b, Decl(objectRestCatchES5.ts, 0, 10)) + +try {} catch ({ a, ...b }) {} +>a : Symbol(a, Decl(objectRestCatchES5.ts, 1, 15)) +>b : Symbol(b, Decl(objectRestCatchES5.ts, 1, 18)) + diff --git a/tests/baselines/reference/objectRestCatchES5.types b/tests/baselines/reference/objectRestCatchES5.types new file mode 100644 index 00000000000..3d6b0a3e695 --- /dev/null +++ b/tests/baselines/reference/objectRestCatchES5.types @@ -0,0 +1,11 @@ +=== tests/cases/conformance/types/rest/objectRestCatchES5.ts === +let a = 1, b = 2; +>a : number +>1 : 1 +>b : number +>2 : 2 + +try {} catch ({ a, ...b }) {} +>a : any +>b : any + diff --git a/tests/cases/conformance/types/rest/objectRestCatchES5.ts b/tests/cases/conformance/types/rest/objectRestCatchES5.ts new file mode 100644 index 00000000000..0e568d32b58 --- /dev/null +++ b/tests/cases/conformance/types/rest/objectRestCatchES5.ts @@ -0,0 +1,2 @@ +let a = 1, b = 2; +try {} catch ({ a, ...b }) {} \ No newline at end of file From 3d2af9ff332fca6c5db2390be0b1f08bba8402a1 Mon Sep 17 00:00:00 2001 From: Ron Buckton Date: Wed, 22 May 2019 11:20:29 -0700 Subject: [PATCH 084/119] Relocate Debug namespace to reduce duplication (#31524) --- src/compiler/binder.ts | 2 +- src/compiler/checker.ts | 4 +- src/compiler/core.ts | 83 ------ src/compiler/debug.ts | 261 ++++++++++++++++++ src/compiler/tsconfig.json | 1 + src/compiler/utilities.ts | 97 +------ src/compiler/visitor.ts | 96 ------- .../codefixes/addNameToNamelessParameter.ts | 4 +- src/services/findAllReferences.ts | 2 +- src/services/importTracker.ts | 4 +- src/services/services.ts | 2 +- src/services/signatureHelp.ts | 2 +- src/testRunner/unittests/factory.ts | 2 +- 13 files changed, 274 insertions(+), 286 deletions(-) create mode 100644 src/compiler/debug.ts diff --git a/src/compiler/binder.ts b/src/compiler/binder.ts index cb6f67d66b1..4540a4409d6 100644 --- a/src/compiler/binder.ts +++ b/src/compiler/binder.ts @@ -2515,7 +2515,7 @@ namespace ts { break; default: - Debug.fail(Debug.showSyntaxKind(thisContainer)); + Debug.failBadSyntaxKind(thisContainer); } } diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index fe17a6fbfed..129a79a7c11 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -5695,7 +5695,7 @@ namespace ts { type = getTypeOfEnumMember(symbol); } else { - return Debug.fail("Unhandled declaration kind! " + Debug.showSyntaxKind(declaration) + " for " + Debug.showSymbol(symbol)); + return Debug.fail("Unhandled declaration kind! " + Debug.formatSyntaxKind(declaration.kind) + " for " + Debug.formatSymbol(symbol)); } if (!popTypeResolution()) { @@ -25536,7 +25536,7 @@ namespace ts { case SyntaxKind.ImportSpecifier: // https://github.com/Microsoft/TypeScript/pull/7591 return DeclarationSpaces.ExportValue; default: - return Debug.fail(Debug.showSyntaxKind(d)); + return Debug.failBadSyntaxKind(d); } } } diff --git a/src/compiler/core.ts b/src/compiler/core.ts index 2dfc7acf188..0034c275999 100644 --- a/src/compiler/core.ts +++ b/src/compiler/core.ts @@ -1686,89 +1686,6 @@ namespace ts { export type AnyFunction = (...args: never[]) => void; export type AnyConstructor = new (...args: unknown[]) => unknown; - export namespace Debug { - export let currentAssertionLevel = AssertionLevel.None; - export let isDebugging = false; - - export function shouldAssert(level: AssertionLevel): boolean { - return currentAssertionLevel >= level; - } - - export function assert(expression: boolean, message?: string, verboseDebugInfo?: string | (() => string), stackCrawlMark?: AnyFunction): void { - if (!expression) { - if (verboseDebugInfo) { - message += "\r\nVerbose Debug Information: " + (typeof verboseDebugInfo === "string" ? verboseDebugInfo : verboseDebugInfo()); - } - fail(message ? "False expression: " + message : "False expression.", stackCrawlMark || assert); - } - } - - export function assertEqual(a: T, b: T, msg?: string, msg2?: string): void { - if (a !== b) { - const message = msg ? msg2 ? `${msg} ${msg2}` : msg : ""; - fail(`Expected ${a} === ${b}. ${message}`); - } - } - - export function assertLessThan(a: number, b: number, msg?: string): void { - if (a >= b) { - fail(`Expected ${a} < ${b}. ${msg || ""}`); - } - } - - export function assertLessThanOrEqual(a: number, b: number): void { - if (a > b) { - fail(`Expected ${a} <= ${b}`); - } - } - - export function assertGreaterThanOrEqual(a: number, b: number): void { - if (a < b) { - fail(`Expected ${a} >= ${b}`); - } - } - - export function fail(message?: string, stackCrawlMark?: AnyFunction): never { - debugger; - const e = new Error(message ? `Debug Failure. ${message}` : "Debug Failure."); - if ((Error).captureStackTrace) { - (Error).captureStackTrace(e, stackCrawlMark || fail); - } - throw e; - } - - export function assertDefined(value: T | null | undefined, message?: string): T { - if (value === undefined || value === null) return fail(message); - return value; - } - - export function assertEachDefined>(value: A, message?: string): A { - for (const v of value) { - assertDefined(v, message); - } - return value; - } - - export function assertNever(member: never, message = "Illegal value:", stackCrawlMark?: AnyFunction): never { - const detail = typeof member === "object" && "kind" in member && "pos" in member ? "SyntaxKind: " + showSyntaxKind(member as Node) : JSON.stringify(member); - return fail(`${message} ${detail}`, stackCrawlMark || assertNever); - } - - export function getFunctionName(func: AnyFunction) { - if (typeof func !== "function") { - return ""; - } - else if (func.hasOwnProperty("name")) { - return (func).name; - } - else { - const text = Function.prototype.toString.call(func); - const match = /^function\s+([\w\$]+)\s*\(/.exec(text); - return match ? match[1] : ""; - } - } - } - export function equateValues(a: T, b: T) { return a === b; } diff --git a/src/compiler/debug.ts b/src/compiler/debug.ts new file mode 100644 index 00000000000..ee6847133c1 --- /dev/null +++ b/src/compiler/debug.ts @@ -0,0 +1,261 @@ +/* @internal */ +namespace ts { + export namespace Debug { + export let currentAssertionLevel = AssertionLevel.None; + export let isDebugging = false; + + export function shouldAssert(level: AssertionLevel): boolean { + return currentAssertionLevel >= level; + } + + export function assert(expression: boolean, message?: string, verboseDebugInfo?: string | (() => string), stackCrawlMark?: AnyFunction): void { + if (!expression) { + if (verboseDebugInfo) { + message += "\r\nVerbose Debug Information: " + (typeof verboseDebugInfo === "string" ? verboseDebugInfo : verboseDebugInfo()); + } + fail(message ? "False expression: " + message : "False expression.", stackCrawlMark || assert); + } + } + + export function assertEqual(a: T, b: T, msg?: string, msg2?: string): void { + if (a !== b) { + const message = msg ? msg2 ? `${msg} ${msg2}` : msg : ""; + fail(`Expected ${a} === ${b}. ${message}`); + } + } + + export function assertLessThan(a: number, b: number, msg?: string): void { + if (a >= b) { + fail(`Expected ${a} < ${b}. ${msg || ""}`); + } + } + + export function assertLessThanOrEqual(a: number, b: number): void { + if (a > b) { + fail(`Expected ${a} <= ${b}`); + } + } + + export function assertGreaterThanOrEqual(a: number, b: number): void { + if (a < b) { + fail(`Expected ${a} >= ${b}`); + } + } + + export function fail(message?: string, stackCrawlMark?: AnyFunction): never { + debugger; + const e = new Error(message ? `Debug Failure. ${message}` : "Debug Failure."); + if ((Error).captureStackTrace) { + (Error).captureStackTrace(e, stackCrawlMark || fail); + } + throw e; + } + + export function assertDefined(value: T | null | undefined, message?: string): T { + if (value === undefined || value === null) return fail(message); + return value; + } + + export function assertEachDefined>(value: A, message?: string): A { + for (const v of value) { + assertDefined(v, message); + } + return value; + } + + export function assertNever(member: never, message = "Illegal value:", stackCrawlMark?: AnyFunction): never { + const detail = typeof member === "object" && "kind" in member && "pos" in member && formatSyntaxKind ? "SyntaxKind: " + formatSyntaxKind((member as Node).kind) : JSON.stringify(member); + return fail(`${message} ${detail}`, stackCrawlMark || assertNever); + } + + export function getFunctionName(func: AnyFunction) { + if (typeof func !== "function") { + return ""; + } + else if (func.hasOwnProperty("name")) { + return (func).name; + } + else { + const text = Function.prototype.toString.call(func); + const match = /^function\s+([\w\$]+)\s*\(/.exec(text); + return match ? match[1] : ""; + } + } + + export function formatSymbol(symbol: Symbol): string { + return `{ name: ${unescapeLeadingUnderscores(symbol.escapedName)}; flags: ${formatSymbolFlags(symbol.flags)}; declarations: ${map(symbol.declarations, node => formatSyntaxKind(node.kind))} }`; + } + + /** + * Formats an enum value as a string for debugging and debug assertions. + */ + export function formatEnum(value = 0, enumObject: any, isFlags?: boolean) { + const members = getEnumMembers(enumObject); + if (value === 0) { + return members.length > 0 && members[0][0] === 0 ? members[0][1] : "0"; + } + if (isFlags) { + let result = ""; + let remainingFlags = value; + for (let i = members.length - 1; i >= 0 && remainingFlags !== 0; i--) { + const [enumValue, enumName] = members[i]; + if (enumValue !== 0 && (remainingFlags & enumValue) === enumValue) { + remainingFlags &= ~enumValue; + result = `${enumName}${result ? "|" : ""}${result}`; + } + } + if (remainingFlags === 0) { + return result; + } + } + else { + for (const [enumValue, enumName] of members) { + if (enumValue === value) { + return enumName; + } + } + } + return value.toString(); + } + + function getEnumMembers(enumObject: any) { + const result: [number, string][] = []; + for (const name in enumObject) { + const value = enumObject[name]; + if (typeof value === "number") { + result.push([value, name]); + } + } + + return stableSort<[number, string]>(result, (x, y) => compareValues(x[0], y[0])); + } + + export function formatSyntaxKind(kind: SyntaxKind | undefined): string { + return formatEnum(kind, (ts).SyntaxKind, /*isFlags*/ false); + } + + export function formatNodeFlags(flags: NodeFlags | undefined): string { + return formatEnum(flags, (ts).NodeFlags, /*isFlags*/ true); + } + + export function formatModifierFlags(flags: ModifierFlags | undefined): string { + return formatEnum(flags, (ts).ModifierFlags, /*isFlags*/ true); + } + + export function formatTransformFlags(flags: TransformFlags | undefined): string { + return formatEnum(flags, (ts).TransformFlags, /*isFlags*/ true); + } + + export function formatEmitFlags(flags: EmitFlags | undefined): string { + return formatEnum(flags, (ts).EmitFlags, /*isFlags*/ true); + } + + export function formatSymbolFlags(flags: SymbolFlags | undefined): string { + return formatEnum(flags, (ts).SymbolFlags, /*isFlags*/ true); + } + + export function formatTypeFlags(flags: TypeFlags | undefined): string { + return formatEnum(flags, (ts).TypeFlags, /*isFlags*/ true); + } + + export function formatObjectFlags(flags: ObjectFlags | undefined): string { + return formatEnum(flags, (ts).ObjectFlags, /*isFlags*/ true); + } + + export function failBadSyntaxKind(node: Node, message?: string): never { + return fail( + `${message || "Unexpected node."}\r\nNode ${formatSyntaxKind(node.kind)} was unexpected.`, + failBadSyntaxKind); + } + + export const assertEachNode = shouldAssert(AssertionLevel.Normal) + ? (nodes: Node[], test: (node: Node) => boolean, message?: string): void => assert( + test === undefined || every(nodes, test), + message || "Unexpected node.", + () => `Node array did not pass test '${getFunctionName(test)}'.`, + assertEachNode) + : noop; + + export const assertNode = shouldAssert(AssertionLevel.Normal) + ? (node: Node | undefined, test: ((node: Node | undefined) => boolean) | undefined, message?: string): void => assert( + test === undefined || test(node), + message || "Unexpected node.", + () => `Node ${formatSyntaxKind(node!.kind)} did not pass test '${getFunctionName(test!)}'.`, + assertNode) + : noop; + + export const assertOptionalNode = shouldAssert(AssertionLevel.Normal) + ? (node: Node, test: (node: Node) => boolean, message?: string): void => assert( + test === undefined || node === undefined || test(node), + message || "Unexpected node.", + () => `Node ${formatSyntaxKind(node.kind)} did not pass test '${getFunctionName(test)}'.`, + assertOptionalNode) + : noop; + + export const assertOptionalToken = shouldAssert(AssertionLevel.Normal) + ? (node: Node, kind: SyntaxKind, message?: string): void => assert( + kind === undefined || node === undefined || node.kind === kind, + message || "Unexpected node.", + () => `Node ${formatSyntaxKind(node.kind)} was not a '${formatSyntaxKind(kind)}' token.`, + assertOptionalToken) + : noop; + + export const assertMissingNode = shouldAssert(AssertionLevel.Normal) + ? (node: Node, message?: string): void => assert( + node === undefined, + message || "Unexpected node.", + () => `Node ${formatSyntaxKind(node.kind)} was unexpected'.`, + assertMissingNode) + : noop; + + let isDebugInfoEnabled = false; + + /** + * Injects debug information into frequently used types. + */ + export function enableDebugInfo() { + if (isDebugInfoEnabled) return; + + // Add additional properties in debug mode to assist with debugging. + Object.defineProperties(objectAllocator.getSymbolConstructor().prototype, { + __debugFlags: { get(this: Symbol) { return formatSymbolFlags(this.flags); } } + }); + + Object.defineProperties(objectAllocator.getTypeConstructor().prototype, { + __debugFlags: { get(this: Type) { return formatTypeFlags(this.flags); } }, + __debugObjectFlags: { get(this: Type) { return this.flags & TypeFlags.Object ? formatObjectFlags((this).objectFlags) : ""; } }, + __debugTypeToString: { value(this: Type) { return this.checker.typeToString(this); } }, + }); + + const nodeConstructors = [ + objectAllocator.getNodeConstructor(), + objectAllocator.getIdentifierConstructor(), + objectAllocator.getTokenConstructor(), + objectAllocator.getSourceFileConstructor() + ]; + + for (const ctor of nodeConstructors) { + if (!ctor.prototype.hasOwnProperty("__debugKind")) { + Object.defineProperties(ctor.prototype, { + __debugKind: { get(this: Node) { return formatSyntaxKind(this.kind); } }, + __debugNodeFlags: { get(this: Node) { return formatNodeFlags(this.flags); } }, + __debugModifierFlags: { get(this: Node) { return formatModifierFlags(getModifierFlagsNoCache(this)); } }, + __debugTransformFlags: { get(this: Node) { return formatTransformFlags(this.transformFlags); } }, + __debugIsParseTreeNode: { get(this: Node) { return isParseTreeNode(this); } }, + __debugEmitFlags: { get(this: Node) { return formatEmitFlags(getEmitFlags(this)); } }, + __debugGetText: { + value(this: Node, includeTrivia?: boolean) { + if (nodeIsSynthesized(this)) return ""; + const parseNode = getParseTreeNode(this); + const sourceFile = parseNode && getSourceFileOfNode(parseNode); + return sourceFile ? getSourceTextOfNodeFromSourceFile(sourceFile, parseNode, includeTrivia) : ""; + } + } + }); + } + } + + isDebugInfoEnabled = true; + } + } +} \ No newline at end of file diff --git a/src/compiler/tsconfig.json b/src/compiler/tsconfig.json index 18934aa9bb1..fdc0ff2969f 100644 --- a/src/compiler/tsconfig.json +++ b/src/compiler/tsconfig.json @@ -8,6 +8,7 @@ "files": [ "core.ts", + "debug.ts", "performance.ts", "semver.ts", diff --git a/src/compiler/utilities.ts b/src/compiler/utilities.ts index ac3be6d434b..0ec81502cf7 100644 --- a/src/compiler/utilities.ts +++ b/src/compiler/utilities.ts @@ -2073,7 +2073,7 @@ namespace ts { } export function importFromModuleSpecifier(node: StringLiteralLike): AnyValidImportOrReExport { - return tryGetImportFromModuleSpecifier(node) || Debug.fail(Debug.showSyntaxKind(node.parent)); + return tryGetImportFromModuleSpecifier(node) || Debug.failBadSyntaxKind(node.parent); } export function tryGetImportFromModuleSpecifier(node: StringLiteralLike): AnyValidImportOrReExport | undefined { @@ -4186,78 +4186,6 @@ namespace ts { return getNewLine ? getNewLine() : sys ? sys.newLine : carriageReturnLineFeed; } - /** - * Formats an enum value as a string for debugging and debug assertions. - */ - function formatEnum(value = 0, enumObject: any, isFlags?: boolean) { - const members = getEnumMembers(enumObject); - if (value === 0) { - return members.length > 0 && members[0][0] === 0 ? members[0][1] : "0"; - } - if (isFlags) { - let result = ""; - let remainingFlags = value; - for (let i = members.length - 1; i >= 0 && remainingFlags !== 0; i--) { - const [enumValue, enumName] = members[i]; - if (enumValue !== 0 && (remainingFlags & enumValue) === enumValue) { - remainingFlags &= ~enumValue; - result = `${enumName}${result ? ", " : ""}${result}`; - } - } - if (remainingFlags === 0) { - return result; - } - } - else { - for (const [enumValue, enumName] of members) { - if (enumValue === value) { - return enumName; - } - } - } - return value.toString(); - } - - function getEnumMembers(enumObject: any) { - const result: [number, string][] = []; - for (const name in enumObject) { - const value = enumObject[name]; - if (typeof value === "number") { - result.push([value, name]); - } - } - - return stableSort<[number, string]>(result, (x, y) => compareValues(x[0], y[0])); - } - - export function formatSyntaxKind(kind: SyntaxKind | undefined): string { - return formatEnum(kind, (ts).SyntaxKind, /*isFlags*/ false); - } - - export function formatModifierFlags(flags: ModifierFlags | undefined): string { - return formatEnum(flags, (ts).ModifierFlags, /*isFlags*/ true); - } - - export function formatTransformFlags(flags: TransformFlags | undefined): string { - return formatEnum(flags, (ts).TransformFlags, /*isFlags*/ true); - } - - export function formatEmitFlags(flags: EmitFlags | undefined): string { - return formatEnum(flags, (ts).EmitFlags, /*isFlags*/ true); - } - - export function formatSymbolFlags(flags: SymbolFlags | undefined): string { - return formatEnum(flags, (ts).SymbolFlags, /*isFlags*/ true); - } - - export function formatTypeFlags(flags: TypeFlags | undefined): string { - return formatEnum(flags, (ts).TypeFlags, /*isFlags*/ true); - } - - export function formatObjectFlags(flags: ObjectFlags | undefined): string { - return formatEnum(flags, (ts).ObjectFlags, /*isFlags*/ true); - } - /** * Creates a new TextRange from the provided pos and end. * @@ -8428,29 +8356,6 @@ namespace ts { return pathext ? path.slice(0, path.length - pathext.length) + (startsWith(ext, ".") ? ext : "." + ext) : path; } - export namespace Debug { - export function showSymbol(symbol: Symbol): string { - const symbolFlags = (ts as any).SymbolFlags; - return `{ flags: ${symbolFlags ? showFlags(symbol.flags, symbolFlags) : symbol.flags}; declarations: ${map(symbol.declarations, showSyntaxKind)} }`; - } - - function showFlags(flags: number, flagsEnum: { [flag: number]: string }): string { - const out: string[] = []; - for (let pow = 0; pow <= 30; pow++) { - const n = 1 << pow; - if (flags & n) { - out.push(flagsEnum[n]); - } - } - return out.join("|"); - } - - export function showSyntaxKind(node: Node): string { - const syntaxKind = (ts as any).SyntaxKind; - return syntaxKind ? syntaxKind[node.kind] : node.kind.toString(); - } - } - export function tryParsePattern(pattern: string): Pattern | undefined { // This should be verified outside of here and a proper error thrown. Debug.assert(hasZeroOrOneAsteriskCharacter(pattern)); diff --git a/src/compiler/visitor.ts b/src/compiler/visitor.ts index 0cb3b269105..53ccd81f7a6 100644 --- a/src/compiler/visitor.ts +++ b/src/compiler/visitor.ts @@ -1558,100 +1558,4 @@ namespace ts { function aggregateTransformFlagsForChildNodes(transformFlags: TransformFlags, nodes: NodeArray): TransformFlags { return transformFlags | aggregateTransformFlagsForNodeArray(nodes); } - - export namespace Debug { - let isDebugInfoEnabled = false; - - export function failBadSyntaxKind(node: Node, message?: string): never { - return fail( - `${message || "Unexpected node."}\r\nNode ${formatSyntaxKind(node.kind)} was unexpected.`, - failBadSyntaxKind); - } - - export const assertEachNode = shouldAssert(AssertionLevel.Normal) - ? (nodes: Node[], test: (node: Node) => boolean, message?: string): void => assert( - test === undefined || every(nodes, test), - message || "Unexpected node.", - () => `Node array did not pass test '${getFunctionName(test)}'.`, - assertEachNode) - : noop; - - export const assertNode = shouldAssert(AssertionLevel.Normal) - ? (node: Node | undefined, test: ((node: Node | undefined) => boolean) | undefined, message?: string): void => assert( - test === undefined || test(node), - message || "Unexpected node.", - () => `Node ${formatSyntaxKind(node!.kind)} did not pass test '${getFunctionName(test!)}'.`, - assertNode) - : noop; - - export const assertOptionalNode = shouldAssert(AssertionLevel.Normal) - ? (node: Node, test: (node: Node) => boolean, message?: string): void => assert( - test === undefined || node === undefined || test(node), - message || "Unexpected node.", - () => `Node ${formatSyntaxKind(node.kind)} did not pass test '${getFunctionName(test)}'.`, - assertOptionalNode) - : noop; - - export const assertOptionalToken = shouldAssert(AssertionLevel.Normal) - ? (node: Node, kind: SyntaxKind, message?: string): void => assert( - kind === undefined || node === undefined || node.kind === kind, - message || "Unexpected node.", - () => `Node ${formatSyntaxKind(node.kind)} was not a '${formatSyntaxKind(kind)}' token.`, - assertOptionalToken) - : noop; - - export const assertMissingNode = shouldAssert(AssertionLevel.Normal) - ? (node: Node, message?: string): void => assert( - node === undefined, - message || "Unexpected node.", - () => `Node ${formatSyntaxKind(node.kind)} was unexpected'.`, - assertMissingNode) - : noop; - - /** - * Injects debug information into frequently used types. - */ - export function enableDebugInfo() { - if (isDebugInfoEnabled) return; - - // Add additional properties in debug mode to assist with debugging. - Object.defineProperties(objectAllocator.getSymbolConstructor().prototype, { - __debugFlags: { get(this: Symbol) { return formatSymbolFlags(this.flags); } } - }); - - Object.defineProperties(objectAllocator.getTypeConstructor().prototype, { - __debugFlags: { get(this: Type) { return formatTypeFlags(this.flags); } }, - __debugObjectFlags: { get(this: Type) { return this.flags & TypeFlags.Object ? formatObjectFlags((this).objectFlags) : ""; } }, - __debugTypeToString: { value(this: Type) { return this.checker.typeToString(this); } }, - }); - - const nodeConstructors = [ - objectAllocator.getNodeConstructor(), - objectAllocator.getIdentifierConstructor(), - objectAllocator.getTokenConstructor(), - objectAllocator.getSourceFileConstructor() - ]; - - for (const ctor of nodeConstructors) { - if (!ctor.prototype.hasOwnProperty("__debugKind")) { - Object.defineProperties(ctor.prototype, { - __debugKind: { get(this: Node) { return formatSyntaxKind(this.kind); } }, - __debugModifierFlags: { get(this: Node) { return formatModifierFlags(getModifierFlagsNoCache(this)); } }, - __debugTransformFlags: { get(this: Node) { return formatTransformFlags(this.transformFlags); } }, - __debugEmitFlags: { get(this: Node) { return formatEmitFlags(getEmitFlags(this)); } }, - __debugGetText: { - value(this: Node, includeTrivia?: boolean) { - if (nodeIsSynthesized(this)) return ""; - const parseNode = getParseTreeNode(this); - const sourceFile = parseNode && getSourceFileOfNode(parseNode); - return sourceFile ? getSourceTextOfNodeFromSourceFile(sourceFile, parseNode, includeTrivia) : ""; - } - } - }); - } - } - - isDebugInfoEnabled = true; - } - } } diff --git a/src/services/codefixes/addNameToNamelessParameter.ts b/src/services/codefixes/addNameToNamelessParameter.ts index f87816ab228..3339f719008 100644 --- a/src/services/codefixes/addNameToNamelessParameter.ts +++ b/src/services/codefixes/addNameToNamelessParameter.ts @@ -15,11 +15,11 @@ namespace ts.codefix { function makeChange(changeTracker: textChanges.ChangeTracker, sourceFile: SourceFile, pos: number) { const token = getTokenAtPosition(sourceFile, pos); if (!isIdentifier(token)) { - return Debug.fail("add-name-to-nameless-parameter operates on identifiers, but got a " + formatSyntaxKind(token.kind)); + return Debug.fail("add-name-to-nameless-parameter operates on identifiers, but got a " + Debug.formatSyntaxKind(token.kind)); } const param = token.parent; if (!isParameter(param)) { - return Debug.fail("Tried to add a parameter name to a non-parameter: " + formatSyntaxKind(token.kind)); + return Debug.fail("Tried to add a parameter name to a non-parameter: " + Debug.formatSyntaxKind(token.kind)); } const i = param.parent.parameters.indexOf(param); Debug.assert(!param.type, "Tried to add a parameter name to a parameter that already had one."); diff --git a/src/services/findAllReferences.ts b/src/services/findAllReferences.ts index 147fee53393..cf0046d2688 100644 --- a/src/services/findAllReferences.ts +++ b/src/services/findAllReferences.ts @@ -635,7 +635,7 @@ namespace ts.FindAllReferences.Core { // Ignore UMD module and global merge if (symbol.flags & SymbolFlags.Transient) return undefined; // Assertions for GH#21814. We should be handling SourceFile symbols in `getReferencedSymbolsForModule` instead of getting here. - Debug.fail(`Unexpected symbol at ${Debug.showSyntaxKind(node)}: ${Debug.showSymbol(symbol)}`); + Debug.fail(`Unexpected symbol at ${Debug.formatSyntaxKind(node.kind)}: ${Debug.formatSymbol(symbol)}`); } return isTypeLiteralNode(decl.parent) && isUnionTypeNode(decl.parent.parent) ? checker.getPropertyOfType(checker.getTypeFromTypeNode(decl.parent.parent), symbol.name) diff --git a/src/services/importTracker.ts b/src/services/importTracker.ts index e8512528af9..2734d059000 100644 --- a/src/services/importTracker.ts +++ b/src/services/importTracker.ts @@ -133,7 +133,7 @@ namespace ts.FindAllReferences { break; default: - Debug.assertNever(direct, `Unexpected import kind: ${Debug.showSyntaxKind(direct)}`); + Debug.failBadSyntaxKind(direct, "Unexpected import kind."); } } } @@ -515,7 +515,7 @@ namespace ts.FindAllReferences { const sym = useLhsSymbol ? checker.getSymbolAtLocation(cast(node.left, isPropertyAccessExpression).name) : symbol; // Better detection for GH#20803 if (sym && !(checker.getMergedSymbol(sym.parent!).flags & SymbolFlags.Module)) { - Debug.fail(`Special property assignment kind does not have a module as its parent. Assignment is ${Debug.showSymbol(sym)}, parent is ${Debug.showSymbol(sym.parent!)}`); + Debug.fail(`Special property assignment kind does not have a module as its parent. Assignment is ${Debug.formatSymbol(sym)}, parent is ${Debug.formatSymbol(sym.parent!)}`); } return sym && exportInfo(sym, kind); } diff --git a/src/services/services.ts b/src/services/services.ts index 9637b3c5321..6c882bbb28f 100644 --- a/src/services/services.ts +++ b/src/services/services.ts @@ -173,7 +173,7 @@ namespace ts { const textPos = scanner.getTextPos(); if (textPos <= end) { if (token === SyntaxKind.Identifier) { - Debug.fail(`Did not expect ${Debug.showSyntaxKind(parent)} to have an Identifier in its trivia`); + Debug.fail(`Did not expect ${Debug.formatSyntaxKind(parent.kind)} to have an Identifier in its trivia`); } nodes.push(createNode(token, pos, textPos, parent)); } diff --git a/src/services/signatureHelp.ts b/src/services/signatureHelp.ts index 0c9f76acacb..25f958dfc6a 100644 --- a/src/services/signatureHelp.ts +++ b/src/services/signatureHelp.ts @@ -455,7 +455,7 @@ namespace ts.SignatureHelp { for (let n = node; !isSourceFile(n) && (isManuallyInvoked || !isBlock(n)); n = n.parent) { // If the node is not a subspan of its parent, this is a big problem. // There have been crashes that might be caused by this violation. - Debug.assert(rangeContainsRange(n.parent, n), "Not a subspan", () => `Child: ${Debug.showSyntaxKind(n)}, parent: ${Debug.showSyntaxKind(n.parent)}`); + Debug.assert(rangeContainsRange(n.parent, n), "Not a subspan", () => `Child: ${Debug.formatSyntaxKind(n.kind)}, parent: ${Debug.formatSyntaxKind(n.parent.kind)}`); const argumentInfo = getImmediatelyContainingArgumentOrContextualParameterInfo(n, position, sourceFile, checker); if (argumentInfo) { return argumentInfo; diff --git a/src/testRunner/unittests/factory.ts b/src/testRunner/unittests/factory.ts index cc760059c19..5593b392567 100644 --- a/src/testRunner/unittests/factory.ts +++ b/src/testRunner/unittests/factory.ts @@ -1,7 +1,7 @@ namespace ts { describe("unittests:: FactoryAPI", () => { function assertSyntaxKind(node: Node, expected: SyntaxKind) { - assert.strictEqual(node.kind, expected, `Actual: ${Debug.showSyntaxKind(node)} Expected: ${(ts as any).SyntaxKind[expected]}`); + assert.strictEqual(node.kind, expected, `Actual: ${Debug.formatSyntaxKind(node.kind)} Expected: ${Debug.formatSyntaxKind(expected)}`); } describe("createExportAssignment", () => { it("parenthesizes default export if necessary", () => { From 6a559e37ee0d660fcc94f086a34370e79e94b17a Mon Sep 17 00:00:00 2001 From: Ron Buckton Date: Wed, 22 May 2019 11:20:57 -0700 Subject: [PATCH 085/119] Fix crash when checking invalid object rest (#31530) --- src/compiler/checker.ts | 39 ++++++++++++------- .../objectRestPropertyMustBeLast.errors.txt | 21 ++++++++++ .../reference/objectRestPropertyMustBeLast.js | 25 ++++++++++++ .../objectRestPropertyMustBeLast.symbols | 23 +++++++++++ .../objectRestPropertyMustBeLast.types | 37 ++++++++++++++++++ .../rest/objectRestPropertyMustBeLast.ts | 5 +++ 6 files changed, 136 insertions(+), 14 deletions(-) create mode 100644 tests/baselines/reference/objectRestPropertyMustBeLast.errors.txt create mode 100644 tests/baselines/reference/objectRestPropertyMustBeLast.js create mode 100644 tests/baselines/reference/objectRestPropertyMustBeLast.symbols create mode 100644 tests/baselines/reference/objectRestPropertyMustBeLast.types create mode 100644 tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 129a79a7c11..05b1015b124 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -23370,14 +23370,16 @@ namespace ts { if (strictNullChecks && properties.length === 0) { return checkNonNullType(sourceType, node); } - for (const p of properties) { - checkObjectLiteralDestructuringPropertyAssignment(sourceType, p, properties, rightIsThis); + for (let i = 0; i < properties.length; i++) { + checkObjectLiteralDestructuringPropertyAssignment(node, sourceType, i, properties, rightIsThis); } return sourceType; } /** Note: If property cannot be a SpreadAssignment, then allProperties does not need to be provided */ - function checkObjectLiteralDestructuringPropertyAssignment(objectLiteralType: Type, property: ObjectLiteralElementLike, allProperties?: NodeArray, rightIsThis = false) { + function checkObjectLiteralDestructuringPropertyAssignment(node: ObjectLiteralExpression, objectLiteralType: Type, propertyIndex: number, allProperties?: NodeArray, rightIsThis = false) { + const properties = node.properties; + const property = properties[propertyIndex]; if (property.kind === SyntaxKind.PropertyAssignment || property.kind === SyntaxKind.ShorthandPropertyAssignment) { const name = property.name; const exprType = getLiteralTypeFromPropertyName(name); @@ -23394,18 +23396,25 @@ namespace ts { return checkDestructuringAssignment(property.kind === SyntaxKind.ShorthandPropertyAssignment ? property : property.initializer, type); } else if (property.kind === SyntaxKind.SpreadAssignment) { - if (languageVersion < ScriptTarget.ESNext) { - checkExternalEmitHelpers(property, ExternalEmitHelpers.Rest); + if (propertyIndex < properties.length - 1) { + error(property, Diagnostics.A_rest_element_must_be_last_in_a_destructuring_pattern); } - const nonRestNames: PropertyName[] = []; - if (allProperties) { - for (let i = 0; i < allProperties.length - 1; i++) { - nonRestNames.push(allProperties[i].name!); + else { + if (languageVersion < ScriptTarget.ESNext) { + checkExternalEmitHelpers(property, ExternalEmitHelpers.Rest); } + const nonRestNames: PropertyName[] = []; + if (allProperties) { + for (const otherProperty of allProperties) { + if (!isSpreadAssignment(otherProperty)) { + nonRestNames.push(otherProperty.name); + } + } + } + const type = getRestType(objectLiteralType, nonRestNames, objectLiteralType.symbol); + checkGrammarForDisallowedTrailingComma(allProperties, Diagnostics.A_rest_parameter_or_binding_pattern_may_not_have_a_trailing_comma); + return checkDestructuringAssignment(property.expression, type); } - const type = getRestType(objectLiteralType, nonRestNames, objectLiteralType.symbol); - checkGrammarForDisallowedTrailingComma(allProperties, Diagnostics.A_rest_parameter_or_binding_pattern_may_not_have_a_trailing_comma); - return checkDestructuringAssignment(property.expression, type); } else { error(property, Diagnostics.Property_assignment_expected); @@ -29964,8 +29973,10 @@ namespace ts { // If this is from nested object binding pattern // for ({ skills: { primary, secondary } } = multiRobot, i = 0; i < 1; i++) { if (expr.parent.kind === SyntaxKind.PropertyAssignment) { - const typeOfParentObjectLiteral = getTypeOfArrayLiteralOrObjectLiteralDestructuringAssignment(expr.parent.parent); - return checkObjectLiteralDestructuringPropertyAssignment(typeOfParentObjectLiteral || errorType, expr.parent)!; // TODO: GH#18217 + const node = cast(expr.parent.parent, isObjectLiteralExpression); + const typeOfParentObjectLiteral = getTypeOfArrayLiteralOrObjectLiteralDestructuringAssignment(node); + const propertyIndex = indexOfNode(node.properties, expr.parent); + return checkObjectLiteralDestructuringPropertyAssignment(node, typeOfParentObjectLiteral || errorType, propertyIndex)!; // TODO: GH#18217 } // Array literal assignment - array destructuring pattern Debug.assert(expr.parent.kind === SyntaxKind.ArrayLiteralExpression); diff --git a/tests/baselines/reference/objectRestPropertyMustBeLast.errors.txt b/tests/baselines/reference/objectRestPropertyMustBeLast.errors.txt new file mode 100644 index 00000000000..bdcb420dc83 --- /dev/null +++ b/tests/baselines/reference/objectRestPropertyMustBeLast.errors.txt @@ -0,0 +1,21 @@ +tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts(1,9): error TS2462: A rest element must be last in a destructuring pattern. +tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts(2,3): error TS2462: A rest element must be last in a destructuring pattern. +tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts(4,9): error TS2462: A rest element must be last in a destructuring pattern. +tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts(5,3): error TS2462: A rest element must be last in a destructuring pattern. + + +==== tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts (4 errors) ==== + var {...a, x } = { x: 1 }; // Error, rest must be last property + ~ +!!! error TS2462: A rest element must be last in a destructuring pattern. + ({...a, x } = { x: 1 }); // Error, rest must be last property + ~~~~ +!!! error TS2462: A rest element must be last in a destructuring pattern. + + var {...a, x, ...b } = { x: 1 }; // Error, rest must be last property + ~ +!!! error TS2462: A rest element must be last in a destructuring pattern. + ({...a, x, ...b } = { x: 1 }); // Error, rest must be last property + ~~~~ +!!! error TS2462: A rest element must be last in a destructuring pattern. + \ No newline at end of file diff --git a/tests/baselines/reference/objectRestPropertyMustBeLast.js b/tests/baselines/reference/objectRestPropertyMustBeLast.js new file mode 100644 index 00000000000..dc91f72dbc7 --- /dev/null +++ b/tests/baselines/reference/objectRestPropertyMustBeLast.js @@ -0,0 +1,25 @@ +//// [objectRestPropertyMustBeLast.ts] +var {...a, x } = { x: 1 }; // Error, rest must be last property +({...a, x } = { x: 1 }); // Error, rest must be last property + +var {...a, x, ...b } = { x: 1 }; // Error, rest must be last property +({...a, x, ...b } = { x: 1 }); // Error, rest must be last property + + +//// [objectRestPropertyMustBeLast.js] +var __rest = (this && this.__rest) || function (s, e) { + var t = {}; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) + t[p] = s[p]; + if (s != null && typeof Object.getOwnPropertySymbols === "function") + for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { + if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) + t[p[i]] = s[p[i]]; + } + return t; +}; +var _a, _b; +var _c = { x: 1 }, x = _c.x; // Error, rest must be last property +(_a = { x: 1 }, (x = _a.x, _a)); // Error, rest must be last property +var _d = { x: 1 }, x = _d.x, b = __rest(_d, ["a", "x"]); // Error, rest must be last property +(_b = { x: 1 }, (x = _b.x, _b), b = __rest(_b, ["x"])); // Error, rest must be last property diff --git a/tests/baselines/reference/objectRestPropertyMustBeLast.symbols b/tests/baselines/reference/objectRestPropertyMustBeLast.symbols new file mode 100644 index 00000000000..7163f2a98c9 --- /dev/null +++ b/tests/baselines/reference/objectRestPropertyMustBeLast.symbols @@ -0,0 +1,23 @@ +=== tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts === +var {...a, x } = { x: 1 }; // Error, rest must be last property +>a : Symbol(a, Decl(objectRestPropertyMustBeLast.ts, 0, 5), Decl(objectRestPropertyMustBeLast.ts, 3, 5)) +>x : Symbol(x, Decl(objectRestPropertyMustBeLast.ts, 0, 10), Decl(objectRestPropertyMustBeLast.ts, 3, 10)) +>x : Symbol(x, Decl(objectRestPropertyMustBeLast.ts, 0, 18)) + +({...a, x } = { x: 1 }); // Error, rest must be last property +>a : Symbol(a, Decl(objectRestPropertyMustBeLast.ts, 0, 5), Decl(objectRestPropertyMustBeLast.ts, 3, 5)) +>x : Symbol(x, Decl(objectRestPropertyMustBeLast.ts, 1, 7)) +>x : Symbol(x, Decl(objectRestPropertyMustBeLast.ts, 1, 15)) + +var {...a, x, ...b } = { x: 1 }; // Error, rest must be last property +>a : Symbol(a, Decl(objectRestPropertyMustBeLast.ts, 0, 5), Decl(objectRestPropertyMustBeLast.ts, 3, 5)) +>x : Symbol(x, Decl(objectRestPropertyMustBeLast.ts, 0, 10), Decl(objectRestPropertyMustBeLast.ts, 3, 10)) +>b : Symbol(b, Decl(objectRestPropertyMustBeLast.ts, 3, 13)) +>x : Symbol(x, Decl(objectRestPropertyMustBeLast.ts, 3, 24)) + +({...a, x, ...b } = { x: 1 }); // Error, rest must be last property +>a : Symbol(a, Decl(objectRestPropertyMustBeLast.ts, 0, 5), Decl(objectRestPropertyMustBeLast.ts, 3, 5)) +>x : Symbol(x, Decl(objectRestPropertyMustBeLast.ts, 4, 7)) +>b : Symbol(b, Decl(objectRestPropertyMustBeLast.ts, 3, 13)) +>x : Symbol(x, Decl(objectRestPropertyMustBeLast.ts, 4, 21)) + diff --git a/tests/baselines/reference/objectRestPropertyMustBeLast.types b/tests/baselines/reference/objectRestPropertyMustBeLast.types new file mode 100644 index 00000000000..8f8aafe6e0f --- /dev/null +++ b/tests/baselines/reference/objectRestPropertyMustBeLast.types @@ -0,0 +1,37 @@ +=== tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts === +var {...a, x } = { x: 1 }; // Error, rest must be last property +>a : {} +>x : number +>{ x: 1 } : { x: number; } +>x : number +>1 : 1 + +({...a, x } = { x: 1 }); // Error, rest must be last property +>({...a, x } = { x: 1 }) : { x: number; } +>{...a, x } = { x: 1 } : { x: number; } +>{...a, x } : { x: number; } +>a : {} +>x : number +>{ x: 1 } : { x: number; } +>x : number +>1 : 1 + +var {...a, x, ...b } = { x: 1 }; // Error, rest must be last property +>a : {} +>x : number +>b : {} +>{ x: 1 } : { x: number; } +>x : number +>1 : 1 + +({...a, x, ...b } = { x: 1 }); // Error, rest must be last property +>({...a, x, ...b } = { x: 1 }) : { x: number; } +>{...a, x, ...b } = { x: 1 } : { x: number; } +>{...a, x, ...b } : { x: number; } +>a : {} +>x : number +>b : {} +>{ x: 1 } : { x: number; } +>x : number +>1 : 1 + diff --git a/tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts b/tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts new file mode 100644 index 00000000000..2e4e17dc302 --- /dev/null +++ b/tests/cases/conformance/types/rest/objectRestPropertyMustBeLast.ts @@ -0,0 +1,5 @@ +var {...a, x } = { x: 1 }; // Error, rest must be last property +({...a, x } = { x: 1 }); // Error, rest must be last property + +var {...a, x, ...b } = { x: 1 }; // Error, rest must be last property +({...a, x, ...b } = { x: 1 }); // Error, rest must be last property From 431f0d6d8c1f803ace4edaf7e0036afcddfd6a11 Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Tue, 21 May 2019 12:47:36 -0700 Subject: [PATCH 086/119] Add test case for #30429 --- ...ionPackageIdWithRelativeAndAbsolutePath.js | 44 +++++++++++ ...ckageIdWithRelativeAndAbsolutePath.symbols | 48 ++++++++++++ ...geIdWithRelativeAndAbsolutePath.trace.json | 76 +++++++++++++++++++ ...PackageIdWithRelativeAndAbsolutePath.types | 46 +++++++++++ ...ionPackageIdWithRelativeAndAbsolutePath.ts | 51 +++++++++++++ 5 files changed, 265 insertions(+) create mode 100644 tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.js create mode 100644 tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.symbols create mode 100644 tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json create mode 100644 tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.types create mode 100644 tests/cases/compiler/moduleResolutionPackageIdWithRelativeAndAbsolutePath.ts diff --git a/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.js b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.js new file mode 100644 index 00000000000..9f09bea10cf --- /dev/null +++ b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.js @@ -0,0 +1,44 @@ +//// [tests/cases/compiler/moduleResolutionPackageIdWithRelativeAndAbsolutePath.ts] //// + +//// [package.json] +{ + "name": "troublesome-lib", + "version": "1.17.1" +} +//// [Compactable.d.ts] +import { Option } from './Option'; +export class Compactable { + option: Option; +} +//// [Option.d.ts] +export class Option { + someProperty: string; +} +//// [app.d.ts] +import { Option } from "troublesome-lib/lib/Option"; +export class SharedOption extends Option { } +export const makeSharedOption: () => SharedOption; +//// [index.d.ts] +import { Compactable } from "troublesome-lib/lib/Compactable"; // Including this will resolve Option as relative through the imports of compactable +//// [package.json] +{ + "name": "troublesome-lib", + "version": "1.17.1" +} +//// [Compactable.d.ts] +import { Option } from './Option'; +export class Compactable { + option: Option; +} +//// [Option.d.ts] +export class Option { + someProperty: string; +} +//// [app.ts] +import * as t from "anotherLib"; // Include the lib that recursively includes option as relative module resolution in this directory +import { makeSharedOption } from "@shared/lib/app"; // Includes option as module in shared folder but as module in node_modules folder + + +//// [/project/src/app.js] +"use strict"; +exports.__esModule = true; diff --git a/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.symbols b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.symbols new file mode 100644 index 00000000000..1e4d65e10b3 --- /dev/null +++ b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.symbols @@ -0,0 +1,48 @@ +=== /project/src/app.ts === +import * as t from "anotherLib"; // Include the lib that recursively includes option as relative module resolution in this directory +>t : Symbol(t, Decl(app.ts, 0, 6)) + +import { makeSharedOption } from "@shared/lib/app"; // Includes option as module in shared folder but as module in node_modules folder +>makeSharedOption : Symbol(makeSharedOption, Decl(app.ts, 1, 8)) + +=== /shared/node_modules/troublesome-lib/lib/Option.d.ts === +export class Option { +>Option : Symbol(Option, Decl(Option.d.ts, 0, 0)) + + someProperty: string; +>someProperty : Symbol(Option.someProperty, Decl(Option.d.ts, 0, 21)) +} +=== /shared/lib/app.d.ts === +import { Option } from "troublesome-lib/lib/Option"; +>Option : Symbol(Option, Decl(app.d.ts, 0, 8)) + +export class SharedOption extends Option { } +>SharedOption : Symbol(SharedOption, Decl(app.d.ts, 0, 52)) +>Option : Symbol(Option, Decl(app.d.ts, 0, 8)) + +export const makeSharedOption: () => SharedOption; +>makeSharedOption : Symbol(makeSharedOption, Decl(app.d.ts, 2, 12)) +>SharedOption : Symbol(SharedOption, Decl(app.d.ts, 0, 52)) + +=== /project/node_modules/anotherLib/index.d.ts === +import { Compactable } from "troublesome-lib/lib/Compactable"; // Including this will resolve Option as relative through the imports of compactable +>Compactable : Symbol(Compactable, Decl(index.d.ts, 0, 8)) + +=== /project/node_modules/troublesome-lib/lib/Compactable.d.ts === +import { Option } from './Option'; +>Option : Symbol(Option, Decl(Compactable.d.ts, 0, 8)) + +export class Compactable { +>Compactable : Symbol(Compactable, Decl(Compactable.d.ts, 0, 34)) + + option: Option; +>option : Symbol(Compactable.option, Decl(Compactable.d.ts, 1, 26)) +>Option : Symbol(Option, Decl(Compactable.d.ts, 0, 8)) +} +=== /project/node_modules/troublesome-lib/lib/Option.d.ts === +export class Option { +>Option : Symbol(Option, Decl(Option.d.ts, 0, 0)) + + someProperty: string; +>someProperty : Symbol(Option.someProperty, Decl(Option.d.ts, 0, 21)) +} diff --git a/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json new file mode 100644 index 00000000000..b08a0f12456 --- /dev/null +++ b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json @@ -0,0 +1,76 @@ +[ + "======== Resolving module 'anotherLib' from '/project/src/app.ts'. ========", + "Module resolution kind is not specified, using 'NodeJs'.", + "'baseUrl' option is set to '/project', using this value to resolve non-relative module name 'anotherLib'.", + "'paths' option is specified, looking for a pattern to match module name 'anotherLib'.", + "'baseUrl' option is set to '/project', using this value to resolve non-relative module name 'anotherLib'.", + "Resolving module name 'anotherLib' relative to base url '/project' - '/project/anotherLib'.", + "Loading module as file / folder, candidate module location '/project/anotherLib', target file type 'TypeScript'.", + "File '/project/anotherLib.ts' does not exist.", + "File '/project/anotherLib.tsx' does not exist.", + "File '/project/anotherLib.d.ts' does not exist.", + "Directory '/project/anotherLib' does not exist, skipping all lookups in it.", + "Loading module 'anotherLib' from 'node_modules' folder, target file type 'TypeScript'.", + "Directory '/project/src/node_modules' does not exist, skipping all lookups in it.", + "File '/project/node_modules/anotherLib/package.json' does not exist.", + "File '/project/node_modules/anotherLib.ts' does not exist.", + "File '/project/node_modules/anotherLib.tsx' does not exist.", + "File '/project/node_modules/anotherLib.d.ts' does not exist.", + "File '/project/node_modules/anotherLib/index.ts' does not exist.", + "File '/project/node_modules/anotherLib/index.tsx' does not exist.", + "File '/project/node_modules/anotherLib/index.d.ts' exist - use it as a name resolution result.", + "Resolving real path for '/project/node_modules/anotherLib/index.d.ts', result '/project/node_modules/anotherLib/index.d.ts'.", + "======== Module name 'anotherLib' was successfully resolved to '/project/node_modules/anotherLib/index.d.ts'. ========", + "======== Resolving module '@shared/lib/app' from '/project/src/app.ts'. ========", + "Module resolution kind is not specified, using 'NodeJs'.", + "'baseUrl' option is set to '/project', using this value to resolve non-relative module name '@shared/lib/app'.", + "'paths' option is specified, looking for a pattern to match module name '@shared/lib/app'.", + "Module name '@shared/lib/app', matched pattern '@shared/*'.", + "Trying substitution '../shared/*', candidate module location: '../shared/lib/app'.", + "Loading module as file / folder, candidate module location '/shared/lib/app', target file type 'TypeScript'.", + "File '/shared/lib/app.ts' does not exist.", + "File '/shared/lib/app.tsx' does not exist.", + "File '/shared/lib/app.d.ts' exist - use it as a name resolution result.", + "======== Module name '@shared/lib/app' was successfully resolved to '/shared/lib/app.d.ts'. ========", + "======== Resolving module 'troublesome-lib/lib/Compactable' from '/project/node_modules/anotherLib/index.d.ts'. ========", + "Module resolution kind is not specified, using 'NodeJs'.", + "'baseUrl' option is set to '/project', using this value to resolve non-relative module name 'troublesome-lib/lib/Compactable'.", + "'paths' option is specified, looking for a pattern to match module name 'troublesome-lib/lib/Compactable'.", + "'baseUrl' option is set to '/project', using this value to resolve non-relative module name 'troublesome-lib/lib/Compactable'.", + "Resolving module name 'troublesome-lib/lib/Compactable' relative to base url '/project' - '/project/troublesome-lib/lib/Compactable'.", + "Loading module as file / folder, candidate module location '/project/troublesome-lib/lib/Compactable', target file type 'TypeScript'.", + "Loading module 'troublesome-lib/lib/Compactable' from 'node_modules' folder, target file type 'TypeScript'.", + "Directory '/project/node_modules/anotherLib/node_modules' does not exist, skipping all lookups in it.", + "'package.json' does not have a 'typesVersions' field.", + "Found 'package.json' at '/project/node_modules/troublesome-lib/package.json'. Package ID is 'troublesome-lib/lib/Compactable/index.d.ts@1.17.1'.", + "File '/project/node_modules/troublesome-lib/lib/Compactable.ts' does not exist.", + "File '/project/node_modules/troublesome-lib/lib/Compactable.tsx' does not exist.", + "File '/project/node_modules/troublesome-lib/lib/Compactable.d.ts' exist - use it as a name resolution result.", + "Resolving real path for '/project/node_modules/troublesome-lib/lib/Compactable.d.ts', result '/project/node_modules/troublesome-lib/lib/Compactable.d.ts'.", + "======== Module name 'troublesome-lib/lib/Compactable' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Compactable.d.ts'. ========", + "======== Resolving module './Option' from '/project/node_modules/troublesome-lib/lib/Compactable.d.ts'. ========", + "Module resolution kind is not specified, using 'NodeJs'.", + "Loading module as file / folder, candidate module location '/project/node_modules/troublesome-lib/lib/Option', target file type 'TypeScript'.", + "File '/project/node_modules/troublesome-lib/lib/Option.ts' does not exist.", + "File '/project/node_modules/troublesome-lib/lib/Option.tsx' does not exist.", + "File '/project/node_modules/troublesome-lib/lib/Option.d.ts' exist - use it as a name resolution result.", + "'package.json' does not have a 'typesVersions' field.", + "Found 'package.json' at '/project/node_modules/troublesome-lib/package.json'. Package ID is 'troublesome-lib/lib/Option.d.ts@1.17.1'.", + "======== Module name './Option' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Option.d.ts'. ========", + "======== Resolving module 'troublesome-lib/lib/Option' from '/shared/lib/app.d.ts'. ========", + "Module resolution kind is not specified, using 'NodeJs'.", + "'baseUrl' option is set to '/project', using this value to resolve non-relative module name 'troublesome-lib/lib/Option'.", + "'paths' option is specified, looking for a pattern to match module name 'troublesome-lib/lib/Option'.", + "'baseUrl' option is set to '/project', using this value to resolve non-relative module name 'troublesome-lib/lib/Option'.", + "Resolving module name 'troublesome-lib/lib/Option' relative to base url '/project' - '/project/troublesome-lib/lib/Option'.", + "Loading module as file / folder, candidate module location '/project/troublesome-lib/lib/Option', target file type 'TypeScript'.", + "Loading module 'troublesome-lib/lib/Option' from 'node_modules' folder, target file type 'TypeScript'.", + "Directory '/shared/lib/node_modules' does not exist, skipping all lookups in it.", + "'package.json' does not have a 'typesVersions' field.", + "Found 'package.json' at '/shared/node_modules/troublesome-lib/package.json'. Package ID is 'troublesome-lib/lib/Option/index.d.ts@1.17.1'.", + "File '/shared/node_modules/troublesome-lib/lib/Option.ts' does not exist.", + "File '/shared/node_modules/troublesome-lib/lib/Option.tsx' does not exist.", + "File '/shared/node_modules/troublesome-lib/lib/Option.d.ts' exist - use it as a name resolution result.", + "Resolving real path for '/shared/node_modules/troublesome-lib/lib/Option.d.ts', result '/shared/node_modules/troublesome-lib/lib/Option.d.ts'.", + "======== Module name 'troublesome-lib/lib/Option' was successfully resolved to '/shared/node_modules/troublesome-lib/lib/Option.d.ts'. ========" +] \ No newline at end of file diff --git a/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.types b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.types new file mode 100644 index 00000000000..f3aa22e7df2 --- /dev/null +++ b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.types @@ -0,0 +1,46 @@ +=== /project/src/app.ts === +import * as t from "anotherLib"; // Include the lib that recursively includes option as relative module resolution in this directory +>t : typeof t + +import { makeSharedOption } from "@shared/lib/app"; // Includes option as module in shared folder but as module in node_modules folder +>makeSharedOption : () => import("/shared/lib/app").SharedOption + +=== /shared/node_modules/troublesome-lib/lib/Option.d.ts === +export class Option { +>Option : Option + + someProperty: string; +>someProperty : string +} +=== /shared/lib/app.d.ts === +import { Option } from "troublesome-lib/lib/Option"; +>Option : typeof Option + +export class SharedOption extends Option { } +>SharedOption : SharedOption +>Option : Option + +export const makeSharedOption: () => SharedOption; +>makeSharedOption : () => SharedOption + +=== /project/node_modules/anotherLib/index.d.ts === +import { Compactable } from "troublesome-lib/lib/Compactable"; // Including this will resolve Option as relative through the imports of compactable +>Compactable : typeof Compactable + +=== /project/node_modules/troublesome-lib/lib/Compactable.d.ts === +import { Option } from './Option'; +>Option : typeof Option + +export class Compactable { +>Compactable : Compactable + + option: Option; +>option : Option +} +=== /project/node_modules/troublesome-lib/lib/Option.d.ts === +export class Option { +>Option : Option + + someProperty: string; +>someProperty : string +} diff --git a/tests/cases/compiler/moduleResolutionPackageIdWithRelativeAndAbsolutePath.ts b/tests/cases/compiler/moduleResolutionPackageIdWithRelativeAndAbsolutePath.ts new file mode 100644 index 00000000000..acbde7b1c7b --- /dev/null +++ b/tests/cases/compiler/moduleResolutionPackageIdWithRelativeAndAbsolutePath.ts @@ -0,0 +1,51 @@ +// @noImplicitReferences: true +// @fullEmitPaths: true +// @traceResolution: true +// @filename: /shared/node_modules/troublesome-lib/package.json +{ + "name": "troublesome-lib", + "version": "1.17.1" +} +// @filename: /shared/node_modules/troublesome-lib/lib/Compactable.d.ts +import { Option } from './Option'; +export class Compactable { + option: Option; +} +// @filename: /shared/node_modules/troublesome-lib/lib/Option.d.ts +export class Option { + someProperty: string; +} +// @filename: /shared/lib/app.d.ts +import { Option } from "troublesome-lib/lib/Option"; +export class SharedOption extends Option { } +export const makeSharedOption: () => SharedOption; +// @filename: /project/node_modules/anotherLib/index.d.ts +import { Compactable } from "troublesome-lib/lib/Compactable"; // Including this will resolve Option as relative through the imports of compactable +// @filename: /project/node_modules/troublesome-lib/package.json +{ + "name": "troublesome-lib", + "version": "1.17.1" +} +// @filename: /project/node_modules/troublesome-lib/lib/Compactable.d.ts +import { Option } from './Option'; +export class Compactable { + option: Option; +} +// @filename: /project/node_modules/troublesome-lib/lib/Option.d.ts +export class Option { + someProperty: string; +} +// @filename: /project/src/app.ts +import * as t from "anotherLib"; // Include the lib that recursively includes option as relative module resolution in this directory +import { makeSharedOption } from "@shared/lib/app"; // Includes option as module in shared folder but as module in node_modules folder + +// @filename: /project/tsconfig.json +{ + "compilerOptions": { + "baseUrl": ".", + "paths": { + "@shared/*": ["../shared/*"] + } + }, + //"files": ["src/app.ts"] +} \ No newline at end of file From 60d0bb9b199e76974cdc65647663267e9fcf75b1 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Wed, 22 May 2019 11:37:35 -0700 Subject: [PATCH 087/119] =?UTF-8?q?Don=E2=80=99t=20touch=20imports=20used?= =?UTF-8?q?=20for=20module=20augmentation=20in=20non-declaration=20files?= =?UTF-8?q?=20since=20it=20could=20change=20JS=20emit?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/services/organizeImports.ts | 28 ++++++++++++------- .../unittests/services/organizeImports.ts | 15 ++++++++++ ...le_augmentation_in_non_declaration_file.ts | 22 +++++++++++++++ 3 files changed, 55 insertions(+), 10 deletions(-) create mode 100644 tests/baselines/reference/organizeImports/Unused_preserve_imports_for_module_augmentation_in_non_declaration_file.ts diff --git a/src/services/organizeImports.ts b/src/services/organizeImports.ts index b6be92fbf9c..81c9108749f 100644 --- a/src/services/organizeImports.ts +++ b/src/services/organizeImports.ts @@ -125,13 +125,22 @@ namespace ts.OrganizeImports { if (name || namedBindings) { usedImports.push(updateImportDeclarationAndClause(importDecl, name, namedBindings)); } - // If a module is imported to be augmented, keep the import declaration, but without an import clause + // If a module is imported to be augmented, it’s used else if (hasModuleDeclarationMatchingSpecifier(sourceFile, moduleSpecifier)) { - usedImports.push(createImportDeclaration( - importDecl.decorators, - importDecl.modifiers, - /*importClause*/ undefined, - moduleSpecifier)); + // If we’re in a declaration file, it’s safe to remove the import clause from it + if (sourceFile.isDeclarationFile) { + usedImports.push(createImportDeclaration( + importDecl.decorators, + importDecl.modifiers, + /*importClause*/ undefined, + moduleSpecifier)); + } + // If we’re not in a declaration file, we can’t remove the import clause even though + // the imported symbols are unused, because removing them makes it look like the import + // declaration has side effects, which will cause it to be preserved in the JS emit. + else { + usedImports.push(importDecl); + } } } @@ -145,10 +154,9 @@ namespace ts.OrganizeImports { function hasModuleDeclarationMatchingSpecifier(sourceFile: SourceFile, moduleSpecifier: Expression) { const moduleSpecifierText = isStringLiteral(moduleSpecifier) && moduleSpecifier.text; - return isString(moduleSpecifierText) && some(sourceFile.statements, statement => - isModuleDeclaration(statement) - && isStringLiteral(statement.name) - && statement.name.text === moduleSpecifierText); + return isString(moduleSpecifierText) && some(sourceFile.moduleAugmentations, moduleName => + isStringLiteral(moduleName) + && moduleName.text === moduleSpecifierText); } function getExternalModuleName(specifier: Expression) { diff --git a/src/testRunner/unittests/services/organizeImports.ts b/src/testRunner/unittests/services/organizeImports.ts index 8003e1867cd..c119aadb34e 100644 --- a/src/testRunner/unittests/services/organizeImports.ts +++ b/src/testRunner/unittests/services/organizeImports.ts @@ -350,6 +350,21 @@ import { } from "lib"; import foo from 'foo'; import { Caseless } from 'caseless'; +declare module 'foo' {} +declare module 'caseless' { + interface Caseless { + test(name: KeyType): boolean; + } +}` + }); + + testOrganizeImports("Unused_preserve_imports_for_module_augmentation_in_non_declaration_file", + { + path: "/test.ts", + content: ` +import foo from 'foo'; +import { Caseless } from 'caseless'; + declare module 'foo' {} declare module 'caseless' { interface Caseless { diff --git a/tests/baselines/reference/organizeImports/Unused_preserve_imports_for_module_augmentation_in_non_declaration_file.ts b/tests/baselines/reference/organizeImports/Unused_preserve_imports_for_module_augmentation_in_non_declaration_file.ts new file mode 100644 index 00000000000..6d28f89903a --- /dev/null +++ b/tests/baselines/reference/organizeImports/Unused_preserve_imports_for_module_augmentation_in_non_declaration_file.ts @@ -0,0 +1,22 @@ +// ==ORIGINAL== + +import foo from 'foo'; +import { Caseless } from 'caseless'; + +declare module 'foo' {} +declare module 'caseless' { + interface Caseless { + test(name: KeyType): boolean; + } +} +// ==ORGANIZED== + +import { Caseless } from 'caseless'; +import foo from 'foo'; + +declare module 'foo' {} +declare module 'caseless' { + interface Caseless { + test(name: KeyType): boolean; + } +} \ No newline at end of file From 85d3c5d7a1b755c7c0ce3de59c961cb4a86a783d Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Wed, 22 May 2019 11:06:49 -0700 Subject: [PATCH 088/119] Trace Package id at the module resolution site --- src/compiler/diagnosticMessages.json | 14 ++++++++----- src/compiler/moduleNameResolver.ts | 21 ++++++++++++------- ...age_relativeImportWithinPackage.trace.json | 12 +++++------ ...ativeImportWithinPackage_scoped.trace.json | 12 +++++------ ...geIdWithRelativeAndAbsolutePath.trace.json | 12 +++++------ ...on_packageJson_yesAtPackageRoot.trace.json | 6 +++--- ...AtPackageRoot_fakeScopedPackage.trace.json | 6 +++--- ...ageRoot_mainFieldInSubDirectory.trace.json | 4 ++-- .../typesVersions.ambientModules.trace.json | 8 +++---- .../typesVersions.multiFile.trace.json | 8 +++---- ...VersionsDeclarationEmit.ambient.trace.json | 8 +++---- ...rsionsDeclarationEmit.multiFile.trace.json | 8 +++---- ...it.multiFileBackReferenceToSelf.trace.json | 16 +++++++------- ...ultiFileBackReferenceToUnmapped.trace.json | 12 +++++------ 14 files changed, 78 insertions(+), 69 deletions(-) diff --git a/src/compiler/diagnosticMessages.json b/src/compiler/diagnosticMessages.json index 87101781ead..e8784e7d1f2 100644 --- a/src/compiler/diagnosticMessages.json +++ b/src/compiler/diagnosticMessages.json @@ -3811,10 +3811,6 @@ "category": "Error", "code": 6189 }, - "Found 'package.json' at '{0}'. Package ID is '{1}'.": { - "category": "Message", - "code": 6190 - }, "Whether to keep outdated console output in watch mode instead of clearing the screen.": { "category": "Message", "code": 6191 @@ -3923,6 +3919,14 @@ "category": "Message", "code": 6217 }, + "======== Module name '{0}' was successfully resolved to '{1}' with Package ID '{2}'. ========": { + "category": "Message", + "code": 6218 + }, + "======== Type reference directive '{0}' was successfully resolved to '{1}' with Package ID '{2}', primary: {3}. ========": { + "category": "Message", + "code": 6219 + }, "Projects to reference": { "category": "Message", @@ -4975,7 +4979,7 @@ "code": 95079 }, - "No value exists in scope for the shorthand property '{0}'. Either declare one or provide an initializer." :{ + "No value exists in scope for the shorthand property '{0}'. Either declare one or provide an initializer.": { "category": "Error", "code": 18004 }, diff --git a/src/compiler/moduleNameResolver.ts b/src/compiler/moduleNameResolver.ts index 8761cc0a087..0cd9160ac42 100644 --- a/src/compiler/moduleNameResolver.ts +++ b/src/compiler/moduleNameResolver.ts @@ -307,7 +307,12 @@ namespace ts { const { fileName, packageId } = resolved; const resolvedFileName = options.preserveSymlinks ? fileName : realPath(fileName, host, traceEnabled); if (traceEnabled) { - trace(host, Diagnostics.Type_reference_directive_0_was_successfully_resolved_to_1_primary_Colon_2, typeReferenceDirectiveName, resolvedFileName, primary); + if (packageId) { + trace(host, Diagnostics.Type_reference_directive_0_was_successfully_resolved_to_1_with_Package_ID_2_primary_Colon_3, typeReferenceDirectiveName, resolvedFileName, packageIdToString(packageId), primary); + } + else { + trace(host, Diagnostics.Type_reference_directive_0_was_successfully_resolved_to_1_primary_Colon_2, typeReferenceDirectiveName, resolvedFileName, primary); + } } resolvedTypeReferenceDirective = { primary, resolvedFileName, packageId, isExternalLibraryImport: pathContainsNodeModules(fileName) }; } @@ -663,7 +668,12 @@ namespace ts { if (traceEnabled) { if (result.resolvedModule) { - trace(host, Diagnostics.Module_name_0_was_successfully_resolved_to_1, moduleName, result.resolvedModule.resolvedFileName); + if (result.resolvedModule.packageId) { + trace(host, Diagnostics.Module_name_0_was_successfully_resolved_to_1_with_Package_ID_2, moduleName, result.resolvedModule.resolvedFileName, packageIdToString(result.resolvedModule.packageId)); + } + else { + trace(host, Diagnostics.Module_name_0_was_successfully_resolved_to_1, moduleName, result.resolvedModule.resolvedFileName); + } } else { trace(host, Diagnostics.Module_name_0_was_not_resolved, moduleName); @@ -1165,12 +1175,7 @@ namespace ts { ? { name: packageJsonContent.name, subModuleName, version: packageJsonContent.version } : undefined; if (traceEnabled) { - if (packageId) { - trace(host, Diagnostics.Found_package_json_at_0_Package_ID_is_1, packageJsonPath, packageIdToString(packageId)); - } - else { - trace(host, Diagnostics.Found_package_json_at_0, packageJsonPath); - } + trace(host, Diagnostics.Found_package_json_at_0, packageJsonPath); } return { packageJsonContent, packageId, versionPaths }; diff --git a/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage.trace.json b/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage.trace.json index c4421e45579..eccaee3a379 100644 --- a/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage.trace.json +++ b/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage.trace.json @@ -3,12 +3,12 @@ "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo/use' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/foo/package.json'. Package ID is 'foo/use/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/foo/package.json'.", "File '/node_modules/foo/use.ts' does not exist.", "File '/node_modules/foo/use.tsx' does not exist.", "File '/node_modules/foo/use.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/foo/use.d.ts', result '/node_modules/foo/use.d.ts'.", - "======== Module name 'foo/use' was successfully resolved to '/node_modules/foo/use.d.ts'. ========", + "======== Module name 'foo/use' was successfully resolved to '/node_modules/foo/use.d.ts' with Package ID 'foo/use/index.d.ts@1.2.3'. ========", "======== Resolving module 'a' from '/index.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'a' from 'node_modules' folder, target file type 'TypeScript'.", @@ -28,8 +28,8 @@ "File '/node_modules/foo/index.tsx' does not exist.", "File '/node_modules/foo/index.d.ts' exist - use it as a name resolution result.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/foo/package.json'. Package ID is 'foo/index.d.ts@1.2.3'.", - "======== Module name './index' was successfully resolved to '/node_modules/foo/index.d.ts'. ========", + "Found 'package.json' at '/node_modules/foo/package.json'.", + "======== Module name './index' was successfully resolved to '/node_modules/foo/index.d.ts' with Package ID 'foo/index.d.ts@1.2.3'. ========", "======== Resolving module 'foo' from '/node_modules/a/index.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo' from 'node_modules' folder, target file type 'TypeScript'.", @@ -37,7 +37,7 @@ "'package.json' does not have a 'types' field.", "'package.json' does not have a 'main' field.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/a/node_modules/foo/package.json'. Package ID is 'foo/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/a/node_modules/foo/package.json'.", "File '/node_modules/a/node_modules/foo.ts' does not exist.", "File '/node_modules/a/node_modules/foo.tsx' does not exist.", "File '/node_modules/a/node_modules/foo.d.ts' does not exist.", @@ -48,5 +48,5 @@ "File '/node_modules/a/node_modules/foo/index.tsx' does not exist.", "File '/node_modules/a/node_modules/foo/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/a/node_modules/foo/index.d.ts', result '/node_modules/a/node_modules/foo/index.d.ts'.", - "======== Module name 'foo' was successfully resolved to '/node_modules/a/node_modules/foo/index.d.ts'. ========" + "======== Module name 'foo' was successfully resolved to '/node_modules/a/node_modules/foo/index.d.ts' with Package ID 'foo/index.d.ts@1.2.3'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage_scoped.trace.json b/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage_scoped.trace.json index 97340de57ca..d08d6e074f5 100644 --- a/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage_scoped.trace.json +++ b/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage_scoped.trace.json @@ -3,12 +3,12 @@ "Module resolution kind is not specified, using 'NodeJs'.", "Loading module '@foo/bar/use' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/@foo/bar/package.json'. Package ID is '@foo/bar/use/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/@foo/bar/package.json'.", "File '/node_modules/@foo/bar/use.ts' does not exist.", "File '/node_modules/@foo/bar/use.tsx' does not exist.", "File '/node_modules/@foo/bar/use.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/@foo/bar/use.d.ts', result '/node_modules/@foo/bar/use.d.ts'.", - "======== Module name '@foo/bar/use' was successfully resolved to '/node_modules/@foo/bar/use.d.ts'. ========", + "======== Module name '@foo/bar/use' was successfully resolved to '/node_modules/@foo/bar/use.d.ts' with Package ID '@foo/bar/use/index.d.ts@1.2.3'. ========", "======== Resolving module 'a' from '/index.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'a' from 'node_modules' folder, target file type 'TypeScript'.", @@ -28,8 +28,8 @@ "File '/node_modules/@foo/bar/index.tsx' does not exist.", "File '/node_modules/@foo/bar/index.d.ts' exist - use it as a name resolution result.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/@foo/bar/package.json'. Package ID is '@foo/bar/index.d.ts@1.2.3'.", - "======== Module name './index' was successfully resolved to '/node_modules/@foo/bar/index.d.ts'. ========", + "Found 'package.json' at '/node_modules/@foo/bar/package.json'.", + "======== Module name './index' was successfully resolved to '/node_modules/@foo/bar/index.d.ts' with Package ID '@foo/bar/index.d.ts@1.2.3'. ========", "======== Resolving module '@foo/bar' from '/node_modules/a/index.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module '@foo/bar' from 'node_modules' folder, target file type 'TypeScript'.", @@ -37,7 +37,7 @@ "'package.json' does not have a 'types' field.", "'package.json' does not have a 'main' field.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/a/node_modules/@foo/bar/package.json'. Package ID is '@foo/bar/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/a/node_modules/@foo/bar/package.json'.", "File '/node_modules/a/node_modules/@foo/bar.ts' does not exist.", "File '/node_modules/a/node_modules/@foo/bar.tsx' does not exist.", "File '/node_modules/a/node_modules/@foo/bar.d.ts' does not exist.", @@ -48,5 +48,5 @@ "File '/node_modules/a/node_modules/@foo/bar/index.tsx' does not exist.", "File '/node_modules/a/node_modules/@foo/bar/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/a/node_modules/@foo/bar/index.d.ts', result '/node_modules/a/node_modules/@foo/bar/index.d.ts'.", - "======== Module name '@foo/bar' was successfully resolved to '/node_modules/a/node_modules/@foo/bar/index.d.ts'. ========" + "======== Module name '@foo/bar' was successfully resolved to '/node_modules/a/node_modules/@foo/bar/index.d.ts' with Package ID '@foo/bar/index.d.ts@1.2.3'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json index b08a0f12456..9f514de9f25 100644 --- a/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json +++ b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json @@ -42,12 +42,12 @@ "Loading module 'troublesome-lib/lib/Compactable' from 'node_modules' folder, target file type 'TypeScript'.", "Directory '/project/node_modules/anotherLib/node_modules' does not exist, skipping all lookups in it.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/project/node_modules/troublesome-lib/package.json'. Package ID is 'troublesome-lib/lib/Compactable/index.d.ts@1.17.1'.", + "Found 'package.json' at '/project/node_modules/troublesome-lib/package.json'.", "File '/project/node_modules/troublesome-lib/lib/Compactable.ts' does not exist.", "File '/project/node_modules/troublesome-lib/lib/Compactable.tsx' does not exist.", "File '/project/node_modules/troublesome-lib/lib/Compactable.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/project/node_modules/troublesome-lib/lib/Compactable.d.ts', result '/project/node_modules/troublesome-lib/lib/Compactable.d.ts'.", - "======== Module name 'troublesome-lib/lib/Compactable' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Compactable.d.ts'. ========", + "======== Module name 'troublesome-lib/lib/Compactable' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Compactable.d.ts' with Package ID 'troublesome-lib/lib/Compactable/index.d.ts@1.17.1'. ========", "======== Resolving module './Option' from '/project/node_modules/troublesome-lib/lib/Compactable.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module as file / folder, candidate module location '/project/node_modules/troublesome-lib/lib/Option', target file type 'TypeScript'.", @@ -55,8 +55,8 @@ "File '/project/node_modules/troublesome-lib/lib/Option.tsx' does not exist.", "File '/project/node_modules/troublesome-lib/lib/Option.d.ts' exist - use it as a name resolution result.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/project/node_modules/troublesome-lib/package.json'. Package ID is 'troublesome-lib/lib/Option.d.ts@1.17.1'.", - "======== Module name './Option' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Option.d.ts'. ========", + "Found 'package.json' at '/project/node_modules/troublesome-lib/package.json'.", + "======== Module name './Option' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Option.d.ts' with Package ID 'troublesome-lib/lib/Option.d.ts@1.17.1'. ========", "======== Resolving module 'troublesome-lib/lib/Option' from '/shared/lib/app.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "'baseUrl' option is set to '/project', using this value to resolve non-relative module name 'troublesome-lib/lib/Option'.", @@ -67,10 +67,10 @@ "Loading module 'troublesome-lib/lib/Option' from 'node_modules' folder, target file type 'TypeScript'.", "Directory '/shared/lib/node_modules' does not exist, skipping all lookups in it.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/shared/node_modules/troublesome-lib/package.json'. Package ID is 'troublesome-lib/lib/Option/index.d.ts@1.17.1'.", + "Found 'package.json' at '/shared/node_modules/troublesome-lib/package.json'.", "File '/shared/node_modules/troublesome-lib/lib/Option.ts' does not exist.", "File '/shared/node_modules/troublesome-lib/lib/Option.tsx' does not exist.", "File '/shared/node_modules/troublesome-lib/lib/Option.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/shared/node_modules/troublesome-lib/lib/Option.d.ts', result '/shared/node_modules/troublesome-lib/lib/Option.d.ts'.", - "======== Module name 'troublesome-lib/lib/Option' was successfully resolved to '/shared/node_modules/troublesome-lib/lib/Option.d.ts'. ========" + "======== Module name 'troublesome-lib/lib/Option' was successfully resolved to '/shared/node_modules/troublesome-lib/lib/Option.d.ts' with Package ID 'troublesome-lib/lib/Option/index.d.ts@1.17.1'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot.trace.json b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot.trace.json index 873805b8b57..4a2e60d9c7f 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot.trace.json @@ -4,7 +4,7 @@ "Loading module 'foo/bar' from 'node_modules' folder, target file type 'TypeScript'.", "File '/node_modules/foo/bar/package.json' does not exist.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/foo/package.json'. Package ID is 'foo/bar/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/foo/package.json'.", "File '/node_modules/foo/bar.ts' does not exist.", "File '/node_modules/foo/bar.tsx' does not exist.", "File '/node_modules/foo/bar.d.ts' does not exist.", @@ -15,10 +15,10 @@ "Loading module 'foo/bar' from 'node_modules' folder, target file type 'JavaScript'.", "File '/node_modules/foo/bar/package.json' does not exist.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/foo/package.json'. Package ID is 'foo/bar/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/foo/package.json'.", "File '/node_modules/foo/bar.js' does not exist.", "File '/node_modules/foo/bar.jsx' does not exist.", "File '/node_modules/foo/bar/index.js' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/foo/bar/index.js', result '/node_modules/foo/bar/index.js'.", - "======== Module name 'foo/bar' was successfully resolved to '/node_modules/foo/bar/index.js'. ========" + "======== Module name 'foo/bar' was successfully resolved to '/node_modules/foo/bar/index.js' with Package ID 'foo/bar/index.d.ts@1.2.3'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_fakeScopedPackage.trace.json b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_fakeScopedPackage.trace.json index 95beae1393e..3f2423ce832 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_fakeScopedPackage.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_fakeScopedPackage.trace.json @@ -4,7 +4,7 @@ "Loading module 'foo/@bar' from 'node_modules' folder, target file type 'TypeScript'.", "File '/node_modules/foo/@bar/package.json' does not exist.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/foo/package.json'. Package ID is 'foo/@bar/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/foo/package.json'.", "File '/node_modules/foo/@bar.ts' does not exist.", "File '/node_modules/foo/@bar.tsx' does not exist.", "File '/node_modules/foo/@bar.d.ts' does not exist.", @@ -15,10 +15,10 @@ "Loading module 'foo/@bar' from 'node_modules' folder, target file type 'JavaScript'.", "File '/node_modules/foo/@bar/package.json' does not exist.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/foo/package.json'. Package ID is 'foo/@bar/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/foo/package.json'.", "File '/node_modules/foo/@bar.js' does not exist.", "File '/node_modules/foo/@bar.jsx' does not exist.", "File '/node_modules/foo/@bar/index.js' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/foo/@bar/index.js', result '/node_modules/foo/@bar/index.js'.", - "======== Module name 'foo/@bar' was successfully resolved to '/node_modules/foo/@bar/index.js'. ========" + "======== Module name 'foo/@bar' was successfully resolved to '/node_modules/foo/@bar/index.js' with Package ID 'foo/@bar/index.d.ts@1.2.3'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_mainFieldInSubDirectory.trace.json b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_mainFieldInSubDirectory.trace.json index 4d7ae487813..6b373fb300f 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_mainFieldInSubDirectory.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_mainFieldInSubDirectory.trace.json @@ -6,7 +6,7 @@ "'package.json' does not have a 'types' field.", "'package.json' has 'main' field 'src/index.js' that references '/node_modules/foo/src/index.js'.", "'package.json' does not have a 'typesVersions' field.", - "Found 'package.json' at '/node_modules/foo/package.json'. Package ID is 'foo/src/index.d.ts@1.2.3'.", + "Found 'package.json' at '/node_modules/foo/package.json'.", "File '/node_modules/foo.ts' does not exist.", "File '/node_modules/foo.tsx' does not exist.", "File '/node_modules/foo.d.ts' does not exist.", @@ -23,5 +23,5 @@ "File '/node_modules/foo/src/index.tsx' does not exist.", "File '/node_modules/foo/src/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/foo/src/index.d.ts', result '/node_modules/foo/src/index.d.ts'.", - "======== Module name 'foo' was successfully resolved to '/node_modules/foo/src/index.d.ts'. ========" + "======== Module name 'foo' was successfully resolved to '/node_modules/foo/src/index.d.ts' with Package ID 'foo/src/index.d.ts@1.2.3'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/typesVersions.ambientModules.trace.json b/tests/baselines/reference/typesVersions.ambientModules.trace.json index ad73f88a8ef..dcaf6acc096 100644 --- a/tests/baselines/reference/typesVersions.ambientModules.trace.json +++ b/tests/baselines/reference/typesVersions.ambientModules.trace.json @@ -5,7 +5,7 @@ "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/moduleResolution/node_modules/ext/index'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'. Package ID is 'ext/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.d.ts' does not exist.", @@ -20,12 +20,12 @@ "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/moduleResolution/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", @@ -44,7 +44,7 @@ "Directory '/node_modules' does not exist, skipping all lookups in it.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'JavaScript'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", diff --git a/tests/baselines/reference/typesVersions.multiFile.trace.json b/tests/baselines/reference/typesVersions.multiFile.trace.json index d52db48acfe..71975474092 100644 --- a/tests/baselines/reference/typesVersions.multiFile.trace.json +++ b/tests/baselines/reference/typesVersions.multiFile.trace.json @@ -5,7 +5,7 @@ "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/moduleResolution/node_modules/ext/index'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'. Package ID is 'ext/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.d.ts' does not exist.", @@ -20,12 +20,12 @@ "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/moduleResolution/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", @@ -33,5 +33,5 @@ "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts'.", - "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts'. ========" + "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/other/index.d.ts@1.0.0'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/typesVersionsDeclarationEmit.ambient.trace.json b/tests/baselines/reference/typesVersionsDeclarationEmit.ambient.trace.json index 2fcf9d052d4..5d5009e8a41 100644 --- a/tests/baselines/reference/typesVersionsDeclarationEmit.ambient.trace.json +++ b/tests/baselines/reference/typesVersionsDeclarationEmit.ambient.trace.json @@ -5,7 +5,7 @@ "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.", @@ -20,12 +20,12 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", @@ -44,7 +44,7 @@ "Directory '/node_modules' does not exist, skipping all lookups in it.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'JavaScript'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", diff --git a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFile.trace.json b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFile.trace.json index eee9622037b..9fb9c48332a 100644 --- a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFile.trace.json +++ b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFile.trace.json @@ -5,7 +5,7 @@ "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.", @@ -20,12 +20,12 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", @@ -33,5 +33,5 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'.", - "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'. ========" + "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/other/index.d.ts@1.0.0'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.trace.json b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.trace.json index 464da214bae..6deb7327c99 100644 --- a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.trace.json +++ b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.trace.json @@ -5,7 +5,7 @@ "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/ndex/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'index'.", @@ -16,7 +16,7 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", - "======== Module name '../' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========", + "======== Module name '../' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/ndex/index.d.ts@1.0.0'. ========", "======== Resolving module '../other' from 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/other', target file type 'TypeScript'.", @@ -24,15 +24,15 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other.d.ts@1.0.0'.", - "======== Module name '../other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'. ========", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "======== Module name '../other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' with Package ID 'ext/other.d.ts@1.0.0'. ========", "======== Resolving module 'ext' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.", @@ -47,12 +47,12 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", @@ -60,5 +60,5 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'.", - "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'. ========" + "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/other/index.d.ts@1.0.0'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.trace.json b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.trace.json index fe65b605283..94f15e64260 100644 --- a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.trace.json +++ b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.trace.json @@ -6,15 +6,15 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other.d.ts@1.0.0'.", - "======== Module name '../other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'. ========", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "======== Module name '../other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' with Package ID 'ext/other.d.ts@1.0.0'. ========", "======== Resolving module 'ext' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.", @@ -29,16 +29,16 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", "'package.json' has a 'typesVersions' field with version-specific path mappings.", - "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.", + "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'.", - "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'. ========" + "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' with Package ID 'ext/other/index.d.ts@1.0.0'. ========" ] \ No newline at end of file From eecb6d90497bd460bbe555d39358b30253896de8 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Wed, 22 May 2019 13:39:05 -0700 Subject: [PATCH 089/119] Add failing test --- .../conformance/types/tuple/readonlyArraysAndTuples.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts b/tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts index d9fecee7dea..35c86175a0b 100644 --- a/tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts +++ b/tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts @@ -28,3 +28,10 @@ function f1(ma: string[], ra: readonly string[], mt: [string, string], rt: reado rt = ra; // Error rt = mt; } + +declare var v: readonly[number, number, ...number[]]; +v[0] = 1; // Error +v[1] = 1; // Error +v[2] = 1; // Error +v[0 + 1] = 1; // Error +v[0 + 2] = 1; // Error From 5d188a8c68d1a54d6933ad0be5e1375b7be3e4db Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Wed, 22 May 2019 14:22:46 -0700 Subject: [PATCH 090/119] Always use resolved file to figure out subModule name in package id Fixes #30429 --- src/compiler/moduleNameResolver.ts | 129 +++++++----------- ...age_relativeImportWithinPackage.trace.json | 11 +- ...ativeImportWithinPackage_scoped.trace.json | 11 +- .../reference/library-reference-10.trace.json | 6 +- .../reference/library-reference-11.trace.json | 3 +- .../reference/library-reference-12.trace.json | 4 +- .../reference/library-reference-2.trace.json | 8 +- ...geIdWithRelativeAndAbsolutePath.trace.json | 10 +- ...lutionWithExtensions_unexpected.trace.json | 10 +- ...utionWithExtensions_unexpected2.trace.json | 8 +- ...on_packageJson_notAtPackageRoot.trace.json | 4 +- ...AtPackageRoot_fakeScopedPackage.trace.json | 4 +- ...ution_packageJson_scopedPackage.trace.json | 4 +- ...on_packageJson_yesAtPackageRoot.trace.json | 15 +- ...AtPackageRoot_fakeScopedPackage.trace.json | 15 +- ...ageRoot_mainFieldInSubDirectory.trace.json | 5 +- .../reference/packageJsonMain.trace.json | 30 +--- .../packageJsonMain_isNonRecursive.trace.json | 10 +- .../typesVersions.ambientModules.trace.json | 13 +- .../typesVersions.justIndex.trace.json | 5 +- .../typesVersions.multiFile.trace.json | 10 +- ...VersionsDeclarationEmit.ambient.trace.json | 13 +- ...rsionsDeclarationEmit.multiFile.trace.json | 10 +- ...it.multiFileBackReferenceToSelf.trace.json | 18 +-- ...ultiFileBackReferenceToUnmapped.trace.json | 12 +- .../reference/typingsLookup4.trace.json | 24 ++-- 26 files changed, 154 insertions(+), 238 deletions(-) diff --git a/src/compiler/moduleNameResolver.ts b/src/compiler/moduleNameResolver.ts index 0cd9160ac42..19402b03ee9 100644 --- a/src/compiler/moduleNameResolver.ts +++ b/src/compiler/moduleNameResolver.ts @@ -16,12 +16,23 @@ namespace ts { push(value: T): void; } - function withPackageId(packageId: PackageId | undefined, r: PathAndExtension | undefined): Resolved | undefined { + function withPackageId(packageInfo: PackageJsonInfo | undefined, r: PathAndExtension | undefined): Resolved | undefined { + let packageId: PackageId | undefined; + if (r && packageInfo) { + const packageJsonContent = packageInfo.packageJsonContent as PackageJson; + if (typeof packageJsonContent.name === "string" && typeof packageJsonContent.version === "string") { + packageId = { + name: packageJsonContent.name, + subModuleName: r.path.slice(packageInfo.packageDirectory.length + directorySeparator.length), + version: packageJsonContent.version + }; + } + } return r && { path: r.path, extension: r.ext, packageId }; } function noPackageId(r: PathAndExtension | undefined): Resolved | undefined { - return withPackageId(/*packageId*/ undefined, r); + return withPackageId(/*packageInfo*/ undefined, r); } function removeIgnoredPackageId(r: Resolved | undefined): PathAndExtension | undefined { @@ -978,10 +989,9 @@ namespace ts { } const resolvedFromFile = loadModuleFromFile(extensions, candidate, onlyRecordFailures, state); if (resolvedFromFile) { - const nm = considerPackageJson ? parseNodeModuleFromPath(resolvedFromFile) : undefined; - const packageInfo = nm && getPackageJsonInfo(nm.packageDirectory, nm.subModuleName, /*onlyRecordFailures*/ false, state); - const packageId = packageInfo && packageInfo.packageId; - return withPackageId(packageId, resolvedFromFile); + const packageDirectory = considerPackageJson ? parseNodeModuleFromPath(resolvedFromFile) : undefined; + const packageInfo = packageDirectory ? getPackageJsonInfo(packageDirectory, /*onlyRecordFailures*/ false, state) : undefined; + return withPackageId(packageInfo, resolvedFromFile); } } if (!onlyRecordFailures) { @@ -1008,13 +1018,12 @@ namespace ts { * (Not neeeded for `loadModuleFromNodeModules` as that looks up the `package.json` as part of resolution.) * * packageDirectory is the directory of the package itself. - * subModuleName is the path within the package. - * For `blah/node_modules/foo/index.d.ts` this is { packageDirectory: "foo", subModuleName: "index.d.ts" }. (Part before "/node_modules/" is ignored.) - * For `/node_modules/foo/bar.d.ts` this is { packageDirectory: "foo", subModuleName": "bar/index.d.ts" }. - * For `/node_modules/@types/foo/bar/index.d.ts` this is { packageDirectory: "@types/foo", subModuleName: "bar/index.d.ts" }. - * For `/node_modules/foo/bar/index.d.ts` this is { packageDirectory: "foo", subModuleName": "bar/index.d.ts" }. + * For `blah/node_modules/foo/index.d.ts` this is packageDirectory: "foo" + * For `/node_modules/foo/bar.d.ts` this is packageDirectory: "foo" + * For `/node_modules/@types/foo/bar/index.d.ts` this is packageDirectory: "@types/foo" + * For `/node_modules/foo/bar/index.d.ts` this is packageDirectory: "foo" */ - function parseNodeModuleFromPath(resolved: PathAndExtension): { packageDirectory: string, subModuleName: string } | undefined { + function parseNodeModuleFromPath(resolved: PathAndExtension): string | undefined { const path = normalizePath(resolved.path); const idx = path.lastIndexOf(nodeModulesPathPart); if (idx === -1) { @@ -1026,9 +1035,7 @@ namespace ts { if (path.charCodeAt(indexAfterNodeModules) === CharacterCodes.at) { indexAfterPackageName = moveToNextDirectorySeparatorIfAvailable(path, indexAfterPackageName); } - const packageDirectory = path.slice(0, indexAfterPackageName); - const subModuleName = removeExtension(path.slice(indexAfterPackageName + 1), resolved.ext) + Extension.Dts; - return { packageDirectory, subModuleName }; + return path.slice(0, indexAfterPackageName); } function moveToNextDirectorySeparatorIfAvailable(path: string, prevSeparatorIndex: number): number { @@ -1036,19 +1043,6 @@ namespace ts { return nextSeparatorIndex === -1 ? prevSeparatorIndex : nextSeparatorIndex; } - function addExtensionAndIndex(path: string): string { - if (path === "") { - return "index.d.ts"; - } - if (endsWith(path, ".d.ts")) { - return path; - } - if (path === "index" || endsWith(path, "/index")) { - return path + ".d.ts"; - } - return path + "/index.d.ts"; - } - function loadModuleFromFileNoPackageId(extensions: Extensions, candidate: string, onlyRecordFailures: boolean, state: ModuleResolutionState): Resolved | undefined { return noPackageId(loadModuleFromFile(extensions, candidate, onlyRecordFailures, state)); } @@ -1129,56 +1123,29 @@ namespace ts { } function loadNodeModuleFromDirectory(extensions: Extensions, candidate: string, onlyRecordFailures: boolean, state: ModuleResolutionState, considerPackageJson = true) { - const packageInfo = considerPackageJson ? getPackageJsonInfo(candidate, "", onlyRecordFailures, state) : undefined; - const packageId = packageInfo && packageInfo.packageId; + const packageInfo = considerPackageJson ? getPackageJsonInfo(candidate, onlyRecordFailures, state) : undefined; const packageJsonContent = packageInfo && packageInfo.packageJsonContent; const versionPaths = packageInfo && packageInfo.versionPaths; - return withPackageId(packageId, loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, packageJsonContent, versionPaths)); + return withPackageId(packageInfo, loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, packageJsonContent, versionPaths)); } interface PackageJsonInfo { - packageJsonContent: PackageJsonPathFields | undefined; - packageId: PackageId | undefined; + packageDirectory: string; + packageJsonContent: PackageJsonPathFields; versionPaths: VersionPaths | undefined; } - function getPackageJsonInfo(packageDirectory: string, subModuleName: string, onlyRecordFailures: boolean, state: ModuleResolutionState): PackageJsonInfo | undefined { + function getPackageJsonInfo(packageDirectory: string, onlyRecordFailures: boolean, state: ModuleResolutionState): PackageJsonInfo | undefined { const { host, traceEnabled } = state; const directoryExists = !onlyRecordFailures && directoryProbablyExists(packageDirectory, host); const packageJsonPath = combinePaths(packageDirectory, "package.json"); if (directoryExists && host.fileExists(packageJsonPath)) { const packageJsonContent = readJson(packageJsonPath, host) as PackageJson; - if (subModuleName === "") { // looking up the root - need to handle types/typings/main redirects for subModuleName - const path = readPackageJsonTypesFields(packageJsonContent, packageDirectory, state); - if (typeof path === "string") { - subModuleName = addExtensionAndIndex(path.substring(packageDirectory.length + 1)); - } - else { - const jsPath = readPackageJsonMainField(packageJsonContent, packageDirectory, state); - if (typeof jsPath === "string" && jsPath.length > packageDirectory.length) { - const potentialSubModule = jsPath.substring(packageDirectory.length + 1); - subModuleName = (forEach(supportedJSExtensions, extension => - tryRemoveExtension(potentialSubModule, extension)) || potentialSubModule) + Extension.Dts; - } - else { - subModuleName = "index.d.ts"; - } - } - } - - if (!endsWith(subModuleName, Extension.Dts)) { - subModuleName = addExtensionAndIndex(subModuleName); - } - - const versionPaths = readPackageJsonTypesVersionPaths(packageJsonContent, state); - const packageId: PackageId | undefined = typeof packageJsonContent.name === "string" && typeof packageJsonContent.version === "string" - ? { name: packageJsonContent.name, subModuleName, version: packageJsonContent.version } - : undefined; if (traceEnabled) { trace(host, Diagnostics.Found_package_json_at_0, packageJsonPath); } - - return { packageJsonContent, packageId, versionPaths }; + const versionPaths = readPackageJsonTypesVersionPaths(packageJsonContent, state); + return { packageDirectory, packageJsonContent, versionPaths }; } else { if (directoryExists && traceEnabled) { @@ -1333,27 +1300,36 @@ namespace ts { const candidate = normalizePath(combinePaths(nodeModulesDirectory, moduleName)); // First look for a nested package.json, as in `node_modules/foo/bar/package.json`. - let packageJsonContent: PackageJsonPathFields | undefined; - let packageId: PackageId | undefined; - let versionPaths: VersionPaths | undefined; - - const packageInfo = getPackageJsonInfo(candidate, "", !nodeModulesDirectoryExists, state); + let packageInfo = getPackageJsonInfo(candidate, !nodeModulesDirectoryExists, state); if (packageInfo) { - ({ packageJsonContent, packageId, versionPaths } = packageInfo); const fromFile = loadModuleFromFile(extensions, candidate, !nodeModulesDirectoryExists, state); if (fromFile) { return noPackageId(fromFile); } - const fromDirectory = loadNodeModuleFromDirectoryWorker(extensions, candidate, !nodeModulesDirectoryExists, state, packageJsonContent, versionPaths); - return withPackageId(packageId, fromDirectory); + const fromDirectory = loadNodeModuleFromDirectoryWorker( + extensions, + candidate, + !nodeModulesDirectoryExists, + state, + packageInfo.packageJsonContent, + packageInfo.versionPaths + ); + return withPackageId(packageInfo, fromDirectory); } const loader: ResolutionKindSpecificLoader = (extensions, candidate, onlyRecordFailures, state) => { const pathAndExtension = loadModuleFromFile(extensions, candidate, onlyRecordFailures, state) || - loadNodeModuleFromDirectoryWorker(extensions, candidate, onlyRecordFailures, state, packageJsonContent, versionPaths); - return withPackageId(packageId, pathAndExtension); + loadNodeModuleFromDirectoryWorker( + extensions, + candidate, + onlyRecordFailures, + state, + packageInfo && packageInfo.packageJsonContent, + packageInfo && packageInfo.versionPaths + ); + return withPackageId(packageInfo, pathAndExtension); }; const { packageName, rest } = parsePackageName(moduleName); @@ -1361,14 +1337,13 @@ namespace ts { const packageDirectory = combinePaths(nodeModulesDirectory, packageName); // Don't use a "types" or "main" from here because we're not loading the root, but a subdirectory -- just here for the packageId and path mappings. - const packageInfo = getPackageJsonInfo(packageDirectory, rest, !nodeModulesDirectoryExists, state); - if (packageInfo) ({ packageId, versionPaths } = packageInfo); - if (versionPaths) { + packageInfo = getPackageJsonInfo(packageDirectory, !nodeModulesDirectoryExists, state); + if (packageInfo && packageInfo.versionPaths) { if (state.traceEnabled) { - trace(state.host, Diagnostics.package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2, versionPaths.version, version, rest); + trace(state.host, Diagnostics.package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2, packageInfo.versionPaths.version, version, rest); } const packageDirectoryExists = nodeModulesDirectoryExists && directoryProbablyExists(packageDirectory, state.host); - const fromPaths = tryLoadModuleUsingPaths(extensions, rest, packageDirectory, versionPaths.paths, loader, !packageDirectoryExists, state); + const fromPaths = tryLoadModuleUsingPaths(extensions, rest, packageDirectory, packageInfo.versionPaths.paths, loader, !packageDirectoryExists, state); if (fromPaths) { return fromPaths.value; } diff --git a/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage.trace.json b/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage.trace.json index eccaee3a379..8711f881de8 100644 --- a/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage.trace.json +++ b/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage.trace.json @@ -2,13 +2,13 @@ "======== Resolving module 'foo/use' from '/index.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo/use' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo/use.ts' does not exist.", "File '/node_modules/foo/use.tsx' does not exist.", "File '/node_modules/foo/use.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/foo/use.d.ts', result '/node_modules/foo/use.d.ts'.", - "======== Module name 'foo/use' was successfully resolved to '/node_modules/foo/use.d.ts' with Package ID 'foo/use/index.d.ts@1.2.3'. ========", + "======== Module name 'foo/use' was successfully resolved to '/node_modules/foo/use.d.ts' with Package ID 'foo/use.d.ts@1.2.3'. ========", "======== Resolving module 'a' from '/index.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'a' from 'node_modules' folder, target file type 'TypeScript'.", @@ -27,17 +27,14 @@ "File '/node_modules/foo/index.ts' does not exist.", "File '/node_modules/foo/index.tsx' does not exist.", "File '/node_modules/foo/index.d.ts' exist - use it as a name resolution result.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "======== Module name './index' was successfully resolved to '/node_modules/foo/index.d.ts' with Package ID 'foo/index.d.ts@1.2.3'. ========", "======== Resolving module 'foo' from '/node_modules/a/index.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' does not have a 'main' field.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/a/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/a/node_modules/foo.ts' does not exist.", "File '/node_modules/a/node_modules/foo.tsx' does not exist.", "File '/node_modules/a/node_modules/foo.d.ts' does not exist.", diff --git a/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage_scoped.trace.json b/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage_scoped.trace.json index d08d6e074f5..2a4b74ad555 100644 --- a/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage_scoped.trace.json +++ b/tests/baselines/reference/duplicatePackage_relativeImportWithinPackage_scoped.trace.json @@ -2,13 +2,13 @@ "======== Resolving module '@foo/bar/use' from '/index.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module '@foo/bar/use' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@foo/bar/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/@foo/bar/use.ts' does not exist.", "File '/node_modules/@foo/bar/use.tsx' does not exist.", "File '/node_modules/@foo/bar/use.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/@foo/bar/use.d.ts', result '/node_modules/@foo/bar/use.d.ts'.", - "======== Module name '@foo/bar/use' was successfully resolved to '/node_modules/@foo/bar/use.d.ts' with Package ID '@foo/bar/use/index.d.ts@1.2.3'. ========", + "======== Module name '@foo/bar/use' was successfully resolved to '/node_modules/@foo/bar/use.d.ts' with Package ID '@foo/bar/use.d.ts@1.2.3'. ========", "======== Resolving module 'a' from '/index.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'a' from 'node_modules' folder, target file type 'TypeScript'.", @@ -27,17 +27,14 @@ "File '/node_modules/@foo/bar/index.ts' does not exist.", "File '/node_modules/@foo/bar/index.tsx' does not exist.", "File '/node_modules/@foo/bar/index.d.ts' exist - use it as a name resolution result.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@foo/bar/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "======== Module name './index' was successfully resolved to '/node_modules/@foo/bar/index.d.ts' with Package ID '@foo/bar/index.d.ts@1.2.3'. ========", "======== Resolving module '@foo/bar' from '/node_modules/a/index.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module '@foo/bar' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' does not have a 'main' field.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/a/node_modules/@foo/bar/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/a/node_modules/@foo/bar.ts' does not exist.", "File '/node_modules/a/node_modules/@foo/bar.tsx' does not exist.", "File '/node_modules/a/node_modules/@foo/bar.d.ts' does not exist.", diff --git a/tests/baselines/reference/library-reference-10.trace.json b/tests/baselines/reference/library-reference-10.trace.json index 37f8ab543ca..92b5b035079 100644 --- a/tests/baselines/reference/library-reference-10.trace.json +++ b/tests/baselines/reference/library-reference-10.trace.json @@ -1,18 +1,16 @@ [ "======== Resolving type reference directive 'jquery', containing file '/foo/consumer.ts', root directory './types'. ========", "Resolving with primary search path './types'.", - "'package.json' has 'typings' field 'jquery.d.ts' that references 'types/jquery/jquery.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at './types/jquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "'package.json' has 'typings' field 'jquery.d.ts' that references 'types/jquery/jquery.d.ts'.", "File 'types/jquery/jquery.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'types/jquery/jquery.d.ts', result '/foo/types/jquery/jquery.d.ts'.", "======== Type reference directive 'jquery' was successfully resolved to '/foo/types/jquery/jquery.d.ts', primary: true. ========", "======== Resolving type reference directive 'jquery', containing file '/foo/__inferred type names__.ts', root directory './types'. ========", "Resolving with primary search path './types'.", - "'package.json' has 'typings' field 'jquery.d.ts' that references 'types/jquery/jquery.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at './types/jquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "'package.json' has 'typings' field 'jquery.d.ts' that references 'types/jquery/jquery.d.ts'.", "File 'types/jquery/jquery.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'types/jquery/jquery.d.ts', result '/foo/types/jquery/jquery.d.ts'.", diff --git a/tests/baselines/reference/library-reference-11.trace.json b/tests/baselines/reference/library-reference-11.trace.json index b5e324d8c36..ff1905707a3 100644 --- a/tests/baselines/reference/library-reference-11.trace.json +++ b/tests/baselines/reference/library-reference-11.trace.json @@ -3,9 +3,8 @@ "Root directory cannot be determined, skipping primary search paths.", "Looking up in 'node_modules' folder, initial location '/a/b'.", "Directory '/a/b/node_modules' does not exist, skipping all lookups in it.", - "'package.json' has 'typings' field 'jquery.d.ts' that references '/a/node_modules/jquery/jquery.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/a/node_modules/jquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/a/node_modules/jquery.d.ts' does not exist.", "'package.json' has 'typings' field 'jquery.d.ts' that references '/a/node_modules/jquery/jquery.d.ts'.", "File '/a/node_modules/jquery/jquery.d.ts' exist - use it as a name resolution result.", diff --git a/tests/baselines/reference/library-reference-12.trace.json b/tests/baselines/reference/library-reference-12.trace.json index 1421f1501d9..63be1cc32a3 100644 --- a/tests/baselines/reference/library-reference-12.trace.json +++ b/tests/baselines/reference/library-reference-12.trace.json @@ -3,10 +3,8 @@ "Root directory cannot be determined, skipping primary search paths.", "Looking up in 'node_modules' folder, initial location '/a/b'.", "Directory '/a/b/node_modules' does not exist, skipping all lookups in it.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'dist/jquery.d.ts' that references '/a/node_modules/jquery/dist/jquery.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/a/node_modules/jquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/a/node_modules/jquery.d.ts' does not exist.", "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'dist/jquery.d.ts' that references '/a/node_modules/jquery/dist/jquery.d.ts'.", diff --git a/tests/baselines/reference/library-reference-2.trace.json b/tests/baselines/reference/library-reference-2.trace.json index b9b4cf08ca2..d4f50990005 100644 --- a/tests/baselines/reference/library-reference-2.trace.json +++ b/tests/baselines/reference/library-reference-2.trace.json @@ -1,10 +1,8 @@ [ "======== Resolving type reference directive 'jquery', containing file '/consumer.ts', root directory '/types'. ========", "Resolving with primary search path '/types'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'jquery.d.ts' that references '/types/jquery/jquery.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/types/jquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'jquery.d.ts' that references '/types/jquery/jquery.d.ts'.", "File '/types/jquery/jquery.d.ts' exist - use it as a name resolution result.", @@ -12,10 +10,8 @@ "======== Type reference directive 'jquery' was successfully resolved to '/types/jquery/jquery.d.ts', primary: true. ========", "======== Resolving type reference directive 'jquery', containing file '/test/__inferred type names__.ts', root directory '/types'. ========", "Resolving with primary search path '/types'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'jquery.d.ts' that references '/types/jquery/jquery.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/types/jquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'jquery.d.ts' that references '/types/jquery/jquery.d.ts'.", "File '/types/jquery/jquery.d.ts' exist - use it as a name resolution result.", diff --git a/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json index 9f514de9f25..e3d7b5dea54 100644 --- a/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json +++ b/tests/baselines/reference/moduleResolutionPackageIdWithRelativeAndAbsolutePath.trace.json @@ -41,21 +41,21 @@ "Loading module as file / folder, candidate module location '/project/troublesome-lib/lib/Compactable', target file type 'TypeScript'.", "Loading module 'troublesome-lib/lib/Compactable' from 'node_modules' folder, target file type 'TypeScript'.", "Directory '/project/node_modules/anotherLib/node_modules' does not exist, skipping all lookups in it.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/project/node_modules/troublesome-lib/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/project/node_modules/troublesome-lib/lib/Compactable.ts' does not exist.", "File '/project/node_modules/troublesome-lib/lib/Compactable.tsx' does not exist.", "File '/project/node_modules/troublesome-lib/lib/Compactable.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/project/node_modules/troublesome-lib/lib/Compactable.d.ts', result '/project/node_modules/troublesome-lib/lib/Compactable.d.ts'.", - "======== Module name 'troublesome-lib/lib/Compactable' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Compactable.d.ts' with Package ID 'troublesome-lib/lib/Compactable/index.d.ts@1.17.1'. ========", + "======== Module name 'troublesome-lib/lib/Compactable' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Compactable.d.ts' with Package ID 'troublesome-lib/lib/Compactable.d.ts@1.17.1'. ========", "======== Resolving module './Option' from '/project/node_modules/troublesome-lib/lib/Compactable.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module as file / folder, candidate module location '/project/node_modules/troublesome-lib/lib/Option', target file type 'TypeScript'.", "File '/project/node_modules/troublesome-lib/lib/Option.ts' does not exist.", "File '/project/node_modules/troublesome-lib/lib/Option.tsx' does not exist.", "File '/project/node_modules/troublesome-lib/lib/Option.d.ts' exist - use it as a name resolution result.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/project/node_modules/troublesome-lib/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "======== Module name './Option' was successfully resolved to '/project/node_modules/troublesome-lib/lib/Option.d.ts' with Package ID 'troublesome-lib/lib/Option.d.ts@1.17.1'. ========", "======== Resolving module 'troublesome-lib/lib/Option' from '/shared/lib/app.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", @@ -66,11 +66,11 @@ "Loading module as file / folder, candidate module location '/project/troublesome-lib/lib/Option', target file type 'TypeScript'.", "Loading module 'troublesome-lib/lib/Option' from 'node_modules' folder, target file type 'TypeScript'.", "Directory '/shared/lib/node_modules' does not exist, skipping all lookups in it.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/shared/node_modules/troublesome-lib/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/shared/node_modules/troublesome-lib/lib/Option.ts' does not exist.", "File '/shared/node_modules/troublesome-lib/lib/Option.tsx' does not exist.", "File '/shared/node_modules/troublesome-lib/lib/Option.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/shared/node_modules/troublesome-lib/lib/Option.d.ts', result '/shared/node_modules/troublesome-lib/lib/Option.d.ts'.", - "======== Module name 'troublesome-lib/lib/Option' was successfully resolved to '/shared/node_modules/troublesome-lib/lib/Option.d.ts' with Package ID 'troublesome-lib/lib/Option/index.d.ts@1.17.1'. ========" + "======== Module name 'troublesome-lib/lib/Option' was successfully resolved to '/shared/node_modules/troublesome-lib/lib/Option.d.ts' with Package ID 'troublesome-lib/lib/Option.d.ts@1.17.1'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/moduleResolutionWithExtensions_unexpected.trace.json b/tests/baselines/reference/moduleResolutionWithExtensions_unexpected.trace.json index d386774db15..28e150aa345 100644 --- a/tests/baselines/reference/moduleResolutionWithExtensions_unexpected.trace.json +++ b/tests/baselines/reference/moduleResolutionWithExtensions_unexpected.trace.json @@ -2,11 +2,8 @@ "======== Resolving module 'normalize.css' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'normalize.css' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'normalize.css' that references '/node_modules/normalize.css/normalize.css'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/normalize.css/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/normalize.css.ts' does not exist.", "File '/node_modules/normalize.css.tsx' does not exist.", "File '/node_modules/normalize.css.d.ts' does not exist.", @@ -25,11 +22,8 @@ "File '/node_modules/normalize.css/index.d.ts' does not exist.", "Directory '/node_modules/@types' does not exist, skipping all lookups in it.", "Loading module 'normalize.css' from 'node_modules' folder, target file type 'JavaScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'normalize.css' that references '/node_modules/normalize.css/normalize.css'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/normalize.css/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/normalize.css.js' does not exist.", "File '/node_modules/normalize.css.jsx' does not exist.", "'package.json' has 'main' field 'normalize.css' that references '/node_modules/normalize.css/normalize.css'.", diff --git a/tests/baselines/reference/moduleResolutionWithExtensions_unexpected2.trace.json b/tests/baselines/reference/moduleResolutionWithExtensions_unexpected2.trace.json index 09a7bf81c98..a92c5953af3 100644 --- a/tests/baselines/reference/moduleResolutionWithExtensions_unexpected2.trace.json +++ b/tests/baselines/reference/moduleResolutionWithExtensions_unexpected2.trace.json @@ -2,10 +2,8 @@ "======== Resolving module 'foo' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'foo.js' that references '/node_modules/foo/foo.js'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo.ts' does not exist.", "File '/node_modules/foo.tsx' does not exist.", "File '/node_modules/foo.d.ts' does not exist.", @@ -27,10 +25,8 @@ "File '/node_modules/foo/index.d.ts' does not exist.", "Directory '/node_modules/@types' does not exist, skipping all lookups in it.", "Loading module 'foo' from 'node_modules' folder, target file type 'JavaScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'foo.js' that references '/node_modules/foo/foo.js'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo.js' does not exist.", "File '/node_modules/foo.jsx' does not exist.", "'package.json' does not have a 'main' field.", diff --git a/tests/baselines/reference/moduleResolution_packageJson_notAtPackageRoot.trace.json b/tests/baselines/reference/moduleResolution_packageJson_notAtPackageRoot.trace.json index dbd645d9d65..a0ff3e6a5f7 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_notAtPackageRoot.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_notAtPackageRoot.trace.json @@ -2,10 +2,8 @@ "======== Resolving module 'foo/bar' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo/bar' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'types.d.ts' that references '/node_modules/foo/bar/types.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/bar/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo/bar.ts' does not exist.", "File '/node_modules/foo/bar.tsx' does not exist.", "File '/node_modules/foo/bar.d.ts' does not exist.", diff --git a/tests/baselines/reference/moduleResolution_packageJson_notAtPackageRoot_fakeScopedPackage.trace.json b/tests/baselines/reference/moduleResolution_packageJson_notAtPackageRoot_fakeScopedPackage.trace.json index e47dcc86b12..ebeee4299fe 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_notAtPackageRoot_fakeScopedPackage.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_notAtPackageRoot_fakeScopedPackage.trace.json @@ -2,10 +2,8 @@ "======== Resolving module 'foo/@bar' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo/@bar' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'types.d.ts' that references '/node_modules/foo/@bar/types.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/@bar/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo/@bar.ts' does not exist.", "File '/node_modules/foo/@bar.tsx' does not exist.", "File '/node_modules/foo/@bar.d.ts' does not exist.", diff --git a/tests/baselines/reference/moduleResolution_packageJson_scopedPackage.trace.json b/tests/baselines/reference/moduleResolution_packageJson_scopedPackage.trace.json index a8e509ff6e8..959e178b57e 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_scopedPackage.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_scopedPackage.trace.json @@ -2,10 +2,8 @@ "======== Resolving module '@foo/bar' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module '@foo/bar' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'types.d.ts' that references '/node_modules/@foo/bar/types.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@foo/bar/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/@foo/bar.ts' does not exist.", "File '/node_modules/@foo/bar.tsx' does not exist.", "File '/node_modules/@foo/bar.d.ts' does not exist.", diff --git a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot.trace.json b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot.trace.json index 4a2e60d9c7f..aafca116d0b 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot.trace.json @@ -3,22 +3,31 @@ "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo/bar' from 'node_modules' folder, target file type 'TypeScript'.", "File '/node_modules/foo/bar/package.json' does not exist.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo/bar.ts' does not exist.", "File '/node_modules/foo/bar.tsx' does not exist.", "File '/node_modules/foo/bar.d.ts' does not exist.", + "'package.json' does not have a 'typings' field.", + "'package.json' has 'types' field 'types.d.ts' that references '/node_modules/foo/bar/types.d.ts'.", + "File '/node_modules/foo/bar/types.d.ts' does not exist.", + "Loading module as file / folder, candidate module location '/node_modules/foo/bar/types.d.ts', target file type 'TypeScript'.", + "File '/node_modules/foo/bar/types.d.ts.ts' does not exist.", + "File '/node_modules/foo/bar/types.d.ts.tsx' does not exist.", + "File '/node_modules/foo/bar/types.d.ts.d.ts' does not exist.", + "Directory '/node_modules/foo/bar/types.d.ts' does not exist, skipping all lookups in it.", "File '/node_modules/foo/bar/index.ts' does not exist.", "File '/node_modules/foo/bar/index.tsx' does not exist.", "File '/node_modules/foo/bar/index.d.ts' does not exist.", "Directory '/node_modules/@types' does not exist, skipping all lookups in it.", "Loading module 'foo/bar' from 'node_modules' folder, target file type 'JavaScript'.", "File '/node_modules/foo/bar/package.json' does not exist.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo/bar.js' does not exist.", "File '/node_modules/foo/bar.jsx' does not exist.", + "'package.json' does not have a 'main' field.", "File '/node_modules/foo/bar/index.js' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/foo/bar/index.js', result '/node_modules/foo/bar/index.js'.", - "======== Module name 'foo/bar' was successfully resolved to '/node_modules/foo/bar/index.js' with Package ID 'foo/bar/index.d.ts@1.2.3'. ========" + "======== Module name 'foo/bar' was successfully resolved to '/node_modules/foo/bar/index.js' with Package ID 'foo/bar/index.js@1.2.3'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_fakeScopedPackage.trace.json b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_fakeScopedPackage.trace.json index 3f2423ce832..f41b1ca0710 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_fakeScopedPackage.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_fakeScopedPackage.trace.json @@ -3,22 +3,31 @@ "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo/@bar' from 'node_modules' folder, target file type 'TypeScript'.", "File '/node_modules/foo/@bar/package.json' does not exist.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo/@bar.ts' does not exist.", "File '/node_modules/foo/@bar.tsx' does not exist.", "File '/node_modules/foo/@bar.d.ts' does not exist.", + "'package.json' does not have a 'typings' field.", + "'package.json' has 'types' field 'types.d.ts' that references '/node_modules/foo/@bar/types.d.ts'.", + "File '/node_modules/foo/@bar/types.d.ts' does not exist.", + "Loading module as file / folder, candidate module location '/node_modules/foo/@bar/types.d.ts', target file type 'TypeScript'.", + "File '/node_modules/foo/@bar/types.d.ts.ts' does not exist.", + "File '/node_modules/foo/@bar/types.d.ts.tsx' does not exist.", + "File '/node_modules/foo/@bar/types.d.ts.d.ts' does not exist.", + "Directory '/node_modules/foo/@bar/types.d.ts' does not exist, skipping all lookups in it.", "File '/node_modules/foo/@bar/index.ts' does not exist.", "File '/node_modules/foo/@bar/index.tsx' does not exist.", "File '/node_modules/foo/@bar/index.d.ts' does not exist.", "Directory '/node_modules/@types' does not exist, skipping all lookups in it.", "Loading module 'foo/@bar' from 'node_modules' folder, target file type 'JavaScript'.", "File '/node_modules/foo/@bar/package.json' does not exist.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo/@bar.js' does not exist.", "File '/node_modules/foo/@bar.jsx' does not exist.", + "'package.json' does not have a 'main' field.", "File '/node_modules/foo/@bar/index.js' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/foo/@bar/index.js', result '/node_modules/foo/@bar/index.js'.", - "======== Module name 'foo/@bar' was successfully resolved to '/node_modules/foo/@bar/index.js' with Package ID 'foo/@bar/index.d.ts@1.2.3'. ========" + "======== Module name 'foo/@bar' was successfully resolved to '/node_modules/foo/@bar/index.js' with Package ID 'foo/@bar/index.js@1.2.3'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_mainFieldInSubDirectory.trace.json b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_mainFieldInSubDirectory.trace.json index 6b373fb300f..cf2b1082bf8 100644 --- a/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_mainFieldInSubDirectory.trace.json +++ b/tests/baselines/reference/moduleResolution_packageJson_yesAtPackageRoot_mainFieldInSubDirectory.trace.json @@ -2,11 +2,8 @@ "======== Resolving module 'foo' from '/index.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'src/index.js' that references '/node_modules/foo/src/index.js'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo.ts' does not exist.", "File '/node_modules/foo.tsx' does not exist.", "File '/node_modules/foo.d.ts' does not exist.", diff --git a/tests/baselines/reference/packageJsonMain.trace.json b/tests/baselines/reference/packageJsonMain.trace.json index 1f722312e1d..2144b6eb15c 100644 --- a/tests/baselines/reference/packageJsonMain.trace.json +++ b/tests/baselines/reference/packageJsonMain.trace.json @@ -2,11 +2,8 @@ "======== Resolving module 'foo' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'oof' that references '/node_modules/foo/oof'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo.ts' does not exist.", "File '/node_modules/foo.tsx' does not exist.", "File '/node_modules/foo.d.ts' does not exist.", @@ -24,11 +21,8 @@ "File '/node_modules/foo/index.d.ts' does not exist.", "Directory '/node_modules/@types' does not exist, skipping all lookups in it.", "Loading module 'foo' from 'node_modules' folder, target file type 'JavaScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'oof' that references '/node_modules/foo/oof'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo.js' does not exist.", "File '/node_modules/foo.jsx' does not exist.", "'package.json' has 'main' field 'oof' that references '/node_modules/foo/oof'.", @@ -40,11 +34,8 @@ "======== Resolving module 'bar' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'bar' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'rab.js' that references '/node_modules/bar/rab.js'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/bar/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/bar.ts' does not exist.", "File '/node_modules/bar.tsx' does not exist.", "File '/node_modules/bar.d.ts' does not exist.", @@ -67,11 +58,8 @@ "File '/node_modules/bar/index.d.ts' does not exist.", "Directory '/node_modules/@types' does not exist, skipping all lookups in it.", "Loading module 'bar' from 'node_modules' folder, target file type 'JavaScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'rab.js' that references '/node_modules/bar/rab.js'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/bar/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/bar.js' does not exist.", "File '/node_modules/bar.jsx' does not exist.", "'package.json' has 'main' field 'rab.js' that references '/node_modules/bar/rab.js'.", @@ -81,11 +69,8 @@ "======== Resolving module 'baz' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'baz' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'zab' that references '/node_modules/baz/zab'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/baz/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/baz.ts' does not exist.", "File '/node_modules/baz.tsx' does not exist.", "File '/node_modules/baz.d.ts' does not exist.", @@ -105,11 +90,8 @@ "File '/node_modules/baz/index.d.ts' does not exist.", "Directory '/node_modules/@types' does not exist, skipping all lookups in it.", "Loading module 'baz' from 'node_modules' folder, target file type 'JavaScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'zab' that references '/node_modules/baz/zab'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/baz/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/baz.js' does not exist.", "File '/node_modules/baz.jsx' does not exist.", "'package.json' has 'main' field 'zab' that references '/node_modules/baz/zab'.", diff --git a/tests/baselines/reference/packageJsonMain_isNonRecursive.trace.json b/tests/baselines/reference/packageJsonMain_isNonRecursive.trace.json index f2f16ec6aeb..5bdd8a7e90c 100644 --- a/tests/baselines/reference/packageJsonMain_isNonRecursive.trace.json +++ b/tests/baselines/reference/packageJsonMain_isNonRecursive.trace.json @@ -2,11 +2,8 @@ "======== Resolving module 'foo' from '/a.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'foo' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'oof' that references '/node_modules/foo/oof'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo.ts' does not exist.", "File '/node_modules/foo.tsx' does not exist.", "File '/node_modules/foo.d.ts' does not exist.", @@ -26,11 +23,8 @@ "File '/node_modules/foo/index.d.ts' does not exist.", "Directory '/node_modules/@types' does not exist, skipping all lookups in it.", "Loading module 'foo' from 'node_modules' folder, target file type 'JavaScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' has 'main' field 'oof' that references '/node_modules/foo/oof'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/foo/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/foo.js' does not exist.", "File '/node_modules/foo.jsx' does not exist.", "'package.json' has 'main' field 'oof' that references '/node_modules/foo/oof'.", diff --git a/tests/baselines/reference/typesVersions.ambientModules.trace.json b/tests/baselines/reference/typesVersions.ambientModules.trace.json index dcaf6acc096..53de9ae651e 100644 --- a/tests/baselines/reference/typesVersions.ambientModules.trace.json +++ b/tests/baselines/reference/typesVersions.ambientModules.trace.json @@ -2,10 +2,8 @@ "======== Resolving module 'ext' from 'tests/cases/conformance/moduleResolution/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/moduleResolution/node_modules/ext/index'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.d.ts' does not exist.", @@ -20,18 +18,20 @@ "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/ts3.1/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/moduleResolution/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.ts' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts' does not exist.", + "'package.json' does not have a 'typings' field.", + "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other/index'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'index'.", "Module name 'index', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.", @@ -43,13 +43,14 @@ "Directory 'node_modules' does not exist, skipping all lookups in it.", "Directory '/node_modules' does not exist, skipping all lookups in it.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'JavaScript'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.js' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.jsx' does not exist.", + "'package.json' does not have a 'main' field.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'index'.", "Module name 'index', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.", diff --git a/tests/baselines/reference/typesVersions.justIndex.trace.json b/tests/baselines/reference/typesVersions.justIndex.trace.json index 28e4a5cb3bf..263d16b0b4b 100644 --- a/tests/baselines/reference/typesVersions.justIndex.trace.json +++ b/tests/baselines/reference/typesVersions.justIndex.trace.json @@ -7,11 +7,8 @@ "File '/a.ts' does not exist.", "File '/a.tsx' does not exist.", "File '/a.d.ts' does not exist.", - "'package.json' does not have a 'typings' field.", - "'package.json' does not have a 'types' field.", - "'package.json' does not have a 'main' field.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at '/a/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' does not have a 'typings' field.", "'package.json' does not have a 'types' field.", "'package.json' does not have a 'main' field.", diff --git a/tests/baselines/reference/typesVersions.multiFile.trace.json b/tests/baselines/reference/typesVersions.multiFile.trace.json index 71975474092..d487d352948 100644 --- a/tests/baselines/reference/typesVersions.multiFile.trace.json +++ b/tests/baselines/reference/typesVersions.multiFile.trace.json @@ -2,10 +2,8 @@ "======== Resolving module 'ext' from 'tests/cases/conformance/moduleResolution/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/moduleResolution/node_modules/ext/index'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext.d.ts' does not exist.", @@ -20,12 +18,12 @@ "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/ts3.1/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/moduleResolution/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", @@ -33,5 +31,5 @@ "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.tsx' does not exist.", "File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts'.", - "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/other/index.d.ts@1.0.0'. ========" + "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/ts3.1/other.d.ts@1.0.0'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/typesVersionsDeclarationEmit.ambient.trace.json b/tests/baselines/reference/typesVersionsDeclarationEmit.ambient.trace.json index 5d5009e8a41..97972b9d1f6 100644 --- a/tests/baselines/reference/typesVersionsDeclarationEmit.ambient.trace.json +++ b/tests/baselines/reference/typesVersionsDeclarationEmit.ambient.trace.json @@ -2,10 +2,8 @@ "======== Resolving module 'ext' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.", @@ -20,18 +18,20 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/ts3.1/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' does not exist.", + "'package.json' does not have a 'typings' field.", + "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other/index'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'index'.", "Module name 'index', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.", @@ -43,13 +43,14 @@ "Directory 'node_modules' does not exist, skipping all lookups in it.", "Directory '/node_modules' does not exist, skipping all lookups in it.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'JavaScript'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.js' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.jsx' does not exist.", + "'package.json' does not have a 'main' field.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'index'.", "Module name 'index', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.", diff --git a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFile.trace.json b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFile.trace.json index 9fb9c48332a..224839cf26d 100644 --- a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFile.trace.json +++ b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFile.trace.json @@ -2,10 +2,8 @@ "======== Resolving module 'ext' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.", @@ -20,12 +18,12 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/ts3.1/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", @@ -33,5 +31,5 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'.", - "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/other/index.d.ts@1.0.0'. ========" + "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/ts3.1/other.d.ts@1.0.0'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.trace.json b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.trace.json index 6deb7327c99..a89df5a6dfe 100644 --- a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.trace.json +++ b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.trace.json @@ -2,10 +2,8 @@ "======== Resolving module '../' from 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/', target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' does not have a 'typings' field.", "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'index'.", @@ -16,23 +14,21 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", - "======== Module name '../' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/ndex/index.d.ts@1.0.0'. ========", + "======== Module name '../' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/s3.1/index.d.ts@1.0.0'. ========", "======== Resolving module '../other' from 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/other', target file type 'TypeScript'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "======== Module name '../other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' with Package ID 'ext/other.d.ts@1.0.0'. ========", "======== Resolving module 'ext' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.", @@ -47,12 +43,12 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/ts3.1/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "Module name 'other', matched pattern '*'.", "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.", @@ -60,5 +56,5 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'.", - "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/other/index.d.ts@1.0.0'. ========" + "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' with Package ID 'ext/ts3.1/other.d.ts@1.0.0'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.trace.json b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.trace.json index 94f15e64260..7da95cd402c 100644 --- a/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.trace.json +++ b/tests/baselines/reference/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.trace.json @@ -5,16 +5,14 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "======== Module name '../other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' with Package ID 'ext/other.d.ts@1.0.0'. ========", "======== Resolving module 'ext' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' does not have a 'typings' field.", - "'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.", @@ -29,16 +27,16 @@ "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.", - "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/index.d.ts@1.0.0'. ========", + "======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' with Package ID 'ext/ts3.1/index.d.ts@1.0.0'. ========", "======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========", "Module resolution kind is not specified, using 'NodeJs'.", "Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.", - "'package.json' has a 'typesVersions' field with version-specific path mappings.", "Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'other'.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.ts' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.", "File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.", "Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'.", - "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' with Package ID 'ext/other/index.d.ts@1.0.0'. ========" + "======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' with Package ID 'ext/other.d.ts@1.0.0'. ========" ] \ No newline at end of file diff --git a/tests/baselines/reference/typingsLookup4.trace.json b/tests/baselines/reference/typingsLookup4.trace.json index 6409896ad17..3ce97d9d8c9 100644 --- a/tests/baselines/reference/typingsLookup4.trace.json +++ b/tests/baselines/reference/typingsLookup4.trace.json @@ -5,9 +5,8 @@ "File '/node_modules/jquery.ts' does not exist.", "File '/node_modules/jquery.tsx' does not exist.", "File '/node_modules/jquery.d.ts' does not exist.", - "'package.json' has 'typings' field 'jquery.d.ts' that references '/node_modules/@types/jquery/jquery.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@types/jquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/@types/jquery.d.ts' does not exist.", "'package.json' has 'typings' field 'jquery.d.ts' that references '/node_modules/@types/jquery/jquery.d.ts'.", "File '/node_modules/@types/jquery/jquery.d.ts' exist - use it as a name resolution result.", @@ -19,9 +18,8 @@ "File '/node_modules/kquery.ts' does not exist.", "File '/node_modules/kquery.tsx' does not exist.", "File '/node_modules/kquery.d.ts' does not exist.", - "'package.json' has 'typings' field 'kquery' that references '/node_modules/@types/kquery/kquery'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@types/kquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/@types/kquery.d.ts' does not exist.", "'package.json' has 'typings' field 'kquery' that references '/node_modules/@types/kquery/kquery'.", "File '/node_modules/@types/kquery/kquery' does not exist.", @@ -37,9 +35,8 @@ "File '/node_modules/lquery.ts' does not exist.", "File '/node_modules/lquery.tsx' does not exist.", "File '/node_modules/lquery.d.ts' does not exist.", - "'package.json' has 'typings' field 'lquery' that references '/node_modules/@types/lquery/lquery'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@types/lquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/@types/lquery.d.ts' does not exist.", "'package.json' has 'typings' field 'lquery' that references '/node_modules/@types/lquery/lquery'.", "File '/node_modules/@types/lquery/lquery' does not exist.", @@ -53,9 +50,8 @@ "File '/node_modules/mquery.ts' does not exist.", "File '/node_modules/mquery.tsx' does not exist.", "File '/node_modules/mquery.d.ts' does not exist.", - "'package.json' has 'typings' field 'mquery' that references '/node_modules/@types/mquery/mquery'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@types/mquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "File '/node_modules/@types/mquery.d.ts' does not exist.", "'package.json' has 'typings' field 'mquery' that references '/node_modules/@types/mquery/mquery'.", "File '/node_modules/@types/mquery/mquery' does not exist.", @@ -69,18 +65,16 @@ "======== Module name 'mquery' was successfully resolved to '/node_modules/@types/mquery/mquery/index.tsx'. ========", "======== Resolving type reference directive 'jquery', containing file '/__inferred type names__.ts', root directory '/node_modules/@types'. ========", "Resolving with primary search path '/node_modules/@types'.", - "'package.json' has 'typings' field 'jquery.d.ts' that references '/node_modules/@types/jquery/jquery.d.ts'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@types/jquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "'package.json' has 'typings' field 'jquery.d.ts' that references '/node_modules/@types/jquery/jquery.d.ts'.", "File '/node_modules/@types/jquery/jquery.d.ts' exist - use it as a name resolution result.", "Resolving real path for '/node_modules/@types/jquery/jquery.d.ts', result '/node_modules/@types/jquery/jquery.d.ts'.", "======== Type reference directive 'jquery' was successfully resolved to '/node_modules/@types/jquery/jquery.d.ts', primary: true. ========", "======== Resolving type reference directive 'kquery', containing file '/__inferred type names__.ts', root directory '/node_modules/@types'. ========", "Resolving with primary search path '/node_modules/@types'.", - "'package.json' has 'typings' field 'kquery' that references '/node_modules/@types/kquery/kquery'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@types/kquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "'package.json' has 'typings' field 'kquery' that references '/node_modules/@types/kquery/kquery'.", "File '/node_modules/@types/kquery/kquery' does not exist.", "Loading module as file / folder, candidate module location '/node_modules/@types/kquery/kquery', target file type 'TypeScript'.", @@ -91,9 +85,8 @@ "======== Type reference directive 'kquery' was successfully resolved to '/node_modules/@types/kquery/kquery.d.ts', primary: true. ========", "======== Resolving type reference directive 'lquery', containing file '/__inferred type names__.ts', root directory '/node_modules/@types'. ========", "Resolving with primary search path '/node_modules/@types'.", - "'package.json' has 'typings' field 'lquery' that references '/node_modules/@types/lquery/lquery'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@types/lquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "'package.json' has 'typings' field 'lquery' that references '/node_modules/@types/lquery/lquery'.", "File '/node_modules/@types/lquery/lquery' does not exist.", "Loading module as file / folder, candidate module location '/node_modules/@types/lquery/lquery', target file type 'TypeScript'.", @@ -102,9 +95,8 @@ "======== Type reference directive 'lquery' was successfully resolved to '/node_modules/@types/lquery/lquery.ts', primary: true. ========", "======== Resolving type reference directive 'mquery', containing file '/__inferred type names__.ts', root directory '/node_modules/@types'. ========", "Resolving with primary search path '/node_modules/@types'.", - "'package.json' has 'typings' field 'mquery' that references '/node_modules/@types/mquery/mquery'.", - "'package.json' does not have a 'typesVersions' field.", "Found 'package.json' at '/node_modules/@types/mquery/package.json'.", + "'package.json' does not have a 'typesVersions' field.", "'package.json' has 'typings' field 'mquery' that references '/node_modules/@types/mquery/mquery'.", "File '/node_modules/@types/mquery/mquery' does not exist.", "Loading module as file / folder, candidate module location '/node_modules/@types/mquery/mquery', target file type 'TypeScript'.", From 9f6791a5abef5d9e8161de6c7bc545a65fa3fe7c Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Wed, 22 May 2019 15:03:17 -0700 Subject: [PATCH 091/119] Error when writing to readonly tuple in rest element range --- src/compiler/checker.ts | 15 ++--- .../readonlyArraysAndTuples.errors.txt | 32 ++++++++++- .../reference/readonlyArraysAndTuples.js | 17 ++++++ .../reference/readonlyArraysAndTuples.symbols | 26 +++++++++ .../reference/readonlyArraysAndTuples.types | 56 +++++++++++++++++++ .../types/tuple/readonlyArraysAndTuples.ts | 12 ++-- 6 files changed, 145 insertions(+), 13 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 05b1015b124..dd3a67d0938 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -10101,6 +10101,7 @@ namespace ts { error(indexNode, Diagnostics.Property_0_does_not_exist_on_type_1, unescapeLeadingUnderscores(propName), typeToString(objectType)); } } + errorIfWritingToReadonlyIndex(getIndexInfoOfType(objectType, IndexKind.Number)); return mapType(objectType, t => getRestTypeOfTupleType(t) || undefinedType); } } @@ -10122,13 +10123,7 @@ namespace ts { error(indexNode, Diagnostics.Type_0_cannot_be_used_as_an_index_type, typeToString(indexType)); return indexInfo.type; } - if (indexInfo.isReadonly && accessExpression && (isAssignmentTarget(accessExpression) || isDeleteTarget(accessExpression))) { - if (accessExpression) { - error(accessExpression, Diagnostics.Index_signature_in_type_0_only_permits_reading, typeToString(objectType)); - return indexInfo.type; - } - return undefined; - } + errorIfWritingToReadonlyIndex(indexInfo); return indexInfo.type; } if (indexType.flags & TypeFlags.Never) { @@ -10188,6 +10183,12 @@ namespace ts { return indexType; } return undefined; + + function errorIfWritingToReadonlyIndex(indexInfo: IndexInfo | undefined): void { + if (indexInfo && indexInfo.isReadonly && accessExpression && (isAssignmentTarget(accessExpression) || isDeleteTarget(accessExpression))) { + error(accessExpression, Diagnostics.Index_signature_in_type_0_only_permits_reading, typeToString(objectType)); + } + } } function getIndexNodeForAccessExpression(accessNode: ElementAccessExpression | IndexedAccessTypeNode | PropertyName | BindingName | SyntheticExpression) { diff --git a/tests/baselines/reference/readonlyArraysAndTuples.errors.txt b/tests/baselines/reference/readonlyArraysAndTuples.errors.txt index 3680b78bb1b..39f377f4ee9 100644 --- a/tests/baselines/reference/readonlyArraysAndTuples.errors.txt +++ b/tests/baselines/reference/readonlyArraysAndTuples.errors.txt @@ -9,9 +9,16 @@ tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(22,5): error TS27 tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(23,5): error TS4104: The type 'readonly [string, string]' is 'readonly' and cannot be assigned to the mutable type '[string, string]'. tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(24,5): error TS2739: Type 'string[]' is missing the following properties from type 'readonly [string, string]': 0, 1 tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(25,5): error TS2739: Type 'readonly string[]' is missing the following properties from type 'readonly [string, string]': 0, 1 +tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(30,3): error TS2540: Cannot assign to '0' because it is a read-only property. +tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(31,3): error TS2540: Cannot assign to '1' because it is a read-only property. +tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(32,1): error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. +tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(33,8): error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. +tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(34,1): error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. +tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(35,1): error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. +tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(36,8): error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. -==== tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts (11 errors) ==== +==== tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts (18 errors) ==== type T10 = string[]; type T11 = Array; type T12 = readonly string[]; @@ -61,4 +68,27 @@ tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts(25,5): error TS27 !!! error TS2739: Type 'readonly string[]' is missing the following properties from type 'readonly [string, string]': 0, 1 rt = mt; } + + declare var v: readonly[number, number, ...number[]]; + v[0] = 1; // Error + ~ +!!! error TS2540: Cannot assign to '0' because it is a read-only property. + v[1] = 1; // Error + ~ +!!! error TS2540: Cannot assign to '1' because it is a read-only property. + v[2] = 1; // Error + ~~~~ +!!! error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. + delete v[2]; // Error + ~~~~ +!!! error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. + v[0 + 1] = 1; // Error + ~~~~~~~~ +!!! error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. + v[0 + 2] = 1; // Error + ~~~~~~~~ +!!! error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. + delete v[0 + 1]; // Error + ~~~~~~~~ +!!! error TS2542: Index signature in type 'readonly [number, number, ...number[]]' only permits reading. \ No newline at end of file diff --git a/tests/baselines/reference/readonlyArraysAndTuples.js b/tests/baselines/reference/readonlyArraysAndTuples.js index 0ba392dadb4..f293ad01b7b 100644 --- a/tests/baselines/reference/readonlyArraysAndTuples.js +++ b/tests/baselines/reference/readonlyArraysAndTuples.js @@ -26,6 +26,15 @@ function f1(ma: string[], ra: readonly string[], mt: [string, string], rt: reado rt = ra; // Error rt = mt; } + +declare var v: readonly[number, number, ...number[]]; +v[0] = 1; // Error +v[1] = 1; // Error +v[2] = 1; // Error +delete v[2]; // Error +v[0 + 1] = 1; // Error +v[0 + 2] = 1; // Error +delete v[0 + 1]; // Error //// [readonlyArraysAndTuples.js] @@ -44,6 +53,13 @@ function f1(ma, ra, mt, rt) { rt = ra; // Error rt = mt; } +v[0] = 1; // Error +v[1] = 1; // Error +v[2] = 1; // Error +delete v[2]; // Error +v[0 + 1] = 1; // Error +v[0 + 2] = 1; // Error +delete v[0 + 1]; // Error //// [readonlyArraysAndTuples.d.ts] @@ -58,3 +74,4 @@ declare type T31 = readonly T; declare type T32 = readonly readonly string[]; declare type T33 = readonly Array; declare function f1(ma: string[], ra: readonly string[], mt: [string, string], rt: readonly [string, string]): void; +declare var v: readonly [number, number, ...number[]]; diff --git a/tests/baselines/reference/readonlyArraysAndTuples.symbols b/tests/baselines/reference/readonlyArraysAndTuples.symbols index c7c371af0d8..53b425fec09 100644 --- a/tests/baselines/reference/readonlyArraysAndTuples.symbols +++ b/tests/baselines/reference/readonlyArraysAndTuples.symbols @@ -90,3 +90,29 @@ function f1(ma: string[], ra: readonly string[], mt: [string, string], rt: reado >mt : Symbol(mt, Decl(readonlyArraysAndTuples.ts, 13, 48)) } +declare var v: readonly[number, number, ...number[]]; +>v : Symbol(v, Decl(readonlyArraysAndTuples.ts, 28, 11)) + +v[0] = 1; // Error +>v : Symbol(v, Decl(readonlyArraysAndTuples.ts, 28, 11)) +>0 : Symbol(0) + +v[1] = 1; // Error +>v : Symbol(v, Decl(readonlyArraysAndTuples.ts, 28, 11)) +>1 : Symbol(1) + +v[2] = 1; // Error +>v : Symbol(v, Decl(readonlyArraysAndTuples.ts, 28, 11)) + +delete v[2]; // Error +>v : Symbol(v, Decl(readonlyArraysAndTuples.ts, 28, 11)) + +v[0 + 1] = 1; // Error +>v : Symbol(v, Decl(readonlyArraysAndTuples.ts, 28, 11)) + +v[0 + 2] = 1; // Error +>v : Symbol(v, Decl(readonlyArraysAndTuples.ts, 28, 11)) + +delete v[0 + 1]; // Error +>v : Symbol(v, Decl(readonlyArraysAndTuples.ts, 28, 11)) + diff --git a/tests/baselines/reference/readonlyArraysAndTuples.types b/tests/baselines/reference/readonlyArraysAndTuples.types index 9ffb409d526..5075319ef95 100644 --- a/tests/baselines/reference/readonlyArraysAndTuples.types +++ b/tests/baselines/reference/readonlyArraysAndTuples.types @@ -97,3 +97,59 @@ function f1(ma: string[], ra: readonly string[], mt: [string, string], rt: reado >mt : [string, string] } +declare var v: readonly[number, number, ...number[]]; +>v : readonly [number, number, ...number[]] + +v[0] = 1; // Error +>v[0] = 1 : 1 +>v[0] : any +>v : readonly [number, number, ...number[]] +>0 : 0 +>1 : 1 + +v[1] = 1; // Error +>v[1] = 1 : 1 +>v[1] : any +>v : readonly [number, number, ...number[]] +>1 : 1 +>1 : 1 + +v[2] = 1; // Error +>v[2] = 1 : 1 +>v[2] : number +>v : readonly [number, number, ...number[]] +>2 : 2 +>1 : 1 + +delete v[2]; // Error +>delete v[2] : boolean +>v[2] : number +>v : readonly [number, number, ...number[]] +>2 : 2 + +v[0 + 1] = 1; // Error +>v[0 + 1] = 1 : 1 +>v[0 + 1] : number +>v : readonly [number, number, ...number[]] +>0 + 1 : number +>0 : 0 +>1 : 1 +>1 : 1 + +v[0 + 2] = 1; // Error +>v[0 + 2] = 1 : 1 +>v[0 + 2] : number +>v : readonly [number, number, ...number[]] +>0 + 2 : number +>0 : 0 +>2 : 2 +>1 : 1 + +delete v[0 + 1]; // Error +>delete v[0 + 1] : boolean +>v[0 + 1] : number +>v : readonly [number, number, ...number[]] +>0 + 1 : number +>0 : 0 +>1 : 1 + diff --git a/tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts b/tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts index 35c86175a0b..6cfdad0d5c4 100644 --- a/tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts +++ b/tests/cases/conformance/types/tuple/readonlyArraysAndTuples.ts @@ -30,8 +30,10 @@ function f1(ma: string[], ra: readonly string[], mt: [string, string], rt: reado } declare var v: readonly[number, number, ...number[]]; -v[0] = 1; // Error -v[1] = 1; // Error -v[2] = 1; // Error -v[0 + 1] = 1; // Error -v[0 + 2] = 1; // Error +v[0] = 1; // Error +v[1] = 1; // Error +v[2] = 1; // Error +delete v[2]; // Error +v[0 + 1] = 1; // Error +v[0 + 2] = 1; // Error +delete v[0 + 1]; // Error From cd7a14ac21974209fc870642e6d1489a66f91af1 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 22 May 2019 17:22:33 -0700 Subject: [PATCH 092/119] Reuse getSimplifiedTypeOrConstraint function --- src/compiler/checker.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index bd8d4c05901..386beb7f24d 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -13066,8 +13066,7 @@ namespace ts { } // A type S is assignable to keyof T if S is assignable to keyof C, where C is the // simplified form of T or, if T doesn't simplify, the constraint of T. - const simplified = getSimplifiedType((target).type, /*writing*/ false); - const constraint = simplified !== (target).type ? simplified : getConstraintOfType((target).type); + const constraint = getSimplifiedTypeOrConstraint((target).type); if (constraint) { // We require Ternary.True here such that circular constraints don't cause // false positives. For example, given 'T extends { [K in keyof T]: string }', From 300cbef07105247ec1c826de9d785bfc72849103 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Wed, 22 May 2019 17:42:05 -0700 Subject: [PATCH 093/119] =?UTF-8?q?Don=E2=80=99t=20crash=20when=20creating?= =?UTF-8?q?=20a=20union=20signature=20from=20signatures=20that=20do=20and?= =?UTF-8?q?=20don=E2=80=99t=20have=20this=20types?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/compiler/checker.ts | 6 ++-- .../reference/unionTypeCallSignatures5.js | 17 ++++++++++ .../unionTypeCallSignatures5.symbols | 31 +++++++++++++++++++ .../reference/unionTypeCallSignatures5.types | 24 ++++++++++++++ .../types/union/unionTypeCallSignatures5.ts | 12 +++++++ 5 files changed, 87 insertions(+), 3 deletions(-) create mode 100644 tests/baselines/reference/unionTypeCallSignatures5.js create mode 100644 tests/baselines/reference/unionTypeCallSignatures5.symbols create mode 100644 tests/baselines/reference/unionTypeCallSignatures5.types create mode 100644 tests/cases/conformance/types/union/unionTypeCallSignatures5.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 05b1015b124..936c73ee9a0 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -7052,10 +7052,10 @@ namespace ts { // Union the result types when more than one signature matches if (unionSignatures.length > 1) { let thisParameter = signature.thisParameter; - if (forEach(unionSignatures, sig => sig.thisParameter)) { - // TODO: GH#18217 We tested that *some* has thisParameter and now act as if *all* do + const firstThisParameterOfUnionSignatures = forEach(unionSignatures, sig => sig.thisParameter); + if (firstThisParameterOfUnionSignatures) { const thisType = getUnionType(map(unionSignatures, sig => sig.thisParameter ? getTypeOfSymbol(sig.thisParameter) : anyType), UnionReduction.Subtype); - thisParameter = createSymbolWithType(signature.thisParameter!, thisType); + thisParameter = createSymbolWithType(firstThisParameterOfUnionSignatures, thisType); } s = createUnionSignature(signature, unionSignatures); s.thisParameter = thisParameter; diff --git a/tests/baselines/reference/unionTypeCallSignatures5.js b/tests/baselines/reference/unionTypeCallSignatures5.js new file mode 100644 index 00000000000..2e756540d94 --- /dev/null +++ b/tests/baselines/reference/unionTypeCallSignatures5.js @@ -0,0 +1,17 @@ +//// [unionTypeCallSignatures5.ts] +// #31485 +interface A { + (this: void, b?: number): void; +} +interface B { + (this: number, b?: number): void; +} +interface C { + (i: number): void; +} +declare const fn: A | B | C; +fn(0); + + +//// [unionTypeCallSignatures5.js] +fn(0); diff --git a/tests/baselines/reference/unionTypeCallSignatures5.symbols b/tests/baselines/reference/unionTypeCallSignatures5.symbols new file mode 100644 index 00000000000..d729dcd7aba --- /dev/null +++ b/tests/baselines/reference/unionTypeCallSignatures5.symbols @@ -0,0 +1,31 @@ +=== tests/cases/conformance/types/union/unionTypeCallSignatures5.ts === +// #31485 +interface A { +>A : Symbol(A, Decl(unionTypeCallSignatures5.ts, 0, 0)) + + (this: void, b?: number): void; +>this : Symbol(this, Decl(unionTypeCallSignatures5.ts, 2, 3)) +>b : Symbol(b, Decl(unionTypeCallSignatures5.ts, 2, 14)) +} +interface B { +>B : Symbol(B, Decl(unionTypeCallSignatures5.ts, 3, 1)) + + (this: number, b?: number): void; +>this : Symbol(this, Decl(unionTypeCallSignatures5.ts, 5, 3)) +>b : Symbol(b, Decl(unionTypeCallSignatures5.ts, 5, 16)) +} +interface C { +>C : Symbol(C, Decl(unionTypeCallSignatures5.ts, 6, 1)) + + (i: number): void; +>i : Symbol(i, Decl(unionTypeCallSignatures5.ts, 8, 3)) +} +declare const fn: A | B | C; +>fn : Symbol(fn, Decl(unionTypeCallSignatures5.ts, 10, 13)) +>A : Symbol(A, Decl(unionTypeCallSignatures5.ts, 0, 0)) +>B : Symbol(B, Decl(unionTypeCallSignatures5.ts, 3, 1)) +>C : Symbol(C, Decl(unionTypeCallSignatures5.ts, 6, 1)) + +fn(0); +>fn : Symbol(fn, Decl(unionTypeCallSignatures5.ts, 10, 13)) + diff --git a/tests/baselines/reference/unionTypeCallSignatures5.types b/tests/baselines/reference/unionTypeCallSignatures5.types new file mode 100644 index 00000000000..53ce4ea6550 --- /dev/null +++ b/tests/baselines/reference/unionTypeCallSignatures5.types @@ -0,0 +1,24 @@ +=== tests/cases/conformance/types/union/unionTypeCallSignatures5.ts === +// #31485 +interface A { + (this: void, b?: number): void; +>this : void +>b : number +} +interface B { + (this: number, b?: number): void; +>this : number +>b : number +} +interface C { + (i: number): void; +>i : number +} +declare const fn: A | B | C; +>fn : A | B | C + +fn(0); +>fn(0) : void +>fn : A | B | C +>0 : 0 + diff --git a/tests/cases/conformance/types/union/unionTypeCallSignatures5.ts b/tests/cases/conformance/types/union/unionTypeCallSignatures5.ts new file mode 100644 index 00000000000..30a5ac031ad --- /dev/null +++ b/tests/cases/conformance/types/union/unionTypeCallSignatures5.ts @@ -0,0 +1,12 @@ +// #31485 +interface A { + (this: void, b?: number): void; +} +interface B { + (this: number, b?: number): void; +} +interface C { + (i: number): void; +} +declare const fn: A | B | C; +fn(0); From 4d27361680796581f3f4fd5aedadff69b120470b Mon Sep 17 00:00:00 2001 From: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com> Date: Thu, 23 May 2019 11:09:28 -0700 Subject: [PATCH 094/119] Allow JS with isolated modules (#31483) * Allow JS with isolated modules Previously legacy JS code was not allowed; it was required to use ES6 module syntax. Unfortunately, the check happens after parsing but before binding, and the commonjs module indicator isn't set until binding because it's not syntactically simple like the ES6 module indicator, which is set during parsing. So I decided that JS should be allowed during isolatedModules unconditionally. We're not going to be transforming it anyway. * Update baselines * Switch test to outDir instead of noEmit --- src/compiler/diagnosticMessages.json | 2 +- src/compiler/program.ts | 4 ++-- tests/baselines/reference/commonJsIsolatedModules.js | 8 ++++++++ .../reference/commonJsIsolatedModules.symbols | 9 +++++++++ .../reference/commonJsIsolatedModules.types | 12 ++++++++++++ .../importHelpersInIsolatedModules.errors.txt | 4 ++-- .../isolatedModulesNoExternalModule.errors.txt | 4 ++-- .../reference/isolatedModulesOut.errors.txt | 4 ++-- .../isolatedModulesPlainFile-AMD.errors.txt | 4 ++-- .../isolatedModulesPlainFile-CommonJS.errors.txt | 4 ++-- .../isolatedModulesPlainFile-ES6.errors.txt | 4 ++-- .../isolatedModulesPlainFile-System.errors.txt | 4 ++-- .../isolatedModulesPlainFile-UMD.errors.txt | 4 ++-- tests/cases/compiler/commonJsIsolatedModules.ts | 12 ++++++++++++ 14 files changed, 60 insertions(+), 19 deletions(-) create mode 100644 tests/baselines/reference/commonJsIsolatedModules.js create mode 100644 tests/baselines/reference/commonJsIsolatedModules.symbols create mode 100644 tests/baselines/reference/commonJsIsolatedModules.types create mode 100644 tests/cases/compiler/commonJsIsolatedModules.ts diff --git a/src/compiler/diagnosticMessages.json b/src/compiler/diagnosticMessages.json index e8784e7d1f2..101b584ca13 100644 --- a/src/compiler/diagnosticMessages.json +++ b/src/compiler/diagnosticMessages.json @@ -655,7 +655,7 @@ "category": "Error", "code": 1207 }, - "Cannot compile namespaces when the '--isolatedModules' flag is provided.": { + "All files must be modules when the '--isolatedModules' flag is provided.": { "category": "Error", "code": 1208 }, diff --git a/src/compiler/program.ts b/src/compiler/program.ts index 6313cc19902..8e4cd48b5ba 100644 --- a/src/compiler/program.ts +++ b/src/compiler/program.ts @@ -2858,10 +2858,10 @@ namespace ts { createDiagnosticForOptionName(Diagnostics.Option_isolatedModules_can_only_be_used_when_either_option_module_is_provided_or_option_target_is_ES2015_or_higher, "isolatedModules", "target"); } - const firstNonExternalModuleSourceFile = find(files, f => !isExternalModule(f) && !f.isDeclarationFile && f.scriptKind !== ScriptKind.JSON); + const firstNonExternalModuleSourceFile = find(files, f => !isExternalModule(f) && !isSourceFileJS(f) && !f.isDeclarationFile && f.scriptKind !== ScriptKind.JSON); if (firstNonExternalModuleSourceFile) { const span = getErrorSpanForNode(firstNonExternalModuleSourceFile, firstNonExternalModuleSourceFile); - programDiagnostics.add(createFileDiagnostic(firstNonExternalModuleSourceFile, span.start, span.length, Diagnostics.Cannot_compile_namespaces_when_the_isolatedModules_flag_is_provided)); + programDiagnostics.add(createFileDiagnostic(firstNonExternalModuleSourceFile, span.start, span.length, Diagnostics.All_files_must_be_modules_when_the_isolatedModules_flag_is_provided)); } } else if (firstNonAmbientExternalModuleSourceFile && languageVersion < ScriptTarget.ES2015 && options.module === ModuleKind.None) { diff --git a/tests/baselines/reference/commonJsIsolatedModules.js b/tests/baselines/reference/commonJsIsolatedModules.js new file mode 100644 index 00000000000..fe983eec37a --- /dev/null +++ b/tests/baselines/reference/commonJsIsolatedModules.js @@ -0,0 +1,8 @@ +//// [index.js] +module.exports = {} +var x = 1 + + +//// [index.js] +module.exports = {}; +var x = 1; diff --git a/tests/baselines/reference/commonJsIsolatedModules.symbols b/tests/baselines/reference/commonJsIsolatedModules.symbols new file mode 100644 index 00000000000..f0f9d0d7855 --- /dev/null +++ b/tests/baselines/reference/commonJsIsolatedModules.symbols @@ -0,0 +1,9 @@ +=== tests/cases/compiler/index.js === +module.exports = {} +>module.exports : Symbol("tests/cases/compiler/index", Decl(index.js, 0, 0)) +>module : Symbol(module, Decl(index.js, 0, 0)) +>exports : Symbol("tests/cases/compiler/index", Decl(index.js, 0, 0)) + +var x = 1 +>x : Symbol(x, Decl(index.js, 1, 3)) + diff --git a/tests/baselines/reference/commonJsIsolatedModules.types b/tests/baselines/reference/commonJsIsolatedModules.types new file mode 100644 index 00000000000..363b450cef9 --- /dev/null +++ b/tests/baselines/reference/commonJsIsolatedModules.types @@ -0,0 +1,12 @@ +=== tests/cases/compiler/index.js === +module.exports = {} +>module.exports = {} : typeof import("tests/cases/compiler/index") +>module.exports : typeof import("tests/cases/compiler/index") +>module : { "tests/cases/compiler/index": typeof import("tests/cases/compiler/index"); } +>exports : typeof import("tests/cases/compiler/index") +>{} : {} + +var x = 1 +>x : number +>1 : 1 + diff --git a/tests/baselines/reference/importHelpersInIsolatedModules.errors.txt b/tests/baselines/reference/importHelpersInIsolatedModules.errors.txt index 7a53c1c8c99..9655daa3325 100644 --- a/tests/baselines/reference/importHelpersInIsolatedModules.errors.txt +++ b/tests/baselines/reference/importHelpersInIsolatedModules.errors.txt @@ -1,4 +1,4 @@ -tests/cases/compiler/script.ts(1,1): error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +tests/cases/compiler/script.ts(1,1): error TS1208: All files must be modules when the '--isolatedModules' flag is provided. ==== tests/cases/compiler/external.ts (0 errors) ==== @@ -16,7 +16,7 @@ tests/cases/compiler/script.ts(1,1): error TS1208: Cannot compile namespaces whe ==== tests/cases/compiler/script.ts (1 errors) ==== class A { } ~~~~~ -!!! error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +!!! error TS1208: All files must be modules when the '--isolatedModules' flag is provided. class B extends A { } declare var dec: any; diff --git a/tests/baselines/reference/isolatedModulesNoExternalModule.errors.txt b/tests/baselines/reference/isolatedModulesNoExternalModule.errors.txt index 6d0f12bb1ab..2ca0a1139fb 100644 --- a/tests/baselines/reference/isolatedModulesNoExternalModule.errors.txt +++ b/tests/baselines/reference/isolatedModulesNoExternalModule.errors.txt @@ -1,7 +1,7 @@ -tests/cases/compiler/file1.ts(1,1): error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +tests/cases/compiler/file1.ts(1,1): error TS1208: All files must be modules when the '--isolatedModules' flag is provided. ==== tests/cases/compiler/file1.ts (1 errors) ==== var x; ~~~ -!!! error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. \ No newline at end of file +!!! error TS1208: All files must be modules when the '--isolatedModules' flag is provided. \ No newline at end of file diff --git a/tests/baselines/reference/isolatedModulesOut.errors.txt b/tests/baselines/reference/isolatedModulesOut.errors.txt index 5581ece62e6..ef9455189d0 100644 --- a/tests/baselines/reference/isolatedModulesOut.errors.txt +++ b/tests/baselines/reference/isolatedModulesOut.errors.txt @@ -1,6 +1,6 @@ error TS5053: Option 'out' cannot be specified with option 'isolatedModules'. tests/cases/compiler/file1.ts(1,1): error TS6131: Cannot compile modules using option 'out' unless the '--module' flag is 'amd' or 'system'. -tests/cases/compiler/file2.ts(1,1): error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +tests/cases/compiler/file2.ts(1,1): error TS1208: All files must be modules when the '--isolatedModules' flag is provided. !!! error TS5053: Option 'out' cannot be specified with option 'isolatedModules'. @@ -11,4 +11,4 @@ tests/cases/compiler/file2.ts(1,1): error TS1208: Cannot compile namespaces when ==== tests/cases/compiler/file2.ts (1 errors) ==== var y; ~~~ -!!! error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. \ No newline at end of file +!!! error TS1208: All files must be modules when the '--isolatedModules' flag is provided. \ No newline at end of file diff --git a/tests/baselines/reference/isolatedModulesPlainFile-AMD.errors.txt b/tests/baselines/reference/isolatedModulesPlainFile-AMD.errors.txt index d24da5e09cc..6c34c9953f0 100644 --- a/tests/baselines/reference/isolatedModulesPlainFile-AMD.errors.txt +++ b/tests/baselines/reference/isolatedModulesPlainFile-AMD.errors.txt @@ -1,9 +1,9 @@ -tests/cases/compiler/isolatedModulesPlainFile-AMD.ts(1,1): error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +tests/cases/compiler/isolatedModulesPlainFile-AMD.ts(1,1): error TS1208: All files must be modules when the '--isolatedModules' flag is provided. ==== tests/cases/compiler/isolatedModulesPlainFile-AMD.ts (1 errors) ==== declare function run(a: number): void; ~~~~~~~ -!!! error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +!!! error TS1208: All files must be modules when the '--isolatedModules' flag is provided. run(1); \ No newline at end of file diff --git a/tests/baselines/reference/isolatedModulesPlainFile-CommonJS.errors.txt b/tests/baselines/reference/isolatedModulesPlainFile-CommonJS.errors.txt index 43d18c54eb9..61a6021bf73 100644 --- a/tests/baselines/reference/isolatedModulesPlainFile-CommonJS.errors.txt +++ b/tests/baselines/reference/isolatedModulesPlainFile-CommonJS.errors.txt @@ -1,9 +1,9 @@ -tests/cases/compiler/isolatedModulesPlainFile-CommonJS.ts(1,1): error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +tests/cases/compiler/isolatedModulesPlainFile-CommonJS.ts(1,1): error TS1208: All files must be modules when the '--isolatedModules' flag is provided. ==== tests/cases/compiler/isolatedModulesPlainFile-CommonJS.ts (1 errors) ==== declare function run(a: number): void; ~~~~~~~ -!!! error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +!!! error TS1208: All files must be modules when the '--isolatedModules' flag is provided. run(1); \ No newline at end of file diff --git a/tests/baselines/reference/isolatedModulesPlainFile-ES6.errors.txt b/tests/baselines/reference/isolatedModulesPlainFile-ES6.errors.txt index 56316072aff..d1f9d635b0e 100644 --- a/tests/baselines/reference/isolatedModulesPlainFile-ES6.errors.txt +++ b/tests/baselines/reference/isolatedModulesPlainFile-ES6.errors.txt @@ -1,9 +1,9 @@ -tests/cases/compiler/isolatedModulesPlainFile-ES6.ts(1,1): error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +tests/cases/compiler/isolatedModulesPlainFile-ES6.ts(1,1): error TS1208: All files must be modules when the '--isolatedModules' flag is provided. ==== tests/cases/compiler/isolatedModulesPlainFile-ES6.ts (1 errors) ==== declare function run(a: number): void; ~~~~~~~ -!!! error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +!!! error TS1208: All files must be modules when the '--isolatedModules' flag is provided. run(1); \ No newline at end of file diff --git a/tests/baselines/reference/isolatedModulesPlainFile-System.errors.txt b/tests/baselines/reference/isolatedModulesPlainFile-System.errors.txt index b1e2ba643fa..e955549d754 100644 --- a/tests/baselines/reference/isolatedModulesPlainFile-System.errors.txt +++ b/tests/baselines/reference/isolatedModulesPlainFile-System.errors.txt @@ -1,9 +1,9 @@ -tests/cases/compiler/isolatedModulesPlainFile-System.ts(1,1): error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +tests/cases/compiler/isolatedModulesPlainFile-System.ts(1,1): error TS1208: All files must be modules when the '--isolatedModules' flag is provided. ==== tests/cases/compiler/isolatedModulesPlainFile-System.ts (1 errors) ==== declare function run(a: number): void; ~~~~~~~ -!!! error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +!!! error TS1208: All files must be modules when the '--isolatedModules' flag is provided. run(1); \ No newline at end of file diff --git a/tests/baselines/reference/isolatedModulesPlainFile-UMD.errors.txt b/tests/baselines/reference/isolatedModulesPlainFile-UMD.errors.txt index 29dfe4f67fb..1b7a01dd5bc 100644 --- a/tests/baselines/reference/isolatedModulesPlainFile-UMD.errors.txt +++ b/tests/baselines/reference/isolatedModulesPlainFile-UMD.errors.txt @@ -1,9 +1,9 @@ -tests/cases/compiler/isolatedModulesPlainFile-UMD.ts(1,1): error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +tests/cases/compiler/isolatedModulesPlainFile-UMD.ts(1,1): error TS1208: All files must be modules when the '--isolatedModules' flag is provided. ==== tests/cases/compiler/isolatedModulesPlainFile-UMD.ts (1 errors) ==== declare function run(a: number): void; ~~~~~~~ -!!! error TS1208: Cannot compile namespaces when the '--isolatedModules' flag is provided. +!!! error TS1208: All files must be modules when the '--isolatedModules' flag is provided. run(1); \ No newline at end of file diff --git a/tests/cases/compiler/commonJsIsolatedModules.ts b/tests/cases/compiler/commonJsIsolatedModules.ts new file mode 100644 index 00000000000..a75a5ec96d2 --- /dev/null +++ b/tests/cases/compiler/commonJsIsolatedModules.ts @@ -0,0 +1,12 @@ +// @Filename: tsconfig.json +{ + "compilerOptions": { + "allowJs": true, + "outDir": "foo", + "isolatedModules": true, + } +} + +// @Filename: index.js +module.exports = {} +var x = 1 From f97f57c1556bde40149ef30f034480917c27fce0 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 23 May 2019 12:15:50 -0700 Subject: [PATCH 095/119] Fix containsPrecedingToken for tokens whose preceding token is a missing node --- src/harness/fourslash.ts | 10 +++++----- src/services/signatureHelp.ts | 20 +++++++++++++++----- tests/cases/fourslash/fourslash.ts | 8 ++++---- 3 files changed, 24 insertions(+), 14 deletions(-) diff --git a/src/harness/fourslash.ts b/src/harness/fourslash.ts index 8a0a2bffbd4..bdcb3e082d2 100644 --- a/src/harness/fourslash.ts +++ b/src/harness/fourslash.ts @@ -1208,7 +1208,7 @@ Actual: ${stringify(fullActual)}`); } } - public verifySignatureHelpPresence(expectPresent: boolean, triggerReason: ts.SignatureHelpTriggerReason | undefined, markers: ReadonlyArray) { + public verifySignatureHelpPresence(expectPresent: boolean, triggerReason: ts.SignatureHelpTriggerReason | undefined, markers: ReadonlyArray) { if (markers.length) { for (const marker of markers) { this.goToMarker(marker); @@ -3768,15 +3768,15 @@ namespace FourSlashInterface { assert(ranges.length !== 0, "Array of ranges is expected to be non-empty"); } - public noSignatureHelp(...markers: string[]): void { + public noSignatureHelp(...markers: (string | FourSlash.Marker)[]): void { this.state.verifySignatureHelpPresence(/*expectPresent*/ false, /*triggerReason*/ undefined, markers); } - public noSignatureHelpForTriggerReason(reason: ts.SignatureHelpTriggerReason, ...markers: string[]): void { + public noSignatureHelpForTriggerReason(reason: ts.SignatureHelpTriggerReason, ...markers: (string | FourSlash.Marker)[]): void { this.state.verifySignatureHelpPresence(/*expectPresent*/ false, reason, markers); } - public signatureHelpPresentForTriggerReason(reason: ts.SignatureHelpTriggerReason, ...markers: string[]): void { + public signatureHelpPresentForTriggerReason(reason: ts.SignatureHelpTriggerReason, ...markers: (string | FourSlash.Marker)[]): void { this.state.verifySignatureHelpPresence(/*expectPresent*/ true, reason, markers); } @@ -5124,7 +5124,7 @@ namespace FourSlashInterface { } export interface VerifySignatureHelpOptions { - readonly marker?: ArrayOrSingle; + readonly marker?: ArrayOrSingle; /** @default 1 */ readonly overloadsCount?: number; /** @default undefined */ diff --git a/src/services/signatureHelp.ts b/src/services/signatureHelp.ts index 25f958dfc6a..998e45bd461 100644 --- a/src/services/signatureHelp.ts +++ b/src/services/signatureHelp.ts @@ -133,11 +133,21 @@ namespace ts.SignatureHelp { } function containsPrecedingToken(startingToken: Node, sourceFile: SourceFile, container: Node) { - const precedingToken = Debug.assertDefined( - findPrecedingToken(startingToken.getFullStart(), sourceFile, startingToken.parent, /*excludeJsdoc*/ true) - ); - - return rangeContainsRange(container, precedingToken); + const pos = startingToken.getFullStart(); + // There’s a possibility that `startingToken.parent` contains only `startingToken` and + // missing nodes, none of which are valid to be returned by `findPrecedingToken`. In that + // case, the preceding token we want is actually higher up the tree—almost definitely the + // next parent, but theoretically the situation with missing nodes might be happening on + // multiple nested levels. + let currentParent: Node | undefined = startingToken.parent; + while (currentParent) { + const precedingToken = findPrecedingToken(pos, sourceFile, currentParent, /*excludeJsdoc*/ true); + if (precedingToken) { + return rangeContainsRange(container, precedingToken); + } + currentParent = currentParent.parent; + } + return Debug.fail("Could not find preceding token"); } export interface ArgumentInfoForCompletions { diff --git a/tests/cases/fourslash/fourslash.ts b/tests/cases/fourslash/fourslash.ts index fa9cdd61c2f..b3253bcd59f 100644 --- a/tests/cases/fourslash/fourslash.ts +++ b/tests/cases/fourslash/fourslash.ts @@ -232,9 +232,9 @@ declare namespace FourSlashInterface { rangesWithSameTextAreRenameLocations(): void; rangesAreRenameLocations(options?: Range[] | { findInStrings?: boolean, findInComments?: boolean, ranges?: Range[] }); findReferencesDefinitionDisplayPartsAtCaretAre(expected: ts.SymbolDisplayPart[]): void; - noSignatureHelp(...markers: string[]): void; - noSignatureHelpForTriggerReason(triggerReason: SignatureHelpTriggerReason, ...markers: string[]): void - signatureHelpPresentForTriggerReason(triggerReason: SignatureHelpTriggerReason, ...markers: string[]): void + noSignatureHelp(...markers: (string | Marker)[]): void; + noSignatureHelpForTriggerReason(triggerReason: SignatureHelpTriggerReason, ...markers: (string | Marker)[]): void + signatureHelpPresentForTriggerReason(triggerReason: SignatureHelpTriggerReason, ...markers: (string | Marker)[]): void signatureHelp(...options: VerifySignatureHelpOptions[], ): void; // Checks that there are no compile errors. noErrors(): void; @@ -538,7 +538,7 @@ declare namespace FourSlashInterface { } interface VerifySignatureHelpOptions { - marker?: ArrayOrSingle; + marker?: ArrayOrSingle; /** @default 1 */ overloadsCount?: number; docComment?: string; From 5d9d4b2553df08effc21d27dc90ca726698db348 Mon Sep 17 00:00:00 2001 From: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com> Date: Thu, 23 May 2019 13:26:41 -0700 Subject: [PATCH 096/119] Manually copy just postMessage changes (#31557) * Manually copy just postMessage changes * Update baselines --- src/lib/dom.generated.d.ts | 3 ++- src/lib/webworker.generated.d.ts | 3 ++- .../baselines/reference/intersectionsOfLargeUnions2.errors.txt | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/lib/dom.generated.d.ts b/src/lib/dom.generated.d.ts index b1daca71fed..18f38b53560 100644 --- a/src/lib/dom.generated.d.ts +++ b/src/lib/dom.generated.d.ts @@ -17328,7 +17328,8 @@ interface WorkerEventMap extends AbstractWorkerEventMap { /** An interface of the Web Workers API represents a background task that can be easily created and can send messages back to its creator. Creating a worker is as simple as calling the Worker() constructor and specifying a script to be run in the worker thread. */ interface Worker extends EventTarget, AbstractWorker { onmessage: ((this: Worker, ev: MessageEvent) => any) | null; - postMessage(message: any, transfer?: Transferable[]): void; + postMessage(message: any, transfer: Transferable[]): void; + postMessage(message: any, options?: PostMessageOptions): void; terminate(): void; addEventListener(type: K, listener: (this: Worker, ev: WorkerEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; diff --git a/src/lib/webworker.generated.d.ts b/src/lib/webworker.generated.d.ts index cc35615d129..de98e9537aa 100644 --- a/src/lib/webworker.generated.d.ts +++ b/src/lib/webworker.generated.d.ts @@ -4231,7 +4231,8 @@ interface WorkerEventMap extends AbstractWorkerEventMap { /** An interface of the Web Workers API represents a background task that can be easily created and can send messages back to its creator. Creating a worker is as simple as calling the Worker() constructor and specifying a script to be run in the worker thread. */ interface Worker extends EventTarget, AbstractWorker { onmessage: ((this: Worker, ev: MessageEvent) => any) | null; - postMessage(message: any, transfer?: Transferable[]): void; + postMessage(message: any, transfer: Transferable[]): void; + postMessage(message: any, options?: PostMessageOptions): void; terminate(): void; addEventListener(type: K, listener: (this: Worker, ev: WorkerEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; diff --git a/tests/baselines/reference/intersectionsOfLargeUnions2.errors.txt b/tests/baselines/reference/intersectionsOfLargeUnions2.errors.txt index a8d4f797fea..bad3705abc0 100644 --- a/tests/baselines/reference/intersectionsOfLargeUnions2.errors.txt +++ b/tests/baselines/reference/intersectionsOfLargeUnions2.errors.txt @@ -10,7 +10,7 @@ tests/cases/compiler/intersectionsOfLargeUnions2.ts(31,15): error TS2536: Type ' interface ElementTagNameMap { ~~~~~~~~~~~~~~~~~ !!! error TS2300: Duplicate identifier 'ElementTagNameMap'. -!!! related TS6203 /.ts/lib.dom.d.ts:18109:6: 'ElementTagNameMap' was also declared here. +!!! related TS6203 /.ts/lib.dom.d.ts:18110:6: 'ElementTagNameMap' was also declared here. [index: number]: HTMLElement } From 7359ff8158df18207ff66cb7040509051eab5242 Mon Sep 17 00:00:00 2001 From: Andrew Branch Date: Thu, 23 May 2019 13:33:38 -0700 Subject: [PATCH 097/119] Add test --- tests/cases/fourslash/signatureHelpJSX.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 tests/cases/fourslash/signatureHelpJSX.ts diff --git a/tests/cases/fourslash/signatureHelpJSX.ts b/tests/cases/fourslash/signatureHelpJSX.ts new file mode 100644 index 00000000000..181ff85541b --- /dev/null +++ b/tests/cases/fourslash/signatureHelpJSX.ts @@ -0,0 +1,10 @@ +/// + +//@Filename: test.tsx +//@jsx: react +////declare var React: any; +////const z =

{[].map(x => Date: Fri, 24 May 2019 01:27:50 +0300 Subject: [PATCH 098/119] Improve error messages when indexing into a type (#31379) * Improved error messages when indexing an object type with a literal string, a literal string union or a string. * Added more specific message when using the indexing operator with an incompatible index argument. * Fixed spelling and error message. --- src/compiler/checker.ts | 32 ++++++++-- src/compiler/diagnosticMessages.json | 8 +++ .../globalThisUnknownNoImplicitAny.errors.txt | 12 ++-- .../keyofAndIndexedAccess2.errors.txt | 6 +- .../reference/noImplicitAnyForIn.errors.txt | 12 ++-- .../noImplicitAnyIndexing.errors.txt | 16 +++-- ...mplicitAnyStringIndexerOnObject.errors.txt | 59 +++++++++++++++++-- .../noImplicitAnyStringIndexerOnObject.js | 38 ++++++++++++ ...noImplicitAnyStringIndexerOnObject.symbols | 52 ++++++++++++++++ .../noImplicitAnyStringIndexerOnObject.types | 59 +++++++++++++++++++ ...eIndexingWithForInNoImplicitAny.errors.txt | 6 +- .../objectSpreadIndexSignature.errors.txt | 6 +- ...ringIndexSignatureNoImplicitAny.errors.txt | 6 +- .../typeFromPrototypeAssignment3.errors.txt | 6 +- .../unionTypeWithIndexSignature.errors.txt | 12 ++-- .../noImplicitAnyStringIndexerOnObject.ts | 20 +++++++ 16 files changed, 312 insertions(+), 38 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index c221da7bdb2..0d7c7b022dd 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -10067,7 +10067,7 @@ namespace ts { return false; } - function getPropertyTypeForIndexType(originalObjectType: Type, objectType: Type, indexType: Type, accessNode: ElementAccessExpression | IndexedAccessTypeNode | PropertyName | BindingName | SyntheticExpression | undefined, accessFlags: AccessFlags) { + function getPropertyTypeForIndexType(originalObjectType: Type, objectType: Type, indexType: Type, fullIndexType: Type, suppressNoImplicitAnyError: boolean, accessNode: ElementAccessExpression | IndexedAccessTypeNode | PropertyName | BindingName | SyntheticExpression | undefined, accessFlags: AccessFlags) { const accessExpression = accessNode && accessNode.kind === SyntaxKind.ElementAccessExpression ? accessNode : undefined; const propName = isTypeUsableAsPropertyName(indexType) ? getPropertyNameFromType(indexType) : @@ -10141,7 +10141,7 @@ namespace ts { if (objectType.symbol === globalThisSymbol && propName !== undefined && globalThisSymbol.exports!.has(propName) && (globalThisSymbol.exports!.get(propName)!.flags & SymbolFlags.BlockScoped)) { error(accessExpression, Diagnostics.Property_0_does_not_exist_on_type_1, unescapeLeadingUnderscores(propName), typeToString(objectType)); } - else if (noImplicitAny && !compilerOptions.suppressImplicitAnyIndexErrors) { + else if (noImplicitAny && !compilerOptions.suppressImplicitAnyIndexErrors && !suppressNoImplicitAnyError) { if (propName !== undefined && typeHasStaticProperty(propName, objectType)) { error(accessExpression, Diagnostics.Property_0_is_a_static_member_of_type_1, propName as string, typeToString(objectType)); } @@ -10161,7 +10161,29 @@ namespace ts { error(accessExpression, Diagnostics.Element_implicitly_has_an_any_type_because_type_0_has_no_index_signature_Did_you_mean_to_call_1, typeToString(objectType), suggestion); } else { - error(accessExpression, Diagnostics.Element_implicitly_has_an_any_type_because_type_0_has_no_index_signature, typeToString(objectType)); + let errorInfo: DiagnosticMessageChain | undefined; + if (indexType.flags & TypeFlags.EnumLiteral) { + errorInfo = chainDiagnosticMessages(/* details */ undefined, Diagnostics.Property_0_does_not_exist_on_type_1, "[" + typeToString(indexType) + "]", typeToString(objectType)); + } + else if (indexType.flags & TypeFlags.UniqueESSymbol) { + const symbolName = getFullyQualifiedName((indexType as UniqueESSymbolType).symbol, accessExpression); + errorInfo = chainDiagnosticMessages(/* details */ undefined, Diagnostics.Property_0_does_not_exist_on_type_1, "[" + symbolName + "]", typeToString(objectType)); + } + else if (indexType.flags & TypeFlags.StringLiteral) { + errorInfo = chainDiagnosticMessages(/* details */ undefined, Diagnostics.Property_0_does_not_exist_on_type_1, (indexType as StringLiteralType).value, typeToString(objectType)); + } + else if (indexType.flags & TypeFlags.NumberLiteral) { + errorInfo = chainDiagnosticMessages(/* details */ undefined, Diagnostics.Property_0_does_not_exist_on_type_1, (indexType as NumberLiteralType).value, typeToString(objectType)); + } + else if (indexType.flags & (TypeFlags.Number | TypeFlags.String)) { + errorInfo = chainDiagnosticMessages(/* details */ undefined, Diagnostics.No_index_signature_with_a_parameter_of_type_0_was_found_on_type_1, typeToString(indexType), typeToString(objectType)); + } + + errorInfo = chainDiagnosticMessages( + errorInfo, + Diagnostics.Element_implicitly_has_an_any_type_because_expression_of_type_0_can_t_be_used_to_index_type_1, typeToString(fullIndexType), typeToString(objectType) + ); + diagnostics.add(createDiagnosticForNodeFromMessageChain(accessExpression, errorInfo)); } } } @@ -10360,7 +10382,7 @@ namespace ts { const propTypes: Type[] = []; let wasMissingProp = false; for (const t of (indexType).types) { - const propType = getPropertyTypeForIndexType(objectType, apparentObjectType, t, accessNode, accessFlags); + const propType = getPropertyTypeForIndexType(objectType, apparentObjectType, t, indexType, wasMissingProp, accessNode, accessFlags); if (propType) { propTypes.push(propType); } @@ -10378,7 +10400,7 @@ namespace ts { } return accessFlags & AccessFlags.Writing ? getIntersectionType(propTypes) : getUnionType(propTypes); } - return getPropertyTypeForIndexType(objectType, apparentObjectType, indexType, accessNode, accessFlags | AccessFlags.CacheSymbol); + return getPropertyTypeForIndexType(objectType, apparentObjectType, indexType, indexType, /* supressNoImplicitAnyError */ false, accessNode, accessFlags | AccessFlags.CacheSymbol); } function getTypeFromIndexedAccessTypeNode(node: IndexedAccessTypeNode) { diff --git a/src/compiler/diagnosticMessages.json b/src/compiler/diagnosticMessages.json index 101b584ca13..e0579429def 100644 --- a/src/compiler/diagnosticMessages.json +++ b/src/compiler/diagnosticMessages.json @@ -4288,6 +4288,14 @@ "category": "Error", "code": 7052 }, + "Element implicitly has an 'any' type because expression of type '{0}' can't be used to index type '{1}'.": { + "category": "Error", + "code": 7053 + }, + "No index signature with a parameter of type '{0}' was found on type '{1}'.": { + "category": "Error", + "code": 7054 + }, "You cannot rename this element.": { "category": "Error", "code": 8000 diff --git a/tests/baselines/reference/globalThisUnknownNoImplicitAny.errors.txt b/tests/baselines/reference/globalThisUnknownNoImplicitAny.errors.txt index 0668d03f93b..907a6cd1ced 100644 --- a/tests/baselines/reference/globalThisUnknownNoImplicitAny.errors.txt +++ b/tests/baselines/reference/globalThisUnknownNoImplicitAny.errors.txt @@ -2,8 +2,10 @@ tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(4,5): error TS2 tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(5,6): error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature. tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(6,12): error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature. tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(8,5): error TS7015: Element implicitly has an 'any' type because index expression is not of type 'number'. -tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(9,1): error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature. -tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(10,1): error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature. +tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(9,1): error TS7053: Element implicitly has an 'any' type because expression of type '"hi"' can't be used to index type 'typeof globalThis'. + Property 'hi' does not exist on type 'typeof globalThis'. +tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(10,1): error TS7053: Element implicitly has an 'any' type because expression of type '"hi"' can't be used to index type 'typeof globalThis'. + Property 'hi' does not exist on type 'typeof globalThis'. ==== tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts (6 errors) ==== @@ -25,8 +27,10 @@ tests/cases/conformance/es2019/globalThisUnknownNoImplicitAny.ts(10,1): error TS !!! error TS7015: Element implicitly has an 'any' type because index expression is not of type 'number'. this['hi'] ~~~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '"hi"' can't be used to index type 'typeof globalThis'. +!!! error TS7053: Property 'hi' does not exist on type 'typeof globalThis'. globalThis['hi'] ~~~~~~~~~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '"hi"' can't be used to index type 'typeof globalThis'. +!!! error TS7053: Property 'hi' does not exist on type 'typeof globalThis'. \ No newline at end of file diff --git a/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt b/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt index 1cad297c52d..40ccd13dac4 100644 --- a/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt +++ b/tests/baselines/reference/keyofAndIndexedAccess2.errors.txt @@ -15,7 +15,8 @@ tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(26,7): error TS233 tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(27,5): error TS2322: Type '1' is not assignable to type 'T[keyof T]'. tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(31,5): error TS2322: Type '{ [key: string]: number; }' is not assignable to type '{ [P in K]: number; }'. tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(38,5): error TS2322: Type '{ [x: string]: number; }' is not assignable to type '{ [P in K]: number; }'. -tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(50,3): error TS7017: Element implicitly has an 'any' type because type 'Item' has no index signature. +tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(50,3): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type 'Item'. + No index signature with a parameter of type 'string' was found on type 'Item'. tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(51,3): error TS2322: Type '123' is not assignable to type 'string & number'. Type '123' is not assignable to type 'string'. tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(52,3): error TS2322: Type '123' is not assignable to type 'T[keyof T]'. @@ -112,7 +113,8 @@ tests/cases/conformance/types/keyof/keyofAndIndexedAccess2.ts(108,5): error TS23 function f10(obj: T, k1: string, k2: keyof Item, k3: keyof T, k4: K) { obj[k1] = 123; // Error ~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type 'Item' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type 'Item'. +!!! error TS7053: No index signature with a parameter of type 'string' was found on type 'Item'. obj[k2] = 123; // Error ~~~~~~~ !!! error TS2322: Type '123' is not assignable to type 'string & number'. diff --git a/tests/baselines/reference/noImplicitAnyForIn.errors.txt b/tests/baselines/reference/noImplicitAnyForIn.errors.txt index b384735d82e..c66a7e07f96 100644 --- a/tests/baselines/reference/noImplicitAnyForIn.errors.txt +++ b/tests/baselines/reference/noImplicitAnyForIn.errors.txt @@ -1,5 +1,7 @@ -tests/cases/compiler/noImplicitAnyForIn.ts(7,18): error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. -tests/cases/compiler/noImplicitAnyForIn.ts(14,18): error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +tests/cases/compiler/noImplicitAnyForIn.ts(7,18): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. + No index signature with a parameter of type 'string' was found on type '{}'. +tests/cases/compiler/noImplicitAnyForIn.ts(14,18): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. + No index signature with a parameter of type 'string' was found on type '{}'. tests/cases/compiler/noImplicitAnyForIn.ts(28,5): error TS7005: Variable 'n' implicitly has an 'any[][]' type. tests/cases/compiler/noImplicitAnyForIn.ts(30,6): error TS2405: The left-hand side of a 'for...in' statement must be of type 'string' or 'any'. @@ -13,7 +15,8 @@ tests/cases/compiler/noImplicitAnyForIn.ts(30,6): error TS2405: The left-hand si //Should yield an implicit 'any' error var _j = x[i][j]; ~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. +!!! error TS7053: No index signature with a parameter of type 'string' was found on type '{}'. } for (var k in x[0]) { @@ -22,7 +25,8 @@ tests/cases/compiler/noImplicitAnyForIn.ts(30,6): error TS2405: The left-hand si //Should yield an implicit 'any' error var k2 = k1[k]; ~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. +!!! error TS7053: No index signature with a parameter of type 'string' was found on type '{}'. } } diff --git a/tests/baselines/reference/noImplicitAnyIndexing.errors.txt b/tests/baselines/reference/noImplicitAnyIndexing.errors.txt index 8d1d3ea6c46..f9631f29aa1 100644 --- a/tests/baselines/reference/noImplicitAnyIndexing.errors.txt +++ b/tests/baselines/reference/noImplicitAnyIndexing.errors.txt @@ -1,7 +1,9 @@ tests/cases/compiler/noImplicitAnyIndexing.ts(12,37): error TS7015: Element implicitly has an 'any' type because index expression is not of type 'number'. -tests/cases/compiler/noImplicitAnyIndexing.ts(19,9): error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. -tests/cases/compiler/noImplicitAnyIndexing.ts(22,9): error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. -tests/cases/compiler/noImplicitAnyIndexing.ts(30,10): error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +tests/cases/compiler/noImplicitAnyIndexing.ts(19,9): error TS7053: Element implicitly has an 'any' type because expression of type '"hi"' can't be used to index type '{}'. + Property 'hi' does not exist on type '{}'. +tests/cases/compiler/noImplicitAnyIndexing.ts(22,9): error TS7053: Element implicitly has an 'any' type because expression of type '10' can't be used to index type '{}'. + Property '10' does not exist on type '{}'. +tests/cases/compiler/noImplicitAnyIndexing.ts(30,10): error TS7053: Element implicitly has an 'any' type because expression of type 'any' can't be used to index type '{}'. ==== tests/cases/compiler/noImplicitAnyIndexing.ts (4 errors) ==== @@ -27,12 +29,14 @@ tests/cases/compiler/noImplicitAnyIndexing.ts(30,10): error TS7017: Element impl // Should report an implicit 'any'. var x = {}["hi"]; ~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '"hi"' can't be used to index type '{}'. +!!! error TS7053: Property 'hi' does not exist on type '{}'. // Should report an implicit 'any'. var y = {}[10]; ~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '10' can't be used to index type '{}'. +!!! error TS7053: Property '10' does not exist on type '{}'. var hi: any = "hi"; @@ -42,7 +46,7 @@ tests/cases/compiler/noImplicitAnyIndexing.ts(30,10): error TS7017: Element impl // Should report an implicit 'any'. var z1 = emptyObj[hi]; ~~~~~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'any' can't be used to index type '{}'. var z2 = (emptyObj)[hi]; interface MyMap { diff --git a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.errors.txt b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.errors.txt index 6df52aea46a..0d2fc1b860e 100644 --- a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.errors.txt +++ b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.errors.txt @@ -1,16 +1,29 @@ -tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(1,9): error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(1,9): error TS7053: Element implicitly has an 'any' type because expression of type '"hello"' can't be used to index type '{}'. + Property 'hello' does not exist on type '{}'. tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(7,1): error TS7052: Element implicitly has an 'any' type because type '{ get: (key: string) => string; }' has no index signature. Did you mean to call 'get' ? tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(8,13): error TS7052: Element implicitly has an 'any' type because type '{ get: (key: string) => string; }' has no index signature. Did you mean to call 'get' ? -tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(13,13): error TS7017: Element implicitly has an 'any' type because type '{ set: (key: string) => string; }' has no index signature. +tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(13,13): error TS7053: Element implicitly has an 'any' type because expression of type '"hello"' can't be used to index type '{ set: (key: string) => string; }'. + Property 'hello' does not exist on type '{ set: (key: string) => string; }'. tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(19,1): error TS7052: Element implicitly has an 'any' type because type '{ set: (key: string) => string; get: (key: string) => string; }' has no index signature. Did you mean to call 'set' ? tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(20,1): error TS7052: Element implicitly has an 'any' type because type '{ set: (key: string) => string; get: (key: string) => string; }' has no index signature. Did you mean to call 'set' ? tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(21,1): error TS7052: Element implicitly has an 'any' type because type '{ set: (key: string) => string; get: (key: string) => string; }' has no index signature. Did you mean to call 'set' ? +tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(26,1): error TS7053: Element implicitly has an 'any' type because expression of type '"a" | "b" | "c"' can't be used to index type '{ a: number; }'. + Property 'b' does not exist on type '{ a: number; }'. +tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(30,1): error TS7053: Element implicitly has an 'any' type because expression of type '"c"' can't be used to index type '{ a: number; }'. + Property 'c' does not exist on type '{ a: number; }'. +tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(33,1): error TS7053: Element implicitly has an 'any' type because expression of type 'unique symbol' can't be used to index type '{ a: number; }'. + Property '[sym]' does not exist on type '{ a: number; }'. +tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(37,1): error TS7053: Element implicitly has an 'any' type because expression of type 'NumEnum' can't be used to index type '{ a: number; }'. + Property '[NumEnum.a]' does not exist on type '{ a: number; }'. +tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(42,1): error TS7053: Element implicitly has an 'any' type because expression of type 'StrEnum' can't be used to index type '{ a: number; }'. + Property '[StrEnum.b]' does not exist on type '{ a: number; }'. -==== tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts (7 errors) ==== +==== tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts (12 errors) ==== var a = {}["hello"]; ~~~~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '"hello"' can't be used to index type '{}'. +!!! error TS7053: Property 'hello' does not exist on type '{}'. var b: string = { '': 'foo' }['']; var c = { @@ -28,7 +41,8 @@ tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(21,1): error TS7052: }; const bar = d['hello']; ~~~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{ set: (key: string) => string; }' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '"hello"' can't be used to index type '{ set: (key: string) => string; }'. +!!! error TS7053: Property 'hello' does not exist on type '{ set: (key: string) => string; }'. var e = { set: (key: string) => 'foobar', @@ -44,4 +58,39 @@ tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts(21,1): error TS7052: ~~~~~~~~~~ !!! error TS7052: Element implicitly has an 'any' type because type '{ set: (key: string) => string; get: (key: string) => string; }' has no index signature. Did you mean to call 'set' ? + const o = { a: 0 }; + + declare const k: "a" | "b" | "c"; + o[k]; + ~~~~ +!!! error TS7053: Element implicitly has an 'any' type because expression of type '"a" | "b" | "c"' can't be used to index type '{ a: number; }'. +!!! error TS7053: Property 'b' does not exist on type '{ a: number; }'. + + + declare const k2: "c"; + o[k2]; + ~~~~~ +!!! error TS7053: Element implicitly has an 'any' type because expression of type '"c"' can't be used to index type '{ a: number; }'. +!!! error TS7053: Property 'c' does not exist on type '{ a: number; }'. + + declare const sym : unique symbol; + o[sym]; + ~~~~~~ +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'unique symbol' can't be used to index type '{ a: number; }'. +!!! error TS7053: Property '[sym]' does not exist on type '{ a: number; }'. + + enum NumEnum { a, b } + let numEnumKey: NumEnum; + o[numEnumKey]; + ~~~~~~~~~~~~~ +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'NumEnum' can't be used to index type '{ a: number; }'. +!!! error TS7053: Property '[NumEnum.a]' does not exist on type '{ a: number; }'. + + + enum StrEnum { a = "a", b = "b" } + let strEnumKey: StrEnum; + o[strEnumKey]; + ~~~~~~~~~~~~~ +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'StrEnum' can't be used to index type '{ a: number; }'. +!!! error TS7053: Property '[StrEnum.b]' does not exist on type '{ a: number; }'. \ No newline at end of file diff --git a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.js b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.js index a02740351cf..572d9f38caf 100644 --- a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.js +++ b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.js @@ -21,6 +21,26 @@ e['hello'] = 'modified'; e['hello'] += 1; e['hello'] ++; +const o = { a: 0 }; + +declare const k: "a" | "b" | "c"; +o[k]; + + +declare const k2: "c"; +o[k2]; + +declare const sym : unique symbol; +o[sym]; + +enum NumEnum { a, b } +let numEnumKey: NumEnum; +o[numEnumKey]; + + +enum StrEnum { a = "a", b = "b" } +let strEnumKey: StrEnum; +o[strEnumKey]; //// [noImplicitAnyStringIndexerOnObject.js] @@ -42,3 +62,21 @@ var e = { e['hello'] = 'modified'; e['hello'] += 1; e['hello']++; +var o = { a: 0 }; +o[k]; +o[k2]; +o[sym]; +var NumEnum; +(function (NumEnum) { + NumEnum[NumEnum["a"] = 0] = "a"; + NumEnum[NumEnum["b"] = 1] = "b"; +})(NumEnum || (NumEnum = {})); +var numEnumKey; +o[numEnumKey]; +var StrEnum; +(function (StrEnum) { + StrEnum["a"] = "a"; + StrEnum["b"] = "b"; +})(StrEnum || (StrEnum = {})); +var strEnumKey; +o[strEnumKey]; diff --git a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.symbols b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.symbols index f86c0d14b6f..307144b8563 100644 --- a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.symbols +++ b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.symbols @@ -55,4 +55,56 @@ e['hello'] += 1; e['hello'] ++; >e : Symbol(e, Decl(noImplicitAnyStringIndexerOnObject.ts, 14, 3)) +const o = { a: 0 }; +>o : Symbol(o, Decl(noImplicitAnyStringIndexerOnObject.ts, 22, 5)) +>a : Symbol(a, Decl(noImplicitAnyStringIndexerOnObject.ts, 22, 11)) + +declare const k: "a" | "b" | "c"; +>k : Symbol(k, Decl(noImplicitAnyStringIndexerOnObject.ts, 24, 13)) + +o[k]; +>o : Symbol(o, Decl(noImplicitAnyStringIndexerOnObject.ts, 22, 5)) +>k : Symbol(k, Decl(noImplicitAnyStringIndexerOnObject.ts, 24, 13)) + + +declare const k2: "c"; +>k2 : Symbol(k2, Decl(noImplicitAnyStringIndexerOnObject.ts, 28, 13)) + +o[k2]; +>o : Symbol(o, Decl(noImplicitAnyStringIndexerOnObject.ts, 22, 5)) +>k2 : Symbol(k2, Decl(noImplicitAnyStringIndexerOnObject.ts, 28, 13)) + +declare const sym : unique symbol; +>sym : Symbol(sym, Decl(noImplicitAnyStringIndexerOnObject.ts, 31, 13)) + +o[sym]; +>o : Symbol(o, Decl(noImplicitAnyStringIndexerOnObject.ts, 22, 5)) +>sym : Symbol(sym, Decl(noImplicitAnyStringIndexerOnObject.ts, 31, 13)) + +enum NumEnum { a, b } +>NumEnum : Symbol(NumEnum, Decl(noImplicitAnyStringIndexerOnObject.ts, 32, 7)) +>a : Symbol(NumEnum.a, Decl(noImplicitAnyStringIndexerOnObject.ts, 34, 14)) +>b : Symbol(NumEnum.b, Decl(noImplicitAnyStringIndexerOnObject.ts, 34, 17)) + +let numEnumKey: NumEnum; +>numEnumKey : Symbol(numEnumKey, Decl(noImplicitAnyStringIndexerOnObject.ts, 35, 3)) +>NumEnum : Symbol(NumEnum, Decl(noImplicitAnyStringIndexerOnObject.ts, 32, 7)) + +o[numEnumKey]; +>o : Symbol(o, Decl(noImplicitAnyStringIndexerOnObject.ts, 22, 5)) +>numEnumKey : Symbol(numEnumKey, Decl(noImplicitAnyStringIndexerOnObject.ts, 35, 3)) + + +enum StrEnum { a = "a", b = "b" } +>StrEnum : Symbol(StrEnum, Decl(noImplicitAnyStringIndexerOnObject.ts, 36, 14)) +>a : Symbol(StrEnum.a, Decl(noImplicitAnyStringIndexerOnObject.ts, 39, 14)) +>b : Symbol(StrEnum.b, Decl(noImplicitAnyStringIndexerOnObject.ts, 39, 23)) + +let strEnumKey: StrEnum; +>strEnumKey : Symbol(strEnumKey, Decl(noImplicitAnyStringIndexerOnObject.ts, 40, 3)) +>StrEnum : Symbol(StrEnum, Decl(noImplicitAnyStringIndexerOnObject.ts, 36, 14)) + +o[strEnumKey]; +>o : Symbol(o, Decl(noImplicitAnyStringIndexerOnObject.ts, 22, 5)) +>strEnumKey : Symbol(strEnumKey, Decl(noImplicitAnyStringIndexerOnObject.ts, 40, 3)) diff --git a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.types b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.types index dcf01d8c5e8..fa74a192248 100644 --- a/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.types +++ b/tests/baselines/reference/noImplicitAnyStringIndexerOnObject.types @@ -89,4 +89,63 @@ e['hello'] ++; >e : { set: (key: string) => string; get: (key: string) => string; } >'hello' : "hello" +const o = { a: 0 }; +>o : { a: number; } +>{ a: 0 } : { a: number; } +>a : number +>0 : 0 + +declare const k: "a" | "b" | "c"; +>k : "a" | "b" | "c" + +o[k]; +>o[k] : any +>o : { a: number; } +>k : "a" | "b" | "c" + + +declare const k2: "c"; +>k2 : "c" + +o[k2]; +>o[k2] : any +>o : { a: number; } +>k2 : "c" + +declare const sym : unique symbol; +>sym : unique symbol + +o[sym]; +>o[sym] : any +>o : { a: number; } +>sym : unique symbol + +enum NumEnum { a, b } +>NumEnum : NumEnum +>a : NumEnum.a +>b : NumEnum.b + +let numEnumKey: NumEnum; +>numEnumKey : NumEnum + +o[numEnumKey]; +>o[numEnumKey] : any +>o : { a: number; } +>numEnumKey : NumEnum + + +enum StrEnum { a = "a", b = "b" } +>StrEnum : StrEnum +>a : StrEnum.a +>"a" : "a" +>b : StrEnum.b +>"b" : "b" + +let strEnumKey: StrEnum; +>strEnumKey : StrEnum + +o[strEnumKey]; +>o[strEnumKey] : any +>o : { a: number; } +>strEnumKey : StrEnum diff --git a/tests/baselines/reference/nonPrimitiveIndexingWithForInNoImplicitAny.errors.txt b/tests/baselines/reference/nonPrimitiveIndexingWithForInNoImplicitAny.errors.txt index f7f2ee3db16..07f52bf3e6f 100644 --- a/tests/baselines/reference/nonPrimitiveIndexingWithForInNoImplicitAny.errors.txt +++ b/tests/baselines/reference/nonPrimitiveIndexingWithForInNoImplicitAny.errors.txt @@ -1,4 +1,5 @@ -tests/cases/conformance/types/nonPrimitive/nonPrimitiveIndexingWithForInNoImplicitAny.ts(4,17): error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +tests/cases/conformance/types/nonPrimitive/nonPrimitiveIndexingWithForInNoImplicitAny.ts(4,17): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. + No index signature with a parameter of type 'string' was found on type '{}'. ==== tests/cases/conformance/types/nonPrimitive/nonPrimitiveIndexingWithForInNoImplicitAny.ts (1 errors) ==== @@ -7,6 +8,7 @@ tests/cases/conformance/types/nonPrimitive/nonPrimitiveIndexingWithForInNoImplic for (var key in a) { var value = a[key]; // error ~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. +!!! error TS7053: No index signature with a parameter of type 'string' was found on type '{}'. } \ No newline at end of file diff --git a/tests/baselines/reference/objectSpreadIndexSignature.errors.txt b/tests/baselines/reference/objectSpreadIndexSignature.errors.txt index dede126d063..5c373b82ae4 100644 --- a/tests/baselines/reference/objectSpreadIndexSignature.errors.txt +++ b/tests/baselines/reference/objectSpreadIndexSignature.errors.txt @@ -1,4 +1,5 @@ -tests/cases/conformance/types/spread/objectSpreadIndexSignature.ts(6,1): error TS7017: Element implicitly has an 'any' type because type '{ b: number; a: number; }' has no index signature. +tests/cases/conformance/types/spread/objectSpreadIndexSignature.ts(6,1): error TS7053: Element implicitly has an 'any' type because expression of type '101' can't be used to index type '{ b: number; a: number; }'. + Property '101' does not exist on type '{ b: number; a: number; }'. ==== tests/cases/conformance/types/spread/objectSpreadIndexSignature.ts (1 errors) ==== @@ -9,7 +10,8 @@ tests/cases/conformance/types/spread/objectSpreadIndexSignature.ts(6,1): error T // only indexed has indexer, so i[101]: any i[101]; ~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{ b: number; a: number; }' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '101' can't be used to index type '{ b: number; a: number; }'. +!!! error TS7053: Property '101' does not exist on type '{ b: number; a: number; }'. let ii = { ...indexed1, ...indexed2 }; // both have indexer, so i[1001]: number | boolean ii[1001]; diff --git a/tests/baselines/reference/propertyAccessStringIndexSignatureNoImplicitAny.errors.txt b/tests/baselines/reference/propertyAccessStringIndexSignatureNoImplicitAny.errors.txt index d5fda181096..0211bf321bf 100644 --- a/tests/baselines/reference/propertyAccessStringIndexSignatureNoImplicitAny.errors.txt +++ b/tests/baselines/reference/propertyAccessStringIndexSignatureNoImplicitAny.errors.txt @@ -1,5 +1,6 @@ tests/cases/conformance/expressions/propertyAccess/propertyAccessStringIndexSignatureNoImplicitAny.ts(10,7): error TS2339: Property 'nope' does not exist on type 'Empty'. -tests/cases/conformance/expressions/propertyAccess/propertyAccessStringIndexSignatureNoImplicitAny.ts(11,1): error TS7017: Element implicitly has an 'any' type because type 'Empty' has no index signature. +tests/cases/conformance/expressions/propertyAccess/propertyAccessStringIndexSignatureNoImplicitAny.ts(11,1): error TS7053: Element implicitly has an 'any' type because expression of type '"not allowed either"' can't be used to index type 'Empty'. + Property 'not allowed either' does not exist on type 'Empty'. ==== tests/cases/conformance/expressions/propertyAccess/propertyAccessStringIndexSignatureNoImplicitAny.ts (2 errors) ==== @@ -17,5 +18,6 @@ tests/cases/conformance/expressions/propertyAccess/propertyAccessStringIndexSign !!! error TS2339: Property 'nope' does not exist on type 'Empty'. empty["not allowed either"]; ~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type 'Empty' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '"not allowed either"' can't be used to index type 'Empty'. +!!! error TS7053: Property 'not allowed either' does not exist on type 'Empty'. \ No newline at end of file diff --git a/tests/baselines/reference/typeFromPrototypeAssignment3.errors.txt b/tests/baselines/reference/typeFromPrototypeAssignment3.errors.txt index 579c3efac72..02ff4ae344c 100644 --- a/tests/baselines/reference/typeFromPrototypeAssignment3.errors.txt +++ b/tests/baselines/reference/typeFromPrototypeAssignment3.errors.txt @@ -1,5 +1,6 @@ tests/cases/conformance/salsa/bug26885.js(2,5): error TS2683: 'this' implicitly has type 'any' because it does not have a type annotation. -tests/cases/conformance/salsa/bug26885.js(11,16): error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +tests/cases/conformance/salsa/bug26885.js(11,16): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. + No index signature with a parameter of type 'string' was found on type '{}'. ==== tests/cases/conformance/salsa/bug26885.js (2 errors) ==== @@ -17,7 +18,8 @@ tests/cases/conformance/salsa/bug26885.js(11,16): error TS7017: Element implicit get(key) { return this._map[key + '']; ~~~~~~~~~~~~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type '{}' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'. +!!! error TS7053: No index signature with a parameter of type 'string' was found on type '{}'. } } diff --git a/tests/baselines/reference/unionTypeWithIndexSignature.errors.txt b/tests/baselines/reference/unionTypeWithIndexSignature.errors.txt index fb4463bc2d9..14a3ffc58a6 100644 --- a/tests/baselines/reference/unionTypeWithIndexSignature.errors.txt +++ b/tests/baselines/reference/unionTypeWithIndexSignature.errors.txt @@ -1,9 +1,11 @@ tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts(11,3): error TS2339: Property 'bar' does not exist on type 'Missing'. Property 'bar' does not exist on type '{ [s: string]: string; }'. tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts(14,4): error TS2540: Cannot assign to 'foo' because it is a read-only property. -tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts(24,1): error TS7017: Element implicitly has an 'any' type because type 'Both' has no index signature. +tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts(24,1): error TS7053: Element implicitly has an 'any' type because expression of type '1' can't be used to index type 'Both'. + Property '1' does not exist on type 'Both'. tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts(25,1): error TS2322: Type '"not ok"' is not assignable to type 'number'. -tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts(26,1): error TS7017: Element implicitly has an 'any' type because type 'Both' has no index signature. +tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts(26,1): error TS7053: Element implicitly has an 'any' type because expression of type 'unique symbol' can't be used to index type 'Both'. + Property '[sym]' does not exist on type 'Both'. ==== tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts (5 errors) ==== @@ -37,11 +39,13 @@ tests/cases/conformance/types/union/unionTypeWithIndexSignature.ts(26,1): error both[0] = 1 both[1] = 0 // not ok ~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type 'Both' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type '1' can't be used to index type 'Both'. +!!! error TS7053: Property '1' does not exist on type 'Both'. both[0] = 'not ok' ~~~~~~~ !!! error TS2322: Type '"not ok"' is not assignable to type 'number'. both[sym] = 'not ok' ~~~~~~~~~ -!!! error TS7017: Element implicitly has an 'any' type because type 'Both' has no index signature. +!!! error TS7053: Element implicitly has an 'any' type because expression of type 'unique symbol' can't be used to index type 'Both'. +!!! error TS7053: Property '[sym]' does not exist on type 'Both'. \ No newline at end of file diff --git a/tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts b/tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts index 1cd967c294f..5e1b9430088 100644 --- a/tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts +++ b/tests/cases/compiler/noImplicitAnyStringIndexerOnObject.ts @@ -22,3 +22,23 @@ e['hello'] = 'modified'; e['hello'] += 1; e['hello'] ++; +const o = { a: 0 }; + +declare const k: "a" | "b" | "c"; +o[k]; + + +declare const k2: "c"; +o[k2]; + +declare const sym : unique symbol; +o[sym]; + +enum NumEnum { a, b } +let numEnumKey: NumEnum; +o[numEnumKey]; + + +enum StrEnum { a = "a", b = "b" } +let strEnumKey: StrEnum; +o[strEnumKey]; From f20a4fdfc48a5ea2c13896d9087d0492ed34811f Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 23 May 2019 15:39:40 -0700 Subject: [PATCH 099/119] Limit size of union types resulting from intersection type normalization --- src/compiler/checker.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 3111cffa126..8760f1709c4 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -9908,6 +9908,12 @@ namespace ts { else { // We are attempting to construct a type of the form X & (A | B) & Y. Transform this into a type of // the form X & A & Y | X & B & Y and recursively reduce until no union type constituents remain. + // If the estimated size of the resulting union type exceeds 100000 constituents, report an error. + const size = reduceLeft(typeSet, (n, t) => n * (t.flags & TypeFlags.Union ? (t).types.length : 1), 1); + if (size >= 100000) { + error(currentNode, Diagnostics.Expression_produces_a_union_type_that_is_too_complex_to_represent); + return errorType; + } const unionIndex = findIndex(typeSet, t => (t.flags & TypeFlags.Union) !== 0); const unionType = typeSet[unionIndex]; result = getUnionType(map(unionType.types, t => getIntersectionType(replaceElement(typeSet, unionIndex, t))), From 53f37cfec3dec5810c6099a4545f0fc974698984 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 23 May 2019 17:09:17 -0700 Subject: [PATCH 100/119] Add test --- .../normalizedIntersectionTooComplex.ts | 38 +++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 tests/cases/compiler/normalizedIntersectionTooComplex.ts diff --git a/tests/cases/compiler/normalizedIntersectionTooComplex.ts b/tests/cases/compiler/normalizedIntersectionTooComplex.ts new file mode 100644 index 00000000000..dff8bb12019 --- /dev/null +++ b/tests/cases/compiler/normalizedIntersectionTooComplex.ts @@ -0,0 +1,38 @@ +// @strict: true + +// Repro from #30050 + +interface Obj { + ref: T; +} +interface Func { + (x: T): void; +} +type UnionToIntersection = (U extends any ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never; +type CtorOf = (arg: UnionToIntersection) => T; + +interface Big { + "0": { common?: string; "0"?: number, ref?: Obj | Func; } + "1": { common?: string; "1"?: number, ref?: Obj | Func; } + "2": { common?: string; "2"?: number, ref?: Obj | Func; } + "3": { common?: string; "3"?: number, ref?: Obj | Func; } + "4": { common?: string; "4"?: number, ref?: Obj | Func; } + "5": { common?: string; "5"?: number, ref?: Obj | Func; } + "6": { common?: string; "6"?: number, ref?: Obj | Func; } + "7": { common?: string; "7"?: number, ref?: Obj | Func; } + "8": { common?: string; "8"?: number, ref?: Obj | Func; } + "9": { common?: string; "9"?: number, ref?: Obj | Func; } + "10": { common?: string; "10"?: number, ref?: Obj | Func; } + "11": { common?: string; "11"?: number, ref?: Obj | Func; } + "12": { common?: string; "12"?: number, ref?: Obj | Func; } + "13": { common?: string; "13"?: number, ref?: Obj | Func; } + "14": { common?: string; "14"?: number, ref?: Obj | Func; } + "15": { common?: string; "15"?: number, ref?: Obj | Func; } + "16": { common?: string; "16"?: number, ref?: Obj | Func; } + "17": { common?: string; "17"?: number, ref?: Obj | Func; } +} +declare function getCtor(comp: T): CtorOf + +declare var all: keyof Big; +const ctor = getCtor(all); +const comp = ctor({ common: "ok", ref: x => console.log(x) }); From 01d15145b402c65505baed1a078a8aa1c65dd4a1 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 23 May 2019 17:09:25 -0700 Subject: [PATCH 101/119] Accept new baselines --- ...ormalizedIntersectionTooComplex.errors.txt | 46 ++++ .../normalizedIntersectionTooComplex.js | 44 +++ .../normalizedIntersectionTooComplex.symbols | 250 ++++++++++++++++++ .../normalizedIntersectionTooComplex.types | 158 +++++++++++ 4 files changed, 498 insertions(+) create mode 100644 tests/baselines/reference/normalizedIntersectionTooComplex.errors.txt create mode 100644 tests/baselines/reference/normalizedIntersectionTooComplex.js create mode 100644 tests/baselines/reference/normalizedIntersectionTooComplex.symbols create mode 100644 tests/baselines/reference/normalizedIntersectionTooComplex.types diff --git a/tests/baselines/reference/normalizedIntersectionTooComplex.errors.txt b/tests/baselines/reference/normalizedIntersectionTooComplex.errors.txt new file mode 100644 index 00000000000..4e214eff507 --- /dev/null +++ b/tests/baselines/reference/normalizedIntersectionTooComplex.errors.txt @@ -0,0 +1,46 @@ +tests/cases/compiler/normalizedIntersectionTooComplex.ts(36,14): error TS2590: Expression produces a union type that is too complex to represent. +tests/cases/compiler/normalizedIntersectionTooComplex.ts(36,40): error TS7006: Parameter 'x' implicitly has an 'any' type. + + +==== tests/cases/compiler/normalizedIntersectionTooComplex.ts (2 errors) ==== + // Repro from #30050 + + interface Obj { + ref: T; + } + interface Func { + (x: T): void; + } + type UnionToIntersection = (U extends any ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never; + type CtorOf = (arg: UnionToIntersection) => T; + + interface Big { + "0": { common?: string; "0"?: number, ref?: Obj | Func; } + "1": { common?: string; "1"?: number, ref?: Obj | Func; } + "2": { common?: string; "2"?: number, ref?: Obj | Func; } + "3": { common?: string; "3"?: number, ref?: Obj | Func; } + "4": { common?: string; "4"?: number, ref?: Obj | Func; } + "5": { common?: string; "5"?: number, ref?: Obj | Func; } + "6": { common?: string; "6"?: number, ref?: Obj | Func; } + "7": { common?: string; "7"?: number, ref?: Obj | Func; } + "8": { common?: string; "8"?: number, ref?: Obj | Func; } + "9": { common?: string; "9"?: number, ref?: Obj | Func; } + "10": { common?: string; "10"?: number, ref?: Obj | Func; } + "11": { common?: string; "11"?: number, ref?: Obj | Func; } + "12": { common?: string; "12"?: number, ref?: Obj | Func; } + "13": { common?: string; "13"?: number, ref?: Obj | Func; } + "14": { common?: string; "14"?: number, ref?: Obj | Func; } + "15": { common?: string; "15"?: number, ref?: Obj | Func; } + "16": { common?: string; "16"?: number, ref?: Obj | Func; } + "17": { common?: string; "17"?: number, ref?: Obj | Func; } + } + declare function getCtor(comp: T): CtorOf + + declare var all: keyof Big; + const ctor = getCtor(all); + const comp = ctor({ common: "ok", ref: x => console.log(x) }); + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +!!! error TS2590: Expression produces a union type that is too complex to represent. + ~ +!!! error TS7006: Parameter 'x' implicitly has an 'any' type. + \ No newline at end of file diff --git a/tests/baselines/reference/normalizedIntersectionTooComplex.js b/tests/baselines/reference/normalizedIntersectionTooComplex.js new file mode 100644 index 00000000000..d55189f7a1c --- /dev/null +++ b/tests/baselines/reference/normalizedIntersectionTooComplex.js @@ -0,0 +1,44 @@ +//// [normalizedIntersectionTooComplex.ts] +// Repro from #30050 + +interface Obj { + ref: T; +} +interface Func { + (x: T): void; +} +type UnionToIntersection = (U extends any ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never; +type CtorOf = (arg: UnionToIntersection) => T; + +interface Big { + "0": { common?: string; "0"?: number, ref?: Obj | Func; } + "1": { common?: string; "1"?: number, ref?: Obj | Func; } + "2": { common?: string; "2"?: number, ref?: Obj | Func; } + "3": { common?: string; "3"?: number, ref?: Obj | Func; } + "4": { common?: string; "4"?: number, ref?: Obj | Func; } + "5": { common?: string; "5"?: number, ref?: Obj | Func; } + "6": { common?: string; "6"?: number, ref?: Obj | Func; } + "7": { common?: string; "7"?: number, ref?: Obj | Func; } + "8": { common?: string; "8"?: number, ref?: Obj | Func; } + "9": { common?: string; "9"?: number, ref?: Obj | Func; } + "10": { common?: string; "10"?: number, ref?: Obj | Func; } + "11": { common?: string; "11"?: number, ref?: Obj | Func; } + "12": { common?: string; "12"?: number, ref?: Obj | Func; } + "13": { common?: string; "13"?: number, ref?: Obj | Func; } + "14": { common?: string; "14"?: number, ref?: Obj | Func; } + "15": { common?: string; "15"?: number, ref?: Obj | Func; } + "16": { common?: string; "16"?: number, ref?: Obj | Func; } + "17": { common?: string; "17"?: number, ref?: Obj | Func; } +} +declare function getCtor(comp: T): CtorOf + +declare var all: keyof Big; +const ctor = getCtor(all); +const comp = ctor({ common: "ok", ref: x => console.log(x) }); + + +//// [normalizedIntersectionTooComplex.js] +"use strict"; +// Repro from #30050 +var ctor = getCtor(all); +var comp = ctor({ common: "ok", ref: function (x) { return console.log(x); } }); diff --git a/tests/baselines/reference/normalizedIntersectionTooComplex.symbols b/tests/baselines/reference/normalizedIntersectionTooComplex.symbols new file mode 100644 index 00000000000..0854ef907df --- /dev/null +++ b/tests/baselines/reference/normalizedIntersectionTooComplex.symbols @@ -0,0 +1,250 @@ +=== tests/cases/compiler/normalizedIntersectionTooComplex.ts === +// Repro from #30050 + +interface Obj { +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 2, 14)) + + ref: T; +>ref : Symbol(Obj.ref, Decl(normalizedIntersectionTooComplex.ts, 2, 18)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 2, 14)) +} +interface Func { +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 5, 15)) + + (x: T): void; +>x : Symbol(x, Decl(normalizedIntersectionTooComplex.ts, 6, 2)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 5, 15)) +} +type UnionToIntersection = (U extends any ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never; +>UnionToIntersection : Symbol(UnionToIntersection, Decl(normalizedIntersectionTooComplex.ts, 7, 1)) +>U : Symbol(U, Decl(normalizedIntersectionTooComplex.ts, 8, 25)) +>U : Symbol(U, Decl(normalizedIntersectionTooComplex.ts, 8, 25)) +>k : Symbol(k, Decl(normalizedIntersectionTooComplex.ts, 8, 48)) +>U : Symbol(U, Decl(normalizedIntersectionTooComplex.ts, 8, 25)) +>k : Symbol(k, Decl(normalizedIntersectionTooComplex.ts, 8, 81)) +>I : Symbol(I, Decl(normalizedIntersectionTooComplex.ts, 8, 89)) +>I : Symbol(I, Decl(normalizedIntersectionTooComplex.ts, 8, 89)) + +type CtorOf = (arg: UnionToIntersection) => T; +>CtorOf : Symbol(CtorOf, Decl(normalizedIntersectionTooComplex.ts, 8, 114)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 9, 12)) +>arg : Symbol(arg, Decl(normalizedIntersectionTooComplex.ts, 9, 18)) +>UnionToIntersection : Symbol(UnionToIntersection, Decl(normalizedIntersectionTooComplex.ts, 7, 1)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 9, 12)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 9, 12)) + +interface Big { +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "0": { common?: string; "0"?: number, ref?: Obj | Func; } +>"0" : Symbol(Big["0"], Decl(normalizedIntersectionTooComplex.ts, 11, 15)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 12, 10)) +>"0" : Symbol("0", Decl(normalizedIntersectionTooComplex.ts, 12, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 12, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "1": { common?: string; "1"?: number, ref?: Obj | Func; } +>"1" : Symbol(Big["1"], Decl(normalizedIntersectionTooComplex.ts, 12, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 13, 10)) +>"1" : Symbol("1", Decl(normalizedIntersectionTooComplex.ts, 13, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 13, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "2": { common?: string; "2"?: number, ref?: Obj | Func; } +>"2" : Symbol(Big["2"], Decl(normalizedIntersectionTooComplex.ts, 13, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 14, 10)) +>"2" : Symbol("2", Decl(normalizedIntersectionTooComplex.ts, 14, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 14, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "3": { common?: string; "3"?: number, ref?: Obj | Func; } +>"3" : Symbol(Big["3"], Decl(normalizedIntersectionTooComplex.ts, 14, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 15, 10)) +>"3" : Symbol("3", Decl(normalizedIntersectionTooComplex.ts, 15, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 15, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "4": { common?: string; "4"?: number, ref?: Obj | Func; } +>"4" : Symbol(Big["4"], Decl(normalizedIntersectionTooComplex.ts, 15, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 16, 10)) +>"4" : Symbol("4", Decl(normalizedIntersectionTooComplex.ts, 16, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 16, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "5": { common?: string; "5"?: number, ref?: Obj | Func; } +>"5" : Symbol(Big["5"], Decl(normalizedIntersectionTooComplex.ts, 16, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 17, 10)) +>"5" : Symbol("5", Decl(normalizedIntersectionTooComplex.ts, 17, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 17, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "6": { common?: string; "6"?: number, ref?: Obj | Func; } +>"6" : Symbol(Big["6"], Decl(normalizedIntersectionTooComplex.ts, 17, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 18, 10)) +>"6" : Symbol("6", Decl(normalizedIntersectionTooComplex.ts, 18, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 18, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "7": { common?: string; "7"?: number, ref?: Obj | Func; } +>"7" : Symbol(Big["7"], Decl(normalizedIntersectionTooComplex.ts, 18, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 19, 10)) +>"7" : Symbol("7", Decl(normalizedIntersectionTooComplex.ts, 19, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 19, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "8": { common?: string; "8"?: number, ref?: Obj | Func; } +>"8" : Symbol(Big["8"], Decl(normalizedIntersectionTooComplex.ts, 19, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 20, 10)) +>"8" : Symbol("8", Decl(normalizedIntersectionTooComplex.ts, 20, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 20, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "9": { common?: string; "9"?: number, ref?: Obj | Func; } +>"9" : Symbol(Big["9"], Decl(normalizedIntersectionTooComplex.ts, 20, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 21, 10)) +>"9" : Symbol("9", Decl(normalizedIntersectionTooComplex.ts, 21, 27)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 21, 41)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "10": { common?: string; "10"?: number, ref?: Obj | Func; } +>"10" : Symbol(Big["10"], Decl(normalizedIntersectionTooComplex.ts, 21, 81)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 22, 11)) +>"10" : Symbol("10", Decl(normalizedIntersectionTooComplex.ts, 22, 28)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 22, 43)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "11": { common?: string; "11"?: number, ref?: Obj | Func; } +>"11" : Symbol(Big["11"], Decl(normalizedIntersectionTooComplex.ts, 22, 85)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 23, 11)) +>"11" : Symbol("11", Decl(normalizedIntersectionTooComplex.ts, 23, 28)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 23, 43)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "12": { common?: string; "12"?: number, ref?: Obj | Func; } +>"12" : Symbol(Big["12"], Decl(normalizedIntersectionTooComplex.ts, 23, 85)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 24, 11)) +>"12" : Symbol("12", Decl(normalizedIntersectionTooComplex.ts, 24, 28)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 24, 43)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "13": { common?: string; "13"?: number, ref?: Obj | Func; } +>"13" : Symbol(Big["13"], Decl(normalizedIntersectionTooComplex.ts, 24, 85)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 25, 11)) +>"13" : Symbol("13", Decl(normalizedIntersectionTooComplex.ts, 25, 28)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 25, 43)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "14": { common?: string; "14"?: number, ref?: Obj | Func; } +>"14" : Symbol(Big["14"], Decl(normalizedIntersectionTooComplex.ts, 25, 85)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 26, 11)) +>"14" : Symbol("14", Decl(normalizedIntersectionTooComplex.ts, 26, 28)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 26, 43)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "15": { common?: string; "15"?: number, ref?: Obj | Func; } +>"15" : Symbol(Big["15"], Decl(normalizedIntersectionTooComplex.ts, 26, 85)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 27, 11)) +>"15" : Symbol("15", Decl(normalizedIntersectionTooComplex.ts, 27, 28)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 27, 43)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "16": { common?: string; "16"?: number, ref?: Obj | Func; } +>"16" : Symbol(Big["16"], Decl(normalizedIntersectionTooComplex.ts, 27, 85)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 28, 11)) +>"16" : Symbol("16", Decl(normalizedIntersectionTooComplex.ts, 28, 28)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 28, 43)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + + "17": { common?: string; "17"?: number, ref?: Obj | Func; } +>"17" : Symbol(Big["17"], Decl(normalizedIntersectionTooComplex.ts, 28, 85)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 29, 11)) +>"17" : Symbol("17", Decl(normalizedIntersectionTooComplex.ts, 29, 28)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 29, 43)) +>Obj : Symbol(Obj, Decl(normalizedIntersectionTooComplex.ts, 0, 0)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>Func : Symbol(Func, Decl(normalizedIntersectionTooComplex.ts, 4, 1)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +} +declare function getCtor(comp: T): CtorOf +>getCtor : Symbol(getCtor, Decl(normalizedIntersectionTooComplex.ts, 30, 1)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 31, 25)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>comp : Symbol(comp, Decl(normalizedIntersectionTooComplex.ts, 31, 46)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 31, 25)) +>CtorOf : Symbol(CtorOf, Decl(normalizedIntersectionTooComplex.ts, 8, 114)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) +>T : Symbol(T, Decl(normalizedIntersectionTooComplex.ts, 31, 25)) + +declare var all: keyof Big; +>all : Symbol(all, Decl(normalizedIntersectionTooComplex.ts, 33, 11)) +>Big : Symbol(Big, Decl(normalizedIntersectionTooComplex.ts, 9, 52)) + +const ctor = getCtor(all); +>ctor : Symbol(ctor, Decl(normalizedIntersectionTooComplex.ts, 34, 5)) +>getCtor : Symbol(getCtor, Decl(normalizedIntersectionTooComplex.ts, 30, 1)) +>all : Symbol(all, Decl(normalizedIntersectionTooComplex.ts, 33, 11)) + +const comp = ctor({ common: "ok", ref: x => console.log(x) }); +>comp : Symbol(comp, Decl(normalizedIntersectionTooComplex.ts, 35, 5)) +>ctor : Symbol(ctor, Decl(normalizedIntersectionTooComplex.ts, 34, 5)) +>common : Symbol(common, Decl(normalizedIntersectionTooComplex.ts, 35, 19)) +>ref : Symbol(ref, Decl(normalizedIntersectionTooComplex.ts, 35, 33)) +>x : Symbol(x, Decl(normalizedIntersectionTooComplex.ts, 35, 38)) +>console.log : Symbol(Console.log, Decl(lib.dom.d.ts, --, --)) +>console : Symbol(console, Decl(lib.dom.d.ts, --, --)) +>log : Symbol(Console.log, Decl(lib.dom.d.ts, --, --)) +>x : Symbol(x, Decl(normalizedIntersectionTooComplex.ts, 35, 38)) + diff --git a/tests/baselines/reference/normalizedIntersectionTooComplex.types b/tests/baselines/reference/normalizedIntersectionTooComplex.types new file mode 100644 index 00000000000..6750b0b0c73 --- /dev/null +++ b/tests/baselines/reference/normalizedIntersectionTooComplex.types @@ -0,0 +1,158 @@ +=== tests/cases/compiler/normalizedIntersectionTooComplex.ts === +// Repro from #30050 + +interface Obj { + ref: T; +>ref : T +} +interface Func { + (x: T): void; +>x : T +} +type UnionToIntersection = (U extends any ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never; +>UnionToIntersection : UnionToIntersection +>k : U +>k : I + +type CtorOf = (arg: UnionToIntersection) => T; +>CtorOf : CtorOf +>arg : UnionToIntersection + +interface Big { + "0": { common?: string; "0"?: number, ref?: Obj | Func; } +>"0" : { common?: string | undefined; "0"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"0" : number | undefined +>ref : Obj<{ common?: string | undefined; "0"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "0"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "1": { common?: string; "1"?: number, ref?: Obj | Func; } +>"1" : { common?: string | undefined; "1"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"1" : number | undefined +>ref : Obj<{ common?: string | undefined; "1"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "1"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "2": { common?: string; "2"?: number, ref?: Obj | Func; } +>"2" : { common?: string | undefined; "2"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"2" : number | undefined +>ref : Obj<{ common?: string | undefined; "2"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "2"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "3": { common?: string; "3"?: number, ref?: Obj | Func; } +>"3" : { common?: string | undefined; "3"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"3" : number | undefined +>ref : Obj<{ common?: string | undefined; "3"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "3"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "4": { common?: string; "4"?: number, ref?: Obj | Func; } +>"4" : { common?: string | undefined; "4"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"4" : number | undefined +>ref : Obj<{ common?: string | undefined; "4"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "4"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "5": { common?: string; "5"?: number, ref?: Obj | Func; } +>"5" : { common?: string | undefined; "5"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"5" : number | undefined +>ref : Obj<{ common?: string | undefined; "5"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "5"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "6": { common?: string; "6"?: number, ref?: Obj | Func; } +>"6" : { common?: string | undefined; "6"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"6" : number | undefined +>ref : Obj<{ common?: string | undefined; "6"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "6"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "7": { common?: string; "7"?: number, ref?: Obj | Func; } +>"7" : { common?: string | undefined; "7"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"7" : number | undefined +>ref : Obj<{ common?: string | undefined; "7"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "7"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "8": { common?: string; "8"?: number, ref?: Obj | Func; } +>"8" : { common?: string | undefined; "8"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"8" : number | undefined +>ref : Obj<{ common?: string | undefined; "8"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "8"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "9": { common?: string; "9"?: number, ref?: Obj | Func; } +>"9" : { common?: string | undefined; "9"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"9" : number | undefined +>ref : Obj<{ common?: string | undefined; "9"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "9"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "10": { common?: string; "10"?: number, ref?: Obj | Func; } +>"10" : { common?: string | undefined; "10"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"10" : number | undefined +>ref : Obj<{ common?: string | undefined; "10"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "10"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "11": { common?: string; "11"?: number, ref?: Obj | Func; } +>"11" : { common?: string | undefined; "11"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"11" : number | undefined +>ref : Obj<{ common?: string | undefined; "11"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "11"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "12": { common?: string; "12"?: number, ref?: Obj | Func; } +>"12" : { common?: string | undefined; "12"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"12" : number | undefined +>ref : Obj<{ common?: string | undefined; "12"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "12"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "13": { common?: string; "13"?: number, ref?: Obj | Func; } +>"13" : { common?: string | undefined; "13"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"13" : number | undefined +>ref : Obj<{ common?: string | undefined; "13"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "13"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "14": { common?: string; "14"?: number, ref?: Obj | Func; } +>"14" : { common?: string | undefined; "14"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"14" : number | undefined +>ref : Obj<{ common?: string | undefined; "14"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "14"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "15": { common?: string; "15"?: number, ref?: Obj | Func; } +>"15" : { common?: string | undefined; "15"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"15" : number | undefined +>ref : Obj<{ common?: string | undefined; "15"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "15"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "16": { common?: string; "16"?: number, ref?: Obj | Func; } +>"16" : { common?: string | undefined; "16"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"16" : number | undefined +>ref : Obj<{ common?: string | undefined; "16"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "16"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined + + "17": { common?: string; "17"?: number, ref?: Obj | Func; } +>"17" : { common?: string | undefined; "17"?: number | undefined; ref?: Obj | Func | undefined; } +>common : string | undefined +>"17" : number | undefined +>ref : Obj<{ common?: string | undefined; "17"?: number | undefined; ref?: Obj | Func | undefined; }> | Func<{ common?: string | undefined; "17"?: number | undefined; ref?: Obj | Func | undefined; }> | undefined +} +declare function getCtor(comp: T): CtorOf +>getCtor : (comp: T) => CtorOf +>comp : T + +declare var all: keyof Big; +>all : "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12" | "13" | "14" | "15" | "16" | "17" + +const ctor = getCtor(all); +>ctor : CtorOf<{ common?: string | undefined; "0"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "1"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "2"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "3"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "4"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "5"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "6"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "7"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "8"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "9"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "10"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "11"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "12"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "13"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "14"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "15"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "16"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "17"?: number | undefined; ref?: Obj | Func | undefined; }> +>getCtor(all) : CtorOf<{ common?: string | undefined; "0"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "1"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "2"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "3"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "4"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "5"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "6"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "7"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "8"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "9"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "10"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "11"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "12"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "13"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "14"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "15"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "16"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "17"?: number | undefined; ref?: Obj | Func | undefined; }> +>getCtor : (comp: T) => CtorOf +>all : "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12" | "13" | "14" | "15" | "16" | "17" + +const comp = ctor({ common: "ok", ref: x => console.log(x) }); +>comp : { common?: string | undefined; "0"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "1"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "2"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "3"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "4"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "5"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "6"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "7"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "8"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "9"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "10"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "11"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "12"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "13"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "14"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "15"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "16"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "17"?: number | undefined; ref?: Obj | Func | undefined; } +>ctor({ common: "ok", ref: x => console.log(x) }) : { common?: string | undefined; "0"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "1"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "2"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "3"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "4"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "5"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "6"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "7"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "8"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "9"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "10"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "11"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "12"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "13"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "14"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "15"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "16"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "17"?: number | undefined; ref?: Obj | Func | undefined; } +>ctor : CtorOf<{ common?: string | undefined; "0"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "1"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "2"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "3"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "4"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "5"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "6"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "7"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "8"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "9"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "10"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "11"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "12"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "13"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "14"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "15"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "16"?: number | undefined; ref?: Obj | Func | undefined; } | { common?: string | undefined; "17"?: number | undefined; ref?: Obj | Func | undefined; }> +>{ common: "ok", ref: x => console.log(x) } : { common: string; ref: (x: any) => void; } +>common : string +>"ok" : "ok" +>ref : (x: any) => void +>x => console.log(x) : (x: any) => void +>x : any +>console.log(x) : void +>console.log : (message?: any, ...optionalParams: any[]) => void +>console : Console +>log : (message?: any, ...optionalParams: any[]) => void +>x : any + From bb4080c175d0f554070b963bee05a0696bc958a2 Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Thu, 23 May 2019 17:17:24 -0700 Subject: [PATCH 102/119] Collect _all_ symlinks a file may have witnessed when attempting to generate specifiers (#31571) --- src/compiler/moduleSpecifiers.ts | 6 +-- ...arationEmitForGlobalishSpecifierSymlink.js | 45 +++++++++++++++++++ ...onEmitForGlobalishSpecifierSymlink.symbols | 43 ++++++++++++++++++ ...tionEmitForGlobalishSpecifierSymlink.types | 41 +++++++++++++++++ ...rationEmitForGlobalishSpecifierSymlink2.js | 33 ++++++++++++++ ...nEmitForGlobalishSpecifierSymlink2.symbols | 30 +++++++++++++ ...ionEmitForGlobalishSpecifierSymlink2.types | 29 ++++++++++++ ...arationEmitForGlobalishSpecifierSymlink.ts | 35 +++++++++++++++ ...rationEmitForGlobalishSpecifierSymlink2.ts | 25 +++++++++++ 9 files changed, 284 insertions(+), 3 deletions(-) create mode 100644 tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.js create mode 100644 tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.symbols create mode 100644 tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.types create mode 100644 tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.js create mode 100644 tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.symbols create mode 100644 tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.types create mode 100644 tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink.ts create mode 100644 tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink2.ts diff --git a/src/compiler/moduleSpecifiers.ts b/src/compiler/moduleSpecifiers.ts index 59bb74a22c1..bc448698c69 100644 --- a/src/compiler/moduleSpecifiers.ts +++ b/src/compiler/moduleSpecifiers.ts @@ -175,9 +175,9 @@ namespace ts.moduleSpecifiers { function discoverProbableSymlinks(files: ReadonlyArray, getCanonicalFileName: GetCanonicalFileName, cwd: string): ReadonlyMap { const result = createMap(); - const symlinks = mapDefined(files, sf => - sf.resolvedModules && firstDefinedIterator(sf.resolvedModules.values(), res => - res && res.originalPath && res.resolvedFileName !== res.originalPath ? [res.resolvedFileName, res.originalPath] : undefined)); + const symlinks = flatten(mapDefined(files, sf => + sf.resolvedModules && compact(arrayFrom(mapIterator(sf.resolvedModules.values(), res => + res && res.originalPath && res.resolvedFileName !== res.originalPath ? [res.resolvedFileName, res.originalPath] as const : undefined))))); for (const [resolvedPath, originalPath] of symlinks) { const [commonResolved, commonOriginal] = guessDirectorySymlink(resolvedPath, originalPath, cwd, getCanonicalFileName); result.set(commonOriginal, commonResolved); diff --git a/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.js b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.js new file mode 100644 index 00000000000..00efdd49280 --- /dev/null +++ b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.js @@ -0,0 +1,45 @@ +//// [tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink.ts] //// + +//// [impl.d.ts] +export function getA(): A; +export enum A { + Val +} +//// [index.d.ts] +export * from "./src/impl"; +//// [package.json] +{ + "name": "typescript-fsa", + "version": "1.0.0" +} +//// [impl.d.ts] +export function getA(): A; +export enum A { + Val +} +//// [index.d.ts] +export * from "./src/impl"; +//// [package.json] +{ + "name": "typescript-fsa", + "version": "1.0.0" +} +//// [index.ts] +import * as _whatever from "p2"; +import { getA } from "typescript-fsa"; + +export const a = getA(); +//// [index.d.ts] +export const a: import("typescript-fsa").A; + + + +//// [index.js] +"use strict"; +exports.__esModule = true; +var typescript_fsa_1 = require("typescript-fsa"); +exports.a = typescript_fsa_1.getA(); + + +//// [index.d.ts] +export declare const a: import("typescript-fsa").A; diff --git a/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.symbols b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.symbols new file mode 100644 index 00000000000..fa0a8593339 --- /dev/null +++ b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.symbols @@ -0,0 +1,43 @@ +=== /p1/node_modules/typescript-fsa/src/impl.d.ts === +export function getA(): A; +>getA : Symbol(getA, Decl(impl.d.ts, 0, 0)) +>A : Symbol(A, Decl(impl.d.ts, 0, 26)) + +export enum A { +>A : Symbol(A, Decl(impl.d.ts, 0, 26)) + + Val +>Val : Symbol(A.Val, Decl(impl.d.ts, 1, 15)) +} +=== /p1/node_modules/typescript-fsa/index.d.ts === +export * from "./src/impl"; +No type information for this code.=== /p2/node_modules/typescript-fsa/src/impl.d.ts === +export function getA(): A; +>getA : Symbol(getA, Decl(impl.d.ts, 0, 0)) +>A : Symbol(A, Decl(impl.d.ts, 0, 26)) + +export enum A { +>A : Symbol(A, Decl(impl.d.ts, 0, 26)) + + Val +>Val : Symbol(A.Val, Decl(impl.d.ts, 1, 15)) +} +=== /p2/node_modules/typescript-fsa/index.d.ts === +export * from "./src/impl"; +No type information for this code.=== /p1/index.ts === +import * as _whatever from "p2"; +>_whatever : Symbol(_whatever, Decl(index.ts, 0, 6)) + +import { getA } from "typescript-fsa"; +>getA : Symbol(getA, Decl(index.ts, 1, 8)) + +export const a = getA(); +>a : Symbol(a, Decl(index.ts, 3, 12)) +>getA : Symbol(getA, Decl(index.ts, 1, 8)) + +=== /p2/index.d.ts === +export const a: import("typescript-fsa").A; +>a : Symbol(a, Decl(index.d.ts, 0, 12)) +>A : Symbol(A, Decl(impl.d.ts, 0, 26)) + + diff --git a/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.types b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.types new file mode 100644 index 00000000000..3f62193fd83 --- /dev/null +++ b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.types @@ -0,0 +1,41 @@ +=== /p1/node_modules/typescript-fsa/src/impl.d.ts === +export function getA(): A; +>getA : () => A + +export enum A { +>A : A + + Val +>Val : A +} +=== /p1/node_modules/typescript-fsa/index.d.ts === +export * from "./src/impl"; +No type information for this code.=== /p2/node_modules/typescript-fsa/src/impl.d.ts === +export function getA(): A; +>getA : () => A + +export enum A { +>A : A + + Val +>Val : A +} +=== /p2/node_modules/typescript-fsa/index.d.ts === +export * from "./src/impl"; +No type information for this code.=== /p1/index.ts === +import * as _whatever from "p2"; +>_whatever : typeof _whatever + +import { getA } from "typescript-fsa"; +>getA : () => import("/p1/node_modules/typescript-fsa/index").A + +export const a = getA(); +>a : import("/p1/node_modules/typescript-fsa/index").A +>getA() : import("/p1/node_modules/typescript-fsa/index").A +>getA : () => import("/p1/node_modules/typescript-fsa/index").A + +=== /p2/index.d.ts === +export const a: import("typescript-fsa").A; +>a : import("/p2/node_modules/typescript-fsa/index").A + + diff --git a/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.js b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.js new file mode 100644 index 00000000000..22889aba461 --- /dev/null +++ b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.js @@ -0,0 +1,33 @@ +//// [tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink2.ts] //// + +//// [impl.d.ts] +export function getA(): A; +export enum A { + Val +} +//// [index.d.ts] +export * from "./src/impl"; +//// [package.json] +{ + "name": "typescript-fsa", + "version": "1.0.0" +} +//// [index.ts] +import * as _whatever from "p2"; +import { getA } from "typescript-fsa"; + +export const a = getA(); +//// [index.d.ts] +export const a: import("typescript-fsa").A; + + + +//// [index.js] +"use strict"; +exports.__esModule = true; +var typescript_fsa_1 = require("typescript-fsa"); +exports.a = typescript_fsa_1.getA(); + + +//// [index.d.ts] +export declare const a: import("typescript-fsa").A; diff --git a/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.symbols b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.symbols new file mode 100644 index 00000000000..e183f07d558 --- /dev/null +++ b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.symbols @@ -0,0 +1,30 @@ +=== /cache/typescript-fsa/src/impl.d.ts === +export function getA(): A; +>getA : Symbol(getA, Decl(impl.d.ts, 0, 0)) +>A : Symbol(A, Decl(impl.d.ts, 0, 26)) + +export enum A { +>A : Symbol(A, Decl(impl.d.ts, 0, 26)) + + Val +>Val : Symbol(A.Val, Decl(impl.d.ts, 1, 15)) +} +=== /cache/typescript-fsa/index.d.ts === +export * from "./src/impl"; +No type information for this code.=== /p1/index.ts === +import * as _whatever from "p2"; +>_whatever : Symbol(_whatever, Decl(index.ts, 0, 6)) + +import { getA } from "typescript-fsa"; +>getA : Symbol(getA, Decl(index.ts, 1, 8)) + +export const a = getA(); +>a : Symbol(a, Decl(index.ts, 3, 12)) +>getA : Symbol(getA, Decl(index.ts, 1, 8)) + +=== /p2/index.d.ts === +export const a: import("typescript-fsa").A; +>a : Symbol(a, Decl(index.d.ts, 0, 12)) +>A : Symbol(A, Decl(impl.d.ts, 0, 26)) + + diff --git a/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.types b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.types new file mode 100644 index 00000000000..7c214ced6b6 --- /dev/null +++ b/tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.types @@ -0,0 +1,29 @@ +=== /cache/typescript-fsa/src/impl.d.ts === +export function getA(): A; +>getA : () => A + +export enum A { +>A : A + + Val +>Val : A +} +=== /cache/typescript-fsa/index.d.ts === +export * from "./src/impl"; +No type information for this code.=== /p1/index.ts === +import * as _whatever from "p2"; +>_whatever : typeof _whatever + +import { getA } from "typescript-fsa"; +>getA : () => import("/cache/typescript-fsa/index").A + +export const a = getA(); +>a : import("/cache/typescript-fsa/index").A +>getA() : import("/cache/typescript-fsa/index").A +>getA : () => import("/cache/typescript-fsa/index").A + +=== /p2/index.d.ts === +export const a: import("typescript-fsa").A; +>a : import("/cache/typescript-fsa/index").A + + diff --git a/tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink.ts b/tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink.ts new file mode 100644 index 00000000000..b42d679b521 --- /dev/null +++ b/tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink.ts @@ -0,0 +1,35 @@ +// @useCaseSensitiveFilenames: true +// @declaration: true +// @filename: /p1/node_modules/typescript-fsa/src/impl.d.ts +export function getA(): A; +export enum A { + Val +} +// @filename: /p1/node_modules/typescript-fsa/index.d.ts +export * from "./src/impl"; +// @filename: /p1/node_modules/typescript-fsa/package.json +{ + "name": "typescript-fsa", + "version": "1.0.0" +} +// @filename: /p2/node_modules/typescript-fsa/src/impl.d.ts +export function getA(): A; +export enum A { + Val +} +// @filename: /p2/node_modules/typescript-fsa/index.d.ts +export * from "./src/impl"; +// @filename: /p2/node_modules/typescript-fsa/package.json +{ + "name": "typescript-fsa", + "version": "1.0.0" +} +// @filename: /p1/index.ts +import * as _whatever from "p2"; +import { getA } from "typescript-fsa"; + +export const a = getA(); +// @filename: /p2/index.d.ts +export const a: import("typescript-fsa").A; + +// @link: /p2 -> /p1/node_modules/p2 diff --git a/tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink2.ts b/tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink2.ts new file mode 100644 index 00000000000..5b46de99622 --- /dev/null +++ b/tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink2.ts @@ -0,0 +1,25 @@ +// @useCaseSensitiveFilenames: true +// @declaration: true +// @filename: /cache/typescript-fsa/src/impl.d.ts +export function getA(): A; +export enum A { + Val +} +// @filename: /cache/typescript-fsa/index.d.ts +export * from "./src/impl"; +// @filename: /cache/typescript-fsa/package.json +{ + "name": "typescript-fsa", + "version": "1.0.0" +} +// @filename: /p1/index.ts +import * as _whatever from "p2"; +import { getA } from "typescript-fsa"; + +export const a = getA(); +// @filename: /p2/index.d.ts +export const a: import("typescript-fsa").A; + +// @link: /p2 -> /p1/node_modules/p2 +// @link: /cache/typescript-fsa -> /p1/node_modules/typescript-fsa +// @link: /cache/typescript-fsa -> /p2/node_modules/typescript-fsa From dfd28d275100db73433318236a2299b002cf0ce3 Mon Sep 17 00:00:00 2001 From: Ron Buckton Date: Thu, 23 May 2019 17:19:32 -0700 Subject: [PATCH 103/119] Fix handling of empty 'types', 'typings', etc. fields in package.json (#31539) --- src/compiler/diagnosticMessages.json | 4 ++++ src/compiler/moduleNameResolver.ts | 10 +++++++- .../reference/typesVersions.emptyTypes.js | 20 ++++++++++++++++ .../typesVersions.emptyTypes.symbols | 8 +++++++ .../typesVersions.emptyTypes.trace.json | 24 +++++++++++++++++++ .../reference/typesVersions.emptyTypes.types | 9 +++++++ .../typesVersions.emptyTypes.ts | 18 ++++++++++++++ 7 files changed, 92 insertions(+), 1 deletion(-) create mode 100644 tests/baselines/reference/typesVersions.emptyTypes.js create mode 100644 tests/baselines/reference/typesVersions.emptyTypes.symbols create mode 100644 tests/baselines/reference/typesVersions.emptyTypes.trace.json create mode 100644 tests/baselines/reference/typesVersions.emptyTypes.types create mode 100644 tests/cases/conformance/moduleResolution/typesVersions.emptyTypes.ts diff --git a/src/compiler/diagnosticMessages.json b/src/compiler/diagnosticMessages.json index e0579429def..5d6dc7d6df4 100644 --- a/src/compiler/diagnosticMessages.json +++ b/src/compiler/diagnosticMessages.json @@ -3927,6 +3927,10 @@ "category": "Message", "code": 6219 }, + "'package.json' had a falsy '{0}' field.": { + "category": "Message", + "code": 6220 + }, "Projects to reference": { "category": "Message", diff --git a/src/compiler/moduleNameResolver.ts b/src/compiler/moduleNameResolver.ts index 19402b03ee9..604b82cce5e 100644 --- a/src/compiler/moduleNameResolver.ts +++ b/src/compiler/moduleNameResolver.ts @@ -141,7 +141,15 @@ namespace ts { function readPackageJsonPathField(jsonContent: PackageJson, fieldName: K, baseDirectory: string, state: ModuleResolutionState): PackageJson[K] | undefined { const fileName = readPackageJsonField(jsonContent, fieldName, "string", state); - if (fileName === undefined) return; + if (fileName === undefined) { + return; + } + if (!fileName) { + if (state.traceEnabled) { + trace(state.host, Diagnostics.package_json_had_a_falsy_0_field, fieldName); + } + return; + } const path = normalizePath(combinePaths(baseDirectory, fileName)); if (state.traceEnabled) { trace(state.host, Diagnostics.package_json_has_0_field_1_that_references_2, fieldName, fileName, path); diff --git a/tests/baselines/reference/typesVersions.emptyTypes.js b/tests/baselines/reference/typesVersions.emptyTypes.js new file mode 100644 index 00000000000..0bcc27d7a65 --- /dev/null +++ b/tests/baselines/reference/typesVersions.emptyTypes.js @@ -0,0 +1,20 @@ +//// [tests/cases/conformance/moduleResolution/typesVersions.emptyTypes.ts] //// + +//// [package.json] +{ + "types": "", + "typesVersions": { + ">=3.1.0-0": { "*" : ["ts3.1/*"] } + } +} + +//// [index.d.ts] +export const a = 0; + +//// [user.ts] +import { a } from "a"; + + +//// [user.js] +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); diff --git a/tests/baselines/reference/typesVersions.emptyTypes.symbols b/tests/baselines/reference/typesVersions.emptyTypes.symbols new file mode 100644 index 00000000000..a4441e407d7 --- /dev/null +++ b/tests/baselines/reference/typesVersions.emptyTypes.symbols @@ -0,0 +1,8 @@ +=== /a/ts3.1/index.d.ts === +export const a = 0; +>a : Symbol(a, Decl(index.d.ts, 0, 12)) + +=== /b/user.ts === +import { a } from "a"; +>a : Symbol(a, Decl(user.ts, 0, 8)) + diff --git a/tests/baselines/reference/typesVersions.emptyTypes.trace.json b/tests/baselines/reference/typesVersions.emptyTypes.trace.json new file mode 100644 index 00000000000..e7a9e7547cf --- /dev/null +++ b/tests/baselines/reference/typesVersions.emptyTypes.trace.json @@ -0,0 +1,24 @@ +[ + "======== Resolving module 'a' from '/b/user.ts'. ========", + "Module resolution kind is not specified, using 'NodeJs'.", + "'baseUrl' option is set to '/', using this value to resolve non-relative module name 'a'.", + "Resolving module name 'a' relative to base url '/' - '/a'.", + "Loading module as file / folder, candidate module location '/a', target file type 'TypeScript'.", + "File '/a.ts' does not exist.", + "File '/a.tsx' does not exist.", + "File '/a.d.ts' does not exist.", + "Found 'package.json' at '/a/package.json'.", + "'package.json' has a 'typesVersions' field with version-specific path mappings.", + "'package.json' does not have a 'typings' field.", + "'package.json' had a falsy 'types' field.", + "'package.json' does not have a 'main' field.", + "'package.json' has a 'typesVersions' entry '>=3.1.0-0' that matches compiler version '3.1.0-dev', looking for a pattern to match module name 'index'.", + "Module name 'index', matched pattern '*'.", + "Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.", + "File '/a/ts3.1/index' does not exist.", + "Loading module as file / folder, candidate module location '/a/ts3.1/index', target file type 'TypeScript'.", + "File '/a/ts3.1/index.ts' does not exist.", + "File '/a/ts3.1/index.tsx' does not exist.", + "File '/a/ts3.1/index.d.ts' exist - use it as a name resolution result.", + "======== Module name 'a' was successfully resolved to '/a/ts3.1/index.d.ts'. ========" +] \ No newline at end of file diff --git a/tests/baselines/reference/typesVersions.emptyTypes.types b/tests/baselines/reference/typesVersions.emptyTypes.types new file mode 100644 index 00000000000..578d4695e1c --- /dev/null +++ b/tests/baselines/reference/typesVersions.emptyTypes.types @@ -0,0 +1,9 @@ +=== /a/ts3.1/index.d.ts === +export const a = 0; +>a : 0 +>0 : 0 + +=== /b/user.ts === +import { a } from "a"; +>a : 0 + diff --git a/tests/cases/conformance/moduleResolution/typesVersions.emptyTypes.ts b/tests/cases/conformance/moduleResolution/typesVersions.emptyTypes.ts new file mode 100644 index 00000000000..f5d0792bfc4 --- /dev/null +++ b/tests/cases/conformance/moduleResolution/typesVersions.emptyTypes.ts @@ -0,0 +1,18 @@ +// @baseUrl: / +// @traceResolution: true +// @target: esnext +// @module: commonjs + +// @filename: /a/package.json +{ + "types": "", + "typesVersions": { + ">=3.1.0-0": { "*" : ["ts3.1/*"] } + } +} + +// @filename: /a/ts3.1/index.d.ts +export const a = 0; + +// @filename: /b/user.ts +import { a } from "a"; From b460d8cd267a8fc01c949289de96d424223a666d Mon Sep 17 00:00:00 2001 From: Ron Buckton Date: Thu, 23 May 2019 17:50:44 -0700 Subject: [PATCH 104/119] Expose getTypeOfArrayLiteralOrObjectLiteralDestructuringAssignment with better name (#31564) --- src/compiler/checker.ts | 21 +++++++++++-------- src/compiler/types.ts | 1 + .../reference/api/tsserverlibrary.d.ts | 1 + tests/baselines/reference/api/typescript.d.ts | 1 + 4 files changed, 15 insertions(+), 9 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 0d7c7b022dd..b1e62d69e22 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -182,6 +182,10 @@ namespace ts { node = getParseTreeNode(node); return node ? getTypeOfNode(node) : errorType; }, + getTypeOfAssignmentPattern: nodeIn => { + const node = getParseTreeNode(nodeIn, isAssignmentPattern); + return node && getTypeOfAssignmentPattern(node) || errorType; + }, getPropertySymbolOfDestructuringAssignment: locationIn => { const location = getParseTreeNode(locationIn, isIdentifier); return location ? getPropertySymbolOfDestructuringAssignment(location) : undefined; @@ -29982,7 +29986,7 @@ namespace ts { // } // [ a ] from // [a] = [ some array ...] - function getTypeOfArrayLiteralOrObjectLiteralDestructuringAssignment(expr: Expression): Type { + function getTypeOfAssignmentPattern(expr: AssignmentPattern): Type | undefined { Debug.assert(expr.kind === SyntaxKind.ObjectLiteralExpression || expr.kind === SyntaxKind.ArrayLiteralExpression); // If this is from "for of" // for ( { a } of elems) { @@ -30001,17 +30005,16 @@ namespace ts { // for ({ skills: { primary, secondary } } = multiRobot, i = 0; i < 1; i++) { if (expr.parent.kind === SyntaxKind.PropertyAssignment) { const node = cast(expr.parent.parent, isObjectLiteralExpression); - const typeOfParentObjectLiteral = getTypeOfArrayLiteralOrObjectLiteralDestructuringAssignment(node); + const typeOfParentObjectLiteral = getTypeOfAssignmentPattern(node) || errorType; const propertyIndex = indexOfNode(node.properties, expr.parent); - return checkObjectLiteralDestructuringPropertyAssignment(node, typeOfParentObjectLiteral || errorType, propertyIndex)!; // TODO: GH#18217 + return checkObjectLiteralDestructuringPropertyAssignment(node, typeOfParentObjectLiteral, propertyIndex); } // Array literal assignment - array destructuring pattern - Debug.assert(expr.parent.kind === SyntaxKind.ArrayLiteralExpression); + const node = cast(expr.parent, isArrayLiteralExpression); // [{ property1: p1, property2 }] = elems; - const typeOfArrayLiteral = getTypeOfArrayLiteralOrObjectLiteralDestructuringAssignment(expr.parent); - const elementType = checkIteratedTypeOrElementType(typeOfArrayLiteral || errorType, expr.parent, /*allowStringInput*/ false, /*allowAsyncIterables*/ false) || errorType; - return checkArrayLiteralDestructuringElementAssignment(expr.parent, typeOfArrayLiteral, - (expr.parent).elements.indexOf(expr), elementType || errorType)!; // TODO: GH#18217 + const typeOfArrayLiteral = getTypeOfAssignmentPattern(node) || errorType; + const elementType = checkIteratedTypeOrElementType(typeOfArrayLiteral, expr.parent, /*allowStringInput*/ false, /*allowAsyncIterables*/ false) || errorType; + return checkArrayLiteralDestructuringElementAssignment(node, typeOfArrayLiteral, node.elements.indexOf(expr), elementType); } // Gets the property symbol corresponding to the property in destructuring assignment @@ -30022,7 +30025,7 @@ namespace ts { // [a] = [ property1, property2 ] function getPropertySymbolOfDestructuringAssignment(location: Identifier) { // Get the type of the object or array literal and then look for property of given name in the type - const typeOfObjectLiteral = getTypeOfArrayLiteralOrObjectLiteralDestructuringAssignment(location.parent.parent); + const typeOfObjectLiteral = getTypeOfAssignmentPattern(cast(location.parent.parent, isAssignmentPattern)); return typeOfObjectLiteral && getPropertyOfType(typeOfObjectLiteral, location.escapedText); } diff --git a/src/compiler/types.ts b/src/compiler/types.ts index db1a62937e6..03ca196a860 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -3154,6 +3154,7 @@ namespace ts { */ getExportSymbolOfSymbol(symbol: Symbol): Symbol; getPropertySymbolOfDestructuringAssignment(location: Identifier): Symbol | undefined; + getTypeOfAssignmentPattern(pattern: AssignmentPattern): Type; getTypeAtLocation(node: Node): Type; getTypeFromTypeNode(node: TypeNode): Type; diff --git a/tests/baselines/reference/api/tsserverlibrary.d.ts b/tests/baselines/reference/api/tsserverlibrary.d.ts index 4b06bc9e839..d10aa28ffe4 100644 --- a/tests/baselines/reference/api/tsserverlibrary.d.ts +++ b/tests/baselines/reference/api/tsserverlibrary.d.ts @@ -1969,6 +1969,7 @@ declare namespace ts { */ getExportSymbolOfSymbol(symbol: Symbol): Symbol; getPropertySymbolOfDestructuringAssignment(location: Identifier): Symbol | undefined; + getTypeOfAssignmentPattern(pattern: AssignmentPattern): Type; getTypeAtLocation(node: Node): Type; getTypeFromTypeNode(node: TypeNode): Type; signatureToString(signature: Signature, enclosingDeclaration?: Node, flags?: TypeFormatFlags, kind?: SignatureKind): string; diff --git a/tests/baselines/reference/api/typescript.d.ts b/tests/baselines/reference/api/typescript.d.ts index f70916a882b..58ccd42344b 100644 --- a/tests/baselines/reference/api/typescript.d.ts +++ b/tests/baselines/reference/api/typescript.d.ts @@ -1969,6 +1969,7 @@ declare namespace ts { */ getExportSymbolOfSymbol(symbol: Symbol): Symbol; getPropertySymbolOfDestructuringAssignment(location: Identifier): Symbol | undefined; + getTypeOfAssignmentPattern(pattern: AssignmentPattern): Type; getTypeAtLocation(node: Node): Type; getTypeFromTypeNode(node: TypeNode): Type; signatureToString(signature: Signature, enclosingDeclaration?: Node, flags?: TypeFormatFlags, kind?: SignatureKind): string; From 57d9ecc39f588917c3c587795dea739f740b066b Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Fri, 24 May 2019 15:04:42 -0700 Subject: [PATCH 105/119] Do not log errors when ts server plugin is not found in one folder but is eventually resolved. Fixes #30106 --- src/server/project.ts | 14 +++++++------- tests/baselines/reference/api/tsserverlibrary.d.ts | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/server/project.ts b/src/server/project.ts index c204facad5c..20cd5667dd9 100644 --- a/src/server/project.ts +++ b/src/server/project.ts @@ -198,13 +198,13 @@ namespace ts.server { return hasOneOrMoreJsAndNoTsFiles(this); } - public static resolveModule(moduleName: string, initialDir: string, host: ServerHost, log: (message: string) => void): {} | undefined { + public static resolveModule(moduleName: string, initialDir: string, host: ServerHost, log: (message: string) => void, logErrors?: (message: string) => void): {} | undefined { const resolvedPath = normalizeSlashes(host.resolvePath(combinePaths(initialDir, "node_modules"))); log(`Loading ${moduleName} from ${initialDir} (resolved to ${resolvedPath})`); const result = host.require!(resolvedPath, moduleName); // TODO: GH#18217 if (result.error) { const err = result.error.stack || result.error.message || JSON.stringify(result.error); - log(`Failed to load module '${moduleName}': ${err}`); + (logErrors || log)(`Failed to load module '${moduleName}' from ${resolvedPath}: ${err}`); return undefined; } return result.module; @@ -1142,12 +1142,11 @@ namespace ts.server { protected enablePlugin(pluginConfigEntry: PluginImport, searchPaths: string[], pluginConfigOverrides: Map | undefined) { this.projectService.logger.info(`Enabling plugin ${pluginConfigEntry.name} from candidate paths: ${searchPaths.join(",")}`); - const log = (message: string) => { - this.projectService.logger.info(message); - }; - + const log = (message: string) => this.projectService.logger.info(message); + let errorLogs: string[] | undefined; + const logError = (message: string) => { (errorLogs || (errorLogs = [])).push(message); }; const resolvedModule = firstDefined(searchPaths, searchPath => - Project.resolveModule(pluginConfigEntry.name, searchPath, this.projectService.host, log)); + Project.resolveModule(pluginConfigEntry.name, searchPath, this.projectService.host, log, logError)); if (resolvedModule) { const configurationOverride = pluginConfigOverrides && pluginConfigOverrides.get(pluginConfigEntry.name); if (configurationOverride) { @@ -1160,6 +1159,7 @@ namespace ts.server { this.enableProxy(resolvedModule, pluginConfigEntry); } else { + forEach(errorLogs, log); this.projectService.logger.info(`Couldn't find ${pluginConfigEntry.name}`); } } diff --git a/tests/baselines/reference/api/tsserverlibrary.d.ts b/tests/baselines/reference/api/tsserverlibrary.d.ts index d10aa28ffe4..993a7494994 100644 --- a/tests/baselines/reference/api/tsserverlibrary.d.ts +++ b/tests/baselines/reference/api/tsserverlibrary.d.ts @@ -8321,7 +8321,7 @@ declare namespace ts.server { private readonly cancellationToken; isNonTsProject(): boolean; isJsOnlyProject(): boolean; - static resolveModule(moduleName: string, initialDir: string, host: ServerHost, log: (message: string) => void): {} | undefined; + static resolveModule(moduleName: string, initialDir: string, host: ServerHost, log: (message: string) => void, logErrors?: (message: string) => void): {} | undefined; isKnownTypesPackageName(name: string): boolean; installPackage(options: InstallPackageOptions): Promise; private readonly typingsCache; From e70f2af25d7d94a88ef0d852c35e38ce8504d59f Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Tue, 28 May 2019 10:51:47 -0700 Subject: [PATCH 106/119] Defer union or intersection property type normalization (#31486) * Defer union or intersection property type normalization * Accept moved span --- src/compiler/checker.ts | 77 +++++++++++++++++-- src/compiler/types.ts | 3 + .../reference/intersectionTypeMembers.js | 34 ++++++++ .../reference/intersectionTypeMembers.symbols | 55 +++++++++++++ .../reference/intersectionTypeMembers.types | 58 ++++++++++++++ ...ormalizedIntersectionTooComplex.errors.txt | 6 +- .../reactTagNameComponentWithPropsNoOOM.js | 33 ++++++++ ...eactTagNameComponentWithPropsNoOOM.symbols | 32 ++++++++ .../reactTagNameComponentWithPropsNoOOM.types | 35 +++++++++ .../reactTagNameComponentWithPropsNoOOM2.js | 33 ++++++++ ...actTagNameComponentWithPropsNoOOM2.symbols | 35 +++++++++ ...reactTagNameComponentWithPropsNoOOM2.types | 36 +++++++++ .../reactTagNameComponentWithPropsNoOOM.tsx | 13 ++++ .../reactTagNameComponentWithPropsNoOOM2.tsx | 13 ++++ .../intersection/intersectionTypeMembers.ts | 22 ++++++ 15 files changed, 474 insertions(+), 11 deletions(-) create mode 100644 tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.js create mode 100644 tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.symbols create mode 100644 tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.types create mode 100644 tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.js create mode 100644 tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.symbols create mode 100644 tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.types create mode 100644 tests/cases/compiler/reactTagNameComponentWithPropsNoOOM.tsx create mode 100644 tests/cases/compiler/reactTagNameComponentWithPropsNoOOM2.tsx diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 5091f5f0306..d59cf4c5470 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -5921,7 +5921,20 @@ namespace ts { return anyType; } + function getTypeOfSymbolWithDeferredType(symbol: Symbol) { + const links = getSymbolLinks(symbol); + if (!links.type) { + Debug.assertDefined(links.deferralParent); + Debug.assertDefined(links.deferralConstituents); + links.type = links.deferralParent!.flags & TypeFlags.Union ? getUnionType(links.deferralConstituents!) : getIntersectionType(links.deferralConstituents!); + } + return links.type; + } + function getTypeOfSymbol(symbol: Symbol): Type { + if (getCheckFlags(symbol) & CheckFlags.DeferredType) { + return getTypeOfSymbolWithDeferredType(symbol); + } if (getCheckFlags(symbol) & CheckFlags.Instantiated) { return getTypeOfInstantiatedSymbol(symbol); } @@ -8061,7 +8074,15 @@ namespace ts { result.declarations = declarations!; result.nameType = nameType; - result.type = isUnion ? getUnionType(propTypes) : getIntersectionType(propTypes); + if (propTypes.length > 2) { + // When `propTypes` has the potential to explode in size when normalized, defer normalization until absolutely needed + result.checkFlags |= CheckFlags.DeferredType; + result.deferralParent = containingType; + result.deferralConstituents = propTypes; + } + else { + result.type = isUnion ? getUnionType(propTypes) : getIntersectionType(propTypes); + } return result; } @@ -12313,8 +12334,8 @@ namespace ts { return false; } - function isIgnoredJsxProperty(source: Type, sourceProp: Symbol, targetMemberType: Type | undefined) { - return getObjectFlags(source) & ObjectFlags.JsxAttributes && !(isUnhyphenatedJsxName(sourceProp.escapedName) || targetMemberType); + function isIgnoredJsxProperty(source: Type, sourceProp: Symbol) { + return getObjectFlags(source) & ObjectFlags.JsxAttributes && !isUnhyphenatedJsxName(sourceProp.escapedName); } /** @@ -13495,6 +13516,49 @@ namespace ts { return result || properties; } + function isPropertySymbolTypeRelated(sourceProp: Symbol, targetProp: Symbol, getTypeOfSourceProperty: (sym: Symbol) => Type, reportErrors: boolean): Ternary { + const targetIsOptional = strictNullChecks && !!(getCheckFlags(targetProp) & CheckFlags.Partial); + const source = getTypeOfSourceProperty(sourceProp); + if (getCheckFlags(targetProp) & CheckFlags.DeferredType && !getSymbolLinks(targetProp).type) { + // Rather than resolving (and normalizing) the type, relate constituent-by-constituent without performing normalization or seconadary passes + const links = getSymbolLinks(targetProp); + Debug.assertDefined(links.deferralParent); + Debug.assertDefined(links.deferralConstituents); + const unionParent = !!(links.deferralParent!.flags & TypeFlags.Union); + let result = unionParent ? Ternary.False : Ternary.True; + const targetTypes = links.deferralConstituents!; + for (const targetType of targetTypes) { + const related = isRelatedTo(source, targetType, /*reportErrors*/ false, /*headMessage*/ undefined, /*isIntersectionConstituent*/ !unionParent); + if (!unionParent) { + if (!related) { + // Can't assign to a target individually - have to fallback to assigning to the _whole_ intersection (which forces normalization) + return isRelatedTo(source, addOptionality(getTypeOfSymbol(targetProp), targetIsOptional), reportErrors); + } + result &= related; + } + else { + if (related) { + return related; + } + } + } + if (unionParent && !result && targetIsOptional) { + result = isRelatedTo(source, undefinedType); + } + if (unionParent && !result && reportErrors) { + // The easiest way to get the right errors here is to un-defer (which may be costly) + // If it turns out this is too costly too often, we can replicate the error handling logic within + // typeRelatedToSomeType without the discriminatable type branch (as that requires a manifest union + // type on which to hand discriminable properties, which we are expressly trying to avoid here) + return isRelatedTo(source, addOptionality(getTypeOfSymbol(targetProp), targetIsOptional), reportErrors); + } + return result; + } + else { + return isRelatedTo(source, addOptionality(getTypeOfSymbol(targetProp), targetIsOptional), reportErrors); + } + } + function propertyRelatedTo(source: Type, target: Type, sourceProp: Symbol, targetProp: Symbol, getTypeOfSourceProperty: (sym: Symbol) => Type, reportErrors: boolean): Ternary { const sourcePropFlags = getDeclarationModifierFlagsFromSymbol(sourceProp); const targetPropFlags = getDeclarationModifierFlagsFromSymbol(targetProp); @@ -13537,7 +13601,7 @@ namespace ts { return Ternary.False; } // If the target comes from a partial union prop, allow `undefined` in the target type - const related = isRelatedTo(getTypeOfSourceProperty(sourceProp), addOptionality(getTypeOfSymbol(targetProp), !!(getCheckFlags(targetProp) & CheckFlags.Partial)), reportErrors); + const related = isPropertySymbolTypeRelated(sourceProp, targetProp, getTypeOfSourceProperty, reportErrors); if (!related) { if (reportErrors) { reportError(Diagnostics.Types_of_property_0_are_incompatible, symbolToString(targetProp)); @@ -13649,9 +13713,6 @@ namespace ts { if (!(targetProp.flags & SymbolFlags.Prototype)) { const sourceProp = getPropertyOfType(source, targetProp.escapedName); if (sourceProp && sourceProp !== targetProp) { - if (isIgnoredJsxProperty(source, sourceProp, getTypeOfSymbol(targetProp))) { - continue; - } const related = propertyRelatedTo(source, target, sourceProp, targetProp, getTypeOfSymbol, reportErrors); if (!related) { return Ternary.False; @@ -13797,7 +13858,7 @@ namespace ts { function eachPropertyRelatedTo(source: Type, target: Type, kind: IndexKind, reportErrors: boolean): Ternary { let result = Ternary.True; for (const prop of getPropertiesOfObjectType(source)) { - if (isIgnoredJsxProperty(source, prop, /*targetMemberType*/ undefined)) { + if (isIgnoredJsxProperty(source, prop)) { continue; } // Skip over symbol-named members diff --git a/src/compiler/types.ts b/src/compiler/types.ts index 03ca196a860..3a80655385d 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -3752,6 +3752,8 @@ namespace ts { extendedContainers?: Symbol[]; // Containers (other than the parent) which this symbol is aliased in extendedContainersByFile?: Map; // Containers (other than the parent) which this symbol is aliased in variances?: VarianceFlags[]; // Alias symbol type argument variance cache + deferralConstituents?: Type[]; // Calculated list of constituents for a deferred type + deferralParent?: Type; // Source union/intersection of a deferred type } /* @internal */ @@ -3778,6 +3780,7 @@ namespace ts { ReverseMapped = 1 << 13, // Property of reverse-inferred homomorphic mapped type OptionalParameter = 1 << 14, // Optional parameter RestParameter = 1 << 15, // Rest parameter + DeferredType = 1 << 16, // Calculation of the type of this symbol is deferred due to processing costs, should be fetched with `getTypeOfSymbolWithDeferredType` Synthetic = SyntheticProperty | SyntheticMethod, Discriminant = HasNonUniformType | HasLiteralType, Partial = ReadPartial | WritePartial diff --git a/tests/baselines/reference/intersectionTypeMembers.js b/tests/baselines/reference/intersectionTypeMembers.js index 59968b007db..867a6f0fc66 100644 --- a/tests/baselines/reference/intersectionTypeMembers.js +++ b/tests/baselines/reference/intersectionTypeMembers.js @@ -43,6 +43,28 @@ const de: D & E = { other: { g: 101 } } } + +// Additional test case with >2 doubly nested members so fix for #31441 is tested w/ excess props +interface F { + nested: { doublyNested: { g: string; } } +} + +interface G { + nested: { doublyNested: { h: string; } } +} + +const defg: D & E & F & G = { + nested: { + doublyNested: { + d: 'yes', + f: 'no', + g: 'ok', + h: 'affirmative' + }, + different: { e: 12 }, + other: { g: 101 } + } +} //// [intersectionTypeMembers.js] @@ -69,3 +91,15 @@ var de = { other: { g: 101 } } }; +var defg = { + nested: { + doublyNested: { + d: 'yes', + f: 'no', + g: 'ok', + h: 'affirmative' + }, + different: { e: 12 }, + other: { g: 101 } + } +}; diff --git a/tests/baselines/reference/intersectionTypeMembers.symbols b/tests/baselines/reference/intersectionTypeMembers.symbols index be47b2960db..b4629d1659d 100644 --- a/tests/baselines/reference/intersectionTypeMembers.symbols +++ b/tests/baselines/reference/intersectionTypeMembers.symbols @@ -146,3 +146,58 @@ const de: D & E = { } } +// Additional test case with >2 doubly nested members so fix for #31441 is tested w/ excess props +interface F { +>F : Symbol(F, Decl(intersectionTypeMembers.ts, 43, 1)) + + nested: { doublyNested: { g: string; } } +>nested : Symbol(F.nested, Decl(intersectionTypeMembers.ts, 46, 13)) +>doublyNested : Symbol(doublyNested, Decl(intersectionTypeMembers.ts, 47, 13)) +>g : Symbol(g, Decl(intersectionTypeMembers.ts, 47, 29)) +} + +interface G { +>G : Symbol(G, Decl(intersectionTypeMembers.ts, 48, 1)) + + nested: { doublyNested: { h: string; } } +>nested : Symbol(G.nested, Decl(intersectionTypeMembers.ts, 50, 13)) +>doublyNested : Symbol(doublyNested, Decl(intersectionTypeMembers.ts, 51, 13)) +>h : Symbol(h, Decl(intersectionTypeMembers.ts, 51, 29)) +} + +const defg: D & E & F & G = { +>defg : Symbol(defg, Decl(intersectionTypeMembers.ts, 54, 5)) +>D : Symbol(D, Decl(intersectionTypeMembers.ts, 26, 14)) +>E : Symbol(E, Decl(intersectionTypeMembers.ts, 30, 1)) +>F : Symbol(F, Decl(intersectionTypeMembers.ts, 43, 1)) +>G : Symbol(G, Decl(intersectionTypeMembers.ts, 48, 1)) + + nested: { +>nested : Symbol(nested, Decl(intersectionTypeMembers.ts, 54, 29)) + + doublyNested: { +>doublyNested : Symbol(doublyNested, Decl(intersectionTypeMembers.ts, 55, 13)) + + d: 'yes', +>d : Symbol(d, Decl(intersectionTypeMembers.ts, 56, 23)) + + f: 'no', +>f : Symbol(f, Decl(intersectionTypeMembers.ts, 57, 21)) + + g: 'ok', +>g : Symbol(g, Decl(intersectionTypeMembers.ts, 58, 20)) + + h: 'affirmative' +>h : Symbol(h, Decl(intersectionTypeMembers.ts, 59, 20)) + + }, + different: { e: 12 }, +>different : Symbol(different, Decl(intersectionTypeMembers.ts, 61, 10)) +>e : Symbol(e, Decl(intersectionTypeMembers.ts, 62, 20)) + + other: { g: 101 } +>other : Symbol(other, Decl(intersectionTypeMembers.ts, 62, 29)) +>g : Symbol(g, Decl(intersectionTypeMembers.ts, 63, 16)) + } +} + diff --git a/tests/baselines/reference/intersectionTypeMembers.types b/tests/baselines/reference/intersectionTypeMembers.types index eb9d5fa4eb8..817fa044624 100644 --- a/tests/baselines/reference/intersectionTypeMembers.types +++ b/tests/baselines/reference/intersectionTypeMembers.types @@ -148,3 +148,61 @@ const de: D & E = { } } +// Additional test case with >2 doubly nested members so fix for #31441 is tested w/ excess props +interface F { + nested: { doublyNested: { g: string; } } +>nested : { doublyNested: { g: string; }; } +>doublyNested : { g: string; } +>g : string +} + +interface G { + nested: { doublyNested: { h: string; } } +>nested : { doublyNested: { h: string; }; } +>doublyNested : { h: string; } +>h : string +} + +const defg: D & E & F & G = { +>defg : D & E & F & G +>{ nested: { doublyNested: { d: 'yes', f: 'no', g: 'ok', h: 'affirmative' }, different: { e: 12 }, other: { g: 101 } }} : { nested: { doublyNested: { d: string; f: string; g: string; h: string; }; different: { e: number; }; other: { g: number; }; }; } + + nested: { +>nested : { doublyNested: { d: string; f: string; g: string; h: string; }; different: { e: number; }; other: { g: number; }; } +>{ doublyNested: { d: 'yes', f: 'no', g: 'ok', h: 'affirmative' }, different: { e: 12 }, other: { g: 101 } } : { doublyNested: { d: string; f: string; g: string; h: string; }; different: { e: number; }; other: { g: number; }; } + + doublyNested: { +>doublyNested : { d: string; f: string; g: string; h: string; } +>{ d: 'yes', f: 'no', g: 'ok', h: 'affirmative' } : { d: string; f: string; g: string; h: string; } + + d: 'yes', +>d : string +>'yes' : "yes" + + f: 'no', +>f : string +>'no' : "no" + + g: 'ok', +>g : string +>'ok' : "ok" + + h: 'affirmative' +>h : string +>'affirmative' : "affirmative" + + }, + different: { e: 12 }, +>different : { e: number; } +>{ e: 12 } : { e: number; } +>e : number +>12 : 12 + + other: { g: 101 } +>other : { g: number; } +>{ g: 101 } : { g: number; } +>g : number +>101 : 101 + } +} + diff --git a/tests/baselines/reference/normalizedIntersectionTooComplex.errors.txt b/tests/baselines/reference/normalizedIntersectionTooComplex.errors.txt index 4e214eff507..64e7d7f00c5 100644 --- a/tests/baselines/reference/normalizedIntersectionTooComplex.errors.txt +++ b/tests/baselines/reference/normalizedIntersectionTooComplex.errors.txt @@ -1,5 +1,5 @@ -tests/cases/compiler/normalizedIntersectionTooComplex.ts(36,14): error TS2590: Expression produces a union type that is too complex to represent. tests/cases/compiler/normalizedIntersectionTooComplex.ts(36,40): error TS7006: Parameter 'x' implicitly has an 'any' type. +tests/cases/compiler/normalizedIntersectionTooComplex.ts(36,40): error TS2590: Expression produces a union type that is too complex to represent. ==== tests/cases/compiler/normalizedIntersectionTooComplex.ts (2 errors) ==== @@ -39,8 +39,8 @@ tests/cases/compiler/normalizedIntersectionTooComplex.ts(36,40): error TS7006: P declare var all: keyof Big; const ctor = getCtor(all); const comp = ctor({ common: "ok", ref: x => console.log(x) }); - ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -!!! error TS2590: Expression produces a union type that is too complex to represent. ~ !!! error TS7006: Parameter 'x' implicitly has an 'any' type. + ~~~~~~~~~~~~~~~~~~~ +!!! error TS2590: Expression produces a union type that is too complex to represent. \ No newline at end of file diff --git a/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.js b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.js new file mode 100644 index 00000000000..c85d07ec99b --- /dev/null +++ b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.js @@ -0,0 +1,33 @@ +//// [reactTagNameComponentWithPropsNoOOM.tsx] +/// + +import * as React from "react"; +declare const Tag: keyof React.ReactHTML; + +const classes = ""; +const rest: {} = {}; +const children: any[] = []; + +{children} + + +//// [reactTagNameComponentWithPropsNoOOM.js] +"use strict"; +/// +var __assign = (this && this.__assign) || function () { + __assign = Object.assign || function(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) + t[p] = s[p]; + } + return t; + }; + return __assign.apply(this, arguments); +}; +exports.__esModule = true; +var React = require("react"); +var classes = ""; +var rest = {}; +var children = []; +React.createElement(Tag, __assign({ className: classes }, rest), children); diff --git a/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.symbols b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.symbols new file mode 100644 index 00000000000..0b827bf7a0d --- /dev/null +++ b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.symbols @@ -0,0 +1,32 @@ +=== tests/cases/compiler/reactTagNameComponentWithPropsNoOOM.tsx === +/// + +import * as React from "react"; +>React : Symbol(React, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 2, 6)) + +declare const Tag: keyof React.ReactHTML; +>Tag : Symbol(Tag, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 3, 13)) +>React : Symbol(React, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 2, 6)) +>ReactHTML : Symbol(React.ReactHTML, Decl(react16.d.ts, 2089, 9)) + +const classes = ""; +>classes : Symbol(classes, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 5, 5)) + +const rest: {} = {}; +>rest : Symbol(rest, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 6, 5)) + +const children: any[] = []; +>children : Symbol(children, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 7, 5)) + + +>Tag : Symbol(Tag, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 3, 13)) +>className : Symbol(className, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 8, 4)) +>classes : Symbol(classes, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 5, 5)) +>rest : Symbol(rest, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 6, 5)) + +{children} +>children : Symbol(children, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 7, 5)) + + +>Tag : Symbol(Tag, Decl(reactTagNameComponentWithPropsNoOOM.tsx, 3, 13)) + diff --git a/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.types b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.types new file mode 100644 index 00000000000..f31716a55e4 --- /dev/null +++ b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM.types @@ -0,0 +1,35 @@ +=== tests/cases/compiler/reactTagNameComponentWithPropsNoOOM.tsx === +/// + +import * as React from "react"; +>React : typeof React + +declare const Tag: keyof React.ReactHTML; +>Tag : "object" | "time" | "link" | "menu" | "dialog" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | "caption" | "cite" | "code" | "col" | "colgroup" | "data" | "datalist" | "dd" | "del" | "details" | "dfn" | "div" | "dl" | "dt" | "em" | "embed" | "fieldset" | "figcaption" | "figure" | "footer" | "form" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "head" | "header" | "hgroup" | "hr" | "html" | "i" | "iframe" | "img" | "input" | "ins" | "kbd" | "keygen" | "label" | "legend" | "li" | "main" | "map" | "mark" | "menuitem" | "meta" | "meter" | "nav" | "noscript" | "ol" | "optgroup" | "option" | "output" | "p" | "param" | "picture" | "pre" | "progress" | "q" | "rp" | "rt" | "ruby" | "s" | "samp" | "script" | "section" | "select" | "small" | "source" | "span" | "strong" | "style" | "sub" | "summary" | "sup" | "table" | "tbody" | "td" | "textarea" | "tfoot" | "th" | "thead" | "title" | "tr" | "track" | "u" | "ul" | "var" | "video" | "wbr" | "webview" +>React : any + +const classes = ""; +>classes : "" +>"" : "" + +const rest: {} = {}; +>rest : {} +>{} : {} + +const children: any[] = []; +>children : any[] +>[] : never[] + + +>{children} : JSX.Element +>Tag : "object" | "time" | "link" | "menu" | "dialog" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | "caption" | "cite" | "code" | "col" | "colgroup" | "data" | "datalist" | "dd" | "del" | "details" | "dfn" | "div" | "dl" | "dt" | "em" | "embed" | "fieldset" | "figcaption" | "figure" | "footer" | "form" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "head" | "header" | "hgroup" | "hr" | "html" | "i" | "iframe" | "img" | "input" | "ins" | "kbd" | "keygen" | "label" | "legend" | "li" | "main" | "map" | "mark" | "menuitem" | "meta" | "meter" | "nav" | "noscript" | "ol" | "optgroup" | "option" | "output" | "p" | "param" | "picture" | "pre" | "progress" | "q" | "rp" | "rt" | "ruby" | "s" | "samp" | "script" | "section" | "select" | "small" | "source" | "span" | "strong" | "style" | "sub" | "summary" | "sup" | "table" | "tbody" | "td" | "textarea" | "tfoot" | "th" | "thead" | "title" | "tr" | "track" | "u" | "ul" | "var" | "video" | "wbr" | "webview" +>className : string +>classes : "" +>rest : {} + +{children} +>children : any[] + + +>Tag : "object" | "time" | "link" | "menu" | "dialog" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | "caption" | "cite" | "code" | "col" | "colgroup" | "data" | "datalist" | "dd" | "del" | "details" | "dfn" | "div" | "dl" | "dt" | "em" | "embed" | "fieldset" | "figcaption" | "figure" | "footer" | "form" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "head" | "header" | "hgroup" | "hr" | "html" | "i" | "iframe" | "img" | "input" | "ins" | "kbd" | "keygen" | "label" | "legend" | "li" | "main" | "map" | "mark" | "menuitem" | "meta" | "meter" | "nav" | "noscript" | "ol" | "optgroup" | "option" | "output" | "p" | "param" | "picture" | "pre" | "progress" | "q" | "rp" | "rt" | "ruby" | "s" | "samp" | "script" | "section" | "select" | "small" | "source" | "span" | "strong" | "style" | "sub" | "summary" | "sup" | "table" | "tbody" | "td" | "textarea" | "tfoot" | "th" | "thead" | "title" | "tr" | "track" | "u" | "ul" | "var" | "video" | "wbr" | "webview" + diff --git a/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.js b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.js new file mode 100644 index 00000000000..4b6e9d0c54a --- /dev/null +++ b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.js @@ -0,0 +1,33 @@ +//// [reactTagNameComponentWithPropsNoOOM2.tsx] +/// + +import * as React from "react"; +declare const Tag: keyof React.ReactHTML; + +const classes = ""; +const rest: React.HTMLAttributes = {}; +const children: any[] = []; + +{children} + + +//// [reactTagNameComponentWithPropsNoOOM2.js] +"use strict"; +/// +var __assign = (this && this.__assign) || function () { + __assign = Object.assign || function(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) + t[p] = s[p]; + } + return t; + }; + return __assign.apply(this, arguments); +}; +exports.__esModule = true; +var React = require("react"); +var classes = ""; +var rest = {}; +var children = []; +React.createElement(Tag, __assign({ className: classes }, rest), children); diff --git a/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.symbols b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.symbols new file mode 100644 index 00000000000..658f9fd5c43 --- /dev/null +++ b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.symbols @@ -0,0 +1,35 @@ +=== tests/cases/compiler/reactTagNameComponentWithPropsNoOOM2.tsx === +/// + +import * as React from "react"; +>React : Symbol(React, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 2, 6)) + +declare const Tag: keyof React.ReactHTML; +>Tag : Symbol(Tag, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 3, 13)) +>React : Symbol(React, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 2, 6)) +>ReactHTML : Symbol(React.ReactHTML, Decl(react16.d.ts, 2089, 9)) + +const classes = ""; +>classes : Symbol(classes, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 5, 5)) + +const rest: React.HTMLAttributes = {}; +>rest : Symbol(rest, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 6, 5)) +>React : Symbol(React, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 2, 6)) +>HTMLAttributes : Symbol(React.HTMLAttributes, Decl(react16.d.ts, 1048, 9), Decl(react16.d.ts, 1105, 9)) +>HTMLElement : Symbol(HTMLElement, Decl(lib.dom.d.ts, --, --), Decl(lib.dom.d.ts, --, --)) + +const children: any[] = []; +>children : Symbol(children, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 7, 5)) + + +>Tag : Symbol(Tag, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 3, 13)) +>className : Symbol(className, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 8, 4)) +>classes : Symbol(classes, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 5, 5)) +>rest : Symbol(rest, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 6, 5)) + +{children} +>children : Symbol(children, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 7, 5)) + + +>Tag : Symbol(Tag, Decl(reactTagNameComponentWithPropsNoOOM2.tsx, 3, 13)) + diff --git a/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.types b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.types new file mode 100644 index 00000000000..fac8a844e03 --- /dev/null +++ b/tests/baselines/reference/reactTagNameComponentWithPropsNoOOM2.types @@ -0,0 +1,36 @@ +=== tests/cases/compiler/reactTagNameComponentWithPropsNoOOM2.tsx === +/// + +import * as React from "react"; +>React : typeof React + +declare const Tag: keyof React.ReactHTML; +>Tag : "object" | "time" | "link" | "menu" | "dialog" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | "caption" | "cite" | "code" | "col" | "colgroup" | "data" | "datalist" | "dd" | "del" | "details" | "dfn" | "div" | "dl" | "dt" | "em" | "embed" | "fieldset" | "figcaption" | "figure" | "footer" | "form" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "head" | "header" | "hgroup" | "hr" | "html" | "i" | "iframe" | "img" | "input" | "ins" | "kbd" | "keygen" | "label" | "legend" | "li" | "main" | "map" | "mark" | "menuitem" | "meta" | "meter" | "nav" | "noscript" | "ol" | "optgroup" | "option" | "output" | "p" | "param" | "picture" | "pre" | "progress" | "q" | "rp" | "rt" | "ruby" | "s" | "samp" | "script" | "section" | "select" | "small" | "source" | "span" | "strong" | "style" | "sub" | "summary" | "sup" | "table" | "tbody" | "td" | "textarea" | "tfoot" | "th" | "thead" | "title" | "tr" | "track" | "u" | "ul" | "var" | "video" | "wbr" | "webview" +>React : any + +const classes = ""; +>classes : "" +>"" : "" + +const rest: React.HTMLAttributes = {}; +>rest : React.HTMLAttributes +>React : any +>{} : {} + +const children: any[] = []; +>children : any[] +>[] : never[] + + +>{children} : JSX.Element +>Tag : "object" | "time" | "link" | "menu" | "dialog" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | "caption" | "cite" | "code" | "col" | "colgroup" | "data" | "datalist" | "dd" | "del" | "details" | "dfn" | "div" | "dl" | "dt" | "em" | "embed" | "fieldset" | "figcaption" | "figure" | "footer" | "form" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "head" | "header" | "hgroup" | "hr" | "html" | "i" | "iframe" | "img" | "input" | "ins" | "kbd" | "keygen" | "label" | "legend" | "li" | "main" | "map" | "mark" | "menuitem" | "meta" | "meter" | "nav" | "noscript" | "ol" | "optgroup" | "option" | "output" | "p" | "param" | "picture" | "pre" | "progress" | "q" | "rp" | "rt" | "ruby" | "s" | "samp" | "script" | "section" | "select" | "small" | "source" | "span" | "strong" | "style" | "sub" | "summary" | "sup" | "table" | "tbody" | "td" | "textarea" | "tfoot" | "th" | "thead" | "title" | "tr" | "track" | "u" | "ul" | "var" | "video" | "wbr" | "webview" +>className : string +>classes : "" +>rest : React.HTMLAttributes + +{children} +>children : any[] + + +>Tag : "object" | "time" | "link" | "menu" | "dialog" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "b" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | "caption" | "cite" | "code" | "col" | "colgroup" | "data" | "datalist" | "dd" | "del" | "details" | "dfn" | "div" | "dl" | "dt" | "em" | "embed" | "fieldset" | "figcaption" | "figure" | "footer" | "form" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "head" | "header" | "hgroup" | "hr" | "html" | "i" | "iframe" | "img" | "input" | "ins" | "kbd" | "keygen" | "label" | "legend" | "li" | "main" | "map" | "mark" | "menuitem" | "meta" | "meter" | "nav" | "noscript" | "ol" | "optgroup" | "option" | "output" | "p" | "param" | "picture" | "pre" | "progress" | "q" | "rp" | "rt" | "ruby" | "s" | "samp" | "script" | "section" | "select" | "small" | "source" | "span" | "strong" | "style" | "sub" | "summary" | "sup" | "table" | "tbody" | "td" | "textarea" | "tfoot" | "th" | "thead" | "title" | "tr" | "track" | "u" | "ul" | "var" | "video" | "wbr" | "webview" + diff --git a/tests/cases/compiler/reactTagNameComponentWithPropsNoOOM.tsx b/tests/cases/compiler/reactTagNameComponentWithPropsNoOOM.tsx new file mode 100644 index 00000000000..e6011974230 --- /dev/null +++ b/tests/cases/compiler/reactTagNameComponentWithPropsNoOOM.tsx @@ -0,0 +1,13 @@ +// @jsx: react +// @strict: true +/// + +import * as React from "react"; +declare const Tag: keyof React.ReactHTML; + +const classes = ""; +const rest: {} = {}; +const children: any[] = []; + +{children} + \ No newline at end of file diff --git a/tests/cases/compiler/reactTagNameComponentWithPropsNoOOM2.tsx b/tests/cases/compiler/reactTagNameComponentWithPropsNoOOM2.tsx new file mode 100644 index 00000000000..64d46b5dd95 --- /dev/null +++ b/tests/cases/compiler/reactTagNameComponentWithPropsNoOOM2.tsx @@ -0,0 +1,13 @@ +// @jsx: react +// @strict: true +/// + +import * as React from "react"; +declare const Tag: keyof React.ReactHTML; + +const classes = ""; +const rest: React.HTMLAttributes = {}; +const children: any[] = []; + +{children} + \ No newline at end of file diff --git a/tests/cases/conformance/types/intersection/intersectionTypeMembers.ts b/tests/cases/conformance/types/intersection/intersectionTypeMembers.ts index a350c657f61..bfb257b8ac2 100644 --- a/tests/cases/conformance/types/intersection/intersectionTypeMembers.ts +++ b/tests/cases/conformance/types/intersection/intersectionTypeMembers.ts @@ -42,3 +42,25 @@ const de: D & E = { other: { g: 101 } } } + +// Additional test case with >2 doubly nested members so fix for #31441 is tested w/ excess props +interface F { + nested: { doublyNested: { g: string; } } +} + +interface G { + nested: { doublyNested: { h: string; } } +} + +const defg: D & E & F & G = { + nested: { + doublyNested: { + d: 'yes', + f: 'no', + g: 'ok', + h: 'affirmative' + }, + different: { e: 12 }, + other: { g: 101 } + } +} From 63b8c6443f809367c2e902fb5261126755b23cca Mon Sep 17 00:00:00 2001 From: TypeScript Bot Date: Tue, 28 May 2019 11:03:29 -0700 Subject: [PATCH 107/119] Update user baselines (#31615) --- tests/baselines/reference/user/bluebird.log | 106 +++++++++--------- .../user/chrome-devtools-frontend.log | 9 +- tests/baselines/reference/user/webpack.log | 5 +- 3 files changed, 56 insertions(+), 64 deletions(-) diff --git a/tests/baselines/reference/user/bluebird.log b/tests/baselines/reference/user/bluebird.log index 5c1689ff49b..26d7270bcb6 100644 --- a/tests/baselines/reference/user/bluebird.log +++ b/tests/baselines/reference/user/bluebird.log @@ -131,60 +131,62 @@ node_modules/bluebird/js/release/promise.js(65,15): error TS2350: Only a void fu node_modules/bluebird/js/release/promise.js(65,68): error TS2339: Property 'classString' does not exist on type 'typeof ret'. node_modules/bluebird/js/release/promise.js(95,22): error TS2339: Property 'isObject' does not exist on type 'typeof ret'. node_modules/bluebird/js/release/promise.js(99,59): error TS2339: Property 'classString' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(119,22): error TS2339: Property 'classString' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(121,32): error TS2339: Property 'classString' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(123,14): error TS2339: Property '_warn' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(136,68): error TS2339: Property 'classString' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(148,14): error TS2551: Property 'isFulfilled' does not exist on type 'Promise'. Did you mean '_setFulfilled'? -node_modules/bluebird/js/release/promise.js(149,37): error TS2339: Property 'value' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(151,21): error TS2551: Property 'isRejected' does not exist on type 'Promise'. Did you mean '_setRejected'? -node_modules/bluebird/js/release/promise.js(152,36): error TS2339: Property 'reason' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(160,14): error TS2339: Property '_warn' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(166,29): error TS2339: Property 'originatesFromRejection' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(177,9): error TS2339: Property '_captureStackTrace' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(207,9): error TS2339: Property '_captureStackTrace' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(214,15): error TS2350: Only a void function can be called with the 'new' keyword. -node_modules/bluebird/js/release/promise.js(214,68): error TS2339: Property 'classString' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(238,63): error TS2339: Property '_boundTo' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(241,14): error TS2339: Property '_fireEvent' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(253,20): error TS2339: Property '_unsetRejectionIsUnhandled' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(257,20): error TS2339: Property '_attachExtraTrace' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(264,26): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(295,10): error TS2339: Property '_fireEvent' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(106,19): error TS2350: Only a void function can be called with the 'new' keyword. +node_modules/bluebird/js/release/promise.js(107,60): error TS2554: Expected 0 arguments, but got 1. +node_modules/bluebird/js/release/promise.js(124,22): error TS2339: Property 'classString' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(126,32): error TS2339: Property 'classString' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(128,14): error TS2339: Property '_warn' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(141,68): error TS2339: Property 'classString' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(153,14): error TS2551: Property 'isFulfilled' does not exist on type 'Promise'. Did you mean '_setFulfilled'? +node_modules/bluebird/js/release/promise.js(154,37): error TS2339: Property 'value' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(156,21): error TS2551: Property 'isRejected' does not exist on type 'Promise'. Did you mean '_setRejected'? +node_modules/bluebird/js/release/promise.js(157,36): error TS2339: Property 'reason' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(165,14): error TS2339: Property '_warn' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(171,29): error TS2339: Property 'originatesFromRejection' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(182,9): error TS2339: Property '_captureStackTrace' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(212,9): error TS2339: Property '_captureStackTrace' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(219,15): error TS2350: Only a void function can be called with the 'new' keyword. +node_modules/bluebird/js/release/promise.js(219,68): error TS2339: Property 'classString' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(243,63): error TS2339: Property '_boundTo' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(246,14): error TS2339: Property '_fireEvent' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(258,20): error TS2339: Property '_unsetRejectionIsUnhandled' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(262,20): error TS2339: Property '_attachExtraTrace' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(269,26): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. node_modules/bluebird/js/release/promise.js(300,10): error TS2339: Property '_fireEvent' does not exist on type 'Promise'. node_modules/bluebird/js/release/promise.js(305,10): error TS2339: Property '_fireEvent' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(322,10): error TS2339: Property '_fireEvent' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(339,42): error TS2339: Property '_isBound' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(400,50): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(404,49): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(412,50): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(416,49): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(434,26): error TS2339: Property '_propagateFrom' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(454,31): error TS2339: Property '_value' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(456,30): error TS2339: Property '_reason' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(459,17): error TS2339: Property '_attachExtraTrace' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(466,22): error TS2339: Property 'ensureErrorObject' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(470,18): error TS2339: Property 'classString' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(471,14): error TS2339: Property '_warn' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(473,10): error TS2339: Property '_attachExtraTrace' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(480,10): error TS2339: Property '_captureStackTrace' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(481,10): error TS2339: Property '_pushContext' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(483,18): error TS2339: Property '_execute' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(489,10): error TS2339: Property '_popContext' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(506,19): error TS2350: Only a void function can be called with the 'new' keyword. -node_modules/bluebird/js/release/promise.js(507,42): error TS2339: Property 'classString' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(558,22): error TS2339: Property '_promiseCancelled' does not exist on type '{}'. -node_modules/bluebird/js/release/promise.js(572,23): error TS2339: Property '_isResolved' does not exist on type '{}'. -node_modules/bluebird/js/release/promise.js(574,26): error TS2339: Property '_promiseFulfilled' does not exist on type '{}'. -node_modules/bluebird/js/release/promise.js(576,26): error TS2339: Property '_promiseRejected' does not exist on type '{}'. -node_modules/bluebird/js/release/promise.js(630,14): error TS2339: Property '_attachExtraTrace' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(642,14): error TS2339: Property '_dereferenceTrace' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(653,46): error TS2339: Property 'isNode' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(659,14): error TS2339: Property '_ensurePossibleRejectionHandled' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(699,10): error TS2339: Property '_clearCancellationData' does not exist on type 'Promise'. -node_modules/bluebird/js/release/promise.js(724,6): error TS2339: Property 'notEnumerableProp' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(754,10): error TS2339: Property 'toFastProperties' does not exist on type 'typeof ret'. -node_modules/bluebird/js/release/promise.js(755,10): error TS2339: Property 'toFastProperties' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(310,10): error TS2339: Property '_fireEvent' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(327,10): error TS2339: Property '_fireEvent' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(344,42): error TS2339: Property '_isBound' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(405,50): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(409,49): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(417,50): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(421,49): error TS2339: Property 'domainBind' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(439,26): error TS2339: Property '_propagateFrom' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(459,31): error TS2339: Property '_value' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(461,30): error TS2339: Property '_reason' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(464,17): error TS2339: Property '_attachExtraTrace' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(471,22): error TS2339: Property 'ensureErrorObject' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(475,18): error TS2339: Property 'classString' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(476,14): error TS2339: Property '_warn' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(478,10): error TS2339: Property '_attachExtraTrace' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(485,10): error TS2339: Property '_captureStackTrace' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(486,10): error TS2339: Property '_pushContext' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(488,18): error TS2339: Property '_execute' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(494,10): error TS2339: Property '_popContext' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(511,19): error TS2350: Only a void function can be called with the 'new' keyword. +node_modules/bluebird/js/release/promise.js(512,42): error TS2339: Property 'classString' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(563,22): error TS2339: Property '_promiseCancelled' does not exist on type '{}'. +node_modules/bluebird/js/release/promise.js(577,23): error TS2339: Property '_isResolved' does not exist on type '{}'. +node_modules/bluebird/js/release/promise.js(579,26): error TS2339: Property '_promiseFulfilled' does not exist on type '{}'. +node_modules/bluebird/js/release/promise.js(581,26): error TS2339: Property '_promiseRejected' does not exist on type '{}'. +node_modules/bluebird/js/release/promise.js(635,14): error TS2339: Property '_attachExtraTrace' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(647,14): error TS2339: Property '_dereferenceTrace' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(658,46): error TS2339: Property 'isNode' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(664,14): error TS2339: Property '_ensurePossibleRejectionHandled' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(704,10): error TS2339: Property '_clearCancellationData' does not exist on type 'Promise'. +node_modules/bluebird/js/release/promise.js(737,6): error TS2339: Property 'notEnumerableProp' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(767,10): error TS2339: Property 'toFastProperties' does not exist on type 'typeof ret'. +node_modules/bluebird/js/release/promise.js(768,10): error TS2339: Property 'toFastProperties' does not exist on type 'typeof ret'. node_modules/bluebird/js/release/promise_array.js(5,20): error TS2339: Property 'isArray' does not exist on type 'typeof ret'. node_modules/bluebird/js/release/promise_array.js(26,6): error TS2339: Property 'inherits' does not exist on type 'typeof ret'. node_modules/bluebird/js/release/promise_array.js(61,19): error TS2339: Property 'asArray' does not exist on type 'typeof ret'. diff --git a/tests/baselines/reference/user/chrome-devtools-frontend.log b/tests/baselines/reference/user/chrome-devtools-frontend.log index bdde6b918c0..d32422fb416 100644 --- a/tests/baselines/reference/user/chrome-devtools-frontend.log +++ b/tests/baselines/reference/user/chrome-devtools-frontend.log @@ -698,13 +698,6 @@ node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighth node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(10092,16): error TS2304: Cannot find name 'd41d8cd98f00b204e9800998ecf8427e_LibraryDetectorTests'. node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(10513,19): error TS2488: Type 'NodeListOf' must have a '[Symbol.iterator]()' method that returns an iterator. node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(10811,19): error TS2304: Cannot find name 'getElementsInDocument'. -node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(11441,1): error TS2322: Type 'unknown' is not assignable to type 'number'. -node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(11444,1): error TS2322: Type 'unknown' is not assignable to type 'number'. -node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(11447,15): error TS2339: Property 'textLength' does not exist on type 'unknown'. -node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(11447,28): error TS2339: Property 'textLength' does not exist on type 'unknown'. -node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(11450,43): error TS2339: Property 'node' does not exist on type 'unknown'. -node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(11453,6): error TS2339: Property 'cssRule' does not exist on type 'unknown'. -node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(11460,6): error TS2339: Property 'cssRule' does not exist on type 'unknown'. node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(12197,34): error TS2554: Expected 0 arguments, but got 2. node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(12327,36): error TS2554: Expected 0 arguments, but got 1. node_modules/chrome-devtools-frontend/front_end/audits2_worker/lighthouse/lighthouse-background.js(13607,7): error TS2339: Property 'protocolMethod' does not exist on type 'Error'. @@ -3389,7 +3382,7 @@ node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(2765,22): error node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(2785,91): error TS2339: Property 'xRel' does not exist on type 'Pos'. node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(2855,32): error TS2339: Property 'left' does not exist on type 'never'. node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(2855,49): error TS2339: Property 'right' does not exist on type 'never'. -node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(2856,10): error TS2365: Operator '+' cannot be applied to types 'null' and '0 | 1'. +node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(2856,10): error TS2365: Operator '+' cannot be applied to types 'null' and '1 | 0'. node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(2858,32): error TS2339: Property 'left' does not exist on type 'never'. node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(2858,49): error TS2339: Property 'right' does not exist on type 'never'. node_modules/chrome-devtools-frontend/front_end/cm/codemirror.js(3034,25): error TS2339: Property 'xRel' does not exist on type 'Pos'. diff --git a/tests/baselines/reference/user/webpack.log b/tests/baselines/reference/user/webpack.log index 0cde6bb1623..ce91836eddf 100644 --- a/tests/baselines/reference/user/webpack.log +++ b/tests/baselines/reference/user/webpack.log @@ -1,10 +1,7 @@ Exit Code: 1 Standard output: -../../../../../built/local/lib.dom.d.ts(17676,19): error TS2451: Cannot redeclare block-scoped variable 'WebAssembly'. +../../../../../built/local/lib.dom.d.ts(17677,19): error TS2451: Cannot redeclare block-scoped variable 'WebAssembly'. declarations.d.ts(258,15): error TS2451: Cannot redeclare block-scoped variable 'WebAssembly'. -lib/ContextModuleFactory.js(253,50): error TS2339: Property 'concat' does not exist on type 'unknown'. -lib/web/JsonpChunkTemplatePlugin.js(13,6): error TS2339: Property 'id' does not exist on type 'unknown'. -lib/web/JsonpMainTemplatePlugin.js(501,11): error TS2339: Property 'id' does not exist on type 'unknown'. From cd09cbbd5e5e483d5441e41d0acbcde9e868af60 Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Tue, 28 May 2019 13:13:46 -0700 Subject: [PATCH 108/119] Cache widened types (#31586) * Cache widened types * Fix lint --- src/compiler/checker.ts | 26 ++-- src/compiler/types.ts | 2 + .../reference/noImplicitThisBigThis.js | 115 ++++++++++++++++++ .../reference/noImplicitThisBigThis.symbols | 99 +++++++++++++++ .../reference/noImplicitThisBigThis.types | 103 ++++++++++++++++ tests/cases/compiler/noImplicitThisBigThis.ts | 50 ++++++++ 6 files changed, 386 insertions(+), 9 deletions(-) create mode 100644 tests/baselines/reference/noImplicitThisBigThis.js create mode 100644 tests/baselines/reference/noImplicitThisBigThis.symbols create mode 100644 tests/baselines/reference/noImplicitThisBigThis.types create mode 100644 tests/cases/compiler/noImplicitThisBigThis.ts diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index d59cf4c5470..85b3641f004 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -14740,26 +14740,34 @@ namespace ts { function getWidenedTypeWithContext(type: Type, context: WideningContext | undefined): Type { if (getObjectFlags(type) & ObjectFlags.RequiresWidening) { + if (context === undefined && type.widened) { + return type.widened; + } + let result: Type | undefined; if (type.flags & TypeFlags.Nullable) { - return anyType; + result = anyType; } - if (isObjectLiteralType(type)) { - return getWidenedTypeOfObjectLiteral(type, context); + else if (isObjectLiteralType(type)) { + result = getWidenedTypeOfObjectLiteral(type, context); } - if (type.flags & TypeFlags.Union) { + else if (type.flags & TypeFlags.Union) { const unionContext = context || createWideningContext(/*parent*/ undefined, /*propertyName*/ undefined, (type).types); const widenedTypes = sameMap((type).types, t => t.flags & TypeFlags.Nullable ? t : getWidenedTypeWithContext(t, unionContext)); // Widening an empty object literal transitions from a highly restrictive type to // a highly inclusive one. For that reason we perform subtype reduction here if the // union includes empty object types (e.g. reducing {} | string to just {}). - return getUnionType(widenedTypes, some(widenedTypes, isEmptyObjectType) ? UnionReduction.Subtype : UnionReduction.Literal); + result = getUnionType(widenedTypes, some(widenedTypes, isEmptyObjectType) ? UnionReduction.Subtype : UnionReduction.Literal); } - if (type.flags & TypeFlags.Intersection) { - return getIntersectionType(sameMap((type).types, getWidenedType)); + else if (type.flags & TypeFlags.Intersection) { + result = getIntersectionType(sameMap((type).types, getWidenedType)); } - if (isArrayType(type) || isTupleType(type)) { - return createTypeReference((type).target, sameMap((type).typeArguments, getWidenedType)); + else if (isArrayType(type) || isTupleType(type)) { + result = createTypeReference((type).target, sameMap((type).typeArguments, getWidenedType)); } + if (result && context === undefined) { + type.widened = result; + } + return result || type; } return type; } diff --git a/src/compiler/types.ts b/src/compiler/types.ts index 3a80655385d..cb646a0b687 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -4013,6 +4013,8 @@ namespace ts { restrictiveInstantiation?: Type; // Instantiation with type parameters mapped to unconstrained form /* @internal */ immediateBaseConstraint?: Type; // Immediate base constraint cache + /* @internal */ + widened?: Type; // Cached widened form of the type } /* @internal */ diff --git a/tests/baselines/reference/noImplicitThisBigThis.js b/tests/baselines/reference/noImplicitThisBigThis.js new file mode 100644 index 00000000000..f2e633f2dcf --- /dev/null +++ b/tests/baselines/reference/noImplicitThisBigThis.js @@ -0,0 +1,115 @@ +//// [noImplicitThisBigThis.ts] +// https://github.com/microsoft/TypeScript/issues/29902 + +function createObj() { + return { + func1() { + return this; + }, + func2() { + return this; + }, + func3() { + return this; + } + }; +} + +function createObjNoCrash() { + return { + func1() { + return this; + }, + func2() { + return this; + }, + func3() { + return this; + }, + func4() { + return this; + }, + func5() { + return this; + }, + func6() { + return this; + }, + func7() { + return this; + }, + func8() { + return this; + }, + func9() { + return this; + } + }; +} + + +//// [noImplicitThisBigThis.js] +// https://github.com/microsoft/TypeScript/issues/29902 +function createObj() { + return { + func1: function () { + return this; + }, + func2: function () { + return this; + }, + func3: function () { + return this; + } + }; +} +function createObjNoCrash() { + return { + func1: function () { + return this; + }, + func2: function () { + return this; + }, + func3: function () { + return this; + }, + func4: function () { + return this; + }, + func5: function () { + return this; + }, + func6: function () { + return this; + }, + func7: function () { + return this; + }, + func8: function () { + return this; + }, + func9: function () { + return this; + } + }; +} + + +//// [noImplicitThisBigThis.d.ts] +declare function createObj(): { + func1(): any; + func2(): any; + func3(): any; +}; +declare function createObjNoCrash(): { + func1(): any; + func2(): any; + func3(): any; + func4(): any; + func5(): any; + func6(): any; + func7(): any; + func8(): any; + func9(): any; +}; diff --git a/tests/baselines/reference/noImplicitThisBigThis.symbols b/tests/baselines/reference/noImplicitThisBigThis.symbols new file mode 100644 index 00000000000..9f0c8c1bf24 --- /dev/null +++ b/tests/baselines/reference/noImplicitThisBigThis.symbols @@ -0,0 +1,99 @@ +=== tests/cases/compiler/noImplicitThisBigThis.ts === +// https://github.com/microsoft/TypeScript/issues/29902 + +function createObj() { +>createObj : Symbol(createObj, Decl(noImplicitThisBigThis.ts, 0, 0)) + + return { + func1() { +>func1 : Symbol(func1, Decl(noImplicitThisBigThis.ts, 3, 12)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 3, 10)) + + }, + func2() { +>func2 : Symbol(func2, Decl(noImplicitThisBigThis.ts, 6, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 3, 10)) + + }, + func3() { +>func3 : Symbol(func3, Decl(noImplicitThisBigThis.ts, 9, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 3, 10)) + } + }; +} + +function createObjNoCrash() { +>createObjNoCrash : Symbol(createObjNoCrash, Decl(noImplicitThisBigThis.ts, 14, 1)) + + return { + func1() { +>func1 : Symbol(func1, Decl(noImplicitThisBigThis.ts, 17, 12)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + + }, + func2() { +>func2 : Symbol(func2, Decl(noImplicitThisBigThis.ts, 20, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + + }, + func3() { +>func3 : Symbol(func3, Decl(noImplicitThisBigThis.ts, 23, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + + }, + func4() { +>func4 : Symbol(func4, Decl(noImplicitThisBigThis.ts, 26, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + + }, + func5() { +>func5 : Symbol(func5, Decl(noImplicitThisBigThis.ts, 29, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + + }, + func6() { +>func6 : Symbol(func6, Decl(noImplicitThisBigThis.ts, 32, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + + }, + func7() { +>func7 : Symbol(func7, Decl(noImplicitThisBigThis.ts, 35, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + + }, + func8() { +>func8 : Symbol(func8, Decl(noImplicitThisBigThis.ts, 38, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + + }, + func9() { +>func9 : Symbol(func9, Decl(noImplicitThisBigThis.ts, 41, 10)) + + return this; +>this : Symbol(__object, Decl(noImplicitThisBigThis.ts, 17, 10)) + } + }; +} + diff --git a/tests/baselines/reference/noImplicitThisBigThis.types b/tests/baselines/reference/noImplicitThisBigThis.types new file mode 100644 index 00000000000..4e1731aebc7 --- /dev/null +++ b/tests/baselines/reference/noImplicitThisBigThis.types @@ -0,0 +1,103 @@ +=== tests/cases/compiler/noImplicitThisBigThis.ts === +// https://github.com/microsoft/TypeScript/issues/29902 + +function createObj() { +>createObj : () => { func1(): any; func2(): any; func3(): any; } + + return { +>{ func1() { return this; }, func2() { return this; }, func3() { return this; } } : { func1(): { func1(): any; func2(): any; func3(): any; }; func2(): { func1(): any; func2(): any; func3(): any; }; func3(): { func1(): any; func2(): any; func3(): any; }; } + + func1() { +>func1 : () => { func1(): any; func2(): any; func3(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; }; func2(): { func1(): any; func2(): any; func3(): any; }; func3(): { func1(): any; func2(): any; func3(): any; }; } + + }, + func2() { +>func2 : () => { func1(): any; func2(): any; func3(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; }; func2(): { func1(): any; func2(): any; func3(): any; }; func3(): { func1(): any; func2(): any; func3(): any; }; } + + }, + func3() { +>func3 : () => { func1(): any; func2(): any; func3(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; }; func2(): { func1(): any; func2(): any; func3(): any; }; func3(): { func1(): any; func2(): any; func3(): any; }; } + } + }; +} + +function createObjNoCrash() { +>createObjNoCrash : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return { +>{ func1() { return this; }, func2() { return this; }, func3() { return this; }, func4() { return this; }, func5() { return this; }, func6() { return this; }, func7() { return this; }, func8() { return this; }, func9() { return this; } } : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + func1() { +>func1 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + }, + func2() { +>func2 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + }, + func3() { +>func3 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + }, + func4() { +>func4 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + }, + func5() { +>func5 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + }, + func6() { +>func6 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + }, + func7() { +>func7 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + }, + func8() { +>func8 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + + }, + func9() { +>func9 : () => { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; } + + return this; +>this : { func1(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func2(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func3(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func4(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func5(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func6(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func7(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func8(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; func9(): { func1(): any; func2(): any; func3(): any; func4(): any; func5(): any; func6(): any; func7(): any; func8(): any; func9(): any; }; } + } + }; +} + diff --git a/tests/cases/compiler/noImplicitThisBigThis.ts b/tests/cases/compiler/noImplicitThisBigThis.ts new file mode 100644 index 00000000000..687f2f9355d --- /dev/null +++ b/tests/cases/compiler/noImplicitThisBigThis.ts @@ -0,0 +1,50 @@ +// @declaration: true +// @noImplicitThis: true + +// https://github.com/microsoft/TypeScript/issues/29902 + +function createObj() { + return { + func1() { + return this; + }, + func2() { + return this; + }, + func3() { + return this; + } + }; +} + +function createObjNoCrash() { + return { + func1() { + return this; + }, + func2() { + return this; + }, + func3() { + return this; + }, + func4() { + return this; + }, + func5() { + return this; + }, + func6() { + return this; + }, + func7() { + return this; + }, + func8() { + return this; + }, + func9() { + return this; + } + }; +} From b75a90e95ab619a8874737a1bce136284b963e11 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Tue, 28 May 2019 16:32:10 -0700 Subject: [PATCH 109/119] Return type inference should not include parameter inferences --- src/compiler/checker.ts | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 5091f5f0306..e83137b87e8 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -14864,13 +14864,6 @@ namespace ts { return context && createInferenceContextWorker(map(context.inferences, cloneInferenceInfo), context.signature, context.flags | extraFlags, context.compareTypes); } - function cloneInferredPartOfContext(context: InferenceContext): InferenceContext | undefined { - const inferences = filter(context.inferences, hasInferenceCandidates); - return inferences.length ? - createInferenceContextWorker(map(inferences, cloneInferenceInfo), context.signature, context.flags, context.compareTypes) : - undefined; - } - function createInferenceContextWorker(inferences: InferenceInfo[], signature: Signature | undefined, flags: InferenceFlags, compareTypes: TypeComparer): InferenceContext { const context: InferenceContext = { inferences, @@ -20846,7 +20839,8 @@ namespace ts { // We clone the inference context to avoid disturbing a resolution in progress for an // outer call expression. Effectively we just want a snapshot of whatever has been // inferred for any outer call expression so far. - const outerMapper = getMapperFromContext(cloneInferenceContext(getInferenceContext(node), InferenceFlags.NoDefault)); + const outerContext = getInferenceContext(node); + const outerMapper = getMapperFromContext(cloneInferenceContext(outerContext, InferenceFlags.NoDefault)); const instantiatedType = instantiateType(contextualType, outerMapper); // If the contextual type is a generic function type with a single call signature, we // instantiate the type with its own type parameters and type arguments. This ensures that @@ -20864,7 +20858,10 @@ namespace ts { inferTypes(context.inferences, inferenceSourceType, inferenceTargetType, InferencePriority.ReturnType); // Create a type mapper for instantiating generic contextual types using the inferences made // from the return type. - context.returnMapper = getMapperFromContext(cloneInferredPartOfContext(context)); + const returnContext = createInferenceContext(signature.typeParameters!, signature, context.flags); + const returnSourceType = instantiateType(contextualType, outerContext && outerContext.returnMapper); + inferTypes(returnContext.inferences, returnSourceType, inferenceTargetType); + context.returnMapper = some(returnContext.inferences, hasInferenceCandidates) ? getMapperFromContext(returnContext) : undefined; } } From 94f19c7edd741ea7fe985c57541dcf233677d22b Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Wed, 29 May 2019 08:59:44 -0700 Subject: [PATCH 110/119] Update version to 3.6.0. --- package.json | 2 +- src/compiler/core.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index a50a79aff13..ae67f3166b5 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "typescript", "author": "Microsoft Corp.", "homepage": "https://www.typescriptlang.org/", - "version": "3.5.0", + "version": "3.6.0", "license": "Apache-2.0", "description": "TypeScript is a language for application scale JavaScript development", "keywords": [ diff --git a/src/compiler/core.ts b/src/compiler/core.ts index 0034c275999..f1511b79c12 100644 --- a/src/compiler/core.ts +++ b/src/compiler/core.ts @@ -1,7 +1,7 @@ namespace ts { // WARNING: The script `configureNightly.ts` uses a regexp to parse out these values. // If changing the text in this section, be sure to test `configureNightly` too. - export const versionMajorMinor = "3.5"; + export const versionMajorMinor = "3.6"; /** The version of the TypeScript compiler release */ export const version = `${versionMajorMinor}.0-dev`; } From c5c869f673044d7e0daa27e194103409251d89dd Mon Sep 17 00:00:00 2001 From: Daniel Rosenwasser Date: Wed, 29 May 2019 10:20:49 -0700 Subject: [PATCH 111/119] Accepted baselines --- tests/baselines/reference/api/tsserverlibrary.d.ts | 2 +- tests/baselines/reference/api/typescript.d.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/baselines/reference/api/tsserverlibrary.d.ts b/tests/baselines/reference/api/tsserverlibrary.d.ts index 993a7494994..e940c5055ff 100644 --- a/tests/baselines/reference/api/tsserverlibrary.d.ts +++ b/tests/baselines/reference/api/tsserverlibrary.d.ts @@ -14,7 +14,7 @@ and limitations under the License. ***************************************************************************** */ declare namespace ts { - const versionMajorMinor = "3.5"; + const versionMajorMinor = "3.6"; /** The version of the TypeScript compiler release */ const version: string; } diff --git a/tests/baselines/reference/api/typescript.d.ts b/tests/baselines/reference/api/typescript.d.ts index 58ccd42344b..d67a1638a5e 100644 --- a/tests/baselines/reference/api/typescript.d.ts +++ b/tests/baselines/reference/api/typescript.d.ts @@ -14,7 +14,7 @@ and limitations under the License. ***************************************************************************** */ declare namespace ts { - const versionMajorMinor = "3.5"; + const versionMajorMinor = "3.6"; /** The version of the TypeScript compiler release */ const version: string; } From 08cd0b3700cbe62a170d9c5693170fc0210d598a Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 29 May 2019 12:42:43 -0700 Subject: [PATCH 112/119] Use proper variances when inferring between type alias instantiations --- src/compiler/checker.ts | 31 ++++++++++++++----------------- 1 file changed, 14 insertions(+), 17 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 85b3641f004..99ae67d764f 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -15171,11 +15171,7 @@ namespace ts { if (source.aliasSymbol && source.aliasTypeArguments && source.aliasSymbol === target.aliasSymbol) { // Source and target are types originating in the same generic type alias declaration. // Simply infer from source type arguments to target type arguments. - const sourceTypes = source.aliasTypeArguments; - const targetTypes = target.aliasTypeArguments!; - for (let i = 0; i < sourceTypes.length; i++) { - inferFromTypes(sourceTypes[i], targetTypes[i]); - } + inferFromTypeArguments(source.aliasTypeArguments, target.aliasTypeArguments!, getAliasVariances(source.aliasSymbol)); return; } if (source.flags & TypeFlags.Union && target.flags & TypeFlags.Union && !(source.flags & TypeFlags.EnumLiteral && target.flags & TypeFlags.EnumLiteral) || @@ -15281,18 +15277,7 @@ namespace ts { } if (getObjectFlags(source) & ObjectFlags.Reference && getObjectFlags(target) & ObjectFlags.Reference && (source).target === (target).target) { // If source and target are references to the same generic type, infer from type arguments - const sourceTypes = (source).typeArguments || emptyArray; - const targetTypes = (target).typeArguments || emptyArray; - const count = sourceTypes.length < targetTypes.length ? sourceTypes.length : targetTypes.length; - const variances = getVariances((source).target); - for (let i = 0; i < count; i++) { - if (i < variances.length && (variances[i] & VarianceFlags.VarianceMask) === VarianceFlags.Contravariant) { - inferFromContravariantTypes(sourceTypes[i], targetTypes[i]); - } - else { - inferFromTypes(sourceTypes[i], targetTypes[i]); - } - } + inferFromTypeArguments((source).typeArguments || emptyArray, (target).typeArguments || emptyArray, getVariances((source).target)); } else if (source.flags & TypeFlags.Index && target.flags & TypeFlags.Index) { contravariant = !contravariant; @@ -15412,6 +15397,18 @@ namespace ts { } } + function inferFromTypeArguments(sourceTypes: readonly Type[], targetTypes: readonly Type[], variances: readonly VarianceFlags[]) { + const count = sourceTypes.length < targetTypes.length ? sourceTypes.length : targetTypes.length; + for (let i = 0; i < count; i++) { + if (i < variances.length && (variances[i] & VarianceFlags.VarianceMask) === VarianceFlags.Contravariant) { + inferFromContravariantTypes(sourceTypes[i], targetTypes[i]); + } + else { + inferFromTypes(sourceTypes[i], targetTypes[i]); + } + } + } + function inferFromContravariantTypes(source: Type, target: Type) { if (strictFunctionTypes || priority & InferencePriority.AlwaysStrict) { contravariant = !contravariant; From 22475e8958ce2892c5311c3249165548606b10e8 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 29 May 2019 13:09:51 -0700 Subject: [PATCH 113/119] Add regression tests --- .../contravariantTypeAliasInference.ts | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 tests/cases/compiler/contravariantTypeAliasInference.ts diff --git a/tests/cases/compiler/contravariantTypeAliasInference.ts b/tests/cases/compiler/contravariantTypeAliasInference.ts new file mode 100644 index 00000000000..77044eeae76 --- /dev/null +++ b/tests/cases/compiler/contravariantTypeAliasInference.ts @@ -0,0 +1,19 @@ +// @strict: true + +type Func1 = (x: T) => void; +type Func2 = ((x: T) => void) | undefined; + +declare let f1: Func1; +declare let f2: Func1<"a">; + +declare function foo(f1: Func1, f2: Func1): void; + +foo(f1, f2); + +declare let g1: Func2; +declare let g2: Func2<"a">; + +declare function bar(g1: Func2, g2: Func2): void; + +bar(f1, f2); +bar(g1, g2); From bb412ab73b1cbc9eaa38145bc733b3325c55f30d Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Wed, 29 May 2019 13:10:01 -0700 Subject: [PATCH 114/119] Accept new baselines --- .../contravariantTypeAliasInference.js | 25 ++++++++ .../contravariantTypeAliasInference.symbols | 64 +++++++++++++++++++ .../contravariantTypeAliasInference.types | 49 ++++++++++++++ 3 files changed, 138 insertions(+) create mode 100644 tests/baselines/reference/contravariantTypeAliasInference.js create mode 100644 tests/baselines/reference/contravariantTypeAliasInference.symbols create mode 100644 tests/baselines/reference/contravariantTypeAliasInference.types diff --git a/tests/baselines/reference/contravariantTypeAliasInference.js b/tests/baselines/reference/contravariantTypeAliasInference.js new file mode 100644 index 00000000000..a0a7b45db91 --- /dev/null +++ b/tests/baselines/reference/contravariantTypeAliasInference.js @@ -0,0 +1,25 @@ +//// [contravariantTypeAliasInference.ts] +type Func1 = (x: T) => void; +type Func2 = ((x: T) => void) | undefined; + +declare let f1: Func1; +declare let f2: Func1<"a">; + +declare function foo(f1: Func1, f2: Func1): void; + +foo(f1, f2); + +declare let g1: Func2; +declare let g2: Func2<"a">; + +declare function bar(g1: Func2, g2: Func2): void; + +bar(f1, f2); +bar(g1, g2); + + +//// [contravariantTypeAliasInference.js] +"use strict"; +foo(f1, f2); +bar(f1, f2); +bar(g1, g2); diff --git a/tests/baselines/reference/contravariantTypeAliasInference.symbols b/tests/baselines/reference/contravariantTypeAliasInference.symbols new file mode 100644 index 00000000000..ff34d3ea17e --- /dev/null +++ b/tests/baselines/reference/contravariantTypeAliasInference.symbols @@ -0,0 +1,64 @@ +=== tests/cases/compiler/contravariantTypeAliasInference.ts === +type Func1 = (x: T) => void; +>Func1 : Symbol(Func1, Decl(contravariantTypeAliasInference.ts, 0, 0)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 0, 11)) +>x : Symbol(x, Decl(contravariantTypeAliasInference.ts, 0, 17)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 0, 11)) + +type Func2 = ((x: T) => void) | undefined; +>Func2 : Symbol(Func2, Decl(contravariantTypeAliasInference.ts, 0, 31)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 1, 11)) +>x : Symbol(x, Decl(contravariantTypeAliasInference.ts, 1, 18)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 1, 11)) + +declare let f1: Func1; +>f1 : Symbol(f1, Decl(contravariantTypeAliasInference.ts, 3, 11)) +>Func1 : Symbol(Func1, Decl(contravariantTypeAliasInference.ts, 0, 0)) + +declare let f2: Func1<"a">; +>f2 : Symbol(f2, Decl(contravariantTypeAliasInference.ts, 4, 11)) +>Func1 : Symbol(Func1, Decl(contravariantTypeAliasInference.ts, 0, 0)) + +declare function foo(f1: Func1, f2: Func1): void; +>foo : Symbol(foo, Decl(contravariantTypeAliasInference.ts, 4, 27)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 6, 21)) +>f1 : Symbol(f1, Decl(contravariantTypeAliasInference.ts, 6, 24)) +>Func1 : Symbol(Func1, Decl(contravariantTypeAliasInference.ts, 0, 0)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 6, 21)) +>f2 : Symbol(f2, Decl(contravariantTypeAliasInference.ts, 6, 37)) +>Func1 : Symbol(Func1, Decl(contravariantTypeAliasInference.ts, 0, 0)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 6, 21)) + +foo(f1, f2); +>foo : Symbol(foo, Decl(contravariantTypeAliasInference.ts, 4, 27)) +>f1 : Symbol(f1, Decl(contravariantTypeAliasInference.ts, 3, 11)) +>f2 : Symbol(f2, Decl(contravariantTypeAliasInference.ts, 4, 11)) + +declare let g1: Func2; +>g1 : Symbol(g1, Decl(contravariantTypeAliasInference.ts, 10, 11)) +>Func2 : Symbol(Func2, Decl(contravariantTypeAliasInference.ts, 0, 31)) + +declare let g2: Func2<"a">; +>g2 : Symbol(g2, Decl(contravariantTypeAliasInference.ts, 11, 11)) +>Func2 : Symbol(Func2, Decl(contravariantTypeAliasInference.ts, 0, 31)) + +declare function bar(g1: Func2, g2: Func2): void; +>bar : Symbol(bar, Decl(contravariantTypeAliasInference.ts, 11, 27)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 13, 21)) +>g1 : Symbol(g1, Decl(contravariantTypeAliasInference.ts, 13, 24)) +>Func2 : Symbol(Func2, Decl(contravariantTypeAliasInference.ts, 0, 31)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 13, 21)) +>g2 : Symbol(g2, Decl(contravariantTypeAliasInference.ts, 13, 37)) +>Func2 : Symbol(Func2, Decl(contravariantTypeAliasInference.ts, 0, 31)) +>T : Symbol(T, Decl(contravariantTypeAliasInference.ts, 13, 21)) + +bar(f1, f2); +>bar : Symbol(bar, Decl(contravariantTypeAliasInference.ts, 11, 27)) +>f1 : Symbol(f1, Decl(contravariantTypeAliasInference.ts, 3, 11)) +>f2 : Symbol(f2, Decl(contravariantTypeAliasInference.ts, 4, 11)) + +bar(g1, g2); +>bar : Symbol(bar, Decl(contravariantTypeAliasInference.ts, 11, 27)) +>g1 : Symbol(g1, Decl(contravariantTypeAliasInference.ts, 10, 11)) +>g2 : Symbol(g2, Decl(contravariantTypeAliasInference.ts, 11, 11)) + diff --git a/tests/baselines/reference/contravariantTypeAliasInference.types b/tests/baselines/reference/contravariantTypeAliasInference.types new file mode 100644 index 00000000000..9ff197cdfce --- /dev/null +++ b/tests/baselines/reference/contravariantTypeAliasInference.types @@ -0,0 +1,49 @@ +=== tests/cases/compiler/contravariantTypeAliasInference.ts === +type Func1 = (x: T) => void; +>Func1 : Func1 +>x : T + +type Func2 = ((x: T) => void) | undefined; +>Func2 : Func2 +>x : T + +declare let f1: Func1; +>f1 : Func1 + +declare let f2: Func1<"a">; +>f2 : Func1<"a"> + +declare function foo(f1: Func1, f2: Func1): void; +>foo : (f1: Func1, f2: Func1) => void +>f1 : Func1 +>f2 : Func1 + +foo(f1, f2); +>foo(f1, f2) : void +>foo : (f1: Func1, f2: Func1) => void +>f1 : Func1 +>f2 : Func1<"a"> + +declare let g1: Func2; +>g1 : Func2 + +declare let g2: Func2<"a">; +>g2 : Func2<"a"> + +declare function bar(g1: Func2, g2: Func2): void; +>bar : (g1: Func2, g2: Func2) => void +>g1 : Func2 +>g2 : Func2 + +bar(f1, f2); +>bar(f1, f2) : void +>bar : (g1: Func2, g2: Func2) => void +>f1 : Func1 +>f2 : Func1<"a"> + +bar(g1, g2); +>bar(g1, g2) : void +>bar : (g1: Func2, g2: Func2) => void +>g1 : Func2 +>g2 : Func2<"a"> + From 953153e565caa9eaad5572d1eac7cc7c997e8464 Mon Sep 17 00:00:00 2001 From: TypeScript Bot Date: Thu, 30 May 2019 11:12:25 -0700 Subject: [PATCH 115/119] Update user baselines (#31674) --- .../reference/user/chrome-devtools-frontend.log | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/tests/baselines/reference/user/chrome-devtools-frontend.log b/tests/baselines/reference/user/chrome-devtools-frontend.log index d32422fb416..6b6b46ab180 100644 --- a/tests/baselines/reference/user/chrome-devtools-frontend.log +++ b/tests/baselines/reference/user/chrome-devtools-frontend.log @@ -3122,9 +3122,6 @@ node_modules/chrome-devtools-frontend/front_end/bindings/BreakpointManager.js(53 node_modules/chrome-devtools-frontend/front_end/bindings/BreakpointManager.js(655,51): error TS2339: Property 'valuesArray' does not exist on type 'Map'. node_modules/chrome-devtools-frontend/front_end/bindings/BreakpointManager.js(667,51): error TS2339: Property 'valuesArray' does not exist on type 'Map'. node_modules/chrome-devtools-frontend/front_end/bindings/BreakpointManager.js(674,79): error TS2345: Argument of type 'this' is not assignable to parameter of type '{ modelAdded(model: T): void; modelRemoved(model: T): void; }'. - Type 'Breakpoint' is not assignable to type '{ modelAdded(model: T): void; modelRemoved(model: T): void; }'. - Types of property 'modelAdded' are incompatible. - Type '(debuggerModel: DebuggerModel) => void' is not assignable to type '(model: T) => void'. node_modules/chrome-devtools-frontend/front_end/bindings/BreakpointManager.js(713,51): error TS2339: Property 'valuesArray' does not exist on type 'Map'. node_modules/chrome-devtools-frontend/front_end/bindings/BreakpointManager.js(787,14): error TS7014: Function type, which lacks return-type annotation, implicitly has an 'any' return type. node_modules/chrome-devtools-frontend/front_end/bindings/BreakpointManager.js(862,14): error TS7014: Function type, which lacks return-type annotation, implicitly has an 'any' return type. @@ -6621,8 +6618,6 @@ node_modules/chrome-devtools-frontend/front_end/heap_snapshot_worker/HeapSnapsho Type 'HeapSnapshotNode' is not assignable to type '{ itemIndex(): number; serialize(): any; }'. Property '_snapshot' does not exist on type '{ itemIndex(): number; serialize(): any; }'. node_modules/chrome-devtools-frontend/front_end/heap_snapshot_worker/HeapSnapshot.js(2341,15): error TS2345: Argument of type 'HeapSnapshotNodeIndexProvider' is not assignable to parameter of type '{ itemForIndex(newIndex: number): { itemIndex(): number; serialize(): any; }; }'. - Types of property 'itemForIndex' are incompatible. - Type '(index: number) => HeapSnapshotNode' is not assignable to type '(newIndex: number) => { itemIndex(): number; serialize(): any; }'. node_modules/chrome-devtools-frontend/front_end/heap_snapshot_worker/HeapSnapshot.js(2353,12): error TS2339: Property 'nodeIndex' does not exist on type 'void'. node_modules/chrome-devtools-frontend/front_end/heap_snapshot_worker/HeapSnapshot.js(2354,16): error TS2339: Property 'id' does not exist on type 'void'. node_modules/chrome-devtools-frontend/front_end/heap_snapshot_worker/HeapSnapshot.js(2397,13): error TS2339: Property 'nodeIndex' does not exist on type 'void'. @@ -7707,9 +7702,6 @@ node_modules/chrome-devtools-frontend/front_end/network_log/NetworkLog.js(44,57) Type 'T' is not assignable to type 'NetworkManager'. node_modules/chrome-devtools-frontend/front_end/network_log/NetworkLog.js(99,59): error TS2345: Argument of type 'this' is not assignable to parameter of type '{ modelAdded(model: T): void; modelRemoved(model: T): void; }'. node_modules/chrome-devtools-frontend/front_end/network_log/NetworkLog.js(101,61): error TS2345: Argument of type 'this' is not assignable to parameter of type '{ modelAdded(model: T): void; modelRemoved(model: T): void; }'. - Type 'NetworkLog' is not assignable to type '{ modelAdded(model: T): void; modelRemoved(model: T): void; }'. - Types of property 'modelAdded' are incompatible. - Type '(networkManager: NetworkManager) => void' is not assignable to type '(model: T) => void'. node_modules/chrome-devtools-frontend/front_end/network_log/NetworkLog.js(123,24): error TS2694: Namespace 'Protocol' has no exported member 'Network'. node_modules/chrome-devtools-frontend/front_end/network_log/NetworkLog.js(154,49): error TS2694: Namespace 'NetworkLog.NetworkLog' has no exported member '_InitiatorInfo'. node_modules/chrome-devtools-frontend/front_end/network_log/NetworkLog.js(165,38): error TS2694: Namespace 'NetworkLog.NetworkLog' has no exported member '_InitiatorInfo'. @@ -10835,7 +10827,7 @@ node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(45,10 node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(46,24): error TS2555: Expected at least 2 arguments, but got 1. node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(54,43): error TS2555: Expected at least 2 arguments, but got 1. node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(69,55): error TS2339: Property 'runtime' does not exist on type 'Window'. -node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(85,5): error TS2739: Type '{ tabbedPane(): TabbedPane; enableMoreTabsButton(): void; }' is missing the following properties from type '{ appendApplicableItems(locationName: string): void; appendView(view: { viewId(): string; title(): string; isCloseable(): boolean; isTransient(): boolean; toolbarItems(): Promise; widget(): Promise<...>; disposeView(): void; }, insertBefore?: { ...; }): void; showView(view: { ...; }, insertBefore?: { ...': appendApplicableItems, appendView, showView, removeView, widget +node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(85,5): error TS2322: Type '{ tabbedPane(): TabbedPane; enableMoreTabsButton(): void; }' is not assignable to type '{ appendApplicableItems(locationName: string): void; appendView(view: { viewId(): string; title(): string; isCloseable(): boolean; isTransient(): boolean; toolbarItems(): Promise; widget(): Promise<...>; disposeView(): void; }, insertBefore?: { ...; }): void; showView(view: { ...; }, insertBefore?: { ...'. node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(100,15): error TS2339: Property 'keyCode' does not exist on type 'Event'. node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(119,31): error TS2339: Property 'createChild' does not exist on type 'Element'. node_modules/chrome-devtools-frontend/front_end/settings/SettingsScreen.js(121,42): error TS2339: Property 'createChild' does not exist on type 'Element'. @@ -11362,7 +11354,7 @@ node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(133,55): node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(208,22): error TS2694: Namespace 'Common' has no exported member 'Event'. node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(227,52): error TS2339: Property '_instance' does not exist on type 'typeof WrapperView'. node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(242,40): error TS2339: Property '_instance' does not exist on type 'typeof WrapperView'. -node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(257,7): error TS2739: Type '{ tabbedPane(): TabbedPane; enableMoreTabsButton(): void; }' is missing the following properties from type '{ appendApplicableItems(locationName: string): void; appendView(view: { viewId(): string; title(): string; isCloseable(): boolean; isTransient(): boolean; toolbarItems(): Promise; widget(): Promise<...>; disposeView(): void; }, insertBefore?: { ...; }): void; showView(view: { ...; }, insertBefore?: { ...': appendApplicableItems, appendView, showView, removeView, widget +node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(257,7): error TS2322: Type '{ tabbedPane(): TabbedPane; enableMoreTabsButton(): void; }' is not assignable to type '{ appendApplicableItems(locationName: string): void; appendView(view: { viewId(): string; title(): string; isCloseable(): boolean; isTransient(): boolean; toolbarItems(): Promise; widget(): Promise<...>; disposeView(): void; }, insertBefore?: { ...; }): void; showView(view: { ...; }, insertBefore?: { ...'. node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(277,20): error TS2339: Property 'window' does not exist on type 'Element'. node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(289,22): error TS2694: Namespace 'Common' has no exported member 'Event'. node_modules/chrome-devtools-frontend/front_end/sources/SourcesPanel.js(330,22): error TS2694: Namespace 'Common' has no exported member 'Event'. @@ -12884,8 +12876,8 @@ node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(53,50): erro node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(69,40): error TS2555: Expected at least 2 arguments, but got 1. node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(80,24): error TS2694: Namespace 'Common' has no exported member 'Event'. node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(92,51): error TS2339: Property 'runtime' does not exist on type 'Window'. -node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(116,7): error TS2739: Type '{ tabbedPane(): TabbedPane; enableMoreTabsButton(): void; }' is missing the following properties from type '{ appendApplicableItems(locationName: string): void; appendView(view: { viewId(): string; title(): string; isCloseable(): boolean; isTransient(): boolean; toolbarItems(): Promise; widget(): Promise<...>; disposeView(): void; }, insertBefore?: { ...; }): void; showView(view: { ...; }, insertBefore?: { ...': appendApplicableItems, appendView, showView, removeView, widget -node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(118,7): error TS2739: Type '{ tabbedPane(): TabbedPane; enableMoreTabsButton(): void; }' is missing the following properties from type '{ appendApplicableItems(locationName: string): void; appendView(view: { viewId(): string; title(): string; isCloseable(): boolean; isTransient(): boolean; toolbarItems(): Promise; widget(): Promise<...>; disposeView(): void; }, insertBefore?: { ...; }): void; showView(view: { ...; }, insertBefore?: { ...': appendApplicableItems, appendView, showView, removeView, widget +node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(116,7): error TS2322: Type '{ tabbedPane(): TabbedPane; enableMoreTabsButton(): void; }' is not assignable to type '{ appendApplicableItems(locationName: string): void; appendView(view: { viewId(): string; title(): string; isCloseable(): boolean; isTransient(): boolean; toolbarItems(): Promise; widget(): Promise<...>; disposeView(): void; }, insertBefore?: { ...; }): void; showView(view: { ...; }, insertBefore?: { ...'. +node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(118,7): error TS2322: Type '{ tabbedPane(): TabbedPane; enableMoreTabsButton(): void; }' is not assignable to type '{ appendApplicableItems(locationName: string): void; appendView(view: { viewId(): string; title(): string; isCloseable(): boolean; isTransient(): boolean; toolbarItems(): Promise; widget(): Promise<...>; disposeView(): void; }, insertBefore?: { ...; }): void; showView(view: { ...; }, insertBefore?: { ...'. node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(247,73): error TS2339: Property 'altKey' does not exist on type 'Event'. node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(247,89): error TS2339: Property 'shiftKey' does not exist on type 'Event'. node_modules/chrome-devtools-frontend/front_end/ui/InspectorView.js(254,17): error TS2339: Property 'keyCode' does not exist on type 'Event'. From 2b36fdd08b9a2618ad8531904d9c19ecbb503a2c Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 30 May 2019 14:40:03 -0700 Subject: [PATCH 116/119] Add regression tests --- .../inferFromGenericFunctionReturnTypes3.ts | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/tests/cases/compiler/inferFromGenericFunctionReturnTypes3.ts b/tests/cases/compiler/inferFromGenericFunctionReturnTypes3.ts index 429d98b6a39..d14111c7a7a 100644 --- a/tests/cases/compiler/inferFromGenericFunctionReturnTypes3.ts +++ b/tests/cases/compiler/inferFromGenericFunctionReturnTypes3.ts @@ -182,3 +182,22 @@ enum State { A, B } type Foo = { state: State } declare function bar(f: () => T[]): T[]; let x: Foo[] = bar(() => !!true ? [{ state: State.A }] : [{ state: State.B }]); // Error + +// Repros from #31443 + +enum Enum { A, B } + +class ClassWithConvert { + constructor(val: T) { } + convert(converter: { to: (v: T) => T; }) { } +} + +function fn(arg: ClassWithConvert, f: () => ClassWithConvert) { } +fn(new ClassWithConvert(Enum.A), () => new ClassWithConvert(Enum.A)); + +type Func = (x: T) => T; + +declare function makeFoo(x: T): Func; +declare function baz(x: Func, y: Func): void; + +baz(makeFoo(Enum.A), makeFoo(Enum.A)); From c3ef035b022b64c692aa9b3c8e691a269a68fc32 Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 30 May 2019 14:40:09 -0700 Subject: [PATCH 117/119] Accept new baselines --- ...FromGenericFunctionReturnTypes3.errors.txt | 19 +++++ .../inferFromGenericFunctionReturnTypes3.js | 32 ++++++++ ...ferFromGenericFunctionReturnTypes3.symbols | 81 +++++++++++++++++++ ...inferFromGenericFunctionReturnTypes3.types | 67 +++++++++++++++ 4 files changed, 199 insertions(+) diff --git a/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.errors.txt b/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.errors.txt index 7c79c63f78a..aea21ac2504 100644 --- a/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.errors.txt +++ b/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.errors.txt @@ -200,4 +200,23 @@ tests/cases/compiler/inferFromGenericFunctionReturnTypes3.ts(180,26): error TS23 !!! error TS2322: Types of property 'state' are incompatible. !!! error TS2322: Type 'State.B' is not assignable to type 'State.A'. !!! related TS6502 tests/cases/compiler/inferFromGenericFunctionReturnTypes3.ts:179:28: The expected type comes from the return type of this signature. + + // Repros from #31443 + + enum Enum { A, B } + + class ClassWithConvert { + constructor(val: T) { } + convert(converter: { to: (v: T) => T; }) { } + } + + function fn(arg: ClassWithConvert, f: () => ClassWithConvert) { } + fn(new ClassWithConvert(Enum.A), () => new ClassWithConvert(Enum.A)); + + type Func = (x: T) => T; + + declare function makeFoo(x: T): Func; + declare function baz(x: Func, y: Func): void; + + baz(makeFoo(Enum.A), makeFoo(Enum.A)); \ No newline at end of file diff --git a/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.js b/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.js index 99070e6ddcb..b6a2e890b11 100644 --- a/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.js +++ b/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.js @@ -179,6 +179,25 @@ enum State { A, B } type Foo = { state: State } declare function bar(f: () => T[]): T[]; let x: Foo[] = bar(() => !!true ? [{ state: State.A }] : [{ state: State.B }]); // Error + +// Repros from #31443 + +enum Enum { A, B } + +class ClassWithConvert { + constructor(val: T) { } + convert(converter: { to: (v: T) => T; }) { } +} + +function fn(arg: ClassWithConvert, f: () => ClassWithConvert) { } +fn(new ClassWithConvert(Enum.A), () => new ClassWithConvert(Enum.A)); + +type Func = (x: T) => T; + +declare function makeFoo(x: T): Func; +declare function baz(x: Func, y: Func): void; + +baz(makeFoo(Enum.A), makeFoo(Enum.A)); //// [inferFromGenericFunctionReturnTypes3.js] @@ -278,6 +297,19 @@ var State; State[State["B"] = 1] = "B"; })(State || (State = {})); let x = bar(() => !!true ? [{ state: State.A }] : [{ state: State.B }]); // Error +// Repros from #31443 +var Enum; +(function (Enum) { + Enum[Enum["A"] = 0] = "A"; + Enum[Enum["B"] = 1] = "B"; +})(Enum || (Enum = {})); +class ClassWithConvert { + constructor(val) { } + convert(converter) { } +} +function fn(arg, f) { } +fn(new ClassWithConvert(Enum.A), () => new ClassWithConvert(Enum.A)); +baz(makeFoo(Enum.A), makeFoo(Enum.A)); //// [inferFromGenericFunctionReturnTypes3.d.ts] diff --git a/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.symbols b/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.symbols index f89421cde07..ecf867a2bf7 100644 --- a/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.symbols +++ b/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.symbols @@ -459,3 +459,84 @@ let x: Foo[] = bar(() => !!true ? [{ state: State.A }] : [{ state: State.B }]); >State : Symbol(State, Decl(inferFromGenericFunctionReturnTypes3.ts, 174, 56)) >B : Symbol(State.B, Decl(inferFromGenericFunctionReturnTypes3.ts, 176, 15)) +// Repros from #31443 + +enum Enum { A, B } +>Enum : Symbol(Enum, Decl(inferFromGenericFunctionReturnTypes3.ts, 179, 79)) +>A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) +>B : Symbol(Enum.B, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 14)) + +class ClassWithConvert { +>ClassWithConvert : Symbol(ClassWithConvert, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 18)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 185, 23)) + + constructor(val: T) { } +>val : Symbol(val, Decl(inferFromGenericFunctionReturnTypes3.ts, 186, 14)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 185, 23)) + + convert(converter: { to: (v: T) => T; }) { } +>convert : Symbol(ClassWithConvert.convert, Decl(inferFromGenericFunctionReturnTypes3.ts, 186, 25)) +>converter : Symbol(converter, Decl(inferFromGenericFunctionReturnTypes3.ts, 187, 10)) +>to : Symbol(to, Decl(inferFromGenericFunctionReturnTypes3.ts, 187, 22)) +>v : Symbol(v, Decl(inferFromGenericFunctionReturnTypes3.ts, 187, 28)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 185, 23)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 185, 23)) +} + +function fn(arg: ClassWithConvert, f: () => ClassWithConvert) { } +>fn : Symbol(fn, Decl(inferFromGenericFunctionReturnTypes3.ts, 188, 1)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 190, 12)) +>arg : Symbol(arg, Decl(inferFromGenericFunctionReturnTypes3.ts, 190, 15)) +>ClassWithConvert : Symbol(ClassWithConvert, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 18)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 190, 12)) +>f : Symbol(f, Decl(inferFromGenericFunctionReturnTypes3.ts, 190, 40)) +>ClassWithConvert : Symbol(ClassWithConvert, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 18)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 190, 12)) + +fn(new ClassWithConvert(Enum.A), () => new ClassWithConvert(Enum.A)); +>fn : Symbol(fn, Decl(inferFromGenericFunctionReturnTypes3.ts, 188, 1)) +>ClassWithConvert : Symbol(ClassWithConvert, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 18)) +>Enum.A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) +>Enum : Symbol(Enum, Decl(inferFromGenericFunctionReturnTypes3.ts, 179, 79)) +>A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) +>ClassWithConvert : Symbol(ClassWithConvert, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 18)) +>Enum.A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) +>Enum : Symbol(Enum, Decl(inferFromGenericFunctionReturnTypes3.ts, 179, 79)) +>A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) + +type Func = (x: T) => T; +>Func : Symbol(Func, Decl(inferFromGenericFunctionReturnTypes3.ts, 191, 69)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 193, 10)) +>x : Symbol(x, Decl(inferFromGenericFunctionReturnTypes3.ts, 193, 16)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 193, 10)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 193, 10)) + +declare function makeFoo(x: T): Func; +>makeFoo : Symbol(makeFoo, Decl(inferFromGenericFunctionReturnTypes3.ts, 193, 27)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 195, 25)) +>x : Symbol(x, Decl(inferFromGenericFunctionReturnTypes3.ts, 195, 28)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 195, 25)) +>Func : Symbol(Func, Decl(inferFromGenericFunctionReturnTypes3.ts, 191, 69)) +>T : Symbol(T, Decl(inferFromGenericFunctionReturnTypes3.ts, 195, 25)) + +declare function baz(x: Func, y: Func): void; +>baz : Symbol(baz, Decl(inferFromGenericFunctionReturnTypes3.ts, 195, 43)) +>U : Symbol(U, Decl(inferFromGenericFunctionReturnTypes3.ts, 196, 21)) +>x : Symbol(x, Decl(inferFromGenericFunctionReturnTypes3.ts, 196, 24)) +>Func : Symbol(Func, Decl(inferFromGenericFunctionReturnTypes3.ts, 191, 69)) +>U : Symbol(U, Decl(inferFromGenericFunctionReturnTypes3.ts, 196, 21)) +>y : Symbol(y, Decl(inferFromGenericFunctionReturnTypes3.ts, 196, 35)) +>Func : Symbol(Func, Decl(inferFromGenericFunctionReturnTypes3.ts, 191, 69)) +>U : Symbol(U, Decl(inferFromGenericFunctionReturnTypes3.ts, 196, 21)) + +baz(makeFoo(Enum.A), makeFoo(Enum.A)); +>baz : Symbol(baz, Decl(inferFromGenericFunctionReturnTypes3.ts, 195, 43)) +>makeFoo : Symbol(makeFoo, Decl(inferFromGenericFunctionReturnTypes3.ts, 193, 27)) +>Enum.A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) +>Enum : Symbol(Enum, Decl(inferFromGenericFunctionReturnTypes3.ts, 179, 79)) +>A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) +>makeFoo : Symbol(makeFoo, Decl(inferFromGenericFunctionReturnTypes3.ts, 193, 27)) +>Enum.A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) +>Enum : Symbol(Enum, Decl(inferFromGenericFunctionReturnTypes3.ts, 179, 79)) +>A : Symbol(Enum.A, Decl(inferFromGenericFunctionReturnTypes3.ts, 183, 11)) + diff --git a/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.types b/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.types index fd83694a171..4c56070fd3c 100644 --- a/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.types +++ b/tests/baselines/reference/inferFromGenericFunctionReturnTypes3.types @@ -506,3 +506,70 @@ let x: Foo[] = bar(() => !!true ? [{ state: State.A }] : [{ state: State.B }]); >State : typeof State >B : State.B +// Repros from #31443 + +enum Enum { A, B } +>Enum : Enum +>A : Enum.A +>B : Enum.B + +class ClassWithConvert { +>ClassWithConvert : ClassWithConvert + + constructor(val: T) { } +>val : T + + convert(converter: { to: (v: T) => T; }) { } +>convert : (converter: { to: (v: T) => T; }) => void +>converter : { to: (v: T) => T; } +>to : (v: T) => T +>v : T +} + +function fn(arg: ClassWithConvert, f: () => ClassWithConvert) { } +>fn : (arg: ClassWithConvert, f: () => ClassWithConvert) => void +>arg : ClassWithConvert +>f : () => ClassWithConvert + +fn(new ClassWithConvert(Enum.A), () => new ClassWithConvert(Enum.A)); +>fn(new ClassWithConvert(Enum.A), () => new ClassWithConvert(Enum.A)) : void +>fn : (arg: ClassWithConvert, f: () => ClassWithConvert) => void +>new ClassWithConvert(Enum.A) : ClassWithConvert +>ClassWithConvert : typeof ClassWithConvert +>Enum.A : Enum.A +>Enum : typeof Enum +>A : Enum.A +>() => new ClassWithConvert(Enum.A) : () => ClassWithConvert +>new ClassWithConvert(Enum.A) : ClassWithConvert +>ClassWithConvert : typeof ClassWithConvert +>Enum.A : Enum.A +>Enum : typeof Enum +>A : Enum.A + +type Func = (x: T) => T; +>Func : Func +>x : T + +declare function makeFoo(x: T): Func; +>makeFoo : (x: T) => Func +>x : T + +declare function baz(x: Func, y: Func): void; +>baz : (x: Func, y: Func) => void +>x : Func +>y : Func + +baz(makeFoo(Enum.A), makeFoo(Enum.A)); +>baz(makeFoo(Enum.A), makeFoo(Enum.A)) : void +>baz : (x: Func, y: Func) => void +>makeFoo(Enum.A) : Func +>makeFoo : (x: T) => Func +>Enum.A : Enum.A +>Enum : typeof Enum +>A : Enum.A +>makeFoo(Enum.A) : Func +>makeFoo : (x: T) => Func +>Enum.A : Enum.A +>Enum : typeof Enum +>A : Enum.A + From 1fe9a0ad4ed30abe67418cb58f5dd06eb23391a6 Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Thu, 30 May 2019 15:20:41 -0700 Subject: [PATCH 118/119] Small fix to user PR script (#31679) --- scripts/open-user-pr.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/open-user-pr.ts b/scripts/open-user-pr.ts index 0a636c267b8..23e4bb951d7 100644 --- a/scripts/open-user-pr.ts +++ b/scripts/open-user-pr.ts @@ -9,7 +9,7 @@ function padNum(number: number) { } const userName = process.env.GH_USERNAME; -const reviewers = process.env.requesting_user ? [process.env.requesting_user] : ["weswigham", "sandersn", "RyanCavanaugh"]; +const reviewers = process.env.REQUESTING_USER ? [process.env.REQUESTING_USER] : ["weswigham", "sandersn", "RyanCavanaugh"]; const now = new Date(); const branchName = `user-update-${process.env.TARGET_FORK}-${now.getFullYear()}${padNum(now.getMonth())}${padNum(now.getDay())}${process.env.TARGET_BRANCH ? "-" + process.env.TARGET_BRANCH : ""}`; const remoteUrl = `https://${process.argv[2]}@github.com/${userName}/TypeScript.git`; @@ -36,14 +36,14 @@ gh.pulls.create({ head: `${userName}:${branchName}`, base: process.env.TARGET_BRANCH || "master", body: -`${process.env.source_issue ? `This test run was triggerd by a request on https://github.com/Microsoft/TypeScript/pull/${process.env.source_issue} `+"\n" : ""}Please review the diff and merge if no changes are unexpected. +`${process.env.SOURCE_ISSUE ? `This test run was triggerd by a request on https://github.com/Microsoft/TypeScript/pull/${process.env.SOURCE_ISSUE} `+"\n" : ""}Please review the diff and merge if no changes are unexpected. You can view the build log [here](https://typescript.visualstudio.com/TypeScript/_build/index?buildId=${process.env.BUILD_BUILDID}&_a=summary). cc ${reviewers.map(r => "@" + r).join(" ")}`, }).then(async r => { const num = r.data.number; console.log(`Pull request ${num} created.`); - if (!process.env.source_issue) { + if (!process.env.SOURCE_ISSUE) { await gh.pulls.createReviewRequest({ owner: process.env.TARGET_FORK, repo: "TypeScript", @@ -53,7 +53,7 @@ cc ${reviewers.map(r => "@" + r).join(" ")}`, } else { await gh.issues.createComment({ - number: +process.env.source_issue, + number: +process.env.SOURCE_ISSUE, owner: "Microsoft", repo: "TypeScript", body: `The user suite test run you requested has finished and _failed_. I've opened a [PR with the baseline diff from master](${r.data.html_url}).` From 08d8f97bb45697812df434411469c19c80e789ed Mon Sep 17 00:00:00 2001 From: Anders Hejlsberg Date: Thu, 30 May 2019 16:06:49 -0700 Subject: [PATCH 119/119] Add comment --- src/compiler/checker.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index e83137b87e8..4558a284f32 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -20857,7 +20857,9 @@ namespace ts { // Inferences made from return types have lower priority than all other inferences. inferTypes(context.inferences, inferenceSourceType, inferenceTargetType, InferencePriority.ReturnType); // Create a type mapper for instantiating generic contextual types using the inferences made - // from the return type. + // from the return type. We need a separate inference pass here because (a) instantiation of + // the source type uses the outer context's return mapper (which excludes inferences made from + // outer arguments), and (b) we don't want any further inferences going into this context. const returnContext = createInferenceContext(signature.typeParameters!, signature, context.flags); const returnSourceType = instantiateType(contextualType, outerContext && outerContext.returnMapper); inferTypes(returnContext.inferences, returnSourceType, inferenceTargetType);