diff --git a/Jakefile b/Jakefile index dd09085800..665bb807b4 100644 --- a/Jakefile +++ b/Jakefile @@ -254,8 +254,6 @@ function compileFile(outFile, sources, prereqs, prefixes, useBuiltCompiler, noOu options += " --stripInternal" } - options += " --cacheDownlevelForOfLength --preserveNewLines"; - var cmd = host + " " + dir + compilerFilename + " " + options + " "; cmd = cmd + sources.join(" "); console.log(cmd + "\n"); diff --git a/src/compiler/commandLineParser.ts b/src/compiler/commandLineParser.ts index 269f23492e..4ba2da757e 100644 --- a/src/compiler/commandLineParser.ts +++ b/src/compiler/commandLineParser.ts @@ -140,18 +140,6 @@ module ts { description: Diagnostics.Do_not_emit_declarations_for_code_that_has_an_internal_annotation, experimental: true }, - { - name: "preserveNewLines", - type: "boolean", - description: Diagnostics.Preserve_new_lines_when_emitting_code, - experimental: true - }, - { - name: "cacheDownlevelForOfLength", - type: "boolean", - description: "Cache length access when downlevel emitting for-of statements", - experimental: true, - }, { name: "target", shortName: "t", diff --git a/src/compiler/emitter.ts b/src/compiler/emitter.ts index 758dbf2d0f..ac5fa31319 100644 --- a/src/compiler/emitter.ts +++ b/src/compiler/emitter.ts @@ -88,7 +88,6 @@ module ts { let writeLine = writer.writeLine; let increaseIndent = writer.increaseIndent; let decreaseIndent = writer.decreaseIndent; - let preserveNewLines = compilerOptions.preserveNewLines || false; let currentSourceFile: SourceFile; @@ -730,7 +729,7 @@ module ts { increaseIndent(); - if (preserveNewLines && nodeStartPositionsAreOnSameLine(parent, nodes[0])) { + if (nodeStartPositionsAreOnSameLine(parent, nodes[0])) { if (spacesBetweenBraces) { write(" "); } @@ -741,7 +740,7 @@ module ts { for (let i = 0, n = nodes.length; i < n; i++) { if (i) { - if (preserveNewLines && nodeEndIsOnSameLineAsNodeStart(nodes[i - 1], nodes[i])) { + if (nodeEndIsOnSameLineAsNodeStart(nodes[i - 1], nodes[i])) { write(", "); } else { @@ -759,7 +758,7 @@ module ts { decreaseIndent(); - if (preserveNewLines && nodeEndPositionsAreOnSameLine(parent, lastOrUndefined(nodes))) { + if (nodeEndPositionsAreOnSameLine(parent, lastOrUndefined(nodes))) { if (spacesBetweenBraces) { write(" "); } @@ -1658,7 +1657,7 @@ module ts { // If the code is not indented, an optional valueToWriteWhenNotIndenting will be // emitted instead. function indentIfOnDifferentLines(parent: Node, node1: Node, node2: Node, valueToWriteWhenNotIndenting?: string): boolean { - let realNodesAreOnDifferentLines = preserveNewLines && !nodeIsSynthesized(parent) && !nodeEndIsOnSameLineAsNodeStart(node1, node2); + let realNodesAreOnDifferentLines = !nodeIsSynthesized(parent) && !nodeEndIsOnSameLineAsNodeStart(node1, node2); // Always use a newline for synthesized code if the synthesizer desires it. let synthesizedNodeIsOnDifferentLine = synthesizedNodeStartsOnNewLine(node2); @@ -1966,7 +1965,7 @@ module ts { } function emitBlock(node: Block) { - if (preserveNewLines && isSingleLineEmptyBlock(node)) { + if (isSingleLineEmptyBlock(node)) { emitToken(SyntaxKind.OpenBraceToken, node.pos); write(" "); emitToken(SyntaxKind.CloseBraceToken, node.statements.end); @@ -2168,8 +2167,6 @@ module ts { let counter = createTempVariable(TempFlags._i); let rhsReference = rhsIsIdentifier ? node.expression : createTempVariable(TempFlags.Auto); - var cachedLength = compilerOptions.cacheDownlevelForOfLength ? createTempVariable(TempFlags._n) : undefined; - // This is the let keyword for the counter and rhsReference. The let keyword for // the LHS will be emitted inside the body. emitStart(node.expression); @@ -2190,14 +2187,6 @@ module ts { emitEnd(node.expression); } - if (cachedLength) { - write(", "); - emitNodeWithoutSourceMap(cachedLength); - write(" = "); - emitNodeWithoutSourceMap(rhsReference); - write(".length"); - } - write("; "); // _i < _a.length; @@ -2205,13 +2194,8 @@ module ts { emitNodeWithoutSourceMap(counter); write(" < "); - if (cachedLength) { - emitNodeWithoutSourceMap(cachedLength); - } - else { - emitNodeWithoutSourceMap(rhsReference); - write(".length"); - } + emitNodeWithoutSourceMap(rhsReference); + write(".length"); emitEnd(node.initializer); write("; "); @@ -2350,7 +2334,7 @@ module ts { write("default:"); } - if (preserveNewLines && node.statements.length === 1 && nodeStartPositionsAreOnSameLine(node, node.statements[0])) { + if (node.statements.length === 1 && nodeStartPositionsAreOnSameLine(node, node.statements[0])) { write(" "); emit(node.statements[0]); } @@ -3090,7 +3074,7 @@ module ts { // If we didn't have to emit any preamble code, then attempt to keep the arrow // function on one line. - if (preserveNewLines && !preambleEmitted && nodeStartPositionsAreOnSameLine(node, body)) { + if (!preambleEmitted && nodeStartPositionsAreOnSameLine(node, body)) { write(" "); emitStart(body); write("return "); @@ -3138,7 +3122,7 @@ module ts { let preambleEmitted = writer.getTextPos() !== initialTextPos; - if (preserveNewLines && !preambleEmitted && nodeEndIsOnSameLineAsNodeStart(body, body)) { + if (!preambleEmitted && nodeEndIsOnSameLineAsNodeStart(body, body)) { for (let statement of body.statements) { write(" "); emit(statement); diff --git a/src/compiler/types.ts b/src/compiler/types.ts index e5697f9f37..d24ee45e21 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -1588,8 +1588,6 @@ module ts { version?: boolean; watch?: boolean; /* @internal */ stripInternal?: boolean; - /* @internal */ preserveNewLines?: boolean; - /* @internal */ cacheDownlevelForOfLength?: boolean; [option: string]: string | number | boolean; } diff --git a/src/harness/harness.ts b/src/harness/harness.ts index 90ca94b4ab..f401f19da2 100644 --- a/src/harness/harness.ts +++ b/src/harness/harness.ts @@ -1008,10 +1008,6 @@ module Harness { options.outDir = setting.value; break; - case 'preservenewlines': - options.preserveNewLines = !!setting.value; - break; - case 'sourceroot': options.sourceRoot = setting.value; break; @@ -1465,7 +1461,7 @@ module Harness { var optionRegex = /^[\/]{2}\s*@(\w+)\s*:\s*(\S*)/gm; // multiple matches on multiple lines // List of allowed metadata names - var fileMetadataNames = ["filename", "comments", "declaration", "module", "nolib", "sourcemap", "target", "out", "outdir", "noemitonerror", "noimplicitany", "noresolve", "newline", "newlines", "emitbom", "errortruncation", "usecasesensitivefilenames", "preserveconstenums", "preservenewlines", "includebuiltfile", "suppressimplicitanyindexerrors", "stripinternal"]; + var fileMetadataNames = ["filename", "comments", "declaration", "module", "nolib", "sourcemap", "target", "out", "outdir", "noemitonerror", "noimplicitany", "noresolve", "newline", "newlines", "emitbom", "errortruncation", "usecasesensitivefilenames", "preserveconstenums", "includebuiltfile", "suppressimplicitanyindexerrors", "stripinternal"]; function extractCompilerSettings(content: string): CompilerSetting[] { diff --git a/tests/baselines/reference/2dArrays.js b/tests/baselines/reference/2dArrays.js index 7840f3d8c5..fe8ab380ba 100644 --- a/tests/baselines/reference/2dArrays.js +++ b/tests/baselines/reference/2dArrays.js @@ -30,9 +30,7 @@ var Board = (function () { function Board() { } Board.prototype.allShipsSunk = function () { - return this.ships.every(function (val) { - return val.isSunk; - }); + return this.ships.every(function (val) { return val.isSunk; }); }; return Board; })(); diff --git a/tests/baselines/reference/APISample_compile.js b/tests/baselines/reference/APISample_compile.js index 07d5e4337a..3f0ba5f18c 100644 --- a/tests/baselines/reference/APISample_compile.js +++ b/tests/baselines/reference/APISample_compile.js @@ -2021,8 +2021,6 @@ function compile(fileNames, options) { } exports.compile = compile; compile(process.argv.slice(2), { - noEmitOnError: true, - noImplicitAny: true, - target: 1 /* ES5 */, - module: 1 /* CommonJS */ + noEmitOnError: true, noImplicitAny: true, + target: 1 /* ES5 */, module: 1 /* CommonJS */ }); diff --git a/tests/baselines/reference/APISample_linter.js b/tests/baselines/reference/APISample_linter.js index b57acaf0e9..ab48f78aff 100644 --- a/tests/baselines/reference/APISample_linter.js +++ b/tests/baselines/reference/APISample_linter.js @@ -2055,7 +2055,8 @@ function delint(sourceFile) { if (ifStatement.thenStatement.kind !== 176 /* Block */) { report(ifStatement.thenStatement, "An if statement's contents should be wrapped in a block body."); } - if (ifStatement.elseStatement && ifStatement.elseStatement.kind !== 176 /* Block */ && ifStatement.elseStatement.kind !== 180 /* IfStatement */) { + if (ifStatement.elseStatement && + ifStatement.elseStatement.kind !== 176 /* Block */ && ifStatement.elseStatement.kind !== 180 /* IfStatement */) { report(ifStatement.elseStatement, "An else statement's contents should be wrapped in a block body."); } break; diff --git a/tests/baselines/reference/APISample_transform.js b/tests/baselines/reference/APISample_transform.js index 4004007508..d40c078a15 100644 --- a/tests/baselines/reference/APISample_transform.js +++ b/tests/baselines/reference/APISample_transform.js @@ -2051,35 +2051,20 @@ function transform(contents, compilerOptions) { // Create a compilerHost object to allow the compiler to read and write files var compilerHost = { getSourceFile: function (fileName, target) { - return files[fileName] !== undefined ? ts.createSourceFile(fileName, files[fileName], target) : undefined; + return files[fileName] !== undefined ? + ts.createSourceFile(fileName, files[fileName], target) : undefined; }, writeFile: function (name, text, writeByteOrderMark) { - outputs.push({ - name: name, - text: text, - writeByteOrderMark: writeByteOrderMark - }); + outputs.push({ name: name, text: text, writeByteOrderMark: writeByteOrderMark }); }, - getDefaultLibFileName: function () { - return "lib.d.ts"; - }, - useCaseSensitiveFileNames: function () { - return false; - }, - getCanonicalFileName: function (fileName) { - return fileName; - }, - getCurrentDirectory: function () { - return ""; - }, - getNewLine: function () { - return "\n"; - } + getDefaultLibFileName: function () { return "lib.d.ts"; }, + useCaseSensitiveFileNames: function () { return false; }, + getCanonicalFileName: function (fileName) { return fileName; }, + getCurrentDirectory: function () { return ""; }, + getNewLine: function () { return "\n"; } }; // Create a program from inputs - var program = ts.createProgram([ - "file.ts" - ], compilerOptions, compilerHost); + var program = ts.createProgram(["file.ts"], compilerOptions, compilerHost); // Query for early errors var errors = ts.getPreEmitDiagnostics(program); var emitResult = program.emit(); @@ -2087,7 +2072,8 @@ function transform(contents, compilerOptions) { return { outputs: outputs, errors: errors.map(function (e) { - return e.file.fileName + "(" + (e.file.getLineAndCharacterOfPosition(e.start).line + 1) + "): " + ts.flattenDiagnosticMessageText(e.messageText, os.EOL); + return e.file.fileName + "(" + (e.file.getLineAndCharacterOfPosition(e.start).line + 1) + "): " + + ts.flattenDiagnosticMessageText(e.messageText, os.EOL); }) }; } diff --git a/tests/baselines/reference/APISample_watcher.js b/tests/baselines/reference/APISample_watcher.js index 34503a0d81..c53034c11d 100644 --- a/tests/baselines/reference/APISample_watcher.js +++ b/tests/baselines/reference/APISample_watcher.js @@ -2080,33 +2080,21 @@ function watch(rootFileNames, options) { var files = {}; // initialize the list of files rootFileNames.forEach(function (fileName) { - files[fileName] = { - version: 0 - }; + files[fileName] = { version: 0 }; }); // Create the language service host to allow the LS to communicate with the host var servicesHost = { - getScriptFileNames: function () { - return rootFileNames; - }, - getScriptVersion: function (fileName) { - return files[fileName] && files[fileName].version.toString(); - }, + getScriptFileNames: function () { return rootFileNames; }, + getScriptVersion: function (fileName) { return files[fileName] && files[fileName].version.toString(); }, getScriptSnapshot: function (fileName) { if (!fs.existsSync(fileName)) { return undefined; } return ts.ScriptSnapshot.fromString(fs.readFileSync(fileName).toString()); }, - getCurrentDirectory: function () { - return process.cwd(); - }, - getCompilationSettings: function () { - return options; - }, - getDefaultLibFileName: function (options) { - return ts.getDefaultLibFilePath(options); - } + getCurrentDirectory: function () { return process.cwd(); }, + getCompilationSettings: function () { return options; }, + getDefaultLibFileName: function (options) { return ts.getDefaultLibFilePath(options); } }; // Create the language service files var services = ts.createLanguageService(servicesHost, ts.createDocumentRegistry()); @@ -2115,10 +2103,7 @@ function watch(rootFileNames, options) { // First time around, emit all files emitFile(fileName); // Add a watch on the file to handle next change - fs.watchFile(fileName, { - persistent: true, - interval: 250 - }, function (curr, prev) { + fs.watchFile(fileName, { persistent: true, interval: 250 }, function (curr, prev) { // Check timestamp if (+curr.mtime <= +prev.mtime) { return; @@ -2143,7 +2128,9 @@ function watch(rootFileNames, options) { }); } function logErrors(fileName) { - var allDiagnostics = services.getCompilerOptionsDiagnostics().concat(services.getSyntacticDiagnostics(fileName)).concat(services.getSemanticDiagnostics(fileName)); + var allDiagnostics = services.getCompilerOptionsDiagnostics() + .concat(services.getSyntacticDiagnostics(fileName)) + .concat(services.getSemanticDiagnostics(fileName)); allDiagnostics.forEach(function (diagnostic) { if (diagnostic.file) { var lineChar = diagnostic.file.getLineAndCharacterOfPosition(diagnostic.start); @@ -2156,10 +2143,7 @@ function watch(rootFileNames, options) { } } // Initialize files constituting the program as all .ts files in the current directory -var currentDirectoryFiles = fs.readdirSync(process.cwd()).filter(function (fileName) { - return fileName.length >= 3 && fileName.substr(fileName.length - 3, 3) === ".ts"; -}); +var currentDirectoryFiles = fs.readdirSync(process.cwd()). + filter(function (fileName) { return fileName.length >= 3 && fileName.substr(fileName.length - 3, 3) === ".ts"; }); // Start the watcher -watch(currentDirectoryFiles, { - module: 1 /* CommonJS */ -}); +watch(currentDirectoryFiles, { module: 1 /* CommonJS */ }); diff --git a/tests/baselines/reference/AmbientModuleAndNonAmbientFunctionWithTheSameNameAndCommonRoot.js b/tests/baselines/reference/AmbientModuleAndNonAmbientFunctionWithTheSameNameAndCommonRoot.js index 74a8a66a8b..90bed5cfd9 100644 --- a/tests/baselines/reference/AmbientModuleAndNonAmbientFunctionWithTheSameNameAndCommonRoot.js +++ b/tests/baselines/reference/AmbientModuleAndNonAmbientFunctionWithTheSameNameAndCommonRoot.js @@ -17,10 +17,7 @@ var cl = Point.Origin; //// [function.js] function Point() { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; } //// [test.js] var cl; diff --git a/tests/baselines/reference/ArrowFunctionExpression1.js b/tests/baselines/reference/ArrowFunctionExpression1.js index baa75809f6..21c71af243 100644 --- a/tests/baselines/reference/ArrowFunctionExpression1.js +++ b/tests/baselines/reference/ArrowFunctionExpression1.js @@ -2,5 +2,4 @@ var v = (public x: string) => { }; //// [ArrowFunctionExpression1.js] -var v = function (x) { -}; +var v = function (x) { }; diff --git a/tests/baselines/reference/ClassAndModuleThatMergeWithModuleMemberThatUsesClassTypeParameter.js b/tests/baselines/reference/ClassAndModuleThatMergeWithModuleMemberThatUsesClassTypeParameter.js index a3ccfbe2f4..b27c2ce5a3 100644 --- a/tests/baselines/reference/ClassAndModuleThatMergeWithModuleMemberThatUsesClassTypeParameter.js +++ b/tests/baselines/reference/ClassAndModuleThatMergeWithModuleMemberThatUsesClassTypeParameter.js @@ -58,8 +58,7 @@ var clodule1 = (function () { })(); var clodule1; (function (clodule1) { - function f(x) { - } + function f(x) { } })(clodule1 || (clodule1 = {})); var clodule2 = (function () { function clodule2() { @@ -82,9 +81,7 @@ var clodule3 = (function () { })(); var clodule3; (function (clodule3) { - clodule3.y = { - id: T - }; + clodule3.y = { id: T }; })(clodule3 || (clodule3 = {})); var clodule4 = (function () { function clodule4() { diff --git a/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedGenericFunctionAndGenericClassStaticFunctionOfTheSameName.js b/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedGenericFunctionAndGenericClassStaticFunctionOfTheSameName.js index cf39aa6c11..255e74631a 100644 --- a/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedGenericFunctionAndGenericClassStaticFunctionOfTheSameName.js +++ b/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedGenericFunctionAndGenericClassStaticFunctionOfTheSameName.js @@ -19,8 +19,7 @@ module clodule { var clodule = (function () { function clodule() { } - clodule.fn = function (id) { - }; + clodule.fn = function (id) { }; return clodule; })(); var clodule; diff --git a/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedGenericFunctionAndNonGenericClassStaticFunctionOfTheSameName.js b/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedGenericFunctionAndNonGenericClassStaticFunctionOfTheSameName.js index 69f72e3b4a..76ba858306 100644 --- a/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedGenericFunctionAndNonGenericClassStaticFunctionOfTheSameName.js +++ b/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedGenericFunctionAndNonGenericClassStaticFunctionOfTheSameName.js @@ -19,8 +19,7 @@ module clodule { var clodule = (function () { function clodule() { } - clodule.fn = function (id) { - }; + clodule.fn = function (id) { }; return clodule; })(); var clodule; diff --git a/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedStaticFunctionUsingClassPrivateStatics.js b/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedStaticFunctionUsingClassPrivateStatics.js index 827557bdba..5f01b6acff 100644 --- a/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedStaticFunctionUsingClassPrivateStatics.js +++ b/tests/baselines/reference/ClassAndModuleThatMergeWithModulesExportedStaticFunctionUsingClassPrivateStatics.js @@ -19,9 +19,7 @@ module clodule { var clodule = (function () { function clodule() { } - clodule.sfn = function (id) { - return 42; - }; + clodule.sfn = function (id) { return 42; }; return clodule; })(); var clodule; diff --git a/tests/baselines/reference/ClassAndModuleThatMergeWithStaticFunctionAndExportedFunctionThatShareAName.js b/tests/baselines/reference/ClassAndModuleThatMergeWithStaticFunctionAndExportedFunctionThatShareAName.js index 13483b591d..a86bc7d2e9 100644 --- a/tests/baselines/reference/ClassAndModuleThatMergeWithStaticFunctionAndExportedFunctionThatShareAName.js +++ b/tests/baselines/reference/ClassAndModuleThatMergeWithStaticFunctionAndExportedFunctionThatShareAName.js @@ -28,19 +28,12 @@ var Point = (function () { this.x = x; this.y = y; } - Point.Origin = function () { - return { - x: 0, - y: 0 - }; - }; // unexpected error here bug 840246 + Point.Origin = function () { return { x: 0, y: 0 }; }; // unexpected error here bug 840246 return Point; })(); var Point; (function (Point) { - function Origin() { - return null; - } + function Origin() { return null; } Point.Origin = Origin; //expected duplicate identifier error })(Point || (Point = {})); var A; @@ -50,20 +43,13 @@ var A; this.x = x; this.y = y; } - Point.Origin = function () { - return { - x: 0, - y: 0 - }; - }; // unexpected error here bug 840246 + Point.Origin = function () { return { x: 0, y: 0 }; }; // unexpected error here bug 840246 return Point; })(); A.Point = Point; var Point; (function (Point) { - function Origin() { - return ""; - } + function Origin() { return ""; } Point.Origin = Origin; //expected duplicate identifier error })(Point = A.Point || (A.Point = {})); })(A || (A = {})); diff --git a/tests/baselines/reference/ClassAndModuleThatMergeWithStaticFunctionAndNonExportedFunctionThatShareAName.js b/tests/baselines/reference/ClassAndModuleThatMergeWithStaticFunctionAndNonExportedFunctionThatShareAName.js index 188a69a18f..f462ea9eaa 100644 --- a/tests/baselines/reference/ClassAndModuleThatMergeWithStaticFunctionAndNonExportedFunctionThatShareAName.js +++ b/tests/baselines/reference/ClassAndModuleThatMergeWithStaticFunctionAndNonExportedFunctionThatShareAName.js @@ -28,19 +28,12 @@ var Point = (function () { this.x = x; this.y = y; } - Point.Origin = function () { - return { - x: 0, - y: 0 - }; - }; + Point.Origin = function () { return { x: 0, y: 0 }; }; return Point; })(); var Point; (function (Point) { - function Origin() { - return ""; - } // not an error, since not exported + function Origin() { return ""; } // not an error, since not exported })(Point || (Point = {})); var A; (function (A) { @@ -49,19 +42,12 @@ var A; this.x = x; this.y = y; } - Point.Origin = function () { - return { - x: 0, - y: 0 - }; - }; + Point.Origin = function () { return { x: 0, y: 0 }; }; return Point; })(); A.Point = Point; var Point; (function (Point) { - function Origin() { - return ""; - } // not an error since not exported + function Origin() { return ""; } // not an error since not exported })(Point = A.Point || (A.Point = {})); })(A || (A = {})); diff --git a/tests/baselines/reference/ClassAndModuleThatMergeWithStaticVariableAndExportedVarThatShareAName.js b/tests/baselines/reference/ClassAndModuleThatMergeWithStaticVariableAndExportedVarThatShareAName.js index c2c20f7f7f..45958ad62d 100644 --- a/tests/baselines/reference/ClassAndModuleThatMergeWithStaticVariableAndExportedVarThatShareAName.js +++ b/tests/baselines/reference/ClassAndModuleThatMergeWithStaticVariableAndExportedVarThatShareAName.js @@ -28,10 +28,7 @@ var Point = (function () { this.x = x; this.y = y; } - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; return Point; })(); var Point; @@ -45,10 +42,7 @@ var A; this.x = x; this.y = y; } - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; return Point; })(); A.Point = Point; diff --git a/tests/baselines/reference/ClassAndModuleThatMergeWithStaticVariableAndNonExportedVarThatShareAName.js b/tests/baselines/reference/ClassAndModuleThatMergeWithStaticVariableAndNonExportedVarThatShareAName.js index 241e1db7b0..ae56fd1acd 100644 --- a/tests/baselines/reference/ClassAndModuleThatMergeWithStaticVariableAndNonExportedVarThatShareAName.js +++ b/tests/baselines/reference/ClassAndModuleThatMergeWithStaticVariableAndNonExportedVarThatShareAName.js @@ -28,10 +28,7 @@ var Point = (function () { this.x = x; this.y = y; } - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; return Point; })(); var Point; @@ -45,10 +42,7 @@ var A; this.x = x; this.y = y; } - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; return Point; })(); A.Point = Point; diff --git a/tests/baselines/reference/ClassDeclaration11.js b/tests/baselines/reference/ClassDeclaration11.js index 6c4ba4ac6e..6284af0767 100644 --- a/tests/baselines/reference/ClassDeclaration11.js +++ b/tests/baselines/reference/ClassDeclaration11.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/ClassDeclaration13.js b/tests/baselines/reference/ClassDeclaration13.js index 4c4324eb1e..7791b77eae 100644 --- a/tests/baselines/reference/ClassDeclaration13.js +++ b/tests/baselines/reference/ClassDeclaration13.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype.bar = function () { - }; + C.prototype.bar = function () { }; return C; })(); diff --git a/tests/baselines/reference/ClassDeclaration21.js b/tests/baselines/reference/ClassDeclaration21.js index 94cf3587c8..b5144b607d 100644 --- a/tests/baselines/reference/ClassDeclaration21.js +++ b/tests/baselines/reference/ClassDeclaration21.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype[1] = function () { - }; + C.prototype[1] = function () { }; return C; })(); diff --git a/tests/baselines/reference/ClassDeclaration22.js b/tests/baselines/reference/ClassDeclaration22.js index c44ba4ba43..0074813e77 100644 --- a/tests/baselines/reference/ClassDeclaration22.js +++ b/tests/baselines/reference/ClassDeclaration22.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype["bar"] = function () { - }; + C.prototype["bar"] = function () { }; return C; })(); diff --git a/tests/baselines/reference/ES3For-ofTypeCheck2.js b/tests/baselines/reference/ES3For-ofTypeCheck2.js index 952eade6cf..865a5493a0 100644 --- a/tests/baselines/reference/ES3For-ofTypeCheck2.js +++ b/tests/baselines/reference/ES3For-ofTypeCheck2.js @@ -2,8 +2,6 @@ for (var v of [true]) { } //// [ES3For-ofTypeCheck2.js] -for (var _i = 0, _a = [ - true -]; _i < _a.length; _i++) { +for (var _i = 0, _a = [true]; _i < _a.length; _i++) { var v = _a[_i]; } diff --git a/tests/baselines/reference/ES5For-of1.js b/tests/baselines/reference/ES5For-of1.js index afdded3418..dffe843399 100644 --- a/tests/baselines/reference/ES5For-of1.js +++ b/tests/baselines/reference/ES5For-of1.js @@ -4,11 +4,7 @@ for (var v of ['a', 'b', 'c']) { } //// [ES5For-of1.js] -for (var _i = 0, _a = [ - 'a', - 'b', - 'c' -]; _i < _a.length; _i++) { +for (var _i = 0, _a = ['a', 'b', 'c']; _i < _a.length; _i++) { var v = _a[_i]; console.log(v); } diff --git a/tests/baselines/reference/ES5For-of1.js.map b/tests/baselines/reference/ES5For-of1.js.map index 4fa49b0f02..568ac1987e 100644 --- a/tests/baselines/reference/ES5For-of1.js.map +++ b/tests/baselines/reference/ES5For-of1.js.map @@ -1,2 +1,2 @@ //// [ES5For-of1.js.map] -{"version":3,"file":"ES5For-of1.js","sourceRoot":"","sources":["ES5For-of1.ts"],"names":[],"mappings":"AAAA,GAAG,CAAC,CAAU,UAAe,EAAf;IAAC,GAAG;IAAE,GAAG;IAAE,GAAG;CAAC,EAAxB,cAAK,EAAL,IAAwB,CAAC;IAAzB,IAAI,CAAC,SAAA;IACN,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAClB"} \ No newline at end of file +{"version":3,"file":"ES5For-of1.js","sourceRoot":"","sources":["ES5For-of1.ts"],"names":[],"mappings":"AAAA,GAAG,CAAC,CAAU,UAAe,EAAf,MAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAxB,cAAK,EAAL,IAAwB,CAAC;IAAzB,IAAI,CAAC,SAAA;IACN,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAClB"} \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of1.sourcemap.txt b/tests/baselines/reference/ES5For-of1.sourcemap.txt index c07414d1d8..7bdd7edfa1 100644 --- a/tests/baselines/reference/ES5For-of1.sourcemap.txt +++ b/tests/baselines/reference/ES5For-of1.sourcemap.txt @@ -8,72 +8,61 @@ sources: ES5For-of1.ts emittedFile:tests/cases/conformance/statements/for-ofStatements/ES5For-of1.js sourceFile:ES5For-of1.ts ------------------------------------------------------------------- ->>>for (var _i = 0, _a = [ +>>>for (var _i = 0, _a = ['a', 'b', 'c']; _i < _a.length; _i++) { 1 > 2 >^^^ 3 > ^ 4 > ^ 5 > ^^^^^^^^^^ 6 > ^^ +7 > ^^^^^^ +8 > ^^^ +9 > ^^ +10> ^^^ +11> ^^ +12> ^^^ +13> ^ +14> ^^ +15> ^^^^^^^^^^^^^^ +16> ^^ +17> ^^^^ +18> ^ 1 > 2 >for 3 > 4 > (var v of 5 > ['a', 'b', 'c'] 6 > +7 > [ +8 > 'a' +9 > , +10> 'b' +11> , +12> 'c' +13> ] +14> +15> var v +16> +17> var v of ['a', 'b', 'c'] +18> ) 1 >Emitted(1, 1) Source(1, 1) + SourceIndex(0) 2 >Emitted(1, 4) Source(1, 4) + SourceIndex(0) 3 >Emitted(1, 5) Source(1, 5) + SourceIndex(0) 4 >Emitted(1, 6) Source(1, 15) + SourceIndex(0) 5 >Emitted(1, 16) Source(1, 30) + SourceIndex(0) 6 >Emitted(1, 18) Source(1, 15) + SourceIndex(0) ---- ->>> 'a', -1 >^^^^ -2 > ^^^ -3 > ^^-> -1 >[ -2 > 'a' -1 >Emitted(2, 5) Source(1, 16) + SourceIndex(0) -2 >Emitted(2, 8) Source(1, 19) + SourceIndex(0) ---- ->>> 'b', -1->^^^^ -2 > ^^^ -3 > ^-> -1->, -2 > 'b' -1->Emitted(3, 5) Source(1, 21) + SourceIndex(0) -2 >Emitted(3, 8) Source(1, 24) + SourceIndex(0) ---- ->>> 'c' -1->^^^^ -2 > ^^^ -3 > ^^^^^^^^^^^^^^^^^^^^-> -1->, -2 > 'c' -1->Emitted(4, 5) Source(1, 26) + SourceIndex(0) -2 >Emitted(4, 8) Source(1, 29) + SourceIndex(0) ---- ->>>]; _i < _a.length; _i++) { -1->^ -2 > ^^ -3 > ^^^^^^^^^^^^^^ -4 > ^^ -5 > ^^^^ -6 > ^ -1->] -2 > -3 > var v -4 > -5 > var v of ['a', 'b', 'c'] -6 > ) -1->Emitted(5, 2) Source(1, 30) + SourceIndex(0) -2 >Emitted(5, 4) Source(1, 6) + SourceIndex(0) -3 >Emitted(5, 18) Source(1, 11) + SourceIndex(0) -4 >Emitted(5, 20) Source(1, 6) + SourceIndex(0) -5 >Emitted(5, 24) Source(1, 30) + SourceIndex(0) -6 >Emitted(5, 25) Source(1, 31) + SourceIndex(0) +7 >Emitted(1, 24) Source(1, 16) + SourceIndex(0) +8 >Emitted(1, 27) Source(1, 19) + SourceIndex(0) +9 >Emitted(1, 29) Source(1, 21) + SourceIndex(0) +10>Emitted(1, 32) Source(1, 24) + SourceIndex(0) +11>Emitted(1, 34) Source(1, 26) + SourceIndex(0) +12>Emitted(1, 37) Source(1, 29) + SourceIndex(0) +13>Emitted(1, 38) Source(1, 30) + SourceIndex(0) +14>Emitted(1, 40) Source(1, 6) + SourceIndex(0) +15>Emitted(1, 54) Source(1, 11) + SourceIndex(0) +16>Emitted(1, 56) Source(1, 6) + SourceIndex(0) +17>Emitted(1, 60) Source(1, 30) + SourceIndex(0) +18>Emitted(1, 61) Source(1, 31) + SourceIndex(0) --- >>> var v = _a[_i]; 1 >^^^^ @@ -85,10 +74,10 @@ sourceFile:ES5For-of1.ts 2 > var 3 > v 4 > -1 >Emitted(6, 5) Source(1, 6) + SourceIndex(0) -2 >Emitted(6, 9) Source(1, 10) + SourceIndex(0) -3 >Emitted(6, 10) Source(1, 11) + SourceIndex(0) -4 >Emitted(6, 19) Source(1, 11) + SourceIndex(0) +1 >Emitted(2, 5) Source(1, 6) + SourceIndex(0) +2 >Emitted(2, 9) Source(1, 10) + SourceIndex(0) +3 >Emitted(2, 10) Source(1, 11) + SourceIndex(0) +4 >Emitted(2, 19) Source(1, 11) + SourceIndex(0) --- >>> console.log(v); 1->^^^^ @@ -108,20 +97,20 @@ sourceFile:ES5For-of1.ts 6 > v 7 > ) 8 > ; -1->Emitted(7, 5) Source(2, 5) + SourceIndex(0) -2 >Emitted(7, 12) Source(2, 12) + SourceIndex(0) -3 >Emitted(7, 13) Source(2, 13) + SourceIndex(0) -4 >Emitted(7, 16) Source(2, 16) + SourceIndex(0) -5 >Emitted(7, 17) Source(2, 17) + SourceIndex(0) -6 >Emitted(7, 18) Source(2, 18) + SourceIndex(0) -7 >Emitted(7, 19) Source(2, 19) + SourceIndex(0) -8 >Emitted(7, 20) Source(2, 20) + SourceIndex(0) +1->Emitted(3, 5) Source(2, 5) + SourceIndex(0) +2 >Emitted(3, 12) Source(2, 12) + SourceIndex(0) +3 >Emitted(3, 13) Source(2, 13) + SourceIndex(0) +4 >Emitted(3, 16) Source(2, 16) + SourceIndex(0) +5 >Emitted(3, 17) Source(2, 17) + SourceIndex(0) +6 >Emitted(3, 18) Source(2, 18) + SourceIndex(0) +7 >Emitted(3, 19) Source(2, 19) + SourceIndex(0) +8 >Emitted(3, 20) Source(2, 20) + SourceIndex(0) --- >>>} 1 >^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > >} -1 >Emitted(8, 2) Source(3, 2) + SourceIndex(0) +1 >Emitted(4, 2) Source(3, 2) + SourceIndex(0) --- >>>//# sourceMappingURL=ES5For-of1.js.map \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of10.js b/tests/baselines/reference/ES5For-of10.js index 673e2ae0f7..f12dc9d8ac 100644 --- a/tests/baselines/reference/ES5For-of10.js +++ b/tests/baselines/reference/ES5For-of10.js @@ -9,9 +9,7 @@ for (foo().x of []) { //// [ES5For-of10.js] function foo() { - return { - x: 0 - }; + return { x: 0 }; } for (var _i = 0, _a = []; _i < _a.length; _i++) { foo().x = _a[_i]; diff --git a/tests/baselines/reference/ES5For-of12.js b/tests/baselines/reference/ES5For-of12.js index 7a5534f4aa..99c5fad5fa 100644 --- a/tests/baselines/reference/ES5For-of12.js +++ b/tests/baselines/reference/ES5For-of12.js @@ -2,10 +2,6 @@ for ([""] of [[""]]) { } //// [ES5For-of12.js] -for (var _i = 0, _a = [ - [ - "" - ] -]; _i < _a.length; _i++) { +for (var _i = 0, _a = [[""]]; _i < _a.length; _i++) { "" = _a[_i][0]; } diff --git a/tests/baselines/reference/ES5For-of13.js b/tests/baselines/reference/ES5For-of13.js index ba9c24eebf..2bcf98e14f 100644 --- a/tests/baselines/reference/ES5For-of13.js +++ b/tests/baselines/reference/ES5For-of13.js @@ -4,11 +4,7 @@ for (let v of ['a', 'b', 'c']) { } //// [ES5For-of13.js] -for (var _i = 0, _a = [ - 'a', - 'b', - 'c' -]; _i < _a.length; _i++) { +for (var _i = 0, _a = ['a', 'b', 'c']; _i < _a.length; _i++) { var v = _a[_i]; var x = v; } diff --git a/tests/baselines/reference/ES5For-of13.js.map b/tests/baselines/reference/ES5For-of13.js.map index 3027624c54..5ff54bb881 100644 --- a/tests/baselines/reference/ES5For-of13.js.map +++ b/tests/baselines/reference/ES5For-of13.js.map @@ -1,2 +1,2 @@ //// [ES5For-of13.js.map] -{"version":3,"file":"ES5For-of13.js","sourceRoot":"","sources":["ES5For-of13.ts"],"names":[],"mappings":"AAAA,GAAG,CAAC,CAAU,UAAe,EAAf;IAAC,GAAG;IAAE,GAAG;IAAE,GAAG;CAAC,EAAxB,cAAK,EAAL,IAAwB,CAAC;IAAzB,IAAI,CAAC,SAAA;IACN,IAAI,CAAC,GAAG,CAAC,CAAC;CACb"} \ No newline at end of file +{"version":3,"file":"ES5For-of13.js","sourceRoot":"","sources":["ES5For-of13.ts"],"names":[],"mappings":"AAAA,GAAG,CAAC,CAAU,UAAe,EAAf,MAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAxB,cAAK,EAAL,IAAwB,CAAC;IAAzB,IAAI,CAAC,SAAA;IACN,IAAI,CAAC,GAAG,CAAC,CAAC;CACb"} \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of13.sourcemap.txt b/tests/baselines/reference/ES5For-of13.sourcemap.txt index d2c3b6847e..c3a188e722 100644 --- a/tests/baselines/reference/ES5For-of13.sourcemap.txt +++ b/tests/baselines/reference/ES5For-of13.sourcemap.txt @@ -8,72 +8,61 @@ sources: ES5For-of13.ts emittedFile:tests/cases/conformance/statements/for-ofStatements/ES5For-of13.js sourceFile:ES5For-of13.ts ------------------------------------------------------------------- ->>>for (var _i = 0, _a = [ +>>>for (var _i = 0, _a = ['a', 'b', 'c']; _i < _a.length; _i++) { 1 > 2 >^^^ 3 > ^ 4 > ^ 5 > ^^^^^^^^^^ 6 > ^^ +7 > ^^^^^^ +8 > ^^^ +9 > ^^ +10> ^^^ +11> ^^ +12> ^^^ +13> ^ +14> ^^ +15> ^^^^^^^^^^^^^^ +16> ^^ +17> ^^^^ +18> ^ 1 > 2 >for 3 > 4 > (let v of 5 > ['a', 'b', 'c'] 6 > +7 > [ +8 > 'a' +9 > , +10> 'b' +11> , +12> 'c' +13> ] +14> +15> let v +16> +17> let v of ['a', 'b', 'c'] +18> ) 1 >Emitted(1, 1) Source(1, 1) + SourceIndex(0) 2 >Emitted(1, 4) Source(1, 4) + SourceIndex(0) 3 >Emitted(1, 5) Source(1, 5) + SourceIndex(0) 4 >Emitted(1, 6) Source(1, 15) + SourceIndex(0) 5 >Emitted(1, 16) Source(1, 30) + SourceIndex(0) 6 >Emitted(1, 18) Source(1, 15) + SourceIndex(0) ---- ->>> 'a', -1 >^^^^ -2 > ^^^ -3 > ^^-> -1 >[ -2 > 'a' -1 >Emitted(2, 5) Source(1, 16) + SourceIndex(0) -2 >Emitted(2, 8) Source(1, 19) + SourceIndex(0) ---- ->>> 'b', -1->^^^^ -2 > ^^^ -3 > ^-> -1->, -2 > 'b' -1->Emitted(3, 5) Source(1, 21) + SourceIndex(0) -2 >Emitted(3, 8) Source(1, 24) + SourceIndex(0) ---- ->>> 'c' -1->^^^^ -2 > ^^^ -3 > ^^^^^^^^^^^^^^^^^^^^-> -1->, -2 > 'c' -1->Emitted(4, 5) Source(1, 26) + SourceIndex(0) -2 >Emitted(4, 8) Source(1, 29) + SourceIndex(0) ---- ->>>]; _i < _a.length; _i++) { -1->^ -2 > ^^ -3 > ^^^^^^^^^^^^^^ -4 > ^^ -5 > ^^^^ -6 > ^ -1->] -2 > -3 > let v -4 > -5 > let v of ['a', 'b', 'c'] -6 > ) -1->Emitted(5, 2) Source(1, 30) + SourceIndex(0) -2 >Emitted(5, 4) Source(1, 6) + SourceIndex(0) -3 >Emitted(5, 18) Source(1, 11) + SourceIndex(0) -4 >Emitted(5, 20) Source(1, 6) + SourceIndex(0) -5 >Emitted(5, 24) Source(1, 30) + SourceIndex(0) -6 >Emitted(5, 25) Source(1, 31) + SourceIndex(0) +7 >Emitted(1, 24) Source(1, 16) + SourceIndex(0) +8 >Emitted(1, 27) Source(1, 19) + SourceIndex(0) +9 >Emitted(1, 29) Source(1, 21) + SourceIndex(0) +10>Emitted(1, 32) Source(1, 24) + SourceIndex(0) +11>Emitted(1, 34) Source(1, 26) + SourceIndex(0) +12>Emitted(1, 37) Source(1, 29) + SourceIndex(0) +13>Emitted(1, 38) Source(1, 30) + SourceIndex(0) +14>Emitted(1, 40) Source(1, 6) + SourceIndex(0) +15>Emitted(1, 54) Source(1, 11) + SourceIndex(0) +16>Emitted(1, 56) Source(1, 6) + SourceIndex(0) +17>Emitted(1, 60) Source(1, 30) + SourceIndex(0) +18>Emitted(1, 61) Source(1, 31) + SourceIndex(0) --- >>> var v = _a[_i]; 1 >^^^^ @@ -84,10 +73,10 @@ sourceFile:ES5For-of13.ts 2 > let 3 > v 4 > -1 >Emitted(6, 5) Source(1, 6) + SourceIndex(0) -2 >Emitted(6, 9) Source(1, 10) + SourceIndex(0) -3 >Emitted(6, 10) Source(1, 11) + SourceIndex(0) -4 >Emitted(6, 19) Source(1, 11) + SourceIndex(0) +1 >Emitted(2, 5) Source(1, 6) + SourceIndex(0) +2 >Emitted(2, 9) Source(1, 10) + SourceIndex(0) +3 >Emitted(2, 10) Source(1, 11) + SourceIndex(0) +4 >Emitted(2, 19) Source(1, 11) + SourceIndex(0) --- >>> var x = v; 1 >^^^^ @@ -103,18 +92,18 @@ sourceFile:ES5For-of13.ts 4 > = 5 > v 6 > ; -1 >Emitted(7, 5) Source(2, 5) + SourceIndex(0) -2 >Emitted(7, 9) Source(2, 9) + SourceIndex(0) -3 >Emitted(7, 10) Source(2, 10) + SourceIndex(0) -4 >Emitted(7, 13) Source(2, 13) + SourceIndex(0) -5 >Emitted(7, 14) Source(2, 14) + SourceIndex(0) -6 >Emitted(7, 15) Source(2, 15) + SourceIndex(0) +1 >Emitted(3, 5) Source(2, 5) + SourceIndex(0) +2 >Emitted(3, 9) Source(2, 9) + SourceIndex(0) +3 >Emitted(3, 10) Source(2, 10) + SourceIndex(0) +4 >Emitted(3, 13) Source(2, 13) + SourceIndex(0) +5 >Emitted(3, 14) Source(2, 14) + SourceIndex(0) +6 >Emitted(3, 15) Source(2, 15) + SourceIndex(0) --- >>>} 1 >^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > >} -1 >Emitted(8, 2) Source(3, 2) + SourceIndex(0) +1 >Emitted(4, 2) Source(3, 2) + SourceIndex(0) --- >>>//# sourceMappingURL=ES5For-of13.js.map \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of17.js b/tests/baselines/reference/ES5For-of17.js index 4752f1be90..50064d8293 100644 --- a/tests/baselines/reference/ES5For-of17.js +++ b/tests/baselines/reference/ES5For-of17.js @@ -11,9 +11,7 @@ for (let v of []) { for (var _i = 0, _a = []; _i < _a.length; _i++) { var v = _a[_i]; v; - for (var _b = 0, _c = [ - v - ]; _b < _c.length; _b++) { + for (var _b = 0, _c = [v]; _b < _c.length; _b++) { var v_1 = _c[_b]; var x = v_1; v_1++; diff --git a/tests/baselines/reference/ES5For-of20.js b/tests/baselines/reference/ES5For-of20.js index d3f44e4922..c6376ab05d 100644 --- a/tests/baselines/reference/ES5For-of20.js +++ b/tests/baselines/reference/ES5For-of20.js @@ -10,9 +10,7 @@ for (let v of []) { for (var _i = 0, _a = []; _i < _a.length; _i++) { var v = _a[_i]; var v_1; - for (var _b = 0, _c = [ - v - ]; _b < _c.length; _b++) { + for (var _b = 0, _c = [v]; _b < _c.length; _b++) { var v_2 = _c[_b]; var v_3; } diff --git a/tests/baselines/reference/ES5For-of22.js b/tests/baselines/reference/ES5For-of22.js index 87b084d52a..6e88a5c4d7 100644 --- a/tests/baselines/reference/ES5For-of22.js +++ b/tests/baselines/reference/ES5For-of22.js @@ -5,11 +5,7 @@ for (var x of [1, 2, 3]) { } //// [ES5For-of22.js] -for (var _i = 0, _b = [ - 1, - 2, - 3 -]; _i < _b.length; _i++) { +for (var _i = 0, _b = [1, 2, 3]; _i < _b.length; _i++) { var x = _b[_i]; var _a = 0; console.log(x); diff --git a/tests/baselines/reference/ES5For-of23.js b/tests/baselines/reference/ES5For-of23.js index dcecfac69d..3842591820 100644 --- a/tests/baselines/reference/ES5For-of23.js +++ b/tests/baselines/reference/ES5For-of23.js @@ -5,11 +5,7 @@ for (var x of [1, 2, 3]) { } //// [ES5For-of23.js] -for (var _i = 0, _b = [ - 1, - 2, - 3 -]; _i < _b.length; _i++) { +for (var _i = 0, _b = [1, 2, 3]; _i < _b.length; _i++) { var x = _b[_i]; var _a = 0; console.log(x); diff --git a/tests/baselines/reference/ES5For-of24.js b/tests/baselines/reference/ES5For-of24.js index 00cd24ea28..cdc0876692 100644 --- a/tests/baselines/reference/ES5For-of24.js +++ b/tests/baselines/reference/ES5For-of24.js @@ -5,11 +5,7 @@ for (var v of a) { } //// [ES5For-of24.js] -var a = [ - 1, - 2, - 3 -]; +var a = [1, 2, 3]; for (var _i = 0; _i < a.length; _i++) { var v = a[_i]; var a_1 = 0; diff --git a/tests/baselines/reference/ES5For-of25.js b/tests/baselines/reference/ES5For-of25.js index 14e59a472f..756c14fbe8 100644 --- a/tests/baselines/reference/ES5For-of25.js +++ b/tests/baselines/reference/ES5For-of25.js @@ -6,11 +6,7 @@ for (var v of a) { } //// [ES5For-of25.js] -var a = [ - 1, - 2, - 3 -]; +var a = [1, 2, 3]; for (var _i = 0; _i < a.length; _i++) { var v = a[_i]; v; diff --git a/tests/baselines/reference/ES5For-of25.js.map b/tests/baselines/reference/ES5For-of25.js.map index 90f1b9c075..cc31767128 100644 --- a/tests/baselines/reference/ES5For-of25.js.map +++ b/tests/baselines/reference/ES5For-of25.js.map @@ -1,2 +1,2 @@ //// [ES5For-of25.js.map] -{"version":3,"file":"ES5For-of25.js","sourceRoot":"","sources":["ES5For-of25.ts"],"names":[],"mappings":"AAAA,IAAI,CAAC,GAAG;IAAC,CAAC;IAAE,CAAC;IAAE,CAAC;CAAC,CAAC;AAClB,GAAG,CAAC,CAAU,UAAC,EAAV,aAAK,EAAL,IAAU,CAAC;IAAX,IAAI,CAAC,GAAI,CAAC,IAAL;IACN,CAAC,CAAC;IACF,CAAC,CAAC;CACL"} \ No newline at end of file +{"version":3,"file":"ES5For-of25.js","sourceRoot":"","sources":["ES5For-of25.ts"],"names":[],"mappings":"AAAA,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;AAClB,GAAG,CAAC,CAAU,UAAC,EAAV,aAAK,EAAL,IAAU,CAAC;IAAX,IAAI,CAAC,GAAI,CAAC,IAAL;IACN,CAAC,CAAC;IACF,CAAC,CAAC;CACL"} \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of25.sourcemap.txt b/tests/baselines/reference/ES5For-of25.sourcemap.txt index 1031764b03..623627fde2 100644 --- a/tests/baselines/reference/ES5For-of25.sourcemap.txt +++ b/tests/baselines/reference/ES5For-of25.sourcemap.txt @@ -8,54 +8,44 @@ sources: ES5For-of25.ts emittedFile:tests/cases/conformance/statements/for-ofStatements/ES5For-of25.js sourceFile:ES5For-of25.ts ------------------------------------------------------------------- ->>>var a = [ +>>>var a = [1, 2, 3]; 1 > 2 >^^^^ 3 > ^ 4 > ^^^ +5 > ^ +6 > ^ +7 > ^^ +8 > ^ +9 > ^^ +10> ^ +11> ^ +12> ^ +13> ^^^^^^^^^^^^^^^^^^^^^^-> 1 > 2 >var 3 > a 4 > = +5 > [ +6 > 1 +7 > , +8 > 2 +9 > , +10> 3 +11> ] +12> ; 1 >Emitted(1, 1) Source(1, 1) + SourceIndex(0) 2 >Emitted(1, 5) Source(1, 5) + SourceIndex(0) 3 >Emitted(1, 6) Source(1, 6) + SourceIndex(0) 4 >Emitted(1, 9) Source(1, 9) + SourceIndex(0) ---- ->>> 1, -1 >^^^^ -2 > ^ -3 > ^^-> -1 >[ -2 > 1 -1 >Emitted(2, 5) Source(1, 10) + SourceIndex(0) -2 >Emitted(2, 6) Source(1, 11) + SourceIndex(0) ---- ->>> 2, -1->^^^^ -2 > ^ -3 > ^-> -1->, -2 > 2 -1->Emitted(3, 5) Source(1, 13) + SourceIndex(0) -2 >Emitted(3, 6) Source(1, 14) + SourceIndex(0) ---- ->>> 3 -1->^^^^ -2 > ^ -1->, -2 > 3 -1->Emitted(4, 5) Source(1, 16) + SourceIndex(0) -2 >Emitted(4, 6) Source(1, 17) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(5, 2) Source(1, 18) + SourceIndex(0) -2 >Emitted(5, 3) Source(1, 19) + SourceIndex(0) +5 >Emitted(1, 10) Source(1, 10) + SourceIndex(0) +6 >Emitted(1, 11) Source(1, 11) + SourceIndex(0) +7 >Emitted(1, 13) Source(1, 13) + SourceIndex(0) +8 >Emitted(1, 14) Source(1, 14) + SourceIndex(0) +9 >Emitted(1, 16) Source(1, 16) + SourceIndex(0) +10>Emitted(1, 17) Source(1, 17) + SourceIndex(0) +11>Emitted(1, 18) Source(1, 18) + SourceIndex(0) +12>Emitted(1, 19) Source(1, 19) + SourceIndex(0) --- >>>for (var _i = 0; _i < a.length; _i++) { 1-> @@ -79,16 +69,16 @@ sourceFile:ES5For-of25.ts 8 > 9 > var v of a 10> ) -1->Emitted(6, 1) Source(2, 1) + SourceIndex(0) -2 >Emitted(6, 4) Source(2, 4) + SourceIndex(0) -3 >Emitted(6, 5) Source(2, 5) + SourceIndex(0) -4 >Emitted(6, 6) Source(2, 15) + SourceIndex(0) -5 >Emitted(6, 16) Source(2, 16) + SourceIndex(0) -6 >Emitted(6, 18) Source(2, 6) + SourceIndex(0) -7 >Emitted(6, 31) Source(2, 11) + SourceIndex(0) -8 >Emitted(6, 33) Source(2, 6) + SourceIndex(0) -9 >Emitted(6, 37) Source(2, 16) + SourceIndex(0) -10>Emitted(6, 38) Source(2, 17) + SourceIndex(0) +1->Emitted(2, 1) Source(2, 1) + SourceIndex(0) +2 >Emitted(2, 4) Source(2, 4) + SourceIndex(0) +3 >Emitted(2, 5) Source(2, 5) + SourceIndex(0) +4 >Emitted(2, 6) Source(2, 15) + SourceIndex(0) +5 >Emitted(2, 16) Source(2, 16) + SourceIndex(0) +6 >Emitted(2, 18) Source(2, 6) + SourceIndex(0) +7 >Emitted(2, 31) Source(2, 11) + SourceIndex(0) +8 >Emitted(2, 33) Source(2, 6) + SourceIndex(0) +9 >Emitted(2, 37) Source(2, 16) + SourceIndex(0) +10>Emitted(2, 38) Source(2, 17) + SourceIndex(0) --- >>> var v = a[_i]; 1 >^^^^ @@ -103,12 +93,12 @@ sourceFile:ES5For-of25.ts 4 > of 5 > a 6 > -1 >Emitted(7, 5) Source(2, 6) + SourceIndex(0) -2 >Emitted(7, 9) Source(2, 10) + SourceIndex(0) -3 >Emitted(7, 10) Source(2, 11) + SourceIndex(0) -4 >Emitted(7, 13) Source(2, 15) + SourceIndex(0) -5 >Emitted(7, 14) Source(2, 16) + SourceIndex(0) -6 >Emitted(7, 18) Source(2, 11) + SourceIndex(0) +1 >Emitted(3, 5) Source(2, 6) + SourceIndex(0) +2 >Emitted(3, 9) Source(2, 10) + SourceIndex(0) +3 >Emitted(3, 10) Source(2, 11) + SourceIndex(0) +4 >Emitted(3, 13) Source(2, 15) + SourceIndex(0) +5 >Emitted(3, 14) Source(2, 16) + SourceIndex(0) +6 >Emitted(3, 18) Source(2, 11) + SourceIndex(0) --- >>> v; 1 >^^^^ @@ -119,9 +109,9 @@ sourceFile:ES5For-of25.ts > 2 > v 3 > ; -1 >Emitted(8, 5) Source(3, 5) + SourceIndex(0) -2 >Emitted(8, 6) Source(3, 6) + SourceIndex(0) -3 >Emitted(8, 7) Source(3, 7) + SourceIndex(0) +1 >Emitted(4, 5) Source(3, 5) + SourceIndex(0) +2 >Emitted(4, 6) Source(3, 6) + SourceIndex(0) +3 >Emitted(4, 7) Source(3, 7) + SourceIndex(0) --- >>> a; 1->^^^^ @@ -131,15 +121,15 @@ sourceFile:ES5For-of25.ts > 2 > a 3 > ; -1->Emitted(9, 5) Source(4, 5) + SourceIndex(0) -2 >Emitted(9, 6) Source(4, 6) + SourceIndex(0) -3 >Emitted(9, 7) Source(4, 7) + SourceIndex(0) +1->Emitted(5, 5) Source(4, 5) + SourceIndex(0) +2 >Emitted(5, 6) Source(4, 6) + SourceIndex(0) +3 >Emitted(5, 7) Source(4, 7) + SourceIndex(0) --- >>>} 1 >^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > >} -1 >Emitted(10, 2) Source(5, 2) + SourceIndex(0) +1 >Emitted(6, 2) Source(5, 2) + SourceIndex(0) --- >>>//# sourceMappingURL=ES5For-of25.js.map \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of26.js b/tests/baselines/reference/ES5For-of26.js index 2cbb65ad79..4571cc660a 100644 --- a/tests/baselines/reference/ES5For-of26.js +++ b/tests/baselines/reference/ES5For-of26.js @@ -5,10 +5,7 @@ for (var [a = 0, b = 1] of [2, 3]) { } //// [ES5For-of26.js] -for (var _i = 0, _a = [ - 2, - 3 -]; _i < _a.length; _i++) { +for (var _i = 0, _a = [2, 3]; _i < _a.length; _i++) { var _b = _a[_i], _c = _b[0], a = _c === void 0 ? 0 : _c, _d = _b[1], b = _d === void 0 ? 1 : _d; a; b; diff --git a/tests/baselines/reference/ES5For-of26.js.map b/tests/baselines/reference/ES5For-of26.js.map index d80a8a7595..704a3a24f2 100644 --- a/tests/baselines/reference/ES5For-of26.js.map +++ b/tests/baselines/reference/ES5For-of26.js.map @@ -1,2 +1,2 @@ //// [ES5For-of26.js.map] -{"version":3,"file":"ES5For-of26.js","sourceRoot":"","sources":["ES5For-of26.ts"],"names":[],"mappings":"AAAA,GAAG,CAAC,CAAuB,UAAM,EAAN;IAAC,CAAC;IAAE,CAAC;CAAC,EAA5B,cAAkB,EAAlB,IAA4B,CAAC;IAA7B,6BAAK,CAAC,mBAAG,CAAC,mBAAE,CAAC,mBAAG,CAAC,KAAC;IACnB,CAAC,CAAC;IACF,CAAC,CAAC;CACL"} \ No newline at end of file +{"version":3,"file":"ES5For-of26.js","sourceRoot":"","sources":["ES5For-of26.ts"],"names":[],"mappings":"AAAA,GAAG,CAAC,CAAuB,UAAM,EAAN,MAAC,CAAC,EAAE,CAAC,CAAC,EAA5B,cAAkB,EAAlB,IAA4B,CAAC;IAA7B,6BAAK,CAAC,mBAAG,CAAC,mBAAE,CAAC,mBAAG,CAAC,KAAC;IACnB,CAAC,CAAC;IACF,CAAC,CAAC;CACL"} \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of26.sourcemap.txt b/tests/baselines/reference/ES5For-of26.sourcemap.txt index 4fcc759dca..c9942b1e86 100644 --- a/tests/baselines/reference/ES5For-of26.sourcemap.txt +++ b/tests/baselines/reference/ES5For-of26.sourcemap.txt @@ -8,64 +8,56 @@ sources: ES5For-of26.ts emittedFile:tests/cases/conformance/statements/for-ofStatements/ES5For-of26.js sourceFile:ES5For-of26.ts ------------------------------------------------------------------- ->>>for (var _i = 0, _a = [ +>>>for (var _i = 0, _a = [2, 3]; _i < _a.length; _i++) { 1 > 2 >^^^ 3 > ^ 4 > ^ 5 > ^^^^^^^^^^ 6 > ^^ +7 > ^^^^^^ +8 > ^ +9 > ^^ +10> ^ +11> ^ +12> ^^ +13> ^^^^^^^^^^^^^^ +14> ^^ +15> ^^^^ +16> ^ +17> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > 2 >for 3 > 4 > (var [a = 0, b = 1] of 5 > [2, 3] 6 > +7 > [ +8 > 2 +9 > , +10> 3 +11> ] +12> +13> var [a = 0, b = 1] +14> +15> var [a = 0, b = 1] of [2, 3] +16> ) 1 >Emitted(1, 1) Source(1, 1) + SourceIndex(0) 2 >Emitted(1, 4) Source(1, 4) + SourceIndex(0) 3 >Emitted(1, 5) Source(1, 5) + SourceIndex(0) 4 >Emitted(1, 6) Source(1, 28) + SourceIndex(0) 5 >Emitted(1, 16) Source(1, 34) + SourceIndex(0) 6 >Emitted(1, 18) Source(1, 28) + SourceIndex(0) ---- ->>> 2, -1 >^^^^ -2 > ^ -3 > ^-> -1 >[ -2 > 2 -1 >Emitted(2, 5) Source(1, 29) + SourceIndex(0) -2 >Emitted(2, 6) Source(1, 30) + SourceIndex(0) ---- ->>> 3 -1->^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^-> -1->, -2 > 3 -1->Emitted(3, 5) Source(1, 32) + SourceIndex(0) -2 >Emitted(3, 6) Source(1, 33) + SourceIndex(0) ---- ->>>]; _i < _a.length; _i++) { -1->^ -2 > ^^ -3 > ^^^^^^^^^^^^^^ -4 > ^^ -5 > ^^^^ -6 > ^ -7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1->] -2 > -3 > var [a = 0, b = 1] -4 > -5 > var [a = 0, b = 1] of [2, 3] -6 > ) -1->Emitted(4, 2) Source(1, 34) + SourceIndex(0) -2 >Emitted(4, 4) Source(1, 6) + SourceIndex(0) -3 >Emitted(4, 18) Source(1, 24) + SourceIndex(0) -4 >Emitted(4, 20) Source(1, 6) + SourceIndex(0) -5 >Emitted(4, 24) Source(1, 34) + SourceIndex(0) -6 >Emitted(4, 25) Source(1, 35) + SourceIndex(0) +7 >Emitted(1, 24) Source(1, 29) + SourceIndex(0) +8 >Emitted(1, 25) Source(1, 30) + SourceIndex(0) +9 >Emitted(1, 27) Source(1, 32) + SourceIndex(0) +10>Emitted(1, 28) Source(1, 33) + SourceIndex(0) +11>Emitted(1, 29) Source(1, 34) + SourceIndex(0) +12>Emitted(1, 31) Source(1, 6) + SourceIndex(0) +13>Emitted(1, 45) Source(1, 24) + SourceIndex(0) +14>Emitted(1, 47) Source(1, 6) + SourceIndex(0) +15>Emitted(1, 51) Source(1, 34) + SourceIndex(0) +16>Emitted(1, 52) Source(1, 35) + SourceIndex(0) --- >>> var _b = _a[_i], _c = _b[0], a = _c === void 0 ? 0 : _c, _d = _b[1], b = _d === void 0 ? 1 : _d; 1->^^^^ @@ -88,16 +80,16 @@ sourceFile:ES5For-of26.ts 8 > = 9 > 1 10> ] -1->Emitted(5, 5) Source(1, 6) + SourceIndex(0) -2 >Emitted(5, 34) Source(1, 11) + SourceIndex(0) -3 >Emitted(5, 35) Source(1, 12) + SourceIndex(0) -4 >Emitted(5, 54) Source(1, 15) + SourceIndex(0) -5 >Emitted(5, 55) Source(1, 16) + SourceIndex(0) -6 >Emitted(5, 74) Source(1, 18) + SourceIndex(0) -7 >Emitted(5, 75) Source(1, 19) + SourceIndex(0) -8 >Emitted(5, 94) Source(1, 22) + SourceIndex(0) -9 >Emitted(5, 95) Source(1, 23) + SourceIndex(0) -10>Emitted(5, 100) Source(1, 24) + SourceIndex(0) +1->Emitted(2, 5) Source(1, 6) + SourceIndex(0) +2 >Emitted(2, 34) Source(1, 11) + SourceIndex(0) +3 >Emitted(2, 35) Source(1, 12) + SourceIndex(0) +4 >Emitted(2, 54) Source(1, 15) + SourceIndex(0) +5 >Emitted(2, 55) Source(1, 16) + SourceIndex(0) +6 >Emitted(2, 74) Source(1, 18) + SourceIndex(0) +7 >Emitted(2, 75) Source(1, 19) + SourceIndex(0) +8 >Emitted(2, 94) Source(1, 22) + SourceIndex(0) +9 >Emitted(2, 95) Source(1, 23) + SourceIndex(0) +10>Emitted(2, 100) Source(1, 24) + SourceIndex(0) --- >>> a; 1 >^^^^ @@ -108,9 +100,9 @@ sourceFile:ES5For-of26.ts > 2 > a 3 > ; -1 >Emitted(6, 5) Source(2, 5) + SourceIndex(0) -2 >Emitted(6, 6) Source(2, 6) + SourceIndex(0) -3 >Emitted(6, 7) Source(2, 7) + SourceIndex(0) +1 >Emitted(3, 5) Source(2, 5) + SourceIndex(0) +2 >Emitted(3, 6) Source(2, 6) + SourceIndex(0) +3 >Emitted(3, 7) Source(2, 7) + SourceIndex(0) --- >>> b; 1->^^^^ @@ -120,15 +112,15 @@ sourceFile:ES5For-of26.ts > 2 > b 3 > ; -1->Emitted(7, 5) Source(3, 5) + SourceIndex(0) -2 >Emitted(7, 6) Source(3, 6) + SourceIndex(0) -3 >Emitted(7, 7) Source(3, 7) + SourceIndex(0) +1->Emitted(4, 5) Source(3, 5) + SourceIndex(0) +2 >Emitted(4, 6) Source(3, 6) + SourceIndex(0) +3 >Emitted(4, 7) Source(3, 7) + SourceIndex(0) --- >>>} 1 >^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > >} -1 >Emitted(8, 2) Source(4, 2) + SourceIndex(0) +1 >Emitted(5, 2) Source(4, 2) + SourceIndex(0) --- >>>//# sourceMappingURL=ES5For-of26.js.map \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of27.js b/tests/baselines/reference/ES5For-of27.js index c3993f6da5..c8e5a03b11 100644 --- a/tests/baselines/reference/ES5For-of27.js +++ b/tests/baselines/reference/ES5For-of27.js @@ -5,10 +5,7 @@ for (var {x: a = 0, y: b = 1} of [2, 3]) { } //// [ES5For-of27.js] -for (var _i = 0, _a = [ - 2, - 3 -]; _i < _a.length; _i++) { +for (var _i = 0, _a = [2, 3]; _i < _a.length; _i++) { var _b = _a[_i], _c = _b.x, a = _c === void 0 ? 0 : _c, _d = _b.y, b = _d === void 0 ? 1 : _d; a; b; diff --git a/tests/baselines/reference/ES5For-of28.js b/tests/baselines/reference/ES5For-of28.js index f1fa44a845..362b883521 100644 --- a/tests/baselines/reference/ES5For-of28.js +++ b/tests/baselines/reference/ES5For-of28.js @@ -5,10 +5,7 @@ for (let [a = 0, b = 1] of [2, 3]) { } //// [ES5For-of28.js] -for (var _i = 0, _a = [ - 2, - 3 -]; _i < _a.length; _i++) { +for (var _i = 0, _a = [2, 3]; _i < _a.length; _i++) { var _b = _a[_i], _c = _b[0], a = _c === void 0 ? 0 : _c, _d = _b[1], b = _d === void 0 ? 1 : _d; a; b; diff --git a/tests/baselines/reference/ES5For-of29.js b/tests/baselines/reference/ES5For-of29.js index 11f847262e..338ff311db 100644 --- a/tests/baselines/reference/ES5For-of29.js +++ b/tests/baselines/reference/ES5For-of29.js @@ -5,10 +5,7 @@ for (const {x: a = 0, y: b = 1} of [2, 3]) { } //// [ES5For-of29.js] -for (var _i = 0, _a = [ - 2, - 3 -]; _i < _a.length; _i++) { +for (var _i = 0, _a = [2, 3]; _i < _a.length; _i++) { var _b = _a[_i], _c = _b.x, a = _c === void 0 ? 0 : _c, _d = _b.y, b = _d === void 0 ? 1 : _d; a; b; diff --git a/tests/baselines/reference/ES5For-of3.js b/tests/baselines/reference/ES5For-of3.js index 9c2808edbb..648d34a9b1 100644 --- a/tests/baselines/reference/ES5For-of3.js +++ b/tests/baselines/reference/ES5For-of3.js @@ -3,11 +3,7 @@ for (var v of ['a', 'b', 'c']) var x = v; //// [ES5For-of3.js] -for (var _i = 0, _a = [ - 'a', - 'b', - 'c' -]; _i < _a.length; _i++) { +for (var _i = 0, _a = ['a', 'b', 'c']; _i < _a.length; _i++) { var v = _a[_i]; var x = v; } diff --git a/tests/baselines/reference/ES5For-of3.js.map b/tests/baselines/reference/ES5For-of3.js.map index bfc09619d8..7454e1ca85 100644 --- a/tests/baselines/reference/ES5For-of3.js.map +++ b/tests/baselines/reference/ES5For-of3.js.map @@ -1,2 +1,2 @@ //// [ES5For-of3.js.map] -{"version":3,"file":"ES5For-of3.js","sourceRoot":"","sources":["ES5For-of3.ts"],"names":[],"mappings":"AAAA,GAAG,CAAC,CAAU,UAAe,EAAf;IAAC,GAAG;IAAE,GAAG;IAAE,GAAG;CAAC,EAAxB,cAAK,EAAL,IAAwB,CAAC;IAAzB,IAAI,CAAC,SAAA;IACN,IAAI,CAAC,GAAG,CAAC,CAAC;CAAA"} \ No newline at end of file +{"version":3,"file":"ES5For-of3.js","sourceRoot":"","sources":["ES5For-of3.ts"],"names":[],"mappings":"AAAA,GAAG,CAAC,CAAU,UAAe,EAAf,MAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAxB,cAAK,EAAL,IAAwB,CAAC;IAAzB,IAAI,CAAC,SAAA;IACN,IAAI,CAAC,GAAG,CAAC,CAAC;CAAA"} \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of3.sourcemap.txt b/tests/baselines/reference/ES5For-of3.sourcemap.txt index 252a4a7414..dd0bca37b6 100644 --- a/tests/baselines/reference/ES5For-of3.sourcemap.txt +++ b/tests/baselines/reference/ES5For-of3.sourcemap.txt @@ -8,72 +8,61 @@ sources: ES5For-of3.ts emittedFile:tests/cases/conformance/statements/for-ofStatements/ES5For-of3.js sourceFile:ES5For-of3.ts ------------------------------------------------------------------- ->>>for (var _i = 0, _a = [ +>>>for (var _i = 0, _a = ['a', 'b', 'c']; _i < _a.length; _i++) { 1 > 2 >^^^ 3 > ^ 4 > ^ 5 > ^^^^^^^^^^ 6 > ^^ +7 > ^^^^^^ +8 > ^^^ +9 > ^^ +10> ^^^ +11> ^^ +12> ^^^ +13> ^ +14> ^^ +15> ^^^^^^^^^^^^^^ +16> ^^ +17> ^^^^ +18> ^ 1 > 2 >for 3 > 4 > (var v of 5 > ['a', 'b', 'c'] 6 > +7 > [ +8 > 'a' +9 > , +10> 'b' +11> , +12> 'c' +13> ] +14> +15> var v +16> +17> var v of ['a', 'b', 'c'] +18> ) 1 >Emitted(1, 1) Source(1, 1) + SourceIndex(0) 2 >Emitted(1, 4) Source(1, 4) + SourceIndex(0) 3 >Emitted(1, 5) Source(1, 5) + SourceIndex(0) 4 >Emitted(1, 6) Source(1, 15) + SourceIndex(0) 5 >Emitted(1, 16) Source(1, 30) + SourceIndex(0) 6 >Emitted(1, 18) Source(1, 15) + SourceIndex(0) ---- ->>> 'a', -1 >^^^^ -2 > ^^^ -3 > ^^-> -1 >[ -2 > 'a' -1 >Emitted(2, 5) Source(1, 16) + SourceIndex(0) -2 >Emitted(2, 8) Source(1, 19) + SourceIndex(0) ---- ->>> 'b', -1->^^^^ -2 > ^^^ -3 > ^-> -1->, -2 > 'b' -1->Emitted(3, 5) Source(1, 21) + SourceIndex(0) -2 >Emitted(3, 8) Source(1, 24) + SourceIndex(0) ---- ->>> 'c' -1->^^^^ -2 > ^^^ -3 > ^^^^^^^^^^^^^^^^^^^^-> -1->, -2 > 'c' -1->Emitted(4, 5) Source(1, 26) + SourceIndex(0) -2 >Emitted(4, 8) Source(1, 29) + SourceIndex(0) ---- ->>>]; _i < _a.length; _i++) { -1->^ -2 > ^^ -3 > ^^^^^^^^^^^^^^ -4 > ^^ -5 > ^^^^ -6 > ^ -1->] -2 > -3 > var v -4 > -5 > var v of ['a', 'b', 'c'] -6 > ) -1->Emitted(5, 2) Source(1, 30) + SourceIndex(0) -2 >Emitted(5, 4) Source(1, 6) + SourceIndex(0) -3 >Emitted(5, 18) Source(1, 11) + SourceIndex(0) -4 >Emitted(5, 20) Source(1, 6) + SourceIndex(0) -5 >Emitted(5, 24) Source(1, 30) + SourceIndex(0) -6 >Emitted(5, 25) Source(1, 31) + SourceIndex(0) +7 >Emitted(1, 24) Source(1, 16) + SourceIndex(0) +8 >Emitted(1, 27) Source(1, 19) + SourceIndex(0) +9 >Emitted(1, 29) Source(1, 21) + SourceIndex(0) +10>Emitted(1, 32) Source(1, 24) + SourceIndex(0) +11>Emitted(1, 34) Source(1, 26) + SourceIndex(0) +12>Emitted(1, 37) Source(1, 29) + SourceIndex(0) +13>Emitted(1, 38) Source(1, 30) + SourceIndex(0) +14>Emitted(1, 40) Source(1, 6) + SourceIndex(0) +15>Emitted(1, 54) Source(1, 11) + SourceIndex(0) +16>Emitted(1, 56) Source(1, 6) + SourceIndex(0) +17>Emitted(1, 60) Source(1, 30) + SourceIndex(0) +18>Emitted(1, 61) Source(1, 31) + SourceIndex(0) --- >>> var v = _a[_i]; 1 >^^^^ @@ -84,10 +73,10 @@ sourceFile:ES5For-of3.ts 2 > var 3 > v 4 > -1 >Emitted(6, 5) Source(1, 6) + SourceIndex(0) -2 >Emitted(6, 9) Source(1, 10) + SourceIndex(0) -3 >Emitted(6, 10) Source(1, 11) + SourceIndex(0) -4 >Emitted(6, 19) Source(1, 11) + SourceIndex(0) +1 >Emitted(2, 5) Source(1, 6) + SourceIndex(0) +2 >Emitted(2, 9) Source(1, 10) + SourceIndex(0) +3 >Emitted(2, 10) Source(1, 11) + SourceIndex(0) +4 >Emitted(2, 19) Source(1, 11) + SourceIndex(0) --- >>> var x = v; 1 >^^^^ @@ -103,17 +92,17 @@ sourceFile:ES5For-of3.ts 4 > = 5 > v 6 > ; -1 >Emitted(7, 5) Source(2, 5) + SourceIndex(0) -2 >Emitted(7, 9) Source(2, 9) + SourceIndex(0) -3 >Emitted(7, 10) Source(2, 10) + SourceIndex(0) -4 >Emitted(7, 13) Source(2, 13) + SourceIndex(0) -5 >Emitted(7, 14) Source(2, 14) + SourceIndex(0) -6 >Emitted(7, 15) Source(2, 15) + SourceIndex(0) +1 >Emitted(3, 5) Source(2, 5) + SourceIndex(0) +2 >Emitted(3, 9) Source(2, 9) + SourceIndex(0) +3 >Emitted(3, 10) Source(2, 10) + SourceIndex(0) +4 >Emitted(3, 13) Source(2, 13) + SourceIndex(0) +5 >Emitted(3, 14) Source(2, 14) + SourceIndex(0) +6 >Emitted(3, 15) Source(2, 15) + SourceIndex(0) --- >>>} 1 >^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > -1 >Emitted(8, 2) Source(2, 15) + SourceIndex(0) +1 >Emitted(4, 2) Source(2, 15) + SourceIndex(0) --- >>>//# sourceMappingURL=ES5For-of3.js.map \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of30.js b/tests/baselines/reference/ES5For-of30.js index f76a7938dc..2a1dc5a339 100644 --- a/tests/baselines/reference/ES5For-of30.js +++ b/tests/baselines/reference/ES5For-of30.js @@ -8,10 +8,7 @@ for ([a = 1, b = ""] of tuple) { //// [ES5For-of30.js] var a, b; -var tuple = [ - 2, - "3" -]; +var tuple = [2, "3"]; for (var _i = 0; _i < tuple.length; _i++) { _a = tuple[_i], _b = _a[0], a = _b === void 0 ? 1 : _b, _c = _a[1], b = _c === void 0 ? "" : _c; a; diff --git a/tests/baselines/reference/ES5For-of6.js b/tests/baselines/reference/ES5For-of6.js index ac740814d8..bf966a0a5a 100644 --- a/tests/baselines/reference/ES5For-of6.js +++ b/tests/baselines/reference/ES5For-of6.js @@ -10,9 +10,6 @@ for (var _i = 0, _a = []; _i < _a.length; _i++) { var w = _a[_i]; for (var _b = 0, _c = []; _b < _c.length; _b++) { var v = _c[_b]; - var x = [ - w, - v - ]; + var x = [w, v]; } } diff --git a/tests/baselines/reference/ES5For-of7.js b/tests/baselines/reference/ES5For-of7.js index b88b6c055a..ad2302cdc5 100644 --- a/tests/baselines/reference/ES5For-of7.js +++ b/tests/baselines/reference/ES5For-of7.js @@ -14,8 +14,5 @@ for (var _i = 0, _a = []; _i < _a.length; _i++) { } for (var _b = 0, _c = []; _b < _c.length; _b++) { var v = _c[_b]; - var x = [ - w, - v - ]; + var x = [w, v]; } diff --git a/tests/baselines/reference/ES5For-of8.js b/tests/baselines/reference/ES5For-of8.js index 6bf7dc37d1..dbe747b969 100644 --- a/tests/baselines/reference/ES5For-of8.js +++ b/tests/baselines/reference/ES5For-of8.js @@ -8,15 +8,9 @@ for (foo().x of ['a', 'b', 'c']) { //// [ES5For-of8.js] function foo() { - return { - x: 0 - }; + return { x: 0 }; } -for (var _i = 0, _a = [ - 'a', - 'b', - 'c' -]; _i < _a.length; _i++) { +for (var _i = 0, _a = ['a', 'b', 'c']; _i < _a.length; _i++) { foo().x = _a[_i]; var p = foo().x; } diff --git a/tests/baselines/reference/ES5For-of8.js.map b/tests/baselines/reference/ES5For-of8.js.map index eadf5e8430..be14106e77 100644 --- a/tests/baselines/reference/ES5For-of8.js.map +++ b/tests/baselines/reference/ES5For-of8.js.map @@ -1,2 +1,2 @@ //// [ES5For-of8.js.map] -{"version":3,"file":"ES5For-of8.js","sourceRoot":"","sources":["ES5For-of8.ts"],"names":["foo"],"mappings":"AAAA;IACIA,MAAMA,CAACA;QAAEA,CAACA,EAAEA,CAACA;KAAEA,CAACA;AACpBA,CAACA;AACD,GAAG,CAAC,CAAY,UAAe,EAAf;IAAC,GAAG;IAAE,GAAG;IAAE,GAAG;CAAC,EAA1B,cAAO,EAAP,IAA0B,CAAC;IAA3B,GAAG,EAAE,CAAC,CAAC,SAAA;IACR,IAAI,CAAC,GAAG,GAAG,EAAE,CAAC,CAAC,CAAC;CACnB"} \ No newline at end of file +{"version":3,"file":"ES5For-of8.js","sourceRoot":"","sources":["ES5For-of8.ts"],"names":["foo"],"mappings":"AAAA;IACIA,MAAMA,CAACA,EAAEA,CAACA,EAAEA,CAACA,EAAEA,CAACA;AACpBA,CAACA;AACD,GAAG,CAAC,CAAY,UAAe,EAAf,MAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAA1B,cAAO,EAAP,IAA0B,CAAC;IAA3B,GAAG,EAAE,CAAC,CAAC,SAAA;IACR,IAAI,CAAC,GAAG,GAAG,EAAE,CAAC,CAAC,CAAC;CACnB"} \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of8.sourcemap.txt b/tests/baselines/reference/ES5For-of8.sourcemap.txt index f4b97ebe69..814f4364dc 100644 --- a/tests/baselines/reference/ES5For-of8.sourcemap.txt +++ b/tests/baselines/reference/ES5For-of8.sourcemap.txt @@ -10,62 +10,69 @@ sourceFile:ES5For-of8.ts ------------------------------------------------------------------- >>>function foo() { 1 > -2 >^^^^^^^^^^^^^-> +2 >^^^^^^^^^^^^^^^^^^^^^-> 1 > 1 >Emitted(1, 1) Source(1, 1) + SourceIndex(0) --- ->>> return { +>>> return { x: 0 }; 1->^^^^ 2 > ^^^^^^ 3 > ^ -4 > ^^-> +4 > ^^ +5 > ^ +6 > ^^ +7 > ^ +8 > ^^ +9 > ^ 1->function foo() { > 2 > return 3 > +4 > { +5 > x +6 > : +7 > 0 +8 > } +9 > ; 1->Emitted(2, 5) Source(2, 5) + SourceIndex(0) name (foo) 2 >Emitted(2, 11) Source(2, 11) + SourceIndex(0) name (foo) 3 >Emitted(2, 12) Source(2, 12) + SourceIndex(0) name (foo) ---- ->>> x: 0 -1->^^^^^^^^ -2 > ^ -3 > ^^ -4 > ^ -1->{ -2 > x -3 > : -4 > 0 -1->Emitted(3, 9) Source(2, 14) + SourceIndex(0) name (foo) -2 >Emitted(3, 10) Source(2, 15) + SourceIndex(0) name (foo) -3 >Emitted(3, 12) Source(2, 17) + SourceIndex(0) name (foo) -4 >Emitted(3, 13) Source(2, 18) + SourceIndex(0) name (foo) ---- ->>> }; -1 >^^^^^ -2 > ^ -1 > } -2 > ; -1 >Emitted(4, 6) Source(2, 20) + SourceIndex(0) name (foo) -2 >Emitted(4, 7) Source(2, 21) + SourceIndex(0) name (foo) +4 >Emitted(2, 14) Source(2, 14) + SourceIndex(0) name (foo) +5 >Emitted(2, 15) Source(2, 15) + SourceIndex(0) name (foo) +6 >Emitted(2, 17) Source(2, 17) + SourceIndex(0) name (foo) +7 >Emitted(2, 18) Source(2, 18) + SourceIndex(0) name (foo) +8 >Emitted(2, 20) Source(2, 20) + SourceIndex(0) name (foo) +9 >Emitted(2, 21) Source(2, 21) + SourceIndex(0) name (foo) --- >>>} 1 > 2 >^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > > 2 >} -1 >Emitted(5, 1) Source(3, 1) + SourceIndex(0) name (foo) -2 >Emitted(5, 2) Source(3, 2) + SourceIndex(0) name (foo) +1 >Emitted(3, 1) Source(3, 1) + SourceIndex(0) name (foo) +2 >Emitted(3, 2) Source(3, 2) + SourceIndex(0) name (foo) --- ->>>for (var _i = 0, _a = [ +>>>for (var _i = 0, _a = ['a', 'b', 'c']; _i < _a.length; _i++) { 1-> 2 >^^^ 3 > ^ 4 > ^ 5 > ^^^^^^^^^^ 6 > ^^ +7 > ^^^^^^ +8 > ^^^ +9 > ^^ +10> ^^^ +11> ^^ +12> ^^^ +13> ^ +14> ^^ +15> ^^^^^^^^^^^^^^ +16> ^^ +17> ^^^^ +18> ^ 1-> > 2 >for @@ -73,59 +80,36 @@ sourceFile:ES5For-of8.ts 4 > (foo().x of 5 > ['a', 'b', 'c'] 6 > -1->Emitted(6, 1) Source(4, 1) + SourceIndex(0) -2 >Emitted(6, 4) Source(4, 4) + SourceIndex(0) -3 >Emitted(6, 5) Source(4, 5) + SourceIndex(0) -4 >Emitted(6, 6) Source(4, 17) + SourceIndex(0) -5 >Emitted(6, 16) Source(4, 32) + SourceIndex(0) -6 >Emitted(6, 18) Source(4, 17) + SourceIndex(0) ---- ->>> 'a', -1 >^^^^ -2 > ^^^ -3 > ^^-> -1 >[ -2 > 'a' -1 >Emitted(7, 5) Source(4, 18) + SourceIndex(0) -2 >Emitted(7, 8) Source(4, 21) + SourceIndex(0) ---- ->>> 'b', -1->^^^^ -2 > ^^^ -3 > ^-> -1->, -2 > 'b' -1->Emitted(8, 5) Source(4, 23) + SourceIndex(0) -2 >Emitted(8, 8) Source(4, 26) + SourceIndex(0) ---- ->>> 'c' -1->^^^^ -2 > ^^^ -3 > ^^^^^^^^^^^^^^^^^^^^-> -1->, -2 > 'c' -1->Emitted(9, 5) Source(4, 28) + SourceIndex(0) -2 >Emitted(9, 8) Source(4, 31) + SourceIndex(0) ---- ->>>]; _i < _a.length; _i++) { -1->^ -2 > ^^ -3 > ^^^^^^^^^^^^^^ -4 > ^^ -5 > ^^^^ -6 > ^ -1->] -2 > -3 > foo().x -4 > -5 > foo().x of ['a', 'b', 'c'] -6 > ) -1->Emitted(10, 2) Source(4, 32) + SourceIndex(0) -2 >Emitted(10, 4) Source(4, 6) + SourceIndex(0) -3 >Emitted(10, 18) Source(4, 13) + SourceIndex(0) -4 >Emitted(10, 20) Source(4, 6) + SourceIndex(0) -5 >Emitted(10, 24) Source(4, 32) + SourceIndex(0) -6 >Emitted(10, 25) Source(4, 33) + SourceIndex(0) +7 > [ +8 > 'a' +9 > , +10> 'b' +11> , +12> 'c' +13> ] +14> +15> foo().x +16> +17> foo().x of ['a', 'b', 'c'] +18> ) +1->Emitted(4, 1) Source(4, 1) + SourceIndex(0) +2 >Emitted(4, 4) Source(4, 4) + SourceIndex(0) +3 >Emitted(4, 5) Source(4, 5) + SourceIndex(0) +4 >Emitted(4, 6) Source(4, 17) + SourceIndex(0) +5 >Emitted(4, 16) Source(4, 32) + SourceIndex(0) +6 >Emitted(4, 18) Source(4, 17) + SourceIndex(0) +7 >Emitted(4, 24) Source(4, 18) + SourceIndex(0) +8 >Emitted(4, 27) Source(4, 21) + SourceIndex(0) +9 >Emitted(4, 29) Source(4, 23) + SourceIndex(0) +10>Emitted(4, 32) Source(4, 26) + SourceIndex(0) +11>Emitted(4, 34) Source(4, 28) + SourceIndex(0) +12>Emitted(4, 37) Source(4, 31) + SourceIndex(0) +13>Emitted(4, 38) Source(4, 32) + SourceIndex(0) +14>Emitted(4, 40) Source(4, 6) + SourceIndex(0) +15>Emitted(4, 54) Source(4, 13) + SourceIndex(0) +16>Emitted(4, 56) Source(4, 6) + SourceIndex(0) +17>Emitted(4, 60) Source(4, 32) + SourceIndex(0) +18>Emitted(4, 61) Source(4, 33) + SourceIndex(0) --- >>> foo().x = _a[_i]; 1 >^^^^ @@ -141,12 +125,12 @@ sourceFile:ES5For-of8.ts 4 > . 5 > x 6 > -1 >Emitted(11, 5) Source(4, 6) + SourceIndex(0) -2 >Emitted(11, 8) Source(4, 9) + SourceIndex(0) -3 >Emitted(11, 10) Source(4, 11) + SourceIndex(0) -4 >Emitted(11, 11) Source(4, 12) + SourceIndex(0) -5 >Emitted(11, 12) Source(4, 13) + SourceIndex(0) -6 >Emitted(11, 21) Source(4, 13) + SourceIndex(0) +1 >Emitted(5, 5) Source(4, 6) + SourceIndex(0) +2 >Emitted(5, 8) Source(4, 9) + SourceIndex(0) +3 >Emitted(5, 10) Source(4, 11) + SourceIndex(0) +4 >Emitted(5, 11) Source(4, 12) + SourceIndex(0) +5 >Emitted(5, 12) Source(4, 13) + SourceIndex(0) +6 >Emitted(5, 21) Source(4, 13) + SourceIndex(0) --- >>> var p = foo().x; 1->^^^^ @@ -168,21 +152,21 @@ sourceFile:ES5For-of8.ts 7 > . 8 > x 9 > ; -1->Emitted(12, 5) Source(5, 5) + SourceIndex(0) -2 >Emitted(12, 9) Source(5, 9) + SourceIndex(0) -3 >Emitted(12, 10) Source(5, 10) + SourceIndex(0) -4 >Emitted(12, 13) Source(5, 13) + SourceIndex(0) -5 >Emitted(12, 16) Source(5, 16) + SourceIndex(0) -6 >Emitted(12, 18) Source(5, 18) + SourceIndex(0) -7 >Emitted(12, 19) Source(5, 19) + SourceIndex(0) -8 >Emitted(12, 20) Source(5, 20) + SourceIndex(0) -9 >Emitted(12, 21) Source(5, 21) + SourceIndex(0) +1->Emitted(6, 5) Source(5, 5) + SourceIndex(0) +2 >Emitted(6, 9) Source(5, 9) + SourceIndex(0) +3 >Emitted(6, 10) Source(5, 10) + SourceIndex(0) +4 >Emitted(6, 13) Source(5, 13) + SourceIndex(0) +5 >Emitted(6, 16) Source(5, 16) + SourceIndex(0) +6 >Emitted(6, 18) Source(5, 18) + SourceIndex(0) +7 >Emitted(6, 19) Source(5, 19) + SourceIndex(0) +8 >Emitted(6, 20) Source(5, 20) + SourceIndex(0) +9 >Emitted(6, 21) Source(5, 21) + SourceIndex(0) --- >>>} 1 >^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > >} -1 >Emitted(13, 2) Source(6, 2) + SourceIndex(0) +1 >Emitted(7, 2) Source(6, 2) + SourceIndex(0) --- >>>//# sourceMappingURL=ES5For-of8.js.map \ No newline at end of file diff --git a/tests/baselines/reference/ES5For-of9.js b/tests/baselines/reference/ES5For-of9.js index bef8311886..3a2cd2b1f7 100644 --- a/tests/baselines/reference/ES5For-of9.js +++ b/tests/baselines/reference/ES5For-of9.js @@ -10,9 +10,7 @@ for (foo().x of []) { //// [ES5For-of9.js] function foo() { - return { - x: 0 - }; + return { x: 0 }; } for (var _i = 0, _a = []; _i < _a.length; _i++) { foo().x = _a[_i]; diff --git a/tests/baselines/reference/ES5For-ofTypeCheck2.js b/tests/baselines/reference/ES5For-ofTypeCheck2.js index 2c79054aff..587de4f82f 100644 --- a/tests/baselines/reference/ES5For-ofTypeCheck2.js +++ b/tests/baselines/reference/ES5For-ofTypeCheck2.js @@ -2,8 +2,6 @@ for (var v of [true]) { } //// [ES5For-ofTypeCheck2.js] -for (var _i = 0, _a = [ - true -]; _i < _a.length; _i++) { +for (var _i = 0, _a = [true]; _i < _a.length; _i++) { var v = _a[_i]; } diff --git a/tests/baselines/reference/ES5For-ofTypeCheck3.js b/tests/baselines/reference/ES5For-ofTypeCheck3.js index b398f04e0c..76d8237997 100644 --- a/tests/baselines/reference/ES5For-ofTypeCheck3.js +++ b/tests/baselines/reference/ES5For-ofTypeCheck3.js @@ -3,10 +3,7 @@ var tuple: [string, number] = ["", 0]; for (var v of tuple) { } //// [ES5For-ofTypeCheck3.js] -var tuple = [ - "", - 0 -]; +var tuple = ["", 0]; for (var _i = 0; _i < tuple.length; _i++) { var v = tuple[_i]; } diff --git a/tests/baselines/reference/ES5SymbolProperty2.js b/tests/baselines/reference/ES5SymbolProperty2.js index a1efd6ae7b..effd1e610f 100644 --- a/tests/baselines/reference/ES5SymbolProperty2.js +++ b/tests/baselines/reference/ES5SymbolProperty2.js @@ -17,8 +17,7 @@ var M; var C = (function () { function C() { } - C.prototype[Symbol.iterator] = function () { - }; + C.prototype[Symbol.iterator] = function () { }; return C; })(); M.C = C; diff --git a/tests/baselines/reference/ES5SymbolProperty3.js b/tests/baselines/reference/ES5SymbolProperty3.js index 7ef892cb3c..52ea7e091e 100644 --- a/tests/baselines/reference/ES5SymbolProperty3.js +++ b/tests/baselines/reference/ES5SymbolProperty3.js @@ -12,8 +12,7 @@ var Symbol; var C = (function () { function C() { } - C.prototype[Symbol.iterator] = function () { - }; + C.prototype[Symbol.iterator] = function () { }; return C; })(); (new C)[Symbol.iterator]; diff --git a/tests/baselines/reference/ES5SymbolProperty4.js b/tests/baselines/reference/ES5SymbolProperty4.js index d4022066bb..ae8a539f35 100644 --- a/tests/baselines/reference/ES5SymbolProperty4.js +++ b/tests/baselines/reference/ES5SymbolProperty4.js @@ -12,8 +12,7 @@ var Symbol; var C = (function () { function C() { } - C.prototype[Symbol.iterator] = function () { - }; + C.prototype[Symbol.iterator] = function () { }; return C; })(); (new C)[Symbol.iterator]; diff --git a/tests/baselines/reference/ES5SymbolProperty5.js b/tests/baselines/reference/ES5SymbolProperty5.js index c433b0ab44..63b12667d0 100644 --- a/tests/baselines/reference/ES5SymbolProperty5.js +++ b/tests/baselines/reference/ES5SymbolProperty5.js @@ -12,8 +12,7 @@ var Symbol; var C = (function () { function C() { } - C.prototype[Symbol.iterator] = function () { - }; + C.prototype[Symbol.iterator] = function () { }; return C; })(); (new C)[Symbol.iterator](0); // Should error diff --git a/tests/baselines/reference/ES5SymbolProperty6.js b/tests/baselines/reference/ES5SymbolProperty6.js index 949ce722aa..10eda091e5 100644 --- a/tests/baselines/reference/ES5SymbolProperty6.js +++ b/tests/baselines/reference/ES5SymbolProperty6.js @@ -9,8 +9,7 @@ class C { var C = (function () { function C() { } - C.prototype[Symbol.iterator] = function () { - }; + C.prototype[Symbol.iterator] = function () { }; return C; })(); (new C)[Symbol.iterator]; diff --git a/tests/baselines/reference/ES5SymbolProperty7.js b/tests/baselines/reference/ES5SymbolProperty7.js index f98e792e8c..d3f796ce75 100644 --- a/tests/baselines/reference/ES5SymbolProperty7.js +++ b/tests/baselines/reference/ES5SymbolProperty7.js @@ -12,8 +12,7 @@ var Symbol; var C = (function () { function C() { } - C.prototype[Symbol.iterator] = function () { - }; + C.prototype[Symbol.iterator] = function () { }; return C; })(); (new C)[Symbol.iterator]; diff --git a/tests/baselines/reference/ExportClassWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js b/tests/baselines/reference/ExportClassWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js index 8fa0469149..bfa243937d 100644 --- a/tests/baselines/reference/ExportClassWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js +++ b/tests/baselines/reference/ExportClassWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js @@ -35,10 +35,7 @@ var A; return Point; })(); A.Point = Point; - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; var Point3d = (function (_super) { __extends(Point3d, _super); function Point3d() { @@ -47,11 +44,7 @@ var A; return Point3d; })(Point); A.Point3d = Point3d; - A.Origin3d = { - x: 0, - y: 0, - z: 0 - }; + A.Origin3d = { x: 0, y: 0, z: 0 }; var Line = (function () { function Line(start, end) { this.start = start; diff --git a/tests/baselines/reference/ExportClassWithInaccessibleTypeInTypeParameterConstraint.js b/tests/baselines/reference/ExportClassWithInaccessibleTypeInTypeParameterConstraint.js index 9c7e3d5db2..71a43788c5 100644 --- a/tests/baselines/reference/ExportClassWithInaccessibleTypeInTypeParameterConstraint.js +++ b/tests/baselines/reference/ExportClassWithInaccessibleTypeInTypeParameterConstraint.js @@ -38,10 +38,7 @@ var A; } return Point; })(); - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; var Point3d = (function (_super) { __extends(Point3d, _super); function Point3d() { @@ -50,11 +47,7 @@ var A; return Point3d; })(Point); A.Point3d = Point3d; - A.Origin3d = { - x: 0, - y: 0, - z: 0 - }; + A.Origin3d = { x: 0, y: 0, z: 0 }; var Line = (function () { function Line(start, end) { this.start = start; diff --git a/tests/baselines/reference/ExportFunctionWithAccessibleTypesInParameterAndReturnTypeAnnotation.js b/tests/baselines/reference/ExportFunctionWithAccessibleTypesInParameterAndReturnTypeAnnotation.js index 56f50afa97..21d969d242 100644 --- a/tests/baselines/reference/ExportFunctionWithAccessibleTypesInParameterAndReturnTypeAnnotation.js +++ b/tests/baselines/reference/ExportFunctionWithAccessibleTypesInParameterAndReturnTypeAnnotation.js @@ -33,10 +33,7 @@ var A; })(); A.Line = Line; function fromOrigin(p) { - return new Line({ - x: 0, - y: 0 - }, p); + return new Line({ x: 0, y: 0 }, p); } A.fromOrigin = fromOrigin; })(A || (A = {})); diff --git a/tests/baselines/reference/ExportFunctionWithInaccessibleTypesInParameterTypeAnnotation.js b/tests/baselines/reference/ExportFunctionWithInaccessibleTypesInParameterTypeAnnotation.js index d669ce248d..99831f1062 100644 --- a/tests/baselines/reference/ExportFunctionWithInaccessibleTypesInParameterTypeAnnotation.js +++ b/tests/baselines/reference/ExportFunctionWithInaccessibleTypesInParameterTypeAnnotation.js @@ -32,10 +32,7 @@ var A; })(); A.Line = Line; function fromOrigin(p) { - return new Line({ - x: 0, - y: 0 - }, p); + return new Line({ x: 0, y: 0 }, p); } A.fromOrigin = fromOrigin; })(A || (A = {})); diff --git a/tests/baselines/reference/ExportFunctionWithInaccessibleTypesInReturnTypeAnnotation.js b/tests/baselines/reference/ExportFunctionWithInaccessibleTypesInReturnTypeAnnotation.js index a7ad139f68..3037e33d88 100644 --- a/tests/baselines/reference/ExportFunctionWithInaccessibleTypesInReturnTypeAnnotation.js +++ b/tests/baselines/reference/ExportFunctionWithInaccessibleTypesInReturnTypeAnnotation.js @@ -32,10 +32,7 @@ var A; return Line; })(); function fromOrigin(p) { - return new Line({ - x: 0, - y: 0 - }, p); + return new Line({ x: 0, y: 0 }, p); } A.fromOrigin = fromOrigin; })(A || (A = {})); diff --git a/tests/baselines/reference/ExportInterfaceWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js b/tests/baselines/reference/ExportInterfaceWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js index a5ce37fb36..e2b32a3bca 100644 --- a/tests/baselines/reference/ExportInterfaceWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js +++ b/tests/baselines/reference/ExportInterfaceWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js @@ -25,13 +25,6 @@ module A { //// [ExportInterfaceWithAccessibleTypesInTypeParameterConstraintsClassHeritageListMemberTypeAnnotations.js] var A; (function (A) { - A.Origin = { - x: 0, - y: 0 - }; - A.Origin3d = { - x: 0, - y: 0, - z: 0 - }; + A.Origin = { x: 0, y: 0 }; + A.Origin3d = { x: 0, y: 0, z: 0 }; })(A || (A = {})); diff --git a/tests/baselines/reference/ExportInterfaceWithInaccessibleTypeInTypeParameterConstraint.js b/tests/baselines/reference/ExportInterfaceWithInaccessibleTypeInTypeParameterConstraint.js index 77db9879e3..7625500a1d 100644 --- a/tests/baselines/reference/ExportInterfaceWithInaccessibleTypeInTypeParameterConstraint.js +++ b/tests/baselines/reference/ExportInterfaceWithInaccessibleTypeInTypeParameterConstraint.js @@ -26,13 +26,6 @@ module A { //// [ExportInterfaceWithInaccessibleTypeInTypeParameterConstraint.js] var A; (function (A) { - A.Origin = { - x: 0, - y: 0 - }; - A.Origin3d = { - x: 0, - y: 0, - z: 0 - }; + A.Origin = { x: 0, y: 0 }; + A.Origin3d = { x: 0, y: 0, z: 0 }; })(A || (A = {})); diff --git a/tests/baselines/reference/ExportModuleWithAccessibleTypesOnItsExportedMembers.js b/tests/baselines/reference/ExportModuleWithAccessibleTypesOnItsExportedMembers.js index c2c4b64ece..df6645df3b 100644 --- a/tests/baselines/reference/ExportModuleWithAccessibleTypesOnItsExportedMembers.js +++ b/tests/baselines/reference/ExportModuleWithAccessibleTypesOnItsExportedMembers.js @@ -38,10 +38,7 @@ var A; function Line(start, end) { } Line.fromOrigin = function (p) { - return new Line({ - x: 0, - y: 0 - }, p); + return new Line({ x: 0, y: 0 }, p); }; return Line; })(); diff --git a/tests/baselines/reference/ExportObjectLiteralAndObjectTypeLiteralWithAccessibleTypesInMemberTypeAnnotations.js b/tests/baselines/reference/ExportObjectLiteralAndObjectTypeLiteralWithAccessibleTypesInMemberTypeAnnotations.js index 50da60f711..46361dd41b 100644 --- a/tests/baselines/reference/ExportObjectLiteralAndObjectTypeLiteralWithAccessibleTypesInMemberTypeAnnotations.js +++ b/tests/baselines/reference/ExportObjectLiteralAndObjectTypeLiteralWithAccessibleTypesInMemberTypeAnnotations.js @@ -21,12 +21,6 @@ var A; } return Point; })(); - A.Origin = { - x: 0, - y: 0 - }; - A.Unity = { - start: new Point(0, 0), - end: new Point(1, 0) - }; + A.Origin = { x: 0, y: 0 }; + A.Unity = { start: new Point(0, 0), end: new Point(1, 0) }; })(A || (A = {})); diff --git a/tests/baselines/reference/ExportVariableWithAccessibleTypeInTypeAnnotation.js b/tests/baselines/reference/ExportVariableWithAccessibleTypeInTypeAnnotation.js index a4d203cc36..591845b627 100644 --- a/tests/baselines/reference/ExportVariableWithAccessibleTypeInTypeAnnotation.js +++ b/tests/baselines/reference/ExportVariableWithAccessibleTypeInTypeAnnotation.js @@ -15,8 +15,5 @@ module A { var A; (function (A) { // valid since Point is exported - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; })(A || (A = {})); diff --git a/tests/baselines/reference/ExportVariableWithInaccessibleTypeInTypeAnnotation.js b/tests/baselines/reference/ExportVariableWithInaccessibleTypeInTypeAnnotation.js index de0b6e706a..d63edb6556 100644 --- a/tests/baselines/reference/ExportVariableWithInaccessibleTypeInTypeAnnotation.js +++ b/tests/baselines/reference/ExportVariableWithInaccessibleTypeInTypeAnnotation.js @@ -22,14 +22,7 @@ module A { var A; (function (A) { // valid since Point is exported - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; // invalid Point3d is not exported - A.Origin3d = { - x: 0, - y: 0, - z: 0 - }; + A.Origin3d = { x: 0, y: 0, z: 0 }; })(A || (A = {})); diff --git a/tests/baselines/reference/FunctionAndModuleWithSameNameAndCommonRoot.js b/tests/baselines/reference/FunctionAndModuleWithSameNameAndCommonRoot.js index 26b2b17de3..369a5b4dd5 100644 --- a/tests/baselines/reference/FunctionAndModuleWithSameNameAndCommonRoot.js +++ b/tests/baselines/reference/FunctionAndModuleWithSameNameAndCommonRoot.js @@ -47,10 +47,7 @@ var cl = B.Point.Origin; var A; (function (A) { function Point() { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; } A.Point = Point; })(A || (A = {})); @@ -59,10 +56,7 @@ var A; (function (A) { var Point; (function (Point) { - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; })(Point = A.Point || (A.Point = {})); })(A || (A = {})); //// [test.js] @@ -75,18 +69,12 @@ var cl = A.Point.Origin; // not expected to be an error. var B; (function (B) { function Point() { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; } B.Point = Point; var Point; (function (Point) { - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; })(Point = B.Point || (B.Point = {})); })(B || (B = {})); var fn; diff --git a/tests/baselines/reference/FunctionAndModuleWithSameNameAndDifferentCommonRoot.js b/tests/baselines/reference/FunctionAndModuleWithSameNameAndDifferentCommonRoot.js index 8c84896b92..13302ea391 100644 --- a/tests/baselines/reference/FunctionAndModuleWithSameNameAndDifferentCommonRoot.js +++ b/tests/baselines/reference/FunctionAndModuleWithSameNameAndDifferentCommonRoot.js @@ -26,10 +26,7 @@ var cl = B.Point.Origin; var A; (function (A) { function Point() { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; } A.Point = Point; })(A || (A = {})); @@ -38,10 +35,7 @@ var B; (function (B) { var Point; (function (Point) { - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; })(Point = B.Point || (B.Point = {})); })(B || (B = {})); //// [test.js] diff --git a/tests/baselines/reference/FunctionDeclaration10_es6.js b/tests/baselines/reference/FunctionDeclaration10_es6.js index 96d3220056..5169453396 100644 --- a/tests/baselines/reference/FunctionDeclaration10_es6.js +++ b/tests/baselines/reference/FunctionDeclaration10_es6.js @@ -4,7 +4,5 @@ function * foo(a = yield => yield) { //// [FunctionDeclaration10_es6.js] function foo(a) { - if (a === void 0) { a = function (yield) { - return yield; - }; } + if (a === void 0) { a = function (yield) { return yield; }; } } diff --git a/tests/baselines/reference/FunctionDeclaration12_es6.js b/tests/baselines/reference/FunctionDeclaration12_es6.js index da9cea3f9c..d9c1739cb4 100644 --- a/tests/baselines/reference/FunctionDeclaration12_es6.js +++ b/tests/baselines/reference/FunctionDeclaration12_es6.js @@ -2,5 +2,4 @@ var v = function * yield() { } //// [FunctionDeclaration12_es6.js] -var v = , yield = function () { -}; +var v = , yield = function () { }; diff --git a/tests/baselines/reference/FunctionDeclaration4.js b/tests/baselines/reference/FunctionDeclaration4.js index 53e040b28f..b50970965f 100644 --- a/tests/baselines/reference/FunctionDeclaration4.js +++ b/tests/baselines/reference/FunctionDeclaration4.js @@ -3,5 +3,4 @@ function foo(); function bar() { } //// [FunctionDeclaration4.js] -function bar() { -} +function bar() { } diff --git a/tests/baselines/reference/FunctionDeclaration6.js b/tests/baselines/reference/FunctionDeclaration6.js index 093fac7ed7..721d4d80b6 100644 --- a/tests/baselines/reference/FunctionDeclaration6.js +++ b/tests/baselines/reference/FunctionDeclaration6.js @@ -6,6 +6,5 @@ //// [FunctionDeclaration6.js] { - function bar() { - } + function bar() { } } diff --git a/tests/baselines/reference/FunctionExpression1_es6.js b/tests/baselines/reference/FunctionExpression1_es6.js index 7c8d82f4ca..97e5d28887 100644 --- a/tests/baselines/reference/FunctionExpression1_es6.js +++ b/tests/baselines/reference/FunctionExpression1_es6.js @@ -2,5 +2,4 @@ var v = function * () { } //// [FunctionExpression1_es6.js] -var v = function () { -}; +var v = function () { }; diff --git a/tests/baselines/reference/FunctionExpression2_es6.js b/tests/baselines/reference/FunctionExpression2_es6.js index 0a2468bcb8..87960e3712 100644 --- a/tests/baselines/reference/FunctionExpression2_es6.js +++ b/tests/baselines/reference/FunctionExpression2_es6.js @@ -2,5 +2,4 @@ var v = function * foo() { } //// [FunctionExpression2_es6.js] -var v = function foo() { -}; +var v = function foo() { }; diff --git a/tests/baselines/reference/FunctionPropertyAssignments1_es6.js b/tests/baselines/reference/FunctionPropertyAssignments1_es6.js index 49c2605e17..0176b41271 100644 --- a/tests/baselines/reference/FunctionPropertyAssignments1_es6.js +++ b/tests/baselines/reference/FunctionPropertyAssignments1_es6.js @@ -2,7 +2,4 @@ var v = { *foo() { } } //// [FunctionPropertyAssignments1_es6.js] -var v = { - foo: function () { - } -}; +var v = { foo: function () { } }; diff --git a/tests/baselines/reference/FunctionPropertyAssignments2_es6.js b/tests/baselines/reference/FunctionPropertyAssignments2_es6.js index 996bd08af0..fc86a6a48d 100644 --- a/tests/baselines/reference/FunctionPropertyAssignments2_es6.js +++ b/tests/baselines/reference/FunctionPropertyAssignments2_es6.js @@ -2,7 +2,4 @@ var v = { *() { } } //// [FunctionPropertyAssignments2_es6.js] -var v = { - : function () { - } -}; +var v = { : function () { } }; diff --git a/tests/baselines/reference/FunctionPropertyAssignments3_es6.js b/tests/baselines/reference/FunctionPropertyAssignments3_es6.js index 64edd61828..89963edbc6 100644 --- a/tests/baselines/reference/FunctionPropertyAssignments3_es6.js +++ b/tests/baselines/reference/FunctionPropertyAssignments3_es6.js @@ -2,7 +2,4 @@ var v = { *{ } } //// [FunctionPropertyAssignments3_es6.js] -var v = { - : function () { - } -}; +var v = { : function () { } }; diff --git a/tests/baselines/reference/FunctionPropertyAssignments4_es6.js b/tests/baselines/reference/FunctionPropertyAssignments4_es6.js index ee6e35defe..7107652341 100644 --- a/tests/baselines/reference/FunctionPropertyAssignments4_es6.js +++ b/tests/baselines/reference/FunctionPropertyAssignments4_es6.js @@ -2,6 +2,4 @@ var v = { * } //// [FunctionPropertyAssignments4_es6.js] -var v = { - : function () { } -}; +var v = { : function () { } }; diff --git a/tests/baselines/reference/FunctionPropertyAssignments5_es6.js b/tests/baselines/reference/FunctionPropertyAssignments5_es6.js index f41bd0d3ff..51e5d0000e 100644 --- a/tests/baselines/reference/FunctionPropertyAssignments5_es6.js +++ b/tests/baselines/reference/FunctionPropertyAssignments5_es6.js @@ -3,7 +3,6 @@ var v = { *[foo()]() { } } //// [FunctionPropertyAssignments5_es6.js] var v = (_a = {}, - _a[foo()] = function () { - }, + _a[foo()] = function () { }, _a); var _a; diff --git a/tests/baselines/reference/FunctionPropertyAssignments6_es6.js b/tests/baselines/reference/FunctionPropertyAssignments6_es6.js index f7e9576c7a..60f3677f10 100644 --- a/tests/baselines/reference/FunctionPropertyAssignments6_es6.js +++ b/tests/baselines/reference/FunctionPropertyAssignments6_es6.js @@ -2,7 +2,4 @@ var v = { *() { } } //// [FunctionPropertyAssignments6_es6.js] -var v = { - : function () { - } -}; +var v = { : function () { } }; diff --git a/tests/baselines/reference/MemberAccessorDeclaration15.js b/tests/baselines/reference/MemberAccessorDeclaration15.js index 41ed265a87..85bbfa6223 100644 --- a/tests/baselines/reference/MemberAccessorDeclaration15.js +++ b/tests/baselines/reference/MemberAccessorDeclaration15.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/MemberFunctionDeclaration1_es6.js b/tests/baselines/reference/MemberFunctionDeclaration1_es6.js index 86e7c9d418..121376d526 100644 --- a/tests/baselines/reference/MemberFunctionDeclaration1_es6.js +++ b/tests/baselines/reference/MemberFunctionDeclaration1_es6.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/MemberFunctionDeclaration2_es6.js b/tests/baselines/reference/MemberFunctionDeclaration2_es6.js index efd60844dc..dcb494b3d1 100644 --- a/tests/baselines/reference/MemberFunctionDeclaration2_es6.js +++ b/tests/baselines/reference/MemberFunctionDeclaration2_es6.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/MemberFunctionDeclaration3_es6.js b/tests/baselines/reference/MemberFunctionDeclaration3_es6.js index 357f9175b4..e858ab1558 100644 --- a/tests/baselines/reference/MemberFunctionDeclaration3_es6.js +++ b/tests/baselines/reference/MemberFunctionDeclaration3_es6.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype[foo] = function () { - }; + C.prototype[foo] = function () { }; return C; })(); diff --git a/tests/baselines/reference/MemberFunctionDeclaration4_es6.js b/tests/baselines/reference/MemberFunctionDeclaration4_es6.js index 9c6d76bfca..26b0868144 100644 --- a/tests/baselines/reference/MemberFunctionDeclaration4_es6.js +++ b/tests/baselines/reference/MemberFunctionDeclaration4_es6.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype. = function () { - }; + C.prototype. = function () { }; return C; })(); diff --git a/tests/baselines/reference/MemberFunctionDeclaration7_es6.js b/tests/baselines/reference/MemberFunctionDeclaration7_es6.js index 211713c6e1..8f942d87f9 100644 --- a/tests/baselines/reference/MemberFunctionDeclaration7_es6.js +++ b/tests/baselines/reference/MemberFunctionDeclaration7_es6.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/ModuleAndFunctionWithSameNameAndCommonRoot.js b/tests/baselines/reference/ModuleAndFunctionWithSameNameAndCommonRoot.js index 6b110cbb0f..e9b8f44f89 100644 --- a/tests/baselines/reference/ModuleAndFunctionWithSameNameAndCommonRoot.js +++ b/tests/baselines/reference/ModuleAndFunctionWithSameNameAndCommonRoot.js @@ -34,10 +34,7 @@ var A; (function (A) { var Point; (function (Point) { - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; })(Point = A.Point || (A.Point = {})); })(A || (A = {})); //// [function.js] @@ -45,10 +42,7 @@ var A; (function (A) { // duplicate identifier error function Point() { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; } A.Point = Point; })(A || (A = {})); @@ -57,17 +51,11 @@ var B; (function (B) { var Point; (function (Point) { - Point.Origin = { - x: 0, - y: 0 - }; + Point.Origin = { x: 0, y: 0 }; })(Point = B.Point || (B.Point = {})); // duplicate identifier error function Point() { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; } B.Point = Point; })(B || (B = {})); diff --git a/tests/baselines/reference/ModuleWithExportedAndNonExportedImportAlias.js b/tests/baselines/reference/ModuleWithExportedAndNonExportedImportAlias.js index 0211c85af9..e31ca5d588 100644 --- a/tests/baselines/reference/ModuleWithExportedAndNonExportedImportAlias.js +++ b/tests/baselines/reference/ModuleWithExportedAndNonExportedImportAlias.js @@ -54,15 +54,9 @@ var B; var Geometry; (function (Geometry) { var Lines = B; - Geometry.Origin = { - x: 0, - y: 0 - }; + Geometry.Origin = { x: 0, y: 0 }; // this is valid since B.Line _is_ visible outside Geometry - Geometry.Unit = new Lines.Line(Geometry.Origin, { - x: 1, - y: 0 - }); + Geometry.Unit = new Lines.Line(Geometry.Origin, { x: 1, y: 0 }); })(Geometry || (Geometry = {})); // expected to work since all are exported var p; diff --git a/tests/baselines/reference/Protected4.js b/tests/baselines/reference/Protected4.js index 665a182ef3..9c23a1be88 100644 --- a/tests/baselines/reference/Protected4.js +++ b/tests/baselines/reference/Protected4.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.m = function () { - }; + C.prototype.m = function () { }; return C; })(); diff --git a/tests/baselines/reference/Protected5.js b/tests/baselines/reference/Protected5.js index 8834cc488c..8426a8765d 100644 --- a/tests/baselines/reference/Protected5.js +++ b/tests/baselines/reference/Protected5.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.m = function () { - }; + C.m = function () { }; return C; })(); diff --git a/tests/baselines/reference/Protected6.js b/tests/baselines/reference/Protected6.js index 004f30b27f..10b5955173 100644 --- a/tests/baselines/reference/Protected6.js +++ b/tests/baselines/reference/Protected6.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.m = function () { - }; + C.m = function () { }; return C; })(); diff --git a/tests/baselines/reference/Protected7.js b/tests/baselines/reference/Protected7.js index 466f6909d6..16c24edb8c 100644 --- a/tests/baselines/reference/Protected7.js +++ b/tests/baselines/reference/Protected7.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.m = function () { - }; + C.prototype.m = function () { }; return C; })(); diff --git a/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedAndNonExportedClassesOfTheSameName.js b/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedAndNonExportedClassesOfTheSameName.js index 52810fa017..deb2f3aa59 100644 --- a/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedAndNonExportedClassesOfTheSameName.js +++ b/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedAndNonExportedClassesOfTheSameName.js @@ -56,10 +56,7 @@ var A; function Point() { } Point.prototype.fromCarthesian = function (p) { - return { - x: p.x, - y: p.y - }; + return { x: p.x, y: p.y }; }; return Point; })(); diff --git a/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedAndNonExportedLocalVarsOfTheSameName.js b/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedAndNonExportedLocalVarsOfTheSameName.js index 227b28f44d..125a803ff3 100644 --- a/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedAndNonExportedLocalVarsOfTheSameName.js +++ b/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedAndNonExportedLocalVarsOfTheSameName.js @@ -47,17 +47,11 @@ var A; var Utils; (function (Utils) { function mirror(p) { - return { - x: p.y, - y: p.x - }; + return { x: p.y, y: p.x }; } Utils.mirror = mirror; })(Utils = A.Utils || (A.Utils = {})); - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; })(A || (A = {})); //// [part2.js] var A; @@ -84,7 +78,4 @@ var o = A.Origin; var o = A.Utils.mirror(o); var p; var p; -var p = new A.Utils.Plane(o, { - x: 1, - y: 1 -}); +var p = new A.Utils.Plane(o, { x: 1, y: 1 }); diff --git a/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedLocalVarsOfTheSameName.js b/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedLocalVarsOfTheSameName.js index 3f5f3bd898..c7f55d0a2d 100644 --- a/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedLocalVarsOfTheSameName.js +++ b/tests/baselines/reference/TwoInternalModulesThatMergeEachWithExportedLocalVarsOfTheSameName.js @@ -35,26 +35,17 @@ var A; var Utils; (function (Utils) { function mirror(p) { - return { - x: p.y, - y: p.x - }; + return { x: p.y, y: p.x }; } Utils.mirror = mirror; })(Utils = A.Utils || (A.Utils = {})); - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; })(A = exports.A || (exports.A = {})); //// [part2.js] var A; (function (A) { // collision with 'Origin' var in other part of merged module - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; var Utils; (function (Utils) { var Plane = (function () { diff --git a/tests/baselines/reference/TwoInternalModulesWithTheSameNameAndDifferentCommonRoot.js b/tests/baselines/reference/TwoInternalModulesWithTheSameNameAndDifferentCommonRoot.js index 32b5ed538d..a854dff15c 100644 --- a/tests/baselines/reference/TwoInternalModulesWithTheSameNameAndDifferentCommonRoot.js +++ b/tests/baselines/reference/TwoInternalModulesWithTheSameNameAndDifferentCommonRoot.js @@ -38,10 +38,7 @@ var Root; var Utils; (function (Utils) { function mirror(p) { - return { - x: p.y, - y: p.x - }; + return { x: p.y, y: p.x }; } Utils.mirror = mirror; })(Utils = A.Utils || (A.Utils = {})); @@ -53,10 +50,7 @@ var otherRoot; var A; (function (A) { // have to be fully qualified since in different root - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; var Utils; (function (Utils) { var Plane = (function () { diff --git a/tests/baselines/reference/TwoInternalModulesWithTheSameNameAndSameCommonRoot.js b/tests/baselines/reference/TwoInternalModulesWithTheSameNameAndSameCommonRoot.js index ba77d51ef6..82c9afd078 100644 --- a/tests/baselines/reference/TwoInternalModulesWithTheSameNameAndSameCommonRoot.js +++ b/tests/baselines/reference/TwoInternalModulesWithTheSameNameAndSameCommonRoot.js @@ -45,10 +45,7 @@ var A; var Utils; (function (Utils) { function mirror(p) { - return { - x: p.y, - y: p.x - }; + return { x: p.y, y: p.x }; } Utils.mirror = mirror; })(Utils = A.Utils || (A.Utils = {})); @@ -56,10 +53,7 @@ var A; //// [part2.js] var A; (function (A) { - A.Origin = { - x: 0, - y: 0 - }; + A.Origin = { x: 0, y: 0 }; var Utils; (function (Utils) { var Plane = (function () { @@ -80,7 +74,4 @@ var o = A.Origin; var o = A.Utils.mirror(o); var p; var p; -var p = new A.Utils.Plane(o, { - x: 1, - y: 1 -}); +var p = new A.Utils.Plane(o, { x: 1, y: 1 }); diff --git a/tests/baselines/reference/YieldExpression10_es6.js b/tests/baselines/reference/YieldExpression10_es6.js index 345f76fc19..3bae1b645f 100644 --- a/tests/baselines/reference/YieldExpression10_es6.js +++ b/tests/baselines/reference/YieldExpression10_es6.js @@ -6,8 +6,7 @@ var v = { * foo() { //// [YieldExpression10_es6.js] -var v = { - foo: function () { +var v = { foo: function () { ; } }; diff --git a/tests/baselines/reference/YieldExpression13_es6.js b/tests/baselines/reference/YieldExpression13_es6.js index 328fc80dbd..093759e6bd 100644 --- a/tests/baselines/reference/YieldExpression13_es6.js +++ b/tests/baselines/reference/YieldExpression13_es6.js @@ -2,6 +2,4 @@ function* foo() { yield } //// [YieldExpression13_es6.js] -function foo() { - ; -} +function foo() { ; } diff --git a/tests/baselines/reference/YieldExpression17_es6.js b/tests/baselines/reference/YieldExpression17_es6.js index 5ac8093395..cefe4ca28d 100644 --- a/tests/baselines/reference/YieldExpression17_es6.js +++ b/tests/baselines/reference/YieldExpression17_es6.js @@ -2,8 +2,4 @@ var v = { get foo() { yield foo; } } //// [YieldExpression17_es6.js] -var v = { - get foo() { - ; - } -}; +var v = { get foo() { ; } }; diff --git a/tests/baselines/reference/accessibilityModifiers.js b/tests/baselines/reference/accessibilityModifiers.js index 901b3a29c2..ebc801ac13 100644 --- a/tests/baselines/reference/accessibilityModifiers.js +++ b/tests/baselines/reference/accessibilityModifiers.js @@ -50,48 +50,36 @@ class E { var C = (function () { function C() { } - C.privateMethod = function () { - }; + C.privateMethod = function () { }; Object.defineProperty(C, "privateGetter", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C, "privateSetter", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); - C.protectedMethod = function () { - }; + C.protectedMethod = function () { }; Object.defineProperty(C, "protectedGetter", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C, "protectedSetter", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); - C.publicMethod = function () { - }; + C.publicMethod = function () { }; Object.defineProperty(C, "publicGetter", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C, "publicSetter", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); @@ -101,48 +89,36 @@ var C = (function () { var D = (function () { function D() { } - D.privateMethod = function () { - }; + D.privateMethod = function () { }; Object.defineProperty(D, "privateGetter", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(D, "privateSetter", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); - D.protectedMethod = function () { - }; + D.protectedMethod = function () { }; Object.defineProperty(D, "protectedGetter", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(D, "protectedSetter", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); - D.publicMethod = function () { - }; + D.publicMethod = function () { }; Object.defineProperty(D, "publicGetter", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(D, "publicSetter", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); @@ -152,18 +128,14 @@ var D = (function () { var E = (function () { function E() { } - E.prototype.method = function () { - }; + E.prototype.method = function () { }; Object.defineProperty(E.prototype, "getter", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(E.prototype, "setter", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/accessorParameterAccessibilityModifier.js b/tests/baselines/reference/accessorParameterAccessibilityModifier.js index 89a511e6c5..8b5ee6196e 100644 --- a/tests/baselines/reference/accessorParameterAccessibilityModifier.js +++ b/tests/baselines/reference/accessorParameterAccessibilityModifier.js @@ -10,14 +10,12 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "X", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C, "X", { - set: function (v2) { - }, + set: function (v2) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/accessorWithES3.js b/tests/baselines/reference/accessorWithES3.js index 6eba5238a9..1eecaa68d6 100644 --- a/tests/baselines/reference/accessorWithES3.js +++ b/tests/baselines/reference/accessorWithES3.js @@ -47,11 +47,8 @@ var D = (function () { return D; })(); var x = { - get a() { - return 1; - } + get a() { return 1; } }; var y = { - set b(v) { - } + set b(v) { } }; diff --git a/tests/baselines/reference/accessorWithES5.js b/tests/baselines/reference/accessorWithES5.js index 1a3690556e..746703bce5 100644 --- a/tests/baselines/reference/accessorWithES5.js +++ b/tests/baselines/reference/accessorWithES5.js @@ -44,11 +44,8 @@ var D = (function () { return D; })(); var x = { - get a() { - return 1; - } + get a() { return 1; } }; var y = { - set b(v) { - } + set b(v) { } }; diff --git a/tests/baselines/reference/accessorWithoutBody1.js b/tests/baselines/reference/accessorWithoutBody1.js index 8f357b8949..e06e305e16 100644 --- a/tests/baselines/reference/accessorWithoutBody1.js +++ b/tests/baselines/reference/accessorWithoutBody1.js @@ -2,6 +2,4 @@ var v = { get foo() } //// [accessorWithoutBody1.js] -var v = { - get foo() { } -}; +var v = { get foo() { } }; diff --git a/tests/baselines/reference/accessorWithoutBody2.js b/tests/baselines/reference/accessorWithoutBody2.js index d9405daeb9..3b5a821d58 100644 --- a/tests/baselines/reference/accessorWithoutBody2.js +++ b/tests/baselines/reference/accessorWithoutBody2.js @@ -2,6 +2,4 @@ var v = { set foo(a) } //// [accessorWithoutBody2.js] -var v = { - set foo(a) { } -}; +var v = { set foo(a) { } }; diff --git a/tests/baselines/reference/accessorsAreNotContextuallyTyped.js b/tests/baselines/reference/accessorsAreNotContextuallyTyped.js index d8cb761bb9..8c01173a13 100644 --- a/tests/baselines/reference/accessorsAreNotContextuallyTyped.js +++ b/tests/baselines/reference/accessorsAreNotContextuallyTyped.js @@ -20,9 +20,7 @@ var C = (function () { } Object.defineProperty(C.prototype, "x", { get: function () { - return function (x) { - return ""; - }; + return function (x) { return ""; }; }, set: function (v) { }, diff --git a/tests/baselines/reference/accessorsNotAllowedInES3.js b/tests/baselines/reference/accessorsNotAllowedInES3.js index 7dab1283e8..0843a39191 100644 --- a/tests/baselines/reference/accessorsNotAllowedInES3.js +++ b/tests/baselines/reference/accessorsNotAllowedInES3.js @@ -11,16 +11,10 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "x", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); return C; })(); -var y = { - get foo() { - return 3; - } -}; +var y = { get foo() { return 3; } }; diff --git a/tests/baselines/reference/accessors_spec_section-4.5_error-cases.js b/tests/baselines/reference/accessors_spec_section-4.5_error-cases.js index 6a3b3773aa..5e527aef3e 100644 --- a/tests/baselines/reference/accessors_spec_section-4.5_error-cases.js +++ b/tests/baselines/reference/accessors_spec_section-4.5_error-cases.js @@ -18,40 +18,26 @@ var LanguageSpec_section_4_5_error_cases = (function () { function LanguageSpec_section_4_5_error_cases() { } Object.defineProperty(LanguageSpec_section_4_5_error_cases.prototype, "AnnotatedSetter_SetterFirst", { - get: function () { - return ""; - }, - set: function (a) { - }, + get: function () { return ""; }, + set: function (a) { }, enumerable: true, configurable: true }); Object.defineProperty(LanguageSpec_section_4_5_error_cases.prototype, "AnnotatedSetter_SetterLast", { - get: function () { - return ""; - }, - set: function (a) { - }, + get: function () { return ""; }, + set: function (a) { }, enumerable: true, configurable: true }); Object.defineProperty(LanguageSpec_section_4_5_error_cases.prototype, "AnnotatedGetter_GetterFirst", { - get: function () { - return ""; - }, - set: function (aStr) { - aStr = 0; - }, + get: function () { return ""; }, + set: function (aStr) { aStr = 0; }, enumerable: true, configurable: true }); Object.defineProperty(LanguageSpec_section_4_5_error_cases.prototype, "AnnotatedGetter_GetterLast", { - get: function () { - return ""; - }, - set: function (aStr) { - aStr = 0; - }, + get: function () { return ""; }, + set: function (aStr) { aStr = 0; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/accessors_spec_section-4.5_inference.js b/tests/baselines/reference/accessors_spec_section-4.5_inference.js index b140e565b2..9aa7ce2f40 100644 --- a/tests/baselines/reference/accessors_spec_section-4.5_inference.js +++ b/tests/baselines/reference/accessors_spec_section-4.5_inference.js @@ -47,56 +47,38 @@ var LanguageSpec_section_4_5_inference = (function () { function LanguageSpec_section_4_5_inference() { } Object.defineProperty(LanguageSpec_section_4_5_inference.prototype, "InferredGetterFromSetterAnnotation", { - get: function () { - return new B(); - }, - set: function (a) { - }, + get: function () { return new B(); }, + set: function (a) { }, enumerable: true, configurable: true }); Object.defineProperty(LanguageSpec_section_4_5_inference.prototype, "InferredGetterFromSetterAnnotation_GetterFirst", { - get: function () { - return new B(); - }, - set: function (a) { - }, + get: function () { return new B(); }, + set: function (a) { }, enumerable: true, configurable: true }); Object.defineProperty(LanguageSpec_section_4_5_inference.prototype, "InferredFromGetter", { - get: function () { - return new B(); - }, - set: function (a) { - }, + get: function () { return new B(); }, + set: function (a) { }, enumerable: true, configurable: true }); Object.defineProperty(LanguageSpec_section_4_5_inference.prototype, "InferredFromGetter_SetterFirst", { - get: function () { - return new B(); - }, - set: function (a) { - }, + get: function () { return new B(); }, + set: function (a) { }, enumerable: true, configurable: true }); Object.defineProperty(LanguageSpec_section_4_5_inference.prototype, "InferredSetterFromGetterAnnotation", { - get: function () { - return new B(); - }, - set: function (a) { - }, + get: function () { return new B(); }, + set: function (a) { }, enumerable: true, configurable: true }); Object.defineProperty(LanguageSpec_section_4_5_inference.prototype, "InferredSetterFromGetterAnnotation_GetterFirst", { - get: function () { - return new B(); - }, - set: function (a) { - }, + get: function () { return new B(); }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/additionOperatorWithAnyAndEveryType.js b/tests/baselines/reference/additionOperatorWithAnyAndEveryType.js index d68af6c23c..04fb5a143c 100644 --- a/tests/baselines/reference/additionOperatorWithAnyAndEveryType.js +++ b/tests/baselines/reference/additionOperatorWithAnyAndEveryType.js @@ -40,13 +40,11 @@ var r19 = a + { a: '' }; var r20 = a + ((a: string) => { return a }); //// [additionOperatorWithAnyAndEveryType.js] -function foo() { -} +function foo() { } var C = (function () { function C() { } - C.foo = function () { - }; + C.foo = function () { }; return C; })(); var E; @@ -85,9 +83,5 @@ var r15 = a + E.a; var r16 = a + M; var r17 = a + ''; var r18 = a + 123; -var r19 = a + { - a: '' -}; -var r20 = a + (function (a) { - return a; -}); +var r19 = a + { a: '' }; +var r20 = a + (function (a) { return a; }); diff --git a/tests/baselines/reference/additionOperatorWithInvalidOperands.js b/tests/baselines/reference/additionOperatorWithInvalidOperands.js index f2403bc167..a8edb4b187 100644 --- a/tests/baselines/reference/additionOperatorWithInvalidOperands.js +++ b/tests/baselines/reference/additionOperatorWithInvalidOperands.js @@ -41,13 +41,11 @@ var r19 = E.a + C.foo(); var r20 = E.a + M; //// [additionOperatorWithInvalidOperands.js] -function foo() { -} +function foo() { } var C = (function () { function C() { } - C.foo = function () { - }; + C.foo = function () { }; return C; })(); var E; diff --git a/tests/baselines/reference/additionOperatorWithNullValueAndInvalidOperator.js b/tests/baselines/reference/additionOperatorWithNullValueAndInvalidOperator.js index 5ec03e15b6..79d3c0b9b8 100644 --- a/tests/baselines/reference/additionOperatorWithNullValueAndInvalidOperator.js +++ b/tests/baselines/reference/additionOperatorWithNullValueAndInvalidOperator.js @@ -25,9 +25,7 @@ var r11 = null + (() => { }); //// [additionOperatorWithNullValueAndInvalidOperator.js] // If one operand is the null or undefined value, it is treated as having the type of the other operand. -function foo() { - return undefined; -} +function foo() { return undefined; } var a; var b; var c; @@ -42,9 +40,6 @@ var r6 = null + c; // other cases var r7 = null + d; var r8 = null + true; -var r9 = null + { - a: '' -}; +var r9 = null + { a: '' }; var r10 = null + foo(); -var r11 = null + (function () { -}); +var r11 = null + (function () { }); diff --git a/tests/baselines/reference/additionOperatorWithStringAndEveryType.js b/tests/baselines/reference/additionOperatorWithStringAndEveryType.js index 56949533e0..03456020c8 100644 --- a/tests/baselines/reference/additionOperatorWithStringAndEveryType.js +++ b/tests/baselines/reference/additionOperatorWithStringAndEveryType.js @@ -75,7 +75,5 @@ var r15 = x + E; var r16 = x + E.a; var r17 = x + ''; var r18 = x + 0; -var r19 = x + { - a: '' -}; +var r19 = x + { a: '' }; var r20 = x + []; diff --git a/tests/baselines/reference/additionOperatorWithTypeParameter.js b/tests/baselines/reference/additionOperatorWithTypeParameter.js index 23a6b95b14..a568f420a3 100644 --- a/tests/baselines/reference/additionOperatorWithTypeParameter.js +++ b/tests/baselines/reference/additionOperatorWithTypeParameter.js @@ -74,7 +74,6 @@ function foo(t, u) { var r16 = t + undefined; var r17 = t + t; var r18 = t + u; - var r19 = t + (function () { - }); + var r19 = t + (function () { }); var r20 = t + []; } diff --git a/tests/baselines/reference/additionOperatorWithUndefinedValueAndInvalidOperands.js b/tests/baselines/reference/additionOperatorWithUndefinedValueAndInvalidOperands.js index 6bf55f351a..98935db2b8 100644 --- a/tests/baselines/reference/additionOperatorWithUndefinedValueAndInvalidOperands.js +++ b/tests/baselines/reference/additionOperatorWithUndefinedValueAndInvalidOperands.js @@ -25,9 +25,7 @@ var r11 = undefined + (() => { }); //// [additionOperatorWithUndefinedValueAndInvalidOperands.js] // If one operand is the null or undefined value, it is treated as having the type of the other operand. -function foo() { - return undefined; -} +function foo() { return undefined; } var a; var b; var c; @@ -42,9 +40,6 @@ var r6 = undefined + c; // other cases var r7 = undefined + d; var r8 = undefined + true; -var r9 = undefined + { - a: '' -}; +var r9 = undefined + { a: '' }; var r10 = undefined + foo(); -var r11 = undefined + (function () { -}); +var r11 = undefined + (function () { }); diff --git a/tests/baselines/reference/aliasUsageInArray.js b/tests/baselines/reference/aliasUsageInArray.js index 1c7f8381be..5712abf344 100644 --- a/tests/baselines/reference/aliasUsageInArray.js +++ b/tests/baselines/reference/aliasUsageInArray.js @@ -46,9 +46,5 @@ var VisualizationModel = (function (_super) { exports.VisualizationModel = VisualizationModel; //// [aliasUsageInArray_main.js] var moduleA = require("aliasUsageInArray_moduleA"); -var xs = [ - moduleA -]; -var xs2 = [ - moduleA -]; +var xs = [moduleA]; +var xs2 = [moduleA]; diff --git a/tests/baselines/reference/aliasUsageInFunctionExpression.js b/tests/baselines/reference/aliasUsageInFunctionExpression.js index e101cd49ab..661c8fd91e 100644 --- a/tests/baselines/reference/aliasUsageInFunctionExpression.js +++ b/tests/baselines/reference/aliasUsageInFunctionExpression.js @@ -45,9 +45,5 @@ var VisualizationModel = (function (_super) { exports.VisualizationModel = VisualizationModel; //// [aliasUsageInFunctionExpression_main.js] var moduleA = require("aliasUsageInFunctionExpression_moduleA"); -var f = function (x) { - return x; -}; -f = function (x) { - return moduleA; -}; +var f = function (x) { return x; }; +f = function (x) { return moduleA; }; diff --git a/tests/baselines/reference/aliasUsageInGenericFunction.js b/tests/baselines/reference/aliasUsageInGenericFunction.js index fc0cd51be5..1070036ade 100644 --- a/tests/baselines/reference/aliasUsageInGenericFunction.js +++ b/tests/baselines/reference/aliasUsageInGenericFunction.js @@ -52,9 +52,5 @@ var moduleA = require("aliasUsageInGenericFunction_moduleA"); function foo(x) { return x; } -var r = foo({ - a: moduleA -}); -var r2 = foo({ - a: null -}); +var r = foo({ a: moduleA }); +var r2 = foo({ a: null }); diff --git a/tests/baselines/reference/aliasUsageInObjectLiteral.js b/tests/baselines/reference/aliasUsageInObjectLiteral.js index 7e6cc1340e..50ccfaf944 100644 --- a/tests/baselines/reference/aliasUsageInObjectLiteral.js +++ b/tests/baselines/reference/aliasUsageInObjectLiteral.js @@ -46,14 +46,6 @@ var VisualizationModel = (function (_super) { exports.VisualizationModel = VisualizationModel; //// [aliasUsageInObjectLiteral_main.js] var moduleA = require("aliasUsageInObjectLiteral_moduleA"); -var a = { - x: moduleA -}; -var b = { - x: moduleA -}; -var c = { - y: { - z: moduleA - } -}; +var a = { x: moduleA }; +var b = { x: moduleA }; +var c = { y: { z: moduleA } }; diff --git a/tests/baselines/reference/aliasUsageInOrExpression.js b/tests/baselines/reference/aliasUsageInOrExpression.js index 8a29a7f998..07a382ebca 100644 --- a/tests/baselines/reference/aliasUsageInOrExpression.js +++ b/tests/baselines/reference/aliasUsageInOrExpression.js @@ -53,9 +53,5 @@ var i; var d1 = i || moduleA; var d2 = i || moduleA; var d2 = moduleA || i; -var e = null || { - x: moduleA -}; -var f = null ? { - x: moduleA -} : null; +var e = null || { x: moduleA }; +var f = null ? { x: moduleA } : null; diff --git a/tests/baselines/reference/aliasUsedAsNameValue.js b/tests/baselines/reference/aliasUsedAsNameValue.js index 4b6debf4c9..fb90918152 100644 --- a/tests/baselines/reference/aliasUsedAsNameValue.js +++ b/tests/baselines/reference/aliasUsedAsNameValue.js @@ -21,9 +21,7 @@ export var a = function () { //// [aliasUsedAsNameValue_0.js] exports.id; //// [aliasUsedAsNameValue_1.js] -function b(a) { - return null; -} +function b(a) { return null; } exports.b = b; //// [aliasUsedAsNameValue_2.js] /// diff --git a/tests/baselines/reference/ambientClassOverloadForFunction.js b/tests/baselines/reference/ambientClassOverloadForFunction.js index cf3a59a465..402eca6338 100644 --- a/tests/baselines/reference/ambientClassOverloadForFunction.js +++ b/tests/baselines/reference/ambientClassOverloadForFunction.js @@ -5,6 +5,4 @@ function foo() { return null; } //// [ambientClassOverloadForFunction.js] ; -function foo() { - return null; -} +function foo() { return null; } diff --git a/tests/baselines/reference/ambiguousGenericAssertion1.js b/tests/baselines/reference/ambiguousGenericAssertion1.js index 0680438758..8d40873036 100644 --- a/tests/baselines/reference/ambiguousGenericAssertion1.js +++ b/tests/baselines/reference/ambiguousGenericAssertion1.js @@ -6,12 +6,8 @@ var r3 = <(x: T) => T>f; // ambiguous, appears to the parser as a << operatio //// [ambiguousGenericAssertion1.js] -function f(x) { - return null; -} -var r = function (x) { - return x; -}; +function f(x) { return null; } +var r = function (x) { return x; }; var r2 = f; // valid var r3 = << T > (x), T; T > f; // ambiguous, appears to the parser as a << operation diff --git a/tests/baselines/reference/ambiguousOverload.js b/tests/baselines/reference/ambiguousOverload.js index fd373c075a..642f09dca1 100644 --- a/tests/baselines/reference/ambiguousOverload.js +++ b/tests/baselines/reference/ambiguousOverload.js @@ -12,15 +12,11 @@ var x2: string = foof2("s", null); var y2: number = foof2("s", null); //// [ambiguousOverload.js] -function foof(bar) { - return bar; -} +function foof(bar) { return bar; } ; var x = foof("s", null); var y = foof("s", null); -function foof2(bar) { - return bar; -} +function foof2(bar) { return bar; } ; var x2 = foof2("s", null); var y2 = foof2("s", null); diff --git a/tests/baselines/reference/anonterface.js b/tests/baselines/reference/anonterface.js index 59d055b29d..12bfbc4ec9 100644 --- a/tests/baselines/reference/anonterface.js +++ b/tests/baselines/reference/anonterface.js @@ -28,6 +28,4 @@ var M; M.C = C; })(M || (M = {})); var c = new M.C(); -c.m(function (n) { - return "hello: " + n; -}, 18); +c.m(function (n) { return "hello: " + n; }, 18); diff --git a/tests/baselines/reference/anyAssignabilityInInheritance.js b/tests/baselines/reference/anyAssignabilityInInheritance.js index bc9ebb02f4..04e3e91761 100644 --- a/tests/baselines/reference/anyAssignabilityInInheritance.js +++ b/tests/baselines/reference/anyAssignabilityInInheritance.js @@ -118,8 +118,7 @@ var E; E[E["A"] = 0] = "A"; })(E || (E = {})); var r3 = foo3(a); // any -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; diff --git a/tests/baselines/reference/anyAssignableToEveryType2.js b/tests/baselines/reference/anyAssignableToEveryType2.js index 41cedb7321..530d8eb043 100644 --- a/tests/baselines/reference/anyAssignableToEveryType2.js +++ b/tests/baselines/reference/anyAssignableToEveryType2.js @@ -146,8 +146,7 @@ var E; (function (E) { E[E["A"] = 0] = "A"; })(E || (E = {})); -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; diff --git a/tests/baselines/reference/anyDeclare.js b/tests/baselines/reference/anyDeclare.js index a46a252949..8bb2f55eb8 100644 --- a/tests/baselines/reference/anyDeclare.js +++ b/tests/baselines/reference/anyDeclare.js @@ -10,6 +10,5 @@ module myMod { var myMod; (function (myMod) { var myFn; - function myFn() { - } + function myFn() { } })(myMod || (myMod = {})); diff --git a/tests/baselines/reference/anyIdenticalToItself.js b/tests/baselines/reference/anyIdenticalToItself.js index dc221b69aa..b7b9b25e41 100644 --- a/tests/baselines/reference/anyIdenticalToItself.js +++ b/tests/baselines/reference/anyIdenticalToItself.js @@ -13,8 +13,7 @@ class C { } //// [anyIdenticalToItself.js] -function foo(x, y) { -} +function foo(x, y) { } var C = (function () { function C() { } diff --git a/tests/baselines/reference/anyInferenceAnonymousFunctions.js b/tests/baselines/reference/anyInferenceAnonymousFunctions.js index 03e45113b2..df92196599 100644 --- a/tests/baselines/reference/anyInferenceAnonymousFunctions.js +++ b/tests/baselines/reference/anyInferenceAnonymousFunctions.js @@ -25,12 +25,6 @@ paired.reduce(function (a1, a2) { paired.reduce(function (b1, b2) { return b1.concat({}); }, []); -paired.reduce(function (b3, b4) { - return b3.concat({}); -}, []); -paired.map(function (c1) { - return c1.count; -}); -paired.map(function (c2) { - return c2.count; -}); +paired.reduce(function (b3, b4) { return b3.concat({}); }, []); +paired.map(function (c1) { return c1.count; }); +paired.map(function (c2) { return c2.count; }); diff --git a/tests/baselines/reference/arrayAssignmentTest1.js b/tests/baselines/reference/arrayAssignmentTest1.js index aed3d0cdf0..0abfa889be 100644 --- a/tests/baselines/reference/arrayAssignmentTest1.js +++ b/tests/baselines/reference/arrayAssignmentTest1.js @@ -95,12 +95,8 @@ var __extends = this.__extends || function (d, b) { var C1 = (function () { function C1() { } - C1.prototype.IM1 = function () { - return null; - }; - C1.prototype.C1M1 = function () { - return null; - }; + C1.prototype.IM1 = function () { return null; }; + C1.prototype.C1M1 = function () { return null; }; return C1; })(); var C2 = (function (_super) { @@ -108,17 +104,13 @@ var C2 = (function (_super) { function C2() { _super.apply(this, arguments); } - C2.prototype.C2M1 = function () { - return null; - }; + C2.prototype.C2M1 = function () { return null; }; return C2; })(C1); var C3 = (function () { function C3() { } - C3.prototype.CM3M1 = function () { - return 3; - }; + C3.prototype.CM3M1 = function () { return 3; }; return C3; })(); /* @@ -137,12 +129,8 @@ var c1 = new C1(); var i1 = c1; var c2 = new C2(); var c3 = new C3(); -var o1 = { - one: 1 -}; -var f1 = function () { - return new C1(); -}; +var o1 = { one: 1 }; +var f1 = function () { return new C1(); }; var arr_any = []; var arr_i1 = []; var arr_c1 = []; diff --git a/tests/baselines/reference/arrayAssignmentTest2.js b/tests/baselines/reference/arrayAssignmentTest2.js index 0e6a983757..977862866e 100644 --- a/tests/baselines/reference/arrayAssignmentTest2.js +++ b/tests/baselines/reference/arrayAssignmentTest2.js @@ -69,12 +69,8 @@ var __extends = this.__extends || function (d, b) { var C1 = (function () { function C1() { } - C1.prototype.IM1 = function () { - return null; - }; - C1.prototype.C1M1 = function () { - return null; - }; + C1.prototype.IM1 = function () { return null; }; + C1.prototype.C1M1 = function () { return null; }; return C1; })(); var C2 = (function (_super) { @@ -82,17 +78,13 @@ var C2 = (function (_super) { function C2() { _super.apply(this, arguments); } - C2.prototype.C2M1 = function () { - return null; - }; + C2.prototype.C2M1 = function () { return null; }; return C2; })(C1); var C3 = (function () { function C3() { } - C3.prototype.CM3M1 = function () { - return 3; - }; + C3.prototype.CM3M1 = function () { return 3; }; return C3; })(); /* @@ -111,12 +103,8 @@ var c1 = new C1(); var i1 = c1; var c2 = new C2(); var c3 = new C3(); -var o1 = { - one: 1 -}; -var f1 = function () { - return new C1(); -}; +var o1 = { one: 1 }; +var f1 = function () { return new C1(); }; var arr_any = []; var arr_i1 = []; var arr_c1 = []; @@ -130,9 +118,7 @@ arr_c3 = arr_c2_2; // should be an error - is arr_c3 = arr_c1_2; // should be an error - is arr_c3 = arr_i1_2; // should be an error - is arr_any = f1; // should be an error - is -arr_any = function () { - return null; -}; // should be an error - is +arr_any = function () { return null; }; // should be an error - is arr_any = o1; // should be an error - is arr_any = a1; // should be ok - is arr_any = c1; // should be an error - is diff --git a/tests/baselines/reference/arrayAssignmentTest4.js b/tests/baselines/reference/arrayAssignmentTest4.js index 43c7f2f414..c38cdebc06 100644 --- a/tests/baselines/reference/arrayAssignmentTest4.js +++ b/tests/baselines/reference/arrayAssignmentTest4.js @@ -30,9 +30,7 @@ arr_any = c3; // should be an error - is var C3 = (function () { function C3() { } - C3.prototype.CM3M1 = function () { - return 3; - }; + C3.prototype.CM3M1 = function () { return 3; }; return C3; })(); /* @@ -47,11 +45,7 @@ Type 1 of any[]: */ var c3 = new C3(); -var o1 = { - one: 1 -}; +var o1 = { one: 1 }; var arr_any = []; -arr_any = function () { - return null; -}; // should be an error - is +arr_any = function () { return null; }; // should be an error - is arr_any = c3; // should be an error - is diff --git a/tests/baselines/reference/arrayAugment.js b/tests/baselines/reference/arrayAugment.js index fcd2ee6987..20cf510712 100644 --- a/tests/baselines/reference/arrayAugment.js +++ b/tests/baselines/reference/arrayAugment.js @@ -9,8 +9,6 @@ var y: string[][]; // Expect no error here //// [arrayAugment.js] -var x = [ - '' -]; +var x = ['']; var y = x.split(4); var y; // Expect no error here diff --git a/tests/baselines/reference/arrayBestCommonTypes.js b/tests/baselines/reference/arrayBestCommonTypes.js index 29da9f0737..f8e158e5b0 100644 --- a/tests/baselines/reference/arrayBestCommonTypes.js +++ b/tests/baselines/reference/arrayBestCommonTypes.js @@ -141,170 +141,34 @@ var EmptyTypes; return null; }; f.prototype.x = function () { - (this.voidIfAny([ - 4, - 2 - ][0])); - (this.voidIfAny([ - 4, - 2, - undefined - ][0])); - (this.voidIfAny([ - undefined, - 2, - 4 - ][0])); - (this.voidIfAny([ - null, - 2, - 4 - ][0])); - (this.voidIfAny([ - 2, - 4, - null - ][0])); - (this.voidIfAny([ - undefined, - 4, - null - ][0])); - (this.voidIfAny([ - '', - "q" - ][0])); - (this.voidIfAny([ - '', - "q", - undefined - ][0])); - (this.voidIfAny([ - undefined, - "q", - '' - ][0])); - (this.voidIfAny([ - null, - "q", - '' - ][0])); - (this.voidIfAny([ - "q", - '', - null - ][0])); - (this.voidIfAny([ - undefined, - '', - null - ][0])); - (this.voidIfAny([ - [ - 3, - 4 - ], - [ - null - ] - ][0][0])); - var t1 = [ - { - x: 7, - y: new derived() - }, - { - x: 5, - y: new base() - } - ]; - var t2 = [ - { - x: true, - y: new derived() - }, - { - x: false, - y: new base() - } - ]; - var t3 = [ - { - x: undefined, - y: new base() - }, - { - x: '', - y: new derived() - } - ]; + (this.voidIfAny([4, 2][0])); + (this.voidIfAny([4, 2, undefined][0])); + (this.voidIfAny([undefined, 2, 4][0])); + (this.voidIfAny([null, 2, 4][0])); + (this.voidIfAny([2, 4, null][0])); + (this.voidIfAny([undefined, 4, null][0])); + (this.voidIfAny(['', "q"][0])); + (this.voidIfAny(['', "q", undefined][0])); + (this.voidIfAny([undefined, "q", ''][0])); + (this.voidIfAny([null, "q", ''][0])); + (this.voidIfAny(["q", '', null][0])); + (this.voidIfAny([undefined, '', null][0])); + (this.voidIfAny([[3, 4], [null]][0][0])); + var t1 = [{ x: 7, y: new derived() }, { x: 5, y: new base() }]; + var t2 = [{ x: true, y: new derived() }, { x: false, y: new base() }]; + var t3 = [{ x: undefined, y: new base() }, { x: '', y: new derived() }]; var anyObj = null; // Order matters here so test all the variants - var a1 = [ - { - x: 0, - y: 'a' - }, - { - x: 'a', - y: 'a' - }, - { - x: anyObj, - y: 'a' - } - ]; - var a2 = [ - { - x: anyObj, - y: 'a' - }, - { - x: 0, - y: 'a' - }, - { - x: 'a', - y: 'a' - } - ]; - var a3 = [ - { - x: 0, - y: 'a' - }, - { - x: anyObj, - y: 'a' - }, - { - x: 'a', - y: 'a' - } - ]; + var a1 = [{ x: 0, y: 'a' }, { x: 'a', y: 'a' }, { x: anyObj, y: 'a' }]; + var a2 = [{ x: anyObj, y: 'a' }, { x: 0, y: 'a' }, { x: 'a', y: 'a' }]; + var a3 = [{ x: 0, y: 'a' }, { x: anyObj, y: 'a' }, { x: 'a', y: 'a' }]; var ifaceObj = null; var baseObj = new base(); var base2Obj = new base2(); - var b1 = [ - baseObj, - base2Obj, - ifaceObj - ]; - var b2 = [ - base2Obj, - baseObj, - ifaceObj - ]; - var b3 = [ - baseObj, - ifaceObj, - base2Obj - ]; - var b4 = [ - ifaceObj, - baseObj, - base2Obj - ]; + var b1 = [baseObj, base2Obj, ifaceObj]; + var b2 = [base2Obj, baseObj, ifaceObj]; + var b3 = [baseObj, ifaceObj, base2Obj]; + var b4 = [ifaceObj, baseObj, base2Obj]; }; return f; })(); @@ -336,170 +200,34 @@ var NonEmptyTypes; return null; }; f.prototype.x = function () { - (this.voidIfAny([ - 4, - 2 - ][0])); - (this.voidIfAny([ - 4, - 2, - undefined - ][0])); - (this.voidIfAny([ - undefined, - 2, - 4 - ][0])); - (this.voidIfAny([ - null, - 2, - 4 - ][0])); - (this.voidIfAny([ - 2, - 4, - null - ][0])); - (this.voidIfAny([ - undefined, - 4, - null - ][0])); - (this.voidIfAny([ - '', - "q" - ][0])); - (this.voidIfAny([ - '', - "q", - undefined - ][0])); - (this.voidIfAny([ - undefined, - "q", - '' - ][0])); - (this.voidIfAny([ - null, - "q", - '' - ][0])); - (this.voidIfAny([ - "q", - '', - null - ][0])); - (this.voidIfAny([ - undefined, - '', - null - ][0])); - (this.voidIfAny([ - [ - 3, - 4 - ], - [ - null - ] - ][0][0])); - var t1 = [ - { - x: 7, - y: new derived() - }, - { - x: 5, - y: new base() - } - ]; - var t2 = [ - { - x: true, - y: new derived() - }, - { - x: false, - y: new base() - } - ]; - var t3 = [ - { - x: undefined, - y: new base() - }, - { - x: '', - y: new derived() - } - ]; + (this.voidIfAny([4, 2][0])); + (this.voidIfAny([4, 2, undefined][0])); + (this.voidIfAny([undefined, 2, 4][0])); + (this.voidIfAny([null, 2, 4][0])); + (this.voidIfAny([2, 4, null][0])); + (this.voidIfAny([undefined, 4, null][0])); + (this.voidIfAny(['', "q"][0])); + (this.voidIfAny(['', "q", undefined][0])); + (this.voidIfAny([undefined, "q", ''][0])); + (this.voidIfAny([null, "q", ''][0])); + (this.voidIfAny(["q", '', null][0])); + (this.voidIfAny([undefined, '', null][0])); + (this.voidIfAny([[3, 4], [null]][0][0])); + var t1 = [{ x: 7, y: new derived() }, { x: 5, y: new base() }]; + var t2 = [{ x: true, y: new derived() }, { x: false, y: new base() }]; + var t3 = [{ x: undefined, y: new base() }, { x: '', y: new derived() }]; var anyObj = null; // Order matters here so test all the variants - var a1 = [ - { - x: 0, - y: 'a' - }, - { - x: 'a', - y: 'a' - }, - { - x: anyObj, - y: 'a' - } - ]; - var a2 = [ - { - x: anyObj, - y: 'a' - }, - { - x: 0, - y: 'a' - }, - { - x: 'a', - y: 'a' - } - ]; - var a3 = [ - { - x: 0, - y: 'a' - }, - { - x: anyObj, - y: 'a' - }, - { - x: 'a', - y: 'a' - } - ]; + var a1 = [{ x: 0, y: 'a' }, { x: 'a', y: 'a' }, { x: anyObj, y: 'a' }]; + var a2 = [{ x: anyObj, y: 'a' }, { x: 0, y: 'a' }, { x: 'a', y: 'a' }]; + var a3 = [{ x: 0, y: 'a' }, { x: anyObj, y: 'a' }, { x: 'a', y: 'a' }]; var ifaceObj = null; var baseObj = new base(); var base2Obj = new base2(); - var b1 = [ - baseObj, - base2Obj, - ifaceObj - ]; - var b2 = [ - base2Obj, - baseObj, - ifaceObj - ]; - var b3 = [ - baseObj, - ifaceObj, - base2Obj - ]; - var b4 = [ - ifaceObj, - baseObj, - base2Obj - ]; + var b1 = [baseObj, base2Obj, ifaceObj]; + var b2 = [base2Obj, baseObj, ifaceObj]; + var b3 = [baseObj, ifaceObj, base2Obj]; + var b4 = [ifaceObj, baseObj, base2Obj]; }; return f; })(); diff --git a/tests/baselines/reference/arrayCast.js b/tests/baselines/reference/arrayCast.js index 7a6482fb39..214bf64225 100644 --- a/tests/baselines/reference/arrayCast.js +++ b/tests/baselines/reference/arrayCast.js @@ -9,15 +9,6 @@ //// [arrayCast.js] // Should fail. Even though the array is contextually typed with { id: number }[], it still // has type { foo: string }[], which is not assignable to { id: number }[]. -[ - { - foo: "s" - } -]; +[{ foo: "s" }]; // Should succeed, as the {} element causes the type of the array to be {}[] -[ - { - foo: "s" - }, - {} -]; +[{ foo: "s" }, {}]; diff --git a/tests/baselines/reference/arrayConcatMap.js b/tests/baselines/reference/arrayConcatMap.js index 992c8eb7ce..715ca158a4 100644 --- a/tests/baselines/reference/arrayConcatMap.js +++ b/tests/baselines/reference/arrayConcatMap.js @@ -3,14 +3,5 @@ var x = [].concat([{ a: 1 }], [{ a: 2 }]) .map(b => b.a); //// [arrayConcatMap.js] -var x = [].concat([ - { - a: 1 - } -], [ - { - a: 2 - } -]).map(function (b) { - return b.a; -}); +var x = [].concat([{ a: 1 }], [{ a: 2 }]) + .map(function (b) { return b.a; }); diff --git a/tests/baselines/reference/arrayLiteral.js b/tests/baselines/reference/arrayLiteral.js index f2d6c99817..ae210aabd4 100644 --- a/tests/baselines/reference/arrayLiteral.js +++ b/tests/baselines/reference/arrayLiteral.js @@ -19,21 +19,11 @@ var y2: number[] = new Array(); // valid uses of array literals var x = []; var x = new Array(1); -var y = [ - 1 -]; -var y = [ - 1, - 2 -]; +var y = [1]; +var y = [1, 2]; var y = new Array(); var x2 = []; var x2 = new Array(1); -var y2 = [ - 1 -]; -var y2 = [ - 1, - 2 -]; +var y2 = [1]; +var y2 = [1, 2]; var y2 = new Array(); diff --git a/tests/baselines/reference/arrayLiteral1.js b/tests/baselines/reference/arrayLiteral1.js index 8949ae684f..b84e7414f2 100644 --- a/tests/baselines/reference/arrayLiteral1.js +++ b/tests/baselines/reference/arrayLiteral1.js @@ -2,7 +2,4 @@ var v30 = [1, 2]; //// [arrayLiteral1.js] -var v30 = [ - 1, - 2 -]; +var v30 = [1, 2]; diff --git a/tests/baselines/reference/arrayLiteral2.js b/tests/baselines/reference/arrayLiteral2.js index 42d05fe916..fb1b805930 100644 --- a/tests/baselines/reference/arrayLiteral2.js +++ b/tests/baselines/reference/arrayLiteral2.js @@ -2,7 +2,4 @@ var v30 = [1, 2], v31; //// [arrayLiteral2.js] -var v30 = [ - 1, - 2 -], v31; +var v30 = [1, 2], v31; diff --git a/tests/baselines/reference/arrayLiteralContextualType.js b/tests/baselines/reference/arrayLiteralContextualType.js index c86347cb02..0edf5c4516 100644 --- a/tests/baselines/reference/arrayLiteralContextualType.js +++ b/tests/baselines/reference/arrayLiteralContextualType.js @@ -44,10 +44,8 @@ var Elephant = (function () { } return Elephant; })(); -function foo(animals) { -} -function bar(animals) { -} +function foo(animals) { } +function bar(animals) { } foo([ new Giraffe(), new Elephant() @@ -56,9 +54,6 @@ bar([ new Giraffe(), new Elephant() ]); // Legal because of the contextual type IAnimal provided by the parameter -var arr = [ - new Giraffe(), - new Elephant() -]; +var arr = [new Giraffe(), new Elephant()]; foo(arr); // ok because arr is Array not {}[] bar(arr); // ok because arr is Array not {}[] diff --git a/tests/baselines/reference/arrayLiteralSpread.js b/tests/baselines/reference/arrayLiteralSpread.js index 6cb0335e55..73a6071452 100644 --- a/tests/baselines/reference/arrayLiteralSpread.js +++ b/tests/baselines/reference/arrayLiteralSpread.js @@ -25,11 +25,7 @@ function f2() { //// [arrayLiteralSpread.js] function f0() { - var a = [ - 1, - 2, - 3 - ]; + var a = [1, 2, 3]; var a1 = a; var a2 = [1].concat(a); var a3 = [1, 2].concat(a); @@ -40,17 +36,11 @@ function f0() { var a8 = a.concat(a, a); } function f1() { - var a = [ - 1, - 2, - 3 - ]; + var a = [1, 2, 3]; var b = ["hello"].concat(a, [true]); var b; } function f2() { var a = []; - var b = [ - 5 - ]; + var b = [5]; } diff --git a/tests/baselines/reference/arrayLiteralTypeInference.js b/tests/baselines/reference/arrayLiteralTypeInference.js index 8d74e6f144..28aa143fa6 100644 --- a/tests/baselines/reference/arrayLiteralTypeInference.js +++ b/tests/baselines/reference/arrayLiteralTypeInference.js @@ -78,14 +78,8 @@ var ActionB = (function (_super) { return ActionB; })(Action); var x1 = [ - { - id: 2, - trueness: false - }, - { - id: 3, - name: "three" - } + { id: 2, trueness: false }, + { id: 3, name: "three" } ]; var x2 = [ new ActionA(), @@ -97,14 +91,8 @@ var x3 = [ new ActionB() ]; var z1 = [ - { - id: 2, - trueness: false - }, - { - id: 3, - name: "three" - } + { id: 2, trueness: false }, + { id: 3, name: "three" } ]; var z2 = [ new ActionA(), diff --git a/tests/baselines/reference/arrayLiteralWidened.js b/tests/baselines/reference/arrayLiteralWidened.js index 02f9e0c654..a250c47849 100644 --- a/tests/baselines/reference/arrayLiteralWidened.js +++ b/tests/baselines/reference/arrayLiteralWidened.js @@ -17,43 +17,10 @@ var c = [[[null]],[undefined]] //// [arrayLiteralWidened.js] // array literals are widened upon assignment according to their element type var a = []; // any[] -var a = [ - null, - null -]; -var a = [ - undefined, - undefined -]; -var b = [ - [], - [ - null, - null - ] -]; // any[][] -var b = [ - [], - [] -]; -var b = [ - [ - undefined, - undefined - ] -]; -var c = [ - [ - [] - ] -]; // any[][][] -var c = [ - [ - [ - null - ] - ], - [ - undefined - ] -]; +var a = [null, null]; +var a = [undefined, undefined]; +var b = [[], [null, null]]; // any[][] +var b = [[], []]; +var b = [[undefined, undefined]]; +var c = [[[]]]; // any[][][] +var c = [[[null]], [undefined]]; diff --git a/tests/baselines/reference/arrayLiteralWithMultipleBestCommonTypes.js b/tests/baselines/reference/arrayLiteralWithMultipleBestCommonTypes.js index 9855abefb2..b4f869d499 100644 --- a/tests/baselines/reference/arrayLiteralWithMultipleBestCommonTypes.js +++ b/tests/baselines/reference/arrayLiteralWithMultipleBestCommonTypes.js @@ -20,48 +20,10 @@ var gs = [(b: { x: number; z?: number }) => 2, (a: { x: number; y?: number }) => var a; var b; var c; -var as = [ - a, - b -]; // { x: number; y?: number };[] -var bs = [ - b, - a -]; // { x: number; z?: number };[] -var cs = [ - a, - b, - c -]; // { x: number; y?: number };[] -var ds = [ - function (x) { - return 1; - }, - function (x) { - return 2; - } -]; // { (x:Object) => number }[] -var es = [ - function (x) { - return 2; - }, - function (x) { - return 1; - } -]; // { (x:string) => number }[] -var fs = [ - function (a) { - return 1; - }, - function (b) { - return 2; - } -]; // (a: { x: number; y?: number }) => number[] -var gs = [ - function (b) { - return 2; - }, - function (a) { - return 1; - } -]; // (b: { x: number; z?: number }) => number[] +var as = [a, b]; // { x: number; y?: number };[] +var bs = [b, a]; // { x: number; z?: number };[] +var cs = [a, b, c]; // { x: number; y?: number };[] +var ds = [function (x) { return 1; }, function (x) { return 2; }]; // { (x:Object) => number }[] +var es = [function (x) { return 2; }, function (x) { return 1; }]; // { (x:string) => number }[] +var fs = [function (a) { return 1; }, function (b) { return 2; }]; // (a: { x: number; y?: number }) => number[] +var gs = [function (b) { return 2; }, function (a) { return 1; }]; // (b: { x: number; z?: number }) => number[] diff --git a/tests/baselines/reference/arrayLiterals.js b/tests/baselines/reference/arrayLiterals.js index e55d14e299..16e5ec7eee 100644 --- a/tests/baselines/reference/arrayLiterals.js +++ b/tests/baselines/reference/arrayLiterals.js @@ -44,91 +44,24 @@ var __extends = this.__extends || function (d, b) { __.prototype = b.prototype; d.prototype = new __(); }; -var arr1 = [ - [], - [ - 1 - ], - [ - '' - ] -]; -var arr2 = [ - [ - null - ], - [ - 1 - ], - [ - '' - ] -]; +var arr1 = [[], [1], ['']]; +var arr2 = [[null], [1], ['']]; // Array literal with elements of only EveryType E has type E[] -var stringArrArr = [ - [ - '' - ], - [ - "" - ] -]; -var stringArr = [ - '', - "" -]; -var numberArr = [ - 0, - 0.0, - 0x00, - 1e1 -]; -var boolArr = [ - false, - true, - false, - true -]; +var stringArrArr = [[''], [""]]; +var stringArr = ['', ""]; +var numberArr = [0, 0.0, 0x00, 1e1]; +var boolArr = [false, true, false, true]; var C = (function () { function C() { } return C; })(); -var classArr = [ - new C(), - new C() -]; -var classTypeArray = [ - C, - C, - C -]; +var classArr = [new C(), new C()]; +var classTypeArray = [C, C, C]; var classTypeArray; // Should OK, not be a parse error // Contextual type C with numeric index signature makes array literal of EveryType E of type BCT(E,C)[] -var context1 = [ - { - a: '', - b: 0, - c: '' - }, - { - a: "", - b: 3, - c: 0 - } -]; -var context2 = [ - { - a: '', - b: 0, - c: '' - }, - { - a: "", - b: 3, - c: 0 - } -]; +var context1 = [{ a: '', b: 0, c: '' }, { a: "", b: 3, c: 0 }]; +var context2 = [{ a: '', b: 0, c: '' }, { a: "", b: 3, c: 0 }]; // Contextual type C with numeric index signature of type Base makes array literal of Derived have type Base[] var Base = (function () { function Base() { @@ -151,12 +84,6 @@ var Derived2 = (function (_super) { return Derived2; })(Base); ; -var context3 = [ - new Derived1(), - new Derived2() -]; +var context3 = [new Derived1(), new Derived2()]; // Contextual type C with numeric index signature of type Base makes array literal of Derived1 and Derived2 have type Base[] -var context4 = [ - new Derived1(), - new Derived1() -]; +var context4 = [new Derived1(), new Derived1()]; diff --git a/tests/baselines/reference/arrayLiteralsWithRecursiveGenerics.js b/tests/baselines/reference/arrayLiteralsWithRecursiveGenerics.js index cce0219905..f15215a88e 100644 --- a/tests/baselines/reference/arrayLiteralsWithRecursiveGenerics.js +++ b/tests/baselines/reference/arrayLiteralsWithRecursiveGenerics.js @@ -52,20 +52,8 @@ var MyList = (function () { var list; var list2; var myList; -var xs = [ - list, - myList -]; // {}[] -var ys = [ - list, - list2 -]; // {}[] -var zs = [ - list, - null -]; // List[] +var xs = [list, myList]; // {}[] +var ys = [list, list2]; // {}[] +var zs = [list, null]; // List[] var myDerivedList; -var as = [ - list, - myDerivedList -]; // List[] +var as = [list, myDerivedList]; // List[] diff --git a/tests/baselines/reference/arrayOfFunctionTypes3.js b/tests/baselines/reference/arrayOfFunctionTypes3.js index 036fc2d85a..c0829418dd 100644 --- a/tests/baselines/reference/arrayOfFunctionTypes3.js +++ b/tests/baselines/reference/arrayOfFunctionTypes3.js @@ -28,42 +28,25 @@ var r7 = r6(''); // any not string //// [arrayOfFunctionTypes3.js] // valid uses of arrays of function types -var x = [ - function () { - return 1; - }, - function () { - } -]; +var x = [function () { return 1; }, function () { }]; var r2 = x[0](); var C = (function () { function C() { } return C; })(); -var y = [ - C, - C -]; +var y = [C, C]; var r3 = new y[0](); var a; var b; var c; -var z = [ - a, - b, - c -]; +var z = [a, b, c]; var r4 = z[0]; var r5 = r4(''); // any not string var r5b = r4(1); var a2; var b2; var c2; -var z2 = [ - a2, - b2, - c2 -]; +var z2 = [a2, b2, c2]; var r6 = z2[0]; var r7 = r6(''); // any not string diff --git a/tests/baselines/reference/arrayReferenceWithoutTypeArgs.js b/tests/baselines/reference/arrayReferenceWithoutTypeArgs.js index 3b0f2c11aa..6fcdae657e 100644 --- a/tests/baselines/reference/arrayReferenceWithoutTypeArgs.js +++ b/tests/baselines/reference/arrayReferenceWithoutTypeArgs.js @@ -7,7 +7,6 @@ class X { var X = (function () { function X() { } - X.prototype.f = function (a) { - }; + X.prototype.f = function (a) { }; return X; })(); diff --git a/tests/baselines/reference/arraySigChecking.js b/tests/baselines/reference/arraySigChecking.js index 82ef3d059e..16189305ea 100644 --- a/tests/baselines/reference/arraySigChecking.js +++ b/tests/baselines/reference/arraySigChecking.js @@ -34,22 +34,13 @@ isEmpty(['a']); //// [arraySigChecking.js] var myVar; -var strArray = [ - myVar.voidFn() -]; +var strArray = [myVar.voidFn()]; var myArray; -myArray = [ - [ - 1, - 2 - ] -]; +myArray = [[1, 2]]; function isEmpty(l) { return l.length === 0; } isEmpty([]); isEmpty(new Array(3)); isEmpty(new Array(3)); -isEmpty([ - 'a' -]); +isEmpty(['a']); diff --git a/tests/baselines/reference/arrowFunctionContexts.js b/tests/baselines/reference/arrowFunctionContexts.js index 3a47b78741..a10e3955ae 100644 --- a/tests/baselines/reference/arrowFunctionContexts.js +++ b/tests/baselines/reference/arrowFunctionContexts.js @@ -105,9 +105,7 @@ var __extends = this.__extends || function (d, b) { }; // Arrow function used in with statement with (window) { - var p = function () { - return this; - }; + var p = function () { return this; }; } // Arrow function as argument to super call var Base = (function () { @@ -119,55 +117,35 @@ var Derived = (function (_super) { __extends(Derived, _super); function Derived() { var _this = this; - _super.call(this, function () { - return _this; - }); + _super.call(this, function () { return _this; }); } return Derived; })(Base); // Arrow function as function argument -window.setTimeout(function () { - return null; -}, 100); +window.setTimeout(function () { return null; }, 100); // Arrow function as value in array literal -var obj = function (n) { - return ''; -}; +var obj = function (n) { return ''; }; var obj; // OK -var arr = [ - function (n) { - return ''; - } -]; +var arr = [function (n) { return ''; }]; var arr; // Incorrect error here (bug 829597) // Arrow function as enum value var E; (function (E) { - E[E["x"] = function () { - return 4; - }] = "x"; - E[E["y"] = (function () { - return _this; - }).length] = "y"; // error, can't use this in enum + E[E["x"] = function () { return 4; }] = "x"; + E[E["y"] = (function () { return _this; }).length] = "y"; // error, can't use this in enum })(E || (E = {})); // Arrow function as module variable initializer var M; (function (M) { - M.a = function (s) { - return ''; - }; - var b = function (s) { - return s; - }; + M.a = function (s) { return ''; }; + var b = function (s) { return s; }; })(M || (M = {})); // Repeat above for module members that are functions? (necessary to redo all of them?) var M2; (function (M2) { // Arrow function used in with statement with (window) { - var p = function () { - return this; - }; + var p = function () { return this; }; } // Arrow function as argument to super call var Base = (function () { @@ -179,69 +157,37 @@ var M2; __extends(Derived, _super); function Derived() { var _this = this; - _super.call(this, function () { - return _this; - }); + _super.call(this, function () { return _this; }); } return Derived; })(Base); // Arrow function as function argument - window.setTimeout(function () { - return null; - }, 100); + window.setTimeout(function () { return null; }, 100); // Arrow function as value in array literal - var obj = function (n) { - return ''; - }; + var obj = function (n) { return ''; }; var obj; // OK - var arr = [ - function (n) { - return ''; - } - ]; + var arr = [function (n) { return ''; }]; var arr; // Incorrect error here (bug 829597) // Arrow function as enum value var E; (function (E) { - E[E["x"] = function () { - return 4; - }] = "x"; - E[E["y"] = (function () { - return _this; - }).length] = "y"; + E[E["x"] = function () { return 4; }] = "x"; + E[E["y"] = (function () { return _this; }).length] = "y"; })(E || (E = {})); // Arrow function as module variable initializer var M; (function (M) { - M.a = function (s) { - return ''; - }; - var b = function (s) { - return s; - }; + M.a = function (s) { return ''; }; + var b = function (s) { return s; }; })(M || (M = {})); })(M2 || (M2 = {})); // (ParamList) => { ... } is a generic arrow function -var generic1 = function (n) { - return [ - n - ]; -}; +var generic1 = function (n) { return [n]; }; var generic1; // Incorrect error, Bug 829597 -var generic2 = function (n) { - return [ - n - ]; -}; +var generic2 = function (n) { return [n]; }; var generic2; // ((ParamList) => { ... } ) is a type assertion to an arrow function -var asserted1 = (function (n) { - return [ - n - ]; -}); +var asserted1 = (function (n) { return [n]; }); var asserted1; -var asserted2 = (function (n) { - return n; -}); +var asserted2 = (function (n) { return n; }); var asserted2; diff --git a/tests/baselines/reference/arrowFunctionExpressions.js b/tests/baselines/reference/arrowFunctionExpressions.js index 760ba23627..68516b52cb 100644 --- a/tests/baselines/reference/arrowFunctionExpressions.js +++ b/tests/baselines/reference/arrowFunctionExpressions.js @@ -90,84 +90,49 @@ function tryCatchFn() { //// [arrowFunctionExpressions.js] // ArrowFormalParameters => AssignmentExpression is equivalent to ArrowFormalParameters => { return AssignmentExpression; } -var a = function (p) { - return p.length; -}; -var a = function (p) { - return p.length; -}; +var a = function (p) { return p.length; }; +var a = function (p) { return p.length; }; // Identifier => Block is equivalent to(Identifier) => Block -var b = function (j) { - return 0; -}; -var b = function (j) { - return 0; -}; +var b = function (j) { return 0; }; +var b = function (j) { return 0; }; // Identifier => AssignmentExpression is equivalent to(Identifier) => AssignmentExpression var c; -var d = function (n) { - return c = n; -}; -var d = function (n) { - return c = n; -}; +var d = function (n) { return c = n; }; +var d = function (n) { return c = n; }; var d; // Arrow function used in class member initializer // Arrow function used in class member function var MyClass = (function () { function MyClass() { var _this = this; - this.m = function (n) { - return n + 1; - }; - this.p = function (n) { - return n && _this; - }; + this.m = function (n) { return n + 1; }; + this.p = function (n) { return n && _this; }; } MyClass.prototype.fn = function () { var _this = this; - var m = function (n) { - return n + 1; - }; - var p = function (n) { - return n && _this; - }; + var m = function (n) { return n + 1; }; + var p = function (n) { return n && _this; }; }; return MyClass; })(); // Arrow function used in arrow function -var arrrr = function () { - return function (m) { - return function () { - return function (n) { - return m + n; - }; - }; - }; -}; +var arrrr = function () { return function (m) { return function () { return function (n) { return m + n; }; }; }; }; var e = arrrr()(3)()(4); var e; // Arrow function used in arrow function used in function function someFn() { - var arr = function (n) { - return function (p) { - return p * n; - }; - }; + var arr = function (n) { return function (p) { return p * n; }; }; arr(3)(4).toExponential(); } // Arrow function used in function function someOtherFn() { - var arr = function (n) { - return '' + n; - }; + var arr = function (n) { return '' + n; }; arr(4).charAt(0); } // Arrow function used in nested function in function function outerFn() { function innerFn() { - var arrowFn = function () { - }; + var arrowFn = function () { }; var p = arrowFn(); var p; } @@ -175,9 +140,7 @@ function outerFn() { // Arrow function used in nested function in arrow function var f = function (n) { function fn(x) { - return function () { - return n + x; - }; + return function () { return n + x; }; } return fn(4); }; @@ -187,9 +150,7 @@ var g; function someOuterFn() { var arr = function (n) { function innerFn() { - return function () { - return n.length; - }; + return function () { return n.length; }; } return innerFn; }; @@ -201,18 +162,12 @@ h.toExponential(); function tryCatchFn() { var _this = this; try { - var x = function () { - return _this; - }; + var x = function () { return _this; }; } catch (e) { - var t = function () { - return e + _this; - }; + var t = function () { return e + _this; }; } finally { - var m = function () { - return _this + ''; - }; + var m = function () { return _this + ''; }; } } diff --git a/tests/baselines/reference/arrowFunctionInConstructorArgument1.js b/tests/baselines/reference/arrowFunctionInConstructorArgument1.js index 3cfc18d2cf..0f9c3f81b3 100644 --- a/tests/baselines/reference/arrowFunctionInConstructorArgument1.js +++ b/tests/baselines/reference/arrowFunctionInConstructorArgument1.js @@ -11,6 +11,4 @@ var C = (function () { } return C; })(); -var c = new C(function () { - return asdf; -}); // should error +var c = new C(function () { return asdf; }); // should error diff --git a/tests/baselines/reference/arrowFunctionInExpressionStatement1.js b/tests/baselines/reference/arrowFunctionInExpressionStatement1.js index 55a6d2781f..9969a28b6c 100644 --- a/tests/baselines/reference/arrowFunctionInExpressionStatement1.js +++ b/tests/baselines/reference/arrowFunctionInExpressionStatement1.js @@ -2,6 +2,4 @@ () => 0; //// [arrowFunctionInExpressionStatement1.js] -(function () { - return 0; -}); +(function () { return 0; }); diff --git a/tests/baselines/reference/arrowFunctionInExpressionStatement2.js b/tests/baselines/reference/arrowFunctionInExpressionStatement2.js index 63f3facd85..2cc6aca998 100644 --- a/tests/baselines/reference/arrowFunctionInExpressionStatement2.js +++ b/tests/baselines/reference/arrowFunctionInExpressionStatement2.js @@ -6,7 +6,5 @@ module M { //// [arrowFunctionInExpressionStatement2.js] var M; (function (M) { - (function () { - return 0; - }); + (function () { return 0; }); })(M || (M = {})); diff --git a/tests/baselines/reference/arrowFunctionMissingCurlyWithSemicolon.js b/tests/baselines/reference/arrowFunctionMissingCurlyWithSemicolon.js index 51ddc0f6da..931520294e 100644 --- a/tests/baselines/reference/arrowFunctionMissingCurlyWithSemicolon.js +++ b/tests/baselines/reference/arrowFunctionMissingCurlyWithSemicolon.js @@ -8,6 +8,4 @@ var square = (x: number) => x * x; // Should error at semicolon. var f = ; var b = 1 * 2 * 3 * 4; -var square = function (x) { - return x * x; -}; +var square = function (x) { return x * x; }; diff --git a/tests/baselines/reference/arrowFunctionWithObjectLiteralBody1.js b/tests/baselines/reference/arrowFunctionWithObjectLiteralBody1.js index e3ff758344..d53f33dead 100644 --- a/tests/baselines/reference/arrowFunctionWithObjectLiteralBody1.js +++ b/tests/baselines/reference/arrowFunctionWithObjectLiteralBody1.js @@ -2,6 +2,4 @@ var v = a => {} //// [arrowFunctionWithObjectLiteralBody1.js] -var v = function (a) { - return {}; -}; +var v = function (a) { return {}; }; diff --git a/tests/baselines/reference/arrowFunctionWithObjectLiteralBody2.js b/tests/baselines/reference/arrowFunctionWithObjectLiteralBody2.js index 384cdc2d48..f2fc086c08 100644 --- a/tests/baselines/reference/arrowFunctionWithObjectLiteralBody2.js +++ b/tests/baselines/reference/arrowFunctionWithObjectLiteralBody2.js @@ -2,6 +2,4 @@ var v = a => {} //// [arrowFunctionWithObjectLiteralBody2.js] -var v = function (a) { - return {}; -}; +var v = function (a) { return {}; }; diff --git a/tests/baselines/reference/arrowFunctionWithObjectLiteralBody5.js b/tests/baselines/reference/arrowFunctionWithObjectLiteralBody5.js index f2d27ea4a6..77f5c2d4c3 100644 --- a/tests/baselines/reference/arrowFunctionWithObjectLiteralBody5.js +++ b/tests/baselines/reference/arrowFunctionWithObjectLiteralBody5.js @@ -8,27 +8,7 @@ var c = () => ({ name: "foo", message: "bar" }); var d = () => ((({ name: "foo", message: "bar" }))); //// [arrowFunctionWithObjectLiteralBody5.js] -var a = function () { - return { - name: "foo", - message: "bar" - }; -}; -var b = function () { - return ({ - name: "foo", - message: "bar" - }); -}; -var c = function () { - return ({ - name: "foo", - message: "bar" - }); -}; -var d = function () { - return (({ - name: "foo", - message: "bar" - })); -}; +var a = function () { return { name: "foo", message: "bar" }; }; +var b = function () { return ({ name: "foo", message: "bar" }); }; +var c = function () { return ({ name: "foo", message: "bar" }); }; +var d = function () { return (({ name: "foo", message: "bar" })); }; diff --git a/tests/baselines/reference/arrowFunctionWithObjectLiteralBody6.js b/tests/baselines/reference/arrowFunctionWithObjectLiteralBody6.js index ac2af4046e..6128a6bef8 100644 --- a/tests/baselines/reference/arrowFunctionWithObjectLiteralBody6.js +++ b/tests/baselines/reference/arrowFunctionWithObjectLiteralBody6.js @@ -8,19 +8,7 @@ var c = () => ({ name: "foo", message: "bar" }); var d = () => ((({ name: "foo", message: "bar" }))); //// [arrowFunctionWithObjectLiteralBody6.js] -var a = () => ({ - name: "foo", - message: "bar" -}); -var b = () => ({ - name: "foo", - message: "bar" -}); -var c = () => ({ - name: "foo", - message: "bar" -}); -var d = () => (({ - name: "foo", - message: "bar" -})); +var a = () => ({ name: "foo", message: "bar" }); +var b = () => ({ name: "foo", message: "bar" }); +var c = () => ({ name: "foo", message: "bar" }); +var d = () => (({ name: "foo", message: "bar" })); diff --git a/tests/baselines/reference/arrowFunctionsMissingTokens.js b/tests/baselines/reference/arrowFunctionsMissingTokens.js index 7bd24f0757..e0e22578ac 100644 --- a/tests/baselines/reference/arrowFunctionsMissingTokens.js +++ b/tests/baselines/reference/arrowFunctionsMissingTokens.js @@ -69,39 +69,22 @@ module okay { //// [arrowFunctionsMissingTokens.js] var missingArrowsWithCurly; (function (missingArrowsWithCurly) { - var a = function () { - }; - var b = function () { - }; - var c = function (x) { - }; - var d = function (x, y) { - }; - var e = function (x, y) { - }; + var a = function () { }; + var b = function () { }; + var c = function (x) { }; + var d = function (x, y) { }; + var e = function (x, y) { }; })(missingArrowsWithCurly || (missingArrowsWithCurly = {})); var missingCurliesWithArrow; (function (missingCurliesWithArrow) { var withStatement; (function (withStatement) { - var a = function () { - var k = 10; - }; - var b = function () { - var k = 10; - }; - var c = function (x) { - var k = 10; - }; - var d = function (x, y) { - var k = 10; - }; - var e = function (x, y) { - var k = 10; - }; - var f = function () { - var k = 10; - }; + var a = function () { var k = 10; }; + var b = function () { var k = 10; }; + var c = function (x) { var k = 10; }; + var d = function (x, y) { var k = 10; }; + var e = function (x, y) { var k = 10; }; + var f = function () { var k = 10; }; })(withStatement || (withStatement = {})); var withoutStatement; (function (withoutStatement) { @@ -127,14 +110,9 @@ var ce_nEst_pas_une_arrow_function; })(ce_nEst_pas_une_arrow_function || (ce_nEst_pas_une_arrow_function = {})); var okay; (function (okay) { - var a = function () { - }; - var b = function () { - }; - var c = function (x) { - }; - var d = function (x, y) { - }; - var e = function (x, y) { - }; + var a = function () { }; + var b = function () { }; + var c = function (x) { }; + var d = function (x, y) { }; + var e = function (x, y) { }; })(okay || (okay = {})); diff --git a/tests/baselines/reference/asiArith.js b/tests/baselines/reference/asiArith.js index 6d7b964c8d..d552fd5ee7 100644 --- a/tests/baselines/reference/asiArith.js +++ b/tests/baselines/reference/asiArith.js @@ -37,7 +37,11 @@ y //// [asiArith.js] var x = 1; var y = 1; -var z = x + + +y; +var z = x + + + + +y; var a = 1; var b = 1; -var c = x - - -y; +var c = x + - + - -y; diff --git a/tests/baselines/reference/assign1.js b/tests/baselines/reference/assign1.js index f29f5a2a9d..fa18c8f287 100644 --- a/tests/baselines/reference/assign1.js +++ b/tests/baselines/reference/assign1.js @@ -12,8 +12,5 @@ module M { //// [assign1.js] var M; (function (M) { - var x = { - salt: 2, - pepper: 0 - }; + var x = { salt: 2, pepper: 0 }; })(M || (M = {})); diff --git a/tests/baselines/reference/assignEveryTypeToAny.js b/tests/baselines/reference/assignEveryTypeToAny.js index ed1911ef99..bbe622b330 100644 --- a/tests/baselines/reference/assignEveryTypeToAny.js +++ b/tests/baselines/reference/assignEveryTypeToAny.js @@ -91,16 +91,8 @@ var h; x = h; var i; x = i; -x = { - f: function () { - return 1; - } -}; -x = { - f: function (x) { - return x; - } -}; +x = { f: function () { return 1; } }; +x = { f: function (x) { return x; } }; function j(a) { x = a; } diff --git a/tests/baselines/reference/assignLambdaToNominalSubtypeOfFunction.js b/tests/baselines/reference/assignLambdaToNominalSubtypeOfFunction.js index 182ceec982..fe6142cafe 100644 --- a/tests/baselines/reference/assignLambdaToNominalSubtypeOfFunction.js +++ b/tests/baselines/reference/assignLambdaToNominalSubtypeOfFunction.js @@ -10,11 +10,6 @@ fn(function (a, b) { return true; }) //// [assignLambdaToNominalSubtypeOfFunction.js] -function fn(cb) { -} -fn(function (a, b) { - return true; -}); -fn(function (a, b) { - return true; -}); +function fn(cb) { } +fn(function (a, b) { return true; }); +fn(function (a, b) { return true; }); diff --git a/tests/baselines/reference/assignToExistingClass.js b/tests/baselines/reference/assignToExistingClass.js index c739279c85..f12979f314 100644 --- a/tests/baselines/reference/assignToExistingClass.js +++ b/tests/baselines/reference/assignToExistingClass.js @@ -28,9 +28,7 @@ var Test; } Tester.prototype.willThrowError = function () { Mocked = Mocked || function () { - return { - myProp: "test" - }; + return { myProp: "test" }; }; }; return Tester; diff --git a/tests/baselines/reference/assignToFn.js b/tests/baselines/reference/assignToFn.js index a565b9ab1a..2ff8ceedfa 100644 --- a/tests/baselines/reference/assignToFn.js +++ b/tests/baselines/reference/assignToFn.js @@ -13,10 +13,6 @@ module M { //// [assignToFn.js] var M; (function (M) { - var x = { - f: function (n) { - return true; - } - }; + var x = { f: function (n) { return true; } }; x.f = "hello"; })(M || (M = {})); diff --git a/tests/baselines/reference/assignmentCompat1.js b/tests/baselines/reference/assignmentCompat1.js index 99b6d592af..09546b7165 100644 --- a/tests/baselines/reference/assignmentCompat1.js +++ b/tests/baselines/reference/assignmentCompat1.js @@ -6,9 +6,7 @@ x = y; y = x; //// [assignmentCompat1.js] -var x = { - one: 1 -}; +var x = { one: 1 }; var y; x = y; y = x; diff --git a/tests/baselines/reference/assignmentCompatBug2.js b/tests/baselines/reference/assignmentCompatBug2.js index 6f4ebd585e..5545cc7d19 100644 --- a/tests/baselines/reference/assignmentCompatBug2.js +++ b/tests/baselines/reference/assignmentCompatBug2.js @@ -39,62 +39,33 @@ b3 = { }; // error //// [assignmentCompatBug2.js] -var b2 = { - a: 0 -}; // error -b2 = { - a: 0 -}; // error -b2 = { - b: 0, - a: 0 -}; +var b2 = { a: 0 }; // error +b2 = { a: 0 }; // error +b2 = { b: 0, a: 0 }; var b3; b3 = { - f: function (n) { - return 0; - }, - g: function (s) { - return 0; - }, + f: function (n) { return 0; }, + g: function (s) { return 0; }, m: 0 }; // ok b3 = { - f: function (n) { - return 0; - }, - g: function (s) { - return 0; - } + f: function (n) { return 0; }, + g: function (s) { return 0; } }; // error b3 = { - f: function (n) { - return 0; - }, + f: function (n) { return 0; }, m: 0 }; // error b3 = { - f: function (n) { - return 0; - }, - g: function (s) { - return 0; - }, + f: function (n) { return 0; }, + g: function (s) { return 0; }, m: 0, n: 0, - k: function (a) { - return null; - } + k: function (a) { return null; } }; // ok b3 = { - f: function (n) { - return 0; - }, - g: function (s) { - return 0; - }, + f: function (n) { return 0; }, + g: function (s) { return 0; }, n: 0, - k: function (a) { - return null; - } + k: function (a) { return null; } }; // error diff --git a/tests/baselines/reference/assignmentCompatBug3.js b/tests/baselines/reference/assignmentCompatBug3.js index 6d3deedc5b..049e709033 100644 --- a/tests/baselines/reference/assignmentCompatBug3.js +++ b/tests/baselines/reference/assignmentCompatBug3.js @@ -28,12 +28,8 @@ foo(x + y); //// [assignmentCompatBug3.js] function makePoint(x, y) { return { - get x() { - return x; - }, - get y() { - return y; - }, + get x() { return x; }, + get y() { return y; }, //x: "yo", //y: "boo", dist: function () { @@ -53,8 +49,7 @@ var C = (function () { }); return C; })(); -function foo(test) { -} +function foo(test) { } var x; var y; foo(x); diff --git a/tests/baselines/reference/assignmentCompatBug5.js b/tests/baselines/reference/assignmentCompatBug5.js index d769e9afd2..ae444c3dad 100644 --- a/tests/baselines/reference/assignmentCompatBug5.js +++ b/tests/baselines/reference/assignmentCompatBug5.js @@ -12,22 +12,11 @@ foo3((n) => { return; }); //// [assignmentCompatBug5.js] -function foo1(x) { -} -foo1({ - b: 5 -}); -function foo2(x) { -} -foo2([ - "s", - "t" -]); -function foo3(x) { -} +function foo1(x) { } +foo1({ b: 5 }); +function foo2(x) { } +foo2(["s", "t"]); +function foo3(x) { } ; -foo3(function (s) { -}); -foo3(function (n) { - return; -}); +foo3(function (s) { }); +foo3(function (n) { return; }); diff --git a/tests/baselines/reference/assignmentCompatForEnums.js b/tests/baselines/reference/assignmentCompatForEnums.js index 4bca6a514d..8db85399fa 100644 --- a/tests/baselines/reference/assignmentCompatForEnums.js +++ b/tests/baselines/reference/assignmentCompatForEnums.js @@ -22,9 +22,7 @@ var TokenType; })(TokenType || (TokenType = {})); ; var list = {}; -function returnType() { - return null; -} +function returnType() { return null; } function foo() { var x = returnType(); var x = list['one']; diff --git a/tests/baselines/reference/assignmentCompatFunctionsWithOptionalArgs.js b/tests/baselines/reference/assignmentCompatFunctionsWithOptionalArgs.js index b56a09ff7e..c96c739bf3 100644 --- a/tests/baselines/reference/assignmentCompatFunctionsWithOptionalArgs.js +++ b/tests/baselines/reference/assignmentCompatFunctionsWithOptionalArgs.js @@ -6,17 +6,7 @@ foo({ id: 1234, name: false }); // Error, name of wrong type foo({ name: "hello" }); // Error, id required but missing //// [assignmentCompatFunctionsWithOptionalArgs.js] -foo({ - id: 1234 -}); // Ok -foo({ - id: 1234, - name: "hello" -}); // Ok -foo({ - id: 1234, - name: false -}); // Error, name of wrong type -foo({ - name: "hello" -}); // Error, id required but missing +foo({ id: 1234 }); // Ok +foo({ id: 1234, name: "hello" }); // Ok +foo({ id: 1234, name: false }); // Error, name of wrong type +foo({ name: "hello" }); // Error, id required but missing diff --git a/tests/baselines/reference/assignmentCompatInterfaceWithStringIndexSignature.js b/tests/baselines/reference/assignmentCompatInterfaceWithStringIndexSignature.js index 2eac9cdb47..bb6817bb60 100644 --- a/tests/baselines/reference/assignmentCompatInterfaceWithStringIndexSignature.js +++ b/tests/baselines/reference/assignmentCompatInterfaceWithStringIndexSignature.js @@ -20,10 +20,8 @@ Biz(new Foo()); var Foo = (function () { function Foo() { } - Foo.prototype.Boz = function () { - }; + Foo.prototype.Boz = function () { }; return Foo; })(); -function Biz(map) { -} +function Biz(map) { } Biz(new Foo()); diff --git a/tests/baselines/reference/assignmentCompatOnNew.js b/tests/baselines/reference/assignmentCompatOnNew.js index bc3b7e6ba9..1b8cfdcc3b 100644 --- a/tests/baselines/reference/assignmentCompatOnNew.js +++ b/tests/baselines/reference/assignmentCompatOnNew.js @@ -13,6 +13,5 @@ var Foo = (function () { return Foo; })(); ; -function bar(x) { -} +function bar(x) { } bar(Foo); // Error, but should be allowed diff --git a/tests/baselines/reference/assignmentCompatWithCallSignatures.js b/tests/baselines/reference/assignmentCompatWithCallSignatures.js index 9cd0a8c8ba..12fc6159fa 100644 --- a/tests/baselines/reference/assignmentCompatWithCallSignatures.js +++ b/tests/baselines/reference/assignmentCompatWithCallSignatures.js @@ -55,40 +55,20 @@ t = s; t = a2; a = s; a = a2; -t = function (x) { - return 1; -}; -t = function () { - return 1; -}; -t = function (x) { - return ''; -}; -a = function (x) { - return 1; -}; -a = function () { - return 1; -}; -a = function (x) { - return ''; -}; +t = function (x) { return 1; }; +t = function () { return 1; }; +t = function (x) { return ''; }; +a = function (x) { return 1; }; +a = function () { return 1; }; +a = function (x) { return ''; }; var s2; var a3; // these are errors t = s2; t = a3; -t = function (x) { - return 1; -}; -t = function (x) { - return ''; -}; +t = function (x) { return 1; }; +t = function (x) { return ''; }; a = s2; a = a3; -a = function (x) { - return 1; -}; -a = function (x) { - return ''; -}; +a = function (x) { return 1; }; +a = function (x) { return ''; }; diff --git a/tests/baselines/reference/assignmentCompatWithCallSignatures2.js b/tests/baselines/reference/assignmentCompatWithCallSignatures2.js index 288a2bdf43..6bfc1b6c0d 100644 --- a/tests/baselines/reference/assignmentCompatWithCallSignatures2.js +++ b/tests/baselines/reference/assignmentCompatWithCallSignatures2.js @@ -62,70 +62,26 @@ t = s; t = a2; a = s; a = a2; -t = { - f: function () { - return 1; - } -}; -t = { - f: function (x) { - return 1; - } -}; -t = { - f: function f() { - return 1; - } -}; -t = { - f: function (x) { - return ''; - } -}; -a = { - f: function () { - return 1; - } -}; -a = { - f: function (x) { - return 1; - } -}; -a = { - f: function (x) { - return ''; - } -}; +t = { f: function () { return 1; } }; +t = { f: function (x) { return 1; } }; +t = { f: function f() { return 1; } }; +t = { f: function (x) { return ''; } }; +a = { f: function () { return 1; } }; +a = { f: function (x) { return 1; } }; +a = { f: function (x) { return ''; } }; // errors -t = function () { - return 1; -}; -t = function (x) { - return ''; -}; -a = function () { - return 1; -}; -a = function (x) { - return ''; -}; +t = function () { return 1; }; +t = function (x) { return ''; }; +a = function () { return 1; }; +a = function (x) { return ''; }; var s2; var a3; // these are errors t = s2; t = a3; -t = function (x) { - return 1; -}; -t = function (x) { - return ''; -}; +t = function (x) { return 1; }; +t = function (x) { return ''; }; a = s2; a = a3; -a = function (x) { - return 1; -}; -a = function (x) { - return ''; -}; +a = function (x) { return 1; }; +a = function (x) { return ''; }; diff --git a/tests/baselines/reference/assignmentCompatWithCallSignaturesWithOptionalParameters.js b/tests/baselines/reference/assignmentCompatWithCallSignaturesWithOptionalParameters.js index 3aa9d5a9a9..e12a741cd0 100644 --- a/tests/baselines/reference/assignmentCompatWithCallSignaturesWithOptionalParameters.js +++ b/tests/baselines/reference/assignmentCompatWithCallSignaturesWithOptionalParameters.js @@ -73,15 +73,9 @@ var a5: (x?: number, y?: number) => number; // call signatures in derived types must have the same or fewer optional parameters as the base type var b; var a; -a = function () { - return 1; -}; // ok, same number of required params -a = function (x) { - return 1; -}; // ok, same number of required params -a = function (x) { - return 1; -}; // error, too many required params +a = function () { return 1; }; // ok, same number of required params +a = function (x) { return 1; }; // ok, same number of required params +a = function (x) { return 1; }; // error, too many required params a = b.a; // ok a = b.a2; // ok a = b.a3; // error @@ -89,15 +83,9 @@ a = b.a4; // error a = b.a5; // ok a = b.a6; // error var a2; -a2 = function () { - return 1; -}; // ok, same number of required params -a2 = function (x) { - return 1; -}; // ok, same number of required params -a2 = function (x) { - return 1; -}; // ok, same number of params +a2 = function () { return 1; }; // ok, same number of required params +a2 = function (x) { return 1; }; // ok, same number of required params +a2 = function (x) { return 1; }; // ok, same number of params a2 = b.a; // ok a2 = b.a2; // ok a2 = b.a3; // ok, same number of params @@ -105,18 +93,10 @@ a2 = b.a4; // ok, excess params are optional in b.a3 a2 = b.a5; // ok a2 = b.a6; // error var a3; -a3 = function () { - return 1; -}; // ok, fewer required params -a3 = function (x) { - return 1; -}; // ok, fewer required params -a3 = function (x) { - return 1; -}; // ok, same number of required params -a3 = function (x, y) { - return 1; -}; // error, too many required params +a3 = function () { return 1; }; // ok, fewer required params +a3 = function (x) { return 1; }; // ok, fewer required params +a3 = function (x) { return 1; }; // ok, same number of required params +a3 = function (x, y) { return 1; }; // error, too many required params a3 = b.a; // ok a3 = b.a2; // ok a3 = b.a3; // ok @@ -124,18 +104,10 @@ a3 = b.a4; // ok a3 = b.a5; // ok a3 = b.a6; // error var a4; -a4 = function () { - return 1; -}; // ok, fewer required params -a4 = function (x, y) { - return 1; -}; // ok, fewer required params -a4 = function (x) { - return 1; -}; // ok, same number of required params -a4 = function (x, y) { - return 1; -}; // ok, same number of params +a4 = function () { return 1; }; // ok, fewer required params +a4 = function (x, y) { return 1; }; // ok, fewer required params +a4 = function (x) { return 1; }; // ok, same number of required params +a4 = function (x, y) { return 1; }; // ok, same number of params a4 = b.a; // ok a4 = b.a2; // ok a4 = b.a3; // ok @@ -143,18 +115,10 @@ a4 = b.a4; // ok a4 = b.a5; // ok a4 = b.a6; // ok, same number of params var a5; -a5 = function () { - return 1; -}; // ok, fewer required params -a5 = function (x, y) { - return 1; -}; // ok, fewer required params -a5 = function (x) { - return 1; -}; // ok, fewer params in lambda -a5 = function (x, y) { - return 1; -}; // ok, same number of params +a5 = function () { return 1; }; // ok, fewer required params +a5 = function (x, y) { return 1; }; // ok, fewer required params +a5 = function (x) { return 1; }; // ok, fewer params in lambda +a5 = function (x, y) { return 1; }; // ok, same number of params a5 = b.a; // ok a5 = b.a2; // ok a5 = b.a3; // ok, fewer params in b.a3 diff --git a/tests/baselines/reference/assignmentCompatWithCallSignaturesWithRestParameters.js b/tests/baselines/reference/assignmentCompatWithCallSignaturesWithRestParameters.js index 054e865eb4..f4cf5cc79e 100644 --- a/tests/baselines/reference/assignmentCompatWithCallSignaturesWithRestParameters.js +++ b/tests/baselines/reference/assignmentCompatWithCallSignaturesWithRestParameters.js @@ -48,9 +48,7 @@ var a4: (x?: number, y?: string, ...z: number[]) => number; //// [assignmentCompatWithCallSignaturesWithRestParameters.js] // call signatures in derived types must have the same or fewer optional parameters as the target for assignment var a; // ok, same number of required params -a = function () { - return 1; -}; // ok, same number of required params +a = function () { return 1; }; // ok, same number of required params a = function () { var args = []; for (var _i = 0; _i < arguments.length; _i++) { @@ -65,22 +63,12 @@ a = function () { } return 1; }; // error, type mismatch -a = function (x) { - return 1; -}; // ok, same number of required params -a = function (x, y, z) { - return 1; -}; // ok, same number of required params -a = function (x) { - return 1; -}; // ok, rest param corresponds to infinite number of params -a = function (x) { - return 1; -}; // error, incompatible type +a = function (x) { return 1; }; // ok, same number of required params +a = function (x, y, z) { return 1; }; // ok, same number of required params +a = function (x) { return 1; }; // ok, rest param corresponds to infinite number of params +a = function (x) { return 1; }; // error, incompatible type var a2; -a2 = function () { - return 1; -}; // ok, fewer required params +a2 = function () { return 1; }; // ok, fewer required params a2 = function () { var args = []; for (var _i = 0; _i < arguments.length; _i++) { @@ -88,12 +76,8 @@ a2 = function () { } return 1; }; // ok, fewer required params -a2 = function (x) { - return 1; -}; // ok, fewer required params -a2 = function (x) { - return 1; -}; // ok, same number of required params +a2 = function (x) { return 1; }; // ok, fewer required params +a2 = function (x) { return 1; }; // ok, same number of required params a2 = function (x) { var args = []; for (var _i = 1; _i < arguments.length; _i++) { @@ -108,28 +92,14 @@ a2 = function (x) { } return 1; }; // should be type mismatch error -a2 = function (x, y) { - return 1; -}; // ok, rest param corresponds to infinite number of params -a2 = function (x, y) { - return 1; -}; // ok, same number of required params +a2 = function (x, y) { return 1; }; // ok, rest param corresponds to infinite number of params +a2 = function (x, y) { return 1; }; // ok, same number of required params var a3; -a3 = function () { - return 1; -}; // ok, fewer required params -a3 = function (x) { - return 1; -}; // ok, fewer required params -a3 = function (x) { - return 1; -}; // ok, same number of required params -a3 = function (x, y) { - return 1; -}; // ok, all present params match -a3 = function (x, y, z) { - return 1; -}; // error +a3 = function () { return 1; }; // ok, fewer required params +a3 = function (x) { return 1; }; // ok, fewer required params +a3 = function (x) { return 1; }; // ok, same number of required params +a3 = function (x, y) { return 1; }; // ok, all present params match +a3 = function (x, y, z) { return 1; }; // error a3 = function (x) { var z = []; for (var _i = 1; _i < arguments.length; _i++) { @@ -137,25 +107,13 @@ a3 = function (x) { } return 1; }; // error -a3 = function (x, y, z) { - return 1; -}; // error +a3 = function (x, y, z) { return 1; }; // error var a4; -a4 = function () { - return 1; -}; // ok, fewer required params -a4 = function (x, y) { - return 1; -}; // error, type mismatch -a4 = function (x) { - return 1; -}; // ok, all present params match -a4 = function (x, y) { - return 1; -}; // error, second param has type mismatch -a4 = function (x, y) { - return 1; -}; // ok, same number of required params with matching types +a4 = function () { return 1; }; // ok, fewer required params +a4 = function (x, y) { return 1; }; // error, type mismatch +a4 = function (x) { return 1; }; // ok, all present params match +a4 = function (x, y) { return 1; }; // error, second param has type mismatch +a4 = function (x, y) { return 1; }; // ok, same number of required params with matching types a4 = function (x) { var args = []; for (var _i = 1; _i < arguments.length; _i++) { diff --git a/tests/baselines/reference/assignmentCompatWithConstructSignatures.js b/tests/baselines/reference/assignmentCompatWithConstructSignatures.js index 3b38bce159..c00aa12171 100644 --- a/tests/baselines/reference/assignmentCompatWithConstructSignatures.js +++ b/tests/baselines/reference/assignmentCompatWithConstructSignatures.js @@ -53,17 +53,9 @@ var a3; // these are errors t = s2; t = a3; -t = function (x) { - return 1; -}; -t = function (x) { - return ''; -}; +t = function (x) { return 1; }; +t = function (x) { return ''; }; a = s2; a = a3; -a = function (x) { - return 1; -}; -a = function (x) { - return ''; -}; +a = function (x) { return 1; }; +a = function (x) { return ''; }; diff --git a/tests/baselines/reference/assignmentCompatWithConstructSignatures2.js b/tests/baselines/reference/assignmentCompatWithConstructSignatures2.js index ac3accc6b5..d00762aa1c 100644 --- a/tests/baselines/reference/assignmentCompatWithConstructSignatures2.js +++ b/tests/baselines/reference/assignmentCompatWithConstructSignatures2.js @@ -55,34 +55,18 @@ t = a2; a = s; a = a2; // errors -t = function () { - return 1; -}; -t = function (x) { - return ''; -}; -a = function () { - return 1; -}; -a = function (x) { - return ''; -}; +t = function () { return 1; }; +t = function (x) { return ''; }; +a = function () { return 1; }; +a = function (x) { return ''; }; var s2; var a3; // these are errors t = s2; t = a3; -t = function (x) { - return 1; -}; -t = function (x) { - return ''; -}; +t = function (x) { return 1; }; +t = function (x) { return ''; }; a = s2; a = a3; -a = function (x) { - return 1; -}; -a = function (x) { - return ''; -}; +a = function (x) { return 1; }; +a = function (x) { return ''; }; diff --git a/tests/baselines/reference/assignmentCompatWithGenericCallSignaturesWithOptionalParameters.js b/tests/baselines/reference/assignmentCompatWithGenericCallSignaturesWithOptionalParameters.js index 1a5efce1ac..f5a3499c8c 100644 --- a/tests/baselines/reference/assignmentCompatWithGenericCallSignaturesWithOptionalParameters.js +++ b/tests/baselines/reference/assignmentCompatWithGenericCallSignaturesWithOptionalParameters.js @@ -138,60 +138,24 @@ var ClassTypeParam; function Base() { var _this = this; this.init = function () { - _this.a = function () { - return null; - }; // ok, same T of required params - _this.a = function (x) { - return null; - }; // ok, same T of required params - _this.a = function (x) { - return null; - }; // error, too many required params - _this.a2 = function () { - return null; - }; // ok, same T of required params - _this.a2 = function (x) { - return null; - }; // ok, same T of required params - _this.a2 = function (x) { - return null; - }; // ok, same number of params - _this.a3 = function () { - return null; - }; // ok, fewer required params - _this.a3 = function (x) { - return null; - }; // ok, fewer required params - _this.a3 = function (x) { - return null; - }; // ok, same T of required params - _this.a3 = function (x, y) { - return null; - }; // error, too many required params - _this.a4 = function () { - return null; - }; // ok, fewer required params - _this.a4 = function (x, y) { - return null; - }; // ok, fewer required params - _this.a4 = function (x) { - return null; - }; // ok, same T of required params - _this.a4 = function (x, y) { - return null; - }; // ok, same number of params - _this.a5 = function () { - return null; - }; // ok, fewer required params - _this.a5 = function (x, y) { - return null; - }; // ok, fewer required params - _this.a5 = function (x) { - return null; - }; // ok, all present params match - _this.a5 = function (x, y) { - return null; - }; // ok, same number of params + _this.a = function () { return null; }; // ok, same T of required params + _this.a = function (x) { return null; }; // ok, same T of required params + _this.a = function (x) { return null; }; // error, too many required params + _this.a2 = function () { return null; }; // ok, same T of required params + _this.a2 = function (x) { return null; }; // ok, same T of required params + _this.a2 = function (x) { return null; }; // ok, same number of params + _this.a3 = function () { return null; }; // ok, fewer required params + _this.a3 = function (x) { return null; }; // ok, fewer required params + _this.a3 = function (x) { return null; }; // ok, same T of required params + _this.a3 = function (x, y) { return null; }; // error, too many required params + _this.a4 = function () { return null; }; // ok, fewer required params + _this.a4 = function (x, y) { return null; }; // ok, fewer required params + _this.a4 = function (x) { return null; }; // ok, same T of required params + _this.a4 = function (x, y) { return null; }; // ok, same number of params + _this.a5 = function () { return null; }; // ok, fewer required params + _this.a5 = function (x, y) { return null; }; // ok, fewer required params + _this.a5 = function (x) { return null; }; // ok, all present params match + _this.a5 = function (x, y) { return null; }; // ok, same number of params }; } return Base; @@ -246,60 +210,24 @@ var GenericSignaturesValid; function Base2() { var _this = this; this.init = function () { - _this.a = function () { - return null; - }; // ok, same T of required params - _this.a = function (x) { - return null; - }; // ok, same T of required params - _this.a = function (x) { - return null; - }; // error, too many required params - _this.a2 = function () { - return null; - }; // ok, same T of required params - _this.a2 = function (x) { - return null; - }; // ok, same T of required params - _this.a2 = function (x) { - return null; - }; // ok, same number of params - _this.a3 = function () { - return null; - }; // ok, fewer required params - _this.a3 = function (x) { - return null; - }; // ok, fewer required params - _this.a3 = function (x) { - return null; - }; // ok, same T of required params - _this.a3 = function (x, y) { - return null; - }; // error, too many required params - _this.a4 = function () { - return null; - }; // ok, fewer required params - _this.a4 = function (x, y) { - return null; - }; // ok, fewer required params - _this.a4 = function (x) { - return null; - }; // ok, same T of required params - _this.a4 = function (x, y) { - return null; - }; // ok, same number of params - _this.a5 = function () { - return null; - }; // ok, fewer required params - _this.a5 = function (x, y) { - return null; - }; // ok, fewer required params - _this.a5 = function (x) { - return null; - }; // ok, all present params match - _this.a5 = function (x, y) { - return null; - }; // ok, same number of params + _this.a = function () { return null; }; // ok, same T of required params + _this.a = function (x) { return null; }; // ok, same T of required params + _this.a = function (x) { return null; }; // error, too many required params + _this.a2 = function () { return null; }; // ok, same T of required params + _this.a2 = function (x) { return null; }; // ok, same T of required params + _this.a2 = function (x) { return null; }; // ok, same number of params + _this.a3 = function () { return null; }; // ok, fewer required params + _this.a3 = function (x) { return null; }; // ok, fewer required params + _this.a3 = function (x) { return null; }; // ok, same T of required params + _this.a3 = function (x, y) { return null; }; // error, too many required params + _this.a4 = function () { return null; }; // ok, fewer required params + _this.a4 = function (x, y) { return null; }; // ok, fewer required params + _this.a4 = function (x) { return null; }; // ok, same T of required params + _this.a4 = function (x, y) { return null; }; // ok, same number of params + _this.a5 = function () { return null; }; // ok, fewer required params + _this.a5 = function (x, y) { return null; }; // ok, fewer required params + _this.a5 = function (x) { return null; }; // ok, all present params match + _this.a5 = function (x, y) { return null; }; // ok, same number of params }; } return Base2; diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembers.js b/tests/baselines/reference/assignmentCompatWithObjectMembers.js index d3dfe7f93f..3bd457f19d 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembers.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembers.js @@ -106,12 +106,8 @@ var SimpleTypes; var t2; var a; var b; - var a2 = { - foo: '' - }; - var b2 = { - foo: '' - }; + var a2 = { foo: '' }; + var b2 = { foo: '' }; s = t; t = s; s = s2; @@ -150,12 +146,8 @@ var ObjectTypes; var t2; var a; var b; - var a2 = { - foo: a2 - }; - var b2 = { - foo: b2 - }; + var a2 = { foo: a2 }; + var b2 = { foo: b2 }; s = t; t = s; s = s2; diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembers2.js b/tests/baselines/reference/assignmentCompatWithObjectMembers2.js index 5eb2a07ac1..ea565e9545 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembers2.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembers2.js @@ -61,12 +61,8 @@ var s2; var t2; var a; var b; -var a2 = { - foo: '' -}; -var b2 = { - foo: '' -}; +var a2 = { foo: '' }; +var b2 = { foo: '' }; s = t; t = s; s = s2; diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembers3.js b/tests/baselines/reference/assignmentCompatWithObjectMembers3.js index f65b06931c..091a1e53d1 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembers3.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembers3.js @@ -61,12 +61,8 @@ var s2; var t2; var a; var b; -var a2 = { - foo: '' -}; -var b2 = { - foo: '' -}; +var a2 = { foo: '' }; +var b2 = { foo: '' }; s = t; t = s; s = s2; diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembers4.js b/tests/baselines/reference/assignmentCompatWithObjectMembers4.js index f9933a3e04..0d535cbb20 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembers4.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembers4.js @@ -136,12 +136,8 @@ var OnlyDerived; var t2; var a; var b; - var a2 = { - foo: new Derived() - }; - var b2 = { - foo: new Derived2() - }; + var a2 = { foo: new Derived() }; + var b2 = { foo: new Derived2() }; s = t; // error t = s; // error s = s2; // ok @@ -199,12 +195,8 @@ var WithBase; var t2; var a; var b; - var a2 = { - foo: new Base() - }; - var b2 = { - foo: new Derived2() - }; + var a2 = { foo: new Base() }; + var b2 = { foo: new Derived2() }; s = t; // ok t = s; // error s = s2; // ok diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembersNumericNames.js b/tests/baselines/reference/assignmentCompatWithObjectMembersNumericNames.js index dc2e1244ef..2a1a08a97e 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembersNumericNames.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembersNumericNames.js @@ -61,12 +61,8 @@ var s2; var t2; var a; var b; -var a2 = { - 1.0: '' -}; -var b2 = { - 1: '' -}; +var a2 = { 1.0: '' }; +var b2 = { 1: '' }; s = t; t = s; s = s2; diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality.js b/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality.js index ca3ada064f..5525b623ec 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality.js @@ -119,9 +119,7 @@ var TargetHasOptional; (function (TargetHasOptional) { var c; var a; - var b = { - opt: new Base() - }; + var b = { opt: new Base() }; var d; var e; var f; @@ -144,9 +142,7 @@ var SourceHasOptional; (function (SourceHasOptional) { var c; var a; - var b = { - opt: new Base() - }; + var b = { opt: new Base() }; var d; var e; var f; diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality2.js b/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality2.js index cf65e181cb..8859a4c9ab 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality2.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembersOptionality2.js @@ -121,9 +121,7 @@ var TargetHasOptional; (function (TargetHasOptional) { var c; var a; - var b = { - opt: new Base() - }; + var b = { opt: new Base() }; var d; var e; var f; @@ -146,9 +144,7 @@ var SourceHasOptional; (function (SourceHasOptional) { var c; var a; - var b = { - opt: new Base() - }; + var b = { opt: new Base() }; var d; var e; var f; diff --git a/tests/baselines/reference/assignmentCompatWithObjectMembersStringNumericNames.js b/tests/baselines/reference/assignmentCompatWithObjectMembersStringNumericNames.js index 06f398401c..a042897ba5 100644 --- a/tests/baselines/reference/assignmentCompatWithObjectMembersStringNumericNames.js +++ b/tests/baselines/reference/assignmentCompatWithObjectMembersStringNumericNames.js @@ -106,12 +106,8 @@ var JustStrings; var t2; var a; var b; - var a2 = { - '1.0': '' - }; - var b2 = { - '1': '' - }; + var a2 = { '1.0': '' }; + var b2 = { '1': '' }; s = t; t = s; s = s2; // ok @@ -150,12 +146,8 @@ var NumbersAndStrings; var t2; var a; var b; - var a2 = { - '1.0': '' - }; - var b2 = { - 1.: '' - }; + var a2 = { '1.0': '' }; + var b2 = { 1.: '' }; s = t; // ok t = s; // ok s = s2; // ok diff --git a/tests/baselines/reference/assignmentCompatWithOverloads.js b/tests/baselines/reference/assignmentCompatWithOverloads.js index 472ebec296..ca3dc0e229 100644 --- a/tests/baselines/reference/assignmentCompatWithOverloads.js +++ b/tests/baselines/reference/assignmentCompatWithOverloads.js @@ -31,18 +31,10 @@ var d: new(x: number) => void; d = C; // Error //// [assignmentCompatWithOverloads.js] -function f1(x) { - return null; -} -function f2(x) { - return null; -} -function f3(x) { - return null; -} -function f4(x) { - return undefined; -} +function f1(x) { return null; } +function f2(x) { return null; } +function f3(x) { return null; } +function f4(x) { return undefined; } var g; g = f1; // OK g = f2; // Error diff --git a/tests/baselines/reference/assignmentCompatability1.js b/tests/baselines/reference/assignmentCompatability1.js index 61ac5d2205..f629d5eba2 100644 --- a/tests/baselines/reference/assignmentCompatability1.js +++ b/tests/baselines/reference/assignmentCompatability1.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability10.js b/tests/baselines/reference/assignmentCompatability10.js index a494e30f6c..bbcc8e879e 100644 --- a/tests/baselines/reference/assignmentCompatability10.js +++ b/tests/baselines/reference/assignmentCompatability10.js @@ -13,9 +13,7 @@ __test2__.__val__x4 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability11.js b/tests/baselines/reference/assignmentCompatability11.js index 929a8f1bca..992e38f772 100644 --- a/tests/baselines/reference/assignmentCompatability11.js +++ b/tests/baselines/reference/assignmentCompatability11.js @@ -13,17 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - two: 1 - }; + __test2__.obj = { two: 1 }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability12.js b/tests/baselines/reference/assignmentCompatability12.js index f0ccb00833..3c802aab6e 100644 --- a/tests/baselines/reference/assignmentCompatability12.js +++ b/tests/baselines/reference/assignmentCompatability12.js @@ -13,17 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - one: "1" - }; + __test2__.obj = { one: "1" }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability13.js b/tests/baselines/reference/assignmentCompatability13.js index 084ef7ebeb..ef4f24f710 100644 --- a/tests/baselines/reference/assignmentCompatability13.js +++ b/tests/baselines/reference/assignmentCompatability13.js @@ -13,17 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - two: "1" - }; + __test2__.obj = { two: "1" }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability14.js b/tests/baselines/reference/assignmentCompatability14.js index 4bfe397bc6..bd4445cb51 100644 --- a/tests/baselines/reference/assignmentCompatability14.js +++ b/tests/baselines/reference/assignmentCompatability14.js @@ -13,17 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - one: true - }; + __test2__.obj = { one: true }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability15.js b/tests/baselines/reference/assignmentCompatability15.js index 0fffe4bd53..37f1be4bc9 100644 --- a/tests/baselines/reference/assignmentCompatability15.js +++ b/tests/baselines/reference/assignmentCompatability15.js @@ -13,17 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - two: true - }; + __test2__.obj = { two: true }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability16.js b/tests/baselines/reference/assignmentCompatability16.js index 6b20f1be30..43c832016b 100644 --- a/tests/baselines/reference/assignmentCompatability16.js +++ b/tests/baselines/reference/assignmentCompatability16.js @@ -13,19 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - one: [ - 1 - ] - }; + __test2__.obj = { one: [1] }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability17.js b/tests/baselines/reference/assignmentCompatability17.js index b44ce12bb1..09ce24b8f5 100644 --- a/tests/baselines/reference/assignmentCompatability17.js +++ b/tests/baselines/reference/assignmentCompatability17.js @@ -13,19 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - two: [ - 1 - ] - }; + __test2__.obj = { two: [1] }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability18.js b/tests/baselines/reference/assignmentCompatability18.js index 1120d349d0..ad93e96303 100644 --- a/tests/baselines/reference/assignmentCompatability18.js +++ b/tests/baselines/reference/assignmentCompatability18.js @@ -13,19 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - one: [ - 1 - ] - }; + __test2__.obj = { one: [1] }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability19.js b/tests/baselines/reference/assignmentCompatability19.js index 6bc4c762ee..f330f94e81 100644 --- a/tests/baselines/reference/assignmentCompatability19.js +++ b/tests/baselines/reference/assignmentCompatability19.js @@ -13,19 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - two: [ - 1 - ] - }; + __test2__.obj = { two: [1] }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability2.js b/tests/baselines/reference/assignmentCompatability2.js index b280ce83c2..207942875b 100644 --- a/tests/baselines/reference/assignmentCompatability2.js +++ b/tests/baselines/reference/assignmentCompatability2.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability20.js b/tests/baselines/reference/assignmentCompatability20.js index aed1436027..321ec78ee1 100644 --- a/tests/baselines/reference/assignmentCompatability20.js +++ b/tests/baselines/reference/assignmentCompatability20.js @@ -13,19 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - one: [ - "1" - ] - }; + __test2__.obj = { one: ["1"] }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability21.js b/tests/baselines/reference/assignmentCompatability21.js index 6ede7ac66e..215ab5dc39 100644 --- a/tests/baselines/reference/assignmentCompatability21.js +++ b/tests/baselines/reference/assignmentCompatability21.js @@ -13,19 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - two: [ - "1" - ] - }; + __test2__.obj = { two: ["1"] }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability22.js b/tests/baselines/reference/assignmentCompatability22.js index 41d6044279..04cc2a2d0a 100644 --- a/tests/baselines/reference/assignmentCompatability22.js +++ b/tests/baselines/reference/assignmentCompatability22.js @@ -13,19 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - one: [ - true - ] - }; + __test2__.obj = { one: [true] }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability23.js b/tests/baselines/reference/assignmentCompatability23.js index 4604fd2ba4..1d03236436 100644 --- a/tests/baselines/reference/assignmentCompatability23.js +++ b/tests/baselines/reference/assignmentCompatability23.js @@ -13,19 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - two: [ - true - ] - }; + __test2__.obj = { two: [true] }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability24.js b/tests/baselines/reference/assignmentCompatability24.js index 5fa5e612d0..e6961264de 100644 --- a/tests/baselines/reference/assignmentCompatability24.js +++ b/tests/baselines/reference/assignmentCompatability24.js @@ -13,17 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = function f(a) { - return a; - }; + __test2__.obj = function f(a) { return a; }; ; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability25.js b/tests/baselines/reference/assignmentCompatability25.js index 7bc941c345..4f365e9049 100644 --- a/tests/baselines/reference/assignmentCompatability25.js +++ b/tests/baselines/reference/assignmentCompatability25.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability26.js b/tests/baselines/reference/assignmentCompatability26.js index b01d3e19a0..e2ae6b766d 100644 --- a/tests/baselines/reference/assignmentCompatability26.js +++ b/tests/baselines/reference/assignmentCompatability26.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability27.js b/tests/baselines/reference/assignmentCompatability27.js index 5460ed7f6c..be5b06dab7 100644 --- a/tests/baselines/reference/assignmentCompatability27.js +++ b/tests/baselines/reference/assignmentCompatability27.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability28.js b/tests/baselines/reference/assignmentCompatability28.js index 6358375ed3..eef6f0a5ef 100644 --- a/tests/baselines/reference/assignmentCompatability28.js +++ b/tests/baselines/reference/assignmentCompatability28.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability29.js b/tests/baselines/reference/assignmentCompatability29.js index 251a580015..c3410a943c 100644 --- a/tests/baselines/reference/assignmentCompatability29.js +++ b/tests/baselines/reference/assignmentCompatability29.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability3.js b/tests/baselines/reference/assignmentCompatability3.js index e32ae5da7b..7120e6ce3e 100644 --- a/tests/baselines/reference/assignmentCompatability3.js +++ b/tests/baselines/reference/assignmentCompatability3.js @@ -13,17 +13,13 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { - __test2__.obj = { - one: 1 - }; + __test2__.obj = { one: 1 }; __test2__.__val__obj = __test2__.obj; })(__test2__ || (__test2__ = {})); __test2__.__val__obj = __test1__.__val__obj4; diff --git a/tests/baselines/reference/assignmentCompatability30.js b/tests/baselines/reference/assignmentCompatability30.js index 3d519971fa..261c86ad58 100644 --- a/tests/baselines/reference/assignmentCompatability30.js +++ b/tests/baselines/reference/assignmentCompatability30.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability31.js b/tests/baselines/reference/assignmentCompatability31.js index ad0954e2dc..152b588b72 100644 --- a/tests/baselines/reference/assignmentCompatability31.js +++ b/tests/baselines/reference/assignmentCompatability31.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability32.js b/tests/baselines/reference/assignmentCompatability32.js index e321f02c64..b9ddacff90 100644 --- a/tests/baselines/reference/assignmentCompatability32.js +++ b/tests/baselines/reference/assignmentCompatability32.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability33.js b/tests/baselines/reference/assignmentCompatability33.js index 44d42b4bd4..80dfcfc4f7 100644 --- a/tests/baselines/reference/assignmentCompatability33.js +++ b/tests/baselines/reference/assignmentCompatability33.js @@ -13,9 +13,7 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability34.js b/tests/baselines/reference/assignmentCompatability34.js index 6716719265..ab324a1039 100644 --- a/tests/baselines/reference/assignmentCompatability34.js +++ b/tests/baselines/reference/assignmentCompatability34.js @@ -13,9 +13,7 @@ __test2__.__val__obj = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability35.js b/tests/baselines/reference/assignmentCompatability35.js index f01c63390e..1b79a83146 100644 --- a/tests/baselines/reference/assignmentCompatability35.js +++ b/tests/baselines/reference/assignmentCompatability35.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability36.js b/tests/baselines/reference/assignmentCompatability36.js index 7c939ceb28..62332f741d 100644 --- a/tests/baselines/reference/assignmentCompatability36.js +++ b/tests/baselines/reference/assignmentCompatability36.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability37.js b/tests/baselines/reference/assignmentCompatability37.js index 5741b18115..8625cae42e 100644 --- a/tests/baselines/reference/assignmentCompatability37.js +++ b/tests/baselines/reference/assignmentCompatability37.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability38.js b/tests/baselines/reference/assignmentCompatability38.js index 81a7692f62..22096b68f2 100644 --- a/tests/baselines/reference/assignmentCompatability38.js +++ b/tests/baselines/reference/assignmentCompatability38.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability39.js b/tests/baselines/reference/assignmentCompatability39.js index fe2f499270..70e8a69229 100644 --- a/tests/baselines/reference/assignmentCompatability39.js +++ b/tests/baselines/reference/assignmentCompatability39.js @@ -13,9 +13,7 @@ __test2__.__val__x2 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability4.js b/tests/baselines/reference/assignmentCompatability4.js index 853164790c..2f7d33b8d5 100644 --- a/tests/baselines/reference/assignmentCompatability4.js +++ b/tests/baselines/reference/assignmentCompatability4.js @@ -13,9 +13,7 @@ __test2__.__val__aa = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability40.js b/tests/baselines/reference/assignmentCompatability40.js index 2692302939..801ddfe759 100644 --- a/tests/baselines/reference/assignmentCompatability40.js +++ b/tests/baselines/reference/assignmentCompatability40.js @@ -13,9 +13,7 @@ __test2__.__val__x5 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability41.js b/tests/baselines/reference/assignmentCompatability41.js index 101eee5ae3..2ebd35a6ca 100644 --- a/tests/baselines/reference/assignmentCompatability41.js +++ b/tests/baselines/reference/assignmentCompatability41.js @@ -13,9 +13,7 @@ __test2__.__val__x6 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability42.js b/tests/baselines/reference/assignmentCompatability42.js index d819f748af..39dab170d3 100644 --- a/tests/baselines/reference/assignmentCompatability42.js +++ b/tests/baselines/reference/assignmentCompatability42.js @@ -13,9 +13,7 @@ __test2__.__val__x7 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability43.js b/tests/baselines/reference/assignmentCompatability43.js index 5c13de6fa5..0ff9bdb481 100644 --- a/tests/baselines/reference/assignmentCompatability43.js +++ b/tests/baselines/reference/assignmentCompatability43.js @@ -13,19 +13,14 @@ __test2__.__val__obj2 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { ; - var obj2 = { - one: 1, - two: "a" - }; + var obj2 = { one: 1, two: "a" }; ; __test2__.__val__obj2 = obj2; })(__test2__ || (__test2__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability5.js b/tests/baselines/reference/assignmentCompatability5.js index b94a00de73..ef38b738ad 100644 --- a/tests/baselines/reference/assignmentCompatability5.js +++ b/tests/baselines/reference/assignmentCompatability5.js @@ -13,18 +13,14 @@ __test2__.__val__obj1 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { ; - var obj1 = { - one: 1 - }; + var obj1 = { one: 1 }; ; __test2__.__val__obj1 = obj1; })(__test2__ || (__test2__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability6.js b/tests/baselines/reference/assignmentCompatability6.js index cd87bd1064..7b1e2bb65d 100644 --- a/tests/baselines/reference/assignmentCompatability6.js +++ b/tests/baselines/reference/assignmentCompatability6.js @@ -13,9 +13,7 @@ __test2__.__val__obj3 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability7.js b/tests/baselines/reference/assignmentCompatability7.js index a668bc3490..c6bf8e53bc 100644 --- a/tests/baselines/reference/assignmentCompatability7.js +++ b/tests/baselines/reference/assignmentCompatability7.js @@ -13,18 +13,14 @@ __test2__.__val__obj4 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); var __test2__; (function (__test2__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test2__.__val__obj4 = obj4; })(__test2__ || (__test2__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability8.js b/tests/baselines/reference/assignmentCompatability8.js index e022ddf7bd..65e4240aac 100644 --- a/tests/baselines/reference/assignmentCompatability8.js +++ b/tests/baselines/reference/assignmentCompatability8.js @@ -13,9 +13,7 @@ __test2__.__val__x1 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability9.js b/tests/baselines/reference/assignmentCompatability9.js index cbc34de158..98932380b3 100644 --- a/tests/baselines/reference/assignmentCompatability9.js +++ b/tests/baselines/reference/assignmentCompatability9.js @@ -13,9 +13,7 @@ __test2__.__val__x3 = __test1__.__val__obj4 var __test1__; (function (__test1__) { ; - var obj4 = { - one: 1 - }; + var obj4 = { one: 1 }; ; __test1__.__val__obj4 = obj4; })(__test1__ || (__test1__ = {})); diff --git a/tests/baselines/reference/assignmentCompatability_checking-apply-member-off-of-function-interface.js b/tests/baselines/reference/assignmentCompatability_checking-apply-member-off-of-function-interface.js index 7346f601da..760631ffbb 100644 --- a/tests/baselines/reference/assignmentCompatability_checking-apply-member-off-of-function-interface.js +++ b/tests/baselines/reference/assignmentCompatability_checking-apply-member-off-of-function-interface.js @@ -35,25 +35,18 @@ fn(a => { }); var x; // Should fail x = ''; -x = [ - '' -]; +x = ['']; x = 4; x = {}; // Should work -function f() { -} +function f() { } ; x = f; -function fn(c) { -} +function fn(c) { } // Should Fail fn(''); -fn([ - '' -]); +fn(['']); fn(4); fn({}); // Should work -fn(function (a) { -}); +fn(function (a) { }); diff --git a/tests/baselines/reference/assignmentCompatability_checking-call-member-off-of-function-interface.js b/tests/baselines/reference/assignmentCompatability_checking-call-member-off-of-function-interface.js index 4e5ed88699..2e61521eef 100644 --- a/tests/baselines/reference/assignmentCompatability_checking-call-member-off-of-function-interface.js +++ b/tests/baselines/reference/assignmentCompatability_checking-call-member-off-of-function-interface.js @@ -35,25 +35,18 @@ fn(a => { }); var x; // Should fail x = ''; -x = [ - '' -]; +x = ['']; x = 4; x = {}; // Should work -function f() { -} +function f() { } ; x = f; -function fn(c) { -} +function fn(c) { } // Should Fail fn(''); -fn([ - '' -]); +fn(['']); fn(4); fn({}); // Should work -fn(function (a) { -}); +fn(function (a) { }); diff --git a/tests/baselines/reference/assignmentLHSIsValue.js b/tests/baselines/reference/assignmentLHSIsValue.js index e6975e7014..4b17f85517 100644 --- a/tests/baselines/reference/assignmentLHSIsValue.js +++ b/tests/baselines/reference/assignmentLHSIsValue.js @@ -84,17 +84,11 @@ var C = (function () { function C() { this = value; } - C.prototype.foo = function () { - this = value; - }; - C.sfoo = function () { - this = value; - }; + C.prototype.foo = function () { this = value; }; + C.sfoo = function () { this = value; }; return C; })(); -function foo() { - this = value; -} +function foo() { this = value; } this = value; // identifiers: module, class, enum, function var M; @@ -129,20 +123,14 @@ var Derived = (function (_super) { _super.call(this); _super.prototype. = value; } - Derived.prototype.foo = function () { - _super.prototype. = value; - }; - Derived.sfoo = function () { - _super. = value; - }; + Derived.prototype.foo = function () { _super.prototype. = value; }; + Derived.sfoo = function () { _super. = value; }; return Derived; })(C); // function expression -function bar() { -} +function bar() { } value; -(function () { -}); +(function () { }); value; // function calls foo() = value; @@ -159,6 +147,5 @@ foo() = value; (/d+/) = value; ({}) = value; ([]) = value; -(function baz() { -}) = value; +(function baz() { }) = value; (foo()) = value; diff --git a/tests/baselines/reference/assignmentStricterConstraints.js b/tests/baselines/reference/assignmentStricterConstraints.js index f8f4ce6d1b..a7f554ade7 100644 --- a/tests/baselines/reference/assignmentStricterConstraints.js +++ b/tests/baselines/reference/assignmentStricterConstraints.js @@ -13,7 +13,6 @@ g(1, "") var f = function (x, y) { x = y; }; -var g = function (x, y) { -}; +var g = function (x, y) { }; g = f; g(1, ""); diff --git a/tests/baselines/reference/assignmentToFunction.js b/tests/baselines/reference/assignmentToFunction.js index 275107e05b..7462fdfcf3 100644 --- a/tests/baselines/reference/assignmentToFunction.js +++ b/tests/baselines/reference/assignmentToFunction.js @@ -11,11 +11,8 @@ module foo { } //// [assignmentToFunction.js] -function fn() { -} -fn = function () { - return 3; -}; +function fn() { } +fn = function () { return 3; }; var foo; (function (foo) { function xyz() { diff --git a/tests/baselines/reference/assignmentToObject.js b/tests/baselines/reference/assignmentToObject.js index 666350b50e..d8134080c6 100644 --- a/tests/baselines/reference/assignmentToObject.js +++ b/tests/baselines/reference/assignmentToObject.js @@ -5,8 +5,6 @@ var c: Object = a; // should be error //// [assignmentToObject.js] -var a = { - toString: 5 -}; +var a = { toString: 5 }; var b = a; // ok var c = a; // should be error diff --git a/tests/baselines/reference/assignmentToObjectAndFunction.js b/tests/baselines/reference/assignmentToObjectAndFunction.js index bd09a7a8e1..a3c4785b18 100644 --- a/tests/baselines/reference/assignmentToObjectAndFunction.js +++ b/tests/baselines/reference/assignmentToObjectAndFunction.js @@ -30,33 +30,27 @@ module bad { var badFundule: Function = bad; // error //// [assignmentToObjectAndFunction.js] -var errObj = { - toString: 0 -}; // Error, incompatible toString +var errObj = { toString: 0 }; // Error, incompatible toString var goodObj = { toString: function (x) { return ""; } }; // Ok, because toString is a subtype of Object's toString var errFun = {}; // Error for no call signature -function foo() { -} +function foo() { } var foo; (function (foo) { foo.boom = 0; })(foo || (foo = {})); var goodFundule = foo; // ok -function bar() { -} +function bar() { } var bar; (function (bar) { - function apply(thisArg, argArray) { - } + function apply(thisArg, argArray) { } bar.apply = apply; })(bar || (bar = {})); var goodFundule2 = bar; // ok -function bad() { -} +function bad() { } var bad; (function (bad) { bad.apply = 0; diff --git a/tests/baselines/reference/assignmentToParenthesizedIdentifiers.js b/tests/baselines/reference/assignmentToParenthesizedIdentifiers.js index 584934ea77..9526cb08be 100644 --- a/tests/baselines/reference/assignmentToParenthesizedIdentifiers.js +++ b/tests/baselines/reference/assignmentToParenthesizedIdentifiers.js @@ -87,48 +87,25 @@ M.y = 3; // OK M.y = ''; // Error (M).y = ''; // Error (M.y) = ''; // Error -M = { - y: 3 -}; // Error -(M) = { - y: 3 -}; // Error +M = { y: 3 }; // Error +(M) = { y: 3 }; // Error var M2; (function (M2) { var M3; (function (M3) { M3.x; })(M3 = M2.M3 || (M2.M3 = {})); - M3 = { - x: 3 - }; // Error + M3 = { x: 3 }; // Error })(M2 || (M2 = {})); -M2.M3 = { - x: 3 -}; // OK -(M2).M3 = { - x: 3 -}; // OK -(M2.M3) = { - x: 3 -}; // OK -M2.M3 = { - x: '' -}; // Error -(M2).M3 = { - x: '' -}; // Error -(M2.M3) = { - x: '' -}; // Error -function fn() { -} -fn = function () { - return 3; -}; // Bug 823548: Should be error (fn is not a reference) -(fn) = function () { - return 3; -}; // Should be error +M2.M3 = { x: 3 }; // OK +(M2).M3 = { x: 3 }; // OK +(M2.M3) = { x: 3 }; // OK +M2.M3 = { x: '' }; // Error +(M2).M3 = { x: '' }; // Error +(M2.M3) = { x: '' }; // Error +function fn() { } +fn = function () { return 3; }; // Bug 823548: Should be error (fn is not a reference) +(fn) = function () { return 3; }; // Should be error function fn2(x, y) { x = 3; (x) = 3; // OK diff --git a/tests/baselines/reference/assignmentToReferenceTypes.js b/tests/baselines/reference/assignmentToReferenceTypes.js index 214e10b9c6..1aec3c2051 100644 --- a/tests/baselines/reference/assignmentToReferenceTypes.js +++ b/tests/baselines/reference/assignmentToReferenceTypes.js @@ -36,8 +36,7 @@ var E; (function (E) { })(E || (E = {})); E = null; -function f() { -} +function f() { } f = null; var x = 1; x = null; diff --git a/tests/baselines/reference/assignments.js b/tests/baselines/reference/assignments.js index f6ca508384..e2c9c90d37 100644 --- a/tests/baselines/reference/assignments.js +++ b/tests/baselines/reference/assignments.js @@ -53,8 +53,7 @@ var E; })(E || (E = {})); E = null; // Error E.A = null; // OK per spec, Error per implementation (509581) -function fn() { -} +function fn() { } fn = null; // Should be error var v; v = null; // OK diff --git a/tests/baselines/reference/augmentedTypeAssignmentCompatIndexSignature.js b/tests/baselines/reference/augmentedTypeAssignmentCompatIndexSignature.js index 88996de155..32fed237a2 100644 --- a/tests/baselines/reference/augmentedTypeAssignmentCompatIndexSignature.js +++ b/tests/baselines/reference/augmentedTypeAssignmentCompatIndexSignature.js @@ -23,7 +23,6 @@ var v2: { //// [augmentedTypeAssignmentCompatIndexSignature.js] var o = {}; -var f = function () { -}; +var f = function () { }; var v1 = o; // Should be allowed var v2 = f; // Should be allowed diff --git a/tests/baselines/reference/augmentedTypeBracketAccessIndexSignature.js b/tests/baselines/reference/augmentedTypeBracketAccessIndexSignature.js index a1b6bf6805..8d2c94899d 100644 --- a/tests/baselines/reference/augmentedTypeBracketAccessIndexSignature.js +++ b/tests/baselines/reference/augmentedTypeBracketAccessIndexSignature.js @@ -15,5 +15,4 @@ var b = (() => { })[0]; // Should be Bar //// [augmentedTypeBracketAccessIndexSignature.js] var a = {}[0]; // Should be Foo -var b = (function () { -})[0]; // Should be Bar +var b = (function () { })[0]; // Should be Bar diff --git a/tests/baselines/reference/augmentedTypeBracketNamedPropertyAccess.js b/tests/baselines/reference/augmentedTypeBracketNamedPropertyAccess.js index 5bc184df66..6ec653c69b 100644 --- a/tests/baselines/reference/augmentedTypeBracketNamedPropertyAccess.js +++ b/tests/baselines/reference/augmentedTypeBracketNamedPropertyAccess.js @@ -15,8 +15,7 @@ var r4 = f['data']; // Should be number //// [augmentedTypeBracketNamedPropertyAccess.js] var o = {}; -var f = function () { -}; +var f = function () { }; var r1 = o['data']; // Should be number var r2 = o['functionData']; // Should be any (no property found) var r3 = f['functionData']; // Should be string diff --git a/tests/baselines/reference/augmentedTypesClass.js b/tests/baselines/reference/augmentedTypesClass.js index 5d0d8ab75d..30b75483d8 100644 --- a/tests/baselines/reference/augmentedTypesClass.js +++ b/tests/baselines/reference/augmentedTypesClass.js @@ -12,8 +12,7 @@ enum c4 { One } // error var c1 = (function () { function c1() { } - c1.prototype.foo = function () { - }; + c1.prototype.foo = function () { }; return c1; })(); var c1 = 1; // error @@ -21,8 +20,7 @@ var c1 = 1; // error var c4 = (function () { function c4() { } - c4.prototype.foo = function () { - }; + c4.prototype.foo = function () { }; return c4; })(); var c4; diff --git a/tests/baselines/reference/augmentedTypesClass2a.js b/tests/baselines/reference/augmentedTypesClass2a.js index fe31f0964c..b2c6fa1e37 100644 --- a/tests/baselines/reference/augmentedTypesClass2a.js +++ b/tests/baselines/reference/augmentedTypesClass2a.js @@ -9,11 +9,8 @@ var c2 = () => { } var c2 = (function () { function c2() { } - c2.prototype.foo = function () { - }; + c2.prototype.foo = function () { }; return c2; })(); // error -function c2() { -} // error -var c2 = function () { -}; +function c2() { } // error +var c2 = function () { }; diff --git a/tests/baselines/reference/augmentedTypesClass3.js b/tests/baselines/reference/augmentedTypesClass3.js index b42d9dda35..11d3f0a0d9 100644 --- a/tests/baselines/reference/augmentedTypesClass3.js +++ b/tests/baselines/reference/augmentedTypesClass3.js @@ -18,15 +18,13 @@ class c5c { public foo() { } } var c5 = (function () { function c5() { } - c5.prototype.foo = function () { - }; + c5.prototype.foo = function () { }; return c5; })(); var c5a = (function () { function c5a() { } - c5a.prototype.foo = function () { - }; + c5a.prototype.foo = function () { }; return c5a; })(); var c5a; @@ -36,8 +34,7 @@ var c5a; var c5b = (function () { function c5b() { } - c5b.prototype.foo = function () { - }; + c5b.prototype.foo = function () { }; return c5b; })(); var c5b; @@ -48,8 +45,7 @@ var c5b; var c5c = (function () { function c5c() { } - c5c.prototype.foo = function () { - }; + c5c.prototype.foo = function () { }; return c5c; })(); //import c5c = require(''); diff --git a/tests/baselines/reference/augmentedTypesClass4.js b/tests/baselines/reference/augmentedTypesClass4.js index 71fc61d665..f178567d84 100644 --- a/tests/baselines/reference/augmentedTypesClass4.js +++ b/tests/baselines/reference/augmentedTypesClass4.js @@ -9,14 +9,12 @@ class c3 { public bar() { } } // error var c3 = (function () { function c3() { } - c3.prototype.foo = function () { - }; + c3.prototype.foo = function () { }; return c3; })(); // error var c3 = (function () { function c3() { } - c3.prototype.bar = function () { - }; + c3.prototype.bar = function () { }; return c3; })(); // error diff --git a/tests/baselines/reference/augmentedTypesEnum.js b/tests/baselines/reference/augmentedTypesEnum.js index 484b0addd5..cb1ec3e844 100644 --- a/tests/baselines/reference/augmentedTypesEnum.js +++ b/tests/baselines/reference/augmentedTypesEnum.js @@ -47,14 +47,12 @@ var e2; (function (e2) { e2[e2["One"] = 0] = "One"; })(e2 || (e2 = {})); // error -function e2() { -} // error +function e2() { } // error var e3; (function (e3) { e3[e3["One"] = 0] = "One"; })(e3 || (e3 = {})); // error -var e3 = function () { -}; // error +var e3 = function () { }; // error // enum then class var e4; (function (e4) { @@ -63,8 +61,7 @@ var e4; var e4 = (function () { function e4() { } - e4.prototype.foo = function () { - }; + e4.prototype.foo = function () { }; return e4; })(); // error // enum then enum diff --git a/tests/baselines/reference/augmentedTypesExternalModule1.js b/tests/baselines/reference/augmentedTypesExternalModule1.js index 69cc810668..104559396c 100644 --- a/tests/baselines/reference/augmentedTypesExternalModule1.js +++ b/tests/baselines/reference/augmentedTypesExternalModule1.js @@ -9,8 +9,7 @@ define(["require", "exports"], function (require, exports) { var c5 = (function () { function c5() { } - c5.prototype.foo = function () { - }; + c5.prototype.foo = function () { }; return c5; })(); }); diff --git a/tests/baselines/reference/augmentedTypesFunction.js b/tests/baselines/reference/augmentedTypesFunction.js index 34567c77e8..1cd1423b7c 100644 --- a/tests/baselines/reference/augmentedTypesFunction.js +++ b/tests/baselines/reference/augmentedTypesFunction.js @@ -40,59 +40,46 @@ module y5c { export interface I { foo(): void } } // should be an error //// [augmentedTypesFunction.js] // function then var -function y1() { -} // error +function y1() { } // error var y1 = 1; // error // function then function -function y2() { -} // error -function y2() { -} // error -function y2a() { -} // error -var y2a = function () { -}; // error +function y2() { } // error +function y2() { } // error +function y2a() { } // error +var y2a = function () { }; // error // function then class -function y3() { -} // error +function y3() { } // error var y3 = (function () { function y3() { } return y3; })(); // error -function y3a() { -} // error +function y3a() { } // error var y3a = (function () { function y3a() { } - y3a.prototype.foo = function () { - }; + y3a.prototype.foo = function () { }; return y3a; })(); // error // function then enum -function y4() { -} // error +function y4() { } // error var y4; (function (y4) { y4[y4["One"] = 0] = "One"; })(y4 || (y4 = {})); // error // function then internal module -function y5() { -} -function y5a() { -} +function y5() { } +function y5a() { } var y5a; (function (y5a) { var y = 2; })(y5a || (y5a = {})); // should be an error -function y5b() { -} +function y5b() { } var y5b; (function (y5b) { y5b.y = 3; })(y5b || (y5b = {})); // should be an error -function y5c() { -} +function y5c() { } // function then import, messes with other errors //function y6() { } //import y6 = require(''); diff --git a/tests/baselines/reference/augmentedTypesModules.js b/tests/baselines/reference/augmentedTypesModules.js index 3b7544996a..558ea6609f 100644 --- a/tests/baselines/reference/augmentedTypesModules.js +++ b/tests/baselines/reference/augmentedTypesModules.js @@ -115,51 +115,43 @@ var m1d; var I = (function () { function I() { } - I.prototype.foo = function () { - }; + I.prototype.foo = function () { }; return I; })(); m1d.I = I; })(m1d || (m1d = {})); var m1d = 1; // error -function m2() { -} +function m2() { } ; // ok since the module is not instantiated var m2a; (function (m2a) { var y = 2; })(m2a || (m2a = {})); -function m2a() { -} +function m2a() { } ; // error since the module is instantiated var m2b; (function (m2b) { m2b.y = 2; })(m2b || (m2b = {})); -function m2b() { -} +function m2b() { } ; // error since the module is instantiated // should be errors to have function first -function m2c() { -} +function m2c() { } ; var m2c; (function (m2c) { m2c.y = 2; })(m2c || (m2c = {})); -function m2f() { -} +function m2f() { } ; -function m2g() { -} +function m2g() { } ; var m2g; (function (m2g) { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); m2g.C = C; @@ -176,15 +168,13 @@ var m3a; var m3a = (function () { function m3a() { } - m3a.prototype.foo = function () { - }; + m3a.prototype.foo = function () { }; return m3a; })(); // error, class isn't ambient or declared before the module var m3b = (function () { function m3b() { } - m3b.prototype.foo = function () { - }; + m3b.prototype.foo = function () { }; return m3b; })(); var m3b; @@ -194,8 +184,7 @@ var m3b; var m3c = (function () { function m3c() { } - m3c.prototype.foo = function () { - }; + m3c.prototype.foo = function () { }; return m3c; })(); var m3c; @@ -215,8 +204,7 @@ var m3g; var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); m3g.C = C; @@ -249,8 +237,7 @@ var m4d; var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); })(m4d || (m4d = {})); diff --git a/tests/baselines/reference/augmentedTypesModules2.js b/tests/baselines/reference/augmentedTypesModules2.js index 70fd31f03e..5cc805a848 100644 --- a/tests/baselines/reference/augmentedTypesModules2.js +++ b/tests/baselines/reference/augmentedTypesModules2.js @@ -29,25 +29,21 @@ module m2g { export class C { foo() { } } } //// [augmentedTypesModules2.js] -function m2() { -} +function m2() { } ; // ok since the module is not instantiated var m2a; (function (m2a) { var y = 2; })(m2a || (m2a = {})); -function m2a() { -} +function m2a() { } ; // error since the module is instantiated var m2b; (function (m2b) { m2b.y = 2; })(m2b || (m2b = {})); -function m2b() { -} +function m2b() { } ; // error since the module is instantiated -function m2c() { -} +function m2c() { } ; var m2c; (function (m2c) { @@ -57,22 +53,18 @@ var m2cc; (function (m2cc) { m2cc.y = 2; })(m2cc || (m2cc = {})); -function m2cc() { -} +function m2cc() { } ; // error to have module first -function m2f() { -} +function m2f() { } ; -function m2g() { -} +function m2g() { } ; var m2g; (function (m2g) { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); m2g.C = C; diff --git a/tests/baselines/reference/augmentedTypesModules3.js b/tests/baselines/reference/augmentedTypesModules3.js index 7f5c390ea3..fb1c7ef6e7 100644 --- a/tests/baselines/reference/augmentedTypesModules3.js +++ b/tests/baselines/reference/augmentedTypesModules3.js @@ -19,7 +19,6 @@ var m3a; var m3a = (function () { function m3a() { } - m3a.prototype.foo = function () { - }; + m3a.prototype.foo = function () { }; return m3a; })(); // error, class isn't ambient or declared before the module diff --git a/tests/baselines/reference/augmentedTypesModules3b.js b/tests/baselines/reference/augmentedTypesModules3b.js index 2d250ab282..080a5e72ad 100644 --- a/tests/baselines/reference/augmentedTypesModules3b.js +++ b/tests/baselines/reference/augmentedTypesModules3b.js @@ -22,8 +22,7 @@ module m3g { export class C { foo() { } } } var m3b = (function () { function m3b() { } - m3b.prototype.foo = function () { - }; + m3b.prototype.foo = function () { }; return m3b; })(); var m3b; @@ -33,8 +32,7 @@ var m3b; var m3c = (function () { function m3c() { } - m3c.prototype.foo = function () { - }; + m3c.prototype.foo = function () { }; return m3c; })(); var m3c; @@ -54,8 +52,7 @@ var m3g; var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); m3g.C = C; diff --git a/tests/baselines/reference/augmentedTypesModules4.js b/tests/baselines/reference/augmentedTypesModules4.js index f8407e2e36..82f08851ef 100644 --- a/tests/baselines/reference/augmentedTypesModules4.js +++ b/tests/baselines/reference/augmentedTypesModules4.js @@ -51,8 +51,7 @@ var m4d; var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); })(m4d || (m4d = {})); diff --git a/tests/baselines/reference/augmentedTypesVar.js b/tests/baselines/reference/augmentedTypesVar.js index f4404cecb3..b4e412acc0 100644 --- a/tests/baselines/reference/augmentedTypesVar.js +++ b/tests/baselines/reference/augmentedTypesVar.js @@ -42,11 +42,9 @@ var x1 = 1; var x1 = 2; // var then function var x2 = 1; // error -function x2() { -} // error +function x2() { } // error var x3 = 1; -var x3 = function () { -}; // error +var x3 = function () { }; // error // var then class var x4 = 1; // error var x4 = (function () { @@ -58,8 +56,7 @@ var x4a = 1; // error var x4a = (function () { function x4a() { } - x4a.prototype.foo = function () { - }; + x4a.prototype.foo = function () { }; return x4a; })(); // error // var then enum diff --git a/tests/baselines/reference/autoLift2.js b/tests/baselines/reference/autoLift2.js index 45790dc2f6..cf840277d7 100644 --- a/tests/baselines/reference/autoLift2.js +++ b/tests/baselines/reference/autoLift2.js @@ -43,18 +43,8 @@ var A = (function () { var _this = this; this.foo = "foo"; this.bar = "bar"; - [ - 1, - 2 - ].forEach(function (p) { - return _this.foo; - }); - [ - 1, - 2 - ].forEach(function (p) { - return _this.bar; - }); + [1, 2].forEach(function (p) { return _this.foo; }); + [1, 2].forEach(function (p) { return _this.bar; }); }; return A; })(); diff --git a/tests/baselines/reference/autolift3.js b/tests/baselines/reference/autolift3.js index cc3bcaaae9..e04501daf4 100644 --- a/tests/baselines/reference/autolift3.js +++ b/tests/baselines/reference/autolift3.js @@ -33,8 +33,7 @@ b.foo(); //// [autolift3.js] var B = (function () { function B() { - function foo() { - } + function foo() { } foo(); var a = 0; var inner = (function () { diff --git a/tests/baselines/reference/bestCommonTypeOfConditionalExpressions.js b/tests/baselines/reference/bestCommonTypeOfConditionalExpressions.js index 69fe778c04..49bc535dbf 100644 --- a/tests/baselines/reference/bestCommonTypeOfConditionalExpressions.js +++ b/tests/baselines/reference/bestCommonTypeOfConditionalExpressions.js @@ -63,15 +63,9 @@ var r = true ? 1 : 2; var r3 = true ? 1 : {}; var r4 = true ? a : b; // typeof a var r5 = true ? b : a; // typeof b -var r6 = true ? function (x) { -} : function (x) { -}; // returns number => void -var r7 = true ? function (x) { -} : function (x) { -}; -var r8 = true ? function (x) { -} : function (x) { -}; // returns Object => void +var r6 = true ? function (x) { } : function (x) { }; // returns number => void +var r7 = true ? function (x) { } : function (x) { }; +var r8 = true ? function (x) { } : function (x) { }; // returns Object => void var r10 = true ? derived : derived2; // no error since we use the contextual type in BCT var r11 = true ? base : derived2; function foo5(t, u) { diff --git a/tests/baselines/reference/bestCommonTypeOfTuple.js b/tests/baselines/reference/bestCommonTypeOfTuple.js index d5cbe7e67c..81cfa752f5 100644 --- a/tests/baselines/reference/bestCommonTypeOfTuple.js +++ b/tests/baselines/reference/bestCommonTypeOfTuple.js @@ -26,15 +26,9 @@ var e3 = t3[2]; // any var e4 = t4[3]; // number //// [bestCommonTypeOfTuple.js] -function f1(x) { - return "foo"; -} -function f2(x) { - return 10; -} -function f3(x) { - return true; -} +function f1(x) { return "foo"; } +function f2(x) { return 10; } +function f3(x) { return true; } var E1; (function (E1) { E1[E1["one"] = 0] = "one"; @@ -48,23 +42,10 @@ var t2; var t3; var t4; // no error -t1 = [ - f1, - f2 -]; -t2 = [ - E1.one, - E2.two -]; -t3 = [ - 5, - undefined -]; -t4 = [ - E1.one, - E2.two, - 20 -]; +t1 = [f1, f2]; +t2 = [E1.one, E2.two]; +t3 = [5, undefined]; +t4 = [E1.one, E2.two, 20]; var e1 = t1[2]; // {} var e2 = t2[2]; // {} var e3 = t3[2]; // any diff --git a/tests/baselines/reference/bestCommonTypeReturnStatement.js b/tests/baselines/reference/bestCommonTypeReturnStatement.js index 232ffc07c5..f4ab98ed1c 100644 --- a/tests/baselines/reference/bestCommonTypeReturnStatement.js +++ b/tests/baselines/reference/bestCommonTypeReturnStatement.js @@ -18,9 +18,5 @@ function f() { return b(); return d(); } -function b() { - return null; -} -function d() { - return null; -} +function b() { return null; } +function d() { return null; } diff --git a/tests/baselines/reference/bestCommonTypeWithContextualTyping.js b/tests/baselines/reference/bestCommonTypeWithContextualTyping.js index afe18e3f28..c45ae88458 100644 --- a/tests/baselines/reference/bestCommonTypeWithContextualTyping.js +++ b/tests/baselines/reference/bestCommonTypeWithContextualTyping.js @@ -25,11 +25,7 @@ var e; // All of these should pass. Neither type is a supertype of the other, but the RHS should // always use Ellement in these examples (not Contextual). Because Ellement is assignable // to Contextual, no errors. -var arr = [ - e -]; // Ellement[] -var obj = { - s: e -}; // { s: Ellement; [s: string]: Ellement } +var arr = [e]; // Ellement[] +var obj = { s: e }; // { s: Ellement; [s: string]: Ellement } var conditional = null ? e : e; // Ellement var contextualOr = e || e; // Ellement diff --git a/tests/baselines/reference/bestCommonTypeWithOptionalProperties.js b/tests/baselines/reference/bestCommonTypeWithOptionalProperties.js index 6a8741097a..25622c3d4f 100644 --- a/tests/baselines/reference/bestCommonTypeWithOptionalProperties.js +++ b/tests/baselines/reference/bestCommonTypeWithOptionalProperties.js @@ -20,33 +20,9 @@ var x; var y; var z; // All these arrays should be X[] -var b1 = [ - x, - y, - z -]; -var b2 = [ - x, - z, - y -]; -var b3 = [ - y, - x, - z -]; -var b4 = [ - y, - z, - x -]; -var b5 = [ - z, - x, - y -]; -var b6 = [ - z, - y, - x -]; +var b1 = [x, y, z]; +var b2 = [x, z, y]; +var b3 = [y, x, z]; +var b4 = [y, z, x]; +var b5 = [z, x, y]; +var b6 = [z, y, x]; diff --git a/tests/baselines/reference/bitwiseNotOperatorInvalidOperations.js b/tests/baselines/reference/bitwiseNotOperatorInvalidOperations.js index b730569bd6..1b64091c04 100644 --- a/tests/baselines/reference/bitwiseNotOperatorInvalidOperations.js +++ b/tests/baselines/reference/bitwiseNotOperatorInvalidOperations.js @@ -18,11 +18,7 @@ var q; var a = q; ~; //expect error // multiple operands after ~ -var mul = ~[ - 1, - 2, - "abc" -]; +var mul = ~[1, 2, "abc"]; ""; //expect error // miss an operand var b = ~; diff --git a/tests/baselines/reference/bitwiseNotOperatorWithAnyOtherType.js b/tests/baselines/reference/bitwiseNotOperatorWithAnyOtherType.js index a73d851668..3ee3f28ad9 100644 --- a/tests/baselines/reference/bitwiseNotOperatorWithAnyOtherType.js +++ b/tests/baselines/reference/bitwiseNotOperatorWithAnyOtherType.js @@ -66,16 +66,9 @@ var ResultIsNumber20 = ~~~(ANY + ANY1); // ~ operator on any type var ANY; var ANY1; -var ANY2 = [ - "", - "" -]; +var ANY2 = ["", ""]; var obj; -var obj1 = { - x: "", - y: function () { - } -}; +var obj1 = { x: "", y: function () { } }; function foo() { var a; return a; diff --git a/tests/baselines/reference/bitwiseNotOperatorWithBooleanType.js b/tests/baselines/reference/bitwiseNotOperatorWithBooleanType.js index 1b2c93307d..fb573a7523 100644 --- a/tests/baselines/reference/bitwiseNotOperatorWithBooleanType.js +++ b/tests/baselines/reference/bitwiseNotOperatorWithBooleanType.js @@ -41,15 +41,11 @@ var ResultIsNumber8 = ~~BOOLEAN; //// [bitwiseNotOperatorWithBooleanType.js] // ~ operator on boolean type var BOOLEAN; -function foo() { - return true; -} +function foo() { return true; } var A = (function () { function A() { } - A.foo = function () { - return false; - }; + A.foo = function () { return false; }; return A; })(); var M; @@ -61,10 +57,7 @@ var objA = new A(); var ResultIsNumber1 = ~BOOLEAN; // boolean type literal var ResultIsNumber2 = ~true; -var ResultIsNumber3 = ~{ - x: true, - y: false -}; +var ResultIsNumber3 = ~{ x: true, y: false }; // boolean type expressions var ResultIsNumber4 = ~objA.a; var ResultIsNumber5 = ~M.n; diff --git a/tests/baselines/reference/bitwiseNotOperatorWithNumberType.js b/tests/baselines/reference/bitwiseNotOperatorWithNumberType.js index ac274bf8c1..ac439f0290 100644 --- a/tests/baselines/reference/bitwiseNotOperatorWithNumberType.js +++ b/tests/baselines/reference/bitwiseNotOperatorWithNumberType.js @@ -47,19 +47,12 @@ var ResultIsNumber13 = ~~~(NUMBER + NUMBER); //// [bitwiseNotOperatorWithNumberType.js] // ~ operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; -function foo() { - return 1; -} +var NUMBER1 = [1, 2]; +function foo() { return 1; } var A = (function () { function A() { } - A.foo = function () { - return 1; - }; + A.foo = function () { return 1; }; return A; })(); var M; @@ -72,16 +65,8 @@ var ResultIsNumber1 = ~NUMBER; var ResultIsNumber2 = ~NUMBER1; // number type literal var ResultIsNumber3 = ~1; -var ResultIsNumber4 = ~{ - x: 1, - y: 2 -}; -var ResultIsNumber5 = ~{ - x: 1, - y: function (n) { - return n; - } -}; +var ResultIsNumber4 = ~{ x: 1, y: 2 }; +var ResultIsNumber5 = ~{ x: 1, y: function (n) { return n; } }; // number type expressions var ResultIsNumber6 = ~objA.a; var ResultIsNumber7 = ~M.n; diff --git a/tests/baselines/reference/bitwiseNotOperatorWithStringType.js b/tests/baselines/reference/bitwiseNotOperatorWithStringType.js index f13cf39bd6..a553712e16 100644 --- a/tests/baselines/reference/bitwiseNotOperatorWithStringType.js +++ b/tests/baselines/reference/bitwiseNotOperatorWithStringType.js @@ -46,19 +46,12 @@ var ResultIsNumber14 = ~~~(STRING + STRING); //// [bitwiseNotOperatorWithStringType.js] // ~ operator on string type var STRING; -var STRING1 = [ - "", - "abc" -]; -function foo() { - return "abc"; -} +var STRING1 = ["", "abc"]; +function foo() { return "abc"; } var A = (function () { function A() { } - A.foo = function () { - return ""; - }; + A.foo = function () { return ""; }; return A; })(); var M; @@ -71,16 +64,8 @@ var ResultIsNumber1 = ~STRING; var ResultIsNumber2 = ~STRING1; // string type literal var ResultIsNumber3 = ~""; -var ResultIsNumber4 = ~{ - x: "", - y: "" -}; -var ResultIsNumber5 = ~{ - x: "", - y: function (s) { - return s; - } -}; +var ResultIsNumber4 = ~{ x: "", y: "" }; +var ResultIsNumber5 = ~{ x: "", y: function (s) { return s; } }; // string type expressions var ResultIsNumber6 = ~objA.a; var ResultIsNumber7 = ~M.n; diff --git a/tests/baselines/reference/callGenericFunctionWithIncorrectNumberOfTypeArguments.js b/tests/baselines/reference/callGenericFunctionWithIncorrectNumberOfTypeArguments.js index 59bfabd21d..f1028956e1 100644 --- a/tests/baselines/reference/callGenericFunctionWithIncorrectNumberOfTypeArguments.js +++ b/tests/baselines/reference/callGenericFunctionWithIncorrectNumberOfTypeArguments.js @@ -47,14 +47,10 @@ var r7b = i2.f(1, ''); //// [callGenericFunctionWithIncorrectNumberOfTypeArguments.js] // type parameter lists must exactly match type argument lists // all of these invocations are errors -function f(x, y) { - return null; -} +function f(x, y) { return null; } var r1 = f(1, ''); var r1b = f(1, ''); -var f2 = function (x, y) { - return null; -}; +var f2 = function (x, y) { return null; }; var r2 = f2(1, ''); var r2b = f2(1, ''); var f3; diff --git a/tests/baselines/reference/callGenericFunctionWithZeroTypeArguments.js b/tests/baselines/reference/callGenericFunctionWithZeroTypeArguments.js index 04edc93f5d..26b9d33a55 100644 --- a/tests/baselines/reference/callGenericFunctionWithZeroTypeArguments.js +++ b/tests/baselines/reference/callGenericFunctionWithZeroTypeArguments.js @@ -38,13 +38,9 @@ var r7 = i2.f(1); //// [callGenericFunctionWithZeroTypeArguments.js] // valid invocations of generic functions with no explicit type arguments provided -function f(x) { - return null; -} +function f(x) { return null; } var r = f(1); -var f2 = function (x) { - return null; -}; +var f2 = function (x) { return null; }; var r2 = f2(1); var f3; var r3 = f3(1); diff --git a/tests/baselines/reference/callNonGenericFunctionWithTypeArguments.js b/tests/baselines/reference/callNonGenericFunctionWithTypeArguments.js index 306b4c7036..7b0355533e 100644 --- a/tests/baselines/reference/callNonGenericFunctionWithTypeArguments.js +++ b/tests/baselines/reference/callNonGenericFunctionWithTypeArguments.js @@ -46,13 +46,9 @@ var r8 = a2(); //// [callNonGenericFunctionWithTypeArguments.js] // it is always illegal to provide type arguments to a non-generic function // all invocations here are illegal -function f(x) { - return null; -} +function f(x) { return null; } var r = f(1); -var f2 = function (x) { - return null; -}; +var f2 = function (x) { return null; }; var r2 = f2(1); var f3; var r3 = f3(1); diff --git a/tests/baselines/reference/callOverloads1.js b/tests/baselines/reference/callOverloads1.js index 86cb951f85..b1148c1242 100644 --- a/tests/baselines/reference/callOverloads1.js +++ b/tests/baselines/reference/callOverloads1.js @@ -22,13 +22,10 @@ var Foo = (function () { function Foo(x) { // WScript.Echo("Constructor function has executed"); } - Foo.prototype.bar1 = function () { - }; + Foo.prototype.bar1 = function () { }; return Foo; })(); -function F1(a) { - return a; -} +function F1(a) { return a; } var f1 = new Foo("hey"); f1.bar1(); Foo(); diff --git a/tests/baselines/reference/callOverloads2.js b/tests/baselines/reference/callOverloads2.js index e3cbceb177..b336911eeb 100644 --- a/tests/baselines/reference/callOverloads2.js +++ b/tests/baselines/reference/callOverloads2.js @@ -30,16 +30,11 @@ var Foo = (function () { function Foo(x) { // WScript.Echo("Constructor function has executed"); } - Foo.prototype.bar1 = function () { - }; + Foo.prototype.bar1 = function () { }; return Foo; })(); -function F1(s) { - return s; -} // error -function F1(a) { - return a; -} // error +function F1(s) { return s; } // error +function F1(a) { return a; } // error var f1 = new Foo("hey"); f1.bar1(); Foo(); diff --git a/tests/baselines/reference/callOverloads3.js b/tests/baselines/reference/callOverloads3.js index 85c16fe85a..3b615438cc 100644 --- a/tests/baselines/reference/callOverloads3.js +++ b/tests/baselines/reference/callOverloads3.js @@ -23,8 +23,7 @@ var Foo = (function () { function Foo(x) { // WScript.Echo("Constructor function has executed"); } - Foo.prototype.bar1 = function () { - }; + Foo.prototype.bar1 = function () { }; return Foo; })(); //class Foo(s: String); diff --git a/tests/baselines/reference/callOverloads4.js b/tests/baselines/reference/callOverloads4.js index 6aab555b72..529b63ad3b 100644 --- a/tests/baselines/reference/callOverloads4.js +++ b/tests/baselines/reference/callOverloads4.js @@ -23,8 +23,7 @@ var Foo = (function () { function Foo(x) { // WScript.Echo("Constructor function has executed"); } - Foo.prototype.bar1 = function () { - }; + Foo.prototype.bar1 = function () { }; return Foo; })(); var f1 = new Foo("hey"); diff --git a/tests/baselines/reference/callOverloads5.js b/tests/baselines/reference/callOverloads5.js index 2220568e4c..dc508b3b8e 100644 --- a/tests/baselines/reference/callOverloads5.js +++ b/tests/baselines/reference/callOverloads5.js @@ -24,8 +24,7 @@ var Foo = (function () { function Foo(x) { // WScript.Echo("Constructor function has executed"); } - Foo.prototype.bar1 = function (a) { - }; + Foo.prototype.bar1 = function (a) { }; return Foo; })(); //class Foo(s: String); diff --git a/tests/baselines/reference/callSignatureWithoutAnnotationsOrBody.js b/tests/baselines/reference/callSignatureWithoutAnnotationsOrBody.js index 6daa62f83a..24c71c9850 100644 --- a/tests/baselines/reference/callSignatureWithoutAnnotationsOrBody.js +++ b/tests/baselines/reference/callSignatureWithoutAnnotationsOrBody.js @@ -21,8 +21,7 @@ var r5 = a.f(); //// [callSignatureWithoutAnnotationsOrBody.js] // Call signatures without a return type annotation and function body return 'any' -function foo(x) { -} +function foo(x) { } var r = foo(1); // void since there's a body var i; var r2 = i(); diff --git a/tests/baselines/reference/callSignatureWithoutReturnTypeAnnotationInference.js b/tests/baselines/reference/callSignatureWithoutReturnTypeAnnotationInference.js index f37d4c0686..0e78aac2b1 100644 --- a/tests/baselines/reference/callSignatureWithoutReturnTypeAnnotationInference.js +++ b/tests/baselines/reference/callSignatureWithoutReturnTypeAnnotationInference.js @@ -165,9 +165,7 @@ function foo7(x) { var r7 = foo7(1); // object types function foo8(x) { - return { - x: x - }; + return { x: x }; } var r8 = foo8(1); function foo9(x) { @@ -204,9 +202,7 @@ function foo12() { return i2; } var r12 = foo12(); -function m1() { - return 1; -} +function m1() { return 1; } var m1; (function (m1) { m1.y = 2; diff --git a/tests/baselines/reference/callSignaturesWithAccessibilityModifiersOnParameters.js b/tests/baselines/reference/callSignaturesWithAccessibilityModifiersOnParameters.js index 22b312e257..5584dd7b21 100644 --- a/tests/baselines/reference/callSignaturesWithAccessibilityModifiersOnParameters.js +++ b/tests/baselines/reference/callSignaturesWithAccessibilityModifiersOnParameters.js @@ -40,43 +40,27 @@ var b = { //// [callSignaturesWithAccessibilityModifiersOnParameters.js] // Call signature parameters do not allow accessibility modifiers -function foo(x, y) { -} -var f = function foo(x, y) { -}; -var f2 = function (x, y) { -}; -var f3 = function (x, y) { -}; -var f4 = function (x, y) { -}; -function foo2(x, y) { -} -var f5 = function foo(x, y) { -}; -var f6 = function (x, y) { -}; -var f7 = function (x, y) { -}; -var f8 = function (x, y) { -}; +function foo(x, y) { } +var f = function foo(x, y) { }; +var f2 = function (x, y) { }; +var f3 = function (x, y) { }; +var f4 = function (x, y) { }; +function foo2(x, y) { } +var f5 = function foo(x, y) { }; +var f6 = function (x, y) { }; +var f7 = function (x, y) { }; +var f8 = function (x, y) { }; var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - }; - C.prototype.foo2 = function (x, y) { - }; - C.prototype.foo3 = function (x, y) { - }; + C.prototype.foo = function (x, y) { }; + C.prototype.foo2 = function (x, y) { }; + C.prototype.foo3 = function (x, y) { }; return C; })(); var a; var b = { - foo: function (x, y) { - }, - a: function foo(x, y) { - }, - b: function (x, y) { - } + foo: function (x, y) { }, + a: function foo(x, y) { }, + b: function (x, y) { } }; diff --git a/tests/baselines/reference/callSignaturesWithDuplicateParameters.js b/tests/baselines/reference/callSignaturesWithDuplicateParameters.js index 49e20266da..6ed7f6f7fe 100644 --- a/tests/baselines/reference/callSignaturesWithDuplicateParameters.js +++ b/tests/baselines/reference/callSignaturesWithDuplicateParameters.js @@ -40,43 +40,27 @@ var b = { //// [callSignaturesWithDuplicateParameters.js] // Duplicate parameter names are always an error -function foo(x, x) { -} -var f = function foo(x, x) { -}; -var f2 = function (x, x) { -}; -var f3 = function (x, x) { -}; -var f4 = function (x, x) { -}; -function foo2(x, x) { -} -var f5 = function foo(x, x) { -}; -var f6 = function (x, x) { -}; -var f7 = function (x, x) { -}; -var f8 = function (x, y) { -}; +function foo(x, x) { } +var f = function foo(x, x) { }; +var f2 = function (x, x) { }; +var f3 = function (x, x) { }; +var f4 = function (x, x) { }; +function foo2(x, x) { } +var f5 = function foo(x, x) { }; +var f6 = function (x, x) { }; +var f7 = function (x, x) { }; +var f8 = function (x, y) { }; var C = (function () { function C() { } - C.prototype.foo = function (x, x) { - }; - C.prototype.foo2 = function (x, x) { - }; - C.prototype.foo3 = function (x, x) { - }; + C.prototype.foo = function (x, x) { }; + C.prototype.foo2 = function (x, x) { }; + C.prototype.foo3 = function (x, x) { }; return C; })(); var a; var b = { - foo: function (x, x) { - }, - a: function foo(x, x) { - }, - b: function (x, x) { - } + foo: function (x, x) { }, + a: function foo(x, x) { }, + b: function (x, x) { } }; diff --git a/tests/baselines/reference/callSignaturesWithOptionalParameters.js b/tests/baselines/reference/callSignaturesWithOptionalParameters.js index fa2126fb6c..2f4876fb2d 100644 --- a/tests/baselines/reference/callSignaturesWithOptionalParameters.js +++ b/tests/baselines/reference/callSignaturesWithOptionalParameters.js @@ -57,12 +57,9 @@ b.b(1); //// [callSignaturesWithOptionalParameters.js] // Optional parameters should be valid in all the below casts -function foo(x) { -} -var f = function foo(x) { -}; -var f2 = function (x, y) { -}; +function foo(x) { } +var f = function foo(x) { }; +var f2 = function (x, y) { }; foo(1); foo(); f(1); @@ -72,8 +69,7 @@ f2(1, 2); var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; + C.prototype.foo = function (x) { }; return C; })(); var c; @@ -90,12 +86,9 @@ a(1); a.foo(); a.foo(1); var b = { - foo: function (x) { - }, - a: function foo(x, y) { - }, - b: function (x) { - } + foo: function (x) { }, + a: function foo(x, y) { }, + b: function (x) { } }; b.foo(); b.foo(1); diff --git a/tests/baselines/reference/callSignaturesWithOptionalParameters2.js b/tests/baselines/reference/callSignaturesWithOptionalParameters2.js index 95ecb3a0e9..a3fb2fe7a8 100644 --- a/tests/baselines/reference/callSignaturesWithOptionalParameters2.js +++ b/tests/baselines/reference/callSignaturesWithOptionalParameters2.js @@ -61,21 +61,17 @@ a.foo(1, 2, 3); //// [callSignaturesWithOptionalParameters2.js] // Optional parameters should be valid in all the below casts -function foo(x) { -} +function foo(x) { } foo(1); foo(); -function foo2(x, y) { -} +function foo2(x, y) { } foo2(1); foo2(1, 2); var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; - C.prototype.foo2 = function (x, y) { - }; + C.prototype.foo = function (x) { }; + C.prototype.foo2 = function (x, y) { }; return C; })(); var c; diff --git a/tests/baselines/reference/callWithSpread.js b/tests/baselines/reference/callWithSpread.js index 4cb52f41d3..d676c0f2a3 100644 --- a/tests/baselines/reference/callWithSpread.js +++ b/tests/baselines/reference/callWithSpread.js @@ -82,11 +82,7 @@ obj.foo.apply(obj, [1, 2].concat(a, ["abc"])); xa[1].foo(1, 2, "abc"); (_a = xa[1]).foo.apply(_a, [1, 2].concat(a)); (_b = xa[1]).foo.apply(_b, [1, 2].concat(a, ["abc"])); -(_c = xa[1]).foo.apply(_c, [ - 1, - 2, - "abc" -]); +(_c = xa[1]).foo.apply(_c, [1, 2, "abc"]); var C = (function () { function C(x, y) { var z = []; diff --git a/tests/baselines/reference/callWithSpreadES6.js b/tests/baselines/reference/callWithSpreadES6.js index d1589d7f6f..d6a915f5f3 100644 --- a/tests/baselines/reference/callWithSpreadES6.js +++ b/tests/baselines/reference/callWithSpreadES6.js @@ -73,11 +73,7 @@ obj.foo(1, 2, ...a, "abc"); xa[1].foo(1, 2, "abc"); xa[1].foo(1, 2, ...a); xa[1].foo(1, 2, ...a, "abc"); -xa[1].foo(...[ - 1, - 2, - "abc" -]); +xa[1].foo(...[1, 2, "abc"]); class C { constructor(x, y, ...z) { this.foo(x, y); diff --git a/tests/baselines/reference/callWithWrongNumberOfTypeArguments.js b/tests/baselines/reference/callWithWrongNumberOfTypeArguments.js index f7bc46a772..74ea401ae3 100644 --- a/tests/baselines/reference/callWithWrongNumberOfTypeArguments.js +++ b/tests/baselines/reference/callWithWrongNumberOfTypeArguments.js @@ -6,8 +6,7 @@ f(); f(); //// [callWithWrongNumberOfTypeArguments.js] -function f() { -} +function f() { } f(); f(); f(); diff --git a/tests/baselines/reference/callbacksDontShareTypes.js b/tests/baselines/reference/callbacksDontShareTypes.js index 649ed1cb6c..e648363805 100644 --- a/tests/baselines/reference/callbacksDontShareTypes.js +++ b/tests/baselines/reference/callbacksDontShareTypes.js @@ -21,14 +21,8 @@ var r5b = _.map(c2, rf1); //// [callbacksDontShareTypes.js] var _; var c2; -var rf1 = function (x) { - return x.toFixed(); -}; -var r1a = _.map(c2, function (x) { - return x.toFixed(); -}); +var rf1 = function (x) { return x.toFixed(); }; +var r1a = _.map(c2, function (x) { return x.toFixed(); }); var r1b = _.map(c2, rf1); // this line should not cause the following 2 to have errors -var r5a = _.map(c2, function (x) { - return x.toFixed(); -}); +var r5a = _.map(c2, function (x) { return x.toFixed(); }); var r5b = _.map(c2, rf1); diff --git a/tests/baselines/reference/captureThisInSuperCall.js b/tests/baselines/reference/captureThisInSuperCall.js index cbb41afea3..7200fabd8c 100644 --- a/tests/baselines/reference/captureThisInSuperCall.js +++ b/tests/baselines/reference/captureThisInSuperCall.js @@ -24,13 +24,8 @@ var B = (function (_super) { __extends(B, _super); function B() { var _this = this; - _super.call(this, { - test: function () { - return _this.someMethod(); - } - }); + _super.call(this, { test: function () { return _this.someMethod(); } }); } - B.prototype.someMethod = function () { - }; + B.prototype.someMethod = function () { }; return B; })(A); diff --git a/tests/baselines/reference/castExpressionParentheses.js b/tests/baselines/reference/castExpressionParentheses.js index c217b5e7b2..ec18d6e373 100644 --- a/tests/baselines/reference/castExpressionParentheses.js +++ b/tests/baselines/reference/castExpressionParentheses.js @@ -42,13 +42,8 @@ new (A()); //// [castExpressionParentheses.js] // parentheses should be omitted // literals -{ - a: 0 -}; -[ - 1, - 3, -]; +{ a: 0 }; +[1, 3,]; "string"; 23.0; /regexp/g; @@ -68,10 +63,8 @@ a().x; (typeof A).x; (-A).x; new (A()); -(function () { -})(); -(function foo() { -})(); +(function () { })(); +(function foo() { })(); (-A).x; // nested cast, should keep one pair of parenthese (-A).x; diff --git a/tests/baselines/reference/castTest.js b/tests/baselines/reference/castTest.js index 5afa67026b..ef9ef084d9 100644 --- a/tests/baselines/reference/castTest.js +++ b/tests/baselines/reference/castTest.js @@ -47,7 +47,5 @@ var p_cast = ({ add: function (dx, dy) { return new Point(this.x + dx, this.y + dy); }, - mult: function (p) { - return p; - } + mult: function (p) { return p; } }); diff --git a/tests/baselines/reference/castingTuple.js b/tests/baselines/reference/castingTuple.js index e615590ea7..2c41d81cd6 100644 --- a/tests/baselines/reference/castingTuple.js +++ b/tests/baselines/reference/castingTuple.js @@ -82,39 +82,20 @@ var E2; E2[E2["one"] = 0] = "one"; })(E2 || (E2 = {})); // no error -var numStrTuple = [ - 5, - "foo" -]; +var numStrTuple = [5, "foo"]; var emptyObjTuple = numStrTuple; var numStrBoolTuple = numStrTuple; -var classCDTuple = [ - new C(), - new D() -]; +var classCDTuple = [new C(), new D()]; var interfaceIITuple = classCDTuple; var classCDATuple = classCDTuple; var eleFromCDA1 = classCDATuple[2]; // A var eleFromCDA2 = classCDATuple[5]; // C | D | A -var t10 = [ - E1.one, - E2.one -]; +var t10 = [E1.one, E2.one]; var t11 = t10; var array1 = emptyObjTuple; -var unionTuple = [ - new C(), - "foo" -]; -var unionTuple2 = [ - new C(), - "foo", - new D() -]; -var unionTuple3 = [ - 10, - "foo" -]; +var unionTuple = [new C(), "foo"]; +var unionTuple2 = [new C(), "foo", new D()]; +var unionTuple3 = [10, "foo"]; var unionTuple4 = unionTuple3; // error var t3 = numStrTuple; diff --git a/tests/baselines/reference/catch.js b/tests/baselines/reference/catch.js index c6b13cf4d6..d3babf1f31 100644 --- a/tests/baselines/reference/catch.js +++ b/tests/baselines/reference/catch.js @@ -7,12 +7,8 @@ function f() { //// [catch.js] function f() { - try { - } - catch (e) { - } - try { - } - catch (e) { - } + try { } + catch (e) { } + try { } + catch (e) { } } diff --git a/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter.js b/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter.js index 3795994c64..70456b9e9d 100644 --- a/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter.js +++ b/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter.js @@ -55,12 +55,4 @@ var C = (function (_super) { return C; })(B); // Ok to go down the chain, but error to try to climb back up -(new Chain(new A)).then(function (a) { - return new B; -}).then(function (b) { - return new C; -}).then(function (c) { - return new B; -}).then(function (b) { - return new A; -}); +(new Chain(new A)).then(function (a) { return new B; }).then(function (b) { return new C; }).then(function (c) { return new B; }).then(function (b) { return new A; }); diff --git a/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter2.js b/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter2.js index dbf55d4ec3..3b9b8b80ec 100644 --- a/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter2.js +++ b/tests/baselines/reference/chainedCallsWithTypeParameterConstrainedToOtherTypeParameter2.js @@ -50,30 +50,12 @@ var Chain = (function () { var t; var s; // Ok to go down the chain, but error to climb up the chain - (new Chain(t)).then(function (tt) { - return s; - }).then(function (ss) { - return t; - }); + (new Chain(t)).then(function (tt) { return s; }).then(function (ss) { return t; }); // But error to try to climb up the chain - (new Chain(s)).then(function (ss) { - return t; - }); + (new Chain(s)).then(function (ss) { return t; }); // Staying at T or S should be fine - (new Chain(t)).then(function (tt) { - return t; - }).then(function (tt) { - return t; - }).then(function (tt) { - return t; - }); - (new Chain(s)).then(function (ss) { - return s; - }).then(function (ss) { - return s; - }).then(function (ss) { - return s; - }); + (new Chain(t)).then(function (tt) { return t; }).then(function (tt) { return t; }).then(function (tt) { return t; }); + (new Chain(s)).then(function (ss) { return s; }).then(function (ss) { return s; }).then(function (ss) { return s; }); return null; }; return Chain; @@ -88,31 +70,11 @@ var Chain2 = (function () { var s; // Ok to go down the chain, check the constraint at the end. // Should get an error that we are assigning a string to a number - (new Chain2(i)).then(function (ii) { - return t; - }).then(function (tt) { - return s; - }).value.x = ""; + (new Chain2(i)).then(function (ii) { return t; }).then(function (tt) { return s; }).value.x = ""; // Staying at T or S should keep the constraint. // Get an error when we assign a string to a number in both cases - (new Chain2(i)).then(function (ii) { - return t; - }).then(function (tt) { - return t; - }).then(function (tt) { - return t; - }).then(function (tt) { - return t; - }).value.x = ""; - (new Chain2(i)).then(function (ii) { - return s; - }).then(function (ss) { - return s; - }).then(function (ss) { - return s; - }).then(function (ss) { - return s; - }).value.x = ""; + (new Chain2(i)).then(function (ii) { return t; }).then(function (tt) { return t; }).then(function (tt) { return t; }).then(function (tt) { return t; }).value.x = ""; + (new Chain2(i)).then(function (ii) { return s; }).then(function (ss) { return s; }).then(function (ss) { return s; }).then(function (ss) { return s; }).value.x = ""; return null; }; return Chain2; diff --git a/tests/baselines/reference/chainedImportAlias.js b/tests/baselines/reference/chainedImportAlias.js index f2b3c6c6cf..077a92d745 100644 --- a/tests/baselines/reference/chainedImportAlias.js +++ b/tests/baselines/reference/chainedImportAlias.js @@ -14,8 +14,7 @@ y.m.foo(); //// [chainedImportAlias_file0.js] var m; (function (m) { - function foo() { - } + function foo() { } m.foo = foo; })(m = exports.m || (exports.m = {})); //// [chainedImportAlias_file1.js] diff --git a/tests/baselines/reference/chainedSpecializationToObjectTypeLiteral.js b/tests/baselines/reference/chainedSpecializationToObjectTypeLiteral.js index e10a41d9fb..1884967aa9 100644 --- a/tests/baselines/reference/chainedSpecializationToObjectTypeLiteral.js +++ b/tests/baselines/reference/chainedSpecializationToObjectTypeLiteral.js @@ -13,9 +13,5 @@ var s3 = s2.each(x => { x.key /* Type is K, should be number */ }); //// [chainedSpecializationToObjectTypeLiteral.js] var s; -var s2 = s.groupBy(function (s) { - return s.length; -}); -var s3 = s2.each(function (x) { - x.key; /* Type is K, should be number */ -}); +var s2 = s.groupBy(function (s) { return s.length; }); +var s3 = s2.each(function (x) { x.key; /* Type is K, should be number */ }); diff --git a/tests/baselines/reference/classBodyWithStatements.js b/tests/baselines/reference/classBodyWithStatements.js index bae4860f72..2324fe0d79 100644 --- a/tests/baselines/reference/classBodyWithStatements.js +++ b/tests/baselines/reference/classBodyWithStatements.js @@ -25,8 +25,7 @@ var C2 = (function () { } return C2; })(); -function foo() { -} +function foo() { } var x = 1; var y = 2; var C3 = (function () { diff --git a/tests/baselines/reference/classExpression.js b/tests/baselines/reference/classExpression.js index 9d902abbf5..6bcf0f46f7 100644 --- a/tests/baselines/reference/classExpression.js +++ b/tests/baselines/reference/classExpression.js @@ -20,9 +20,7 @@ var C = (function () { return C; })(); var y = { - foo: , - class: C2 -}, _a = void 0; + foo: , class: C2 }, _a = void 0; var M; (function (M) { var z = ; diff --git a/tests/baselines/reference/classExtendingClass.js b/tests/baselines/reference/classExtendingClass.js index 6c7d9fe679..130bf5818e 100644 --- a/tests/baselines/reference/classExtendingClass.js +++ b/tests/baselines/reference/classExtendingClass.js @@ -41,10 +41,8 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.thing = function () { - }; - C.other = function () { - }; + C.prototype.thing = function () { }; + C.other = function () { }; return C; })(); var D = (function (_super) { @@ -62,10 +60,8 @@ var r4 = D.other(); var C2 = (function () { function C2() { } - C2.prototype.thing = function (x) { - }; - C2.other = function (x) { - }; + C2.prototype.thing = function (x) { }; + C2.other = function (x) { }; return C2; })(); var D2 = (function (_super) { diff --git a/tests/baselines/reference/classExtendingPrimitive.js b/tests/baselines/reference/classExtendingPrimitive.js index b69bc3403f..8130181891 100644 --- a/tests/baselines/reference/classExtendingPrimitive.js +++ b/tests/baselines/reference/classExtendingPrimitive.js @@ -69,8 +69,7 @@ var C5a = (function () { return C5a; })(); null; -{ -} +{ } var C6 = (function (_super) { __extends(C6, _super); function C6() { diff --git a/tests/baselines/reference/classExtendingPrimitive2.js b/tests/baselines/reference/classExtendingPrimitive2.js index 9a50793445..06b481dbbf 100644 --- a/tests/baselines/reference/classExtendingPrimitive2.js +++ b/tests/baselines/reference/classExtendingPrimitive2.js @@ -18,5 +18,4 @@ var C5a = (function () { return C5a; })(); null; -{ -} +{ } diff --git a/tests/baselines/reference/classExtendsEveryObjectType.js b/tests/baselines/reference/classExtendsEveryObjectType.js index 2adb974bb2..2ae7ea71ce 100644 --- a/tests/baselines/reference/classExtendsEveryObjectType.js +++ b/tests/baselines/reference/classExtendsEveryObjectType.js @@ -35,8 +35,7 @@ var C2 = (function () { } return C2; })(); -{ -} // error +{ } // error var x; var C3 = (function (_super) { __extends(C3, _super); @@ -56,8 +55,7 @@ var C4 = (function (_super) { } return C4; })(M); // error -function foo() { -} +function foo() { } var C5 = (function (_super) { __extends(C5, _super); function C5() { @@ -71,5 +69,4 @@ var C6 = (function () { return C6; })(); []; -{ -} // error +{ } // error diff --git a/tests/baselines/reference/classExtendsEveryObjectType2.js b/tests/baselines/reference/classExtendsEveryObjectType2.js index f2bcb02fee..7be1313776 100644 --- a/tests/baselines/reference/classExtendsEveryObjectType2.js +++ b/tests/baselines/reference/classExtendsEveryObjectType2.js @@ -9,13 +9,11 @@ var C2 = (function () { } return C2; })(); -{ -} // error +{ } // error var C6 = (function () { function C6() { } return C6; })(); []; -{ -} // error +{ } // error diff --git a/tests/baselines/reference/classExtendsInterfaceThatExtendsClassWithPrivates1.js b/tests/baselines/reference/classExtendsInterfaceThatExtendsClassWithPrivates1.js index ed6e3138b0..907b6bd6fd 100644 --- a/tests/baselines/reference/classExtendsInterfaceThatExtendsClassWithPrivates1.js +++ b/tests/baselines/reference/classExtendsInterfaceThatExtendsClassWithPrivates1.js @@ -19,20 +19,14 @@ var C = (function () { function C() { this.x = 1; } - C.prototype.foo = function (x) { - return x; - }; + C.prototype.foo = function (x) { return x; }; return C; })(); var D2 = (function () { function D2() { this.x = 3; } - D2.prototype.foo = function (x) { - return x; - }; - D2.prototype.other = function (x) { - return x; - }; + D2.prototype.foo = function (x) { return x; }; + D2.prototype.other = function (x) { return x; }; return D2; })(); diff --git a/tests/baselines/reference/classExtendsValidConstructorFunction.js b/tests/baselines/reference/classExtendsValidConstructorFunction.js index a0876e8f70..c2f0f17e53 100644 --- a/tests/baselines/reference/classExtendsValidConstructorFunction.js +++ b/tests/baselines/reference/classExtendsValidConstructorFunction.js @@ -12,8 +12,7 @@ var __extends = this.__extends || function (d, b) { __.prototype = b.prototype; d.prototype = new __(); }; -function foo() { -} +function foo() { } var x = new foo(); // can be used as a constructor function var C = (function (_super) { __extends(C, _super); diff --git a/tests/baselines/reference/classImplementsClass2.js b/tests/baselines/reference/classImplementsClass2.js index 98554944bc..bc4f6b6748 100644 --- a/tests/baselines/reference/classImplementsClass2.js +++ b/tests/baselines/reference/classImplementsClass2.js @@ -23,9 +23,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - return 1; - }; + A.prototype.foo = function () { return 1; }; return A; })(); var C = (function () { diff --git a/tests/baselines/reference/classImplementsClass3.js b/tests/baselines/reference/classImplementsClass3.js index 9dbfc4388e..450263d00c 100644 --- a/tests/baselines/reference/classImplementsClass3.js +++ b/tests/baselines/reference/classImplementsClass3.js @@ -24,9 +24,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - return 1; - }; + A.prototype.foo = function () { return 1; }; return A; })(); var C = (function () { diff --git a/tests/baselines/reference/classImplementsClass4.js b/tests/baselines/reference/classImplementsClass4.js index 0e08e508fb..ac5c899bbb 100644 --- a/tests/baselines/reference/classImplementsClass4.js +++ b/tests/baselines/reference/classImplementsClass4.js @@ -27,9 +27,7 @@ var A = (function () { function A() { this.x = 1; } - A.prototype.foo = function () { - return 1; - }; + A.prototype.foo = function () { return 1; }; return A; })(); var C = (function () { diff --git a/tests/baselines/reference/classImplementsClass5.js b/tests/baselines/reference/classImplementsClass5.js index 46e826683e..a0971904cc 100644 --- a/tests/baselines/reference/classImplementsClass5.js +++ b/tests/baselines/reference/classImplementsClass5.js @@ -28,9 +28,7 @@ var A = (function () { function A() { this.x = 1; } - A.prototype.foo = function () { - return 1; - }; + A.prototype.foo = function () { return 1; }; return A; })(); var C = (function () { diff --git a/tests/baselines/reference/classImplementsClass6.js b/tests/baselines/reference/classImplementsClass6.js index 386cd6685a..931218e2be 100644 --- a/tests/baselines/reference/classImplementsClass6.js +++ b/tests/baselines/reference/classImplementsClass6.js @@ -34,9 +34,7 @@ var A = (function () { A.bar = function () { return ""; }; - A.prototype.foo = function () { - return 1; - }; + A.prototype.foo = function () { return 1; }; return A; })(); var C = (function () { diff --git a/tests/baselines/reference/classImplementsImportedInterface.js b/tests/baselines/reference/classImplementsImportedInterface.js index c76a026b58..a2af2083a2 100644 --- a/tests/baselines/reference/classImplementsImportedInterface.js +++ b/tests/baselines/reference/classImplementsImportedInterface.js @@ -18,8 +18,7 @@ var M2; var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); })(M2 || (M2 = {})); diff --git a/tests/baselines/reference/classMethodWithKeywordName1.js b/tests/baselines/reference/classMethodWithKeywordName1.js index 9b6b7595f0..ba5bb72632 100644 --- a/tests/baselines/reference/classMethodWithKeywordName1.js +++ b/tests/baselines/reference/classMethodWithKeywordName1.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.try = function () { - }; + C.try = function () { }; return C; })(); diff --git a/tests/baselines/reference/classOrder2.js b/tests/baselines/reference/classOrder2.js index 179be45602..4bc1c3f790 100644 --- a/tests/baselines/reference/classOrder2.js +++ b/tests/baselines/reference/classOrder2.js @@ -31,16 +31,13 @@ var A = (function (_super) { function A() { _super.apply(this, arguments); } - A.prototype.foo = function () { - this.bar(); - }; + A.prototype.foo = function () { this.bar(); }; return A; })(B); var B = (function () { function B() { } - B.prototype.bar = function () { - }; + B.prototype.bar = function () { }; return B; })(); var a = new A(); diff --git a/tests/baselines/reference/classOverloadForFunction.js b/tests/baselines/reference/classOverloadForFunction.js index 47c787986d..40f076b0f2 100644 --- a/tests/baselines/reference/classOverloadForFunction.js +++ b/tests/baselines/reference/classOverloadForFunction.js @@ -10,5 +10,4 @@ var foo = (function () { return foo; })(); ; -function foo() { -} +function foo() { } diff --git a/tests/baselines/reference/classPropertyAsPrivate.js b/tests/baselines/reference/classPropertyAsPrivate.js index 8b59dcde77..51d08b48ec 100644 --- a/tests/baselines/reference/classPropertyAsPrivate.js +++ b/tests/baselines/reference/classPropertyAsPrivate.js @@ -28,27 +28,19 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "y", { - get: function () { - return null; - }, - set: function (x) { - }, + get: function () { return null; }, + set: function (x) { }, enumerable: true, configurable: true }); - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; Object.defineProperty(C, "b", { - get: function () { - return null; - }, - set: function (x) { - }, + get: function () { return null; }, + set: function (x) { }, enumerable: true, configurable: true }); - C.foo = function () { - }; + C.foo = function () { }; return C; })(); var c; diff --git a/tests/baselines/reference/classPropertyAsProtected.js b/tests/baselines/reference/classPropertyAsProtected.js index ddb193f072..1cd7408981 100644 --- a/tests/baselines/reference/classPropertyAsProtected.js +++ b/tests/baselines/reference/classPropertyAsProtected.js @@ -28,27 +28,19 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "y", { - get: function () { - return null; - }, - set: function (x) { - }, + get: function () { return null; }, + set: function (x) { }, enumerable: true, configurable: true }); - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; Object.defineProperty(C, "b", { - get: function () { - return null; - }, - set: function (x) { - }, + get: function () { return null; }, + set: function (x) { }, enumerable: true, configurable: true }); - C.foo = function () { - }; + C.foo = function () { }; return C; })(); var c; diff --git a/tests/baselines/reference/classPropertyIsPublicByDefault.js b/tests/baselines/reference/classPropertyIsPublicByDefault.js index db1eca56c1..a0b61a0892 100644 --- a/tests/baselines/reference/classPropertyIsPublicByDefault.js +++ b/tests/baselines/reference/classPropertyIsPublicByDefault.js @@ -27,27 +27,19 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "y", { - get: function () { - return null; - }, - set: function (x) { - }, + get: function () { return null; }, + set: function (x) { }, enumerable: true, configurable: true }); - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; Object.defineProperty(C, "b", { - get: function () { - return null; - }, - set: function (x) { - }, + get: function () { return null; }, + set: function (x) { }, enumerable: true, configurable: true }); - C.foo = function () { - }; + C.foo = function () { }; return C; })(); var c; diff --git a/tests/baselines/reference/classSideInheritance1.js b/tests/baselines/reference/classSideInheritance1.js index 38b84b77bd..74df624a78 100644 --- a/tests/baselines/reference/classSideInheritance1.js +++ b/tests/baselines/reference/classSideInheritance1.js @@ -28,9 +28,7 @@ var A = (function () { A.bar = function () { return ""; }; - A.prototype.foo = function () { - return 1; - }; + A.prototype.foo = function () { return 1; }; return A; })(); var C2 = (function (_super) { diff --git a/tests/baselines/reference/classWithEmptyBody.js b/tests/baselines/reference/classWithEmptyBody.js index df9bc85710..16c50ccec7 100644 --- a/tests/baselines/reference/classWithEmptyBody.js +++ b/tests/baselines/reference/classWithEmptyBody.js @@ -29,11 +29,8 @@ var C = (function () { var c; var o = c; c = 1; -c = { - foo: '' -}; -c = function () { -}; +c = { foo: '' }; +c = function () { }; var D = (function () { function D() { return 1; @@ -43,8 +40,5 @@ var D = (function () { var d; var o = d; d = 1; -d = { - foo: '' -}; -d = function () { -}; +d = { foo: '' }; +d = function () { }; diff --git a/tests/baselines/reference/classWithMultipleBaseClasses.js b/tests/baselines/reference/classWithMultipleBaseClasses.js index c6900f526c..0e101d61dc 100644 --- a/tests/baselines/reference/classWithMultipleBaseClasses.js +++ b/tests/baselines/reference/classWithMultipleBaseClasses.js @@ -28,23 +28,19 @@ interface I extends A, B { var A = (function () { function A() { } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); var B = (function () { function B() { } - B.prototype.bar = function () { - }; + B.prototype.bar = function () { }; return B; })(); var D = (function () { function D() { } - D.prototype.baz = function () { - }; - D.prototype.bat = function () { - }; + D.prototype.baz = function () { }; + D.prototype.bat = function () { }; return D; })(); diff --git a/tests/baselines/reference/classWithOnlyPublicMembersEquivalentToInterface.js b/tests/baselines/reference/classWithOnlyPublicMembersEquivalentToInterface.js index acb802d0f9..1c07449c99 100644 --- a/tests/baselines/reference/classWithOnlyPublicMembersEquivalentToInterface.js +++ b/tests/baselines/reference/classWithOnlyPublicMembersEquivalentToInterface.js @@ -30,15 +30,10 @@ i = c; var C = (function () { function C() { } - C.prototype.y = function (a) { - return null; - }; + C.prototype.y = function (a) { return null; }; Object.defineProperty(C.prototype, "z", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/classWithOnlyPublicMembersEquivalentToInterface2.js b/tests/baselines/reference/classWithOnlyPublicMembersEquivalentToInterface2.js index 1048c2e512..78e5cb0586 100644 --- a/tests/baselines/reference/classWithOnlyPublicMembersEquivalentToInterface2.js +++ b/tests/baselines/reference/classWithOnlyPublicMembersEquivalentToInterface2.js @@ -32,15 +32,10 @@ i = c; var C = (function () { function C() { } - C.prototype.y = function (a) { - return null; - }; + C.prototype.y = function (a) { return null; }; Object.defineProperty(C.prototype, "z", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/classWithOptionalParameter.js b/tests/baselines/reference/classWithOptionalParameter.js index 082e624916..2f11f15feb 100644 --- a/tests/baselines/reference/classWithOptionalParameter.js +++ b/tests/baselines/reference/classWithOptionalParameter.js @@ -16,14 +16,12 @@ class C2 { var C = (function () { function C() { } - C.prototype.f = function () { - }; + C.prototype.f = function () { }; return C; })(); var C2 = (function () { function C2() { } - C2.prototype.f = function (x) { - }; + C2.prototype.f = function (x) { }; return C2; })(); diff --git a/tests/baselines/reference/classWithOverloadImplementationOfWrongName.js b/tests/baselines/reference/classWithOverloadImplementationOfWrongName.js index f8cb9bf4c5..4ac6548483 100644 --- a/tests/baselines/reference/classWithOverloadImplementationOfWrongName.js +++ b/tests/baselines/reference/classWithOverloadImplementationOfWrongName.js @@ -9,7 +9,6 @@ class C { var C = (function () { function C() { } - C.prototype.bar = function (x) { - }; + C.prototype.bar = function (x) { }; return C; })(); diff --git a/tests/baselines/reference/classWithOverloadImplementationOfWrongName2.js b/tests/baselines/reference/classWithOverloadImplementationOfWrongName2.js index 5caba8f3fd..fd28ae3d9e 100644 --- a/tests/baselines/reference/classWithOverloadImplementationOfWrongName2.js +++ b/tests/baselines/reference/classWithOverloadImplementationOfWrongName2.js @@ -9,7 +9,6 @@ class C { var C = (function () { function C() { } - C.prototype.bar = function (x) { - }; + C.prototype.bar = function (x) { }; return C; })(); diff --git a/tests/baselines/reference/classWithPrivateProperty.js b/tests/baselines/reference/classWithPrivateProperty.js index 47ff7c9142..0529fd8d69 100644 --- a/tests/baselines/reference/classWithPrivateProperty.js +++ b/tests/baselines/reference/classWithPrivateProperty.js @@ -28,19 +28,11 @@ var C = (function () { function C() { this.a = ''; this.b = ''; - this.d = function () { - return ''; - }; + this.d = function () { return ''; }; } - C.prototype.c = function () { - return ''; - }; - C.f = function () { - return ''; - }; - C.g = function () { - return ''; - }; + C.prototype.c = function () { return ''; }; + C.f = function () { return ''; }; + C.g = function () { return ''; }; return C; })(); var c = new C(); diff --git a/tests/baselines/reference/classWithProtectedProperty.js b/tests/baselines/reference/classWithProtectedProperty.js index c8b15c1396..4de87229ad 100644 --- a/tests/baselines/reference/classWithProtectedProperty.js +++ b/tests/baselines/reference/classWithProtectedProperty.js @@ -39,19 +39,11 @@ var C = (function () { function C() { this.a = ''; this.b = ''; - this.d = function () { - return ''; - }; + this.d = function () { return ''; }; } - C.prototype.c = function () { - return ''; - }; - C.f = function () { - return ''; - }; - C.g = function () { - return ''; - }; + C.prototype.c = function () { return ''; }; + C.f = function () { return ''; }; + C.g = function () { return ''; }; return C; })(); var D = (function (_super) { diff --git a/tests/baselines/reference/classWithPublicProperty.js b/tests/baselines/reference/classWithPublicProperty.js index 88dc9d8de1..cc1b0aad64 100644 --- a/tests/baselines/reference/classWithPublicProperty.js +++ b/tests/baselines/reference/classWithPublicProperty.js @@ -26,19 +26,11 @@ var C = (function () { function C() { this.a = ''; this.b = ''; - this.d = function () { - return ''; - }; + this.d = function () { return ''; }; } - C.prototype.c = function () { - return ''; - }; - C.f = function () { - return ''; - }; - C.g = function () { - return ''; - }; + C.prototype.c = function () { return ''; }; + C.f = function () { return ''; }; + C.g = function () { return ''; }; return C; })(); // all of these are valid diff --git a/tests/baselines/reference/classWithStaticMembers.js b/tests/baselines/reference/classWithStaticMembers.js index 2cded4b1f2..36b8bd0af6 100644 --- a/tests/baselines/reference/classWithStaticMembers.js +++ b/tests/baselines/reference/classWithStaticMembers.js @@ -31,15 +31,10 @@ var C = (function () { this.a = a; this.b = b; } - C.fn = function () { - return this; - }; + C.fn = function () { return this; }; Object.defineProperty(C, "x", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/classdecl.js b/tests/baselines/reference/classdecl.js index 1f588b785e..e9253b61ca 100644 --- a/tests/baselines/reference/classdecl.js +++ b/tests/baselines/reference/classdecl.js @@ -103,8 +103,7 @@ var __extends = this.__extends || function (d, b) { var a = (function () { function a(ns) { } - a.prototype.pgF = function () { - }; + a.prototype.pgF = function () { }; Object.defineProperty(a.prototype, "d", { get: function () { return 30; @@ -116,10 +115,7 @@ var a = (function () { }); Object.defineProperty(a, "p2", { get: function () { - return { - x: 30, - y: 40 - }; + return { x: 30, y: 40 }; }, enumerable: true, configurable: true diff --git a/tests/baselines/reference/cloduleAcrossModuleDefinitions.js b/tests/baselines/reference/cloduleAcrossModuleDefinitions.js index 9772af2043..c877de38a0 100644 --- a/tests/baselines/reference/cloduleAcrossModuleDefinitions.js +++ b/tests/baselines/reference/cloduleAcrossModuleDefinitions.js @@ -21,10 +21,8 @@ var A; var B = (function () { function B() { } - B.prototype.foo = function () { - }; - B.bar = function () { - }; + B.prototype.foo = function () { }; + B.bar = function () { }; return B; })(); A.B = B; diff --git a/tests/baselines/reference/cloduleTest1.js b/tests/baselines/reference/cloduleTest1.js index f79f1e5c46..9e7edc77c7 100644 --- a/tests/baselines/reference/cloduleTest1.js +++ b/tests/baselines/reference/cloduleTest1.js @@ -14,8 +14,7 @@ //// [cloduleTest1.js] var $; (function ($) { - function ajax(options) { - } + function ajax(options) { } $.ajax = ajax; })($ || ($ = {})); var it = $('.foo').addClass('bar'); diff --git a/tests/baselines/reference/cloduleWithDuplicateMember1.js b/tests/baselines/reference/cloduleWithDuplicateMember1.js index ed4d69545f..e3cb8f83fe 100644 --- a/tests/baselines/reference/cloduleWithDuplicateMember1.js +++ b/tests/baselines/reference/cloduleWithDuplicateMember1.js @@ -20,9 +20,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "x", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); @@ -33,8 +31,7 @@ var C = (function () { enumerable: true, configurable: true }); - C.foo = function () { - }; + C.foo = function () { }; return C; })(); var C; @@ -43,10 +40,8 @@ var C; })(C || (C = {})); var C; (function (C) { - function foo() { - } + function foo() { } C.foo = foo; - function x() { - } + function x() { } C.x = x; })(C || (C = {})); diff --git a/tests/baselines/reference/cloduleWithDuplicateMember2.js b/tests/baselines/reference/cloduleWithDuplicateMember2.js index 461930c02a..c16c6c9af8 100644 --- a/tests/baselines/reference/cloduleWithDuplicateMember2.js +++ b/tests/baselines/reference/cloduleWithDuplicateMember2.js @@ -16,14 +16,12 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "x", { - set: function (y) { - }, + set: function (y) { }, enumerable: true, configurable: true }); Object.defineProperty(C, "y", { - set: function (z) { - }, + set: function (z) { }, enumerable: true, configurable: true }); @@ -35,7 +33,6 @@ var C; })(C || (C = {})); var C; (function (C) { - function x() { - } + function x() { } C.x = x; })(C || (C = {})); diff --git a/tests/baselines/reference/clodulesDerivedClasses.js b/tests/baselines/reference/clodulesDerivedClasses.js index f249a7d558..b4b31e59d3 100644 --- a/tests/baselines/reference/clodulesDerivedClasses.js +++ b/tests/baselines/reference/clodulesDerivedClasses.js @@ -38,9 +38,7 @@ var Shape; (function (Shape) { var Utils; (function (Utils) { - function convert() { - return null; - } + function convert() { return null; } Utils.convert = convert; })(Utils = Shape.Utils || (Shape.Utils = {})); })(Shape || (Shape = {})); diff --git a/tests/baselines/reference/collisionSuperAndParameter.js b/tests/baselines/reference/collisionSuperAndParameter.js index f7198dfbf0..be9e0ce3f6 100644 --- a/tests/baselines/reference/collisionSuperAndParameter.js +++ b/tests/baselines/reference/collisionSuperAndParameter.js @@ -75,17 +75,13 @@ var Foo = (function () { Foo.prototype.a = function () { var _this = this; var lamda = function (_super) { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; }; Foo.prototype.b = function (_super) { var _this = this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; }; Object.defineProperty(Foo.prototype, "c", { @@ -108,17 +104,13 @@ var Foo2 = (function (_super) { Foo2.prototype.x = function () { var _this = this; var lamda = function (_super) { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; }; Foo2.prototype.y = function (_super) { var _this = this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; }; Object.defineProperty(Foo2.prototype, "z", { @@ -137,9 +129,7 @@ var Foo4 = (function (_super) { Foo4.prototype.y = function (_super) { var _this = this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; }; return Foo4; diff --git a/tests/baselines/reference/collisionThisExpressionAndAliasInGlobal.js b/tests/baselines/reference/collisionThisExpressionAndAliasInGlobal.js index b1db7f12ea..1f61379864 100644 --- a/tests/baselines/reference/collisionThisExpressionAndAliasInGlobal.js +++ b/tests/baselines/reference/collisionThisExpressionAndAliasInGlobal.js @@ -11,7 +11,5 @@ var a; (function (a) { a.b = 10; })(a || (a = {})); -var f = function () { - return _this; -}; +var f = function () { return _this; }; var _this = a; // Error diff --git a/tests/baselines/reference/collisionThisExpressionAndAmbientClassInGlobal.js b/tests/baselines/reference/collisionThisExpressionAndAmbientClassInGlobal.js index 7c617b2575..b99311b0c3 100644 --- a/tests/baselines/reference/collisionThisExpressionAndAmbientClassInGlobal.js +++ b/tests/baselines/reference/collisionThisExpressionAndAmbientClassInGlobal.js @@ -6,7 +6,5 @@ var a = new _this(); // Error //// [collisionThisExpressionAndAmbientClassInGlobal.js] var _this = this; -var f = function () { - return _this; -}; +var f = function () { return _this; }; var a = new _this(); // Error diff --git a/tests/baselines/reference/collisionThisExpressionAndAmbientVarInGlobal.js b/tests/baselines/reference/collisionThisExpressionAndAmbientVarInGlobal.js index 8aec5140ca..c6c5486905 100644 --- a/tests/baselines/reference/collisionThisExpressionAndAmbientVarInGlobal.js +++ b/tests/baselines/reference/collisionThisExpressionAndAmbientVarInGlobal.js @@ -5,7 +5,5 @@ _this = 10; // Error //// [collisionThisExpressionAndAmbientVarInGlobal.js] var _this = this; -var f = function () { - return _this; -}; +var f = function () { return _this; }; _this = 10; // Error diff --git a/tests/baselines/reference/collisionThisExpressionAndClassInGlobal.js b/tests/baselines/reference/collisionThisExpressionAndClassInGlobal.js index c31d03bed9..ccaa335d80 100644 --- a/tests/baselines/reference/collisionThisExpressionAndClassInGlobal.js +++ b/tests/baselines/reference/collisionThisExpressionAndClassInGlobal.js @@ -10,6 +10,4 @@ var _this = (function () { } return _this; })(); -var f = function () { - return _this; -}; +var f = function () { return _this; }; diff --git a/tests/baselines/reference/collisionThisExpressionAndEnumInGlobal.js b/tests/baselines/reference/collisionThisExpressionAndEnumInGlobal.js index 3de272e51a..4ab929a387 100644 --- a/tests/baselines/reference/collisionThisExpressionAndEnumInGlobal.js +++ b/tests/baselines/reference/collisionThisExpressionAndEnumInGlobal.js @@ -12,6 +12,4 @@ var _this; _this[_this["_thisVal1"] = 0] = "_thisVal1"; _this[_this["_thisVal2"] = 1] = "_thisVal2"; })(_this || (_this = {})); -var f = function () { - return _this; -}; +var f = function () { return _this; }; diff --git a/tests/baselines/reference/collisionThisExpressionAndFunctionInGlobal.js b/tests/baselines/reference/collisionThisExpressionAndFunctionInGlobal.js index 07e2a1358f..3c6232ba0b 100644 --- a/tests/baselines/reference/collisionThisExpressionAndFunctionInGlobal.js +++ b/tests/baselines/reference/collisionThisExpressionAndFunctionInGlobal.js @@ -9,6 +9,4 @@ var _this = this; function _this() { return 10; } -var f = function () { - return _this; -}; +var f = function () { return _this; }; diff --git a/tests/baselines/reference/collisionThisExpressionAndLocalVarInAccessors.js b/tests/baselines/reference/collisionThisExpressionAndLocalVarInAccessors.js index 0e3384feb2..53df298454 100644 --- a/tests/baselines/reference/collisionThisExpressionAndLocalVarInAccessors.js +++ b/tests/baselines/reference/collisionThisExpressionAndLocalVarInAccessors.js @@ -51,24 +51,20 @@ var class1 = (function () { get: function () { var _this = this; var x2 = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; return 10; }, set: function (val) { var _this = this; var x2 = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; }, enumerable: true, @@ -84,11 +80,9 @@ var class2 = (function () { var _this = this; var _this = 2; var x2 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; return 10; }, @@ -96,11 +90,9 @@ var class2 = (function () { var _this = this; var _this = 2; var x2 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; }, enumerable: true, diff --git a/tests/baselines/reference/collisionThisExpressionAndLocalVarInConstructor.js b/tests/baselines/reference/collisionThisExpressionAndLocalVarInConstructor.js index e4c1c7ac9b..d0ed79da53 100644 --- a/tests/baselines/reference/collisionThisExpressionAndLocalVarInConstructor.js +++ b/tests/baselines/reference/collisionThisExpressionAndLocalVarInConstructor.js @@ -26,12 +26,10 @@ var class1 = (function () { function class1() { var _this = this; var x2 = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; } return class1; @@ -41,11 +39,9 @@ var class2 = (function () { var _this = this; var _this = 2; var x2 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; } return class2; diff --git a/tests/baselines/reference/collisionThisExpressionAndLocalVarInFunction.js b/tests/baselines/reference/collisionThisExpressionAndLocalVarInFunction.js index 967d01819e..879dd83d77 100644 --- a/tests/baselines/reference/collisionThisExpressionAndLocalVarInFunction.js +++ b/tests/baselines/reference/collisionThisExpressionAndLocalVarInFunction.js @@ -12,7 +12,5 @@ var console; function x() { var _this = this; var _this = 5; - (function (x) { - console.log(_this.x); - }); + (function (x) { console.log(_this.x); }); } diff --git a/tests/baselines/reference/collisionThisExpressionAndLocalVarInLambda.js b/tests/baselines/reference/collisionThisExpressionAndLocalVarInLambda.js index a799ec36ea..e8b7a0db7f 100644 --- a/tests/baselines/reference/collisionThisExpressionAndLocalVarInLambda.js +++ b/tests/baselines/reference/collisionThisExpressionAndLocalVarInLambda.js @@ -12,13 +12,9 @@ alert(x.doStuff(x => alert(x))); //// [collisionThisExpressionAndLocalVarInLambda.js] var _this = this; var x = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; -alert(x.doStuff(function (x) { - return alert(x); -})); +alert(x.doStuff(function (x) { return alert(x); })); diff --git a/tests/baselines/reference/collisionThisExpressionAndLocalVarInMethod.js b/tests/baselines/reference/collisionThisExpressionAndLocalVarInMethod.js index 398ed39379..63b536bd8b 100644 --- a/tests/baselines/reference/collisionThisExpressionAndLocalVarInMethod.js +++ b/tests/baselines/reference/collisionThisExpressionAndLocalVarInMethod.js @@ -25,23 +25,19 @@ var a = (function () { a.prototype.method1 = function () { var _this = this; return { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; }; a.prototype.method2 = function () { var _this = this; var _this = 2; return { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; }; return a; diff --git a/tests/baselines/reference/collisionThisExpressionAndLocalVarInProperty.js b/tests/baselines/reference/collisionThisExpressionAndLocalVarInProperty.js index f884c93a62..65d181921d 100644 --- a/tests/baselines/reference/collisionThisExpressionAndLocalVarInProperty.js +++ b/tests/baselines/reference/collisionThisExpressionAndLocalVarInProperty.js @@ -24,12 +24,10 @@ var class1 = (function () { function class1() { var _this = this; this.prop1 = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; } return class1; @@ -38,11 +36,9 @@ var class2 = (function () { function class2() { var _this = this; this.prop1 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; var _this = 2; } diff --git a/tests/baselines/reference/collisionThisExpressionAndLocalVarWithSuperExperssion.js b/tests/baselines/reference/collisionThisExpressionAndLocalVarWithSuperExperssion.js index 5ac394520e..d502fc5c03 100644 --- a/tests/baselines/reference/collisionThisExpressionAndLocalVarWithSuperExperssion.js +++ b/tests/baselines/reference/collisionThisExpressionAndLocalVarWithSuperExperssion.js @@ -40,9 +40,7 @@ var b = (function (_super) { b.prototype.foo = function () { var _this = this; var _this = 10; - var f = function () { - return _super.prototype.foo.call(_this); - }; + var f = function () { return _super.prototype.foo.call(_this); }; }; return b; })(a); diff --git a/tests/baselines/reference/collisionThisExpressionAndModuleInGlobal.js b/tests/baselines/reference/collisionThisExpressionAndModuleInGlobal.js index 2bf6987c86..777f141451 100644 --- a/tests/baselines/reference/collisionThisExpressionAndModuleInGlobal.js +++ b/tests/baselines/reference/collisionThisExpressionAndModuleInGlobal.js @@ -15,6 +15,4 @@ var _this; return c; })(); })(_this || (_this = {})); -var f = function () { - return _this; -}; +var f = function () { return _this; }; diff --git a/tests/baselines/reference/collisionThisExpressionAndNameResolution.js b/tests/baselines/reference/collisionThisExpressionAndNameResolution.js index 12398920f5..8b128d9294 100644 --- a/tests/baselines/reference/collisionThisExpressionAndNameResolution.js +++ b/tests/baselines/reference/collisionThisExpressionAndNameResolution.js @@ -22,9 +22,7 @@ var Foo = (function () { function inner() { var _this = this; console.log(_this); // Error as this doesnt not resolve to user defined _this - return function (x) { - return _this; - }; // New scope. So should inject new _this capture into function inner + return function (x) { return _this; }; // New scope. So should inject new _this capture into function inner } }; return Foo; diff --git a/tests/baselines/reference/collisionThisExpressionAndParameter.js b/tests/baselines/reference/collisionThisExpressionAndParameter.js index 95ade61d20..3a19cf20d5 100644 --- a/tests/baselines/reference/collisionThisExpressionAndParameter.js +++ b/tests/baselines/reference/collisionThisExpressionAndParameter.js @@ -101,25 +101,19 @@ var Foo = (function () { var _this = 10; // Local var. No this capture in x(), so no conflict. function inner(_this) { var _this = this; - return function (x) { - return _this; - }; // New scope. So should inject new _this capture into function inner + return function (x) { return _this; }; // New scope. So should inject new _this capture into function inner } }; Foo.prototype.y = function () { var _this = this; var lamda = function (_this) { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; }; Foo.prototype.z = function (_this) { var _this = this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; }; Foo.prototype.x1 = function () { @@ -141,45 +135,35 @@ var Foo1 = (function () { function Foo1(_this) { var _this = this; var x2 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; } return Foo1; })(); function f1(_this) { var _this = this; - (function (x) { - console.log(_this.x); - }); + (function (x) { console.log(_this.x); }); } var Foo3 = (function () { function Foo3(_this) { var _this = this; var x2 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; } Foo3.prototype.z = function (_this) { var _this = this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; }; return Foo3; })(); function f3(_this) { var _this = this; - (function (x) { - console.log(_this.x); - }); + (function (x) { console.log(_this.x); }); } diff --git a/tests/baselines/reference/collisionThisExpressionAndPropertyNameAsConstuctorParameter.js b/tests/baselines/reference/collisionThisExpressionAndPropertyNameAsConstuctorParameter.js index 75e4a60bfd..a77098739e 100644 --- a/tests/baselines/reference/collisionThisExpressionAndPropertyNameAsConstuctorParameter.js +++ b/tests/baselines/reference/collisionThisExpressionAndPropertyNameAsConstuctorParameter.js @@ -40,9 +40,7 @@ var Foo2 = (function () { function Foo2(_this) { var _this = this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; } return Foo2; @@ -52,9 +50,7 @@ var Foo3 = (function () { var _this = this; this._this = _this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; } return Foo3; @@ -63,9 +59,7 @@ var Foo4 = (function () { function Foo4(_this) { var _this = this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; } return Foo4; @@ -75,9 +69,7 @@ var Foo5 = (function () { var _this = this; this._this = _this; var lambda = function () { - return function (x) { - return _this; - }; // New scope. So should inject new _this capture + return function (x) { return _this; }; // New scope. So should inject new _this capture }; } return Foo5; diff --git a/tests/baselines/reference/collisionThisExpressionAndVarInGlobal.js b/tests/baselines/reference/collisionThisExpressionAndVarInGlobal.js index 77a6a28e28..7057ad7ac5 100644 --- a/tests/baselines/reference/collisionThisExpressionAndVarInGlobal.js +++ b/tests/baselines/reference/collisionThisExpressionAndVarInGlobal.js @@ -5,6 +5,4 @@ var f = () => this; //// [collisionThisExpressionAndVarInGlobal.js] var _this = this; var _this = 1; -var f = function () { - return _this; -}; +var f = function () { return _this; }; diff --git a/tests/baselines/reference/commaOperatorWithSecondOperandAnyType.js b/tests/baselines/reference/commaOperatorWithSecondOperandAnyType.js index 903a77c1ac..522bbbe4e1 100644 --- a/tests/baselines/reference/commaOperatorWithSecondOperandAnyType.js +++ b/tests/baselines/reference/commaOperatorWithSecondOperandAnyType.js @@ -59,14 +59,8 @@ var resultIsAny5 = (OBJECT, ANY); var x; 1, ANY; ++NUMBER, ANY; -"string", [ - null, - 1 -]; -"string".charAt(0), [ - null, - 1 -]; +"string", [null, 1]; +"string".charAt(0), [null, 1]; true, x("any"); !BOOLEAN, x.doSomeThing(); var resultIsAny6 = (1, ANY); diff --git a/tests/baselines/reference/commaOperatorWithSecondOperandBooleanType.js b/tests/baselines/reference/commaOperatorWithSecondOperandBooleanType.js index 6e3df84900..dfaba1a93c 100644 --- a/tests/baselines/reference/commaOperatorWithSecondOperandBooleanType.js +++ b/tests/baselines/reference/commaOperatorWithSecondOperandBooleanType.js @@ -58,27 +58,11 @@ null, BOOLEAN; ANY = undefined, BOOLEAN; 1, true; ++NUMBER, true; -[ - 1, - 2, - 3 -], !BOOLEAN; -OBJECT = [ - 1, - 2, - 3 -], BOOLEAN = false; +[1, 2, 3], !BOOLEAN; +OBJECT = [1, 2, 3], BOOLEAN = false; var resultIsBoolean6 = (null, BOOLEAN); var resultIsBoolean7 = (ANY = undefined, BOOLEAN); var resultIsBoolean8 = (1, true); var resultIsBoolean9 = (++NUMBER, true); -var resultIsBoolean10 = ([ - 1, - 2, - 3 -], !BOOLEAN); -var resultIsBoolean11 = (OBJECT = [ - 1, - 2, - 3 -], BOOLEAN = false); +var resultIsBoolean10 = ([1, 2, 3], !BOOLEAN); +var resultIsBoolean11 = (OBJECT = [1, 2, 3], BOOLEAN = false); diff --git a/tests/baselines/reference/commaOperatorWithSecondOperandObjectType.js b/tests/baselines/reference/commaOperatorWithSecondOperandObjectType.js index 452d74d7cf..90c16543ff 100644 --- a/tests/baselines/reference/commaOperatorWithSecondOperandObjectType.js +++ b/tests/baselines/reference/commaOperatorWithSecondOperandObjectType.js @@ -72,9 +72,6 @@ STRING.toLowerCase(), new CLASS(); var resultIsObject6 = (null, OBJECT); var resultIsObject7 = (ANY = null, OBJECT); var resultIsObject8 = (true, {}); -var resultIsObject9 = (!BOOLEAN, { - a: 1, - b: "s" -}); +var resultIsObject9 = (!BOOLEAN, { a: 1, b: "s" }); var resultIsObject10 = ("string", new Date()); var resultIsObject11 = (STRING.toLowerCase(), new CLASS()); diff --git a/tests/baselines/reference/commaOperatorWithSecondOperandStringType.js b/tests/baselines/reference/commaOperatorWithSecondOperandStringType.js index 163679b337..412e9e8312 100644 --- a/tests/baselines/reference/commaOperatorWithSecondOperandStringType.js +++ b/tests/baselines/reference/commaOperatorWithSecondOperandStringType.js @@ -61,17 +61,11 @@ null, STRING; ANY = new Date(), STRING; true, ""; BOOLEAN == undefined, ""; -[ - "a", - "b" -], NUMBER.toString(); +["a", "b"], NUMBER.toString(); OBJECT = new Object, STRING + "string"; var resultIsString6 = (null, STRING); var resultIsString7 = (ANY = new Date(), STRING); var resultIsString8 = (true, ""); var resultIsString9 = (BOOLEAN == undefined, ""); -var resultIsString10 = ([ - "a", - "b" -], NUMBER.toString()); +var resultIsString10 = (["a", "b"], NUMBER.toString()); var resultIsString11 = (new Object, STRING + "string"); diff --git a/tests/baselines/reference/commentEmitAtEndOfFile1.js b/tests/baselines/reference/commentEmitAtEndOfFile1.js index 1a1f7cb890..1be031fa84 100644 --- a/tests/baselines/reference/commentEmitAtEndOfFile1.js +++ b/tests/baselines/reference/commentEmitAtEndOfFile1.js @@ -16,7 +16,6 @@ var f = ''; // test #2 var foo; (function (foo) { - function bar() { - } + function bar() { } })(foo || (foo = {})); // test #4 diff --git a/tests/baselines/reference/commentInMethodCall.js b/tests/baselines/reference/commentInMethodCall.js index 0f304df0b3..4ad2fc552d 100644 --- a/tests/baselines/reference/commentInMethodCall.js +++ b/tests/baselines/reference/commentInMethodCall.js @@ -8,5 +8,4 @@ s.map(// do something //// [commentInMethodCall.js] //commment here var s; -s.map(function () { -}); +s.map(function () { }); diff --git a/tests/baselines/reference/commentOnBlock1.js b/tests/baselines/reference/commentOnBlock1.js index ff557c1fc9..ed5437c1f6 100644 --- a/tests/baselines/reference/commentOnBlock1.js +++ b/tests/baselines/reference/commentOnBlock1.js @@ -7,6 +7,5 @@ function f() { //// [commentOnBlock1.js] // asdf function f() { - /*asdf*/ { - } + /*asdf*/ { } } diff --git a/tests/baselines/reference/commentOnClassAccessor1.js b/tests/baselines/reference/commentOnClassAccessor1.js index cdd14a829f..428e500da5 100644 --- a/tests/baselines/reference/commentOnClassAccessor1.js +++ b/tests/baselines/reference/commentOnClassAccessor1.js @@ -14,9 +14,7 @@ var C = (function () { /** * @type {number} */ - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/commentOnClassAccessor2.js b/tests/baselines/reference/commentOnClassAccessor2.js index c85d17e6e1..22a6b69f6c 100644 --- a/tests/baselines/reference/commentOnClassAccessor2.js +++ b/tests/baselines/reference/commentOnClassAccessor2.js @@ -19,14 +19,11 @@ var C = (function () { /** * Getter. */ - get: function () { - return 1; - }, + get: function () { return 1; }, /** * Setter. */ - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/commentsBeforeFunctionExpression1.js b/tests/baselines/reference/commentsBeforeFunctionExpression1.js index bd7a1896a5..0e23722faf 100644 --- a/tests/baselines/reference/commentsBeforeFunctionExpression1.js +++ b/tests/baselines/reference/commentsBeforeFunctionExpression1.js @@ -6,7 +6,5 @@ var v = { //// [commentsBeforeFunctionExpression1.js] var v = { - f: function (a) { - return 0; - } + f: function (a) { return 0; } }; diff --git a/tests/baselines/reference/commentsFunction.js b/tests/baselines/reference/commentsFunction.js index f5779be524..0ffb271410 100644 --- a/tests/baselines/reference/commentsFunction.js +++ b/tests/baselines/reference/commentsFunction.js @@ -74,12 +74,8 @@ var fooFunc = function FooFunctionValue(/** fooFunctionValue param */ b) { return b; }; /// lamdaFoo var comment -var lambdaFoo = function (/**param a*/ a, /**param b*/ b) { - return a + b; -}; -var lambddaNoVarComment = function (/**param a*/ a, /**param b*/ b) { - return a * b; -}; +var lambdaFoo = function (/**param a*/ a, /**param b*/ b) { return a + b; }; +var lambddaNoVarComment = function (/**param a*/ a, /**param b*/ b) { return a * b; }; lambdaFoo(10, 20); lambddaNoVarComment(10, 20); function blah(a /* multiline trailing comment @@ -90,15 +86,9 @@ function blah2(a /* single line multiple trailing comments */ /* second */) { function blah3(a // trailing commen single line ) { } -lambdaFoo = function (a, b) { - return a * b; -}; // This is trailing comment -/*leading comment*/ (function () { - return 0; -}); // Needs to be wrapped in parens to be a valid expression (not declaration) -/*leading comment*/ (function () { - return 0; -}); //trailing comment +lambdaFoo = function (a, b) { return a * b; }; // This is trailing comment +/*leading comment*/ (function () { return 0; }); // Needs to be wrapped in parens to be a valid expression (not declaration) +/*leading comment*/ (function () { return 0; }); //trailing comment function blah4(/*1*/ a /*2*/, /*3*/ b /*4*/) { } function foo1() { diff --git a/tests/baselines/reference/commentsInterface.js b/tests/baselines/reference/commentsInterface.js index dfffedaea1..bff79a02aa 100644 --- a/tests/baselines/reference/commentsInterface.js +++ b/tests/baselines/reference/commentsInterface.js @@ -89,9 +89,7 @@ var i2_i_nc_fnfoo = i2_i.nc_fnfoo; var i2_i_nc_fnfoo_r = i2_i.nc_fnfoo(10); var i3_i; i3_i = { - f: function (/**i3_i a*/ a) { - return "Hello" + a; - }, + f: function (/**i3_i a*/ a) { return "Hello" + a; }, l: this.f, /** own x*/ x: this.f(10), diff --git a/tests/baselines/reference/commentsOnObjectLiteral3.js b/tests/baselines/reference/commentsOnObjectLiteral3.js index 5d57b76991..49f2a6ffbf 100644 --- a/tests/baselines/reference/commentsOnObjectLiteral3.js +++ b/tests/baselines/reference/commentsOnObjectLiteral3.js @@ -27,8 +27,7 @@ var v = { func: function () { }, //PropertyName + CallSignature - func1: function () { - }, + func1: function () { }, //getter get a() { return this.prop; diff --git a/tests/baselines/reference/commentsVarDecl.js b/tests/baselines/reference/commentsVarDecl.js index d76b43fafb..5ff2a3c1c6 100644 --- a/tests/baselines/reference/commentsVarDecl.js +++ b/tests/baselines/reference/commentsVarDecl.js @@ -70,9 +70,7 @@ var yy = /// value comment 20; /** comment2 */ -var z = function (x, y) { - return x + y; -}; +var z = function (x, y) { return x + y; }; var z2; var x2 = z2; var n4; diff --git a/tests/baselines/reference/complexClassRelationships.js b/tests/baselines/reference/complexClassRelationships.js index a1e982e4b4..e8dc954e14 100644 --- a/tests/baselines/reference/complexClassRelationships.js +++ b/tests/baselines/reference/complexClassRelationships.js @@ -68,11 +68,7 @@ var Derived = (function (_super) { })(Base); var BaseCollection = (function () { function BaseCollection(f) { - (function (item) { - return [ - item.Components - ]; - }); + (function (item) { return [item.Components]; }); } return BaseCollection; })(); @@ -85,9 +81,7 @@ var Thing = (function () { function Thing() { } Object.defineProperty(Thing.prototype, "Components", { - get: function () { - return null; - }, + get: function () { return null; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/compositeGenericFunction.js b/tests/baselines/reference/compositeGenericFunction.js index 0fe2e7d6f4..106c724ea2 100644 --- a/tests/baselines/reference/compositeGenericFunction.js +++ b/tests/baselines/reference/compositeGenericFunction.js @@ -7,12 +7,8 @@ var z: number = h(f); var z: number = h(f); //// [compositeGenericFunction.js] -function f(value) { - return value; -} +function f(value) { return value; } ; -function h(func) { - return null; -} +function h(func) { return null; } var z = h(f); var z = h(f); diff --git a/tests/baselines/reference/compoundAssignmentLHSIsValue.js b/tests/baselines/reference/compoundAssignmentLHSIsValue.js index 40c8a3d7ad..d85d053f8e 100644 --- a/tests/baselines/reference/compoundAssignmentLHSIsValue.js +++ b/tests/baselines/reference/compoundAssignmentLHSIsValue.js @@ -192,14 +192,8 @@ value; } value; // array literals -[ - '', - '' -] *= value; -[ - '', - '' -] += value; +['', ''] *= value; +['', ''] += value; // super var Derived = (function (_super) { __extends(Derived, _super); @@ -219,17 +213,13 @@ var Derived = (function (_super) { return Derived; })(C); // function expression -function bar1() { -} +function bar1() { } value; -function bar2() { -} +function bar2() { } value; -(function () { -}); +(function () { }); value; -(function () { -}); +(function () { }); value; // function calls foo() *= value; @@ -259,9 +249,7 @@ foo() += value; ({}) += value; ([]) *= value; ([]) += value; -(function baz1() { -}) *= value; -(function baz2() { -}) += value; +(function baz1() { }) *= value; +(function baz2() { }) += value; (foo()) *= value; (foo()) += value; diff --git a/tests/baselines/reference/computedPropertyNames10_ES5.js b/tests/baselines/reference/computedPropertyNames10_ES5.js index 5d8ff398d6..302f9355be 100644 --- a/tests/baselines/reference/computedPropertyNames10_ES5.js +++ b/tests/baselines/reference/computedPropertyNames10_ES5.js @@ -21,27 +21,16 @@ var s; var n; var a; var v = (_a = {}, - _a[s] = function () { - }, - _a[n] = function () { - }, - _a[s + s] = function () { - }, - _a[s + n] = function () { - }, - _a[+s] = function () { - }, - _a[""] = function () { - }, - _a[0] = function () { - }, - _a[a] = function () { - }, - _a[true] = function () { - }, - _a["hello bye"] = function () { - }, - _a["hello " + a + " bye"] = function () { - }, + _a[s] = function () { }, + _a[n] = function () { }, + _a[s + s] = function () { }, + _a[s + n] = function () { }, + _a[+s] = function () { }, + _a[""] = function () { }, + _a[0] = function () { }, + _a[a] = function () { }, + _a[true] = function () { }, + _a["hello bye"] = function () { }, + _a["hello " + a + " bye"] = function () { }, _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNames10_ES6.js b/tests/baselines/reference/computedPropertyNames10_ES6.js index 72613b5c82..0a55fabecd 100644 --- a/tests/baselines/reference/computedPropertyNames10_ES6.js +++ b/tests/baselines/reference/computedPropertyNames10_ES6.js @@ -21,26 +21,15 @@ var s; var n; var a; var v = { - [s]() { - }, - [n]() { - }, - [s + s]() { - }, - [s + n]() { - }, - [+s]() { - }, - [""]() { - }, - [0]() { - }, - [a]() { - }, - [true]() { - }, - [`hello bye`]() { - }, - [`hello ${a} bye`]() { - } + [s]() { }, + [n]() { }, + [s + s]() { }, + [s + n]() { }, + [+s]() { }, + [""]() { }, + [0]() { }, + [a]() { }, + [true]() { }, + [`hello bye`]() { }, + [`hello ${a} bye`]() { } }; diff --git a/tests/baselines/reference/computedPropertyNames11_ES5.js b/tests/baselines/reference/computedPropertyNames11_ES5.js index 2b56eeb29f..6990200334 100644 --- a/tests/baselines/reference/computedPropertyNames11_ES5.js +++ b/tests/baselines/reference/computedPropertyNames11_ES5.js @@ -21,77 +21,16 @@ var s; var n; var a; var v = (_a = {}, - _a[s] = Object.defineProperty({ - get: function () { - return 0; - }, - enumerable: true, - configurable: true - }), - _a[n] = Object.defineProperty({ - set: function (v) { - }, - enumerable: true, - configurable: true - }), - _a[s + s] = Object.defineProperty({ - get: function () { - return 0; - }, - enumerable: true, - configurable: true - }), - _a[s + n] = Object.defineProperty({ - set: function (v) { - }, - enumerable: true, - configurable: true - }), - _a[+s] = Object.defineProperty({ - get: function () { - return 0; - }, - enumerable: true, - configurable: true - }), - _a[""] = Object.defineProperty({ - set: function (v) { - }, - enumerable: true, - configurable: true - }), - _a[0] = Object.defineProperty({ - get: function () { - return 0; - }, - enumerable: true, - configurable: true - }), - _a[a] = Object.defineProperty({ - set: function (v) { - }, - enumerable: true, - configurable: true - }), - _a[true] = Object.defineProperty({ - get: function () { - return 0; - }, - enumerable: true, - configurable: true - }), - _a["hello bye"] = Object.defineProperty({ - set: function (v) { - }, - enumerable: true, - configurable: true - }), - _a["hello " + a + " bye"] = Object.defineProperty({ - get: function () { - return 0; - }, - enumerable: true, - configurable: true - }), + _a[s] = Object.defineProperty({ get: function () { return 0; }, enumerable: true, configurable: true }), + _a[n] = Object.defineProperty({ set: function (v) { }, enumerable: true, configurable: true }), + _a[s + s] = Object.defineProperty({ get: function () { return 0; }, enumerable: true, configurable: true }), + _a[s + n] = Object.defineProperty({ set: function (v) { }, enumerable: true, configurable: true }), + _a[+s] = Object.defineProperty({ get: function () { return 0; }, enumerable: true, configurable: true }), + _a[""] = Object.defineProperty({ set: function (v) { }, enumerable: true, configurable: true }), + _a[0] = Object.defineProperty({ get: function () { return 0; }, enumerable: true, configurable: true }), + _a[a] = Object.defineProperty({ set: function (v) { }, enumerable: true, configurable: true }), + _a[true] = Object.defineProperty({ get: function () { return 0; }, enumerable: true, configurable: true }), + _a["hello bye"] = Object.defineProperty({ set: function (v) { }, enumerable: true, configurable: true }), + _a["hello " + a + " bye"] = Object.defineProperty({ get: function () { return 0; }, enumerable: true, configurable: true }), _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNames11_ES6.js b/tests/baselines/reference/computedPropertyNames11_ES6.js index 63f786e463..f1a774b88f 100644 --- a/tests/baselines/reference/computedPropertyNames11_ES6.js +++ b/tests/baselines/reference/computedPropertyNames11_ES6.js @@ -21,32 +21,15 @@ var s; var n; var a; var v = { - get [s]() { - return 0; - }, - set [n](v) { - }, - get [s + s]() { - return 0; - }, - set [s + n](v) { - }, - get [+s]() { - return 0; - }, - set [""](v) { - }, - get [0]() { - return 0; - }, - set [a](v) { - }, - get [true]() { - return 0; - }, - set [`hello bye`](v) { - }, - get [`hello ${a} bye`]() { - return 0; - } + get [s]() { return 0; }, + set [n](v) { }, + get [s + s]() { return 0; }, + set [s + n](v) { }, + get [+s]() { return 0; }, + set [""](v) { }, + get [0]() { return 0; }, + set [a](v) { }, + get [true]() { return 0; }, + set [`hello bye`](v) { }, + get [`hello ${a} bye`]() { return 0; } }; diff --git a/tests/baselines/reference/computedPropertyNames13_ES5.js b/tests/baselines/reference/computedPropertyNames13_ES5.js index 7933d6f983..8956216291 100644 --- a/tests/baselines/reference/computedPropertyNames13_ES5.js +++ b/tests/baselines/reference/computedPropertyNames13_ES5.js @@ -23,27 +23,16 @@ var a; var C = (function () { function C() { } - C.prototype[s] = function () { - }; - C.prototype[n] = function () { - }; - C[s + s] = function () { - }; - C.prototype[s + n] = function () { - }; - C.prototype[+s] = function () { - }; - C[""] = function () { - }; - C.prototype[0] = function () { - }; - C.prototype[a] = function () { - }; - C[true] = function () { - }; - C.prototype["hello bye"] = function () { - }; - C["hello " + a + " bye"] = function () { - }; + C.prototype[s] = function () { }; + C.prototype[n] = function () { }; + C[s + s] = function () { }; + C.prototype[s + n] = function () { }; + C.prototype[+s] = function () { }; + C[""] = function () { }; + C.prototype[0] = function () { }; + C.prototype[a] = function () { }; + C[true] = function () { }; + C.prototype["hello bye"] = function () { }; + C["hello " + a + " bye"] = function () { }; return C; })(); diff --git a/tests/baselines/reference/computedPropertyNames13_ES6.js b/tests/baselines/reference/computedPropertyNames13_ES6.js index 18d81fcec5..4d4c4372eb 100644 --- a/tests/baselines/reference/computedPropertyNames13_ES6.js +++ b/tests/baselines/reference/computedPropertyNames13_ES6.js @@ -21,26 +21,15 @@ var s; var n; var a; class C { - [s]() { - } - [n]() { - } - static [s + s]() { - } - [s + n]() { - } - [+s]() { - } - static [""]() { - } - [0]() { - } - [a]() { - } - static [true]() { - } - [`hello bye`]() { - } - static [`hello ${a} bye`]() { - } + [s]() { } + [n]() { } + static [s + s]() { } + [s + n]() { } + [+s]() { } + static [""]() { } + [0]() { } + [a]() { } + static [true]() { } + [`hello bye`]() { } + static [`hello ${a} bye`]() { } } diff --git a/tests/baselines/reference/computedPropertyNames14_ES5.js b/tests/baselines/reference/computedPropertyNames14_ES5.js index 3a53e4106f..5db5e842a2 100644 --- a/tests/baselines/reference/computedPropertyNames14_ES5.js +++ b/tests/baselines/reference/computedPropertyNames14_ES5.js @@ -14,17 +14,11 @@ var b; var C = (function () { function C() { } - C.prototype[b] = function () { - }; - C[true] = function () { - }; - C.prototype[[]] = function () { - }; - C[{}] = function () { - }; - C.prototype[undefined] = function () { - }; - C[null] = function () { - }; + C.prototype[b] = function () { }; + C[true] = function () { }; + C.prototype[[]] = function () { }; + C[{}] = function () { }; + C.prototype[undefined] = function () { }; + C[null] = function () { }; return C; })(); diff --git a/tests/baselines/reference/computedPropertyNames14_ES6.js b/tests/baselines/reference/computedPropertyNames14_ES6.js index b1b2a9bf28..e925d6af9d 100644 --- a/tests/baselines/reference/computedPropertyNames14_ES6.js +++ b/tests/baselines/reference/computedPropertyNames14_ES6.js @@ -12,16 +12,10 @@ class C { //// [computedPropertyNames14_ES6.js] var b; class C { - [b]() { - } - static [true]() { - } - [[]]() { - } - static [{}]() { - } - [undefined]() { - } - static [null]() { - } + [b]() { } + static [true]() { } + [[]]() { } + static [{}]() { } + [undefined]() { } + static [null]() { } } diff --git a/tests/baselines/reference/computedPropertyNames15_ES5.js b/tests/baselines/reference/computedPropertyNames15_ES5.js index 7e0db9855d..93258b64c7 100644 --- a/tests/baselines/reference/computedPropertyNames15_ES5.js +++ b/tests/baselines/reference/computedPropertyNames15_ES5.js @@ -15,11 +15,8 @@ var p3; var C = (function () { function C() { } - C.prototype[p1] = function () { - }; - C.prototype[p2] = function () { - }; - C.prototype[p3] = function () { - }; + C.prototype[p1] = function () { }; + C.prototype[p2] = function () { }; + C.prototype[p3] = function () { }; return C; })(); diff --git a/tests/baselines/reference/computedPropertyNames15_ES6.js b/tests/baselines/reference/computedPropertyNames15_ES6.js index 1a9141ab13..4cf6ca8814 100644 --- a/tests/baselines/reference/computedPropertyNames15_ES6.js +++ b/tests/baselines/reference/computedPropertyNames15_ES6.js @@ -13,10 +13,7 @@ var p1; var p2; var p3; class C { - [p1]() { - } - [p2]() { - } - [p3]() { - } + [p1]() { } + [p2]() { } + [p3]() { } } diff --git a/tests/baselines/reference/computedPropertyNames16_ES5.js b/tests/baselines/reference/computedPropertyNames16_ES5.js index b8c4991bee..2c7316e139 100644 --- a/tests/baselines/reference/computedPropertyNames16_ES5.js +++ b/tests/baselines/reference/computedPropertyNames16_ES5.js @@ -24,74 +24,57 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, s, { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, n, { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C, s + s, { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, s + n, { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, +s, { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C, "", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, 0, { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, a, { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C, true, { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, "hello bye", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, "hello " + a + " bye", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames16_ES6.js b/tests/baselines/reference/computedPropertyNames16_ES6.js index 96e175976d..aaec8db01a 100644 --- a/tests/baselines/reference/computedPropertyNames16_ES6.js +++ b/tests/baselines/reference/computedPropertyNames16_ES6.js @@ -21,32 +21,15 @@ var s; var n; var a; class C { - get [s]() { - return 0; - } - set [n](v) { - } - static get [s + s]() { - return 0; - } - set [s + n](v) { - } - get [+s]() { - return 0; - } - static set [""](v) { - } - get [0]() { - return 0; - } - set [a](v) { - } - static get [true]() { - return 0; - } - set [`hello bye`](v) { - } - get [`hello ${a} bye`]() { - return 0; - } + get [s]() { return 0; } + set [n](v) { } + static get [s + s]() { return 0; } + set [s + n](v) { } + get [+s]() { return 0; } + static set [""](v) { } + get [0]() { return 0; } + set [a](v) { } + static get [true]() { return 0; } + set [`hello bye`](v) { } + get [`hello ${a} bye`]() { return 0; } } diff --git a/tests/baselines/reference/computedPropertyNames17_ES5.js b/tests/baselines/reference/computedPropertyNames17_ES5.js index 33bc5bfd3c..3b5c100694 100644 --- a/tests/baselines/reference/computedPropertyNames17_ES5.js +++ b/tests/baselines/reference/computedPropertyNames17_ES5.js @@ -15,41 +15,32 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, b, { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C, true, { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, [], { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, {}, { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C, undefined, { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, null, { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames17_ES6.js b/tests/baselines/reference/computedPropertyNames17_ES6.js index a181a61004..5b1e87744c 100644 --- a/tests/baselines/reference/computedPropertyNames17_ES6.js +++ b/tests/baselines/reference/computedPropertyNames17_ES6.js @@ -12,19 +12,10 @@ class C { //// [computedPropertyNames17_ES6.js] var b; class C { - get [b]() { - return 0; - } - static set [true](v) { - } - get [[]]() { - return 0; - } - set [{}](v) { - } - static get [undefined]() { - return 0; - } - set [null](v) { - } + get [b]() { return 0; } + static set [true](v) { } + get [[]]() { return 0; } + set [{}](v) { } + static get [undefined]() { return 0; } + set [null](v) { } } diff --git a/tests/baselines/reference/computedPropertyNames1_ES5.js b/tests/baselines/reference/computedPropertyNames1_ES5.js index 9acf507ecb..37e06616c2 100644 --- a/tests/baselines/reference/computedPropertyNames1_ES5.js +++ b/tests/baselines/reference/computedPropertyNames1_ES5.js @@ -6,18 +6,7 @@ var v = { //// [computedPropertyNames1_ES5.js] var v = (_a = {}, - _a[0 + 1] = Object.defineProperty({ - get: function () { - return 0; - }, - enumerable: true, - configurable: true - }), - _a[0 + 1] = Object.defineProperty({ - set: function (v) { - }, - enumerable: true, - configurable: true - }), + _a[0 + 1] = Object.defineProperty({ get: function () { return 0; }, enumerable: true, configurable: true }), + _a[0 + 1] = Object.defineProperty({ set: function (v) { }, enumerable: true, configurable: true }), _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNames1_ES6.js b/tests/baselines/reference/computedPropertyNames1_ES6.js index 86cdd9c433..80a7d2ecdd 100644 --- a/tests/baselines/reference/computedPropertyNames1_ES6.js +++ b/tests/baselines/reference/computedPropertyNames1_ES6.js @@ -6,9 +6,6 @@ var v = { //// [computedPropertyNames1_ES6.js] var v = { - get [0 + 1]() { - return 0; - }, - set [0 + 1](v) { - } //No error + get [0 + 1]() { return 0; }, + set [0 + 1](v) { } //No error }; diff --git a/tests/baselines/reference/computedPropertyNames21_ES5.js b/tests/baselines/reference/computedPropertyNames21_ES5.js index 2678cdc228..81f95cd824 100644 --- a/tests/baselines/reference/computedPropertyNames21_ES5.js +++ b/tests/baselines/reference/computedPropertyNames21_ES5.js @@ -13,7 +13,6 @@ var C = (function () { C.prototype.bar = function () { return 0; }; - C.prototype[this.bar()] = function () { - }; + C.prototype[this.bar()] = function () { }; return C; })(); diff --git a/tests/baselines/reference/computedPropertyNames21_ES6.js b/tests/baselines/reference/computedPropertyNames21_ES6.js index c5f6b4e22b..5cee093bc4 100644 --- a/tests/baselines/reference/computedPropertyNames21_ES6.js +++ b/tests/baselines/reference/computedPropertyNames21_ES6.js @@ -11,6 +11,5 @@ class C { bar() { return 0; } - [this.bar()]() { - } + [this.bar()]() { } } diff --git a/tests/baselines/reference/computedPropertyNames22_ES5.js b/tests/baselines/reference/computedPropertyNames22_ES5.js index b28e0ea68e..df12193250 100644 --- a/tests/baselines/reference/computedPropertyNames22_ES5.js +++ b/tests/baselines/reference/computedPropertyNames22_ES5.js @@ -14,8 +14,7 @@ var C = (function () { } C.prototype.bar = function () { var obj = (_a = {}, - _a[this.bar()] = function () { - }, + _a[this.bar()] = function () { }, _a); return 0; var _a; diff --git a/tests/baselines/reference/computedPropertyNames22_ES6.js b/tests/baselines/reference/computedPropertyNames22_ES6.js index c88ceb6bc8..5fd0487d23 100644 --- a/tests/baselines/reference/computedPropertyNames22_ES6.js +++ b/tests/baselines/reference/computedPropertyNames22_ES6.js @@ -12,8 +12,7 @@ class C { class C { bar() { var obj = { - [this.bar()]() { - } + [this.bar()]() { } }; return 0; } diff --git a/tests/baselines/reference/computedPropertyNames23_ES5.js b/tests/baselines/reference/computedPropertyNames23_ES5.js index 34eb089637..8f68d9f310 100644 --- a/tests/baselines/reference/computedPropertyNames23_ES5.js +++ b/tests/baselines/reference/computedPropertyNames23_ES5.js @@ -17,8 +17,7 @@ var C = (function () { }; C.prototype[(_a = {}, _a[this.bar()] = 1, - _a)[0]] = function () { - }; + _a)[0]] = function () { }; return C; var _a; })(); diff --git a/tests/baselines/reference/computedPropertyNames23_ES6.js b/tests/baselines/reference/computedPropertyNames23_ES6.js index 0bae1abdad..2103c26d19 100644 --- a/tests/baselines/reference/computedPropertyNames23_ES6.js +++ b/tests/baselines/reference/computedPropertyNames23_ES6.js @@ -13,8 +13,5 @@ class C { bar() { return 0; } - [{ - [this.bar()]: 1 - }[0]]() { - } + [{ [this.bar()]: 1 }[0]]() { } } diff --git a/tests/baselines/reference/computedPropertyNames24_ES5.js b/tests/baselines/reference/computedPropertyNames24_ES5.js index cea5240003..3fd4d41d0c 100644 --- a/tests/baselines/reference/computedPropertyNames24_ES5.js +++ b/tests/baselines/reference/computedPropertyNames24_ES5.js @@ -28,7 +28,6 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype[_super.bar.call(this)] = function () { - }; + C.prototype[_super.bar.call(this)] = function () { }; return C; })(Base); diff --git a/tests/baselines/reference/computedPropertyNames24_ES6.js b/tests/baselines/reference/computedPropertyNames24_ES6.js index 8d33db10f7..8441ae9111 100644 --- a/tests/baselines/reference/computedPropertyNames24_ES6.js +++ b/tests/baselines/reference/computedPropertyNames24_ES6.js @@ -19,6 +19,5 @@ class Base { class C extends Base { // Gets emitted as super, not _super, which is consistent with // use of super in static properties initializers. - [super.bar()]() { - } + [super.bar()]() { } } diff --git a/tests/baselines/reference/computedPropertyNames25_ES5.js b/tests/baselines/reference/computedPropertyNames25_ES5.js index 4bcf877c57..f8196dd130 100644 --- a/tests/baselines/reference/computedPropertyNames25_ES5.js +++ b/tests/baselines/reference/computedPropertyNames25_ES5.js @@ -35,8 +35,7 @@ var C = (function (_super) { } C.prototype.foo = function () { var obj = (_a = {}, - _a[_super.prototype.bar.call(this)] = function () { - }, + _a[_super.prototype.bar.call(this)] = function () { }, _a); return 0; var _a; diff --git a/tests/baselines/reference/computedPropertyNames25_ES6.js b/tests/baselines/reference/computedPropertyNames25_ES6.js index cc6a0670b2..5fa7071c65 100644 --- a/tests/baselines/reference/computedPropertyNames25_ES6.js +++ b/tests/baselines/reference/computedPropertyNames25_ES6.js @@ -22,8 +22,7 @@ class Base { class C extends Base { foo() { var obj = { - [super.bar()]() { - } + [super.bar()]() { } }; return 0; } diff --git a/tests/baselines/reference/computedPropertyNames26_ES5.js b/tests/baselines/reference/computedPropertyNames26_ES5.js index cac71f734a..884d5c0f66 100644 --- a/tests/baselines/reference/computedPropertyNames26_ES5.js +++ b/tests/baselines/reference/computedPropertyNames26_ES5.js @@ -32,8 +32,7 @@ var C = (function (_super) { } C.prototype[(_a = {}, _a[_super.bar.call(this)] = 1, - _a)[0]] = function () { - }; + _a)[0]] = function () { }; return C; var _a; })(Base); diff --git a/tests/baselines/reference/computedPropertyNames26_ES6.js b/tests/baselines/reference/computedPropertyNames26_ES6.js index 4526368de7..bdf65456e4 100644 --- a/tests/baselines/reference/computedPropertyNames26_ES6.js +++ b/tests/baselines/reference/computedPropertyNames26_ES6.js @@ -21,8 +21,5 @@ class Base { class C extends Base { // Gets emitted as super, not _super, which is consistent with // use of super in static properties initializers. - [{ - [super.bar()]: 1 - }[0]]() { - } + [{ [super.bar()]: 1 }[0]]() { } } diff --git a/tests/baselines/reference/computedPropertyNames27_ES5.js b/tests/baselines/reference/computedPropertyNames27_ES5.js index 2f550731df..df1fed0972 100644 --- a/tests/baselines/reference/computedPropertyNames27_ES5.js +++ b/tests/baselines/reference/computedPropertyNames27_ES5.js @@ -22,7 +22,6 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype[(_super.call(this), "prop")] = function () { - }; + C.prototype[(_super.call(this), "prop")] = function () { }; return C; })(Base); diff --git a/tests/baselines/reference/computedPropertyNames27_ES6.js b/tests/baselines/reference/computedPropertyNames27_ES6.js index 57589dfcaf..947d9fafe1 100644 --- a/tests/baselines/reference/computedPropertyNames27_ES6.js +++ b/tests/baselines/reference/computedPropertyNames27_ES6.js @@ -9,6 +9,5 @@ class C extends Base { class Base { } class C extends Base { - [(super(), "prop")]() { - } + [(super(), "prop")]() { } } diff --git a/tests/baselines/reference/computedPropertyNames28_ES5.js b/tests/baselines/reference/computedPropertyNames28_ES5.js index 418252784a..b88cb0dfaf 100644 --- a/tests/baselines/reference/computedPropertyNames28_ES5.js +++ b/tests/baselines/reference/computedPropertyNames28_ES5.js @@ -27,8 +27,7 @@ var C = (function (_super) { function C() { _super.call(this); var obj = (_a = {}, - _a[(_super.call(this), "prop")] = function () { - }, + _a[(_super.call(this), "prop")] = function () { }, _a); var _a; } diff --git a/tests/baselines/reference/computedPropertyNames28_ES6.js b/tests/baselines/reference/computedPropertyNames28_ES6.js index bc0e32593d..0897df3d33 100644 --- a/tests/baselines/reference/computedPropertyNames28_ES6.js +++ b/tests/baselines/reference/computedPropertyNames28_ES6.js @@ -17,8 +17,7 @@ class C extends Base { constructor() { super(); var obj = { - [(super(), "prop")]() { - } + [(super(), "prop")]() { } }; } } diff --git a/tests/baselines/reference/computedPropertyNames29_ES5.js b/tests/baselines/reference/computedPropertyNames29_ES5.js index 93a80128d9..022c930ab6 100644 --- a/tests/baselines/reference/computedPropertyNames29_ES5.js +++ b/tests/baselines/reference/computedPropertyNames29_ES5.js @@ -18,8 +18,7 @@ var C = (function () { var _this = this; (function () { var obj = (_a = {}, - _a[_this.bar()] = function () { - }, + _a[_this.bar()] = function () { }, _a); var _a; }); diff --git a/tests/baselines/reference/computedPropertyNames29_ES6.js b/tests/baselines/reference/computedPropertyNames29_ES6.js index 35958b372b..1aa479555d 100644 --- a/tests/baselines/reference/computedPropertyNames29_ES6.js +++ b/tests/baselines/reference/computedPropertyNames29_ES6.js @@ -15,8 +15,7 @@ class C { bar() { (() => { var obj = { - [this.bar()]() { - } // needs capture + [this.bar()]() { } // needs capture }; }); return 0; diff --git a/tests/baselines/reference/computedPropertyNames2_ES5.js b/tests/baselines/reference/computedPropertyNames2_ES5.js index 97d9a673bb..581b581d87 100644 --- a/tests/baselines/reference/computedPropertyNames2_ES5.js +++ b/tests/baselines/reference/computedPropertyNames2_ES5.js @@ -16,31 +16,25 @@ var accessorName = "accessor"; var C = (function () { function C() { } - C.prototype[methodName] = function () { - }; - C[methodName] = function () { - }; + C.prototype[methodName] = function () { }; + C[methodName] = function () { }; Object.defineProperty(C.prototype, accessorName, { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, accessorName, { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C, accessorName, { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); Object.defineProperty(C, accessorName, { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames2_ES6.js b/tests/baselines/reference/computedPropertyNames2_ES6.js index 4287cb2c4b..9eeb1a609f 100644 --- a/tests/baselines/reference/computedPropertyNames2_ES6.js +++ b/tests/baselines/reference/computedPropertyNames2_ES6.js @@ -14,16 +14,10 @@ class C { var methodName = "method"; var accessorName = "accessor"; class C { - [methodName]() { - } - static [methodName]() { - } - get [accessorName]() { - } - set [accessorName](v) { - } - static get [accessorName]() { - } - static set [accessorName](v) { - } + [methodName]() { } + static [methodName]() { } + get [accessorName]() { } + set [accessorName](v) { } + static get [accessorName]() { } + static set [accessorName](v) { } } diff --git a/tests/baselines/reference/computedPropertyNames30_ES5.js b/tests/baselines/reference/computedPropertyNames30_ES5.js index b11b651a0d..fd63a192d0 100644 --- a/tests/baselines/reference/computedPropertyNames30_ES5.js +++ b/tests/baselines/reference/computedPropertyNames30_ES5.js @@ -33,8 +33,7 @@ var C = (function (_super) { _super.call(this); (function () { var obj = (_a = {}, - _a[(_super.call(this), "prop")] = function () { - }, + _a[(_super.call(this), "prop")] = function () { }, _a); var _a; }); diff --git a/tests/baselines/reference/computedPropertyNames30_ES6.js b/tests/baselines/reference/computedPropertyNames30_ES6.js index cda2a278d4..44a475fed9 100644 --- a/tests/baselines/reference/computedPropertyNames30_ES6.js +++ b/tests/baselines/reference/computedPropertyNames30_ES6.js @@ -26,8 +26,7 @@ class C extends Base { // Ideally, we would capture this. But the reference is // illegal, and not capturing this is consistent with //treatment of other similar violations. - [(super(), "prop")]() { - } + [(super(), "prop")]() { } }; }); } diff --git a/tests/baselines/reference/computedPropertyNames31_ES5.js b/tests/baselines/reference/computedPropertyNames31_ES5.js index a079b3fa44..8a3c1a3f6c 100644 --- a/tests/baselines/reference/computedPropertyNames31_ES5.js +++ b/tests/baselines/reference/computedPropertyNames31_ES5.js @@ -39,8 +39,7 @@ var C = (function (_super) { var _this = this; (function () { var obj = (_a = {}, - _a[_super.prototype.bar.call(_this)] = function () { - }, + _a[_super.prototype.bar.call(_this)] = function () { }, _a); var _a; }); diff --git a/tests/baselines/reference/computedPropertyNames31_ES6.js b/tests/baselines/reference/computedPropertyNames31_ES6.js index 777e03bbca..2c63dcee07 100644 --- a/tests/baselines/reference/computedPropertyNames31_ES6.js +++ b/tests/baselines/reference/computedPropertyNames31_ES6.js @@ -26,8 +26,7 @@ class C extends Base { var _this = this; (() => { var obj = { - [super.bar()]() { - } // needs capture + [super.bar()]() { } // needs capture }; }); return 0; diff --git a/tests/baselines/reference/computedPropertyNames32_ES5.js b/tests/baselines/reference/computedPropertyNames32_ES5.js index 5a54120258..a0d8b066b5 100644 --- a/tests/baselines/reference/computedPropertyNames32_ES5.js +++ b/tests/baselines/reference/computedPropertyNames32_ES5.js @@ -8,16 +8,13 @@ class C { } //// [computedPropertyNames32_ES5.js] -function foo() { - return ''; -} +function foo() { return ''; } var C = (function () { function C() { } C.prototype.bar = function () { return 0; }; - C.prototype[foo()] = function () { - }; + C.prototype[foo()] = function () { }; return C; })(); diff --git a/tests/baselines/reference/computedPropertyNames32_ES6.js b/tests/baselines/reference/computedPropertyNames32_ES6.js index 198c5e9981..07d331d923 100644 --- a/tests/baselines/reference/computedPropertyNames32_ES6.js +++ b/tests/baselines/reference/computedPropertyNames32_ES6.js @@ -8,13 +8,10 @@ class C { } //// [computedPropertyNames32_ES6.js] -function foo() { - return ''; -} +function foo() { return ''; } class C { bar() { return 0; } - [foo()]() { - } + [foo()]() { } } diff --git a/tests/baselines/reference/computedPropertyNames33_ES5.js b/tests/baselines/reference/computedPropertyNames33_ES5.js index 2436235119..3d7c70a925 100644 --- a/tests/baselines/reference/computedPropertyNames33_ES5.js +++ b/tests/baselines/reference/computedPropertyNames33_ES5.js @@ -10,16 +10,13 @@ class C { } //// [computedPropertyNames33_ES5.js] -function foo() { - return ''; -} +function foo() { return ''; } var C = (function () { function C() { } C.prototype.bar = function () { var obj = (_a = {}, - _a[foo()] = function () { - }, + _a[foo()] = function () { }, _a); return 0; var _a; diff --git a/tests/baselines/reference/computedPropertyNames33_ES6.js b/tests/baselines/reference/computedPropertyNames33_ES6.js index 7fb08d2852..2a74f48634 100644 --- a/tests/baselines/reference/computedPropertyNames33_ES6.js +++ b/tests/baselines/reference/computedPropertyNames33_ES6.js @@ -10,14 +10,11 @@ class C { } //// [computedPropertyNames33_ES6.js] -function foo() { - return ''; -} +function foo() { return ''; } class C { bar() { var obj = { - [foo()]() { - } + [foo()]() { } }; return 0; } diff --git a/tests/baselines/reference/computedPropertyNames34_ES5.js b/tests/baselines/reference/computedPropertyNames34_ES5.js index 83e757222b..fd46b144fa 100644 --- a/tests/baselines/reference/computedPropertyNames34_ES5.js +++ b/tests/baselines/reference/computedPropertyNames34_ES5.js @@ -10,16 +10,13 @@ class C { } //// [computedPropertyNames34_ES5.js] -function foo() { - return ''; -} +function foo() { return ''; } var C = (function () { function C() { } C.bar = function () { var obj = (_a = {}, - _a[foo()] = function () { - }, + _a[foo()] = function () { }, _a); return 0; var _a; diff --git a/tests/baselines/reference/computedPropertyNames34_ES6.js b/tests/baselines/reference/computedPropertyNames34_ES6.js index e73d349bcd..6952805284 100644 --- a/tests/baselines/reference/computedPropertyNames34_ES6.js +++ b/tests/baselines/reference/computedPropertyNames34_ES6.js @@ -10,14 +10,11 @@ class C { } //// [computedPropertyNames34_ES6.js] -function foo() { - return ''; -} +function foo() { return ''; } class C { static bar() { var obj = { - [foo()]() { - } + [foo()]() { } }; return 0; } diff --git a/tests/baselines/reference/computedPropertyNames35_ES5.js b/tests/baselines/reference/computedPropertyNames35_ES5.js index b55743a2d8..0804c946f1 100644 --- a/tests/baselines/reference/computedPropertyNames35_ES5.js +++ b/tests/baselines/reference/computedPropertyNames35_ES5.js @@ -6,6 +6,4 @@ interface I { } //// [computedPropertyNames35_ES5.js] -function foo() { - return ''; -} +function foo() { return ''; } diff --git a/tests/baselines/reference/computedPropertyNames35_ES6.js b/tests/baselines/reference/computedPropertyNames35_ES6.js index b08d7c0f31..2d3f408831 100644 --- a/tests/baselines/reference/computedPropertyNames35_ES6.js +++ b/tests/baselines/reference/computedPropertyNames35_ES6.js @@ -6,6 +6,4 @@ interface I { } //// [computedPropertyNames35_ES6.js] -function foo() { - return ''; -} +function foo() { return ''; } diff --git a/tests/baselines/reference/computedPropertyNames36_ES5.js b/tests/baselines/reference/computedPropertyNames36_ES5.js index fa92da7b7b..5519a6d284 100644 --- a/tests/baselines/reference/computedPropertyNames36_ES5.js +++ b/tests/baselines/reference/computedPropertyNames36_ES5.js @@ -26,15 +26,12 @@ var C = (function () { } Object.defineProperty(C.prototype, "get1", { // Computed properties - get: function () { - return new Foo; - }, + get: function () { return new Foo; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, "set1", { - set: function (p) { - }, + set: function (p) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames36_ES6.js b/tests/baselines/reference/computedPropertyNames36_ES6.js index 573b8fa0c1..5d10ceef31 100644 --- a/tests/baselines/reference/computedPropertyNames36_ES6.js +++ b/tests/baselines/reference/computedPropertyNames36_ES6.js @@ -17,9 +17,6 @@ class Foo2 { } class C { // Computed properties - get ["get1"]() { - return new Foo; - } - set ["set1"](p) { - } + get ["get1"]() { return new Foo; } + set ["set1"](p) { } } diff --git a/tests/baselines/reference/computedPropertyNames37_ES5.js b/tests/baselines/reference/computedPropertyNames37_ES5.js index f185e93db3..54a7243f3f 100644 --- a/tests/baselines/reference/computedPropertyNames37_ES5.js +++ b/tests/baselines/reference/computedPropertyNames37_ES5.js @@ -26,15 +26,12 @@ var C = (function () { } Object.defineProperty(C.prototype, "get1", { // Computed properties - get: function () { - return new Foo; - }, + get: function () { return new Foo; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, "set1", { - set: function (p) { - }, + set: function (p) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames37_ES6.js b/tests/baselines/reference/computedPropertyNames37_ES6.js index d62c95e6f8..025df25d05 100644 --- a/tests/baselines/reference/computedPropertyNames37_ES6.js +++ b/tests/baselines/reference/computedPropertyNames37_ES6.js @@ -17,9 +17,6 @@ class Foo2 { } class C { // Computed properties - get ["get1"]() { - return new Foo; - } - set ["set1"](p) { - } + get ["get1"]() { return new Foo; } + set ["set1"](p) { } } diff --git a/tests/baselines/reference/computedPropertyNames38_ES5.js b/tests/baselines/reference/computedPropertyNames38_ES5.js index 42115927b3..49af4d00d5 100644 --- a/tests/baselines/reference/computedPropertyNames38_ES5.js +++ b/tests/baselines/reference/computedPropertyNames38_ES5.js @@ -26,15 +26,12 @@ var C = (function () { } Object.defineProperty(C.prototype, 1 << 6, { // Computed properties - get: function () { - return new Foo; - }, + get: function () { return new Foo; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, 1 << 6, { - set: function (p) { - }, + set: function (p) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames38_ES6.js b/tests/baselines/reference/computedPropertyNames38_ES6.js index cf1d01873f..ea87afedcc 100644 --- a/tests/baselines/reference/computedPropertyNames38_ES6.js +++ b/tests/baselines/reference/computedPropertyNames38_ES6.js @@ -17,9 +17,6 @@ class Foo2 { } class C { // Computed properties - get [1 << 6]() { - return new Foo; - } - set [1 << 6](p) { - } + get [1 << 6]() { return new Foo; } + set [1 << 6](p) { } } diff --git a/tests/baselines/reference/computedPropertyNames39_ES5.js b/tests/baselines/reference/computedPropertyNames39_ES5.js index 12cc55f131..1b8d3aab2f 100644 --- a/tests/baselines/reference/computedPropertyNames39_ES5.js +++ b/tests/baselines/reference/computedPropertyNames39_ES5.js @@ -26,15 +26,12 @@ var C = (function () { } Object.defineProperty(C.prototype, 1 << 6, { // Computed properties - get: function () { - return new Foo; - }, + get: function () { return new Foo; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, 1 << 6, { - set: function (p) { - }, + set: function (p) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames39_ES6.js b/tests/baselines/reference/computedPropertyNames39_ES6.js index 9afd60b646..a874140da0 100644 --- a/tests/baselines/reference/computedPropertyNames39_ES6.js +++ b/tests/baselines/reference/computedPropertyNames39_ES6.js @@ -17,9 +17,6 @@ class Foo2 { } class C { // Computed properties - get [1 << 6]() { - return new Foo; - } - set [1 << 6](p) { - } + get [1 << 6]() { return new Foo; } + set [1 << 6](p) { } } diff --git a/tests/baselines/reference/computedPropertyNames3_ES5.js b/tests/baselines/reference/computedPropertyNames3_ES5.js index 09440d5601..f5a063f91e 100644 --- a/tests/baselines/reference/computedPropertyNames3_ES5.js +++ b/tests/baselines/reference/computedPropertyNames3_ES5.js @@ -14,35 +14,25 @@ var id; var C = (function () { function C() { } - C.prototype[0 + 1] = function () { - }; - C[function () { - }] = function () { - }; + C.prototype[0 + 1] = function () { }; + C[function () { }] = function () { }; Object.defineProperty(C.prototype, delete id, { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); - Object.defineProperty(C.prototype, [ - 0, - 1 - ], { - set: function (v) { - }, + Object.defineProperty(C.prototype, [0, 1], { + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C, "", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); Object.defineProperty(C, id.toString(), { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames3_ES6.js b/tests/baselines/reference/computedPropertyNames3_ES6.js index b5fb9e8800..d12d7d1866 100644 --- a/tests/baselines/reference/computedPropertyNames3_ES6.js +++ b/tests/baselines/reference/computedPropertyNames3_ES6.js @@ -12,20 +12,10 @@ class C { //// [computedPropertyNames3_ES6.js] var id; class C { - [0 + 1]() { - } - static [() => { - }]() { - } - get [delete id]() { - } - set [[ - 0, - 1 - ]](v) { - } - static get [""]() { - } - static set [id.toString()](v) { - } + [0 + 1]() { } + static [() => { }]() { } + get [delete id]() { } + set [[0, 1]](v) { } + static get [""]() { } + static set [id.toString()](v) { } } diff --git a/tests/baselines/reference/computedPropertyNames40_ES5.js b/tests/baselines/reference/computedPropertyNames40_ES5.js index 887c5c3847..e806376202 100644 --- a/tests/baselines/reference/computedPropertyNames40_ES5.js +++ b/tests/baselines/reference/computedPropertyNames40_ES5.js @@ -25,11 +25,7 @@ var C = (function () { function C() { } // Computed properties - C.prototype[""] = function () { - return new Foo; - }; - C.prototype[""] = function () { - return new Foo2; - }; + C.prototype[""] = function () { return new Foo; }; + C.prototype[""] = function () { return new Foo2; }; return C; })(); diff --git a/tests/baselines/reference/computedPropertyNames40_ES6.js b/tests/baselines/reference/computedPropertyNames40_ES6.js index c4820e0ca9..af566425d5 100644 --- a/tests/baselines/reference/computedPropertyNames40_ES6.js +++ b/tests/baselines/reference/computedPropertyNames40_ES6.js @@ -17,10 +17,6 @@ class Foo2 { } class C { // Computed properties - [""]() { - return new Foo; - } - [""]() { - return new Foo2; - } + [""]() { return new Foo; } + [""]() { return new Foo2; } } diff --git a/tests/baselines/reference/computedPropertyNames41_ES5.js b/tests/baselines/reference/computedPropertyNames41_ES5.js index b4223ec521..7d7c390bf3 100644 --- a/tests/baselines/reference/computedPropertyNames41_ES5.js +++ b/tests/baselines/reference/computedPropertyNames41_ES5.js @@ -24,8 +24,6 @@ var C = (function () { function C() { } // Computed properties - C[""] = function () { - return new Foo; - }; + C[""] = function () { return new Foo; }; return C; })(); diff --git a/tests/baselines/reference/computedPropertyNames41_ES6.js b/tests/baselines/reference/computedPropertyNames41_ES6.js index 5773f892fd..b27f8da01d 100644 --- a/tests/baselines/reference/computedPropertyNames41_ES6.js +++ b/tests/baselines/reference/computedPropertyNames41_ES6.js @@ -16,7 +16,5 @@ class Foo2 { } class C { // Computed properties - static [""]() { - return new Foo; - } + static [""]() { return new Foo; } } diff --git a/tests/baselines/reference/computedPropertyNames43_ES5.js b/tests/baselines/reference/computedPropertyNames43_ES5.js index f7faa34798..b689f02ee9 100644 --- a/tests/baselines/reference/computedPropertyNames43_ES5.js +++ b/tests/baselines/reference/computedPropertyNames43_ES5.js @@ -41,15 +41,12 @@ var D = (function (_super) { } Object.defineProperty(D.prototype, "get1", { // Computed properties - get: function () { - return new Foo; - }, + get: function () { return new Foo; }, enumerable: true, configurable: true }); Object.defineProperty(D.prototype, "set1", { - set: function (p) { - }, + set: function (p) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames43_ES6.js b/tests/baselines/reference/computedPropertyNames43_ES6.js index ab9d09834d..346c2a0d30 100644 --- a/tests/baselines/reference/computedPropertyNames43_ES6.js +++ b/tests/baselines/reference/computedPropertyNames43_ES6.js @@ -21,9 +21,6 @@ class C { } class D extends C { // Computed properties - get ["get1"]() { - return new Foo; - } - set ["set1"](p) { - } + get ["get1"]() { return new Foo; } + set ["set1"](p) { } } diff --git a/tests/baselines/reference/computedPropertyNames44_ES5.js b/tests/baselines/reference/computedPropertyNames44_ES5.js index 072b3e9068..32d3505e25 100644 --- a/tests/baselines/reference/computedPropertyNames44_ES5.js +++ b/tests/baselines/reference/computedPropertyNames44_ES5.js @@ -32,9 +32,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "get1", { - get: function () { - return new Foo; - }, + get: function () { return new Foo; }, enumerable: true, configurable: true }); @@ -46,8 +44,7 @@ var D = (function (_super) { _super.apply(this, arguments); } Object.defineProperty(D.prototype, "set1", { - set: function (p) { - }, + set: function (p) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames44_ES6.js b/tests/baselines/reference/computedPropertyNames44_ES6.js index 13d46131e9..cd1b8c5da2 100644 --- a/tests/baselines/reference/computedPropertyNames44_ES6.js +++ b/tests/baselines/reference/computedPropertyNames44_ES6.js @@ -17,11 +17,8 @@ class Foo { class Foo2 { } class C { - get ["get1"]() { - return new Foo; - } + get ["get1"]() { return new Foo; } } class D extends C { - set ["set1"](p) { - } + set ["set1"](p) { } } diff --git a/tests/baselines/reference/computedPropertyNames45_ES5.js b/tests/baselines/reference/computedPropertyNames45_ES5.js index 4389b32a83..3d924b00b7 100644 --- a/tests/baselines/reference/computedPropertyNames45_ES5.js +++ b/tests/baselines/reference/computedPropertyNames45_ES5.js @@ -33,9 +33,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "get1", { - get: function () { - return new Foo; - }, + get: function () { return new Foo; }, enumerable: true, configurable: true }); @@ -47,8 +45,7 @@ var D = (function (_super) { _super.apply(this, arguments); } Object.defineProperty(D.prototype, "set1", { - set: function (p) { - }, + set: function (p) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNames45_ES6.js b/tests/baselines/reference/computedPropertyNames45_ES6.js index bea5f5211e..2c01d7625e 100644 --- a/tests/baselines/reference/computedPropertyNames45_ES6.js +++ b/tests/baselines/reference/computedPropertyNames45_ES6.js @@ -18,11 +18,8 @@ class Foo { class Foo2 { } class C { - get ["get1"]() { - return new Foo; - } + get ["get1"]() { return new Foo; } } class D extends C { - set ["set1"](p) { - } + set ["set1"](p) { } } diff --git a/tests/baselines/reference/computedPropertyNames49_ES5.js b/tests/baselines/reference/computedPropertyNames49_ES5.js index 27730d56df..5f952c6f3f 100644 --- a/tests/baselines/reference/computedPropertyNames49_ES5.js +++ b/tests/baselines/reference/computedPropertyNames49_ES5.js @@ -30,37 +30,21 @@ var x = (_a = { p1: 10 }, _a.p1 = 10, - _a[1 + 1] = Object.defineProperty({ - get: function () { + _a[1 + 1] = Object.defineProperty({ get: function () { throw 10; - }, - enumerable: true, - configurable: true - }), - _a[1 + 1] = Object.defineProperty({ - get: function () { + }, enumerable: true, configurable: true }), + _a[1 + 1] = Object.defineProperty({ get: function () { return 10; - }, - enumerable: true, - configurable: true - }), - _a[1 + 1] = Object.defineProperty({ - set: function () { + }, enumerable: true, configurable: true }), + _a[1 + 1] = Object.defineProperty({ set: function () { // just throw throw 10; - }, - enumerable: true, - configurable: true - }), - _a.foo = Object.defineProperty({ - get: function () { + }, enumerable: true, configurable: true }), + _a.foo = Object.defineProperty({ get: function () { if (1 == 1) { return 10; } - }, - enumerable: true, - configurable: true - }), + }, enumerable: true, configurable: true }), _a.p2 = 20, _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNames50_ES5.js b/tests/baselines/reference/computedPropertyNames50_ES5.js index 4221a21a76..32502d80e0 100644 --- a/tests/baselines/reference/computedPropertyNames50_ES5.js +++ b/tests/baselines/reference/computedPropertyNames50_ES5.js @@ -35,37 +35,21 @@ var x = (_a = { } }, _a.p1 = 10, - _a.foo = Object.defineProperty({ - get: function () { + _a.foo = Object.defineProperty({ get: function () { if (1 == 1) { return 10; } - }, - enumerable: true, - configurable: true - }), - _a[1 + 1] = Object.defineProperty({ - get: function () { + }, enumerable: true, configurable: true }), + _a[1 + 1] = Object.defineProperty({ get: function () { throw 10; - }, - enumerable: true, - configurable: true - }), - _a[1 + 1] = Object.defineProperty({ - set: function () { + }, enumerable: true, configurable: true }), + _a[1 + 1] = Object.defineProperty({ set: function () { // just throw throw 10; - }, - enumerable: true, - configurable: true - }), - _a[1 + 1] = Object.defineProperty({ - get: function () { + }, enumerable: true, configurable: true }), + _a[1 + 1] = Object.defineProperty({ get: function () { return 10; - }, - enumerable: true, - configurable: true - }), + }, enumerable: true, configurable: true }), _a.p2 = 20, _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNames9_ES5.js b/tests/baselines/reference/computedPropertyNames9_ES5.js index 1b4fa16de2..b1ac6c9e3b 100644 --- a/tests/baselines/reference/computedPropertyNames9_ES5.js +++ b/tests/baselines/reference/computedPropertyNames9_ES5.js @@ -11,8 +11,7 @@ var v = { } //// [computedPropertyNames9_ES5.js] -function f(x) { -} +function f(x) { } var v = (_a = {}, _a[f("")] = 0, _a[f(0)] = 0, diff --git a/tests/baselines/reference/computedPropertyNames9_ES6.js b/tests/baselines/reference/computedPropertyNames9_ES6.js index 8f111935b0..b0e66c81cb 100644 --- a/tests/baselines/reference/computedPropertyNames9_ES6.js +++ b/tests/baselines/reference/computedPropertyNames9_ES6.js @@ -11,8 +11,7 @@ var v = { } //// [computedPropertyNames9_ES6.js] -function f(x) { -} +function f(x) { } var v = { [f("")]: 0, [f(0)]: 0, diff --git a/tests/baselines/reference/computedPropertyNamesContextualType1_ES5.js b/tests/baselines/reference/computedPropertyNamesContextualType1_ES5.js index a74e04937c..1ee8835115 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType1_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType1_ES5.js @@ -11,11 +11,7 @@ var o: I = { //// [computedPropertyNamesContextualType1_ES5.js] var o = (_a = {}, - _a["" + 0] = function (y) { - return y.length; - }, - _a["" + 1] = function (y) { - return y.length; - }, + _a["" + 0] = function (y) { return y.length; }, + _a["" + 1] = function (y) { return y.length; }, _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNamesContextualType1_ES6.js b/tests/baselines/reference/computedPropertyNamesContextualType1_ES6.js index b202d656b7..4c4dfb9f9a 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType1_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType1_ES6.js @@ -11,8 +11,6 @@ var o: I = { //// [computedPropertyNamesContextualType1_ES6.js] var o = { - ["" + 0](y) { - return y.length; - }, + ["" + 0](y) { return y.length; }, ["" + 1]: y => y.length }; diff --git a/tests/baselines/reference/computedPropertyNamesContextualType2_ES5.js b/tests/baselines/reference/computedPropertyNamesContextualType2_ES5.js index b33ff276fc..6be09e4bef 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType2_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType2_ES5.js @@ -11,11 +11,7 @@ var o: I = { //// [computedPropertyNamesContextualType2_ES5.js] var o = (_a = {}, - _a[+"foo"] = function (y) { - return y.length; - }, - _a[+"bar"] = function (y) { - return y.length; - }, + _a[+"foo"] = function (y) { return y.length; }, + _a[+"bar"] = function (y) { return y.length; }, _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNamesContextualType2_ES6.js b/tests/baselines/reference/computedPropertyNamesContextualType2_ES6.js index 6be2c11cc5..1f0704ce8a 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType2_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType2_ES6.js @@ -11,8 +11,6 @@ var o: I = { //// [computedPropertyNamesContextualType2_ES6.js] var o = { - [+"foo"](y) { - return y.length; - }, + [+"foo"](y) { return y.length; }, [+"bar"]: y => y.length }; diff --git a/tests/baselines/reference/computedPropertyNamesContextualType3_ES5.js b/tests/baselines/reference/computedPropertyNamesContextualType3_ES5.js index c3f189a578..b510cda291 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType3_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType3_ES5.js @@ -10,11 +10,7 @@ var o: I = { //// [computedPropertyNamesContextualType3_ES5.js] var o = (_a = {}, - _a[+"foo"] = function (y) { - return y.length; - }, - _a[+"bar"] = function (y) { - return y.length; - }, + _a[+"foo"] = function (y) { return y.length; }, + _a[+"bar"] = function (y) { return y.length; }, _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNamesContextualType3_ES6.js b/tests/baselines/reference/computedPropertyNamesContextualType3_ES6.js index 6124271a57..08d39bbeae 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType3_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType3_ES6.js @@ -10,8 +10,6 @@ var o: I = { //// [computedPropertyNamesContextualType3_ES6.js] var o = { - [+"foo"](y) { - return y.length; - }, + [+"foo"](y) { return y.length; }, [+"bar"]: y => y.length }; diff --git a/tests/baselines/reference/computedPropertyNamesContextualType6_ES5.js b/tests/baselines/reference/computedPropertyNamesContextualType6_ES5.js index d60690a249..f50231e3f0 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType6_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType6_ES5.js @@ -16,16 +16,12 @@ foo({ //// [computedPropertyNamesContextualType6_ES5.js] foo((_a = { p: "", - 0: function () { - } + 0: function () { } }, _a.p = "", - _a[0] = function () { - }, + _a[0] = function () { }, _a["hi" + "bye"] = true, _a[0 + 1] = 0, - _a[+"hi"] = [ - 0 - ], + _a[+"hi"] = [0], _a)); var _a; diff --git a/tests/baselines/reference/computedPropertyNamesContextualType6_ES6.js b/tests/baselines/reference/computedPropertyNamesContextualType6_ES6.js index e7218fff23..1360cc2002 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType6_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType6_ES6.js @@ -16,11 +16,8 @@ foo({ //// [computedPropertyNamesContextualType6_ES6.js] foo({ p: "", - 0: () => { - }, + 0: () => { }, ["hi" + "bye"]: true, [0 + 1]: 0, - [+"hi"]: [ - 0 - ] + [+"hi"]: [0] }); diff --git a/tests/baselines/reference/computedPropertyNamesContextualType7_ES5.js b/tests/baselines/reference/computedPropertyNamesContextualType7_ES5.js index 02c2ffa734..e1c567c62d 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType7_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType7_ES5.js @@ -16,16 +16,12 @@ foo({ //// [computedPropertyNamesContextualType7_ES5.js] foo((_a = { p: "", - 0: function () { - } + 0: function () { } }, _a.p = "", - _a[0] = function () { - }, + _a[0] = function () { }, _a["hi" + "bye"] = true, _a[0 + 1] = 0, - _a[+"hi"] = [ - 0 - ], + _a[+"hi"] = [0], _a)); var _a; diff --git a/tests/baselines/reference/computedPropertyNamesContextualType7_ES6.js b/tests/baselines/reference/computedPropertyNamesContextualType7_ES6.js index d6b50e93ae..185ccd72ea 100644 --- a/tests/baselines/reference/computedPropertyNamesContextualType7_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesContextualType7_ES6.js @@ -16,11 +16,8 @@ foo({ //// [computedPropertyNamesContextualType7_ES6.js] foo({ p: "", - 0: () => { - }, + 0: () => { }, ["hi" + "bye"]: true, [0 + 1]: 0, - [+"hi"]: [ - 0 - ] + [+"hi"]: [0] }); diff --git a/tests/baselines/reference/computedPropertyNamesDeclarationEmit1_ES5.js b/tests/baselines/reference/computedPropertyNamesDeclarationEmit1_ES5.js index c091003735..84b92f6c92 100644 --- a/tests/baselines/reference/computedPropertyNamesDeclarationEmit1_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesDeclarationEmit1_ES5.js @@ -9,18 +9,14 @@ class C { var C = (function () { function C() { } - C.prototype["" + ""] = function () { - }; + C.prototype["" + ""] = function () { }; Object.defineProperty(C.prototype, "" + "", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C.prototype, "" + "", { - set: function (x) { - }, + set: function (x) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNamesDeclarationEmit1_ES6.js b/tests/baselines/reference/computedPropertyNamesDeclarationEmit1_ES6.js index f234ae0d97..2cdb6e3460 100644 --- a/tests/baselines/reference/computedPropertyNamesDeclarationEmit1_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesDeclarationEmit1_ES6.js @@ -7,13 +7,9 @@ class C { //// [computedPropertyNamesDeclarationEmit1_ES6.js] class C { - ["" + ""]() { - } - get ["" + ""]() { - return 0; - } - set ["" + ""](x) { - } + ["" + ""]() { } + get ["" + ""]() { return 0; } + set ["" + ""](x) { } } diff --git a/tests/baselines/reference/computedPropertyNamesDeclarationEmit2_ES5.js b/tests/baselines/reference/computedPropertyNamesDeclarationEmit2_ES5.js index 22a5b0d305..9847ea8b7e 100644 --- a/tests/baselines/reference/computedPropertyNamesDeclarationEmit2_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesDeclarationEmit2_ES5.js @@ -9,18 +9,14 @@ class C { var C = (function () { function C() { } - C["" + ""] = function () { - }; + C["" + ""] = function () { }; Object.defineProperty(C, "" + "", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); Object.defineProperty(C, "" + "", { - set: function (x) { - }, + set: function (x) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/computedPropertyNamesDeclarationEmit2_ES6.js b/tests/baselines/reference/computedPropertyNamesDeclarationEmit2_ES6.js index b5e70193b0..d8934f6c80 100644 --- a/tests/baselines/reference/computedPropertyNamesDeclarationEmit2_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesDeclarationEmit2_ES6.js @@ -7,13 +7,9 @@ class C { //// [computedPropertyNamesDeclarationEmit2_ES6.js] class C { - static ["" + ""]() { - } - static get ["" + ""]() { - return 0; - } - static set ["" + ""](x) { - } + static ["" + ""]() { } + static get ["" + ""]() { return 0; } + static set ["" + ""](x) { } } diff --git a/tests/baselines/reference/computedPropertyNamesDeclarationEmit5_ES5.js b/tests/baselines/reference/computedPropertyNamesDeclarationEmit5_ES5.js index 047a8cdb33..58c3133e6e 100644 --- a/tests/baselines/reference/computedPropertyNamesDeclarationEmit5_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesDeclarationEmit5_ES5.js @@ -9,21 +9,9 @@ var v = { //// [computedPropertyNamesDeclarationEmit5_ES5.js] var v = (_a = {}, _a["" + ""] = 0, - _a["" + ""] = function () { - }, - _a["" + ""] = Object.defineProperty({ - get: function () { - return 0; - }, - enumerable: true, - configurable: true - }), - _a["" + ""] = Object.defineProperty({ - set: function (x) { - }, - enumerable: true, - configurable: true - }), + _a["" + ""] = function () { }, + _a["" + ""] = Object.defineProperty({ get: function () { return 0; }, enumerable: true, configurable: true }), + _a["" + ""] = Object.defineProperty({ set: function (x) { }, enumerable: true, configurable: true }), _a); var _a; diff --git a/tests/baselines/reference/computedPropertyNamesDeclarationEmit5_ES6.js b/tests/baselines/reference/computedPropertyNamesDeclarationEmit5_ES6.js index 0ae3eaf62b..e19ac43656 100644 --- a/tests/baselines/reference/computedPropertyNamesDeclarationEmit5_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesDeclarationEmit5_ES6.js @@ -9,13 +9,9 @@ var v = { //// [computedPropertyNamesDeclarationEmit5_ES6.js] var v = { ["" + ""]: 0, - ["" + ""]() { - }, - get ["" + ""]() { - return 0; - }, - set ["" + ""](x) { - } + ["" + ""]() { }, + get ["" + ""]() { return 0; }, + set ["" + ""](x) { } }; diff --git a/tests/baselines/reference/computedPropertyNamesOnOverloads_ES5.js b/tests/baselines/reference/computedPropertyNamesOnOverloads_ES5.js index c922b87f47..1470605413 100644 --- a/tests/baselines/reference/computedPropertyNamesOnOverloads_ES5.js +++ b/tests/baselines/reference/computedPropertyNamesOnOverloads_ES5.js @@ -13,7 +13,6 @@ var accessorName = "accessor"; var C = (function () { function C() { } - C.prototype[methodName] = function (v) { - }; + C.prototype[methodName] = function (v) { }; return C; })(); diff --git a/tests/baselines/reference/computedPropertyNamesOnOverloads_ES6.js b/tests/baselines/reference/computedPropertyNamesOnOverloads_ES6.js index ced0a8d449..5f09cb5f31 100644 --- a/tests/baselines/reference/computedPropertyNamesOnOverloads_ES6.js +++ b/tests/baselines/reference/computedPropertyNamesOnOverloads_ES6.js @@ -11,6 +11,5 @@ class C { var methodName = "method"; var accessorName = "accessor"; class C { - [methodName](v) { - } + [methodName](v) { } } diff --git a/tests/baselines/reference/computedPropertyNamesWithStaticProperty.js b/tests/baselines/reference/computedPropertyNamesWithStaticProperty.js index e6b7bd5aae..9f0407588a 100644 --- a/tests/baselines/reference/computedPropertyNamesWithStaticProperty.js +++ b/tests/baselines/reference/computedPropertyNamesWithStaticProperty.js @@ -18,7 +18,6 @@ class C { set [C.staticProp](x) { var y = x; } - [C.staticProp]() { - } + [C.staticProp]() { } } C.staticProp = 10; diff --git a/tests/baselines/reference/concatError.js b/tests/baselines/reference/concatError.js index 1b7ff27be6..dee3d8a30e 100644 --- a/tests/baselines/reference/concatError.js +++ b/tests/baselines/reference/concatError.js @@ -41,9 +41,7 @@ interface Array { } */ var fa; -fa = fa.concat([ - 0 -]); +fa = fa.concat([0]); fa = fa.concat(0); /* diff --git a/tests/baselines/reference/conditionalExpressions2.js b/tests/baselines/reference/conditionalExpressions2.js index 5510a78ad6..6749a2c0ac 100644 --- a/tests/baselines/reference/conditionalExpressions2.js +++ b/tests/baselines/reference/conditionalExpressions2.js @@ -16,22 +16,11 @@ var c = false ? 1 : 0; var d = false ? false : true; var e = false ? "foo" : "bar"; var f = false ? null : undefined; -var g = true ? { - g: 5 -} : null; -var h = [ - { - h: 5 - }, - null -]; -function i() { - if (true) { - return { - x: 5 - }; - } - else { - return null; - } +var g = true ? { g: 5 } : null; +var h = [{ h: 5 }, null]; +function i() { if (true) { + return { x: 5 }; } +else { + return null; +} } diff --git a/tests/baselines/reference/conditionalOperatorConditionIsNumberType.js b/tests/baselines/reference/conditionalOperatorConditionIsNumberType.js index 1cd71e6887..f8fbe708e1 100644 --- a/tests/baselines/reference/conditionalOperatorConditionIsNumberType.js +++ b/tests/baselines/reference/conditionalOperatorConditionIsNumberType.js @@ -91,15 +91,9 @@ condNumber ? exprString1 : exprBoolean1; // Union 1000000000000 ? exprIsObject1 : exprIsObject2; 10000 ? exprString1 : exprBoolean1; // Union //Cond is a number type expression -function foo() { - return 1; -} +function foo() { return 1; } ; -var array = [ - 1, - 2, - 3 -]; +var array = [1, 2, 3]; 1 * 0 ? exprAny1 : exprAny2; 1 + 1 ? exprBoolean1 : exprBoolean2; "string".length ? exprNumber1 : exprNumber2; diff --git a/tests/baselines/reference/conditionalOperatorConditionIsObjectType.js b/tests/baselines/reference/conditionalOperatorConditionIsObjectType.js index 17f64c7142..b2830e4d1d 100644 --- a/tests/baselines/reference/conditionalOperatorConditionIsObjectType.js +++ b/tests/baselines/reference/conditionalOperatorConditionIsObjectType.js @@ -77,8 +77,7 @@ var exprBoolean2; var exprNumber2; var exprString2; var exprIsObject2; -function foo() { -} +function foo() { } ; var C = (function () { function C() { @@ -94,25 +93,12 @@ condObject ? exprString1 : exprString2; condObject ? exprIsObject1 : exprIsObject2; condObject ? exprString1 : exprBoolean1; // union //Cond is an object type literal -(function (a) { - return a.length; -}) ? exprAny1 : exprAny2; -(function (a) { - return a.length; -}) ? exprBoolean1 : exprBoolean2; +(function (a) { return a.length; }) ? exprAny1 : exprAny2; +(function (a) { return a.length; }) ? exprBoolean1 : exprBoolean2; ({}) ? exprNumber1 : exprNumber2; -({ - a: 1, - b: "s" -}) ? exprString1 : exprString2; -({ - a: 1, - b: "s" -}) ? exprIsObject1 : exprIsObject2; -({ - a: 1, - b: "s" -}) ? exprString1 : exprBoolean1; // union +({ a: 1, b: "s" }) ? exprString1 : exprString2; +({ a: 1, b: "s" }) ? exprIsObject1 : exprIsObject2; +({ a: 1, b: "s" }) ? exprString1 : exprBoolean1; // union //Cond is an object type expression foo() ? exprAny1 : exprAny2; new Date() ? exprBoolean1 : exprBoolean2; @@ -127,25 +113,12 @@ var resultIsNumber1 = condObject ? exprNumber1 : exprNumber2; var resultIsString1 = condObject ? exprString1 : exprString2; var resultIsObject1 = condObject ? exprIsObject1 : exprIsObject2; var resultIsStringOrBoolean1 = condObject ? exprString1 : exprBoolean1; // union -var resultIsAny2 = (function (a) { - return a.length; -}) ? exprAny1 : exprAny2; -var resultIsBoolean2 = (function (a) { - return a.length; -}) ? exprBoolean1 : exprBoolean2; +var resultIsAny2 = (function (a) { return a.length; }) ? exprAny1 : exprAny2; +var resultIsBoolean2 = (function (a) { return a.length; }) ? exprBoolean1 : exprBoolean2; var resultIsNumber2 = ({}) ? exprNumber1 : exprNumber2; -var resultIsString2 = ({ - a: 1, - b: "s" -}) ? exprString1 : exprString2; -var resultIsObject2 = ({ - a: 1, - b: "s" -}) ? exprIsObject1 : exprIsObject2; -var resultIsStringOrBoolean2 = ({ - a: 1, - b: "s" -}) ? exprString1 : exprBoolean1; // union +var resultIsString2 = ({ a: 1, b: "s" }) ? exprString1 : exprString2; +var resultIsObject2 = ({ a: 1, b: "s" }) ? exprIsObject1 : exprIsObject2; +var resultIsStringOrBoolean2 = ({ a: 1, b: "s" }) ? exprString1 : exprBoolean1; // union var resultIsAny3 = foo() ? exprAny1 : exprAny2; var resultIsBoolean3 = new Date() ? exprBoolean1 : exprBoolean2; var resultIsNumber3 = new C() ? exprNumber1 : exprNumber2; diff --git a/tests/baselines/reference/conditionalOperatorConditoinIsAnyType.js b/tests/baselines/reference/conditionalOperatorConditoinIsAnyType.js index 30d90a8b27..80cfaf97f2 100644 --- a/tests/baselines/reference/conditionalOperatorConditoinIsAnyType.js +++ b/tests/baselines/reference/conditionalOperatorConditoinIsAnyType.js @@ -88,14 +88,8 @@ condAny ? exprString1 : exprBoolean1; // union null ? exprAny1 : exprAny2; null ? exprBoolean1 : exprBoolean2; undefined ? exprNumber1 : exprNumber2; -[ - null, - undefined -] ? exprString1 : exprString2; -[ - null, - undefined -] ? exprIsObject1 : exprIsObject2; +[null, undefined] ? exprString1 : exprString2; +[null, undefined] ? exprIsObject1 : exprIsObject2; undefined ? exprString1 : exprBoolean1; // union //Cond is an any type expression x.doSomeThing() ? exprAny1 : exprAny2; @@ -114,20 +108,11 @@ var resultIsStringOrBoolean1 = condAny ? exprString1 : exprBoolean1; // union var resultIsAny2 = null ? exprAny1 : exprAny2; var resultIsBoolean2 = null ? exprBoolean1 : exprBoolean2; var resultIsNumber2 = undefined ? exprNumber1 : exprNumber2; -var resultIsString2 = [ - null, - undefined -] ? exprString1 : exprString2; -var resultIsObject2 = [ - null, - undefined -] ? exprIsObject1 : exprIsObject2; +var resultIsString2 = [null, undefined] ? exprString1 : exprString2; +var resultIsObject2 = [null, undefined] ? exprIsObject1 : exprIsObject2; var resultIsStringOrBoolean2 = null ? exprString1 : exprBoolean1; // union var resultIsStringOrBoolean3 = undefined ? exprString1 : exprBoolean1; // union -var resultIsStringOrBoolean4 = [ - null, - undefined -] ? exprString1 : exprBoolean1; // union +var resultIsStringOrBoolean4 = [null, undefined] ? exprString1 : exprBoolean1; // union var resultIsAny3 = x.doSomeThing() ? exprAny1 : exprAny2; var resultIsBoolean3 = x("x") ? exprBoolean1 : exprBoolean2; var resultIsNumber3 = x(x) ? exprNumber1 : exprNumber2; diff --git a/tests/baselines/reference/conditionalOperatorConditoinIsStringType.js b/tests/baselines/reference/conditionalOperatorConditoinIsStringType.js index ce4fd98523..dbd68d9f00 100644 --- a/tests/baselines/reference/conditionalOperatorConditoinIsStringType.js +++ b/tests/baselines/reference/conditionalOperatorConditoinIsStringType.js @@ -92,15 +92,9 @@ condString ? exprString1 : exprBoolean1; // union " " ? exprIsObject1 : exprIsObject2; "hello " ? exprString1 : exprBoolean1; // union //Cond is a string type expression -function foo() { - return "string"; -} +function foo() { return "string"; } ; -var array = [ - "1", - "2", - "3" -]; +var array = ["1", "2", "3"]; typeof condString ? exprAny1 : exprAny2; condString.toUpperCase ? exprBoolean1 : exprBoolean2; condString + "string" ? exprNumber1 : exprNumber2; diff --git a/tests/baselines/reference/conditionalOperatorWithIdenticalBCT.js b/tests/baselines/reference/conditionalOperatorWithIdenticalBCT.js index 592c5a6ca1..722310815a 100644 --- a/tests/baselines/reference/conditionalOperatorWithIdenticalBCT.js +++ b/tests/baselines/reference/conditionalOperatorWithIdenticalBCT.js @@ -86,59 +86,27 @@ true ? x : a; var result1 = true ? x : a; //Expr1 and Expr2 are literals true ? {} : 1; -true ? { - a: 1 -} : { - a: 2, - b: 'string' -}; +true ? { a: 1 } : { a: 2, b: 'string' }; var result2 = true ? {} : 1; -var result3 = true ? { - a: 1 -} : { - a: 2, - b: 'string' -}; +var result3 = true ? { a: 1 } : { a: 2, b: 'string' }; //Contextually typed var resultIsX1 = true ? x : a; -var result4 = true ? function (m) { - return m.propertyX; -} : function (n) { - return n.propertyA; -}; +var result4 = true ? function (m) { return m.propertyX; } : function (n) { return n.propertyA; }; //Cond ? Expr1 : Expr2, Expr2 is supertype //Be Not contextually typed true ? a : x; var result5 = true ? a : x; //Expr1 and Expr2 are literals true ? 1 : {}; -true ? { - a: 2, - b: 'string' -} : { - a: 1 -}; +true ? { a: 2, b: 'string' } : { a: 1 }; var result6 = true ? 1 : {}; -var result7 = true ? { - a: 2, - b: 'string' -} : { - a: 1 -}; +var result7 = true ? { a: 2, b: 'string' } : { a: 1 }; //Contextually typed var resultIsX2 = true ? x : a; -var result8 = true ? function (m) { - return m.propertyA; -} : function (n) { - return n.propertyX; -}; +var result8 = true ? function (m) { return m.propertyA; } : function (n) { return n.propertyX; }; //Result = Cond ? Expr1 : Expr2, Result is supertype //Contextually typed var resultIsX3 = true ? a : b; -var result10 = true ? function (m) { - return m.propertyX1; -} : function (n) { - return n.propertyX2; -}; +var result10 = true ? function (m) { return m.propertyX1; } : function (n) { return n.propertyX2; }; //Expr1 and Expr2 are literals var result11 = true ? 1 : 'string'; diff --git a/tests/baselines/reference/conditionalOperatorWithoutIdenticalBCT.js b/tests/baselines/reference/conditionalOperatorWithoutIdenticalBCT.js index 78c7569c0f..83262ed130 100644 --- a/tests/baselines/reference/conditionalOperatorWithoutIdenticalBCT.js +++ b/tests/baselines/reference/conditionalOperatorWithoutIdenticalBCT.js @@ -63,23 +63,7 @@ var result1 = true ? a : b; var result2 = true ? a : b; var result3 = true ? a : b; var result31 = true ? a : b; -var result4 = true ? function (m) { - return m.propertyX1; -} : function (n) { - return n.propertyX2; -}; -var result5 = true ? function (m) { - return m.propertyX1; -} : function (n) { - return n.propertyX2; -}; -var result6 = true ? function (m) { - return m.propertyX1; -} : function (n) { - return n.propertyX2; -}; -var result61 = true ? function (m) { - return m.propertyX1; -} : function (n) { - return n.propertyX2; -}; +var result4 = true ? function (m) { return m.propertyX1; } : function (n) { return n.propertyX2; }; +var result5 = true ? function (m) { return m.propertyX1; } : function (n) { return n.propertyX2; }; +var result6 = true ? function (m) { return m.propertyX1; } : function (n) { return n.propertyX2; }; +var result61 = true ? function (m) { return m.propertyX1; } : function (n) { return n.propertyX2; }; diff --git a/tests/baselines/reference/conditionallyDuplicateOverloadsCausedByOverloadResolution.js b/tests/baselines/reference/conditionallyDuplicateOverloadsCausedByOverloadResolution.js index e2029d1bf3..d8a36f9e09 100644 --- a/tests/baselines/reference/conditionallyDuplicateOverloadsCausedByOverloadResolution.js +++ b/tests/baselines/reference/conditionallyDuplicateOverloadsCausedByOverloadResolution.js @@ -22,8 +22,7 @@ var out2 = foo2((x, y) => { //// [conditionallyDuplicateOverloadsCausedByOverloadResolution.js] var out = foo(function (x, y) { - function bar() { - } + function bar() { } return bar; }); var out2 = foo2(function (x, y) { diff --git a/tests/baselines/reference/conflictMarkerTrivia2.js b/tests/baselines/reference/conflictMarkerTrivia2.js index bbb631de38..bbf6726b99 100644 --- a/tests/baselines/reference/conflictMarkerTrivia2.js +++ b/tests/baselines/reference/conflictMarkerTrivia2.js @@ -20,7 +20,6 @@ var C = (function () { C.prototype.foo = function () { a(); }; - C.prototype.bar = function () { - }; + C.prototype.bar = function () { }; return C; })(); diff --git a/tests/baselines/reference/conflictingTypeAnnotatedVar.js b/tests/baselines/reference/conflictingTypeAnnotatedVar.js index b44dc6f1e3..283912c487 100644 --- a/tests/baselines/reference/conflictingTypeAnnotatedVar.js +++ b/tests/baselines/reference/conflictingTypeAnnotatedVar.js @@ -5,7 +5,5 @@ function foo(): number { } //// [conflictingTypeAnnotatedVar.js] var foo; -function foo() { -} -function foo() { -} +function foo() { } +function foo() { } diff --git a/tests/baselines/reference/constDeclarations-access2.js b/tests/baselines/reference/constDeclarations-access2.js index fd51c93263..ae8dae7064 100644 --- a/tests/baselines/reference/constDeclarations-access2.js +++ b/tests/baselines/reference/constDeclarations-access2.js @@ -62,11 +62,9 @@ x--; ++((x)); // OK var a = x + 1; -function f(v) { -} +function f(v) { } f(x); -if (x) { -} +if (x) { } x; (x); -x; diff --git a/tests/baselines/reference/constDeclarations-access3.js b/tests/baselines/reference/constDeclarations-access3.js index 9ac4880bdd..9140da965c 100644 --- a/tests/baselines/reference/constDeclarations-access3.js +++ b/tests/baselines/reference/constDeclarations-access3.js @@ -71,11 +71,9 @@ M.x--; M["x"] = 0; // OK var a = M.x + 1; -function f(v) { -} +function f(v) { } f(M.x); -if (M.x) { -} +if (M.x) { } M.x; (M.x); -M.x; diff --git a/tests/baselines/reference/constDeclarations-access4.js b/tests/baselines/reference/constDeclarations-access4.js index b226e746bb..608d950526 100644 --- a/tests/baselines/reference/constDeclarations-access4.js +++ b/tests/baselines/reference/constDeclarations-access4.js @@ -67,11 +67,9 @@ M.x--; M["x"] = 0; // OK var a = M.x + 1; -function f(v) { -} +function f(v) { } f(M.x); -if (M.x) { -} +if (M.x) { } M.x; (M.x); -M.x; diff --git a/tests/baselines/reference/constDeclarations-access5.js b/tests/baselines/reference/constDeclarations-access5.js index 313ce3db21..7735e37d2b 100644 --- a/tests/baselines/reference/constDeclarations-access5.js +++ b/tests/baselines/reference/constDeclarations-access5.js @@ -73,11 +73,9 @@ m.x--; m["x"] = 0; // OK var a = m.x + 1; -function f(v) { -} +function f(v) { } f(m.x); -if (m.x) { -} +if (m.x) { } m.x; (m.x); -m.x; diff --git a/tests/baselines/reference/constDeclarations-errors.js b/tests/baselines/reference/constDeclarations-errors.js index e1e68032f8..e7143f2564 100644 --- a/tests/baselines/reference/constDeclarations-errors.js +++ b/tests/baselines/reference/constDeclarations-errors.js @@ -21,14 +21,10 @@ for(const c10 = 0, c11; c10 < 1;) { } const c1; const c2; const c3, c4, c5, c6; // error, missing initialicer -for (const c in {}) { -} +for (const c in {}) { } // error, assigning to a const -for (const c8 = 0; c8 < 1; c8++) { -} +for (const c8 = 0; c8 < 1; c8++) { } // error, can not be unintalized -for (const c9; c9 < 1;) { -} +for (const c9; c9 < 1;) { } // error, can not be unintalized -for (const c10 = 0, c11; c10 < 1;) { -} +for (const c10 = 0, c11; c10 < 1;) { } diff --git a/tests/baselines/reference/constEnumErrors.js b/tests/baselines/reference/constEnumErrors.js index ca5e3f87e6..4afd98982f 100644 --- a/tests/baselines/reference/constEnumErrors.js +++ b/tests/baselines/reference/constEnumErrors.js @@ -52,9 +52,7 @@ var y0 = E2[1]; var name = "A"; var y1 = E2[name]; var x = E2; -var y = [ - E2 -]; +var y = [E2]; function foo(t) { } foo(E2); diff --git a/tests/baselines/reference/constEnums.js b/tests/baselines/reference/constEnums.js index b7077c74df..4f85cc59d0 100644 --- a/tests/baselines/reference/constEnums.js +++ b/tests/baselines/reference/constEnums.js @@ -216,11 +216,8 @@ function foo(x) { } function bar(e) { switch (e) { - case 1 /* V1 */: - return 1; - case 101 /* V2 */: - return 1; - case 64 /* V3 */: - return 1; + case 1 /* V1 */: return 1; + case 101 /* V2 */: return 1; + case 64 /* V3 */: return 1; } } diff --git a/tests/baselines/reference/constantOverloadFunction.js b/tests/baselines/reference/constantOverloadFunction.js index 12e84e2077..408b56805f 100644 --- a/tests/baselines/reference/constantOverloadFunction.js +++ b/tests/baselines/reference/constantOverloadFunction.js @@ -23,8 +23,7 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base() { } - Base.prototype.foo = function () { - }; + Base.prototype.foo = function () { }; return Base; })(); var Derived1 = (function (_super) { @@ -32,8 +31,7 @@ var Derived1 = (function (_super) { function Derived1() { _super.apply(this, arguments); } - Derived1.prototype.bar = function () { - }; + Derived1.prototype.bar = function () { }; return Derived1; })(Base); var Derived2 = (function (_super) { @@ -41,8 +39,7 @@ var Derived2 = (function (_super) { function Derived2() { _super.apply(this, arguments); } - Derived2.prototype.baz = function () { - }; + Derived2.prototype.baz = function () { }; return Derived2; })(Base); var Derived3 = (function (_super) { @@ -50,8 +47,7 @@ var Derived3 = (function (_super) { function Derived3() { _super.apply(this, arguments); } - Derived3.prototype.biz = function () { - }; + Derived3.prototype.biz = function () { }; return Derived3; })(Base); function foo(tagName) { diff --git a/tests/baselines/reference/constantOverloadFunctionNoSubtypeError.js b/tests/baselines/reference/constantOverloadFunctionNoSubtypeError.js index 563b73d7e5..591d6171db 100644 --- a/tests/baselines/reference/constantOverloadFunctionNoSubtypeError.js +++ b/tests/baselines/reference/constantOverloadFunctionNoSubtypeError.js @@ -24,8 +24,7 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base() { } - Base.prototype.foo = function () { - }; + Base.prototype.foo = function () { }; return Base; })(); var Derived1 = (function (_super) { @@ -33,8 +32,7 @@ var Derived1 = (function (_super) { function Derived1() { _super.apply(this, arguments); } - Derived1.prototype.bar = function () { - }; + Derived1.prototype.bar = function () { }; return Derived1; })(Base); var Derived2 = (function (_super) { @@ -42,8 +40,7 @@ var Derived2 = (function (_super) { function Derived2() { _super.apply(this, arguments); } - Derived2.prototype.baz = function () { - }; + Derived2.prototype.baz = function () { }; return Derived2; })(Base); var Derived3 = (function (_super) { @@ -51,8 +48,7 @@ var Derived3 = (function (_super) { function Derived3() { _super.apply(this, arguments); } - Derived3.prototype.biz = function () { - }; + Derived3.prototype.biz = function () { }; return Derived3; })(Base); function foo(tagName) { diff --git a/tests/baselines/reference/constraintCheckInGenericBaseTypeReference.js b/tests/baselines/reference/constraintCheckInGenericBaseTypeReference.js index 3d99e07bb5..caeb2d32ee 100644 --- a/tests/baselines/reference/constraintCheckInGenericBaseTypeReference.js +++ b/tests/baselines/reference/constraintCheckInGenericBaseTypeReference.js @@ -30,8 +30,7 @@ var __extends = this.__extends || function (d, b) { var Constraint = (function () { function Constraint() { } - Constraint.prototype.method = function () { - }; + Constraint.prototype.method = function () { }; return Constraint; })(); var GenericBase = (function () { diff --git a/tests/baselines/reference/constraintErrors1.js b/tests/baselines/reference/constraintErrors1.js index c8da89d574..71723130b5 100644 --- a/tests/baselines/reference/constraintErrors1.js +++ b/tests/baselines/reference/constraintErrors1.js @@ -2,5 +2,4 @@ function foo5(test: T) { } //// [constraintErrors1.js] -function foo5(test) { -} +function foo5(test) { } diff --git a/tests/baselines/reference/constraintSatisfactionWithAny.js b/tests/baselines/reference/constraintSatisfactionWithAny.js index 924c2ab170..06d8b17690 100644 --- a/tests/baselines/reference/constraintSatisfactionWithAny.js +++ b/tests/baselines/reference/constraintSatisfactionWithAny.js @@ -54,16 +54,10 @@ var c8 = new C4(b); //// [constraintSatisfactionWithAny.js] // any is not a valid type argument unless there is no constraint, or the constraint is any -function foo(x) { - return null; -} -function foo2(x) { - return null; -} +function foo(x) { return null; } +function foo2(x) { return null; } //function foo3(x: T): T { return null; } -function foo4(x) { - return null; -} +function foo4(x) { return null; } var a; foo(a); foo2(a); diff --git a/tests/baselines/reference/constraintSatisfactionWithEmptyObject.js b/tests/baselines/reference/constraintSatisfactionWithEmptyObject.js index 5f9e902141..7850b0ebd0 100644 --- a/tests/baselines/reference/constraintSatisfactionWithEmptyObject.js +++ b/tests/baselines/reference/constraintSatisfactionWithEmptyObject.js @@ -40,8 +40,7 @@ var i2: I2<{}>; //// [constraintSatisfactionWithEmptyObject.js] // valid uses of a basic object constraint, no errors expected // Object constraint -function foo(x) { -} +function foo(x) { } var r = foo({}); var a = {}; var r = foo({}); @@ -54,8 +53,7 @@ var C = (function () { var r2 = new C({}); var i; // {} constraint -function foo2(x) { -} +function foo2(x) { } var r = foo2({}); var a = {}; var r = foo2({}); diff --git a/tests/baselines/reference/constructorArgWithGenericCallSignature.js b/tests/baselines/reference/constructorArgWithGenericCallSignature.js index 5fa7c46124..ca85986985 100644 --- a/tests/baselines/reference/constructorArgWithGenericCallSignature.js +++ b/tests/baselines/reference/constructorArgWithGenericCallSignature.js @@ -23,8 +23,7 @@ var Test; return MyClass; })(); Test.MyClass = MyClass; - function F(func) { - } + function F(func) { } Test.F = F; })(Test || (Test = {})); var func; diff --git a/tests/baselines/reference/constructorAsType.js b/tests/baselines/reference/constructorAsType.js index d2029e5899..9f8c14ce74 100644 --- a/tests/baselines/reference/constructorAsType.js +++ b/tests/baselines/reference/constructorAsType.js @@ -6,10 +6,6 @@ var Person2:{new() : {name:string;};}; Person = Person2; //// [constructorAsType.js] -var Person = function () { - return { - name: "joe" - }; -}; +var Person = function () { return { name: "joe" }; }; var Person2; Person = Person2; diff --git a/tests/baselines/reference/constructorOverloads1.js b/tests/baselines/reference/constructorOverloads1.js index 6f834d0bf6..97f33dca86 100644 --- a/tests/baselines/reference/constructorOverloads1.js +++ b/tests/baselines/reference/constructorOverloads1.js @@ -25,19 +25,13 @@ f1.bar2(); var Foo = (function () { function Foo(x) { } - Foo.prototype.bar1 = function () { - }; - Foo.prototype.bar2 = function () { - }; + Foo.prototype.bar1 = function () { }; + Foo.prototype.bar2 = function () { }; return Foo; })(); var f1 = new Foo("hey"); var f2 = new Foo(0); var f3 = new Foo(f1); -var f4 = new Foo([ - f1, - f2, - f3 -]); +var f4 = new Foo([f1, f2, f3]); f1.bar1(); f1.bar2(); diff --git a/tests/baselines/reference/constructorOverloads2.js b/tests/baselines/reference/constructorOverloads2.js index 753eca4a1f..e3eae0ed5a 100644 --- a/tests/baselines/reference/constructorOverloads2.js +++ b/tests/baselines/reference/constructorOverloads2.js @@ -35,8 +35,7 @@ var __extends = this.__extends || function (d, b) { var FooBase = (function () { function FooBase(x) { } - FooBase.prototype.bar1 = function () { - }; + FooBase.prototype.bar1 = function () { }; return FooBase; })(); var Foo = (function (_super) { @@ -44,16 +43,11 @@ var Foo = (function (_super) { function Foo(x, y) { _super.call(this, x); } - Foo.prototype.bar1 = function () { - }; + Foo.prototype.bar1 = function () { }; return Foo; })(FooBase); var f1 = new Foo("hey"); var f2 = new Foo(0); var f3 = new Foo(f1); -var f4 = new Foo([ - f1, - f2, - f3 -]); +var f4 = new Foo([f1, f2, f3]); f1.bar1(); diff --git a/tests/baselines/reference/constructorOverloads3.js b/tests/baselines/reference/constructorOverloads3.js index 382a7cd891..c54226745c 100644 --- a/tests/baselines/reference/constructorOverloads3.js +++ b/tests/baselines/reference/constructorOverloads3.js @@ -33,16 +33,11 @@ var Foo = (function (_super) { __extends(Foo, _super); function Foo(x, y) { } - Foo.prototype.bar1 = function () { - }; + Foo.prototype.bar1 = function () { }; return Foo; })(FooBase); var f1 = new Foo("hey"); var f2 = new Foo(0); var f3 = new Foo(f1); -var f4 = new Foo([ - f1, - f2, - f3 -]); +var f4 = new Foo([f1, f2, f3]); f1.bar1(); diff --git a/tests/baselines/reference/constructorOverloads6.js b/tests/baselines/reference/constructorOverloads6.js index aef68fcd86..1996449165 100644 --- a/tests/baselines/reference/constructorOverloads6.js +++ b/tests/baselines/reference/constructorOverloads6.js @@ -28,9 +28,5 @@ f1.bar1(); var f1 = new Foo("hey"); var f2 = new Foo(0); var f3 = new Foo(f1); -var f4 = new Foo([ - f1, - f2, - f3 -]); +var f4 = new Foo([f1, f2, f3]); f1.bar1(); diff --git a/tests/baselines/reference/constructorOverloads7.js b/tests/baselines/reference/constructorOverloads7.js index b7e152c66e..5b7e407e80 100644 --- a/tests/baselines/reference/constructorOverloads7.js +++ b/tests/baselines/reference/constructorOverloads7.js @@ -34,6 +34,4 @@ function Point(x, y) { this.y = y; return this; } -function EF1(a, b) { - return a + b; -} +function EF1(a, b) { return a + b; } diff --git a/tests/baselines/reference/constructorParametersInVariableDeclarations.js b/tests/baselines/reference/constructorParametersInVariableDeclarations.js index 3528a9574a..984c8c392b 100644 --- a/tests/baselines/reference/constructorParametersInVariableDeclarations.js +++ b/tests/baselines/reference/constructorParametersInVariableDeclarations.js @@ -20,24 +20,16 @@ class B { var A = (function () { function A(x) { this.a = x; - this.b = { - p: x - }; - this.c = function () { - return x; - }; + this.b = { p: x }; + this.c = function () { return x; }; } return A; })(); var B = (function () { function B() { this.a = x; - this.b = { - p: x - }; - this.c = function () { - return x; - }; + this.b = { p: x }; + this.c = function () { return x; }; var x = 1; } return B; diff --git a/tests/baselines/reference/constructorReturnsInvalidType.js b/tests/baselines/reference/constructorReturnsInvalidType.js index 92afb41a3f..7f6119cc8b 100644 --- a/tests/baselines/reference/constructorReturnsInvalidType.js +++ b/tests/baselines/reference/constructorReturnsInvalidType.js @@ -14,8 +14,7 @@ var X = (function () { function X() { return 1; } - X.prototype.foo = function () { - }; + X.prototype.foo = function () { }; return X; })(); var x = new X(); diff --git a/tests/baselines/reference/constructorWithAssignableReturnExpression.js b/tests/baselines/reference/constructorWithAssignableReturnExpression.js index b56e63e8e4..238f2e18ae 100644 --- a/tests/baselines/reference/constructorWithAssignableReturnExpression.js +++ b/tests/baselines/reference/constructorWithAssignableReturnExpression.js @@ -51,25 +51,19 @@ var D = (function () { })(); var E = (function () { function E() { - return { - x: 1 - }; + return { x: 1 }; } return E; })(); var F = (function () { function F() { - return { - x: 1 - }; // error + return { x: 1 }; // error } return F; })(); var G = (function () { function G() { - return { - x: null - }; + return { x: null }; } return G; })(); diff --git a/tests/baselines/reference/constructorWithIncompleteTypeAnnotation.js b/tests/baselines/reference/constructorWithIncompleteTypeAnnotation.js index 0bc51e90c5..64c7027387 100644 --- a/tests/baselines/reference/constructorWithIncompleteTypeAnnotation.js +++ b/tests/baselines/reference/constructorWithIncompleteTypeAnnotation.js @@ -314,10 +314,12 @@ var TypeScriptAllInOne; Program.prototype.if = function (retValue) { if (retValue === void 0) { retValue = != 0; } return 1; - ^ retValue; + ^ + retValue; bfs.TYPES(); if (retValue != 0) { - return 1 && ; + return 1 && + ; } retValue = bfs.OPERATOR; ' );; @@ -348,7 +350,8 @@ var BasicFeatures = (function () { BasicFeatures.prototype.VARIABLES = function () { var local = Number.MAX_VALUE; var min = Number.MIN_VALUE; - var inf = Number.NEGATIVE_INFINITY - ; + var inf = Number.NEGATIVE_INFINITY - + ; var nan = Number.NaN; var undef = undefined; var _\uD4A5\u7204\uC316, uE59F = local; @@ -357,22 +360,16 @@ var BasicFeatures = (function () { var local6 = local5 instanceof fs.File; var hex = 0xBADC0DE, Hex = 0XDEADBEEF; var float = 6.02e23, float2 = 6.02E-23; - var char = 'c', \u0066 = '\u0066', hexchar = '\x42' != ; + var char = 'c', \u0066 = '\u0066', hexchar = '\x42' != + ; var quoted = '"', quoted2 = "'"; var reg = /\w*/; - var objLit = { - "var": number = 42, - equals: function (x) { - return x["var"] === 42; - }, - instanceof: function () { - return 'objLit{42}'; - } - }; + var objLit = { "var": number = 42, equals: function (x) { return x["var"] === 42; }, instanceof: function () { return 'objLit{42}'; } }; var weekday = Weekdays.Monday; var con = char + f + hexchar + float.toString() + float2.toString() + reg.toString() + objLit + weekday; // - var any = 0 ^= ; + var any = 0 ^= + ; var bool = 0; var declare = 0; var constructor = 0; @@ -388,7 +385,8 @@ var BasicFeatures = (function () { var public = 0; var set = 0; var static = 0; - var string = 0 / > ; + var string = 0 / > + ; var yield = 0; var sum3 = any + bool + declare + constructor + get + implements + interface + let + module + number + package + private + protected + public + set + static + string + yield; return 0; @@ -414,24 +412,18 @@ var BasicFeatures = (function () { default: break; } - for (var x in { - x: 0, - y: 1 - }) { + for (var x in { x: 0, y: 1 }) { !; try { throw null; } - catch (Exception) { - } + catch (Exception) { } } try { } finally { - try { - } - catch (Exception) { - } + try { } + catch (Exception) { } } return retVal; }; @@ -444,17 +436,13 @@ var BasicFeatures = (function () { var c = new CLASS(); var xx = c; retVal += ; - try { - } - catch () { - } + try { } + catch () { } Property; retVal += c.Member(); retVal += xx.Foo() ? 0 : 1; //anonymous type - var anony = { - a: new CLASS() - }; + var anony = { a: new CLASS() }; retVal += anony.a.d(); return retVal; }; @@ -463,13 +451,7 @@ var BasicFeatures = (function () { ///// ///// BasicFeatures.prototype.OPERATOR = function () { - var a = [ - 1, - 2, - 3, - 4, - 5, - ]; /*[] bug*/ // YES [] + var a = [1, 2, 3, 4, 5,]; /*[] bug*/ // YES [] var i = a[1]; /*[]*/ i = i + i - i * i / i % i & i | i ^ i; /*+ - * / % & | ^*/ var b = true && false || true ^ false; /*& | ^*/ @@ -505,15 +487,10 @@ var BasicFeatures = (function () { })(); var CLASS = (function () { function CLASS() { - this.d = function () { - yield; - 0; - }; + this.d = function () { yield; 0; }; } Object.defineProperty(CLASS.prototype, "Property", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); @@ -521,11 +498,11 @@ var CLASS = (function () { return 0; }; CLASS.prototype.Foo = function () { - var myEvent = function () { - return 1; - }; + var myEvent = function () { return 1; }; if (myEvent() == 1) - return true ? : ; + return true ? + : + ; else return false; }; @@ -567,10 +544,10 @@ while () : string, ; rest: string[]; { - & public; + & + public; DefaultValue(value ? : string = "Hello"); - { - } + { } } var Weekdays; (function (Weekdays) { diff --git a/tests/baselines/reference/contextualSignatureInstantiation1.js b/tests/baselines/reference/contextualSignatureInstantiation1.js index a9abab149b..843ac5140f 100644 --- a/tests/baselines/reference/contextualSignatureInstantiation1.js +++ b/tests/baselines/reference/contextualSignatureInstantiation1.js @@ -8,11 +8,7 @@ var e2 = (x: string, y?: K) => x.length; var r100 = map2(e2); // type arg inference should fail for S since a generic lambda is not inferentially typed. Falls back to { length: number } //// [contextualSignatureInstantiation1.js] -var e = function (x, y) { - return x.length; -}; +var e = function (x, y) { return x.length; }; var r99 = map(e); // should be {}[] for S since a generic lambda is not inferentially typed -var e2 = function (x, y) { - return x.length; -}; +var e2 = function (x, y) { return x.length; }; var r100 = map2(e2); // type arg inference should fail for S since a generic lambda is not inferentially typed. Falls back to { length: number } diff --git a/tests/baselines/reference/contextualSignatureInstantiation2.js b/tests/baselines/reference/contextualSignatureInstantiation2.js index 8b29b432ce..78bc5a8885 100644 --- a/tests/baselines/reference/contextualSignatureInstantiation2.js +++ b/tests/baselines/reference/contextualSignatureInstantiation2.js @@ -8,12 +8,6 @@ var r23 = dot(id)(id); //// [contextualSignatureInstantiation2.js] // dot f g x = f(g(x)) var dot; -dot = function (f) { - return function (g) { - return function (x) { - return f(g(x)); - }; - }; -}; +dot = function (f) { return function (g) { return function (x) { return f(g(x)); }; }; }; var id; var r23 = dot(id)(id); diff --git a/tests/baselines/reference/contextualSignatureInstantiation3.js b/tests/baselines/reference/contextualSignatureInstantiation3.js index ccc5e58436..9198a02ccd 100644 --- a/tests/baselines/reference/contextualSignatureInstantiation3.js +++ b/tests/baselines/reference/contextualSignatureInstantiation3.js @@ -31,15 +31,9 @@ function identity(x) { return x; } function singleton(x) { - return [ - x - ]; + return [x]; } -var xs = [ - 1, - 2, - 3 -]; +var xs = [1, 2, 3]; // Have compiler check that we get the correct types var v1; var v1 = xs.map(identity); // Error if not number[] diff --git a/tests/baselines/reference/contextualSignatureInstantiationWithTypeParameterConstrainedToOuterTypeParameter.js b/tests/baselines/reference/contextualSignatureInstantiationWithTypeParameterConstrainedToOuterTypeParameter.js index bd76a746ac..726d45bffe 100644 --- a/tests/baselines/reference/contextualSignatureInstantiationWithTypeParameterConstrainedToOuterTypeParameter.js +++ b/tests/baselines/reference/contextualSignatureInstantiationWithTypeParameterConstrainedToOuterTypeParameter.js @@ -8,9 +8,7 @@ var x = h("", f()); // Call should succeed and x should be string. All t //// [contextualSignatureInstantiationWithTypeParameterConstrainedToOuterTypeParameter.js] function f() { - function g(u) { - return null; - } + function g(u) { return null; } return g; } var h; diff --git a/tests/baselines/reference/contextualTypeAny.js b/tests/baselines/reference/contextualTypeAny.js index 1a3918ba0d..a88b353a89 100644 --- a/tests/baselines/reference/contextualTypeAny.js +++ b/tests/baselines/reference/contextualTypeAny.js @@ -7,11 +7,5 @@ var arr: number[] = ["", x]; //// [contextualTypeAny.js] var x; -var obj = { - p: "", - q: x -}; -var arr = [ - "", - x -]; +var obj = { p: "", q: x }; +var arr = ["", x]; diff --git a/tests/baselines/reference/contextualTypeAppliedToVarArgs.js b/tests/baselines/reference/contextualTypeAppliedToVarArgs.js index c4e78318a9..77ce90ec73 100644 --- a/tests/baselines/reference/contextualTypeAppliedToVarArgs.js +++ b/tests/baselines/reference/contextualTypeAppliedToVarArgs.js @@ -18,8 +18,7 @@ class Foo{ //// [contextualTypeAppliedToVarArgs.js] function delegate(instance, method, data) { - return function () { - }; + return function () { }; } var Foo = (function () { function Foo() { diff --git a/tests/baselines/reference/contextualTypeArrayReturnType.js b/tests/baselines/reference/contextualTypeArrayReturnType.js index d84b93ec95..adc568d523 100644 --- a/tests/baselines/reference/contextualTypeArrayReturnType.js +++ b/tests/baselines/reference/contextualTypeArrayReturnType.js @@ -24,9 +24,7 @@ var style: IBookStyle = { var style = { initialLeftPageTransforms: function (width) { return [ - { - 'ry': null - } + { 'ry': null } ]; } }; diff --git a/tests/baselines/reference/contextualTypeWithTuple.js b/tests/baselines/reference/contextualTypeWithTuple.js index d5c8fa8387..cfcdd13f7d 100644 --- a/tests/baselines/reference/contextualTypeWithTuple.js +++ b/tests/baselines/reference/contextualTypeWithTuple.js @@ -27,36 +27,11 @@ numStrTuple = unionTuple3; //// [contextualTypeWithTuple.js] // no error -var numStrTuple = [ - 5, - "hello" -]; -var numStrTuple2 = [ - 5, - "foo", - true -]; -var numStrBoolTuple = [ - 5, - "foo", - true -]; -var objNumTuple = [ - { - a: "world" - }, - 5 -]; -var strTupleTuple = [ - "bar", - [ - 5, - { - x: 1, - y: 1 - } - ] -]; +var numStrTuple = [5, "hello"]; +var numStrTuple2 = [5, "foo", true]; +var numStrBoolTuple = [5, "foo", true]; +var objNumTuple = [{ a: "world" }, 5]; +var strTupleTuple = ["bar", [5, { x: 1, y: 1 }]]; var C = (function () { function C() { } @@ -67,36 +42,16 @@ var D = (function () { } return D; })(); -var unionTuple = [ - new C(), - "foo" -]; -var unionTuple1 = [ - new C(), - "foo" -]; -var unionTuple2 = [ - new C(), - "foo", - new D() -]; -var unionTuple3 = [ - 10, - "foo" -]; +var unionTuple = [new C(), "foo"]; +var unionTuple1 = [new C(), "foo"]; +var unionTuple2 = [new C(), "foo", new D()]; +var unionTuple3 = [10, "foo"]; numStrTuple = numStrTuple2; numStrTuple = numStrBoolTuple; // error -objNumTuple = [ - {}, - 5 -]; +objNumTuple = [{}, 5]; numStrBoolTuple = numStrTuple; -var strStrTuple = [ - "foo", - "bar", - 5 -]; +var strStrTuple = ["foo", "bar", 5]; unionTuple = unionTuple1; unionTuple = unionTuple2; unionTuple2 = unionTuple; diff --git a/tests/baselines/reference/contextualTypeWithUnionTypeCallSignatures.js b/tests/baselines/reference/contextualTypeWithUnionTypeCallSignatures.js index 9daf108f1c..e29d4720cb 100644 --- a/tests/baselines/reference/contextualTypeWithUnionTypeCallSignatures.js +++ b/tests/baselines/reference/contextualTypeWithUnionTypeCallSignatures.js @@ -40,21 +40,11 @@ var x4: IWithCallSignatures | IWithCallSignatures4 = a => /*here a should be any //When used as a contextual type, a union type U has those members that are present in any of // its constituent types, with types that are unions of the respective members in the constituent types. // With no call signature | callSignatures -var x = function (a) { - return a.toString(); -}; +var x = function (a) { return a.toString(); }; // With call signatures with different return type -var x2 = function (a) { - return a.toString(); -}; // Like iWithCallSignatures -var x2 = function (a) { - return a; -}; // Like iWithCallSignatures2 +var x2 = function (a) { return a.toString(); }; // Like iWithCallSignatures +var x2 = function (a) { return a; }; // Like iWithCallSignatures2 // With call signatures of mismatching parameter type -var x3 = function (a) { - return a.toString(); -}; +var x3 = function (a) { return a.toString(); }; // With call signature count mismatch -var x4 = function (a) { - return a.toString(); -}; +var x4 = function (a) { return a.toString(); }; diff --git a/tests/baselines/reference/contextualTypeWithUnionTypeIndexSignatures.js b/tests/baselines/reference/contextualTypeWithUnionTypeIndexSignatures.js index 7dfcb68301..2c07f46142 100644 --- a/tests/baselines/reference/contextualTypeWithUnionTypeIndexSignatures.js +++ b/tests/baselines/reference/contextualTypeWithUnionTypeIndexSignatures.js @@ -65,52 +65,16 @@ var x4: IWithNumberIndexSignature1 | IWithNumberIndexSignature2 = { 1: a => a }; // Let S be the set of types in U that has a string index signature. // If S is not empty, U has a string index signature of a union type of // the types of the string index signatures from each type in S. -var x = { - z: function (a) { - return a; - } -}; // a should be number -var x = { - foo: function (a) { - return a; - } -}; // a should be any -var x = { - foo: "hello" -}; -var x2 = { - z: function (a) { - return a.toString(); - } -}; // a should be number -var x2 = { - z: function (a) { - return a; - } -}; // a should be number +var x = { z: function (a) { return a; } }; // a should be number +var x = { foo: function (a) { return a; } }; // a should be any +var x = { foo: "hello" }; +var x2 = { z: function (a) { return a.toString(); } }; // a should be number +var x2 = { z: function (a) { return a; } }; // a should be number // Let S be the set of types in U that has a numeric index signature. // If S is not empty, U has a numeric index signature of a union type of // the types of the numeric index signatures from each type in S. -var x3 = { - 1: function (a) { - return a; - } -}; // a should be number -var x3 = { - 0: function (a) { - return a; - } -}; // a should be any -var x3 = { - 0: "hello" -}; -var x4 = { - 1: function (a) { - return a.toString(); - } -}; // a should be number -var x4 = { - 1: function (a) { - return a; - } -}; // a should be number +var x3 = { 1: function (a) { return a; } }; // a should be number +var x3 = { 0: function (a) { return a; } }; // a should be any +var x3 = { 0: "hello" }; +var x4 = { 1: function (a) { return a.toString(); } }; // a should be number +var x4 = { 1: function (a) { return a; } }; // a should be number diff --git a/tests/baselines/reference/contextualTypeWithUnionTypeMembers.js b/tests/baselines/reference/contextualTypeWithUnionTypeMembers.js index 7fd30a635a..10672d8679 100644 --- a/tests/baselines/reference/contextualTypeWithUnionTypeMembers.js +++ b/tests/baselines/reference/contextualTypeWithUnionTypeMembers.js @@ -128,94 +128,49 @@ var i1Ori2 = i1; var i1Ori2 = i2; var i1Ori2 = { commonPropertyType: "hello", - commonMethodType: function (a) { - return a; - }, - commonMethodWithTypeParameter: function (a) { - return a; - }, - methodOnlyInI1: function (a) { - return a; - }, + commonMethodType: function (a) { return a; }, + commonMethodWithTypeParameter: function (a) { return a; }, + methodOnlyInI1: function (a) { return a; }, propertyOnlyInI1: "Hello" }; var i1Ori2 = { commonPropertyType: "hello", - commonMethodType: function (a) { - return a; - }, - commonMethodWithTypeParameter: function (a) { - return a; - }, - methodOnlyInI2: function (a) { - return a; - }, + commonMethodType: function (a) { return a; }, + commonMethodWithTypeParameter: function (a) { return a; }, + methodOnlyInI2: function (a) { return a; }, propertyOnlyInI2: "Hello" }; var i1Ori2 = { commonPropertyType: "hello", - commonMethodType: function (a) { - return a; - }, - commonMethodWithTypeParameter: function (a) { - return a; - }, - methodOnlyInI1: function (a) { - return a; - }, + commonMethodType: function (a) { return a; }, + commonMethodWithTypeParameter: function (a) { return a; }, + methodOnlyInI1: function (a) { return a; }, propertyOnlyInI1: "Hello", - methodOnlyInI2: function (a) { - return a; - }, + methodOnlyInI2: function (a) { return a; }, propertyOnlyInI2: "Hello" }; -var arrayI1OrI2 = [ - i1, - i2, - { +var arrayI1OrI2 = [i1, i2, { commonPropertyType: "hello", - commonMethodType: function (a) { - return a; - }, - commonMethodWithTypeParameter: function (a) { - return a; - }, - methodOnlyInI1: function (a) { - return a; - }, + commonMethodType: function (a) { return a; }, + commonMethodWithTypeParameter: function (a) { return a; }, + methodOnlyInI1: function (a) { return a; }, propertyOnlyInI1: "Hello" }, { commonPropertyType: "hello", - commonMethodType: function (a) { - return a; - }, - commonMethodWithTypeParameter: function (a) { - return a; - }, - methodOnlyInI2: function (a) { - return a; - }, + commonMethodType: function (a) { return a; }, + commonMethodWithTypeParameter: function (a) { return a; }, + methodOnlyInI2: function (a) { return a; }, propertyOnlyInI2: "Hello" - }, - { + }, { commonPropertyType: "hello", - commonMethodType: function (a) { - return a; - }, - commonMethodWithTypeParameter: function (a) { - return a; - }, - methodOnlyInI1: function (a) { - return a; - }, + commonMethodType: function (a) { return a; }, + commonMethodWithTypeParameter: function (a) { return a; }, + methodOnlyInI1: function (a) { return a; }, propertyOnlyInI1: "Hello", - methodOnlyInI2: function (a) { - return a; - }, + methodOnlyInI2: function (a) { return a; }, propertyOnlyInI2: "Hello" - } -]; + }]; var i11; var i21; var i11Ori21 = i11; @@ -236,24 +191,18 @@ var i11Ori21 = { }, commonPropertyDifferentType: 10 }; -var arrayOrI11OrI21 = [ - i11, - i21, - i11 || i21, - { +var arrayOrI11OrI21 = [i11, i21, i11 || i21, { // Like i1 commonMethodDifferentReturnType: function (a, b) { var z = a.charAt(b); return z; }, commonPropertyDifferentType: "hello" - }, - { + }, { // Like i2 commonMethodDifferentReturnType: function (a, b) { var z = a.charCodeAt(b); return z; }, commonPropertyDifferentType: 10 - } -]; + }]; diff --git a/tests/baselines/reference/contextualTypeWithUnionTypeObjectLiteral.js b/tests/baselines/reference/contextualTypeWithUnionTypeObjectLiteral.js index d58b497a18..dc8f07823b 100644 --- a/tests/baselines/reference/contextualTypeWithUnionTypeObjectLiteral.js +++ b/tests/baselines/reference/contextualTypeWithUnionTypeObjectLiteral.js @@ -79,9 +79,7 @@ var objStrOrNum3 = { var objStrOrNum4 = { prop: strOrNumber }; -var objStrOrNum5 = { - prop: strOrNumber -}; +var objStrOrNum5 = { prop: strOrNumber }; var objStrOrNum6 = { prop: strOrNumber, anotherP: str @@ -113,7 +111,5 @@ var i11Ori21 = { }; var strOrNumber; var i11Ori21 = { - commonMethodDifferentReturnType: function (a, b) { - return strOrNumber; - } + commonMethodDifferentReturnType: function (a, b) { return strOrNumber; } }; diff --git a/tests/baselines/reference/contextualTyping.js b/tests/baselines/reference/contextualTyping.js index b4c565c509..75b98b16c3 100644 --- a/tests/baselines/reference/contextualTyping.js +++ b/tests/baselines/reference/contextualTyping.js @@ -249,48 +249,24 @@ var C2T5; }; })(C2T5 || (C2T5 = {})); // CONTEXT: Variable declaration -var c3t1 = (function (s) { - return s; -}); +var c3t1 = (function (s) { return s; }); var c3t2 = ({ n: 1 }); var c3t3 = []; -var c3t4 = function () { - return ({}); -}; -var c3t5 = function (n) { - return ({}); -}; -var c3t6 = function (n, s) { - return ({}); -}; -var c3t7 = function (n) { - return n; -}; -var c3t8 = function (n) { - return n; -}; -var c3t9 = [ - [], - [] -]; -var c3t10 = [ - ({}), - ({}) -]; -var c3t11 = [ - function (n, s) { - return s; - } -]; +var c3t4 = function () { return ({}); }; +var c3t5 = function (n) { return ({}); }; +var c3t6 = function (n, s) { return ({}); }; +var c3t7 = function (n) { return n; }; +var c3t8 = function (n) { return n; }; +var c3t9 = [[], []]; +var c3t10 = [({}), ({})]; +var c3t11 = [function (n, s) { return s; }]; var c3t12 = { foo: ({}) }; var c3t13 = ({ - f: function (i, s) { - return s; - } + f: function (i, s) { return s; } }); var c3t14 = ({ a: [] @@ -314,74 +290,41 @@ var C5T5; })(C5T5 || (C5T5 = {})); // CONTEXT: Variable assignment var c6t5; -c6t5 = function (n) { - return ({}); -}; +c6t5 = function (n) { return ({}); }; // CONTEXT: Array index assignment var c7t2; -c7t2[0] = ({ - n: 1 -}); +c7t2[0] = ({ n: 1 }); var objc8 = ({}); -objc8.t1 = (function (s) { - return s; -}); +objc8.t1 = (function (s) { return s; }); objc8.t2 = ({ n: 1 }); objc8.t3 = []; -objc8.t4 = function () { - return ({}); -}; -objc8.t5 = function (n) { - return ({}); -}; -objc8.t6 = function (n, s) { - return ({}); -}; -objc8.t7 = function (n) { - return n; -}; -objc8.t8 = function (n) { - return n; -}; -objc8.t9 = [ - [], - [] -]; -objc8.t10 = [ - ({}), - ({}) -]; -objc8.t11 = [ - function (n, s) { - return s; - } -]; +objc8.t4 = function () { return ({}); }; +objc8.t5 = function (n) { return ({}); }; +objc8.t6 = function (n, s) { return ({}); }; +objc8.t7 = function (n) { return n; }; +objc8.t8 = function (n) { return n; }; +objc8.t9 = [[], []]; +objc8.t10 = [({}), ({})]; +objc8.t11 = [function (n, s) { return s; }]; objc8.t12 = { foo: ({}) }; objc8.t13 = ({ - f: function (i, s) { - return s; - } + f: function (i, s) { return s; } }); objc8.t14 = ({ a: [] }); // CONTEXT: Function call -function c9t5(f) { -} +function c9t5(f) { } ; c9t5(function (n) { return ({}); }); // CONTEXT: Return statement -var c10t5 = function () { - return function (n) { - return ({}); - }; -}; +var c10t5 = function () { return function (n) { return ({}); }; }; // CONTEXT: Newing a class var C11t5 = (function () { function C11t5(f) { @@ -389,59 +332,31 @@ var C11t5 = (function () { return C11t5; })(); ; -var i = new C11t5(function (n) { - return ({}); -}); +var i = new C11t5(function (n) { return ({}); }); // CONTEXT: Type annotated expression -var c12t1 = (function (s) { - return s; -}); +var c12t1 = (function (s) { return s; }); var c12t2 = ({ n: 1 }); var c12t3 = []; -var c12t4 = function () { - return ({}); -}; -var c12t5 = function (n) { - return ({}); -}; -var c12t6 = function (n, s) { - return ({}); -}; -var c12t7 = function (n) { - return n; -}; -var c12t8 = function (n) { - return n; -}; -var c12t9 = [ - [], - [] -]; -var c12t10 = [ - ({}), - ({}) -]; -var c12t11 = [ - function (n, s) { - return s; - } -]; +var c12t4 = function () { return ({}); }; +var c12t5 = function (n) { return ({}); }; +var c12t6 = function (n, s) { return ({}); }; +var c12t7 = function (n) { return n; }; +var c12t8 = function (n) { return n; }; +var c12t9 = [[], []]; +var c12t10 = [({}), ({})]; +var c12t11 = [function (n, s) { return s; }]; var c12t12 = { foo: ({}) }; var c12t13 = ({ - f: function (i, s) { - return s; - } + f: function (i, s) { return s; } }); var c12t14 = ({ a: [] }); -function EF1(a, b) { - return a + b; -} +function EF1(a, b) { return a + b; } var efv = EF1(1, 2); function Point(x, y) { this.x = x; diff --git a/tests/baselines/reference/contextualTyping.js.map b/tests/baselines/reference/contextualTyping.js.map index 0b38517f9c..a8835dc965 100644 --- a/tests/baselines/reference/contextualTyping.js.map +++ b/tests/baselines/reference/contextualTyping.js.map @@ -1,2 +1,2 @@ //// [contextualTyping.js.map] -{"version":3,"file":"contextualTyping.js","sourceRoot":"","sources":["contextualTyping.ts"],"names":["C1T5","C1T5.constructor","C2T5","C4T5","C4T5.constructor","C5T5","c9t5","C11t5","C11t5.constructor","EF1","Point"],"mappings":"AAaA,AADA,sCAAsC;;IACtCA;QACIC,QAAGA,GAAqCA,UAASA,CAACA;YAC9C,MAAM,CAAC,CAAC,CAAC;QACb,CAAC,CAAAA;IACLA,CAACA;IAADD,WAACA;AAADA,CAACA,AAJD,IAIC;AAGD,AADA,uCAAuC;AACvC,IAAO,IAAI,CAIV;AAJD,WAAO,IAAI,EAAC,CAAC;IACEE,QAAGA,GAAqCA,UAASA,CAACA;QACzD,MAAM,CAAC,CAAC,CAAC;IACb,CAAC,CAAAA;AACLA,CAACA,EAJM,IAAI,KAAJ,IAAI,QAIV;AAGD,AADA,gCAAgC;IAC5B,IAAI,GAA0B,CAAC,UAAS,CAAC;IAAI,MAAM,CAAC,CAAC,CAAA;AAAC,CAAC,CAAC,CAAC;AAC7D,IAAI,IAAI,GAAS,CAAC;IACd,CAAC,EAAE,CAAC;CACP,CAAC,CAAA;AACF,IAAI,IAAI,GAAa,EAAE,CAAC;AACxB,IAAI,IAAI,GAAe;IAAa,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AACxD,IAAI,IAAI,GAAwB,UAAS,CAAC;IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AAClE,IAAI,IAAI,GAAmC,UAAS,CAAC,EAAE,CAAC;IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AAChF,IAAI,IAAI,GAGJ,UAAS,CAAC;IAAI,MAAM,CAAC,CAAC,CAAC;AAAC,CAAC,CAAC;AAE9B,IAAI,IAAI,GAAqC,UAAS,CAAC;IAAI,MAAM,CAAC,CAAC,CAAC;AAAC,CAAC,CAAC;AACvE,IAAI,IAAI,GAAe;IAAC,EAAE;IAAC,EAAE;CAAC,CAAC;AAC/B,IAAI,KAAK,GAAW;IAAO,CAAC,EAAE,CAAC;IAAO,CAAC,EAAE,CAAC;CAAC,CAAC;AAC5C,IAAI,KAAK,GAAwC;IAAC,UAAS,CAAC,EAAE,CAAC;QAAI,MAAM,CAAC,CAAC,CAAC;IAAC,CAAC;CAAC,CAAC;AAChF,IAAI,KAAK,GAAS;IACd,GAAG,EAAQ,CAAC,EAAE,CAAC;CAClB,CAAA;AACD,IAAI,KAAK,GAAS,CAAC;IACf,CAAC,EAAE,UAAS,CAAC,EAAE,CAAC;QAAI,MAAM,CAAC,CAAC,CAAC;IAAC,CAAC;CAClC,CAAC,CAAA;AACF,IAAI,KAAK,GAAS,CAAC;IACf,CAAC,EAAE,EAAE;CACR,CAAC,CAAA;AAGF,AADA,qCAAqC;;IAGjCC;QACIC,IAAIA,CAACA,GAAGA,GAAGA,UAASA,CAACA,EAAEA,CAACA;YACpB,MAAM,CAAC,CAAC,CAAC;QACb,CAAC,CAAAA;IACLA,CAACA;IACLD,WAACA;AAADA,CAACA,AAPD,IAOC;AAGD,AADA,sCAAsC;AACtC,IAAO,IAAI,CAKV;AALD,WAAO,IAAI,EAAC,CAAC;IACEE,QAAqCA,CAACA;IACjDA,QAAGA,GAAGA,UAASA,CAACA,EAAEA,CAACA;QACf,MAAM,CAAC,CAAC,CAAC;IACb,CAAC,CAAAA;AACLA,CAACA,EALM,IAAI,KAAJ,IAAI,QAKV;AAGD,AADA,+BAA+B;IAC3B,IAAyB,CAAC;AAC9B,IAAI,GAAwB,UAAS,CAAC;IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AAG9D,AADA,kCAAkC;IAC9B,IAAY,CAAC;AACjB,IAAI,CAAC,CAAC,CAAC,GAAS,CAAC;IAAC,CAAC,EAAE,CAAC;CAAC,CAAC,CAAC;AAuBzB,IAAI,KAAK,GAkBS,CAAC,EAAE,CAAC,CAAC;AAEvB,KAAK,CAAC,EAAE,GAAG,CAAC,UAAS,CAAC;IAAI,MAAM,CAAC,CAAC,CAAA;AAAC,CAAC,CAAC,CAAC;AACtC,KAAK,CAAC,EAAE,GAAS,CAAC;IACd,CAAC,EAAE,CAAC;CACP,CAAC,CAAC;AACH,KAAK,CAAC,EAAE,GAAG,EAAE,CAAC;AACd,KAAK,CAAC,EAAE,GAAG;IAAa,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AAC5C,KAAK,CAAC,EAAE,GAAG,UAAS,CAAC;IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AAC7C,KAAK,CAAC,EAAE,GAAG,UAAS,CAAC,EAAE,CAAC;IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AAChD,KAAK,CAAC,EAAE,GAAG,UAAS,CAAS;IAAI,MAAM,CAAC,CAAC,CAAA;AAAC,CAAC,CAAC;AAE5C,KAAK,CAAC,EAAE,GAAG,UAAS,CAAC;IAAI,MAAM,CAAC,CAAC,CAAC;AAAC,CAAC,CAAC;AACrC,KAAK,CAAC,EAAE,GAAG;IAAC,EAAE;IAAC,EAAE;CAAC,CAAC;AACnB,KAAK,CAAC,GAAG,GAAG;IAAO,CAAC,EAAE,CAAC;IAAO,CAAC,EAAE,CAAC;CAAC,CAAC;AACpC,KAAK,CAAC,GAAG,GAAG;IAAC,UAAS,CAAC,EAAE,CAAC;QAAI,MAAM,CAAC,CAAC,CAAC;IAAC,CAAC;CAAC,CAAC;AAC3C,KAAK,CAAC,GAAG,GAAG;IACR,GAAG,EAAQ,CAAC,EAAE,CAAC;CAClB,CAAA;AACD,KAAK,CAAC,GAAG,GAAS,CAAC;IACf,CAAC,EAAE,UAAS,CAAC,EAAE,CAAC;QAAI,MAAM,CAAC,CAAC,CAAC;IAAC,CAAC;CAClC,CAAC,CAAA;AACF,KAAK,CAAC,GAAG,GAAS,CAAC;IACf,CAAC,EAAE,EAAE;CACR,CAAC,CAAA;AAEF,AADA,yBAAyB;cACX,CAAsB;AAAGC,CAACA;AAAA,CAAC;AACzC,IAAI,CAAC,UAAS,CAAC;IACX,MAAM,CAAO,CAAC,EAAE,CAAC,CAAC;AACtB,CAAC,CAAC,CAAC;AAGH,AADA,4BAA4B;IACxB,KAAK,GAA8B;IAAa,MAAM,CAAC,UAAS,CAAC;QAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;IAAC,CAAC,CAAA;AAAC,CAAC,CAAC;AAG/F,AADA,0BAA0B;;IACZC,eAAYA,CAAsBA;IAAIC,CAACA;IAACD,YAACA;AAADA,CAACA,AAAvD,IAAuD;AAAA,CAAC;AACxD,IAAI,CAAC,GAAG,IAAI,KAAK,CAAC,UAAS,CAAC;IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC,CAAC;AAGrD,AADA,qCAAqC;IACjC,KAAK,GAA2B,CAAC,UAAS,CAAC;IAAI,MAAM,CAAC,CAAC,CAAA;AAAC,CAAC,CAAC,CAAC;AAC/D,IAAI,KAAK,GAAU,CAAC;IAChB,CAAC,EAAE,CAAC;CACP,CAAC,CAAC;AACH,IAAI,KAAK,GAAc,EAAE,CAAC;AAC1B,IAAI,KAAK,GAAgB;IAAa,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AAC1D,IAAI,KAAK,GAAyB,UAAS,CAAC;IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AACpE,IAAI,KAAK,GAAoC,UAAS,CAAC,EAAE,CAAC;IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA;AAAC,CAAC,CAAC;AAClF,IAAI,KAAK,GAGN,UAAS,CAAQ;IAAI,MAAM,CAAC,CAAC,CAAA;AAAC,CAAC,CAAC;AAEnC,IAAI,KAAK,GAAsC,UAAS,CAAC;IAAI,MAAM,CAAC,CAAC,CAAC;AAAC,CAAC,CAAC;AACzE,IAAI,KAAK,GAAgB;IAAC,EAAE;IAAC,EAAE;CAAC,CAAC;AACjC,IAAI,MAAM,GAAY;IAAO,CAAC,EAAE,CAAC;IAAO,CAAC,EAAE,CAAC;CAAC,CAAC;AAC9C,IAAI,MAAM,GAAyC;IAAC,UAAS,CAAC,EAAE,CAAC;QAAI,MAAM,CAAC,CAAC,CAAC;IAAC,CAAC;CAAC,CAAC;AAClF,IAAI,MAAM,GAAU;IAChB,GAAG,EAAQ,CAAC,EAAE,CAAC;CAClB,CAAA;AACD,IAAI,MAAM,GAAU,CAAC;IACjB,CAAC,EAAE,UAAS,CAAC,EAAE,CAAC;QAAI,MAAM,CAAC,CAAC,CAAC;IAAC,CAAC;CAClC,CAAC,CAAA;AACF,IAAI,MAAM,GAAU,CAAC;IACjB,CAAC,EAAE,EAAE;CACR,CAAC,CAAA;AAOF,aAAa,CAAC,EAAC,CAAC;IAAIE,MAAMA,CAACA,CAACA,GAACA,CAACA,CAACA;AAACA,CAACA;AAEjC,IAAI,GAAG,GAAG,GAAG,CAAC,CAAC,EAAC,CAAC,CAAC,CAAC;AAcnB,eAAe,CAAC,EAAE,CAAC;IACfC,IAAIA,CAACA,CAACA,GAAGA,CAACA,CAACA;IACXA,IAAIA,CAACA,CAACA,GAAGA,CAACA,CAACA;IAEXA,MAAMA,CAACA,IAAIA,CAACA;AAChBA,CAACA;AAED,KAAK,CAAC,MAAM,GAAG,IAAI,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAE/B,KAAK,CAAC,SAAS,CAAC,GAAG,GAAG,UAAS,EAAE,EAAE,EAAE;IACjC,MAAM,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,CAAC,GAAG,EAAE,CAAC,CAAC;AAC/C,CAAC,CAAC;AAEF,KAAK,CAAC,SAAS,GAAG;IACd,CAAC,EAAE,CAAC;IACJ,CAAC,EAAE,CAAC;IACJ,GAAG,EAAE,UAAS,EAAE,EAAE,EAAE;QAChB,MAAM,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,CAAC,GAAG,EAAE,CAAC,CAAC;IAC/C,CAAC;CACJ,CAAC;AAIF,IAAI,CAAC,GAAM,EAAG,CAAC"} \ No newline at end of file +{"version":3,"file":"contextualTyping.js","sourceRoot":"","sources":["contextualTyping.ts"],"names":["C1T5","C1T5.constructor","C2T5","C4T5","C4T5.constructor","C5T5","c9t5","C11t5","C11t5.constructor","EF1","Point"],"mappings":"AAaA,AADA,sCAAsC;;IACtCA;QACIC,QAAGA,GAAqCA,UAASA,CAACA;YAC9C,MAAM,CAAC,CAAC,CAAC;QACb,CAAC,CAAAA;IACLA,CAACA;IAADD,WAACA;AAADA,CAACA,AAJD,IAIC;AAGD,AADA,uCAAuC;AACvC,IAAO,IAAI,CAIV;AAJD,WAAO,IAAI,EAAC,CAAC;IACEE,QAAGA,GAAqCA,UAASA,CAACA;QACzD,MAAM,CAAC,CAAC,CAAC;IACb,CAAC,CAAAA;AACLA,CAACA,EAJM,IAAI,KAAJ,IAAI,QAIV;AAGD,AADA,gCAAgC;IAC5B,IAAI,GAA0B,CAAC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAA,CAAC,CAAC,CAAC,CAAC;AAC7D,IAAI,IAAI,GAAS,CAAC;IACd,CAAC,EAAE,CAAC;CACP,CAAC,CAAA;AACF,IAAI,IAAI,GAAa,EAAE,CAAC;AACxB,IAAI,IAAI,GAAe,cAAa,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AACxD,IAAI,IAAI,GAAwB,UAAS,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AAClE,IAAI,IAAI,GAAmC,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AAChF,IAAI,IAAI,GAGJ,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAE9B,IAAI,IAAI,GAAqC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACvE,IAAI,IAAI,GAAe,CAAC,EAAE,EAAC,EAAE,CAAC,CAAC;AAC/B,IAAI,KAAK,GAAW,CAAO,CAAC,EAAE,CAAC,EAAO,CAAC,EAAE,CAAC,CAAC,CAAC;AAC5C,IAAI,KAAK,GAAwC,CAAC,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAChF,IAAI,KAAK,GAAS;IACd,GAAG,EAAQ,CAAC,EAAE,CAAC;CAClB,CAAA;AACD,IAAI,KAAK,GAAS,CAAC;IACf,CAAC,EAAE,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;CAClC,CAAC,CAAA;AACF,IAAI,KAAK,GAAS,CAAC;IACf,CAAC,EAAE,EAAE;CACR,CAAC,CAAA;AAGF,AADA,qCAAqC;;IAGjCC;QACIC,IAAIA,CAACA,GAAGA,GAAGA,UAASA,CAACA,EAAEA,CAACA;YACpB,MAAM,CAAC,CAAC,CAAC;QACb,CAAC,CAAAA;IACLA,CAACA;IACLD,WAACA;AAADA,CAACA,AAPD,IAOC;AAGD,AADA,sCAAsC;AACtC,IAAO,IAAI,CAKV;AALD,WAAO,IAAI,EAAC,CAAC;IACEE,QAAqCA,CAACA;IACjDA,QAAGA,GAAGA,UAASA,CAACA,EAAEA,CAACA;QACf,MAAM,CAAC,CAAC,CAAC;IACb,CAAC,CAAAA;AACLA,CAACA,EALM,IAAI,KAAJ,IAAI,QAKV;AAGD,AADA,+BAA+B;IAC3B,IAAyB,CAAC;AAC9B,IAAI,GAAwB,UAAS,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AAG9D,AADA,kCAAkC;IAC9B,IAAY,CAAC;AACjB,IAAI,CAAC,CAAC,CAAC,GAAS,CAAC,EAAC,CAAC,EAAE,CAAC,EAAC,CAAC,CAAC;AAuBzB,IAAI,KAAK,GAkBS,CAAC,EAAE,CAAC,CAAC;AAEvB,KAAK,CAAC,EAAE,GAAG,CAAC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAA,CAAC,CAAC,CAAC,CAAC;AACtC,KAAK,CAAC,EAAE,GAAS,CAAC;IACd,CAAC,EAAE,CAAC;CACP,CAAC,CAAC;AACH,KAAK,CAAC,EAAE,GAAG,EAAE,CAAC;AACd,KAAK,CAAC,EAAE,GAAG,cAAa,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AAC5C,KAAK,CAAC,EAAE,GAAG,UAAS,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AAC7C,KAAK,CAAC,EAAE,GAAG,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AAChD,KAAK,CAAC,EAAE,GAAG,UAAS,CAAS,IAAI,MAAM,CAAC,CAAC,CAAA,CAAC,CAAC,CAAC;AAE5C,KAAK,CAAC,EAAE,GAAG,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACrC,KAAK,CAAC,EAAE,GAAG,CAAC,EAAE,EAAC,EAAE,CAAC,CAAC;AACnB,KAAK,CAAC,GAAG,GAAG,CAAO,CAAC,EAAE,CAAC,EAAO,CAAC,EAAE,CAAC,CAAC,CAAC;AACpC,KAAK,CAAC,GAAG,GAAG,CAAC,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAC3C,KAAK,CAAC,GAAG,GAAG;IACR,GAAG,EAAQ,CAAC,EAAE,CAAC;CAClB,CAAA;AACD,KAAK,CAAC,GAAG,GAAS,CAAC;IACf,CAAC,EAAE,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;CAClC,CAAC,CAAA;AACF,KAAK,CAAC,GAAG,GAAS,CAAC;IACf,CAAC,EAAE,EAAE;CACR,CAAC,CAAA;AAEF,AADA,yBAAyB;cACX,CAAsB,IAAGC,CAACA;AAAA,CAAC;AACzC,IAAI,CAAC,UAAS,CAAC;IACX,MAAM,CAAO,CAAC,EAAE,CAAC,CAAC;AACtB,CAAC,CAAC,CAAC;AAGH,AADA,4BAA4B;IACxB,KAAK,GAA8B,cAAa,MAAM,CAAC,UAAS,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAA,CAAC,CAAC,CAAC;AAG/F,AADA,0BAA0B;;IACZC,eAAYA,CAAsBA;IAAIC,CAACA;IAACD,YAACA;AAADA,CAACA,AAAvD,IAAuD;AAAA,CAAC;AACxD,IAAI,CAAC,GAAG,IAAI,KAAK,CAAC,UAAS,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC,CAAC;AAGrD,AADA,qCAAqC;IACjC,KAAK,GAA2B,CAAC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAA,CAAC,CAAC,CAAC,CAAC;AAC/D,IAAI,KAAK,GAAU,CAAC;IAChB,CAAC,EAAE,CAAC;CACP,CAAC,CAAC;AACH,IAAI,KAAK,GAAc,EAAE,CAAC;AAC1B,IAAI,KAAK,GAAgB,cAAa,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AAC1D,IAAI,KAAK,GAAyB,UAAS,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AACpE,IAAI,KAAK,GAAoC,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAO,CAAC,EAAE,CAAC,CAAA,CAAC,CAAC,CAAC;AAClF,IAAI,KAAK,GAGN,UAAS,CAAQ,IAAI,MAAM,CAAC,CAAC,CAAA,CAAC,CAAC,CAAC;AAEnC,IAAI,KAAK,GAAsC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACzE,IAAI,KAAK,GAAgB,CAAC,EAAE,EAAC,EAAE,CAAC,CAAC;AACjC,IAAI,MAAM,GAAY,CAAO,CAAC,EAAE,CAAC,EAAO,CAAC,EAAE,CAAC,CAAC,CAAC;AAC9C,IAAI,MAAM,GAAyC,CAAC,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAClF,IAAI,MAAM,GAAU;IAChB,GAAG,EAAQ,CAAC,EAAE,CAAC;CAClB,CAAA;AACD,IAAI,MAAM,GAAU,CAAC;IACjB,CAAC,EAAE,UAAS,CAAC,EAAE,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;CAClC,CAAC,CAAA;AACF,IAAI,MAAM,GAAU,CAAC;IACjB,CAAC,EAAE,EAAE;CACR,CAAC,CAAA;AAOF,aAAa,CAAC,EAAC,CAAC,IAAIE,MAAMA,CAACA,CAACA,GAACA,CAACA,CAACA,CAACA,CAACA;AAEjC,IAAI,GAAG,GAAG,GAAG,CAAC,CAAC,EAAC,CAAC,CAAC,CAAC;AAcnB,eAAe,CAAC,EAAE,CAAC;IACfC,IAAIA,CAACA,CAACA,GAAGA,CAACA,CAACA;IACXA,IAAIA,CAACA,CAACA,GAAGA,CAACA,CAACA;IAEXA,MAAMA,CAACA,IAAIA,CAACA;AAChBA,CAACA;AAED,KAAK,CAAC,MAAM,GAAG,IAAI,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAE/B,KAAK,CAAC,SAAS,CAAC,GAAG,GAAG,UAAS,EAAE,EAAE,EAAE;IACjC,MAAM,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,CAAC,GAAG,EAAE,CAAC,CAAC;AAC/C,CAAC,CAAC;AAEF,KAAK,CAAC,SAAS,GAAG;IACd,CAAC,EAAE,CAAC;IACJ,CAAC,EAAE,CAAC;IACJ,GAAG,EAAE,UAAS,EAAE,EAAE,EAAE;QAChB,MAAM,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,CAAC,GAAG,EAAE,CAAC,CAAC;IAC/C,CAAC;CACJ,CAAC;AAIF,IAAI,CAAC,GAAM,EAAG,CAAC"} \ No newline at end of file diff --git a/tests/baselines/reference/contextualTyping.sourcemap.txt b/tests/baselines/reference/contextualTyping.sourcemap.txt index 225aa3285f..085f6a439f 100644 --- a/tests/baselines/reference/contextualTyping.sourcemap.txt +++ b/tests/baselines/reference/contextualTyping.sourcemap.txt @@ -259,6 +259,7 @@ sourceFile:contextualTyping.ts 1-> 2 > 3 >^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +4 > ^^^^^^^^^-> 1-> > >// CONTEXT: Variable declaration @@ -269,76 +270,71 @@ sourceFile:contextualTyping.ts 2 >Emitted(17, 1) Source(27, 1) + SourceIndex(0) 3 >Emitted(17, 33) Source(27, 33) + SourceIndex(0) --- ->>>var c3t1 = (function (s) { -1 >^^^^ +>>>var c3t1 = (function (s) { return s; }); +1->^^^^ 2 > ^^^^ 3 > ^^^ 4 > ^ 5 > ^^^^^^^^^^ 6 > ^ -1 > +7 > ^^^^ +8 > ^^^^^^ +9 > ^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^ +1-> >var 2 > c3t1 3 > : (s: string) => string = 4 > ( 5 > function( 6 > s -1 >Emitted(18, 5) Source(28, 5) + SourceIndex(0) +7 > ) { +8 > return +9 > +10> s +11> +12> +13> } +14> ) +15> ; +1->Emitted(18, 5) Source(28, 5) + SourceIndex(0) 2 >Emitted(18, 9) Source(28, 9) + SourceIndex(0) 3 >Emitted(18, 12) Source(28, 35) + SourceIndex(0) 4 >Emitted(18, 13) Source(28, 36) + SourceIndex(0) 5 >Emitted(18, 23) Source(28, 45) + SourceIndex(0) 6 >Emitted(18, 24) Source(28, 46) + SourceIndex(0) ---- ->>> return s; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > -1 >Emitted(19, 5) Source(28, 50) + SourceIndex(0) -2 >Emitted(19, 11) Source(28, 56) + SourceIndex(0) -3 >Emitted(19, 12) Source(28, 57) + SourceIndex(0) -4 >Emitted(19, 13) Source(28, 58) + SourceIndex(0) -5 >Emitted(19, 14) Source(28, 58) + SourceIndex(0) ---- ->>>}); -1 > -2 >^ -3 > ^ -4 > ^ -5 > ^^^^^^^^^^^-> -1 > -2 >} -3 > ) -4 > ; -1 >Emitted(20, 1) Source(28, 59) + SourceIndex(0) -2 >Emitted(20, 2) Source(28, 60) + SourceIndex(0) -3 >Emitted(20, 3) Source(28, 61) + SourceIndex(0) -4 >Emitted(20, 4) Source(28, 62) + SourceIndex(0) +7 >Emitted(18, 28) Source(28, 50) + SourceIndex(0) +8 >Emitted(18, 34) Source(28, 56) + SourceIndex(0) +9 >Emitted(18, 35) Source(28, 57) + SourceIndex(0) +10>Emitted(18, 36) Source(28, 58) + SourceIndex(0) +11>Emitted(18, 37) Source(28, 58) + SourceIndex(0) +12>Emitted(18, 38) Source(28, 59) + SourceIndex(0) +13>Emitted(18, 39) Source(28, 60) + SourceIndex(0) +14>Emitted(18, 40) Source(28, 61) + SourceIndex(0) +15>Emitted(18, 41) Source(28, 62) + SourceIndex(0) --- >>>var c3t2 = ({ -1-> +1 > 2 >^^^^ 3 > ^^^^ 4 > ^^^ 5 > ^ -1-> +1 > > 2 >var 3 > c3t2 4 > = 5 > ( -1->Emitted(21, 1) Source(29, 1) + SourceIndex(0) -2 >Emitted(21, 5) Source(29, 5) + SourceIndex(0) -3 >Emitted(21, 9) Source(29, 9) + SourceIndex(0) -4 >Emitted(21, 12) Source(29, 18) + SourceIndex(0) -5 >Emitted(21, 13) Source(29, 19) + SourceIndex(0) +1 >Emitted(19, 1) Source(29, 1) + SourceIndex(0) +2 >Emitted(19, 5) Source(29, 5) + SourceIndex(0) +3 >Emitted(19, 9) Source(29, 9) + SourceIndex(0) +4 >Emitted(19, 12) Source(29, 18) + SourceIndex(0) +5 >Emitted(19, 13) Source(29, 19) + SourceIndex(0) --- >>> n: 1 1 >^^^^ @@ -350,10 +346,10 @@ sourceFile:contextualTyping.ts 2 > n 3 > : 4 > 1 -1 >Emitted(22, 5) Source(30, 5) + SourceIndex(0) -2 >Emitted(22, 6) Source(30, 6) + SourceIndex(0) -3 >Emitted(22, 8) Source(30, 8) + SourceIndex(0) -4 >Emitted(22, 9) Source(30, 9) + SourceIndex(0) +1 >Emitted(20, 5) Source(30, 5) + SourceIndex(0) +2 >Emitted(20, 6) Source(30, 6) + SourceIndex(0) +3 >Emitted(20, 8) Source(30, 8) + SourceIndex(0) +4 >Emitted(20, 9) Source(30, 9) + SourceIndex(0) --- >>>}); 1 >^ @@ -364,9 +360,9 @@ sourceFile:contextualTyping.ts >} 2 > ) 3 > -1 >Emitted(23, 2) Source(31, 2) + SourceIndex(0) -2 >Emitted(23, 3) Source(31, 3) + SourceIndex(0) -3 >Emitted(23, 4) Source(31, 3) + SourceIndex(0) +1 >Emitted(21, 2) Source(31, 2) + SourceIndex(0) +2 >Emitted(21, 3) Source(31, 3) + SourceIndex(0) +3 >Emitted(21, 4) Source(31, 3) + SourceIndex(0) --- >>>var c3t3 = []; 1-> @@ -375,7 +371,7 @@ sourceFile:contextualTyping.ts 4 > ^^^ 5 > ^^ 6 > ^ -7 > ^^^^^^^^^^^-> +7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >var @@ -383,71 +379,77 @@ sourceFile:contextualTyping.ts 4 > : number[] = 5 > [] 6 > ; -1->Emitted(24, 1) Source(32, 1) + SourceIndex(0) -2 >Emitted(24, 5) Source(32, 5) + SourceIndex(0) -3 >Emitted(24, 9) Source(32, 9) + SourceIndex(0) -4 >Emitted(24, 12) Source(32, 22) + SourceIndex(0) -5 >Emitted(24, 14) Source(32, 24) + SourceIndex(0) -6 >Emitted(24, 15) Source(32, 25) + SourceIndex(0) +1->Emitted(22, 1) Source(32, 1) + SourceIndex(0) +2 >Emitted(22, 5) Source(32, 5) + SourceIndex(0) +3 >Emitted(22, 9) Source(32, 9) + SourceIndex(0) +4 >Emitted(22, 12) Source(32, 22) + SourceIndex(0) +5 >Emitted(22, 14) Source(32, 24) + SourceIndex(0) +6 >Emitted(22, 15) Source(32, 25) + SourceIndex(0) --- ->>>var c3t4 = function () { +>>>var c3t4 = function () { return ({}); }; 1-> 2 >^^^^ 3 > ^^^^ 4 > ^^^ -5 > ^^^^^^-> +5 > ^^^^^^^^^^^^^^ +6 > ^^^^^^ +7 > ^ +8 > ^ +9 > ^^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^^-> 1-> > 2 >var 3 > c3t4 4 > : () => IFoo = -1->Emitted(25, 1) Source(33, 1) + SourceIndex(0) -2 >Emitted(25, 5) Source(33, 5) + SourceIndex(0) -3 >Emitted(25, 9) Source(33, 9) + SourceIndex(0) -4 >Emitted(25, 12) Source(33, 24) + SourceIndex(0) +5 > function() { +6 > return +7 > +8 > ( +9 > {} +10> ) +11> +12> +13> } +14> ; +1->Emitted(23, 1) Source(33, 1) + SourceIndex(0) +2 >Emitted(23, 5) Source(33, 5) + SourceIndex(0) +3 >Emitted(23, 9) Source(33, 9) + SourceIndex(0) +4 >Emitted(23, 12) Source(33, 24) + SourceIndex(0) +5 >Emitted(23, 26) Source(33, 37) + SourceIndex(0) +6 >Emitted(23, 32) Source(33, 43) + SourceIndex(0) +7 >Emitted(23, 33) Source(33, 50) + SourceIndex(0) +8 >Emitted(23, 34) Source(33, 51) + SourceIndex(0) +9 >Emitted(23, 36) Source(33, 53) + SourceIndex(0) +10>Emitted(23, 37) Source(33, 54) + SourceIndex(0) +11>Emitted(23, 38) Source(33, 54) + SourceIndex(0) +12>Emitted(23, 39) Source(33, 55) + SourceIndex(0) +13>Emitted(23, 40) Source(33, 56) + SourceIndex(0) +14>Emitted(23, 41) Source(33, 57) + SourceIndex(0) --- ->>> return ({}); -1->^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1->function() { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1->Emitted(26, 5) Source(33, 37) + SourceIndex(0) -2 >Emitted(26, 11) Source(33, 43) + SourceIndex(0) -3 >Emitted(26, 12) Source(33, 50) + SourceIndex(0) -4 >Emitted(26, 13) Source(33, 51) + SourceIndex(0) -5 >Emitted(26, 15) Source(33, 53) + SourceIndex(0) -6 >Emitted(26, 16) Source(33, 54) + SourceIndex(0) -7 >Emitted(26, 17) Source(33, 54) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(27, 1) Source(33, 55) + SourceIndex(0) -2 >Emitted(27, 2) Source(33, 56) + SourceIndex(0) -3 >Emitted(27, 3) Source(33, 57) + SourceIndex(0) ---- ->>>var c3t5 = function (n) { +>>>var c3t5 = function (n) { return ({}); }; 1-> 2 >^^^^ 3 > ^^^^ 4 > ^^^ 5 > ^^^^^^^^^^ 6 > ^ +7 > ^^^^ +8 > ^^^^^^ +9 > ^ +10> ^ +11> ^^ +12> ^ +13> ^ +14> ^ +15> ^ +16> ^ +17> ^^^^-> 1-> > 2 >var @@ -455,49 +457,34 @@ sourceFile:contextualTyping.ts 4 > : (n: number) => IFoo = 5 > function( 6 > n -1->Emitted(28, 1) Source(34, 1) + SourceIndex(0) -2 >Emitted(28, 5) Source(34, 5) + SourceIndex(0) -3 >Emitted(28, 9) Source(34, 9) + SourceIndex(0) -4 >Emitted(28, 12) Source(34, 33) + SourceIndex(0) -5 >Emitted(28, 22) Source(34, 42) + SourceIndex(0) -6 >Emitted(28, 23) Source(34, 43) + SourceIndex(0) +7 > ) { +8 > return +9 > +10> ( +11> {} +12> ) +13> +14> +15> } +16> ; +1->Emitted(24, 1) Source(34, 1) + SourceIndex(0) +2 >Emitted(24, 5) Source(34, 5) + SourceIndex(0) +3 >Emitted(24, 9) Source(34, 9) + SourceIndex(0) +4 >Emitted(24, 12) Source(34, 33) + SourceIndex(0) +5 >Emitted(24, 22) Source(34, 42) + SourceIndex(0) +6 >Emitted(24, 23) Source(34, 43) + SourceIndex(0) +7 >Emitted(24, 27) Source(34, 47) + SourceIndex(0) +8 >Emitted(24, 33) Source(34, 53) + SourceIndex(0) +9 >Emitted(24, 34) Source(34, 60) + SourceIndex(0) +10>Emitted(24, 35) Source(34, 61) + SourceIndex(0) +11>Emitted(24, 37) Source(34, 63) + SourceIndex(0) +12>Emitted(24, 38) Source(34, 64) + SourceIndex(0) +13>Emitted(24, 39) Source(34, 64) + SourceIndex(0) +14>Emitted(24, 40) Source(34, 65) + SourceIndex(0) +15>Emitted(24, 41) Source(34, 66) + SourceIndex(0) +16>Emitted(24, 42) Source(34, 67) + SourceIndex(0) --- ->>> return ({}); -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(29, 5) Source(34, 47) + SourceIndex(0) -2 >Emitted(29, 11) Source(34, 53) + SourceIndex(0) -3 >Emitted(29, 12) Source(34, 60) + SourceIndex(0) -4 >Emitted(29, 13) Source(34, 61) + SourceIndex(0) -5 >Emitted(29, 15) Source(34, 63) + SourceIndex(0) -6 >Emitted(29, 16) Source(34, 64) + SourceIndex(0) -7 >Emitted(29, 17) Source(34, 64) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(30, 1) Source(34, 65) + SourceIndex(0) -2 >Emitted(30, 2) Source(34, 66) + SourceIndex(0) -3 >Emitted(30, 3) Source(34, 67) + SourceIndex(0) ---- ->>>var c3t6 = function (n, s) { +>>>var c3t6 = function (n, s) { return ({}); }; 1-> 2 >^^^^ 3 > ^^^^ @@ -506,6 +493,16 @@ sourceFile:contextualTyping.ts 6 > ^ 7 > ^^ 8 > ^ +9 > ^^^^ +10> ^^^^^^ +11> ^ +12> ^ +13> ^^ +14> ^ +15> ^ +16> ^ +17> ^ +18> ^ 1-> > 2 >var @@ -515,58 +512,52 @@ sourceFile:contextualTyping.ts 6 > n 7 > , 8 > s -1->Emitted(31, 1) Source(35, 1) + SourceIndex(0) -2 >Emitted(31, 5) Source(35, 5) + SourceIndex(0) -3 >Emitted(31, 9) Source(35, 9) + SourceIndex(0) -4 >Emitted(31, 12) Source(35, 44) + SourceIndex(0) -5 >Emitted(31, 22) Source(35, 53) + SourceIndex(0) -6 >Emitted(31, 23) Source(35, 54) + SourceIndex(0) -7 >Emitted(31, 25) Source(35, 56) + SourceIndex(0) -8 >Emitted(31, 26) Source(35, 57) + SourceIndex(0) +9 > ) { +10> return +11> +12> ( +13> {} +14> ) +15> +16> +17> } +18> ; +1->Emitted(25, 1) Source(35, 1) + SourceIndex(0) +2 >Emitted(25, 5) Source(35, 5) + SourceIndex(0) +3 >Emitted(25, 9) Source(35, 9) + SourceIndex(0) +4 >Emitted(25, 12) Source(35, 44) + SourceIndex(0) +5 >Emitted(25, 22) Source(35, 53) + SourceIndex(0) +6 >Emitted(25, 23) Source(35, 54) + SourceIndex(0) +7 >Emitted(25, 25) Source(35, 56) + SourceIndex(0) +8 >Emitted(25, 26) Source(35, 57) + SourceIndex(0) +9 >Emitted(25, 30) Source(35, 61) + SourceIndex(0) +10>Emitted(25, 36) Source(35, 67) + SourceIndex(0) +11>Emitted(25, 37) Source(35, 74) + SourceIndex(0) +12>Emitted(25, 38) Source(35, 75) + SourceIndex(0) +13>Emitted(25, 40) Source(35, 77) + SourceIndex(0) +14>Emitted(25, 41) Source(35, 78) + SourceIndex(0) +15>Emitted(25, 42) Source(35, 78) + SourceIndex(0) +16>Emitted(25, 43) Source(35, 79) + SourceIndex(0) +17>Emitted(25, 44) Source(35, 80) + SourceIndex(0) +18>Emitted(25, 45) Source(35, 81) + SourceIndex(0) --- ->>> return ({}); -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(32, 5) Source(35, 61) + SourceIndex(0) -2 >Emitted(32, 11) Source(35, 67) + SourceIndex(0) -3 >Emitted(32, 12) Source(35, 74) + SourceIndex(0) -4 >Emitted(32, 13) Source(35, 75) + SourceIndex(0) -5 >Emitted(32, 15) Source(35, 77) + SourceIndex(0) -6 >Emitted(32, 16) Source(35, 78) + SourceIndex(0) -7 >Emitted(32, 17) Source(35, 78) + SourceIndex(0) ---- ->>>}; +>>>var c3t7 = function (n) { return n; }; 1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(33, 1) Source(35, 79) + SourceIndex(0) -2 >Emitted(33, 2) Source(35, 80) + SourceIndex(0) -3 >Emitted(33, 3) Source(35, 81) + SourceIndex(0) ---- ->>>var c3t7 = function (n) { -1-> 2 >^^^^ 3 > ^^^^ 4 > ^^^ 5 > ^^^^^^^^^^ 6 > ^ -1-> +7 > ^^^^ +8 > ^^^^^^ +9 > ^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^-> +1 > > 2 >var 3 > c3t7 @@ -576,49 +567,44 @@ sourceFile:contextualTyping.ts > } = 5 > function( 6 > n -1->Emitted(34, 1) Source(36, 1) + SourceIndex(0) -2 >Emitted(34, 5) Source(36, 5) + SourceIndex(0) -3 >Emitted(34, 9) Source(36, 9) + SourceIndex(0) -4 >Emitted(34, 12) Source(39, 5) + SourceIndex(0) -5 >Emitted(34, 22) Source(39, 14) + SourceIndex(0) -6 >Emitted(34, 23) Source(39, 15) + SourceIndex(0) +7 > ) { +8 > return +9 > +10> n +11> ; +12> +13> } +14> ; +1 >Emitted(26, 1) Source(36, 1) + SourceIndex(0) +2 >Emitted(26, 5) Source(36, 5) + SourceIndex(0) +3 >Emitted(26, 9) Source(36, 9) + SourceIndex(0) +4 >Emitted(26, 12) Source(39, 5) + SourceIndex(0) +5 >Emitted(26, 22) Source(39, 14) + SourceIndex(0) +6 >Emitted(26, 23) Source(39, 15) + SourceIndex(0) +7 >Emitted(26, 27) Source(39, 19) + SourceIndex(0) +8 >Emitted(26, 33) Source(39, 25) + SourceIndex(0) +9 >Emitted(26, 34) Source(39, 26) + SourceIndex(0) +10>Emitted(26, 35) Source(39, 27) + SourceIndex(0) +11>Emitted(26, 36) Source(39, 28) + SourceIndex(0) +12>Emitted(26, 37) Source(39, 29) + SourceIndex(0) +13>Emitted(26, 38) Source(39, 30) + SourceIndex(0) +14>Emitted(26, 39) Source(39, 31) + SourceIndex(0) --- ->>> return n; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > n -5 > ; -1 >Emitted(35, 5) Source(39, 19) + SourceIndex(0) -2 >Emitted(35, 11) Source(39, 25) + SourceIndex(0) -3 >Emitted(35, 12) Source(39, 26) + SourceIndex(0) -4 >Emitted(35, 13) Source(39, 27) + SourceIndex(0) -5 >Emitted(35, 14) Source(39, 28) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(36, 1) Source(39, 29) + SourceIndex(0) -2 >Emitted(36, 2) Source(39, 30) + SourceIndex(0) -3 >Emitted(36, 3) Source(39, 31) + SourceIndex(0) ---- ->>>var c3t8 = function (n) { +>>>var c3t8 = function (n) { return n; }; 1-> 2 >^^^^ 3 > ^^^^ 4 > ^^^ 5 > ^^^^^^^^^^ 6 > ^ +7 > ^^^^ +8 > ^^^^^^ +9 > ^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ 1-> > > @@ -627,218 +613,181 @@ sourceFile:contextualTyping.ts 4 > : (n: number, s: string) => number = 5 > function( 6 > n -1->Emitted(37, 1) Source(41, 1) + SourceIndex(0) -2 >Emitted(37, 5) Source(41, 5) + SourceIndex(0) -3 >Emitted(37, 9) Source(41, 9) + SourceIndex(0) -4 >Emitted(37, 12) Source(41, 46) + SourceIndex(0) -5 >Emitted(37, 22) Source(41, 55) + SourceIndex(0) -6 >Emitted(37, 23) Source(41, 56) + SourceIndex(0) +7 > ) { +8 > return +9 > +10> n +11> ; +12> +13> } +14> ; +1->Emitted(27, 1) Source(41, 1) + SourceIndex(0) +2 >Emitted(27, 5) Source(41, 5) + SourceIndex(0) +3 >Emitted(27, 9) Source(41, 9) + SourceIndex(0) +4 >Emitted(27, 12) Source(41, 46) + SourceIndex(0) +5 >Emitted(27, 22) Source(41, 55) + SourceIndex(0) +6 >Emitted(27, 23) Source(41, 56) + SourceIndex(0) +7 >Emitted(27, 27) Source(41, 60) + SourceIndex(0) +8 >Emitted(27, 33) Source(41, 66) + SourceIndex(0) +9 >Emitted(27, 34) Source(41, 67) + SourceIndex(0) +10>Emitted(27, 35) Source(41, 68) + SourceIndex(0) +11>Emitted(27, 36) Source(41, 69) + SourceIndex(0) +12>Emitted(27, 37) Source(41, 70) + SourceIndex(0) +13>Emitted(27, 38) Source(41, 71) + SourceIndex(0) +14>Emitted(27, 39) Source(41, 72) + SourceIndex(0) --- ->>> return n; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > n -5 > ; -1 >Emitted(38, 5) Source(41, 60) + SourceIndex(0) -2 >Emitted(38, 11) Source(41, 66) + SourceIndex(0) -3 >Emitted(38, 12) Source(41, 67) + SourceIndex(0) -4 >Emitted(38, 13) Source(41, 68) + SourceIndex(0) -5 >Emitted(38, 14) Source(41, 69) + SourceIndex(0) ---- ->>>}; +>>>var c3t9 = [[], []]; 1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(39, 1) Source(41, 70) + SourceIndex(0) -2 >Emitted(39, 2) Source(41, 71) + SourceIndex(0) -3 >Emitted(39, 3) Source(41, 72) + SourceIndex(0) ---- ->>>var c3t9 = [ -1-> 2 >^^^^ 3 > ^^^^ 4 > ^^^ -1-> +5 > ^ +6 > ^^ +7 > ^^ +8 > ^^ +9 > ^ +10> ^ +11> ^^^^^^-> +1 > > 2 >var 3 > c3t9 4 > : number[][] = -1->Emitted(40, 1) Source(42, 1) + SourceIndex(0) -2 >Emitted(40, 5) Source(42, 5) + SourceIndex(0) -3 >Emitted(40, 9) Source(42, 9) + SourceIndex(0) -4 >Emitted(40, 12) Source(42, 24) + SourceIndex(0) +5 > [ +6 > [] +7 > , +8 > [] +9 > ] +10> ; +1 >Emitted(28, 1) Source(42, 1) + SourceIndex(0) +2 >Emitted(28, 5) Source(42, 5) + SourceIndex(0) +3 >Emitted(28, 9) Source(42, 9) + SourceIndex(0) +4 >Emitted(28, 12) Source(42, 24) + SourceIndex(0) +5 >Emitted(28, 13) Source(42, 25) + SourceIndex(0) +6 >Emitted(28, 15) Source(42, 27) + SourceIndex(0) +7 >Emitted(28, 17) Source(42, 28) + SourceIndex(0) +8 >Emitted(28, 19) Source(42, 30) + SourceIndex(0) +9 >Emitted(28, 20) Source(42, 31) + SourceIndex(0) +10>Emitted(28, 21) Source(42, 32) + SourceIndex(0) --- ->>> [], -1 >^^^^ -2 > ^^ -3 > ^-> -1 >[ -2 > [] -1 >Emitted(41, 5) Source(42, 25) + SourceIndex(0) -2 >Emitted(41, 7) Source(42, 27) + SourceIndex(0) ---- ->>> [] -1->^^^^ -2 > ^^ -1->, -2 > [] -1->Emitted(42, 5) Source(42, 28) + SourceIndex(0) -2 >Emitted(42, 7) Source(42, 30) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(43, 2) Source(42, 31) + SourceIndex(0) -2 >Emitted(43, 3) Source(42, 32) + SourceIndex(0) ---- ->>>var c3t10 = [ +>>>var c3t10 = [({}), ({})]; 1-> 2 >^^^^ 3 > ^^^^^ 4 > ^^^ +5 > ^ +6 > ^ +7 > ^^ +8 > ^ +9 > ^^ +10> ^ +11> ^^ +12> ^ +13> ^ +14> ^ +15> ^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >var 3 > c3t10 4 > : IFoo[] = -1->Emitted(44, 1) Source(43, 1) + SourceIndex(0) -2 >Emitted(44, 5) Source(43, 5) + SourceIndex(0) -3 >Emitted(44, 10) Source(43, 10) + SourceIndex(0) -4 >Emitted(44, 13) Source(43, 21) + SourceIndex(0) +5 > [ +6 > ( +7 > {} +8 > ) +9 > , +10> ( +11> {} +12> ) +13> ] +14> ; +1->Emitted(29, 1) Source(43, 1) + SourceIndex(0) +2 >Emitted(29, 5) Source(43, 5) + SourceIndex(0) +3 >Emitted(29, 10) Source(43, 10) + SourceIndex(0) +4 >Emitted(29, 13) Source(43, 21) + SourceIndex(0) +5 >Emitted(29, 14) Source(43, 28) + SourceIndex(0) +6 >Emitted(29, 15) Source(43, 29) + SourceIndex(0) +7 >Emitted(29, 17) Source(43, 31) + SourceIndex(0) +8 >Emitted(29, 18) Source(43, 32) + SourceIndex(0) +9 >Emitted(29, 20) Source(43, 39) + SourceIndex(0) +10>Emitted(29, 21) Source(43, 40) + SourceIndex(0) +11>Emitted(29, 23) Source(43, 42) + SourceIndex(0) +12>Emitted(29, 24) Source(43, 43) + SourceIndex(0) +13>Emitted(29, 25) Source(43, 44) + SourceIndex(0) +14>Emitted(29, 26) Source(43, 45) + SourceIndex(0) --- ->>> ({}), -1 >^^^^ -2 > ^ -3 > ^^ -4 > ^ -5 > ^-> -1 >[ -2 > ( -3 > {} -4 > ) -1 >Emitted(45, 5) Source(43, 28) + SourceIndex(0) -2 >Emitted(45, 6) Source(43, 29) + SourceIndex(0) -3 >Emitted(45, 8) Source(43, 31) + SourceIndex(0) -4 >Emitted(45, 9) Source(43, 32) + SourceIndex(0) ---- ->>> ({}) -1->^^^^ -2 > ^ -3 > ^^ -4 > ^ -1->, -2 > ( -3 > {} -4 > ) -1->Emitted(46, 5) Source(43, 39) + SourceIndex(0) -2 >Emitted(46, 6) Source(43, 40) + SourceIndex(0) -3 >Emitted(46, 8) Source(43, 42) + SourceIndex(0) -4 >Emitted(46, 9) Source(43, 43) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(47, 2) Source(43, 44) + SourceIndex(0) -2 >Emitted(47, 3) Source(43, 45) + SourceIndex(0) ---- ->>>var c3t11 = [ +>>>var c3t11 = [function (n, s) { return s; }]; 1-> 2 >^^^^ 3 > ^^^^^ 4 > ^^^ -5 > ^^^^^^^^^^-> +5 > ^ +6 > ^^^^^^^^^^ +7 > ^ +8 > ^^ +9 > ^ +10> ^^^^ +11> ^^^^^^ +12> ^ +13> ^ +14> ^ +15> ^ +16> ^ +17> ^ +18> ^ 1-> > 2 >var 3 > c3t11 4 > : {(n: number, s: string): string;}[] = -1->Emitted(48, 1) Source(44, 1) + SourceIndex(0) -2 >Emitted(48, 5) Source(44, 5) + SourceIndex(0) -3 >Emitted(48, 10) Source(44, 10) + SourceIndex(0) -4 >Emitted(48, 13) Source(44, 50) + SourceIndex(0) ---- ->>> function (n, s) { -1->^^^^ -2 > ^^^^^^^^^^ -3 > ^ -4 > ^^ -5 > ^ -1->[ -2 > function( -3 > n -4 > , -5 > s -1->Emitted(49, 5) Source(44, 51) + SourceIndex(0) -2 >Emitted(49, 15) Source(44, 60) + SourceIndex(0) -3 >Emitted(49, 16) Source(44, 61) + SourceIndex(0) -4 >Emitted(49, 18) Source(44, 63) + SourceIndex(0) -5 >Emitted(49, 19) Source(44, 64) + SourceIndex(0) ---- ->>> return s; -1 >^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > ; -1 >Emitted(50, 9) Source(44, 68) + SourceIndex(0) -2 >Emitted(50, 15) Source(44, 74) + SourceIndex(0) -3 >Emitted(50, 16) Source(44, 75) + SourceIndex(0) -4 >Emitted(50, 17) Source(44, 76) + SourceIndex(0) -5 >Emitted(50, 18) Source(44, 77) + SourceIndex(0) ---- ->>> } -1 >^^^^ -2 > ^ -1 > -2 > } -1 >Emitted(51, 5) Source(44, 78) + SourceIndex(0) -2 >Emitted(51, 6) Source(44, 79) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(52, 2) Source(44, 80) + SourceIndex(0) -2 >Emitted(52, 3) Source(44, 81) + SourceIndex(0) +5 > [ +6 > function( +7 > n +8 > , +9 > s +10> ) { +11> return +12> +13> s +14> ; +15> +16> } +17> ] +18> ; +1->Emitted(30, 1) Source(44, 1) + SourceIndex(0) +2 >Emitted(30, 5) Source(44, 5) + SourceIndex(0) +3 >Emitted(30, 10) Source(44, 10) + SourceIndex(0) +4 >Emitted(30, 13) Source(44, 50) + SourceIndex(0) +5 >Emitted(30, 14) Source(44, 51) + SourceIndex(0) +6 >Emitted(30, 24) Source(44, 60) + SourceIndex(0) +7 >Emitted(30, 25) Source(44, 61) + SourceIndex(0) +8 >Emitted(30, 27) Source(44, 63) + SourceIndex(0) +9 >Emitted(30, 28) Source(44, 64) + SourceIndex(0) +10>Emitted(30, 32) Source(44, 68) + SourceIndex(0) +11>Emitted(30, 38) Source(44, 74) + SourceIndex(0) +12>Emitted(30, 39) Source(44, 75) + SourceIndex(0) +13>Emitted(30, 40) Source(44, 76) + SourceIndex(0) +14>Emitted(30, 41) Source(44, 77) + SourceIndex(0) +15>Emitted(30, 42) Source(44, 78) + SourceIndex(0) +16>Emitted(30, 43) Source(44, 79) + SourceIndex(0) +17>Emitted(30, 44) Source(44, 80) + SourceIndex(0) +18>Emitted(30, 45) Source(44, 81) + SourceIndex(0) --- >>>var c3t12 = { -1-> +1 > 2 >^^^^ 3 > ^^^^^ 4 > ^^^ 5 > ^^-> -1-> +1 > > 2 >var 3 > c3t12 4 > : IBar = -1->Emitted(53, 1) Source(45, 1) + SourceIndex(0) -2 >Emitted(53, 5) Source(45, 5) + SourceIndex(0) -3 >Emitted(53, 10) Source(45, 10) + SourceIndex(0) -4 >Emitted(53, 13) Source(45, 19) + SourceIndex(0) +1 >Emitted(31, 1) Source(45, 1) + SourceIndex(0) +2 >Emitted(31, 5) Source(45, 5) + SourceIndex(0) +3 >Emitted(31, 10) Source(45, 10) + SourceIndex(0) +4 >Emitted(31, 13) Source(45, 19) + SourceIndex(0) --- >>> foo: ({}) 1->^^^^ @@ -854,12 +803,12 @@ sourceFile:contextualTyping.ts 4 > ( 5 > {} 6 > ) -1->Emitted(54, 5) Source(46, 5) + SourceIndex(0) -2 >Emitted(54, 8) Source(46, 8) + SourceIndex(0) -3 >Emitted(54, 10) Source(46, 16) + SourceIndex(0) -4 >Emitted(54, 11) Source(46, 17) + SourceIndex(0) -5 >Emitted(54, 13) Source(46, 19) + SourceIndex(0) -6 >Emitted(54, 14) Source(46, 20) + SourceIndex(0) +1->Emitted(32, 5) Source(46, 5) + SourceIndex(0) +2 >Emitted(32, 8) Source(46, 8) + SourceIndex(0) +3 >Emitted(32, 10) Source(46, 16) + SourceIndex(0) +4 >Emitted(32, 11) Source(46, 17) + SourceIndex(0) +5 >Emitted(32, 13) Source(46, 19) + SourceIndex(0) +6 >Emitted(32, 14) Source(46, 20) + SourceIndex(0) --- >>>}; 1 >^ @@ -868,8 +817,8 @@ sourceFile:contextualTyping.ts 1 > >} 2 > -1 >Emitted(55, 2) Source(47, 2) + SourceIndex(0) -2 >Emitted(55, 3) Source(47, 2) + SourceIndex(0) +1 >Emitted(33, 2) Source(47, 2) + SourceIndex(0) +2 >Emitted(33, 3) Source(47, 2) + SourceIndex(0) --- >>>var c3t13 = ({ 1-> @@ -877,20 +826,20 @@ sourceFile:contextualTyping.ts 3 > ^^^^^ 4 > ^^^ 5 > ^ -6 > ^^^^^^^^^^^^-> +6 > ^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >var 3 > c3t13 4 > = 5 > ( -1->Emitted(56, 1) Source(48, 1) + SourceIndex(0) -2 >Emitted(56, 5) Source(48, 5) + SourceIndex(0) -3 >Emitted(56, 10) Source(48, 10) + SourceIndex(0) -4 >Emitted(56, 13) Source(48, 19) + SourceIndex(0) -5 >Emitted(56, 14) Source(48, 20) + SourceIndex(0) +1->Emitted(34, 1) Source(48, 1) + SourceIndex(0) +2 >Emitted(34, 5) Source(48, 5) + SourceIndex(0) +3 >Emitted(34, 10) Source(48, 10) + SourceIndex(0) +4 >Emitted(34, 13) Source(48, 19) + SourceIndex(0) +5 >Emitted(34, 14) Source(48, 20) + SourceIndex(0) --- ->>> f: function (i, s) { +>>> f: function (i, s) { return s; } 1->^^^^ 2 > ^ 3 > ^^ @@ -898,6 +847,13 @@ sourceFile:contextualTyping.ts 5 > ^ 6 > ^^ 7 > ^ +8 > ^^^^ +9 > ^^^^^^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ 1->{ > 2 > f @@ -906,38 +862,27 @@ sourceFile:contextualTyping.ts 5 > i 6 > , 7 > s -1->Emitted(57, 5) Source(49, 5) + SourceIndex(0) -2 >Emitted(57, 6) Source(49, 6) + SourceIndex(0) -3 >Emitted(57, 8) Source(49, 8) + SourceIndex(0) -4 >Emitted(57, 18) Source(49, 17) + SourceIndex(0) -5 >Emitted(57, 19) Source(49, 18) + SourceIndex(0) -6 >Emitted(57, 21) Source(49, 20) + SourceIndex(0) -7 >Emitted(57, 22) Source(49, 21) + SourceIndex(0) ---- ->>> return s; -1 >^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > ; -1 >Emitted(58, 9) Source(49, 25) + SourceIndex(0) -2 >Emitted(58, 15) Source(49, 31) + SourceIndex(0) -3 >Emitted(58, 16) Source(49, 32) + SourceIndex(0) -4 >Emitted(58, 17) Source(49, 33) + SourceIndex(0) -5 >Emitted(58, 18) Source(49, 34) + SourceIndex(0) ---- ->>> } -1 >^^^^ -2 > ^ -1 > -2 > } -1 >Emitted(59, 5) Source(49, 35) + SourceIndex(0) -2 >Emitted(59, 6) Source(49, 36) + SourceIndex(0) +8 > ) { +9 > return +10> +11> s +12> ; +13> +14> } +1->Emitted(35, 5) Source(49, 5) + SourceIndex(0) +2 >Emitted(35, 6) Source(49, 6) + SourceIndex(0) +3 >Emitted(35, 8) Source(49, 8) + SourceIndex(0) +4 >Emitted(35, 18) Source(49, 17) + SourceIndex(0) +5 >Emitted(35, 19) Source(49, 18) + SourceIndex(0) +6 >Emitted(35, 21) Source(49, 20) + SourceIndex(0) +7 >Emitted(35, 22) Source(49, 21) + SourceIndex(0) +8 >Emitted(35, 26) Source(49, 25) + SourceIndex(0) +9 >Emitted(35, 32) Source(49, 31) + SourceIndex(0) +10>Emitted(35, 33) Source(49, 32) + SourceIndex(0) +11>Emitted(35, 34) Source(49, 33) + SourceIndex(0) +12>Emitted(35, 35) Source(49, 34) + SourceIndex(0) +13>Emitted(35, 36) Source(49, 35) + SourceIndex(0) +14>Emitted(35, 37) Source(49, 36) + SourceIndex(0) --- >>>}); 1 >^ @@ -948,9 +893,9 @@ sourceFile:contextualTyping.ts >} 2 > ) 3 > -1 >Emitted(60, 2) Source(50, 2) + SourceIndex(0) -2 >Emitted(60, 3) Source(50, 3) + SourceIndex(0) -3 >Emitted(60, 4) Source(50, 3) + SourceIndex(0) +1 >Emitted(36, 2) Source(50, 2) + SourceIndex(0) +2 >Emitted(36, 3) Source(50, 3) + SourceIndex(0) +3 >Emitted(36, 4) Source(50, 3) + SourceIndex(0) --- >>>var c3t14 = ({ 1-> @@ -964,11 +909,11 @@ sourceFile:contextualTyping.ts 3 > c3t14 4 > = 5 > ( -1->Emitted(61, 1) Source(51, 1) + SourceIndex(0) -2 >Emitted(61, 5) Source(51, 5) + SourceIndex(0) -3 >Emitted(61, 10) Source(51, 10) + SourceIndex(0) -4 >Emitted(61, 13) Source(51, 19) + SourceIndex(0) -5 >Emitted(61, 14) Source(51, 20) + SourceIndex(0) +1->Emitted(37, 1) Source(51, 1) + SourceIndex(0) +2 >Emitted(37, 5) Source(51, 5) + SourceIndex(0) +3 >Emitted(37, 10) Source(51, 10) + SourceIndex(0) +4 >Emitted(37, 13) Source(51, 19) + SourceIndex(0) +5 >Emitted(37, 14) Source(51, 20) + SourceIndex(0) --- >>> a: [] 1 >^^^^ @@ -980,10 +925,10 @@ sourceFile:contextualTyping.ts 2 > a 3 > : 4 > [] -1 >Emitted(62, 5) Source(52, 5) + SourceIndex(0) -2 >Emitted(62, 6) Source(52, 6) + SourceIndex(0) -3 >Emitted(62, 8) Source(52, 8) + SourceIndex(0) -4 >Emitted(62, 10) Source(52, 10) + SourceIndex(0) +1 >Emitted(38, 5) Source(52, 5) + SourceIndex(0) +2 >Emitted(38, 6) Source(52, 6) + SourceIndex(0) +3 >Emitted(38, 8) Source(52, 8) + SourceIndex(0) +4 >Emitted(38, 10) Source(52, 10) + SourceIndex(0) --- >>>}); 1 >^ @@ -994,9 +939,9 @@ sourceFile:contextualTyping.ts >} 2 > ) 3 > -1 >Emitted(63, 2) Source(53, 2) + SourceIndex(0) -2 >Emitted(63, 3) Source(53, 3) + SourceIndex(0) -3 >Emitted(63, 4) Source(53, 3) + SourceIndex(0) +1 >Emitted(39, 2) Source(53, 2) + SourceIndex(0) +2 >Emitted(39, 3) Source(53, 3) + SourceIndex(0) +3 >Emitted(39, 4) Source(53, 3) + SourceIndex(0) --- >>>// CONTEXT: Class property assignment 1-> @@ -1008,9 +953,9 @@ sourceFile:contextualTyping.ts > 2 > 3 >// CONTEXT: Class property assignment -1->Emitted(64, 1) Source(56, 1) + SourceIndex(0) -2 >Emitted(64, 1) Source(55, 1) + SourceIndex(0) -3 >Emitted(64, 38) Source(55, 38) + SourceIndex(0) +1->Emitted(40, 1) Source(56, 1) + SourceIndex(0) +2 >Emitted(40, 1) Source(55, 1) + SourceIndex(0) +3 >Emitted(40, 38) Source(55, 38) + SourceIndex(0) --- >>>var C4T5 = (function () { >>> function C4T5() { @@ -1020,7 +965,7 @@ sourceFile:contextualTyping.ts >class C4T5 { > foo: (i: number, s: string) => string; > -1 >Emitted(66, 5) Source(58, 5) + SourceIndex(0) name (C4T5) +1 >Emitted(42, 5) Source(58, 5) + SourceIndex(0) name (C4T5) --- >>> this.foo = function (i, s) { 1->^^^^^^^^ @@ -1042,15 +987,15 @@ sourceFile:contextualTyping.ts 7 > i 8 > , 9 > s -1->Emitted(67, 9) Source(59, 9) + SourceIndex(0) name (C4T5.constructor) -2 >Emitted(67, 13) Source(59, 13) + SourceIndex(0) name (C4T5.constructor) -3 >Emitted(67, 14) Source(59, 14) + SourceIndex(0) name (C4T5.constructor) -4 >Emitted(67, 17) Source(59, 17) + SourceIndex(0) name (C4T5.constructor) -5 >Emitted(67, 20) Source(59, 20) + SourceIndex(0) name (C4T5.constructor) -6 >Emitted(67, 30) Source(59, 29) + SourceIndex(0) name (C4T5.constructor) -7 >Emitted(67, 31) Source(59, 30) + SourceIndex(0) name (C4T5.constructor) -8 >Emitted(67, 33) Source(59, 32) + SourceIndex(0) name (C4T5.constructor) -9 >Emitted(67, 34) Source(59, 33) + SourceIndex(0) name (C4T5.constructor) +1->Emitted(43, 9) Source(59, 9) + SourceIndex(0) name (C4T5.constructor) +2 >Emitted(43, 13) Source(59, 13) + SourceIndex(0) name (C4T5.constructor) +3 >Emitted(43, 14) Source(59, 14) + SourceIndex(0) name (C4T5.constructor) +4 >Emitted(43, 17) Source(59, 17) + SourceIndex(0) name (C4T5.constructor) +5 >Emitted(43, 20) Source(59, 20) + SourceIndex(0) name (C4T5.constructor) +6 >Emitted(43, 30) Source(59, 29) + SourceIndex(0) name (C4T5.constructor) +7 >Emitted(43, 31) Source(59, 30) + SourceIndex(0) name (C4T5.constructor) +8 >Emitted(43, 33) Source(59, 32) + SourceIndex(0) name (C4T5.constructor) +9 >Emitted(43, 34) Source(59, 33) + SourceIndex(0) name (C4T5.constructor) --- >>> return s; 1 >^^^^^^^^^^^^ @@ -1064,11 +1009,11 @@ sourceFile:contextualTyping.ts 3 > 4 > s 5 > ; -1 >Emitted(68, 13) Source(60, 13) + SourceIndex(0) -2 >Emitted(68, 19) Source(60, 19) + SourceIndex(0) -3 >Emitted(68, 20) Source(60, 20) + SourceIndex(0) -4 >Emitted(68, 21) Source(60, 21) + SourceIndex(0) -5 >Emitted(68, 22) Source(60, 22) + SourceIndex(0) +1 >Emitted(44, 13) Source(60, 13) + SourceIndex(0) +2 >Emitted(44, 19) Source(60, 19) + SourceIndex(0) +3 >Emitted(44, 20) Source(60, 20) + SourceIndex(0) +4 >Emitted(44, 21) Source(60, 21) + SourceIndex(0) +5 >Emitted(44, 22) Source(60, 22) + SourceIndex(0) --- >>> }; 1 >^^^^^^^^ @@ -1078,9 +1023,9 @@ sourceFile:contextualTyping.ts > 2 > } 3 > -1 >Emitted(69, 9) Source(61, 9) + SourceIndex(0) -2 >Emitted(69, 10) Source(61, 10) + SourceIndex(0) -3 >Emitted(69, 11) Source(61, 10) + SourceIndex(0) name (C4T5.constructor) +1 >Emitted(45, 9) Source(61, 9) + SourceIndex(0) +2 >Emitted(45, 10) Source(61, 10) + SourceIndex(0) +3 >Emitted(45, 11) Source(61, 10) + SourceIndex(0) name (C4T5.constructor) --- >>> } 1 >^^^^ @@ -1089,8 +1034,8 @@ sourceFile:contextualTyping.ts 1 > > 2 > } -1 >Emitted(70, 5) Source(62, 5) + SourceIndex(0) name (C4T5.constructor) -2 >Emitted(70, 6) Source(62, 6) + SourceIndex(0) name (C4T5.constructor) +1 >Emitted(46, 5) Source(62, 5) + SourceIndex(0) name (C4T5.constructor) +2 >Emitted(46, 6) Source(62, 6) + SourceIndex(0) name (C4T5.constructor) --- >>> return C4T5; 1->^^^^ @@ -1098,8 +1043,8 @@ sourceFile:contextualTyping.ts 1-> > 2 > } -1->Emitted(71, 5) Source(63, 1) + SourceIndex(0) name (C4T5) -2 >Emitted(71, 16) Source(63, 2) + SourceIndex(0) name (C4T5) +1->Emitted(47, 5) Source(63, 1) + SourceIndex(0) name (C4T5) +2 >Emitted(47, 16) Source(63, 2) + SourceIndex(0) name (C4T5) --- >>>})(); 1 > @@ -1118,10 +1063,10 @@ sourceFile:contextualTyping.ts > } > } > } -1 >Emitted(72, 1) Source(63, 1) + SourceIndex(0) name (C4T5) -2 >Emitted(72, 2) Source(63, 2) + SourceIndex(0) name (C4T5) -3 >Emitted(72, 2) Source(56, 1) + SourceIndex(0) -4 >Emitted(72, 6) Source(63, 2) + SourceIndex(0) +1 >Emitted(48, 1) Source(63, 1) + SourceIndex(0) name (C4T5) +2 >Emitted(48, 2) Source(63, 2) + SourceIndex(0) name (C4T5) +3 >Emitted(48, 2) Source(56, 1) + SourceIndex(0) +4 >Emitted(48, 6) Source(63, 2) + SourceIndex(0) --- >>>// CONTEXT: Module property assignment 1-> @@ -1133,9 +1078,9 @@ sourceFile:contextualTyping.ts > 2 > 3 >// CONTEXT: Module property assignment -1->Emitted(73, 1) Source(66, 1) + SourceIndex(0) -2 >Emitted(73, 1) Source(65, 1) + SourceIndex(0) -3 >Emitted(73, 39) Source(65, 39) + SourceIndex(0) +1->Emitted(49, 1) Source(66, 1) + SourceIndex(0) +2 >Emitted(49, 1) Source(65, 1) + SourceIndex(0) +3 >Emitted(49, 39) Source(65, 39) + SourceIndex(0) --- >>>var C5T5; 1 > @@ -1153,10 +1098,10 @@ sourceFile:contextualTyping.ts > return s; > } > } -1 >Emitted(74, 1) Source(66, 1) + SourceIndex(0) -2 >Emitted(74, 5) Source(66, 8) + SourceIndex(0) -3 >Emitted(74, 9) Source(66, 12) + SourceIndex(0) -4 >Emitted(74, 10) Source(71, 2) + SourceIndex(0) +1 >Emitted(50, 1) Source(66, 1) + SourceIndex(0) +2 >Emitted(50, 5) Source(66, 8) + SourceIndex(0) +3 >Emitted(50, 9) Source(66, 12) + SourceIndex(0) +4 >Emitted(50, 10) Source(71, 2) + SourceIndex(0) --- >>>(function (C5T5) { 1-> @@ -1169,11 +1114,11 @@ sourceFile:contextualTyping.ts 3 > C5T5 4 > 5 > { -1->Emitted(75, 1) Source(66, 1) + SourceIndex(0) -2 >Emitted(75, 12) Source(66, 8) + SourceIndex(0) -3 >Emitted(75, 16) Source(66, 12) + SourceIndex(0) -4 >Emitted(75, 18) Source(66, 13) + SourceIndex(0) -5 >Emitted(75, 19) Source(66, 14) + SourceIndex(0) +1->Emitted(51, 1) Source(66, 1) + SourceIndex(0) +2 >Emitted(51, 12) Source(66, 8) + SourceIndex(0) +3 >Emitted(51, 16) Source(66, 12) + SourceIndex(0) +4 >Emitted(51, 18) Source(66, 13) + SourceIndex(0) +5 >Emitted(51, 19) Source(66, 14) + SourceIndex(0) --- >>> C5T5.foo; 1 >^^^^ @@ -1184,9 +1129,9 @@ sourceFile:contextualTyping.ts > export var 2 > foo: (i: number, s: string) => string 3 > ; -1 >Emitted(76, 5) Source(67, 16) + SourceIndex(0) name (C5T5) -2 >Emitted(76, 13) Source(67, 53) + SourceIndex(0) name (C5T5) -3 >Emitted(76, 14) Source(67, 54) + SourceIndex(0) name (C5T5) +1 >Emitted(52, 5) Source(67, 16) + SourceIndex(0) name (C5T5) +2 >Emitted(52, 13) Source(67, 53) + SourceIndex(0) name (C5T5) +3 >Emitted(52, 14) Source(67, 54) + SourceIndex(0) name (C5T5) --- >>> C5T5.foo = function (i, s) { 1->^^^^ @@ -1204,13 +1149,13 @@ sourceFile:contextualTyping.ts 5 > i 6 > , 7 > s -1->Emitted(77, 5) Source(68, 5) + SourceIndex(0) name (C5T5) -2 >Emitted(77, 13) Source(68, 8) + SourceIndex(0) name (C5T5) -3 >Emitted(77, 16) Source(68, 11) + SourceIndex(0) name (C5T5) -4 >Emitted(77, 26) Source(68, 20) + SourceIndex(0) name (C5T5) -5 >Emitted(77, 27) Source(68, 21) + SourceIndex(0) name (C5T5) -6 >Emitted(77, 29) Source(68, 23) + SourceIndex(0) name (C5T5) -7 >Emitted(77, 30) Source(68, 24) + SourceIndex(0) name (C5T5) +1->Emitted(53, 5) Source(68, 5) + SourceIndex(0) name (C5T5) +2 >Emitted(53, 13) Source(68, 8) + SourceIndex(0) name (C5T5) +3 >Emitted(53, 16) Source(68, 11) + SourceIndex(0) name (C5T5) +4 >Emitted(53, 26) Source(68, 20) + SourceIndex(0) name (C5T5) +5 >Emitted(53, 27) Source(68, 21) + SourceIndex(0) name (C5T5) +6 >Emitted(53, 29) Source(68, 23) + SourceIndex(0) name (C5T5) +7 >Emitted(53, 30) Source(68, 24) + SourceIndex(0) name (C5T5) --- >>> return s; 1 >^^^^^^^^ @@ -1224,11 +1169,11 @@ sourceFile:contextualTyping.ts 3 > 4 > s 5 > ; -1 >Emitted(78, 9) Source(69, 9) + SourceIndex(0) -2 >Emitted(78, 15) Source(69, 15) + SourceIndex(0) -3 >Emitted(78, 16) Source(69, 16) + SourceIndex(0) -4 >Emitted(78, 17) Source(69, 17) + SourceIndex(0) -5 >Emitted(78, 18) Source(69, 18) + SourceIndex(0) +1 >Emitted(54, 9) Source(69, 9) + SourceIndex(0) +2 >Emitted(54, 15) Source(69, 15) + SourceIndex(0) +3 >Emitted(54, 16) Source(69, 16) + SourceIndex(0) +4 >Emitted(54, 17) Source(69, 17) + SourceIndex(0) +5 >Emitted(54, 18) Source(69, 18) + SourceIndex(0) --- >>> }; 1 >^^^^ @@ -1239,9 +1184,9 @@ sourceFile:contextualTyping.ts > 2 > } 3 > -1 >Emitted(79, 5) Source(70, 5) + SourceIndex(0) -2 >Emitted(79, 6) Source(70, 6) + SourceIndex(0) -3 >Emitted(79, 7) Source(70, 6) + SourceIndex(0) name (C5T5) +1 >Emitted(55, 5) Source(70, 5) + SourceIndex(0) +2 >Emitted(55, 6) Source(70, 6) + SourceIndex(0) +3 >Emitted(55, 7) Source(70, 6) + SourceIndex(0) name (C5T5) --- >>>})(C5T5 || (C5T5 = {})); 1-> @@ -1265,13 +1210,13 @@ sourceFile:contextualTyping.ts > return s; > } > } -1->Emitted(80, 1) Source(71, 1) + SourceIndex(0) name (C5T5) -2 >Emitted(80, 2) Source(71, 2) + SourceIndex(0) name (C5T5) -3 >Emitted(80, 4) Source(66, 8) + SourceIndex(0) -4 >Emitted(80, 8) Source(66, 12) + SourceIndex(0) -5 >Emitted(80, 13) Source(66, 8) + SourceIndex(0) -6 >Emitted(80, 17) Source(66, 12) + SourceIndex(0) -7 >Emitted(80, 25) Source(71, 2) + SourceIndex(0) +1->Emitted(56, 1) Source(71, 1) + SourceIndex(0) name (C5T5) +2 >Emitted(56, 2) Source(71, 2) + SourceIndex(0) name (C5T5) +3 >Emitted(56, 4) Source(66, 8) + SourceIndex(0) +4 >Emitted(56, 8) Source(66, 12) + SourceIndex(0) +5 >Emitted(56, 13) Source(66, 8) + SourceIndex(0) +6 >Emitted(56, 17) Source(66, 12) + SourceIndex(0) +7 >Emitted(56, 25) Source(71, 2) + SourceIndex(0) --- >>>// CONTEXT: Variable assignment 1-> @@ -1283,104 +1228,99 @@ sourceFile:contextualTyping.ts > 2 > 3 >// CONTEXT: Variable assignment -1->Emitted(81, 1) Source(74, 1) + SourceIndex(0) -2 >Emitted(81, 1) Source(73, 1) + SourceIndex(0) -3 >Emitted(81, 32) Source(73, 32) + SourceIndex(0) +1->Emitted(57, 1) Source(74, 1) + SourceIndex(0) +2 >Emitted(57, 1) Source(73, 1) + SourceIndex(0) +3 >Emitted(57, 32) Source(73, 32) + SourceIndex(0) --- >>>var c6t5; 1 >^^^^ 2 > ^^^^ 3 > ^ -4 > ^^^^^^^^^^^^^-> +4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > >var 2 > c6t5: (n: number) => IFoo 3 > ; -1 >Emitted(82, 5) Source(74, 5) + SourceIndex(0) -2 >Emitted(82, 9) Source(74, 30) + SourceIndex(0) -3 >Emitted(82, 10) Source(74, 31) + SourceIndex(0) +1 >Emitted(58, 5) Source(74, 5) + SourceIndex(0) +2 >Emitted(58, 9) Source(74, 30) + SourceIndex(0) +3 >Emitted(58, 10) Source(74, 31) + SourceIndex(0) --- ->>>c6t5 = function (n) { +>>>c6t5 = function (n) { return ({}); }; 1-> 2 >^^^^ 3 > ^^^ 4 > ^^^^^^^^^^ 5 > ^ +6 > ^^^^ +7 > ^^^^^^ +8 > ^ +9 > ^ +10> ^^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^ 1-> > 2 >c6t5 3 > = <(n: number) => IFoo> 4 > function( 5 > n -1->Emitted(83, 1) Source(75, 1) + SourceIndex(0) -2 >Emitted(83, 5) Source(75, 5) + SourceIndex(0) -3 >Emitted(83, 8) Source(75, 29) + SourceIndex(0) -4 >Emitted(83, 18) Source(75, 38) + SourceIndex(0) -5 >Emitted(83, 19) Source(75, 39) + SourceIndex(0) ---- ->>> return ({}); -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(84, 5) Source(75, 43) + SourceIndex(0) -2 >Emitted(84, 11) Source(75, 49) + SourceIndex(0) -3 >Emitted(84, 12) Source(75, 56) + SourceIndex(0) -4 >Emitted(84, 13) Source(75, 57) + SourceIndex(0) -5 >Emitted(84, 15) Source(75, 59) + SourceIndex(0) -6 >Emitted(84, 16) Source(75, 60) + SourceIndex(0) -7 >Emitted(84, 17) Source(75, 60) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(85, 1) Source(75, 61) + SourceIndex(0) -2 >Emitted(85, 2) Source(75, 62) + SourceIndex(0) -3 >Emitted(85, 3) Source(75, 63) + SourceIndex(0) +6 > ) { +7 > return +8 > +9 > ( +10> {} +11> ) +12> +13> +14> } +15> ; +1->Emitted(59, 1) Source(75, 1) + SourceIndex(0) +2 >Emitted(59, 5) Source(75, 5) + SourceIndex(0) +3 >Emitted(59, 8) Source(75, 29) + SourceIndex(0) +4 >Emitted(59, 18) Source(75, 38) + SourceIndex(0) +5 >Emitted(59, 19) Source(75, 39) + SourceIndex(0) +6 >Emitted(59, 23) Source(75, 43) + SourceIndex(0) +7 >Emitted(59, 29) Source(75, 49) + SourceIndex(0) +8 >Emitted(59, 30) Source(75, 56) + SourceIndex(0) +9 >Emitted(59, 31) Source(75, 57) + SourceIndex(0) +10>Emitted(59, 33) Source(75, 59) + SourceIndex(0) +11>Emitted(59, 34) Source(75, 60) + SourceIndex(0) +12>Emitted(59, 35) Source(75, 60) + SourceIndex(0) +13>Emitted(59, 36) Source(75, 61) + SourceIndex(0) +14>Emitted(59, 37) Source(75, 62) + SourceIndex(0) +15>Emitted(59, 38) Source(75, 63) + SourceIndex(0) --- >>>// CONTEXT: Array index assignment -1-> +1 > 2 > 3 >^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -1-> +1 > > >// CONTEXT: Array index assignment > 2 > 3 >// CONTEXT: Array index assignment -1->Emitted(86, 1) Source(78, 1) + SourceIndex(0) -2 >Emitted(86, 1) Source(77, 1) + SourceIndex(0) -3 >Emitted(86, 35) Source(77, 35) + SourceIndex(0) +1 >Emitted(60, 1) Source(78, 1) + SourceIndex(0) +2 >Emitted(60, 1) Source(77, 1) + SourceIndex(0) +3 >Emitted(60, 35) Source(77, 35) + SourceIndex(0) --- >>>var c7t2; 1 >^^^^ 2 > ^^^^ 3 > ^ -4 > ^^^^-> +4 > ^^^^^^^^^^^^^-> 1 > >var 2 > c7t2: IFoo[] 3 > ; -1 >Emitted(87, 5) Source(78, 5) + SourceIndex(0) -2 >Emitted(87, 9) Source(78, 17) + SourceIndex(0) -3 >Emitted(87, 10) Source(78, 18) + SourceIndex(0) +1 >Emitted(61, 5) Source(78, 5) + SourceIndex(0) +2 >Emitted(61, 9) Source(78, 17) + SourceIndex(0) +3 >Emitted(61, 10) Source(78, 18) + SourceIndex(0) --- ->>>c7t2[0] = ({ +>>>c7t2[0] = ({ n: 1 }); 1-> 2 >^^^^ 3 > ^ @@ -1388,6 +1328,13 @@ sourceFile:contextualTyping.ts 5 > ^ 6 > ^^^ 7 > ^ +8 > ^^ +9 > ^ +10> ^^ +11> ^ +12> ^^ +13> ^ +14> ^ 1-> > 2 >c7t2 @@ -1396,42 +1343,30 @@ sourceFile:contextualTyping.ts 5 > ] 6 > = 7 > ( -1->Emitted(88, 1) Source(79, 1) + SourceIndex(0) -2 >Emitted(88, 5) Source(79, 5) + SourceIndex(0) -3 >Emitted(88, 6) Source(79, 6) + SourceIndex(0) -4 >Emitted(88, 7) Source(79, 7) + SourceIndex(0) -5 >Emitted(88, 8) Source(79, 8) + SourceIndex(0) -6 >Emitted(88, 11) Source(79, 17) + SourceIndex(0) -7 >Emitted(88, 12) Source(79, 18) + SourceIndex(0) ---- ->>> n: 1 -1 >^^^^ -2 > ^ -3 > ^^ -4 > ^ -1 >{ -2 > n -3 > : -4 > 1 -1 >Emitted(89, 5) Source(79, 19) + SourceIndex(0) -2 >Emitted(89, 6) Source(79, 20) + SourceIndex(0) -3 >Emitted(89, 8) Source(79, 22) + SourceIndex(0) -4 >Emitted(89, 9) Source(79, 23) + SourceIndex(0) ---- ->>>}); -1 >^ -2 > ^ -3 > ^ -4 > ^^^^^^^^^^^^^^^-> -1 >} -2 > ) -3 > ; -1 >Emitted(90, 2) Source(79, 24) + SourceIndex(0) -2 >Emitted(90, 3) Source(79, 25) + SourceIndex(0) -3 >Emitted(90, 4) Source(79, 26) + SourceIndex(0) +8 > { +9 > n +10> : +11> 1 +12> } +13> ) +14> ; +1->Emitted(62, 1) Source(79, 1) + SourceIndex(0) +2 >Emitted(62, 5) Source(79, 5) + SourceIndex(0) +3 >Emitted(62, 6) Source(79, 6) + SourceIndex(0) +4 >Emitted(62, 7) Source(79, 7) + SourceIndex(0) +5 >Emitted(62, 8) Source(79, 8) + SourceIndex(0) +6 >Emitted(62, 11) Source(79, 17) + SourceIndex(0) +7 >Emitted(62, 12) Source(79, 18) + SourceIndex(0) +8 >Emitted(62, 14) Source(79, 19) + SourceIndex(0) +9 >Emitted(62, 15) Source(79, 20) + SourceIndex(0) +10>Emitted(62, 17) Source(79, 22) + SourceIndex(0) +11>Emitted(62, 18) Source(79, 23) + SourceIndex(0) +12>Emitted(62, 20) Source(79, 24) + SourceIndex(0) +13>Emitted(62, 21) Source(79, 25) + SourceIndex(0) +14>Emitted(62, 22) Source(79, 26) + SourceIndex(0) --- >>>var objc8 = ({}); -1-> +1 > 2 >^^^^ 3 > ^^^^^ 4 > ^^^ @@ -1439,8 +1374,8 @@ sourceFile:contextualTyping.ts 6 > ^^ 7 > ^ 8 > ^ -9 > ^^^^^^^^^^-> -1-> +9 > ^^^^^^^^^^^^^^^^^^^^^^^^-> +1 > > >// CONTEXT: Object property assignment >interface IPlaceHolder { @@ -1489,16 +1424,16 @@ sourceFile:contextualTyping.ts 6 > {} 7 > ) 8 > ; -1->Emitted(91, 1) Source(102, 1) + SourceIndex(0) -2 >Emitted(91, 5) Source(102, 5) + SourceIndex(0) -3 >Emitted(91, 10) Source(102, 10) + SourceIndex(0) -4 >Emitted(91, 13) Source(120, 19) + SourceIndex(0) -5 >Emitted(91, 14) Source(120, 20) + SourceIndex(0) -6 >Emitted(91, 16) Source(120, 22) + SourceIndex(0) -7 >Emitted(91, 17) Source(120, 23) + SourceIndex(0) -8 >Emitted(91, 18) Source(120, 24) + SourceIndex(0) +1 >Emitted(63, 1) Source(102, 1) + SourceIndex(0) +2 >Emitted(63, 5) Source(102, 5) + SourceIndex(0) +3 >Emitted(63, 10) Source(102, 10) + SourceIndex(0) +4 >Emitted(63, 13) Source(120, 19) + SourceIndex(0) +5 >Emitted(63, 14) Source(120, 20) + SourceIndex(0) +6 >Emitted(63, 16) Source(120, 22) + SourceIndex(0) +7 >Emitted(63, 17) Source(120, 23) + SourceIndex(0) +8 >Emitted(63, 18) Source(120, 24) + SourceIndex(0) --- ->>>objc8.t1 = (function (s) { +>>>objc8.t1 = (function (s) { return s; }); 1-> 2 >^^^^^ 3 > ^ @@ -1507,6 +1442,15 @@ sourceFile:contextualTyping.ts 6 > ^ 7 > ^^^^^^^^^^ 8 > ^ +9 > ^^^^ +10> ^^^^^^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^ +16> ^ +17> ^ 1-> > > @@ -1517,67 +1461,53 @@ sourceFile:contextualTyping.ts 6 > ( 7 > function( 8 > s -1->Emitted(92, 1) Source(122, 1) + SourceIndex(0) -2 >Emitted(92, 6) Source(122, 6) + SourceIndex(0) -3 >Emitted(92, 7) Source(122, 7) + SourceIndex(0) -4 >Emitted(92, 9) Source(122, 9) + SourceIndex(0) -5 >Emitted(92, 12) Source(122, 12) + SourceIndex(0) -6 >Emitted(92, 13) Source(122, 13) + SourceIndex(0) -7 >Emitted(92, 23) Source(122, 22) + SourceIndex(0) -8 >Emitted(92, 24) Source(122, 23) + SourceIndex(0) ---- ->>> return s; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > -1 >Emitted(93, 5) Source(122, 27) + SourceIndex(0) -2 >Emitted(93, 11) Source(122, 33) + SourceIndex(0) -3 >Emitted(93, 12) Source(122, 34) + SourceIndex(0) -4 >Emitted(93, 13) Source(122, 35) + SourceIndex(0) -5 >Emitted(93, 14) Source(122, 35) + SourceIndex(0) ---- ->>>}); -1 > -2 >^ -3 > ^ -4 > ^ -5 > ^^^^^^^^^^^-> -1 > -2 >} -3 > ) -4 > ; -1 >Emitted(94, 1) Source(122, 36) + SourceIndex(0) -2 >Emitted(94, 2) Source(122, 37) + SourceIndex(0) -3 >Emitted(94, 3) Source(122, 38) + SourceIndex(0) -4 >Emitted(94, 4) Source(122, 39) + SourceIndex(0) +9 > ) { +10> return +11> +12> s +13> +14> +15> } +16> ) +17> ; +1->Emitted(64, 1) Source(122, 1) + SourceIndex(0) +2 >Emitted(64, 6) Source(122, 6) + SourceIndex(0) +3 >Emitted(64, 7) Source(122, 7) + SourceIndex(0) +4 >Emitted(64, 9) Source(122, 9) + SourceIndex(0) +5 >Emitted(64, 12) Source(122, 12) + SourceIndex(0) +6 >Emitted(64, 13) Source(122, 13) + SourceIndex(0) +7 >Emitted(64, 23) Source(122, 22) + SourceIndex(0) +8 >Emitted(64, 24) Source(122, 23) + SourceIndex(0) +9 >Emitted(64, 28) Source(122, 27) + SourceIndex(0) +10>Emitted(64, 34) Source(122, 33) + SourceIndex(0) +11>Emitted(64, 35) Source(122, 34) + SourceIndex(0) +12>Emitted(64, 36) Source(122, 35) + SourceIndex(0) +13>Emitted(64, 37) Source(122, 35) + SourceIndex(0) +14>Emitted(64, 38) Source(122, 36) + SourceIndex(0) +15>Emitted(64, 39) Source(122, 37) + SourceIndex(0) +16>Emitted(64, 40) Source(122, 38) + SourceIndex(0) +17>Emitted(64, 41) Source(122, 39) + SourceIndex(0) --- >>>objc8.t2 = ({ -1-> +1 > 2 >^^^^^ 3 > ^ 4 > ^^ 5 > ^^^ 6 > ^ -1-> +1 > > 2 >objc8 3 > . 4 > t2 5 > = 6 > ( -1->Emitted(95, 1) Source(123, 1) + SourceIndex(0) -2 >Emitted(95, 6) Source(123, 6) + SourceIndex(0) -3 >Emitted(95, 7) Source(123, 7) + SourceIndex(0) -4 >Emitted(95, 9) Source(123, 9) + SourceIndex(0) -5 >Emitted(95, 12) Source(123, 18) + SourceIndex(0) -6 >Emitted(95, 13) Source(123, 19) + SourceIndex(0) +1 >Emitted(65, 1) Source(123, 1) + SourceIndex(0) +2 >Emitted(65, 6) Source(123, 6) + SourceIndex(0) +3 >Emitted(65, 7) Source(123, 7) + SourceIndex(0) +4 >Emitted(65, 9) Source(123, 9) + SourceIndex(0) +5 >Emitted(65, 12) Source(123, 18) + SourceIndex(0) +6 >Emitted(65, 13) Source(123, 19) + SourceIndex(0) --- >>> n: 1 1 >^^^^ @@ -1589,10 +1519,10 @@ sourceFile:contextualTyping.ts 2 > n 3 > : 4 > 1 -1 >Emitted(96, 5) Source(124, 5) + SourceIndex(0) -2 >Emitted(96, 6) Source(124, 6) + SourceIndex(0) -3 >Emitted(96, 8) Source(124, 8) + SourceIndex(0) -4 >Emitted(96, 9) Source(124, 9) + SourceIndex(0) +1 >Emitted(66, 5) Source(124, 5) + SourceIndex(0) +2 >Emitted(66, 6) Source(124, 6) + SourceIndex(0) +3 >Emitted(66, 8) Source(124, 8) + SourceIndex(0) +4 >Emitted(66, 9) Source(124, 9) + SourceIndex(0) --- >>>}); 1 >^ @@ -1603,9 +1533,9 @@ sourceFile:contextualTyping.ts >} 2 > ) 3 > ; -1 >Emitted(97, 2) Source(125, 2) + SourceIndex(0) -2 >Emitted(97, 3) Source(125, 3) + SourceIndex(0) -3 >Emitted(97, 4) Source(125, 4) + SourceIndex(0) +1 >Emitted(67, 2) Source(125, 2) + SourceIndex(0) +2 >Emitted(67, 3) Source(125, 3) + SourceIndex(0) +3 >Emitted(67, 4) Source(125, 4) + SourceIndex(0) --- >>>objc8.t3 = []; 1-> @@ -1615,7 +1545,7 @@ sourceFile:contextualTyping.ts 5 > ^^^ 6 > ^^ 7 > ^ -8 > ^^^^^^^^^^^-> +8 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >objc8 @@ -1624,69 +1554,64 @@ sourceFile:contextualTyping.ts 5 > = 6 > [] 7 > ; -1->Emitted(98, 1) Source(126, 1) + SourceIndex(0) -2 >Emitted(98, 6) Source(126, 6) + SourceIndex(0) -3 >Emitted(98, 7) Source(126, 7) + SourceIndex(0) -4 >Emitted(98, 9) Source(126, 9) + SourceIndex(0) -5 >Emitted(98, 12) Source(126, 12) + SourceIndex(0) -6 >Emitted(98, 14) Source(126, 14) + SourceIndex(0) -7 >Emitted(98, 15) Source(126, 15) + SourceIndex(0) +1->Emitted(68, 1) Source(126, 1) + SourceIndex(0) +2 >Emitted(68, 6) Source(126, 6) + SourceIndex(0) +3 >Emitted(68, 7) Source(126, 7) + SourceIndex(0) +4 >Emitted(68, 9) Source(126, 9) + SourceIndex(0) +5 >Emitted(68, 12) Source(126, 12) + SourceIndex(0) +6 >Emitted(68, 14) Source(126, 14) + SourceIndex(0) +7 >Emitted(68, 15) Source(126, 15) + SourceIndex(0) --- ->>>objc8.t4 = function () { +>>>objc8.t4 = function () { return ({}); }; 1-> 2 >^^^^^ 3 > ^ 4 > ^^ 5 > ^^^ -6 > ^^^^^^-> +6 > ^^^^^^^^^^^^^^ +7 > ^^^^^^ +8 > ^ +9 > ^ +10> ^^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^ +16> ^^-> 1-> > 2 >objc8 3 > . 4 > t4 5 > = -1->Emitted(99, 1) Source(127, 1) + SourceIndex(0) -2 >Emitted(99, 6) Source(127, 6) + SourceIndex(0) -3 >Emitted(99, 7) Source(127, 7) + SourceIndex(0) -4 >Emitted(99, 9) Source(127, 9) + SourceIndex(0) -5 >Emitted(99, 12) Source(127, 12) + SourceIndex(0) +6 > function() { +7 > return +8 > +9 > ( +10> {} +11> ) +12> +13> +14> } +15> ; +1->Emitted(69, 1) Source(127, 1) + SourceIndex(0) +2 >Emitted(69, 6) Source(127, 6) + SourceIndex(0) +3 >Emitted(69, 7) Source(127, 7) + SourceIndex(0) +4 >Emitted(69, 9) Source(127, 9) + SourceIndex(0) +5 >Emitted(69, 12) Source(127, 12) + SourceIndex(0) +6 >Emitted(69, 26) Source(127, 25) + SourceIndex(0) +7 >Emitted(69, 32) Source(127, 31) + SourceIndex(0) +8 >Emitted(69, 33) Source(127, 38) + SourceIndex(0) +9 >Emitted(69, 34) Source(127, 39) + SourceIndex(0) +10>Emitted(69, 36) Source(127, 41) + SourceIndex(0) +11>Emitted(69, 37) Source(127, 42) + SourceIndex(0) +12>Emitted(69, 38) Source(127, 42) + SourceIndex(0) +13>Emitted(69, 39) Source(127, 43) + SourceIndex(0) +14>Emitted(69, 40) Source(127, 44) + SourceIndex(0) +15>Emitted(69, 41) Source(127, 45) + SourceIndex(0) --- ->>> return ({}); -1->^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1->function() { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1->Emitted(100, 5) Source(127, 25) + SourceIndex(0) -2 >Emitted(100, 11) Source(127, 31) + SourceIndex(0) -3 >Emitted(100, 12) Source(127, 38) + SourceIndex(0) -4 >Emitted(100, 13) Source(127, 39) + SourceIndex(0) -5 >Emitted(100, 15) Source(127, 41) + SourceIndex(0) -6 >Emitted(100, 16) Source(127, 42) + SourceIndex(0) -7 >Emitted(100, 17) Source(127, 42) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(101, 1) Source(127, 43) + SourceIndex(0) -2 >Emitted(101, 2) Source(127, 44) + SourceIndex(0) -3 >Emitted(101, 3) Source(127, 45) + SourceIndex(0) ---- ->>>objc8.t5 = function (n) { +>>>objc8.t5 = function (n) { return ({}); }; 1-> 2 >^^^^^ 3 > ^ @@ -1694,6 +1619,17 @@ sourceFile:contextualTyping.ts 5 > ^^^ 6 > ^^^^^^^^^^ 7 > ^ +8 > ^^^^ +9 > ^^^^^^ +10> ^ +11> ^ +12> ^^ +13> ^ +14> ^ +15> ^ +16> ^ +17> ^ +18> ^^^^-> 1-> > 2 >objc8 @@ -1702,50 +1638,35 @@ sourceFile:contextualTyping.ts 5 > = 6 > function( 7 > n -1->Emitted(102, 1) Source(128, 1) + SourceIndex(0) -2 >Emitted(102, 6) Source(128, 6) + SourceIndex(0) -3 >Emitted(102, 7) Source(128, 7) + SourceIndex(0) -4 >Emitted(102, 9) Source(128, 9) + SourceIndex(0) -5 >Emitted(102, 12) Source(128, 12) + SourceIndex(0) -6 >Emitted(102, 22) Source(128, 21) + SourceIndex(0) -7 >Emitted(102, 23) Source(128, 22) + SourceIndex(0) +8 > ) { +9 > return +10> +11> ( +12> {} +13> ) +14> +15> +16> } +17> ; +1->Emitted(70, 1) Source(128, 1) + SourceIndex(0) +2 >Emitted(70, 6) Source(128, 6) + SourceIndex(0) +3 >Emitted(70, 7) Source(128, 7) + SourceIndex(0) +4 >Emitted(70, 9) Source(128, 9) + SourceIndex(0) +5 >Emitted(70, 12) Source(128, 12) + SourceIndex(0) +6 >Emitted(70, 22) Source(128, 21) + SourceIndex(0) +7 >Emitted(70, 23) Source(128, 22) + SourceIndex(0) +8 >Emitted(70, 27) Source(128, 26) + SourceIndex(0) +9 >Emitted(70, 33) Source(128, 32) + SourceIndex(0) +10>Emitted(70, 34) Source(128, 39) + SourceIndex(0) +11>Emitted(70, 35) Source(128, 40) + SourceIndex(0) +12>Emitted(70, 37) Source(128, 42) + SourceIndex(0) +13>Emitted(70, 38) Source(128, 43) + SourceIndex(0) +14>Emitted(70, 39) Source(128, 43) + SourceIndex(0) +15>Emitted(70, 40) Source(128, 44) + SourceIndex(0) +16>Emitted(70, 41) Source(128, 45) + SourceIndex(0) +17>Emitted(70, 42) Source(128, 46) + SourceIndex(0) --- ->>> return ({}); -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(103, 5) Source(128, 26) + SourceIndex(0) -2 >Emitted(103, 11) Source(128, 32) + SourceIndex(0) -3 >Emitted(103, 12) Source(128, 39) + SourceIndex(0) -4 >Emitted(103, 13) Source(128, 40) + SourceIndex(0) -5 >Emitted(103, 15) Source(128, 42) + SourceIndex(0) -6 >Emitted(103, 16) Source(128, 43) + SourceIndex(0) -7 >Emitted(103, 17) Source(128, 43) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(104, 1) Source(128, 44) + SourceIndex(0) -2 >Emitted(104, 2) Source(128, 45) + SourceIndex(0) -3 >Emitted(104, 3) Source(128, 46) + SourceIndex(0) ---- ->>>objc8.t6 = function (n, s) { +>>>objc8.t6 = function (n, s) { return ({}); }; 1-> 2 >^^^^^ 3 > ^ @@ -1755,6 +1676,16 @@ sourceFile:contextualTyping.ts 7 > ^ 8 > ^^ 9 > ^ +10> ^^^^ +11> ^^^^^^ +12> ^ +13> ^ +14> ^^ +15> ^ +16> ^ +17> ^ +18> ^ +19> ^ 1-> > 2 >objc8 @@ -1765,60 +1696,54 @@ sourceFile:contextualTyping.ts 7 > n 8 > , 9 > s -1->Emitted(105, 1) Source(129, 1) + SourceIndex(0) -2 >Emitted(105, 6) Source(129, 6) + SourceIndex(0) -3 >Emitted(105, 7) Source(129, 7) + SourceIndex(0) -4 >Emitted(105, 9) Source(129, 9) + SourceIndex(0) -5 >Emitted(105, 12) Source(129, 12) + SourceIndex(0) -6 >Emitted(105, 22) Source(129, 21) + SourceIndex(0) -7 >Emitted(105, 23) Source(129, 22) + SourceIndex(0) -8 >Emitted(105, 25) Source(129, 24) + SourceIndex(0) -9 >Emitted(105, 26) Source(129, 25) + SourceIndex(0) +10> ) { +11> return +12> +13> ( +14> {} +15> ) +16> +17> +18> } +19> ; +1->Emitted(71, 1) Source(129, 1) + SourceIndex(0) +2 >Emitted(71, 6) Source(129, 6) + SourceIndex(0) +3 >Emitted(71, 7) Source(129, 7) + SourceIndex(0) +4 >Emitted(71, 9) Source(129, 9) + SourceIndex(0) +5 >Emitted(71, 12) Source(129, 12) + SourceIndex(0) +6 >Emitted(71, 22) Source(129, 21) + SourceIndex(0) +7 >Emitted(71, 23) Source(129, 22) + SourceIndex(0) +8 >Emitted(71, 25) Source(129, 24) + SourceIndex(0) +9 >Emitted(71, 26) Source(129, 25) + SourceIndex(0) +10>Emitted(71, 30) Source(129, 29) + SourceIndex(0) +11>Emitted(71, 36) Source(129, 35) + SourceIndex(0) +12>Emitted(71, 37) Source(129, 42) + SourceIndex(0) +13>Emitted(71, 38) Source(129, 43) + SourceIndex(0) +14>Emitted(71, 40) Source(129, 45) + SourceIndex(0) +15>Emitted(71, 41) Source(129, 46) + SourceIndex(0) +16>Emitted(71, 42) Source(129, 46) + SourceIndex(0) +17>Emitted(71, 43) Source(129, 47) + SourceIndex(0) +18>Emitted(71, 44) Source(129, 48) + SourceIndex(0) +19>Emitted(71, 45) Source(129, 49) + SourceIndex(0) --- ->>> return ({}); -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(106, 5) Source(129, 29) + SourceIndex(0) -2 >Emitted(106, 11) Source(129, 35) + SourceIndex(0) -3 >Emitted(106, 12) Source(129, 42) + SourceIndex(0) -4 >Emitted(106, 13) Source(129, 43) + SourceIndex(0) -5 >Emitted(106, 15) Source(129, 45) + SourceIndex(0) -6 >Emitted(106, 16) Source(129, 46) + SourceIndex(0) -7 >Emitted(106, 17) Source(129, 46) + SourceIndex(0) ---- ->>>}; +>>>objc8.t7 = function (n) { return n; }; 1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(107, 1) Source(129, 47) + SourceIndex(0) -2 >Emitted(107, 2) Source(129, 48) + SourceIndex(0) -3 >Emitted(107, 3) Source(129, 49) + SourceIndex(0) ---- ->>>objc8.t7 = function (n) { -1-> 2 >^^^^^ 3 > ^ 4 > ^^ 5 > ^^^ 6 > ^^^^^^^^^^ 7 > ^ -1-> +8 > ^^^^ +9 > ^^^^^^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^ +16> ^-> +1 > > 2 >objc8 3 > . @@ -1826,44 +1751,31 @@ sourceFile:contextualTyping.ts 5 > = 6 > function( 7 > n: number -1->Emitted(108, 1) Source(130, 1) + SourceIndex(0) -2 >Emitted(108, 6) Source(130, 6) + SourceIndex(0) -3 >Emitted(108, 7) Source(130, 7) + SourceIndex(0) -4 >Emitted(108, 9) Source(130, 9) + SourceIndex(0) -5 >Emitted(108, 12) Source(130, 12) + SourceIndex(0) -6 >Emitted(108, 22) Source(130, 21) + SourceIndex(0) -7 >Emitted(108, 23) Source(130, 30) + SourceIndex(0) +8 > ) { +9 > return +10> +11> n +12> +13> +14> } +15> ; +1 >Emitted(72, 1) Source(130, 1) + SourceIndex(0) +2 >Emitted(72, 6) Source(130, 6) + SourceIndex(0) +3 >Emitted(72, 7) Source(130, 7) + SourceIndex(0) +4 >Emitted(72, 9) Source(130, 9) + SourceIndex(0) +5 >Emitted(72, 12) Source(130, 12) + SourceIndex(0) +6 >Emitted(72, 22) Source(130, 21) + SourceIndex(0) +7 >Emitted(72, 23) Source(130, 30) + SourceIndex(0) +8 >Emitted(72, 27) Source(130, 34) + SourceIndex(0) +9 >Emitted(72, 33) Source(130, 40) + SourceIndex(0) +10>Emitted(72, 34) Source(130, 41) + SourceIndex(0) +11>Emitted(72, 35) Source(130, 42) + SourceIndex(0) +12>Emitted(72, 36) Source(130, 42) + SourceIndex(0) +13>Emitted(72, 37) Source(130, 43) + SourceIndex(0) +14>Emitted(72, 38) Source(130, 44) + SourceIndex(0) +15>Emitted(72, 39) Source(130, 45) + SourceIndex(0) --- ->>> return n; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > n -5 > -1 >Emitted(109, 5) Source(130, 34) + SourceIndex(0) -2 >Emitted(109, 11) Source(130, 40) + SourceIndex(0) -3 >Emitted(109, 12) Source(130, 41) + SourceIndex(0) -4 >Emitted(109, 13) Source(130, 42) + SourceIndex(0) -5 >Emitted(109, 14) Source(130, 42) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(110, 1) Source(130, 43) + SourceIndex(0) -2 >Emitted(110, 2) Source(130, 44) + SourceIndex(0) -3 >Emitted(110, 3) Source(130, 45) + SourceIndex(0) ---- ->>>objc8.t8 = function (n) { +>>>objc8.t8 = function (n) { return n; }; 1-> 2 >^^^^^ 3 > ^ @@ -1871,6 +1783,14 @@ sourceFile:contextualTyping.ts 5 > ^^^ 6 > ^^^^^^^^^^ 7 > ^ +8 > ^^^^ +9 > ^^^^^^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^ 1-> > > @@ -1880,231 +1800,194 @@ sourceFile:contextualTyping.ts 5 > = 6 > function( 7 > n -1->Emitted(111, 1) Source(132, 1) + SourceIndex(0) -2 >Emitted(111, 6) Source(132, 6) + SourceIndex(0) -3 >Emitted(111, 7) Source(132, 7) + SourceIndex(0) -4 >Emitted(111, 9) Source(132, 9) + SourceIndex(0) -5 >Emitted(111, 12) Source(132, 12) + SourceIndex(0) -6 >Emitted(111, 22) Source(132, 21) + SourceIndex(0) -7 >Emitted(111, 23) Source(132, 22) + SourceIndex(0) +8 > ) { +9 > return +10> +11> n +12> ; +13> +14> } +15> ; +1->Emitted(73, 1) Source(132, 1) + SourceIndex(0) +2 >Emitted(73, 6) Source(132, 6) + SourceIndex(0) +3 >Emitted(73, 7) Source(132, 7) + SourceIndex(0) +4 >Emitted(73, 9) Source(132, 9) + SourceIndex(0) +5 >Emitted(73, 12) Source(132, 12) + SourceIndex(0) +6 >Emitted(73, 22) Source(132, 21) + SourceIndex(0) +7 >Emitted(73, 23) Source(132, 22) + SourceIndex(0) +8 >Emitted(73, 27) Source(132, 26) + SourceIndex(0) +9 >Emitted(73, 33) Source(132, 32) + SourceIndex(0) +10>Emitted(73, 34) Source(132, 33) + SourceIndex(0) +11>Emitted(73, 35) Source(132, 34) + SourceIndex(0) +12>Emitted(73, 36) Source(132, 35) + SourceIndex(0) +13>Emitted(73, 37) Source(132, 36) + SourceIndex(0) +14>Emitted(73, 38) Source(132, 37) + SourceIndex(0) +15>Emitted(73, 39) Source(132, 38) + SourceIndex(0) --- ->>> return n; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > n -5 > ; -1 >Emitted(112, 5) Source(132, 26) + SourceIndex(0) -2 >Emitted(112, 11) Source(132, 32) + SourceIndex(0) -3 >Emitted(112, 12) Source(132, 33) + SourceIndex(0) -4 >Emitted(112, 13) Source(132, 34) + SourceIndex(0) -5 >Emitted(112, 14) Source(132, 35) + SourceIndex(0) ---- ->>>}; +>>>objc8.t9 = [[], []]; 1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(113, 1) Source(132, 36) + SourceIndex(0) -2 >Emitted(113, 2) Source(132, 37) + SourceIndex(0) -3 >Emitted(113, 3) Source(132, 38) + SourceIndex(0) ---- ->>>objc8.t9 = [ -1-> 2 >^^^^^ 3 > ^ 4 > ^^ 5 > ^^^ -1-> +6 > ^ +7 > ^^ +8 > ^^ +9 > ^^ +10> ^ +11> ^ +12> ^^^^^^-> +1 > > 2 >objc8 3 > . 4 > t9 5 > = -1->Emitted(114, 1) Source(133, 1) + SourceIndex(0) -2 >Emitted(114, 6) Source(133, 6) + SourceIndex(0) -3 >Emitted(114, 7) Source(133, 7) + SourceIndex(0) -4 >Emitted(114, 9) Source(133, 9) + SourceIndex(0) -5 >Emitted(114, 12) Source(133, 12) + SourceIndex(0) +6 > [ +7 > [] +8 > , +9 > [] +10> ] +11> ; +1 >Emitted(74, 1) Source(133, 1) + SourceIndex(0) +2 >Emitted(74, 6) Source(133, 6) + SourceIndex(0) +3 >Emitted(74, 7) Source(133, 7) + SourceIndex(0) +4 >Emitted(74, 9) Source(133, 9) + SourceIndex(0) +5 >Emitted(74, 12) Source(133, 12) + SourceIndex(0) +6 >Emitted(74, 13) Source(133, 13) + SourceIndex(0) +7 >Emitted(74, 15) Source(133, 15) + SourceIndex(0) +8 >Emitted(74, 17) Source(133, 16) + SourceIndex(0) +9 >Emitted(74, 19) Source(133, 18) + SourceIndex(0) +10>Emitted(74, 20) Source(133, 19) + SourceIndex(0) +11>Emitted(74, 21) Source(133, 20) + SourceIndex(0) --- ->>> [], -1 >^^^^ -2 > ^^ -3 > ^-> -1 >[ -2 > [] -1 >Emitted(115, 5) Source(133, 13) + SourceIndex(0) -2 >Emitted(115, 7) Source(133, 15) + SourceIndex(0) ---- ->>> [] -1->^^^^ -2 > ^^ -1->, -2 > [] -1->Emitted(116, 5) Source(133, 16) + SourceIndex(0) -2 >Emitted(116, 7) Source(133, 18) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(117, 2) Source(133, 19) + SourceIndex(0) -2 >Emitted(117, 3) Source(133, 20) + SourceIndex(0) ---- ->>>objc8.t10 = [ +>>>objc8.t10 = [({}), ({})]; 1-> 2 >^^^^^ 3 > ^ 4 > ^^^ 5 > ^^^ +6 > ^ +7 > ^ +8 > ^^ +9 > ^ +10> ^^ +11> ^ +12> ^^ +13> ^ +14> ^ +15> ^ +16> ^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >objc8 3 > . 4 > t10 5 > = -1->Emitted(118, 1) Source(134, 1) + SourceIndex(0) -2 >Emitted(118, 6) Source(134, 6) + SourceIndex(0) -3 >Emitted(118, 7) Source(134, 7) + SourceIndex(0) -4 >Emitted(118, 10) Source(134, 10) + SourceIndex(0) -5 >Emitted(118, 13) Source(134, 13) + SourceIndex(0) +6 > [ +7 > ( +8 > {} +9 > ) +10> , +11> ( +12> {} +13> ) +14> ] +15> ; +1->Emitted(75, 1) Source(134, 1) + SourceIndex(0) +2 >Emitted(75, 6) Source(134, 6) + SourceIndex(0) +3 >Emitted(75, 7) Source(134, 7) + SourceIndex(0) +4 >Emitted(75, 10) Source(134, 10) + SourceIndex(0) +5 >Emitted(75, 13) Source(134, 13) + SourceIndex(0) +6 >Emitted(75, 14) Source(134, 20) + SourceIndex(0) +7 >Emitted(75, 15) Source(134, 21) + SourceIndex(0) +8 >Emitted(75, 17) Source(134, 23) + SourceIndex(0) +9 >Emitted(75, 18) Source(134, 24) + SourceIndex(0) +10>Emitted(75, 20) Source(134, 31) + SourceIndex(0) +11>Emitted(75, 21) Source(134, 32) + SourceIndex(0) +12>Emitted(75, 23) Source(134, 34) + SourceIndex(0) +13>Emitted(75, 24) Source(134, 35) + SourceIndex(0) +14>Emitted(75, 25) Source(134, 36) + SourceIndex(0) +15>Emitted(75, 26) Source(134, 37) + SourceIndex(0) --- ->>> ({}), -1 >^^^^ -2 > ^ -3 > ^^ -4 > ^ -5 > ^-> -1 >[ -2 > ( -3 > {} -4 > ) -1 >Emitted(119, 5) Source(134, 20) + SourceIndex(0) -2 >Emitted(119, 6) Source(134, 21) + SourceIndex(0) -3 >Emitted(119, 8) Source(134, 23) + SourceIndex(0) -4 >Emitted(119, 9) Source(134, 24) + SourceIndex(0) ---- ->>> ({}) -1->^^^^ -2 > ^ -3 > ^^ -4 > ^ -1->, -2 > ( -3 > {} -4 > ) -1->Emitted(120, 5) Source(134, 31) + SourceIndex(0) -2 >Emitted(120, 6) Source(134, 32) + SourceIndex(0) -3 >Emitted(120, 8) Source(134, 34) + SourceIndex(0) -4 >Emitted(120, 9) Source(134, 35) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(121, 2) Source(134, 36) + SourceIndex(0) -2 >Emitted(121, 3) Source(134, 37) + SourceIndex(0) ---- ->>>objc8.t11 = [ +>>>objc8.t11 = [function (n, s) { return s; }]; 1-> 2 >^^^^^ 3 > ^ 4 > ^^^ 5 > ^^^ -6 > ^^^^^^^^^^-> +6 > ^ +7 > ^^^^^^^^^^ +8 > ^ +9 > ^^ +10> ^ +11> ^^^^ +12> ^^^^^^ +13> ^ +14> ^ +15> ^ +16> ^ +17> ^ +18> ^ +19> ^ 1-> > 2 >objc8 3 > . 4 > t11 5 > = -1->Emitted(122, 1) Source(135, 1) + SourceIndex(0) -2 >Emitted(122, 6) Source(135, 6) + SourceIndex(0) -3 >Emitted(122, 7) Source(135, 7) + SourceIndex(0) -4 >Emitted(122, 10) Source(135, 10) + SourceIndex(0) -5 >Emitted(122, 13) Source(135, 13) + SourceIndex(0) ---- ->>> function (n, s) { -1->^^^^ -2 > ^^^^^^^^^^ -3 > ^ -4 > ^^ -5 > ^ -1->[ -2 > function( -3 > n -4 > , -5 > s -1->Emitted(123, 5) Source(135, 14) + SourceIndex(0) -2 >Emitted(123, 15) Source(135, 23) + SourceIndex(0) -3 >Emitted(123, 16) Source(135, 24) + SourceIndex(0) -4 >Emitted(123, 18) Source(135, 26) + SourceIndex(0) -5 >Emitted(123, 19) Source(135, 27) + SourceIndex(0) ---- ->>> return s; -1 >^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > ; -1 >Emitted(124, 9) Source(135, 31) + SourceIndex(0) -2 >Emitted(124, 15) Source(135, 37) + SourceIndex(0) -3 >Emitted(124, 16) Source(135, 38) + SourceIndex(0) -4 >Emitted(124, 17) Source(135, 39) + SourceIndex(0) -5 >Emitted(124, 18) Source(135, 40) + SourceIndex(0) ---- ->>> } -1 >^^^^ -2 > ^ -1 > -2 > } -1 >Emitted(125, 5) Source(135, 41) + SourceIndex(0) -2 >Emitted(125, 6) Source(135, 42) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(126, 2) Source(135, 43) + SourceIndex(0) -2 >Emitted(126, 3) Source(135, 44) + SourceIndex(0) +6 > [ +7 > function( +8 > n +9 > , +10> s +11> ) { +12> return +13> +14> s +15> ; +16> +17> } +18> ] +19> ; +1->Emitted(76, 1) Source(135, 1) + SourceIndex(0) +2 >Emitted(76, 6) Source(135, 6) + SourceIndex(0) +3 >Emitted(76, 7) Source(135, 7) + SourceIndex(0) +4 >Emitted(76, 10) Source(135, 10) + SourceIndex(0) +5 >Emitted(76, 13) Source(135, 13) + SourceIndex(0) +6 >Emitted(76, 14) Source(135, 14) + SourceIndex(0) +7 >Emitted(76, 24) Source(135, 23) + SourceIndex(0) +8 >Emitted(76, 25) Source(135, 24) + SourceIndex(0) +9 >Emitted(76, 27) Source(135, 26) + SourceIndex(0) +10>Emitted(76, 28) Source(135, 27) + SourceIndex(0) +11>Emitted(76, 32) Source(135, 31) + SourceIndex(0) +12>Emitted(76, 38) Source(135, 37) + SourceIndex(0) +13>Emitted(76, 39) Source(135, 38) + SourceIndex(0) +14>Emitted(76, 40) Source(135, 39) + SourceIndex(0) +15>Emitted(76, 41) Source(135, 40) + SourceIndex(0) +16>Emitted(76, 42) Source(135, 41) + SourceIndex(0) +17>Emitted(76, 43) Source(135, 42) + SourceIndex(0) +18>Emitted(76, 44) Source(135, 43) + SourceIndex(0) +19>Emitted(76, 45) Source(135, 44) + SourceIndex(0) --- >>>objc8.t12 = { -1-> +1 > 2 >^^^^^ 3 > ^ 4 > ^^^ 5 > ^^^ 6 > ^^-> -1-> +1 > > 2 >objc8 3 > . 4 > t12 5 > = -1->Emitted(127, 1) Source(136, 1) + SourceIndex(0) -2 >Emitted(127, 6) Source(136, 6) + SourceIndex(0) -3 >Emitted(127, 7) Source(136, 7) + SourceIndex(0) -4 >Emitted(127, 10) Source(136, 10) + SourceIndex(0) -5 >Emitted(127, 13) Source(136, 13) + SourceIndex(0) +1 >Emitted(77, 1) Source(136, 1) + SourceIndex(0) +2 >Emitted(77, 6) Source(136, 6) + SourceIndex(0) +3 >Emitted(77, 7) Source(136, 7) + SourceIndex(0) +4 >Emitted(77, 10) Source(136, 10) + SourceIndex(0) +5 >Emitted(77, 13) Source(136, 13) + SourceIndex(0) --- >>> foo: ({}) 1->^^^^ @@ -2120,12 +2003,12 @@ sourceFile:contextualTyping.ts 4 > ( 5 > {} 6 > ) -1->Emitted(128, 5) Source(137, 5) + SourceIndex(0) -2 >Emitted(128, 8) Source(137, 8) + SourceIndex(0) -3 >Emitted(128, 10) Source(137, 16) + SourceIndex(0) -4 >Emitted(128, 11) Source(137, 17) + SourceIndex(0) -5 >Emitted(128, 13) Source(137, 19) + SourceIndex(0) -6 >Emitted(128, 14) Source(137, 20) + SourceIndex(0) +1->Emitted(78, 5) Source(137, 5) + SourceIndex(0) +2 >Emitted(78, 8) Source(137, 8) + SourceIndex(0) +3 >Emitted(78, 10) Source(137, 16) + SourceIndex(0) +4 >Emitted(78, 11) Source(137, 17) + SourceIndex(0) +5 >Emitted(78, 13) Source(137, 19) + SourceIndex(0) +6 >Emitted(78, 14) Source(137, 20) + SourceIndex(0) --- >>>}; 1 >^ @@ -2134,8 +2017,8 @@ sourceFile:contextualTyping.ts 1 > >} 2 > -1 >Emitted(129, 2) Source(138, 2) + SourceIndex(0) -2 >Emitted(129, 3) Source(138, 2) + SourceIndex(0) +1 >Emitted(79, 2) Source(138, 2) + SourceIndex(0) +2 >Emitted(79, 3) Source(138, 2) + SourceIndex(0) --- >>>objc8.t13 = ({ 1-> @@ -2144,7 +2027,7 @@ sourceFile:contextualTyping.ts 4 > ^^^ 5 > ^^^ 6 > ^ -7 > ^^^^^^^^^^^^-> +7 > ^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >objc8 @@ -2152,14 +2035,14 @@ sourceFile:contextualTyping.ts 4 > t13 5 > = 6 > ( -1->Emitted(130, 1) Source(139, 1) + SourceIndex(0) -2 >Emitted(130, 6) Source(139, 6) + SourceIndex(0) -3 >Emitted(130, 7) Source(139, 7) + SourceIndex(0) -4 >Emitted(130, 10) Source(139, 10) + SourceIndex(0) -5 >Emitted(130, 13) Source(139, 19) + SourceIndex(0) -6 >Emitted(130, 14) Source(139, 20) + SourceIndex(0) +1->Emitted(80, 1) Source(139, 1) + SourceIndex(0) +2 >Emitted(80, 6) Source(139, 6) + SourceIndex(0) +3 >Emitted(80, 7) Source(139, 7) + SourceIndex(0) +4 >Emitted(80, 10) Source(139, 10) + SourceIndex(0) +5 >Emitted(80, 13) Source(139, 19) + SourceIndex(0) +6 >Emitted(80, 14) Source(139, 20) + SourceIndex(0) --- ->>> f: function (i, s) { +>>> f: function (i, s) { return s; } 1->^^^^ 2 > ^ 3 > ^^ @@ -2167,6 +2050,13 @@ sourceFile:contextualTyping.ts 5 > ^ 6 > ^^ 7 > ^ +8 > ^^^^ +9 > ^^^^^^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ 1->{ > 2 > f @@ -2175,38 +2065,27 @@ sourceFile:contextualTyping.ts 5 > i 6 > , 7 > s -1->Emitted(131, 5) Source(140, 5) + SourceIndex(0) -2 >Emitted(131, 6) Source(140, 6) + SourceIndex(0) -3 >Emitted(131, 8) Source(140, 8) + SourceIndex(0) -4 >Emitted(131, 18) Source(140, 17) + SourceIndex(0) -5 >Emitted(131, 19) Source(140, 18) + SourceIndex(0) -6 >Emitted(131, 21) Source(140, 20) + SourceIndex(0) -7 >Emitted(131, 22) Source(140, 21) + SourceIndex(0) ---- ->>> return s; -1 >^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > ; -1 >Emitted(132, 9) Source(140, 25) + SourceIndex(0) -2 >Emitted(132, 15) Source(140, 31) + SourceIndex(0) -3 >Emitted(132, 16) Source(140, 32) + SourceIndex(0) -4 >Emitted(132, 17) Source(140, 33) + SourceIndex(0) -5 >Emitted(132, 18) Source(140, 34) + SourceIndex(0) ---- ->>> } -1 >^^^^ -2 > ^ -1 > -2 > } -1 >Emitted(133, 5) Source(140, 35) + SourceIndex(0) -2 >Emitted(133, 6) Source(140, 36) + SourceIndex(0) +8 > ) { +9 > return +10> +11> s +12> ; +13> +14> } +1->Emitted(81, 5) Source(140, 5) + SourceIndex(0) +2 >Emitted(81, 6) Source(140, 6) + SourceIndex(0) +3 >Emitted(81, 8) Source(140, 8) + SourceIndex(0) +4 >Emitted(81, 18) Source(140, 17) + SourceIndex(0) +5 >Emitted(81, 19) Source(140, 18) + SourceIndex(0) +6 >Emitted(81, 21) Source(140, 20) + SourceIndex(0) +7 >Emitted(81, 22) Source(140, 21) + SourceIndex(0) +8 >Emitted(81, 26) Source(140, 25) + SourceIndex(0) +9 >Emitted(81, 32) Source(140, 31) + SourceIndex(0) +10>Emitted(81, 33) Source(140, 32) + SourceIndex(0) +11>Emitted(81, 34) Source(140, 33) + SourceIndex(0) +12>Emitted(81, 35) Source(140, 34) + SourceIndex(0) +13>Emitted(81, 36) Source(140, 35) + SourceIndex(0) +14>Emitted(81, 37) Source(140, 36) + SourceIndex(0) --- >>>}); 1 >^ @@ -2217,9 +2096,9 @@ sourceFile:contextualTyping.ts >} 2 > ) 3 > -1 >Emitted(134, 2) Source(141, 2) + SourceIndex(0) -2 >Emitted(134, 3) Source(141, 3) + SourceIndex(0) -3 >Emitted(134, 4) Source(141, 3) + SourceIndex(0) +1 >Emitted(82, 2) Source(141, 2) + SourceIndex(0) +2 >Emitted(82, 3) Source(141, 3) + SourceIndex(0) +3 >Emitted(82, 4) Source(141, 3) + SourceIndex(0) --- >>>objc8.t14 = ({ 1-> @@ -2235,12 +2114,12 @@ sourceFile:contextualTyping.ts 4 > t14 5 > = 6 > ( -1->Emitted(135, 1) Source(142, 1) + SourceIndex(0) -2 >Emitted(135, 6) Source(142, 6) + SourceIndex(0) -3 >Emitted(135, 7) Source(142, 7) + SourceIndex(0) -4 >Emitted(135, 10) Source(142, 10) + SourceIndex(0) -5 >Emitted(135, 13) Source(142, 19) + SourceIndex(0) -6 >Emitted(135, 14) Source(142, 20) + SourceIndex(0) +1->Emitted(83, 1) Source(142, 1) + SourceIndex(0) +2 >Emitted(83, 6) Source(142, 6) + SourceIndex(0) +3 >Emitted(83, 7) Source(142, 7) + SourceIndex(0) +4 >Emitted(83, 10) Source(142, 10) + SourceIndex(0) +5 >Emitted(83, 13) Source(142, 19) + SourceIndex(0) +6 >Emitted(83, 14) Source(142, 20) + SourceIndex(0) --- >>> a: [] 1 >^^^^ @@ -2252,10 +2131,10 @@ sourceFile:contextualTyping.ts 2 > a 3 > : 4 > [] -1 >Emitted(136, 5) Source(143, 5) + SourceIndex(0) -2 >Emitted(136, 6) Source(143, 6) + SourceIndex(0) -3 >Emitted(136, 8) Source(143, 8) + SourceIndex(0) -4 >Emitted(136, 10) Source(143, 10) + SourceIndex(0) +1 >Emitted(84, 5) Source(143, 5) + SourceIndex(0) +2 >Emitted(84, 6) Source(143, 6) + SourceIndex(0) +3 >Emitted(84, 8) Source(143, 8) + SourceIndex(0) +4 >Emitted(84, 10) Source(143, 10) + SourceIndex(0) --- >>>}); 1 >^ @@ -2266,9 +2145,9 @@ sourceFile:contextualTyping.ts >} 2 > ) 3 > -1 >Emitted(137, 2) Source(144, 2) + SourceIndex(0) -2 >Emitted(137, 3) Source(144, 3) + SourceIndex(0) -3 >Emitted(137, 4) Source(144, 3) + SourceIndex(0) +1 >Emitted(85, 2) Source(144, 2) + SourceIndex(0) +2 >Emitted(85, 3) Source(144, 3) + SourceIndex(0) +3 >Emitted(85, 4) Source(144, 3) + SourceIndex(0) --- >>>// CONTEXT: Function call 1-> @@ -2279,36 +2158,33 @@ sourceFile:contextualTyping.ts > 2 > 3 >// CONTEXT: Function call -1->Emitted(138, 1) Source(146, 1) + SourceIndex(0) -2 >Emitted(138, 1) Source(145, 1) + SourceIndex(0) -3 >Emitted(138, 26) Source(145, 26) + SourceIndex(0) +1->Emitted(86, 1) Source(146, 1) + SourceIndex(0) +2 >Emitted(86, 1) Source(145, 1) + SourceIndex(0) +3 >Emitted(86, 26) Source(145, 26) + SourceIndex(0) --- ->>>function c9t5(f) { +>>>function c9t5(f) { } 1 >^^^^^^^^^^^^^^ 2 > ^ +3 > ^^^^ +4 > ^ 1 > >function c9t5( 2 > f: (n: number) => IFoo -1 >Emitted(139, 15) Source(146, 15) + SourceIndex(0) -2 >Emitted(139, 16) Source(146, 37) + SourceIndex(0) ---- ->>>} -1 > -2 >^ -3 > ^-> -1 >) { -2 >} -1 >Emitted(140, 1) Source(146, 40) + SourceIndex(0) name (c9t5) -2 >Emitted(140, 2) Source(146, 41) + SourceIndex(0) name (c9t5) +3 > ) { +4 > } +1 >Emitted(87, 15) Source(146, 15) + SourceIndex(0) +2 >Emitted(87, 16) Source(146, 37) + SourceIndex(0) +3 >Emitted(87, 20) Source(146, 40) + SourceIndex(0) name (c9t5) +4 >Emitted(87, 21) Source(146, 41) + SourceIndex(0) name (c9t5) --- >>>; -1-> +1 > 2 >^ 3 > ^^^^^^^^^^^^^^^^^^^-> -1-> +1 > 2 >; -1->Emitted(141, 1) Source(146, 41) + SourceIndex(0) -2 >Emitted(141, 2) Source(146, 42) + SourceIndex(0) +1 >Emitted(88, 1) Source(146, 41) + SourceIndex(0) +2 >Emitted(88, 2) Source(146, 42) + SourceIndex(0) --- >>>c9t5(function (n) { 1-> @@ -2323,11 +2199,11 @@ sourceFile:contextualTyping.ts 3 > ( 4 > function( 5 > n -1->Emitted(142, 1) Source(147, 1) + SourceIndex(0) -2 >Emitted(142, 5) Source(147, 5) + SourceIndex(0) -3 >Emitted(142, 6) Source(147, 6) + SourceIndex(0) -4 >Emitted(142, 16) Source(147, 15) + SourceIndex(0) -5 >Emitted(142, 17) Source(147, 16) + SourceIndex(0) +1->Emitted(89, 1) Source(147, 1) + SourceIndex(0) +2 >Emitted(89, 5) Source(147, 5) + SourceIndex(0) +3 >Emitted(89, 6) Source(147, 6) + SourceIndex(0) +4 >Emitted(89, 16) Source(147, 15) + SourceIndex(0) +5 >Emitted(89, 17) Source(147, 16) + SourceIndex(0) --- >>> return ({}); 1->^^^^ @@ -2345,13 +2221,13 @@ sourceFile:contextualTyping.ts 5 > {} 6 > ) 7 > ; -1->Emitted(143, 5) Source(148, 5) + SourceIndex(0) -2 >Emitted(143, 11) Source(148, 11) + SourceIndex(0) -3 >Emitted(143, 12) Source(148, 18) + SourceIndex(0) -4 >Emitted(143, 13) Source(148, 19) + SourceIndex(0) -5 >Emitted(143, 15) Source(148, 21) + SourceIndex(0) -6 >Emitted(143, 16) Source(148, 22) + SourceIndex(0) -7 >Emitted(143, 17) Source(148, 23) + SourceIndex(0) +1->Emitted(90, 5) Source(148, 5) + SourceIndex(0) +2 >Emitted(90, 11) Source(148, 11) + SourceIndex(0) +3 >Emitted(90, 12) Source(148, 18) + SourceIndex(0) +4 >Emitted(90, 13) Source(148, 19) + SourceIndex(0) +5 >Emitted(90, 15) Source(148, 21) + SourceIndex(0) +6 >Emitted(90, 16) Source(148, 22) + SourceIndex(0) +7 >Emitted(90, 17) Source(148, 23) + SourceIndex(0) --- >>>}); 1 > @@ -2364,115 +2240,106 @@ sourceFile:contextualTyping.ts 2 >} 3 > ) 4 > ; -1 >Emitted(144, 1) Source(149, 1) + SourceIndex(0) -2 >Emitted(144, 2) Source(149, 2) + SourceIndex(0) -3 >Emitted(144, 3) Source(149, 3) + SourceIndex(0) -4 >Emitted(144, 4) Source(149, 4) + SourceIndex(0) +1 >Emitted(91, 1) Source(149, 1) + SourceIndex(0) +2 >Emitted(91, 2) Source(149, 2) + SourceIndex(0) +3 >Emitted(91, 3) Source(149, 3) + SourceIndex(0) +4 >Emitted(91, 4) Source(149, 4) + SourceIndex(0) --- >>>// CONTEXT: Return statement 1-> 2 > 3 >^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > >// CONTEXT: Return statement > 2 > 3 >// CONTEXT: Return statement -1->Emitted(145, 1) Source(152, 1) + SourceIndex(0) -2 >Emitted(145, 1) Source(151, 1) + SourceIndex(0) -3 >Emitted(145, 29) Source(151, 29) + SourceIndex(0) +1->Emitted(92, 1) Source(152, 1) + SourceIndex(0) +2 >Emitted(92, 1) Source(151, 1) + SourceIndex(0) +3 >Emitted(92, 29) Source(151, 29) + SourceIndex(0) --- ->>>var c10t5 = function () { -1 >^^^^ +>>>var c10t5 = function () { return function (n) { return ({}); }; }; +1->^^^^ 2 > ^^^^^ 3 > ^^^ -4 > ^^^^^^^^^^^^^^-> -1 > +4 > ^^^^^^^^^^^^^^ +5 > ^^^^^^ +6 > ^ +7 > ^^^^^^^^^^ +8 > ^ +9 > ^^^^ +10> ^^^^^^ +11> ^ +12> ^ +13> ^^ +14> ^ +15> ^ +16> ^ +17> ^ +18> ^ +19> ^ +20> ^ +21> ^ +1-> >var 2 > c10t5 3 > : () => (n: number) => IFoo = -1 >Emitted(146, 5) Source(152, 5) + SourceIndex(0) -2 >Emitted(146, 10) Source(152, 10) + SourceIndex(0) -3 >Emitted(146, 13) Source(152, 40) + SourceIndex(0) ---- ->>> return function (n) { -1->^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^^^^^^^^^^ -5 > ^ -1->function() { -2 > return -3 > -4 > function( -5 > n -1->Emitted(147, 5) Source(152, 53) + SourceIndex(0) -2 >Emitted(147, 11) Source(152, 59) + SourceIndex(0) -3 >Emitted(147, 12) Source(152, 60) + SourceIndex(0) -4 >Emitted(147, 22) Source(152, 69) + SourceIndex(0) -5 >Emitted(147, 23) Source(152, 70) + SourceIndex(0) ---- ->>> return ({}); -1 >^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(148, 9) Source(152, 74) + SourceIndex(0) -2 >Emitted(148, 15) Source(152, 80) + SourceIndex(0) -3 >Emitted(148, 16) Source(152, 87) + SourceIndex(0) -4 >Emitted(148, 17) Source(152, 88) + SourceIndex(0) -5 >Emitted(148, 19) Source(152, 90) + SourceIndex(0) -6 >Emitted(148, 20) Source(152, 91) + SourceIndex(0) -7 >Emitted(148, 21) Source(152, 91) + SourceIndex(0) ---- ->>> }; -1 >^^^^ -2 > ^ -3 > ^ -1 > -2 > } -3 > -1 >Emitted(149, 5) Source(152, 92) + SourceIndex(0) -2 >Emitted(149, 6) Source(152, 93) + SourceIndex(0) -3 >Emitted(149, 7) Source(152, 93) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(150, 1) Source(152, 94) + SourceIndex(0) -2 >Emitted(150, 2) Source(152, 95) + SourceIndex(0) -3 >Emitted(150, 3) Source(152, 96) + SourceIndex(0) +4 > function() { +5 > return +6 > +7 > function( +8 > n +9 > ) { +10> return +11> +12> ( +13> {} +14> ) +15> +16> +17> } +18> +19> +20> } +21> ; +1->Emitted(93, 5) Source(152, 5) + SourceIndex(0) +2 >Emitted(93, 10) Source(152, 10) + SourceIndex(0) +3 >Emitted(93, 13) Source(152, 40) + SourceIndex(0) +4 >Emitted(93, 27) Source(152, 53) + SourceIndex(0) +5 >Emitted(93, 33) Source(152, 59) + SourceIndex(0) +6 >Emitted(93, 34) Source(152, 60) + SourceIndex(0) +7 >Emitted(93, 44) Source(152, 69) + SourceIndex(0) +8 >Emitted(93, 45) Source(152, 70) + SourceIndex(0) +9 >Emitted(93, 49) Source(152, 74) + SourceIndex(0) +10>Emitted(93, 55) Source(152, 80) + SourceIndex(0) +11>Emitted(93, 56) Source(152, 87) + SourceIndex(0) +12>Emitted(93, 57) Source(152, 88) + SourceIndex(0) +13>Emitted(93, 59) Source(152, 90) + SourceIndex(0) +14>Emitted(93, 60) Source(152, 91) + SourceIndex(0) +15>Emitted(93, 61) Source(152, 91) + SourceIndex(0) +16>Emitted(93, 62) Source(152, 92) + SourceIndex(0) +17>Emitted(93, 63) Source(152, 93) + SourceIndex(0) +18>Emitted(93, 64) Source(152, 93) + SourceIndex(0) +19>Emitted(93, 65) Source(152, 94) + SourceIndex(0) +20>Emitted(93, 66) Source(152, 95) + SourceIndex(0) +21>Emitted(93, 67) Source(152, 96) + SourceIndex(0) --- >>>// CONTEXT: Newing a class -1-> +1 > 2 > 3 >^^^^^^^^^^^^^^^^^^^^^^^^^^ 4 > ^-> -1-> +1 > > >// CONTEXT: Newing a class > 2 > 3 >// CONTEXT: Newing a class -1->Emitted(151, 1) Source(155, 1) + SourceIndex(0) -2 >Emitted(151, 1) Source(154, 1) + SourceIndex(0) -3 >Emitted(151, 27) Source(154, 27) + SourceIndex(0) +1 >Emitted(94, 1) Source(155, 1) + SourceIndex(0) +2 >Emitted(94, 1) Source(154, 1) + SourceIndex(0) +3 >Emitted(94, 27) Source(154, 27) + SourceIndex(0) --- >>>var C11t5 = (function () { >>> function C11t5(f) { @@ -2483,9 +2350,9 @@ sourceFile:contextualTyping.ts >class C11t5 { 2 > constructor( 3 > f: (n: number) => IFoo -1->Emitted(153, 5) Source(155, 15) + SourceIndex(0) name (C11t5) -2 >Emitted(153, 20) Source(155, 27) + SourceIndex(0) name (C11t5) -3 >Emitted(153, 21) Source(155, 49) + SourceIndex(0) name (C11t5) +1->Emitted(96, 5) Source(155, 15) + SourceIndex(0) name (C11t5) +2 >Emitted(96, 20) Source(155, 27) + SourceIndex(0) name (C11t5) +3 >Emitted(96, 21) Source(155, 49) + SourceIndex(0) name (C11t5) --- >>> } 1 >^^^^ @@ -2493,16 +2360,16 @@ sourceFile:contextualTyping.ts 3 > ^^^^^^^^^^^^^-> 1 >) { 2 > } -1 >Emitted(154, 5) Source(155, 53) + SourceIndex(0) name (C11t5.constructor) -2 >Emitted(154, 6) Source(155, 54) + SourceIndex(0) name (C11t5.constructor) +1 >Emitted(97, 5) Source(155, 53) + SourceIndex(0) name (C11t5.constructor) +2 >Emitted(97, 6) Source(155, 54) + SourceIndex(0) name (C11t5.constructor) --- >>> return C11t5; 1->^^^^ 2 > ^^^^^^^^^^^^ 1-> 2 > } -1->Emitted(155, 5) Source(155, 55) + SourceIndex(0) name (C11t5) -2 >Emitted(155, 17) Source(155, 56) + SourceIndex(0) name (C11t5) +1->Emitted(98, 5) Source(155, 55) + SourceIndex(0) name (C11t5) +2 >Emitted(98, 17) Source(155, 56) + SourceIndex(0) name (C11t5) --- >>>})(); 1 > @@ -2513,21 +2380,21 @@ sourceFile:contextualTyping.ts 2 >} 3 > 4 > class C11t5 { constructor(f: (n: number) => IFoo) { } } -1 >Emitted(156, 1) Source(155, 55) + SourceIndex(0) name (C11t5) -2 >Emitted(156, 2) Source(155, 56) + SourceIndex(0) name (C11t5) -3 >Emitted(156, 2) Source(155, 1) + SourceIndex(0) -4 >Emitted(156, 6) Source(155, 56) + SourceIndex(0) +1 >Emitted(99, 1) Source(155, 55) + SourceIndex(0) name (C11t5) +2 >Emitted(99, 2) Source(155, 56) + SourceIndex(0) name (C11t5) +3 >Emitted(99, 2) Source(155, 1) + SourceIndex(0) +4 >Emitted(99, 6) Source(155, 56) + SourceIndex(0) --- >>>; 1 > 2 >^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > 2 >; -1 >Emitted(157, 1) Source(155, 56) + SourceIndex(0) -2 >Emitted(157, 2) Source(155, 57) + SourceIndex(0) +1 >Emitted(100, 1) Source(155, 56) + SourceIndex(0) +2 >Emitted(100, 2) Source(155, 57) + SourceIndex(0) --- ->>>var i = new C11t5(function (n) { +>>>var i = new C11t5(function (n) { return ({}); }); 1-> 2 >^^^^ 3 > ^ @@ -2537,6 +2404,17 @@ sourceFile:contextualTyping.ts 7 > ^ 8 > ^^^^^^^^^^ 9 > ^ +10> ^^^^ +11> ^^^^^^ +12> ^ +13> ^ +14> ^^ +15> ^ +16> ^ +17> ^ +18> ^ +19> ^ +20> ^ 1-> > 2 >var @@ -2547,138 +2425,118 @@ sourceFile:contextualTyping.ts 7 > ( 8 > function( 9 > n -1->Emitted(158, 1) Source(156, 1) + SourceIndex(0) -2 >Emitted(158, 5) Source(156, 5) + SourceIndex(0) -3 >Emitted(158, 6) Source(156, 6) + SourceIndex(0) -4 >Emitted(158, 9) Source(156, 9) + SourceIndex(0) -5 >Emitted(158, 13) Source(156, 13) + SourceIndex(0) -6 >Emitted(158, 18) Source(156, 18) + SourceIndex(0) -7 >Emitted(158, 19) Source(156, 19) + SourceIndex(0) -8 >Emitted(158, 29) Source(156, 28) + SourceIndex(0) -9 >Emitted(158, 30) Source(156, 29) + SourceIndex(0) ---- ->>> return ({}); -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(159, 5) Source(156, 33) + SourceIndex(0) -2 >Emitted(159, 11) Source(156, 39) + SourceIndex(0) -3 >Emitted(159, 12) Source(156, 46) + SourceIndex(0) -4 >Emitted(159, 13) Source(156, 47) + SourceIndex(0) -5 >Emitted(159, 15) Source(156, 49) + SourceIndex(0) -6 >Emitted(159, 16) Source(156, 50) + SourceIndex(0) -7 >Emitted(159, 17) Source(156, 50) + SourceIndex(0) ---- ->>>}); -1 > -2 >^ -3 > ^ -4 > ^ -5 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ) -4 > ; -1 >Emitted(160, 1) Source(156, 51) + SourceIndex(0) -2 >Emitted(160, 2) Source(156, 52) + SourceIndex(0) -3 >Emitted(160, 3) Source(156, 53) + SourceIndex(0) -4 >Emitted(160, 4) Source(156, 54) + SourceIndex(0) +10> ) { +11> return +12> +13> ( +14> {} +15> ) +16> +17> +18> } +19> ) +20> ; +1->Emitted(101, 1) Source(156, 1) + SourceIndex(0) +2 >Emitted(101, 5) Source(156, 5) + SourceIndex(0) +3 >Emitted(101, 6) Source(156, 6) + SourceIndex(0) +4 >Emitted(101, 9) Source(156, 9) + SourceIndex(0) +5 >Emitted(101, 13) Source(156, 13) + SourceIndex(0) +6 >Emitted(101, 18) Source(156, 18) + SourceIndex(0) +7 >Emitted(101, 19) Source(156, 19) + SourceIndex(0) +8 >Emitted(101, 29) Source(156, 28) + SourceIndex(0) +9 >Emitted(101, 30) Source(156, 29) + SourceIndex(0) +10>Emitted(101, 34) Source(156, 33) + SourceIndex(0) +11>Emitted(101, 40) Source(156, 39) + SourceIndex(0) +12>Emitted(101, 41) Source(156, 46) + SourceIndex(0) +13>Emitted(101, 42) Source(156, 47) + SourceIndex(0) +14>Emitted(101, 44) Source(156, 49) + SourceIndex(0) +15>Emitted(101, 45) Source(156, 50) + SourceIndex(0) +16>Emitted(101, 46) Source(156, 50) + SourceIndex(0) +17>Emitted(101, 47) Source(156, 51) + SourceIndex(0) +18>Emitted(101, 48) Source(156, 52) + SourceIndex(0) +19>Emitted(101, 49) Source(156, 53) + SourceIndex(0) +20>Emitted(101, 50) Source(156, 54) + SourceIndex(0) --- >>>// CONTEXT: Type annotated expression -1-> +1 > 2 > 3 >^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -1-> +4 > ^^^^^-> +1 > > >// CONTEXT: Type annotated expression > 2 > 3 >// CONTEXT: Type annotated expression -1->Emitted(161, 1) Source(159, 1) + SourceIndex(0) -2 >Emitted(161, 1) Source(158, 1) + SourceIndex(0) -3 >Emitted(161, 38) Source(158, 38) + SourceIndex(0) +1 >Emitted(102, 1) Source(159, 1) + SourceIndex(0) +2 >Emitted(102, 1) Source(158, 1) + SourceIndex(0) +3 >Emitted(102, 38) Source(158, 38) + SourceIndex(0) --- ->>>var c12t1 = (function (s) { -1 >^^^^ +>>>var c12t1 = (function (s) { return s; }); +1->^^^^ 2 > ^^^^^ 3 > ^^^ 4 > ^ 5 > ^^^^^^^^^^ 6 > ^ -1 > +7 > ^^^^ +8 > ^^^^^^ +9 > ^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^ +1-> >var 2 > c12t1 3 > = <(s: string) => string> 4 > ( 5 > function( 6 > s -1 >Emitted(162, 5) Source(159, 5) + SourceIndex(0) -2 >Emitted(162, 10) Source(159, 10) + SourceIndex(0) -3 >Emitted(162, 13) Source(159, 37) + SourceIndex(0) -4 >Emitted(162, 14) Source(159, 38) + SourceIndex(0) -5 >Emitted(162, 24) Source(159, 47) + SourceIndex(0) -6 >Emitted(162, 25) Source(159, 48) + SourceIndex(0) ---- ->>> return s; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > -1 >Emitted(163, 5) Source(159, 52) + SourceIndex(0) -2 >Emitted(163, 11) Source(159, 58) + SourceIndex(0) -3 >Emitted(163, 12) Source(159, 59) + SourceIndex(0) -4 >Emitted(163, 13) Source(159, 60) + SourceIndex(0) -5 >Emitted(163, 14) Source(159, 60) + SourceIndex(0) ---- ->>>}); -1 > -2 >^ -3 > ^ -4 > ^ -5 > ^^^^^^^^^^^^-> -1 > -2 >} -3 > ) -4 > ; -1 >Emitted(164, 1) Source(159, 61) + SourceIndex(0) -2 >Emitted(164, 2) Source(159, 62) + SourceIndex(0) -3 >Emitted(164, 3) Source(159, 63) + SourceIndex(0) -4 >Emitted(164, 4) Source(159, 64) + SourceIndex(0) +7 > ) { +8 > return +9 > +10> s +11> +12> +13> } +14> ) +15> ; +1->Emitted(103, 5) Source(159, 5) + SourceIndex(0) +2 >Emitted(103, 10) Source(159, 10) + SourceIndex(0) +3 >Emitted(103, 13) Source(159, 37) + SourceIndex(0) +4 >Emitted(103, 14) Source(159, 38) + SourceIndex(0) +5 >Emitted(103, 24) Source(159, 47) + SourceIndex(0) +6 >Emitted(103, 25) Source(159, 48) + SourceIndex(0) +7 >Emitted(103, 29) Source(159, 52) + SourceIndex(0) +8 >Emitted(103, 35) Source(159, 58) + SourceIndex(0) +9 >Emitted(103, 36) Source(159, 59) + SourceIndex(0) +10>Emitted(103, 37) Source(159, 60) + SourceIndex(0) +11>Emitted(103, 38) Source(159, 60) + SourceIndex(0) +12>Emitted(103, 39) Source(159, 61) + SourceIndex(0) +13>Emitted(103, 40) Source(159, 62) + SourceIndex(0) +14>Emitted(103, 41) Source(159, 63) + SourceIndex(0) +15>Emitted(103, 42) Source(159, 64) + SourceIndex(0) --- >>>var c12t2 = ({ -1-> +1 > 2 >^^^^ 3 > ^^^^^ 4 > ^^^ 5 > ^ -1-> +1 > > 2 >var 3 > c12t2 4 > = 5 > ( -1->Emitted(165, 1) Source(160, 1) + SourceIndex(0) -2 >Emitted(165, 5) Source(160, 5) + SourceIndex(0) -3 >Emitted(165, 10) Source(160, 10) + SourceIndex(0) -4 >Emitted(165, 13) Source(160, 20) + SourceIndex(0) -5 >Emitted(165, 14) Source(160, 21) + SourceIndex(0) +1 >Emitted(104, 1) Source(160, 1) + SourceIndex(0) +2 >Emitted(104, 5) Source(160, 5) + SourceIndex(0) +3 >Emitted(104, 10) Source(160, 10) + SourceIndex(0) +4 >Emitted(104, 13) Source(160, 20) + SourceIndex(0) +5 >Emitted(104, 14) Source(160, 21) + SourceIndex(0) --- >>> n: 1 1 >^^^^ @@ -2690,10 +2548,10 @@ sourceFile:contextualTyping.ts 2 > n 3 > : 4 > 1 -1 >Emitted(166, 5) Source(161, 5) + SourceIndex(0) -2 >Emitted(166, 6) Source(161, 6) + SourceIndex(0) -3 >Emitted(166, 8) Source(161, 8) + SourceIndex(0) -4 >Emitted(166, 9) Source(161, 9) + SourceIndex(0) +1 >Emitted(105, 5) Source(161, 5) + SourceIndex(0) +2 >Emitted(105, 6) Source(161, 6) + SourceIndex(0) +3 >Emitted(105, 8) Source(161, 8) + SourceIndex(0) +4 >Emitted(105, 9) Source(161, 9) + SourceIndex(0) --- >>>}); 1 >^ @@ -2704,9 +2562,9 @@ sourceFile:contextualTyping.ts >} 2 > ) 3 > ; -1 >Emitted(167, 2) Source(162, 2) + SourceIndex(0) -2 >Emitted(167, 3) Source(162, 3) + SourceIndex(0) -3 >Emitted(167, 4) Source(162, 4) + SourceIndex(0) +1 >Emitted(106, 2) Source(162, 2) + SourceIndex(0) +2 >Emitted(106, 3) Source(162, 3) + SourceIndex(0) +3 >Emitted(106, 4) Source(162, 4) + SourceIndex(0) --- >>>var c12t3 = []; 1-> @@ -2715,7 +2573,7 @@ sourceFile:contextualTyping.ts 4 > ^^^ 5 > ^^ 6 > ^ -7 > ^^^^^^^^^^^-> +7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >var @@ -2723,71 +2581,77 @@ sourceFile:contextualTyping.ts 4 > = 5 > [] 6 > ; -1->Emitted(168, 1) Source(163, 1) + SourceIndex(0) -2 >Emitted(168, 5) Source(163, 5) + SourceIndex(0) -3 >Emitted(168, 10) Source(163, 10) + SourceIndex(0) -4 >Emitted(168, 13) Source(163, 24) + SourceIndex(0) -5 >Emitted(168, 15) Source(163, 26) + SourceIndex(0) -6 >Emitted(168, 16) Source(163, 27) + SourceIndex(0) +1->Emitted(107, 1) Source(163, 1) + SourceIndex(0) +2 >Emitted(107, 5) Source(163, 5) + SourceIndex(0) +3 >Emitted(107, 10) Source(163, 10) + SourceIndex(0) +4 >Emitted(107, 13) Source(163, 24) + SourceIndex(0) +5 >Emitted(107, 15) Source(163, 26) + SourceIndex(0) +6 >Emitted(107, 16) Source(163, 27) + SourceIndex(0) --- ->>>var c12t4 = function () { +>>>var c12t4 = function () { return ({}); }; 1-> 2 >^^^^ 3 > ^^^^^ 4 > ^^^ -5 > ^^^^^-> +5 > ^^^^^^^^^^^^^^ +6 > ^^^^^^ +7 > ^ +8 > ^ +9 > ^^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^^-> 1-> > 2 >var 3 > c12t4 4 > = <() => IFoo> -1->Emitted(169, 1) Source(164, 1) + SourceIndex(0) -2 >Emitted(169, 5) Source(164, 5) + SourceIndex(0) -3 >Emitted(169, 10) Source(164, 10) + SourceIndex(0) -4 >Emitted(169, 13) Source(164, 26) + SourceIndex(0) +5 > function() { +6 > return +7 > +8 > ( +9 > {} +10> ) +11> +12> +13> } +14> ; +1->Emitted(108, 1) Source(164, 1) + SourceIndex(0) +2 >Emitted(108, 5) Source(164, 5) + SourceIndex(0) +3 >Emitted(108, 10) Source(164, 10) + SourceIndex(0) +4 >Emitted(108, 13) Source(164, 26) + SourceIndex(0) +5 >Emitted(108, 27) Source(164, 39) + SourceIndex(0) +6 >Emitted(108, 33) Source(164, 45) + SourceIndex(0) +7 >Emitted(108, 34) Source(164, 52) + SourceIndex(0) +8 >Emitted(108, 35) Source(164, 53) + SourceIndex(0) +9 >Emitted(108, 37) Source(164, 55) + SourceIndex(0) +10>Emitted(108, 38) Source(164, 56) + SourceIndex(0) +11>Emitted(108, 39) Source(164, 56) + SourceIndex(0) +12>Emitted(108, 40) Source(164, 57) + SourceIndex(0) +13>Emitted(108, 41) Source(164, 58) + SourceIndex(0) +14>Emitted(108, 42) Source(164, 59) + SourceIndex(0) --- ->>> return ({}); -1->^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1->function() { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1->Emitted(170, 5) Source(164, 39) + SourceIndex(0) -2 >Emitted(170, 11) Source(164, 45) + SourceIndex(0) -3 >Emitted(170, 12) Source(164, 52) + SourceIndex(0) -4 >Emitted(170, 13) Source(164, 53) + SourceIndex(0) -5 >Emitted(170, 15) Source(164, 55) + SourceIndex(0) -6 >Emitted(170, 16) Source(164, 56) + SourceIndex(0) -7 >Emitted(170, 17) Source(164, 56) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(171, 1) Source(164, 57) + SourceIndex(0) -2 >Emitted(171, 2) Source(164, 58) + SourceIndex(0) -3 >Emitted(171, 3) Source(164, 59) + SourceIndex(0) ---- ->>>var c12t5 = function (n) { +>>>var c12t5 = function (n) { return ({}); }; 1-> 2 >^^^^ 3 > ^^^^^ 4 > ^^^ 5 > ^^^^^^^^^^ 6 > ^ +7 > ^^^^ +8 > ^^^^^^ +9 > ^ +10> ^ +11> ^^ +12> ^ +13> ^ +14> ^ +15> ^ +16> ^ +17> ^^^^-> 1-> > 2 >var @@ -2795,49 +2659,34 @@ sourceFile:contextualTyping.ts 4 > = <(n: number) => IFoo> 5 > function( 6 > n -1->Emitted(172, 1) Source(165, 1) + SourceIndex(0) -2 >Emitted(172, 5) Source(165, 5) + SourceIndex(0) -3 >Emitted(172, 10) Source(165, 10) + SourceIndex(0) -4 >Emitted(172, 13) Source(165, 35) + SourceIndex(0) -5 >Emitted(172, 23) Source(165, 44) + SourceIndex(0) -6 >Emitted(172, 24) Source(165, 45) + SourceIndex(0) +7 > ) { +8 > return +9 > +10> ( +11> {} +12> ) +13> +14> +15> } +16> ; +1->Emitted(109, 1) Source(165, 1) + SourceIndex(0) +2 >Emitted(109, 5) Source(165, 5) + SourceIndex(0) +3 >Emitted(109, 10) Source(165, 10) + SourceIndex(0) +4 >Emitted(109, 13) Source(165, 35) + SourceIndex(0) +5 >Emitted(109, 23) Source(165, 44) + SourceIndex(0) +6 >Emitted(109, 24) Source(165, 45) + SourceIndex(0) +7 >Emitted(109, 28) Source(165, 49) + SourceIndex(0) +8 >Emitted(109, 34) Source(165, 55) + SourceIndex(0) +9 >Emitted(109, 35) Source(165, 62) + SourceIndex(0) +10>Emitted(109, 36) Source(165, 63) + SourceIndex(0) +11>Emitted(109, 38) Source(165, 65) + SourceIndex(0) +12>Emitted(109, 39) Source(165, 66) + SourceIndex(0) +13>Emitted(109, 40) Source(165, 66) + SourceIndex(0) +14>Emitted(109, 41) Source(165, 67) + SourceIndex(0) +15>Emitted(109, 42) Source(165, 68) + SourceIndex(0) +16>Emitted(109, 43) Source(165, 69) + SourceIndex(0) --- ->>> return ({}); -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(173, 5) Source(165, 49) + SourceIndex(0) -2 >Emitted(173, 11) Source(165, 55) + SourceIndex(0) -3 >Emitted(173, 12) Source(165, 62) + SourceIndex(0) -4 >Emitted(173, 13) Source(165, 63) + SourceIndex(0) -5 >Emitted(173, 15) Source(165, 65) + SourceIndex(0) -6 >Emitted(173, 16) Source(165, 66) + SourceIndex(0) -7 >Emitted(173, 17) Source(165, 66) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(174, 1) Source(165, 67) + SourceIndex(0) -2 >Emitted(174, 2) Source(165, 68) + SourceIndex(0) -3 >Emitted(174, 3) Source(165, 69) + SourceIndex(0) ---- ->>>var c12t6 = function (n, s) { +>>>var c12t6 = function (n, s) { return ({}); }; 1-> 2 >^^^^ 3 > ^^^^^ @@ -2846,6 +2695,16 @@ sourceFile:contextualTyping.ts 6 > ^ 7 > ^^ 8 > ^ +9 > ^^^^ +10> ^^^^^^ +11> ^ +12> ^ +13> ^^ +14> ^ +15> ^ +16> ^ +17> ^ +18> ^ 1-> > 2 >var @@ -2855,58 +2714,52 @@ sourceFile:contextualTyping.ts 6 > n 7 > , 8 > s -1->Emitted(175, 1) Source(166, 1) + SourceIndex(0) -2 >Emitted(175, 5) Source(166, 5) + SourceIndex(0) -3 >Emitted(175, 10) Source(166, 10) + SourceIndex(0) -4 >Emitted(175, 13) Source(166, 46) + SourceIndex(0) -5 >Emitted(175, 23) Source(166, 55) + SourceIndex(0) -6 >Emitted(175, 24) Source(166, 56) + SourceIndex(0) -7 >Emitted(175, 26) Source(166, 58) + SourceIndex(0) -8 >Emitted(175, 27) Source(166, 59) + SourceIndex(0) +9 > ) { +10> return +11> +12> ( +13> {} +14> ) +15> +16> +17> } +18> ; +1->Emitted(110, 1) Source(166, 1) + SourceIndex(0) +2 >Emitted(110, 5) Source(166, 5) + SourceIndex(0) +3 >Emitted(110, 10) Source(166, 10) + SourceIndex(0) +4 >Emitted(110, 13) Source(166, 46) + SourceIndex(0) +5 >Emitted(110, 23) Source(166, 55) + SourceIndex(0) +6 >Emitted(110, 24) Source(166, 56) + SourceIndex(0) +7 >Emitted(110, 26) Source(166, 58) + SourceIndex(0) +8 >Emitted(110, 27) Source(166, 59) + SourceIndex(0) +9 >Emitted(110, 31) Source(166, 63) + SourceIndex(0) +10>Emitted(110, 37) Source(166, 69) + SourceIndex(0) +11>Emitted(110, 38) Source(166, 76) + SourceIndex(0) +12>Emitted(110, 39) Source(166, 77) + SourceIndex(0) +13>Emitted(110, 41) Source(166, 79) + SourceIndex(0) +14>Emitted(110, 42) Source(166, 80) + SourceIndex(0) +15>Emitted(110, 43) Source(166, 80) + SourceIndex(0) +16>Emitted(110, 44) Source(166, 81) + SourceIndex(0) +17>Emitted(110, 45) Source(166, 82) + SourceIndex(0) +18>Emitted(110, 46) Source(166, 83) + SourceIndex(0) --- ->>> return ({}); -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^ -6 > ^ -7 > ^ -1 >) { -2 > return -3 > -4 > ( -5 > {} -6 > ) -7 > -1 >Emitted(176, 5) Source(166, 63) + SourceIndex(0) -2 >Emitted(176, 11) Source(166, 69) + SourceIndex(0) -3 >Emitted(176, 12) Source(166, 76) + SourceIndex(0) -4 >Emitted(176, 13) Source(166, 77) + SourceIndex(0) -5 >Emitted(176, 15) Source(166, 79) + SourceIndex(0) -6 >Emitted(176, 16) Source(166, 80) + SourceIndex(0) -7 >Emitted(176, 17) Source(166, 80) + SourceIndex(0) ---- ->>>}; +>>>var c12t7 = function (n) { return n; }; 1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(177, 1) Source(166, 81) + SourceIndex(0) -2 >Emitted(177, 2) Source(166, 82) + SourceIndex(0) -3 >Emitted(177, 3) Source(166, 83) + SourceIndex(0) ---- ->>>var c12t7 = function (n) { -1-> 2 >^^^^ 3 > ^^^^^ 4 > ^^^ 5 > ^^^^^^^^^^ 6 > ^ -1-> +7 > ^^^^ +8 > ^^^^^^ +9 > ^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ +15> ^-> +1 > > 2 >var 3 > c12t7 @@ -2916,49 +2769,44 @@ sourceFile:contextualTyping.ts > }> 5 > function( 6 > n:number -1->Emitted(178, 1) Source(167, 1) + SourceIndex(0) -2 >Emitted(178, 5) Source(167, 5) + SourceIndex(0) -3 >Emitted(178, 10) Source(167, 10) + SourceIndex(0) -4 >Emitted(178, 13) Source(170, 4) + SourceIndex(0) -5 >Emitted(178, 23) Source(170, 13) + SourceIndex(0) -6 >Emitted(178, 24) Source(170, 21) + SourceIndex(0) +7 > ) { +8 > return +9 > +10> n +11> +12> +13> } +14> ; +1 >Emitted(111, 1) Source(167, 1) + SourceIndex(0) +2 >Emitted(111, 5) Source(167, 5) + SourceIndex(0) +3 >Emitted(111, 10) Source(167, 10) + SourceIndex(0) +4 >Emitted(111, 13) Source(170, 4) + SourceIndex(0) +5 >Emitted(111, 23) Source(170, 13) + SourceIndex(0) +6 >Emitted(111, 24) Source(170, 21) + SourceIndex(0) +7 >Emitted(111, 28) Source(170, 25) + SourceIndex(0) +8 >Emitted(111, 34) Source(170, 31) + SourceIndex(0) +9 >Emitted(111, 35) Source(170, 32) + SourceIndex(0) +10>Emitted(111, 36) Source(170, 33) + SourceIndex(0) +11>Emitted(111, 37) Source(170, 33) + SourceIndex(0) +12>Emitted(111, 38) Source(170, 34) + SourceIndex(0) +13>Emitted(111, 39) Source(170, 35) + SourceIndex(0) +14>Emitted(111, 40) Source(170, 36) + SourceIndex(0) --- ->>> return n; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > n -5 > -1 >Emitted(179, 5) Source(170, 25) + SourceIndex(0) -2 >Emitted(179, 11) Source(170, 31) + SourceIndex(0) -3 >Emitted(179, 12) Source(170, 32) + SourceIndex(0) -4 >Emitted(179, 13) Source(170, 33) + SourceIndex(0) -5 >Emitted(179, 14) Source(170, 33) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(180, 1) Source(170, 34) + SourceIndex(0) -2 >Emitted(180, 2) Source(170, 35) + SourceIndex(0) -3 >Emitted(180, 3) Source(170, 36) + SourceIndex(0) ---- ->>>var c12t8 = function (n) { +>>>var c12t8 = function (n) { return n; }; 1-> 2 >^^^^ 3 > ^^^^^ 4 > ^^^ 5 > ^^^^^^^^^^ 6 > ^ +7 > ^^^^ +8 > ^^^^^^ +9 > ^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ 1-> > > @@ -2967,218 +2815,181 @@ sourceFile:contextualTyping.ts 4 > = <(n: number, s: string) => number> 5 > function( 6 > n -1->Emitted(181, 1) Source(172, 1) + SourceIndex(0) -2 >Emitted(181, 5) Source(172, 5) + SourceIndex(0) -3 >Emitted(181, 10) Source(172, 10) + SourceIndex(0) -4 >Emitted(181, 13) Source(172, 48) + SourceIndex(0) -5 >Emitted(181, 23) Source(172, 57) + SourceIndex(0) -6 >Emitted(181, 24) Source(172, 58) + SourceIndex(0) +7 > ) { +8 > return +9 > +10> n +11> ; +12> +13> } +14> ; +1->Emitted(112, 1) Source(172, 1) + SourceIndex(0) +2 >Emitted(112, 5) Source(172, 5) + SourceIndex(0) +3 >Emitted(112, 10) Source(172, 10) + SourceIndex(0) +4 >Emitted(112, 13) Source(172, 48) + SourceIndex(0) +5 >Emitted(112, 23) Source(172, 57) + SourceIndex(0) +6 >Emitted(112, 24) Source(172, 58) + SourceIndex(0) +7 >Emitted(112, 28) Source(172, 62) + SourceIndex(0) +8 >Emitted(112, 34) Source(172, 68) + SourceIndex(0) +9 >Emitted(112, 35) Source(172, 69) + SourceIndex(0) +10>Emitted(112, 36) Source(172, 70) + SourceIndex(0) +11>Emitted(112, 37) Source(172, 71) + SourceIndex(0) +12>Emitted(112, 38) Source(172, 72) + SourceIndex(0) +13>Emitted(112, 39) Source(172, 73) + SourceIndex(0) +14>Emitted(112, 40) Source(172, 74) + SourceIndex(0) --- ->>> return n; -1 >^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > n -5 > ; -1 >Emitted(182, 5) Source(172, 62) + SourceIndex(0) -2 >Emitted(182, 11) Source(172, 68) + SourceIndex(0) -3 >Emitted(182, 12) Source(172, 69) + SourceIndex(0) -4 >Emitted(182, 13) Source(172, 70) + SourceIndex(0) -5 >Emitted(182, 14) Source(172, 71) + SourceIndex(0) ---- ->>>}; +>>>var c12t9 = [[], []]; 1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^-> -1 > -2 >} -3 > ; -1 >Emitted(183, 1) Source(172, 72) + SourceIndex(0) -2 >Emitted(183, 2) Source(172, 73) + SourceIndex(0) -3 >Emitted(183, 3) Source(172, 74) + SourceIndex(0) ---- ->>>var c12t9 = [ -1-> 2 >^^^^ 3 > ^^^^^ 4 > ^^^ -1-> +5 > ^ +6 > ^^ +7 > ^^ +8 > ^^ +9 > ^ +10> ^ +11> ^^^^^^-> +1 > > 2 >var 3 > c12t9 4 > = -1->Emitted(184, 1) Source(173, 1) + SourceIndex(0) -2 >Emitted(184, 5) Source(173, 5) + SourceIndex(0) -3 >Emitted(184, 10) Source(173, 10) + SourceIndex(0) -4 >Emitted(184, 13) Source(173, 26) + SourceIndex(0) +5 > [ +6 > [] +7 > , +8 > [] +9 > ] +10> ; +1 >Emitted(113, 1) Source(173, 1) + SourceIndex(0) +2 >Emitted(113, 5) Source(173, 5) + SourceIndex(0) +3 >Emitted(113, 10) Source(173, 10) + SourceIndex(0) +4 >Emitted(113, 13) Source(173, 26) + SourceIndex(0) +5 >Emitted(113, 14) Source(173, 27) + SourceIndex(0) +6 >Emitted(113, 16) Source(173, 29) + SourceIndex(0) +7 >Emitted(113, 18) Source(173, 30) + SourceIndex(0) +8 >Emitted(113, 20) Source(173, 32) + SourceIndex(0) +9 >Emitted(113, 21) Source(173, 33) + SourceIndex(0) +10>Emitted(113, 22) Source(173, 34) + SourceIndex(0) --- ->>> [], -1 >^^^^ -2 > ^^ -3 > ^-> -1 >[ -2 > [] -1 >Emitted(185, 5) Source(173, 27) + SourceIndex(0) -2 >Emitted(185, 7) Source(173, 29) + SourceIndex(0) ---- ->>> [] -1->^^^^ -2 > ^^ -1->, -2 > [] -1->Emitted(186, 5) Source(173, 30) + SourceIndex(0) -2 >Emitted(186, 7) Source(173, 32) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(187, 2) Source(173, 33) + SourceIndex(0) -2 >Emitted(187, 3) Source(173, 34) + SourceIndex(0) ---- ->>>var c12t10 = [ +>>>var c12t10 = [({}), ({})]; 1-> 2 >^^^^ 3 > ^^^^^^ 4 > ^^^ +5 > ^ +6 > ^ +7 > ^^ +8 > ^ +9 > ^^ +10> ^ +11> ^^ +12> ^ +13> ^ +14> ^ +15> ^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >var 3 > c12t10 4 > = -1->Emitted(188, 1) Source(174, 1) + SourceIndex(0) -2 >Emitted(188, 5) Source(174, 5) + SourceIndex(0) -3 >Emitted(188, 11) Source(174, 11) + SourceIndex(0) -4 >Emitted(188, 14) Source(174, 23) + SourceIndex(0) +5 > [ +6 > ( +7 > {} +8 > ) +9 > , +10> ( +11> {} +12> ) +13> ] +14> ; +1->Emitted(114, 1) Source(174, 1) + SourceIndex(0) +2 >Emitted(114, 5) Source(174, 5) + SourceIndex(0) +3 >Emitted(114, 11) Source(174, 11) + SourceIndex(0) +4 >Emitted(114, 14) Source(174, 23) + SourceIndex(0) +5 >Emitted(114, 15) Source(174, 30) + SourceIndex(0) +6 >Emitted(114, 16) Source(174, 31) + SourceIndex(0) +7 >Emitted(114, 18) Source(174, 33) + SourceIndex(0) +8 >Emitted(114, 19) Source(174, 34) + SourceIndex(0) +9 >Emitted(114, 21) Source(174, 41) + SourceIndex(0) +10>Emitted(114, 22) Source(174, 42) + SourceIndex(0) +11>Emitted(114, 24) Source(174, 44) + SourceIndex(0) +12>Emitted(114, 25) Source(174, 45) + SourceIndex(0) +13>Emitted(114, 26) Source(174, 46) + SourceIndex(0) +14>Emitted(114, 27) Source(174, 47) + SourceIndex(0) --- ->>> ({}), -1 >^^^^ -2 > ^ -3 > ^^ -4 > ^ -5 > ^-> -1 >[ -2 > ( -3 > {} -4 > ) -1 >Emitted(189, 5) Source(174, 30) + SourceIndex(0) -2 >Emitted(189, 6) Source(174, 31) + SourceIndex(0) -3 >Emitted(189, 8) Source(174, 33) + SourceIndex(0) -4 >Emitted(189, 9) Source(174, 34) + SourceIndex(0) ---- ->>> ({}) -1->^^^^ -2 > ^ -3 > ^^ -4 > ^ -1->, -2 > ( -3 > {} -4 > ) -1->Emitted(190, 5) Source(174, 41) + SourceIndex(0) -2 >Emitted(190, 6) Source(174, 42) + SourceIndex(0) -3 >Emitted(190, 8) Source(174, 44) + SourceIndex(0) -4 >Emitted(190, 9) Source(174, 45) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(191, 2) Source(174, 46) + SourceIndex(0) -2 >Emitted(191, 3) Source(174, 47) + SourceIndex(0) ---- ->>>var c12t11 = [ +>>>var c12t11 = [function (n, s) { return s; }]; 1-> 2 >^^^^ 3 > ^^^^^^ 4 > ^^^ -5 > ^^^^^^^^^-> +5 > ^ +6 > ^^^^^^^^^^ +7 > ^ +8 > ^^ +9 > ^ +10> ^^^^ +11> ^^^^^^ +12> ^ +13> ^ +14> ^ +15> ^ +16> ^ +17> ^ +18> ^ 1-> > 2 >var 3 > c12t11 4 > = <{(n: number, s: string): string;}[]> -1->Emitted(192, 1) Source(175, 1) + SourceIndex(0) -2 >Emitted(192, 5) Source(175, 5) + SourceIndex(0) -3 >Emitted(192, 11) Source(175, 11) + SourceIndex(0) -4 >Emitted(192, 14) Source(175, 52) + SourceIndex(0) ---- ->>> function (n, s) { -1->^^^^ -2 > ^^^^^^^^^^ -3 > ^ -4 > ^^ -5 > ^ -1->[ -2 > function( -3 > n -4 > , -5 > s -1->Emitted(193, 5) Source(175, 53) + SourceIndex(0) -2 >Emitted(193, 15) Source(175, 62) + SourceIndex(0) -3 >Emitted(193, 16) Source(175, 63) + SourceIndex(0) -4 >Emitted(193, 18) Source(175, 65) + SourceIndex(0) -5 >Emitted(193, 19) Source(175, 66) + SourceIndex(0) ---- ->>> return s; -1 >^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > ; -1 >Emitted(194, 9) Source(175, 70) + SourceIndex(0) -2 >Emitted(194, 15) Source(175, 76) + SourceIndex(0) -3 >Emitted(194, 16) Source(175, 77) + SourceIndex(0) -4 >Emitted(194, 17) Source(175, 78) + SourceIndex(0) -5 >Emitted(194, 18) Source(175, 79) + SourceIndex(0) ---- ->>> } -1 >^^^^ -2 > ^ -1 > -2 > } -1 >Emitted(195, 5) Source(175, 80) + SourceIndex(0) -2 >Emitted(195, 6) Source(175, 81) + SourceIndex(0) ---- ->>>]; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^^-> -1 >] -2 > ; -1 >Emitted(196, 2) Source(175, 82) + SourceIndex(0) -2 >Emitted(196, 3) Source(175, 83) + SourceIndex(0) +5 > [ +6 > function( +7 > n +8 > , +9 > s +10> ) { +11> return +12> +13> s +14> ; +15> +16> } +17> ] +18> ; +1->Emitted(115, 1) Source(175, 1) + SourceIndex(0) +2 >Emitted(115, 5) Source(175, 5) + SourceIndex(0) +3 >Emitted(115, 11) Source(175, 11) + SourceIndex(0) +4 >Emitted(115, 14) Source(175, 52) + SourceIndex(0) +5 >Emitted(115, 15) Source(175, 53) + SourceIndex(0) +6 >Emitted(115, 25) Source(175, 62) + SourceIndex(0) +7 >Emitted(115, 26) Source(175, 63) + SourceIndex(0) +8 >Emitted(115, 28) Source(175, 65) + SourceIndex(0) +9 >Emitted(115, 29) Source(175, 66) + SourceIndex(0) +10>Emitted(115, 33) Source(175, 70) + SourceIndex(0) +11>Emitted(115, 39) Source(175, 76) + SourceIndex(0) +12>Emitted(115, 40) Source(175, 77) + SourceIndex(0) +13>Emitted(115, 41) Source(175, 78) + SourceIndex(0) +14>Emitted(115, 42) Source(175, 79) + SourceIndex(0) +15>Emitted(115, 43) Source(175, 80) + SourceIndex(0) +16>Emitted(115, 44) Source(175, 81) + SourceIndex(0) +17>Emitted(115, 45) Source(175, 82) + SourceIndex(0) +18>Emitted(115, 46) Source(175, 83) + SourceIndex(0) --- >>>var c12t12 = { -1-> +1 > 2 >^^^^ 3 > ^^^^^^ 4 > ^^^ 5 > ^-> -1-> +1 > > 2 >var 3 > c12t12 4 > = -1->Emitted(197, 1) Source(176, 1) + SourceIndex(0) -2 >Emitted(197, 5) Source(176, 5) + SourceIndex(0) -3 >Emitted(197, 11) Source(176, 11) + SourceIndex(0) -4 >Emitted(197, 14) Source(176, 21) + SourceIndex(0) +1 >Emitted(116, 1) Source(176, 1) + SourceIndex(0) +2 >Emitted(116, 5) Source(176, 5) + SourceIndex(0) +3 >Emitted(116, 11) Source(176, 11) + SourceIndex(0) +4 >Emitted(116, 14) Source(176, 21) + SourceIndex(0) --- >>> foo: ({}) 1->^^^^ @@ -3194,12 +3005,12 @@ sourceFile:contextualTyping.ts 4 > ( 5 > {} 6 > ) -1->Emitted(198, 5) Source(177, 5) + SourceIndex(0) -2 >Emitted(198, 8) Source(177, 8) + SourceIndex(0) -3 >Emitted(198, 10) Source(177, 16) + SourceIndex(0) -4 >Emitted(198, 11) Source(177, 17) + SourceIndex(0) -5 >Emitted(198, 13) Source(177, 19) + SourceIndex(0) -6 >Emitted(198, 14) Source(177, 20) + SourceIndex(0) +1->Emitted(117, 5) Source(177, 5) + SourceIndex(0) +2 >Emitted(117, 8) Source(177, 8) + SourceIndex(0) +3 >Emitted(117, 10) Source(177, 16) + SourceIndex(0) +4 >Emitted(117, 11) Source(177, 17) + SourceIndex(0) +5 >Emitted(117, 13) Source(177, 19) + SourceIndex(0) +6 >Emitted(117, 14) Source(177, 20) + SourceIndex(0) --- >>>}; 1 >^ @@ -3208,8 +3019,8 @@ sourceFile:contextualTyping.ts 1 > >} 2 > -1 >Emitted(199, 2) Source(178, 2) + SourceIndex(0) -2 >Emitted(199, 3) Source(178, 2) + SourceIndex(0) +1 >Emitted(118, 2) Source(178, 2) + SourceIndex(0) +2 >Emitted(118, 3) Source(178, 2) + SourceIndex(0) --- >>>var c12t13 = ({ 1-> @@ -3217,20 +3028,20 @@ sourceFile:contextualTyping.ts 3 > ^^^^^^ 4 > ^^^ 5 > ^ -6 > ^^^^^^^^^^^-> +6 > ^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >var 3 > c12t13 4 > = 5 > ( -1->Emitted(200, 1) Source(179, 1) + SourceIndex(0) -2 >Emitted(200, 5) Source(179, 5) + SourceIndex(0) -3 >Emitted(200, 11) Source(179, 11) + SourceIndex(0) -4 >Emitted(200, 14) Source(179, 21) + SourceIndex(0) -5 >Emitted(200, 15) Source(179, 22) + SourceIndex(0) +1->Emitted(119, 1) Source(179, 1) + SourceIndex(0) +2 >Emitted(119, 5) Source(179, 5) + SourceIndex(0) +3 >Emitted(119, 11) Source(179, 11) + SourceIndex(0) +4 >Emitted(119, 14) Source(179, 21) + SourceIndex(0) +5 >Emitted(119, 15) Source(179, 22) + SourceIndex(0) --- ->>> f: function (i, s) { +>>> f: function (i, s) { return s; } 1->^^^^ 2 > ^ 3 > ^^ @@ -3238,6 +3049,13 @@ sourceFile:contextualTyping.ts 5 > ^ 6 > ^^ 7 > ^ +8 > ^^^^ +9 > ^^^^^^ +10> ^ +11> ^ +12> ^ +13> ^ +14> ^ 1->{ > 2 > f @@ -3246,38 +3064,27 @@ sourceFile:contextualTyping.ts 5 > i 6 > , 7 > s -1->Emitted(201, 5) Source(180, 5) + SourceIndex(0) -2 >Emitted(201, 6) Source(180, 6) + SourceIndex(0) -3 >Emitted(201, 8) Source(180, 8) + SourceIndex(0) -4 >Emitted(201, 18) Source(180, 17) + SourceIndex(0) -5 >Emitted(201, 19) Source(180, 18) + SourceIndex(0) -6 >Emitted(201, 21) Source(180, 20) + SourceIndex(0) -7 >Emitted(201, 22) Source(180, 21) + SourceIndex(0) ---- ->>> return s; -1 >^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^ -1 >) { -2 > return -3 > -4 > s -5 > ; -1 >Emitted(202, 9) Source(180, 25) + SourceIndex(0) -2 >Emitted(202, 15) Source(180, 31) + SourceIndex(0) -3 >Emitted(202, 16) Source(180, 32) + SourceIndex(0) -4 >Emitted(202, 17) Source(180, 33) + SourceIndex(0) -5 >Emitted(202, 18) Source(180, 34) + SourceIndex(0) ---- ->>> } -1 >^^^^ -2 > ^ -1 > -2 > } -1 >Emitted(203, 5) Source(180, 35) + SourceIndex(0) -2 >Emitted(203, 6) Source(180, 36) + SourceIndex(0) +8 > ) { +9 > return +10> +11> s +12> ; +13> +14> } +1->Emitted(120, 5) Source(180, 5) + SourceIndex(0) +2 >Emitted(120, 6) Source(180, 6) + SourceIndex(0) +3 >Emitted(120, 8) Source(180, 8) + SourceIndex(0) +4 >Emitted(120, 18) Source(180, 17) + SourceIndex(0) +5 >Emitted(120, 19) Source(180, 18) + SourceIndex(0) +6 >Emitted(120, 21) Source(180, 20) + SourceIndex(0) +7 >Emitted(120, 22) Source(180, 21) + SourceIndex(0) +8 >Emitted(120, 26) Source(180, 25) + SourceIndex(0) +9 >Emitted(120, 32) Source(180, 31) + SourceIndex(0) +10>Emitted(120, 33) Source(180, 32) + SourceIndex(0) +11>Emitted(120, 34) Source(180, 33) + SourceIndex(0) +12>Emitted(120, 35) Source(180, 34) + SourceIndex(0) +13>Emitted(120, 36) Source(180, 35) + SourceIndex(0) +14>Emitted(120, 37) Source(180, 36) + SourceIndex(0) --- >>>}); 1 >^ @@ -3288,9 +3095,9 @@ sourceFile:contextualTyping.ts >} 2 > ) 3 > -1 >Emitted(204, 2) Source(181, 2) + SourceIndex(0) -2 >Emitted(204, 3) Source(181, 3) + SourceIndex(0) -3 >Emitted(204, 4) Source(181, 3) + SourceIndex(0) +1 >Emitted(121, 2) Source(181, 2) + SourceIndex(0) +2 >Emitted(121, 3) Source(181, 3) + SourceIndex(0) +3 >Emitted(121, 4) Source(181, 3) + SourceIndex(0) --- >>>var c12t14 = ({ 1-> @@ -3304,11 +3111,11 @@ sourceFile:contextualTyping.ts 3 > c12t14 4 > = 5 > ( -1->Emitted(205, 1) Source(182, 1) + SourceIndex(0) -2 >Emitted(205, 5) Source(182, 5) + SourceIndex(0) -3 >Emitted(205, 11) Source(182, 11) + SourceIndex(0) -4 >Emitted(205, 14) Source(182, 21) + SourceIndex(0) -5 >Emitted(205, 15) Source(182, 22) + SourceIndex(0) +1->Emitted(122, 1) Source(182, 1) + SourceIndex(0) +2 >Emitted(122, 5) Source(182, 5) + SourceIndex(0) +3 >Emitted(122, 11) Source(182, 11) + SourceIndex(0) +4 >Emitted(122, 14) Source(182, 21) + SourceIndex(0) +5 >Emitted(122, 15) Source(182, 22) + SourceIndex(0) --- >>> a: [] 1 >^^^^ @@ -3320,31 +3127,39 @@ sourceFile:contextualTyping.ts 2 > a 3 > : 4 > [] -1 >Emitted(206, 5) Source(183, 5) + SourceIndex(0) -2 >Emitted(206, 6) Source(183, 6) + SourceIndex(0) -3 >Emitted(206, 8) Source(183, 8) + SourceIndex(0) -4 >Emitted(206, 10) Source(183, 10) + SourceIndex(0) +1 >Emitted(123, 5) Source(183, 5) + SourceIndex(0) +2 >Emitted(123, 6) Source(183, 6) + SourceIndex(0) +3 >Emitted(123, 8) Source(183, 8) + SourceIndex(0) +4 >Emitted(123, 10) Source(183, 10) + SourceIndex(0) --- >>>}); 1 >^ 2 > ^ 3 > ^ -4 > ^^^^^^^^^^^^^^^^^^-> +4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > >} 2 > ) 3 > -1 >Emitted(207, 2) Source(184, 2) + SourceIndex(0) -2 >Emitted(207, 3) Source(184, 3) + SourceIndex(0) -3 >Emitted(207, 4) Source(184, 3) + SourceIndex(0) +1 >Emitted(124, 2) Source(184, 2) + SourceIndex(0) +2 >Emitted(124, 3) Source(184, 3) + SourceIndex(0) +3 >Emitted(124, 4) Source(184, 3) + SourceIndex(0) --- ->>>function EF1(a, b) { +>>>function EF1(a, b) { return a + b; } 1-> 2 >^^^^^^^^^^^^^ 3 > ^ 4 > ^^ 5 > ^ -6 > ^-> +6 > ^^^^ +7 > ^^^^^^ +8 > ^ +9 > ^ +10> ^^^ +11> ^ +12> ^ +13> ^ +14> ^ 1-> > >// CONTEXT: Contextual typing declarations @@ -3357,46 +3172,32 @@ sourceFile:contextualTyping.ts 3 > a 4 > , 5 > b -1->Emitted(208, 1) Source(191, 1) + SourceIndex(0) -2 >Emitted(208, 14) Source(191, 14) + SourceIndex(0) -3 >Emitted(208, 15) Source(191, 15) + SourceIndex(0) -4 >Emitted(208, 17) Source(191, 16) + SourceIndex(0) -5 >Emitted(208, 18) Source(191, 17) + SourceIndex(0) ---- ->>> return a + b; -1->^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^ -5 > ^^^ -6 > ^ -7 > ^ -1->) { -2 > return -3 > -4 > a -5 > + -6 > b -7 > ; -1->Emitted(209, 5) Source(191, 21) + SourceIndex(0) name (EF1) -2 >Emitted(209, 11) Source(191, 27) + SourceIndex(0) name (EF1) -3 >Emitted(209, 12) Source(191, 28) + SourceIndex(0) name (EF1) -4 >Emitted(209, 13) Source(191, 29) + SourceIndex(0) name (EF1) -5 >Emitted(209, 16) Source(191, 30) + SourceIndex(0) name (EF1) -6 >Emitted(209, 17) Source(191, 31) + SourceIndex(0) name (EF1) -7 >Emitted(209, 18) Source(191, 32) + SourceIndex(0) name (EF1) ---- ->>>} -1 > -2 >^ -3 > ^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >} -1 >Emitted(210, 1) Source(191, 33) + SourceIndex(0) name (EF1) -2 >Emitted(210, 2) Source(191, 34) + SourceIndex(0) name (EF1) +6 > ) { +7 > return +8 > +9 > a +10> + +11> b +12> ; +13> +14> } +1->Emitted(125, 1) Source(191, 1) + SourceIndex(0) +2 >Emitted(125, 14) Source(191, 14) + SourceIndex(0) +3 >Emitted(125, 15) Source(191, 15) + SourceIndex(0) +4 >Emitted(125, 17) Source(191, 16) + SourceIndex(0) +5 >Emitted(125, 18) Source(191, 17) + SourceIndex(0) +6 >Emitted(125, 22) Source(191, 21) + SourceIndex(0) name (EF1) +7 >Emitted(125, 28) Source(191, 27) + SourceIndex(0) name (EF1) +8 >Emitted(125, 29) Source(191, 28) + SourceIndex(0) name (EF1) +9 >Emitted(125, 30) Source(191, 29) + SourceIndex(0) name (EF1) +10>Emitted(125, 33) Source(191, 30) + SourceIndex(0) name (EF1) +11>Emitted(125, 34) Source(191, 31) + SourceIndex(0) name (EF1) +12>Emitted(125, 35) Source(191, 32) + SourceIndex(0) name (EF1) +13>Emitted(125, 36) Source(191, 33) + SourceIndex(0) name (EF1) +14>Emitted(125, 37) Source(191, 34) + SourceIndex(0) name (EF1) --- >>>var efv = EF1(1, 2); -1-> +1 > 2 >^^^^ 3 > ^^^ 4 > ^^^ @@ -3408,7 +3209,7 @@ sourceFile:contextualTyping.ts 10> ^ 11> ^ 12> ^^^-> -1-> +1 > > > 2 >var @@ -3421,17 +3222,17 @@ sourceFile:contextualTyping.ts 9 > 2 10> ) 11> ; -1->Emitted(211, 1) Source(193, 1) + SourceIndex(0) -2 >Emitted(211, 5) Source(193, 5) + SourceIndex(0) -3 >Emitted(211, 8) Source(193, 8) + SourceIndex(0) -4 >Emitted(211, 11) Source(193, 11) + SourceIndex(0) -5 >Emitted(211, 14) Source(193, 14) + SourceIndex(0) -6 >Emitted(211, 15) Source(193, 15) + SourceIndex(0) -7 >Emitted(211, 16) Source(193, 16) + SourceIndex(0) -8 >Emitted(211, 18) Source(193, 17) + SourceIndex(0) -9 >Emitted(211, 19) Source(193, 18) + SourceIndex(0) -10>Emitted(211, 20) Source(193, 19) + SourceIndex(0) -11>Emitted(211, 21) Source(193, 20) + SourceIndex(0) +1 >Emitted(126, 1) Source(193, 1) + SourceIndex(0) +2 >Emitted(126, 5) Source(193, 5) + SourceIndex(0) +3 >Emitted(126, 8) Source(193, 8) + SourceIndex(0) +4 >Emitted(126, 11) Source(193, 11) + SourceIndex(0) +5 >Emitted(126, 14) Source(193, 14) + SourceIndex(0) +6 >Emitted(126, 15) Source(193, 15) + SourceIndex(0) +7 >Emitted(126, 16) Source(193, 16) + SourceIndex(0) +8 >Emitted(126, 18) Source(193, 17) + SourceIndex(0) +9 >Emitted(126, 19) Source(193, 18) + SourceIndex(0) +10>Emitted(126, 20) Source(193, 19) + SourceIndex(0) +11>Emitted(126, 21) Source(193, 20) + SourceIndex(0) --- >>>function Point(x, y) { 1-> @@ -3458,11 +3259,11 @@ sourceFile:contextualTyping.ts 3 > x 4 > , 5 > y -1->Emitted(212, 1) Source(207, 1) + SourceIndex(0) -2 >Emitted(212, 16) Source(207, 16) + SourceIndex(0) -3 >Emitted(212, 17) Source(207, 17) + SourceIndex(0) -4 >Emitted(212, 19) Source(207, 19) + SourceIndex(0) -5 >Emitted(212, 20) Source(207, 20) + SourceIndex(0) +1->Emitted(127, 1) Source(207, 1) + SourceIndex(0) +2 >Emitted(127, 16) Source(207, 16) + SourceIndex(0) +3 >Emitted(127, 17) Source(207, 17) + SourceIndex(0) +4 >Emitted(127, 19) Source(207, 19) + SourceIndex(0) +5 >Emitted(127, 20) Source(207, 20) + SourceIndex(0) --- >>> this.x = x; 1 >^^^^ @@ -3481,13 +3282,13 @@ sourceFile:contextualTyping.ts 5 > = 6 > x 7 > ; -1 >Emitted(213, 5) Source(208, 5) + SourceIndex(0) name (Point) -2 >Emitted(213, 9) Source(208, 9) + SourceIndex(0) name (Point) -3 >Emitted(213, 10) Source(208, 10) + SourceIndex(0) name (Point) -4 >Emitted(213, 11) Source(208, 11) + SourceIndex(0) name (Point) -5 >Emitted(213, 14) Source(208, 14) + SourceIndex(0) name (Point) -6 >Emitted(213, 15) Source(208, 15) + SourceIndex(0) name (Point) -7 >Emitted(213, 16) Source(208, 16) + SourceIndex(0) name (Point) +1 >Emitted(128, 5) Source(208, 5) + SourceIndex(0) name (Point) +2 >Emitted(128, 9) Source(208, 9) + SourceIndex(0) name (Point) +3 >Emitted(128, 10) Source(208, 10) + SourceIndex(0) name (Point) +4 >Emitted(128, 11) Source(208, 11) + SourceIndex(0) name (Point) +5 >Emitted(128, 14) Source(208, 14) + SourceIndex(0) name (Point) +6 >Emitted(128, 15) Source(208, 15) + SourceIndex(0) name (Point) +7 >Emitted(128, 16) Source(208, 16) + SourceIndex(0) name (Point) --- >>> this.y = y; 1->^^^^ @@ -3506,13 +3307,13 @@ sourceFile:contextualTyping.ts 5 > = 6 > y 7 > ; -1->Emitted(214, 5) Source(209, 5) + SourceIndex(0) name (Point) -2 >Emitted(214, 9) Source(209, 9) + SourceIndex(0) name (Point) -3 >Emitted(214, 10) Source(209, 10) + SourceIndex(0) name (Point) -4 >Emitted(214, 11) Source(209, 11) + SourceIndex(0) name (Point) -5 >Emitted(214, 14) Source(209, 14) + SourceIndex(0) name (Point) -6 >Emitted(214, 15) Source(209, 15) + SourceIndex(0) name (Point) -7 >Emitted(214, 16) Source(209, 16) + SourceIndex(0) name (Point) +1->Emitted(129, 5) Source(209, 5) + SourceIndex(0) name (Point) +2 >Emitted(129, 9) Source(209, 9) + SourceIndex(0) name (Point) +3 >Emitted(129, 10) Source(209, 10) + SourceIndex(0) name (Point) +4 >Emitted(129, 11) Source(209, 11) + SourceIndex(0) name (Point) +5 >Emitted(129, 14) Source(209, 14) + SourceIndex(0) name (Point) +6 >Emitted(129, 15) Source(209, 15) + SourceIndex(0) name (Point) +7 >Emitted(129, 16) Source(209, 16) + SourceIndex(0) name (Point) --- >>> return this; 1->^^^^ @@ -3527,11 +3328,11 @@ sourceFile:contextualTyping.ts 3 > 4 > this 5 > ; -1->Emitted(215, 5) Source(211, 5) + SourceIndex(0) name (Point) -2 >Emitted(215, 11) Source(211, 11) + SourceIndex(0) name (Point) -3 >Emitted(215, 12) Source(211, 12) + SourceIndex(0) name (Point) -4 >Emitted(215, 16) Source(211, 16) + SourceIndex(0) name (Point) -5 >Emitted(215, 17) Source(211, 17) + SourceIndex(0) name (Point) +1->Emitted(130, 5) Source(211, 5) + SourceIndex(0) name (Point) +2 >Emitted(130, 11) Source(211, 11) + SourceIndex(0) name (Point) +3 >Emitted(130, 12) Source(211, 12) + SourceIndex(0) name (Point) +4 >Emitted(130, 16) Source(211, 16) + SourceIndex(0) name (Point) +5 >Emitted(130, 17) Source(211, 17) + SourceIndex(0) name (Point) --- >>>} 1 > @@ -3540,8 +3341,8 @@ sourceFile:contextualTyping.ts 1 > > 2 >} -1 >Emitted(216, 1) Source(212, 1) + SourceIndex(0) name (Point) -2 >Emitted(216, 2) Source(212, 2) + SourceIndex(0) name (Point) +1 >Emitted(131, 1) Source(212, 1) + SourceIndex(0) name (Point) +2 >Emitted(131, 2) Source(212, 2) + SourceIndex(0) name (Point) --- >>>Point.origin = new Point(0, 0); 1-> @@ -3573,19 +3374,19 @@ sourceFile:contextualTyping.ts 11> 0 12> ) 13> ; -1->Emitted(217, 1) Source(214, 1) + SourceIndex(0) -2 >Emitted(217, 6) Source(214, 6) + SourceIndex(0) -3 >Emitted(217, 7) Source(214, 7) + SourceIndex(0) -4 >Emitted(217, 13) Source(214, 13) + SourceIndex(0) -5 >Emitted(217, 16) Source(214, 16) + SourceIndex(0) -6 >Emitted(217, 20) Source(214, 20) + SourceIndex(0) -7 >Emitted(217, 25) Source(214, 25) + SourceIndex(0) -8 >Emitted(217, 26) Source(214, 26) + SourceIndex(0) -9 >Emitted(217, 27) Source(214, 27) + SourceIndex(0) -10>Emitted(217, 29) Source(214, 29) + SourceIndex(0) -11>Emitted(217, 30) Source(214, 30) + SourceIndex(0) -12>Emitted(217, 31) Source(214, 31) + SourceIndex(0) -13>Emitted(217, 32) Source(214, 32) + SourceIndex(0) +1->Emitted(132, 1) Source(214, 1) + SourceIndex(0) +2 >Emitted(132, 6) Source(214, 6) + SourceIndex(0) +3 >Emitted(132, 7) Source(214, 7) + SourceIndex(0) +4 >Emitted(132, 13) Source(214, 13) + SourceIndex(0) +5 >Emitted(132, 16) Source(214, 16) + SourceIndex(0) +6 >Emitted(132, 20) Source(214, 20) + SourceIndex(0) +7 >Emitted(132, 25) Source(214, 25) + SourceIndex(0) +8 >Emitted(132, 26) Source(214, 26) + SourceIndex(0) +9 >Emitted(132, 27) Source(214, 27) + SourceIndex(0) +10>Emitted(132, 29) Source(214, 29) + SourceIndex(0) +11>Emitted(132, 30) Source(214, 30) + SourceIndex(0) +12>Emitted(132, 31) Source(214, 31) + SourceIndex(0) +13>Emitted(132, 32) Source(214, 32) + SourceIndex(0) --- >>>Point.prototype.add = function (dx, dy) { 1-> @@ -3613,17 +3414,17 @@ sourceFile:contextualTyping.ts 9 > dx 10> , 11> dy -1->Emitted(218, 1) Source(216, 1) + SourceIndex(0) -2 >Emitted(218, 6) Source(216, 6) + SourceIndex(0) -3 >Emitted(218, 7) Source(216, 7) + SourceIndex(0) -4 >Emitted(218, 16) Source(216, 16) + SourceIndex(0) -5 >Emitted(218, 17) Source(216, 17) + SourceIndex(0) -6 >Emitted(218, 20) Source(216, 20) + SourceIndex(0) -7 >Emitted(218, 23) Source(216, 23) + SourceIndex(0) -8 >Emitted(218, 33) Source(216, 32) + SourceIndex(0) -9 >Emitted(218, 35) Source(216, 34) + SourceIndex(0) -10>Emitted(218, 37) Source(216, 36) + SourceIndex(0) -11>Emitted(218, 39) Source(216, 38) + SourceIndex(0) +1->Emitted(133, 1) Source(216, 1) + SourceIndex(0) +2 >Emitted(133, 6) Source(216, 6) + SourceIndex(0) +3 >Emitted(133, 7) Source(216, 7) + SourceIndex(0) +4 >Emitted(133, 16) Source(216, 16) + SourceIndex(0) +5 >Emitted(133, 17) Source(216, 17) + SourceIndex(0) +6 >Emitted(133, 20) Source(216, 20) + SourceIndex(0) +7 >Emitted(133, 23) Source(216, 23) + SourceIndex(0) +8 >Emitted(133, 33) Source(216, 32) + SourceIndex(0) +9 >Emitted(133, 35) Source(216, 34) + SourceIndex(0) +10>Emitted(133, 37) Source(216, 36) + SourceIndex(0) +11>Emitted(133, 39) Source(216, 38) + SourceIndex(0) --- >>> return new Point(this.x + dx, this.y + dy); 1->^^^^ @@ -3665,25 +3466,25 @@ sourceFile:contextualTyping.ts 17> dy 18> ) 19> ; -1->Emitted(219, 5) Source(217, 5) + SourceIndex(0) -2 >Emitted(219, 11) Source(217, 11) + SourceIndex(0) -3 >Emitted(219, 12) Source(217, 12) + SourceIndex(0) -4 >Emitted(219, 16) Source(217, 16) + SourceIndex(0) -5 >Emitted(219, 21) Source(217, 21) + SourceIndex(0) -6 >Emitted(219, 22) Source(217, 22) + SourceIndex(0) -7 >Emitted(219, 26) Source(217, 26) + SourceIndex(0) -8 >Emitted(219, 27) Source(217, 27) + SourceIndex(0) -9 >Emitted(219, 28) Source(217, 28) + SourceIndex(0) -10>Emitted(219, 31) Source(217, 31) + SourceIndex(0) -11>Emitted(219, 33) Source(217, 33) + SourceIndex(0) -12>Emitted(219, 35) Source(217, 35) + SourceIndex(0) -13>Emitted(219, 39) Source(217, 39) + SourceIndex(0) -14>Emitted(219, 40) Source(217, 40) + SourceIndex(0) -15>Emitted(219, 41) Source(217, 41) + SourceIndex(0) -16>Emitted(219, 44) Source(217, 44) + SourceIndex(0) -17>Emitted(219, 46) Source(217, 46) + SourceIndex(0) -18>Emitted(219, 47) Source(217, 47) + SourceIndex(0) -19>Emitted(219, 48) Source(217, 48) + SourceIndex(0) +1->Emitted(134, 5) Source(217, 5) + SourceIndex(0) +2 >Emitted(134, 11) Source(217, 11) + SourceIndex(0) +3 >Emitted(134, 12) Source(217, 12) + SourceIndex(0) +4 >Emitted(134, 16) Source(217, 16) + SourceIndex(0) +5 >Emitted(134, 21) Source(217, 21) + SourceIndex(0) +6 >Emitted(134, 22) Source(217, 22) + SourceIndex(0) +7 >Emitted(134, 26) Source(217, 26) + SourceIndex(0) +8 >Emitted(134, 27) Source(217, 27) + SourceIndex(0) +9 >Emitted(134, 28) Source(217, 28) + SourceIndex(0) +10>Emitted(134, 31) Source(217, 31) + SourceIndex(0) +11>Emitted(134, 33) Source(217, 33) + SourceIndex(0) +12>Emitted(134, 35) Source(217, 35) + SourceIndex(0) +13>Emitted(134, 39) Source(217, 39) + SourceIndex(0) +14>Emitted(134, 40) Source(217, 40) + SourceIndex(0) +15>Emitted(134, 41) Source(217, 41) + SourceIndex(0) +16>Emitted(134, 44) Source(217, 44) + SourceIndex(0) +17>Emitted(134, 46) Source(217, 46) + SourceIndex(0) +18>Emitted(134, 47) Source(217, 47) + SourceIndex(0) +19>Emitted(134, 48) Source(217, 48) + SourceIndex(0) --- >>>}; 1 > @@ -3694,9 +3495,9 @@ sourceFile:contextualTyping.ts > 2 >} 3 > ; -1 >Emitted(220, 1) Source(218, 1) + SourceIndex(0) -2 >Emitted(220, 2) Source(218, 2) + SourceIndex(0) -3 >Emitted(220, 3) Source(218, 3) + SourceIndex(0) +1 >Emitted(135, 1) Source(218, 1) + SourceIndex(0) +2 >Emitted(135, 2) Source(218, 2) + SourceIndex(0) +3 >Emitted(135, 3) Source(218, 3) + SourceIndex(0) --- >>>Point.prototype = { 1-> @@ -3711,11 +3512,11 @@ sourceFile:contextualTyping.ts 3 > . 4 > prototype 5 > = -1->Emitted(221, 1) Source(220, 1) + SourceIndex(0) -2 >Emitted(221, 6) Source(220, 6) + SourceIndex(0) -3 >Emitted(221, 7) Source(220, 7) + SourceIndex(0) -4 >Emitted(221, 16) Source(220, 16) + SourceIndex(0) -5 >Emitted(221, 19) Source(220, 19) + SourceIndex(0) +1->Emitted(136, 1) Source(220, 1) + SourceIndex(0) +2 >Emitted(136, 6) Source(220, 6) + SourceIndex(0) +3 >Emitted(136, 7) Source(220, 7) + SourceIndex(0) +4 >Emitted(136, 16) Source(220, 16) + SourceIndex(0) +5 >Emitted(136, 19) Source(220, 19) + SourceIndex(0) --- >>> x: 0, 1 >^^^^ @@ -3728,10 +3529,10 @@ sourceFile:contextualTyping.ts 2 > x 3 > : 4 > 0 -1 >Emitted(222, 5) Source(221, 5) + SourceIndex(0) -2 >Emitted(222, 6) Source(221, 6) + SourceIndex(0) -3 >Emitted(222, 8) Source(221, 8) + SourceIndex(0) -4 >Emitted(222, 9) Source(221, 9) + SourceIndex(0) +1 >Emitted(137, 5) Source(221, 5) + SourceIndex(0) +2 >Emitted(137, 6) Source(221, 6) + SourceIndex(0) +3 >Emitted(137, 8) Source(221, 8) + SourceIndex(0) +4 >Emitted(137, 9) Source(221, 9) + SourceIndex(0) --- >>> y: 0, 1->^^^^ @@ -3744,10 +3545,10 @@ sourceFile:contextualTyping.ts 2 > y 3 > : 4 > 0 -1->Emitted(223, 5) Source(222, 5) + SourceIndex(0) -2 >Emitted(223, 6) Source(222, 6) + SourceIndex(0) -3 >Emitted(223, 8) Source(222, 8) + SourceIndex(0) -4 >Emitted(223, 9) Source(222, 9) + SourceIndex(0) +1->Emitted(138, 5) Source(222, 5) + SourceIndex(0) +2 >Emitted(138, 6) Source(222, 6) + SourceIndex(0) +3 >Emitted(138, 8) Source(222, 8) + SourceIndex(0) +4 >Emitted(138, 9) Source(222, 9) + SourceIndex(0) --- >>> add: function (dx, dy) { 1->^^^^ @@ -3766,13 +3567,13 @@ sourceFile:contextualTyping.ts 5 > dx 6 > , 7 > dy -1->Emitted(224, 5) Source(223, 5) + SourceIndex(0) -2 >Emitted(224, 8) Source(223, 8) + SourceIndex(0) -3 >Emitted(224, 10) Source(223, 10) + SourceIndex(0) -4 >Emitted(224, 20) Source(223, 19) + SourceIndex(0) -5 >Emitted(224, 22) Source(223, 21) + SourceIndex(0) -6 >Emitted(224, 24) Source(223, 23) + SourceIndex(0) -7 >Emitted(224, 26) Source(223, 25) + SourceIndex(0) +1->Emitted(139, 5) Source(223, 5) + SourceIndex(0) +2 >Emitted(139, 8) Source(223, 8) + SourceIndex(0) +3 >Emitted(139, 10) Source(223, 10) + SourceIndex(0) +4 >Emitted(139, 20) Source(223, 19) + SourceIndex(0) +5 >Emitted(139, 22) Source(223, 21) + SourceIndex(0) +6 >Emitted(139, 24) Source(223, 23) + SourceIndex(0) +7 >Emitted(139, 26) Source(223, 25) + SourceIndex(0) --- >>> return new Point(this.x + dx, this.y + dy); 1->^^^^^^^^ @@ -3814,25 +3615,25 @@ sourceFile:contextualTyping.ts 17> dy 18> ) 19> ; -1->Emitted(225, 9) Source(224, 9) + SourceIndex(0) -2 >Emitted(225, 15) Source(224, 15) + SourceIndex(0) -3 >Emitted(225, 16) Source(224, 16) + SourceIndex(0) -4 >Emitted(225, 20) Source(224, 20) + SourceIndex(0) -5 >Emitted(225, 25) Source(224, 25) + SourceIndex(0) -6 >Emitted(225, 26) Source(224, 26) + SourceIndex(0) -7 >Emitted(225, 30) Source(224, 30) + SourceIndex(0) -8 >Emitted(225, 31) Source(224, 31) + SourceIndex(0) -9 >Emitted(225, 32) Source(224, 32) + SourceIndex(0) -10>Emitted(225, 35) Source(224, 35) + SourceIndex(0) -11>Emitted(225, 37) Source(224, 37) + SourceIndex(0) -12>Emitted(225, 39) Source(224, 39) + SourceIndex(0) -13>Emitted(225, 43) Source(224, 43) + SourceIndex(0) -14>Emitted(225, 44) Source(224, 44) + SourceIndex(0) -15>Emitted(225, 45) Source(224, 45) + SourceIndex(0) -16>Emitted(225, 48) Source(224, 48) + SourceIndex(0) -17>Emitted(225, 50) Source(224, 50) + SourceIndex(0) -18>Emitted(225, 51) Source(224, 51) + SourceIndex(0) -19>Emitted(225, 52) Source(224, 52) + SourceIndex(0) +1->Emitted(140, 9) Source(224, 9) + SourceIndex(0) +2 >Emitted(140, 15) Source(224, 15) + SourceIndex(0) +3 >Emitted(140, 16) Source(224, 16) + SourceIndex(0) +4 >Emitted(140, 20) Source(224, 20) + SourceIndex(0) +5 >Emitted(140, 25) Source(224, 25) + SourceIndex(0) +6 >Emitted(140, 26) Source(224, 26) + SourceIndex(0) +7 >Emitted(140, 30) Source(224, 30) + SourceIndex(0) +8 >Emitted(140, 31) Source(224, 31) + SourceIndex(0) +9 >Emitted(140, 32) Source(224, 32) + SourceIndex(0) +10>Emitted(140, 35) Source(224, 35) + SourceIndex(0) +11>Emitted(140, 37) Source(224, 37) + SourceIndex(0) +12>Emitted(140, 39) Source(224, 39) + SourceIndex(0) +13>Emitted(140, 43) Source(224, 43) + SourceIndex(0) +14>Emitted(140, 44) Source(224, 44) + SourceIndex(0) +15>Emitted(140, 45) Source(224, 45) + SourceIndex(0) +16>Emitted(140, 48) Source(224, 48) + SourceIndex(0) +17>Emitted(140, 50) Source(224, 50) + SourceIndex(0) +18>Emitted(140, 51) Source(224, 51) + SourceIndex(0) +19>Emitted(140, 52) Source(224, 52) + SourceIndex(0) --- >>> } 1 >^^^^ @@ -3840,8 +3641,8 @@ sourceFile:contextualTyping.ts 1 > > 2 > } -1 >Emitted(226, 5) Source(225, 5) + SourceIndex(0) -2 >Emitted(226, 6) Source(225, 6) + SourceIndex(0) +1 >Emitted(141, 5) Source(225, 5) + SourceIndex(0) +2 >Emitted(141, 6) Source(225, 6) + SourceIndex(0) --- >>>}; 1 >^ @@ -3850,8 +3651,8 @@ sourceFile:contextualTyping.ts 1 > >} 2 > ; -1 >Emitted(227, 2) Source(226, 2) + SourceIndex(0) -2 >Emitted(227, 3) Source(226, 3) + SourceIndex(0) +1 >Emitted(142, 2) Source(226, 2) + SourceIndex(0) +2 >Emitted(142, 3) Source(226, 3) + SourceIndex(0) --- >>>var x = {}; 1-> @@ -3871,11 +3672,11 @@ sourceFile:contextualTyping.ts 4 > : B = 5 > { } 6 > ; -1->Emitted(228, 1) Source(230, 1) + SourceIndex(0) -2 >Emitted(228, 5) Source(230, 5) + SourceIndex(0) -3 >Emitted(228, 6) Source(230, 6) + SourceIndex(0) -4 >Emitted(228, 9) Source(230, 12) + SourceIndex(0) -5 >Emitted(228, 11) Source(230, 15) + SourceIndex(0) -6 >Emitted(228, 12) Source(230, 16) + SourceIndex(0) +1->Emitted(143, 1) Source(230, 1) + SourceIndex(0) +2 >Emitted(143, 5) Source(230, 5) + SourceIndex(0) +3 >Emitted(143, 6) Source(230, 6) + SourceIndex(0) +4 >Emitted(143, 9) Source(230, 12) + SourceIndex(0) +5 >Emitted(143, 11) Source(230, 15) + SourceIndex(0) +6 >Emitted(143, 12) Source(230, 16) + SourceIndex(0) --- >>>//# sourceMappingURL=contextualTyping.js.map \ No newline at end of file diff --git a/tests/baselines/reference/contextualTyping1.js b/tests/baselines/reference/contextualTyping1.js index 6b1b88c36f..7f1e12c744 100644 --- a/tests/baselines/reference/contextualTyping1.js +++ b/tests/baselines/reference/contextualTyping1.js @@ -2,4 +2,4 @@ var foo: {id:number;} = {id:4}; //// [contextualTyping1.js] -var foo = {\n id: 4\n};\n \ No newline at end of file +var foo = { id: 4 };\n \ No newline at end of file diff --git a/tests/baselines/reference/contextualTyping10.js b/tests/baselines/reference/contextualTyping10.js index e6afd72e81..08a2172b69 100644 --- a/tests/baselines/reference/contextualTyping10.js +++ b/tests/baselines/reference/contextualTyping10.js @@ -4,14 +4,7 @@ class foo { public bar:{id:number;}[] = [{id:1}, {id:2}]; } //// [contextualTyping10.js] var foo = (function () { function foo() { - this.bar = [ - { - id: 1 - }, - { - id: 2 - } - ]; + this.bar = [{ id: 1 }, { id: 2 }]; } return foo; })(); diff --git a/tests/baselines/reference/contextualTyping11.js b/tests/baselines/reference/contextualTyping11.js index 123295d538..a7ec3815fa 100644 --- a/tests/baselines/reference/contextualTyping11.js +++ b/tests/baselines/reference/contextualTyping11.js @@ -4,9 +4,7 @@ class foo { public bar:{id:number;}[] = [({})]; } //// [contextualTyping11.js] var foo = (function () { function foo() { - this.bar = [ - ({}) - ]; + this.bar = [({})]; } return foo; })(); diff --git a/tests/baselines/reference/contextualTyping12.js b/tests/baselines/reference/contextualTyping12.js index 60f3965f95..c41ccbed99 100644 --- a/tests/baselines/reference/contextualTyping12.js +++ b/tests/baselines/reference/contextualTyping12.js @@ -4,15 +4,7 @@ class foo { public bar:{id:number;}[] = [{id:1}, {id:2, name:"foo"}]; } //// [contextualTyping12.js] var foo = (function () { function foo() { - this.bar = [ - { - id: 1 - }, - { - id: 2, - name: "foo" - } - ]; + this.bar = [{ id: 1 }, { id: 2, name: "foo" }]; } return foo; })(); diff --git a/tests/baselines/reference/contextualTyping13.js b/tests/baselines/reference/contextualTyping13.js index c035434342..7965745b94 100644 --- a/tests/baselines/reference/contextualTyping13.js +++ b/tests/baselines/reference/contextualTyping13.js @@ -2,6 +2,4 @@ var foo:(a:number)=>number = function(a){return a}; //// [contextualTyping13.js] -var foo = function (a) { - return a; -}; +var foo = function (a) { return a; }; diff --git a/tests/baselines/reference/contextualTyping14.js b/tests/baselines/reference/contextualTyping14.js index ea9539ef41..5bae8c948a 100644 --- a/tests/baselines/reference/contextualTyping14.js +++ b/tests/baselines/reference/contextualTyping14.js @@ -4,9 +4,7 @@ class foo { public bar:(a:number)=>number = function(a){return a}; } //// [contextualTyping14.js] var foo = (function () { function foo() { - this.bar = function (a) { - return a; - }; + this.bar = function (a) { return a; }; } return foo; })(); diff --git a/tests/baselines/reference/contextualTyping15.js b/tests/baselines/reference/contextualTyping15.js index 9985568157..250076ec4d 100644 --- a/tests/baselines/reference/contextualTyping15.js +++ b/tests/baselines/reference/contextualTyping15.js @@ -4,9 +4,7 @@ class foo { public bar: { (): number; (i: number): number; } = function() { retu //// [contextualTyping15.js] var foo = (function () { function foo() { - this.bar = function () { - return 1; - }; + this.bar = function () { return 1; }; } return foo; })(); diff --git a/tests/baselines/reference/contextualTyping16.js b/tests/baselines/reference/contextualTyping16.js index bccf047ad1..1a4c28ba74 100644 --- a/tests/baselines/reference/contextualTyping16.js +++ b/tests/baselines/reference/contextualTyping16.js @@ -2,9 +2,5 @@ var foo: {id:number;} = {id:4}; foo = {id:5}; //// [contextualTyping16.js] -var foo = { - id: 4 -}; -foo = { - id: 5 -}; +var foo = { id: 4 }; +foo = { id: 5 }; diff --git a/tests/baselines/reference/contextualTyping17.js b/tests/baselines/reference/contextualTyping17.js index 2e433cd4df..0ae2605dbd 100644 --- a/tests/baselines/reference/contextualTyping17.js +++ b/tests/baselines/reference/contextualTyping17.js @@ -2,10 +2,5 @@ var foo: {id:number;} = {id:4}; foo = {id: 5, name:"foo"}; //// [contextualTyping17.js] -var foo = { - id: 4 -}; -foo = { - id: 5, - name: "foo" -}; +var foo = { id: 4 }; +foo = { id: 5, name: "foo" }; diff --git a/tests/baselines/reference/contextualTyping18.js b/tests/baselines/reference/contextualTyping18.js index 7289d73ba1..fb058032ed 100644 --- a/tests/baselines/reference/contextualTyping18.js +++ b/tests/baselines/reference/contextualTyping18.js @@ -3,6 +3,4 @@ var foo: {id:number;} = <{id:number;}>({ }); foo = {id: 5}; //// [contextualTyping18.js] var foo = ({}); -foo = { - id: 5 -}; +foo = { id: 5 }; diff --git a/tests/baselines/reference/contextualTyping19.js b/tests/baselines/reference/contextualTyping19.js index 2b70fc1976..e4e5137285 100644 --- a/tests/baselines/reference/contextualTyping19.js +++ b/tests/baselines/reference/contextualTyping19.js @@ -2,16 +2,5 @@ var foo:{id:number;}[] = [{id:1}]; foo = [{id:1}, {id:2}]; //// [contextualTyping19.js] -var foo = [ - { - id: 1 - } -]; -foo = [ - { - id: 1 - }, - { - id: 2 - } -]; +var foo = [{ id: 1 }]; +foo = [{ id: 1 }, { id: 2 }]; diff --git a/tests/baselines/reference/contextualTyping2.js b/tests/baselines/reference/contextualTyping2.js index 4240ce23a1..4dc3f71e9b 100644 --- a/tests/baselines/reference/contextualTyping2.js +++ b/tests/baselines/reference/contextualTyping2.js @@ -2,7 +2,4 @@ var foo: {id:number;} = {id:4, name:"foo"}; //// [contextualTyping2.js] -var foo = { - id: 4, - name: "foo" -}; +var foo = { id: 4, name: "foo" }; diff --git a/tests/baselines/reference/contextualTyping20.js b/tests/baselines/reference/contextualTyping20.js index e2afa7a21f..f53a7f7554 100644 --- a/tests/baselines/reference/contextualTyping20.js +++ b/tests/baselines/reference/contextualTyping20.js @@ -2,17 +2,5 @@ var foo:{id:number;}[] = [{id:1}]; foo = [{id:1}, {id:2, name:"foo"}]; //// [contextualTyping20.js] -var foo = [ - { - id: 1 - } -]; -foo = [ - { - id: 1 - }, - { - id: 2, - name: "foo" - } -]; +var foo = [{ id: 1 }]; +foo = [{ id: 1 }, { id: 2, name: "foo" }]; diff --git a/tests/baselines/reference/contextualTyping21.js b/tests/baselines/reference/contextualTyping21.js index 6c3aa6e885..3d87d9e424 100644 --- a/tests/baselines/reference/contextualTyping21.js +++ b/tests/baselines/reference/contextualTyping21.js @@ -2,14 +2,5 @@ var foo:{id:number;}[] = [{id:1}]; foo = [{id:1}, 1]; //// [contextualTyping21.js] -var foo = [ - { - id: 1 - } -]; -foo = [ - { - id: 1 - }, - 1 -]; +var foo = [{ id: 1 }]; +foo = [{ id: 1 }, 1]; diff --git a/tests/baselines/reference/contextualTyping22.js b/tests/baselines/reference/contextualTyping22.js index b8ebfd3ecb..3c9a5cb4d3 100644 --- a/tests/baselines/reference/contextualTyping22.js +++ b/tests/baselines/reference/contextualTyping22.js @@ -2,9 +2,5 @@ var foo:(a:number)=>number = function(a){return a}; foo = function(b){return b}; //// [contextualTyping22.js] -var foo = function (a) { - return a; -}; -foo = function (b) { - return b; -}; +var foo = function (a) { return a; }; +foo = function (b) { return b; }; diff --git a/tests/baselines/reference/contextualTyping23.js b/tests/baselines/reference/contextualTyping23.js index 187fd3f86d..0207f6af15 100644 --- a/tests/baselines/reference/contextualTyping23.js +++ b/tests/baselines/reference/contextualTyping23.js @@ -3,6 +3,4 @@ var foo:(a:{():number; (i:number):number; })=>number; foo = function(a){return 5 //// [contextualTyping23.js] var foo; -foo = function (a) { - return 5; -}; +foo = function (a) { return 5; }; diff --git a/tests/baselines/reference/contextualTyping24.js b/tests/baselines/reference/contextualTyping24.js index 170a6983b9..04c4ecba21 100644 --- a/tests/baselines/reference/contextualTyping24.js +++ b/tests/baselines/reference/contextualTyping24.js @@ -3,6 +3,4 @@ var foo:(a:{():number; (i:number):number; })=>number; foo = function(a:string){r //// [contextualTyping24.js] var foo; -foo = function (a) { - return 5; -}; +foo = function (a) { return 5; }; diff --git a/tests/baselines/reference/contextualTyping25.js b/tests/baselines/reference/contextualTyping25.js index 808ee2202e..f90a70098d 100644 --- a/tests/baselines/reference/contextualTyping25.js +++ b/tests/baselines/reference/contextualTyping25.js @@ -2,7 +2,6 @@ function foo(param:{id:number;}){}; foo(<{id:number;}>({})); //// [contextualTyping25.js] -function foo(param) { -} +function foo(param) { } ; foo(({})); diff --git a/tests/baselines/reference/contextualTyping26.js b/tests/baselines/reference/contextualTyping26.js index fabd810c8f..feacf3da32 100644 --- a/tests/baselines/reference/contextualTyping26.js +++ b/tests/baselines/reference/contextualTyping26.js @@ -2,7 +2,6 @@ function foo(param:{id:number;}){}; foo(<{id:number;}>({})); //// [contextualTyping26.js] -function foo(param) { -} +function foo(param) { } ; foo(({})); diff --git a/tests/baselines/reference/contextualTyping27.js b/tests/baselines/reference/contextualTyping27.js index 11b8c25141..ce35e60619 100644 --- a/tests/baselines/reference/contextualTyping27.js +++ b/tests/baselines/reference/contextualTyping27.js @@ -2,7 +2,6 @@ function foo(param:{id:number;}){}; foo(<{id:number;}>({})); //// [contextualTyping27.js] -function foo(param) { -} +function foo(param) { } ; foo(({})); diff --git a/tests/baselines/reference/contextualTyping28.js b/tests/baselines/reference/contextualTyping28.js index a9dd848a2c..095e381240 100644 --- a/tests/baselines/reference/contextualTyping28.js +++ b/tests/baselines/reference/contextualTyping28.js @@ -2,9 +2,6 @@ function foo(param:number[]){}; foo([1]); //// [contextualTyping28.js] -function foo(param) { -} +function foo(param) { } ; -foo([ - 1 -]); +foo([1]); diff --git a/tests/baselines/reference/contextualTyping29.js b/tests/baselines/reference/contextualTyping29.js index cf3a8e340a..1d5b32c208 100644 --- a/tests/baselines/reference/contextualTyping29.js +++ b/tests/baselines/reference/contextualTyping29.js @@ -2,10 +2,6 @@ function foo(param:number[]){}; foo([1, 3]); //// [contextualTyping29.js] -function foo(param) { -} +function foo(param) { } ; -foo([ - 1, - 3 -]); +foo([1, 3]); diff --git a/tests/baselines/reference/contextualTyping3.js b/tests/baselines/reference/contextualTyping3.js index 8ea5481037..19d71f4ca7 100644 --- a/tests/baselines/reference/contextualTyping3.js +++ b/tests/baselines/reference/contextualTyping3.js @@ -4,9 +4,7 @@ class foo { public bar:{id:number;} = {id:5}; } //// [contextualTyping3.js] var foo = (function () { function foo() { - this.bar = { - id: 5 - }; + this.bar = { id: 5 }; } return foo; })(); diff --git a/tests/baselines/reference/contextualTyping30.js b/tests/baselines/reference/contextualTyping30.js index 25b8d9c6f5..94547a387d 100644 --- a/tests/baselines/reference/contextualTyping30.js +++ b/tests/baselines/reference/contextualTyping30.js @@ -2,10 +2,6 @@ function foo(param:number[]){}; foo([1, "a"]); //// [contextualTyping30.js] -function foo(param) { -} +function foo(param) { } ; -foo([ - 1, - "a" -]); +foo([1, "a"]); diff --git a/tests/baselines/reference/contextualTyping31.js b/tests/baselines/reference/contextualTyping31.js index 0e29d9f68c..1eb4d5660f 100644 --- a/tests/baselines/reference/contextualTyping31.js +++ b/tests/baselines/reference/contextualTyping31.js @@ -2,9 +2,6 @@ function foo(param:number[]){}; foo([1]); //// [contextualTyping31.js] -function foo(param) { -} +function foo(param) { } ; -foo([ - 1 -]); +foo([1]); diff --git a/tests/baselines/reference/contextualTyping32.js b/tests/baselines/reference/contextualTyping32.js index 8a47a109ae..bbbafa7079 100644 --- a/tests/baselines/reference/contextualTyping32.js +++ b/tests/baselines/reference/contextualTyping32.js @@ -2,14 +2,6 @@ function foo(param: {():number; (i:number):number; }[]) { }; foo([function(){return 1;}, function(){return 4}]); //// [contextualTyping32.js] -function foo(param) { -} +function foo(param) { } ; -foo([ - function () { - return 1; - }, - function () { - return 4; - } -]); +foo([function () { return 1; }, function () { return 4; }]); diff --git a/tests/baselines/reference/contextualTyping33.js b/tests/baselines/reference/contextualTyping33.js index 9ee3245416..1d800b1d11 100644 --- a/tests/baselines/reference/contextualTyping33.js +++ b/tests/baselines/reference/contextualTyping33.js @@ -2,14 +2,6 @@ function foo(param: {():number; (i:number):number; }[]) { }; foo([function(){return 1;}, function(){return "foo"}]); //// [contextualTyping33.js] -function foo(param) { -} +function foo(param) { } ; -foo([ - function () { - return 1; - }, - function () { - return "foo"; - } -]); +foo([function () { return 1; }, function () { return "foo"; }]); diff --git a/tests/baselines/reference/contextualTyping34.js b/tests/baselines/reference/contextualTyping34.js index fc801d3cd7..5e12ba602a 100644 --- a/tests/baselines/reference/contextualTyping34.js +++ b/tests/baselines/reference/contextualTyping34.js @@ -2,6 +2,4 @@ var foo = <{ id: number;}> ({id:4}); //// [contextualTyping34.js] -var foo = ({ - id: 4 -}); +var foo = ({ id: 4 }); diff --git a/tests/baselines/reference/contextualTyping35.js b/tests/baselines/reference/contextualTyping35.js index bf9e02dd90..34d9e6b39a 100644 --- a/tests/baselines/reference/contextualTyping35.js +++ b/tests/baselines/reference/contextualTyping35.js @@ -2,7 +2,4 @@ var foo = <{ id: number;}> {id:4, name: "as"}; //// [contextualTyping35.js] -var foo = { - id: 4, - name: "as" -}; +var foo = { id: 4, name: "as" }; diff --git a/tests/baselines/reference/contextualTyping36.js b/tests/baselines/reference/contextualTyping36.js index 623a1e92ad..3bdaf5a8d0 100644 --- a/tests/baselines/reference/contextualTyping36.js +++ b/tests/baselines/reference/contextualTyping36.js @@ -2,9 +2,4 @@ var foo = <{ id: number; }[]>[{ id: 4 }, <{ id: number; }>({ })]; //// [contextualTyping36.js] -var foo = [ - { - id: 4 - }, - ({}) -]; +var foo = [{ id: 4 }, ({})]; diff --git a/tests/baselines/reference/contextualTyping37.js b/tests/baselines/reference/contextualTyping37.js index 2f2636579b..4bb6e7b350 100644 --- a/tests/baselines/reference/contextualTyping37.js +++ b/tests/baselines/reference/contextualTyping37.js @@ -2,9 +2,4 @@ var foo = <{ id: number; }[]>[{ foo: "s" }, { }]; //// [contextualTyping37.js] -var foo = [ - { - foo: "s" - }, - {} -]; +var foo = [{ foo: "s" }, {}]; diff --git a/tests/baselines/reference/contextualTyping38.js b/tests/baselines/reference/contextualTyping38.js index 71ed8ece57..9bed543ff7 100644 --- a/tests/baselines/reference/contextualTyping38.js +++ b/tests/baselines/reference/contextualTyping38.js @@ -2,6 +2,4 @@ var foo = <{ (): number; }> function(a) { return a }; //// [contextualTyping38.js] -var foo = function (a) { - return a; -}; +var foo = function (a) { return a; }; diff --git a/tests/baselines/reference/contextualTyping39.js b/tests/baselines/reference/contextualTyping39.js index 9a97b7eb3c..89d045830a 100644 --- a/tests/baselines/reference/contextualTyping39.js +++ b/tests/baselines/reference/contextualTyping39.js @@ -2,6 +2,4 @@ var foo = <{ (): number; }> function() { return "err"; }; //// [contextualTyping39.js] -var foo = function () { - return "err"; -}; +var foo = function () { return "err"; }; diff --git a/tests/baselines/reference/contextualTyping4.js b/tests/baselines/reference/contextualTyping4.js index 902791adcb..af79e3732f 100644 --- a/tests/baselines/reference/contextualTyping4.js +++ b/tests/baselines/reference/contextualTyping4.js @@ -4,10 +4,7 @@ class foo { public bar:{id:number;} = {id:5, name:"foo"}; } //// [contextualTyping4.js] var foo = (function () { function foo() { - this.bar = { - id: 5, - name: "foo" - }; + this.bar = { id: 5, name: "foo" }; } return foo; })(); diff --git a/tests/baselines/reference/contextualTyping40.js b/tests/baselines/reference/contextualTyping40.js index ba2c447b10..0b98f8e45c 100644 --- a/tests/baselines/reference/contextualTyping40.js +++ b/tests/baselines/reference/contextualTyping40.js @@ -2,6 +2,4 @@ var foo = <{():number; (i:number):number; }> function(){return 1;}; //// [contextualTyping40.js] -var foo = function () { - return 1; -}; +var foo = function () { return 1; }; diff --git a/tests/baselines/reference/contextualTyping41.js b/tests/baselines/reference/contextualTyping41.js index 720f1d178f..8bce7918dd 100644 --- a/tests/baselines/reference/contextualTyping41.js +++ b/tests/baselines/reference/contextualTyping41.js @@ -2,6 +2,4 @@ var foo = <{():number; (i:number):number; }> (function(){return "err";}); //// [contextualTyping41.js] -var foo = (function () { - return "err"; -}); +var foo = (function () { return "err"; }); diff --git a/tests/baselines/reference/contextualTyping6.js b/tests/baselines/reference/contextualTyping6.js index c1fb58d4d2..df2d2ac15c 100644 --- a/tests/baselines/reference/contextualTyping6.js +++ b/tests/baselines/reference/contextualTyping6.js @@ -2,11 +2,4 @@ var foo:{id:number;}[] = [{id:1}, {id:2}]; //// [contextualTyping6.js] -var foo = [ - { - id: 1 - }, - { - id: 2 - } -]; +var foo = [{ id: 1 }, { id: 2 }]; diff --git a/tests/baselines/reference/contextualTyping7.js b/tests/baselines/reference/contextualTyping7.js index 6b93e7308d..2cd2494c3b 100644 --- a/tests/baselines/reference/contextualTyping7.js +++ b/tests/baselines/reference/contextualTyping7.js @@ -2,6 +2,4 @@ var foo:{id:number;}[] = [<{id:number;}>({})]; //// [contextualTyping7.js] -var foo = [ - ({}) -]; +var foo = [({})]; diff --git a/tests/baselines/reference/contextualTyping8.js b/tests/baselines/reference/contextualTyping8.js index 276b32bed6..a0e3b5b9ef 100644 --- a/tests/baselines/reference/contextualTyping8.js +++ b/tests/baselines/reference/contextualTyping8.js @@ -2,6 +2,4 @@ var foo:{id:number;}[] = [<{id:number;}>({})]; //// [contextualTyping8.js] -var foo = [ - ({}) -]; +var foo = [({})]; diff --git a/tests/baselines/reference/contextualTyping9.js b/tests/baselines/reference/contextualTyping9.js index 19d0f0fba7..71384cf8b0 100644 --- a/tests/baselines/reference/contextualTyping9.js +++ b/tests/baselines/reference/contextualTyping9.js @@ -2,12 +2,4 @@ var foo:{id:number;}[] = [{id:1}, {id:2, name:"foo"}]; //// [contextualTyping9.js] -var foo = [ - { - id: 1 - }, - { - id: 2, - name: "foo" - } -]; +var foo = [{ id: 1 }, { id: 2, name: "foo" }]; diff --git a/tests/baselines/reference/contextualTypingArrayOfLambdas.js b/tests/baselines/reference/contextualTypingArrayOfLambdas.js index b9ea5beaa7..844a50428e 100644 --- a/tests/baselines/reference/contextualTypingArrayOfLambdas.js +++ b/tests/baselines/reference/contextualTypingArrayOfLambdas.js @@ -40,11 +40,4 @@ var C = (function (_super) { } return C; })(A); -var xs = [ - function (x) { - }, - function (x) { - }, - function (x) { - } -]; +var xs = [function (x) { }, function (x) { }, function (x) { }]; diff --git a/tests/baselines/reference/contextualTypingOfAccessors.js b/tests/baselines/reference/contextualTypingOfAccessors.js index 0f45574be9..f785d19636 100644 --- a/tests/baselines/reference/contextualTypingOfAccessors.js +++ b/tests/baselines/reference/contextualTypingOfAccessors.js @@ -18,10 +18,7 @@ x = { var x; x = { get foo() { - return function (n) { - return n; - }; + return function (n) { return n; }; }, - set foo(x) { - } + set foo(x) { } }; diff --git a/tests/baselines/reference/contextualTypingOfArrayLiterals1.js b/tests/baselines/reference/contextualTypingOfArrayLiterals1.js index e2edcb3d5d..e751309340 100644 --- a/tests/baselines/reference/contextualTypingOfArrayLiterals1.js +++ b/tests/baselines/reference/contextualTypingOfArrayLiterals1.js @@ -9,9 +9,6 @@ r2.getDate(); //// [contextualTypingOfArrayLiterals1.js] -var x3 = [ - new Date(), - 1 -]; +var x3 = [new Date(), 1]; var r2 = x3[1]; r2.getDate(); diff --git a/tests/baselines/reference/contextualTypingOfConditionalExpression.js b/tests/baselines/reference/contextualTypingOfConditionalExpression.js index 805ffca750..b1100ba80a 100644 --- a/tests/baselines/reference/contextualTypingOfConditionalExpression.js +++ b/tests/baselines/reference/contextualTypingOfConditionalExpression.js @@ -21,11 +21,7 @@ var __extends = this.__extends || function (d, b) { __.prototype = b.prototype; d.prototype = new __(); }; -var x = true ? function (a) { - return a.toExponential(); -} : function (b) { - return b.toFixed(); -}; +var x = true ? function (a) { return a.toExponential(); } : function (b) { return b.toFixed(); }; var A = (function () { function A() { } @@ -45,8 +41,4 @@ var C = (function (_super) { } return C; })(A); -var x2 = true ? function (a) { - return a.foo; -} : function (b) { - return b.foo; -}; +var x2 = true ? function (a) { return a.foo; } : function (b) { return b.foo; }; diff --git a/tests/baselines/reference/contextualTypingOfConditionalExpression2.js b/tests/baselines/reference/contextualTypingOfConditionalExpression2.js index c84fa87e81..f832d2766e 100644 --- a/tests/baselines/reference/contextualTypingOfConditionalExpression2.js +++ b/tests/baselines/reference/contextualTypingOfConditionalExpression2.js @@ -38,7 +38,4 @@ var C = (function (_super) { } return C; })(A); -var x2 = true ? function (a) { - return a.foo; -} : function (b) { -}; +var x2 = true ? function (a) { return a.foo; } : function (b) { }; diff --git a/tests/baselines/reference/contextualTypingOfGenericFunctionTypedArguments1.js b/tests/baselines/reference/contextualTypingOfGenericFunctionTypedArguments1.js index b2a8bf0dba..8142b51dcd 100644 --- a/tests/baselines/reference/contextualTypingOfGenericFunctionTypedArguments1.js +++ b/tests/baselines/reference/contextualTypingOfGenericFunctionTypedArguments1.js @@ -22,10 +22,6 @@ var r6 = _.forEach(c2, (x) => { return x.toFixed() }); var c2; var _; // errors on all 3 lines, bug was that r5 was the only line with errors -var f = function (x) { - return x.toFixed(); -}; +var f = function (x) { return x.toFixed(); }; var r5 = _.forEach(c2, f); -var r6 = _.forEach(c2, function (x) { - return x.toFixed(); -}); +var r6 = _.forEach(c2, function (x) { return x.toFixed(); }); diff --git a/tests/baselines/reference/contextualTypingOfLambdaReturnExpression.js b/tests/baselines/reference/contextualTypingOfLambdaReturnExpression.js index ecc6a0ecd1..67670bf872 100644 --- a/tests/baselines/reference/contextualTypingOfLambdaReturnExpression.js +++ b/tests/baselines/reference/contextualTypingOfLambdaReturnExpression.js @@ -7,11 +7,6 @@ callb((a) => a.length); // Ok, we choose the second overload because the first o callb((a) => { a.length; }); // Error, we picked the first overload and errored when type checking the lambda body //// [contextualTypingOfLambdaReturnExpression.js] -function callb(a) { -} -callb(function (a) { - return a.length; -}); // Ok, we choose the second overload because the first one gave us an error when trying to resolve the lambda return type -callb(function (a) { - a.length; -}); // Error, we picked the first overload and errored when type checking the lambda body +function callb(a) { } +callb(function (a) { return a.length; }); // Ok, we choose the second overload because the first one gave us an error when trying to resolve the lambda return type +callb(function (a) { a.length; }); // Error, we picked the first overload and errored when type checking the lambda body diff --git a/tests/baselines/reference/contextualTypingOfLambdaWithMultipleSignatures.js b/tests/baselines/reference/contextualTypingOfLambdaWithMultipleSignatures.js index 400a052a7b..f21bc852af 100644 --- a/tests/baselines/reference/contextualTypingOfLambdaWithMultipleSignatures.js +++ b/tests/baselines/reference/contextualTypingOfLambdaWithMultipleSignatures.js @@ -9,5 +9,4 @@ foo.getFoo = bar => { }; //// [contextualTypingOfLambdaWithMultipleSignatures.js] var foo; -foo.getFoo = function (bar) { -}; +foo.getFoo = function (bar) { }; diff --git a/tests/baselines/reference/contextualTypingOfLambdaWithMultipleSignatures2.js b/tests/baselines/reference/contextualTypingOfLambdaWithMultipleSignatures2.js index 415fc3acd2..442ded4ba7 100644 --- a/tests/baselines/reference/contextualTypingOfLambdaWithMultipleSignatures2.js +++ b/tests/baselines/reference/contextualTypingOfLambdaWithMultipleSignatures2.js @@ -8,6 +8,4 @@ f = (a) => { return a.asdf } //// [contextualTypingOfLambdaWithMultipleSignatures2.js] var f; -f = function (a) { - return a.asdf; -}; +f = function (a) { return a.asdf; }; diff --git a/tests/baselines/reference/contextualTypingOfObjectLiterals.js b/tests/baselines/reference/contextualTypingOfObjectLiterals.js index d965ef5828..e267ce6269 100644 --- a/tests/baselines/reference/contextualTypingOfObjectLiterals.js +++ b/tests/baselines/reference/contextualTypingOfObjectLiterals.js @@ -12,13 +12,10 @@ f(obj2); // Error - indexer doesn't match //// [contextualTypingOfObjectLiterals.js] var obj1; -var obj2 = { - x: "" -}; +var obj2 = { x: "" }; obj1 = {}; // Ok obj1 = obj2; // Error - indexer doesn't match -function f(x) { -} +function f(x) { } f({}); // Ok f(obj1); // Ok f(obj2); // Error - indexer doesn't match diff --git a/tests/baselines/reference/contextualTypingOfObjectLiterals2.js b/tests/baselines/reference/contextualTypingOfObjectLiterals2.js index f709890c55..4c450d3115 100644 --- a/tests/baselines/reference/contextualTypingOfObjectLiterals2.js +++ b/tests/baselines/reference/contextualTypingOfObjectLiterals2.js @@ -6,10 +6,5 @@ function f2(args: Foo) { } f2({ foo: s => s.hmm }) // 's' should be 'string', so this should be an error //// [contextualTypingOfObjectLiterals2.js] -function f2(args) { -} -f2({ - foo: function (s) { - return s.hmm; - } -}); // 's' should be 'string', so this should be an error +function f2(args) { } +f2({ foo: function (s) { return s.hmm; } }); // 's' should be 'string', so this should be an error diff --git a/tests/baselines/reference/contextualTypingTwoInstancesOfSameTypeParameter.js b/tests/baselines/reference/contextualTypingTwoInstancesOfSameTypeParameter.js index 96e8f86035..4b392bac80 100644 --- a/tests/baselines/reference/contextualTypingTwoInstancesOfSameTypeParameter.js +++ b/tests/baselines/reference/contextualTypingTwoInstancesOfSameTypeParameter.js @@ -8,8 +8,4 @@ f6(x => f6(y => x = y)); function f6(x) { return null; } -f6(function (x) { - return f6(function (y) { - return x = y; - }); -}); +f6(function (x) { return f6(function (y) { return x = y; }); }); diff --git a/tests/baselines/reference/contextualTypingWithFixedTypeParameters1.js b/tests/baselines/reference/contextualTypingWithFixedTypeParameters1.js index f8804547d4..55f7580b3f 100644 --- a/tests/baselines/reference/contextualTypingWithFixedTypeParameters1.js +++ b/tests/baselines/reference/contextualTypingWithFixedTypeParameters1.js @@ -5,13 +5,5 @@ var r9 = f10('', () => (a => a.foo), 1); // error //// [contextualTypingWithFixedTypeParameters1.js] var f10; -f10('', function () { - return function (a) { - return a.foo; - }; -}, ''); // a is string -var r9 = f10('', function () { - return (function (a) { - return a.foo; - }); -}, 1); // error +f10('', function () { return function (a) { return a.foo; }; }, ''); // a is string +var r9 = f10('', function () { return (function (a) { return a.foo; }); }, 1); // error diff --git a/tests/baselines/reference/contextualTypingWithGenericAndNonGenericSignature.js b/tests/baselines/reference/contextualTypingWithGenericAndNonGenericSignature.js index f548b6daaa..5ee0c75802 100644 --- a/tests/baselines/reference/contextualTypingWithGenericAndNonGenericSignature.js +++ b/tests/baselines/reference/contextualTypingWithGenericAndNonGenericSignature.js @@ -19,10 +19,6 @@ f3 = (x, y) => { return x } //// [contextualTypingWithGenericAndNonGenericSignature.js] //• If e is a FunctionExpression or ArrowFunctionExpression with no type parameters and no parameter or return type annotations, and T is a function type with EXACTLY ONE non - generic call signature, then any inferences made for type parameters referenced by the parameters of T’s call signature are fixed(section 4.12.2) and e is processed with the contextual type T, as described in section 4.9.3. var f2; -f2 = function (x, y) { - return x; -}; +f2 = function (x, y) { return x; }; var f3; -f3 = function (x, y) { - return x; -}; +f3 = function (x, y) { return x; }; diff --git a/tests/baselines/reference/contextualTypingWithGenericSignature.js b/tests/baselines/reference/contextualTypingWithGenericSignature.js index a1417e90b4..611a35f38a 100644 --- a/tests/baselines/reference/contextualTypingWithGenericSignature.js +++ b/tests/baselines/reference/contextualTypingWithGenericSignature.js @@ -10,6 +10,4 @@ f2 = (x, y) => { return x } //// [contextualTypingWithGenericSignature.js] // If e is a FunctionExpression or ArrowFunctionExpression with no type parameters and no parameter or return type annotations, and T is a function type with EXACTLY ONE non - generic call signature, then any inferences made for type parameters referenced by the parameters of T’s call signature are fixed(section 4.12.2) and e is processed with the contextual type T, as described in section 4.9.3. var f2; -f2 = function (x, y) { - return x; -}; +f2 = function (x, y) { return x; }; diff --git a/tests/baselines/reference/contextuallyTypingOrOperator.js b/tests/baselines/reference/contextuallyTypingOrOperator.js index 6ffd81b1e0..6dc3e09bf8 100644 --- a/tests/baselines/reference/contextuallyTypingOrOperator.js +++ b/tests/baselines/reference/contextuallyTypingOrOperator.js @@ -7,27 +7,7 @@ var v3 = (s: string) => s.length || function (s: number) { return 1 }; var v4 = (s: number) => 1 || function (s: string) { return s.length }; //// [contextuallyTypingOrOperator.js] -var v = { - a: function (s) { - return s.length; - } -} || { - a: function (s) { - return 1; - } -}; -var v2 = function (s) { - return s.length || function (s) { - s.length; - }; -}; -var v3 = function (s) { - return s.length || function (s) { - return 1; - }; -}; -var v4 = function (s) { - return 1 || function (s) { - return s.length; - }; -}; +var v = { a: function (s) { return s.length; } } || { a: function (s) { return 1; } }; +var v2 = function (s) { return s.length || function (s) { s.length; }; }; +var v3 = function (s) { return s.length || function (s) { return 1; }; }; +var v4 = function (s) { return 1 || function (s) { return s.length; }; }; diff --git a/tests/baselines/reference/contextuallyTypingOrOperator2.js b/tests/baselines/reference/contextuallyTypingOrOperator2.js index 0b4dfa46bc..fa850929b3 100644 --- a/tests/baselines/reference/contextuallyTypingOrOperator2.js +++ b/tests/baselines/reference/contextuallyTypingOrOperator2.js @@ -4,17 +4,5 @@ var v: { a: (_: string) => number } = { a: s => s.length } || { a: s => 1 }; var v2 = (s: string) => s.length || function (s) { s.aaa }; //// [contextuallyTypingOrOperator2.js] -var v = { - a: function (s) { - return s.length; - } -} || { - a: function (s) { - return 1; - } -}; -var v2 = function (s) { - return s.length || function (s) { - s.aaa; - }; -}; +var v = { a: function (s) { return s.length; } } || { a: function (s) { return 1; } }; +var v2 = function (s) { return s.length || function (s) { s.aaa; }; }; diff --git a/tests/baselines/reference/convertKeywordsYes.js b/tests/baselines/reference/convertKeywordsYes.js index deae65b54c..a68f751f43 100644 --- a/tests/baselines/reference/convertKeywordsYes.js +++ b/tests/baselines/reference/convertKeywordsYes.js @@ -325,8 +325,7 @@ var string = 0; var get = 0; var yield = 0; var declare = 0; -function bigGeneric(c, a, b2, i, i2, l, m, n, p, p2, p3, p4, s, s2, s3, g, y, d) { -} +function bigGeneric(c, a, b2, i, i2, l, m, n, p, p2, p3, p4, s, s2, s3, g, y, d) { } var bigObject = { constructor: 0, any: 0, diff --git a/tests/baselines/reference/couldNotSelectGenericOverload.js b/tests/baselines/reference/couldNotSelectGenericOverload.js index 44bd87ace5..996ebde844 100644 --- a/tests/baselines/reference/couldNotSelectGenericOverload.js +++ b/tests/baselines/reference/couldNotSelectGenericOverload.js @@ -9,16 +9,9 @@ var b3G = makeArray2(1, ""); // error //// [couldNotSelectGenericOverload.js] -function makeArray(items) { - return items; -} -var b = [ - 1, - "" -]; +function makeArray(items) { return items; } +var b = [1, ""]; var b1G = makeArray(1, ""); // any, no error var b2G = makeArray(b); // any[] -function makeArray2(items) { - return items; -} +function makeArray2(items) { return items; } var b3G = makeArray2(1, ""); // error diff --git a/tests/baselines/reference/covariance1.js b/tests/baselines/reference/covariance1.js index 9c012ca85c..bed31338cb 100644 --- a/tests/baselines/reference/covariance1.js +++ b/tests/baselines/reference/covariance1.js @@ -27,15 +27,10 @@ var M; return XX; })(); M.XX = XX; - function f(y) { - } + function f(y) { } M.f = f; var a; - f({ - x: a - }); // ok + f({ x: a }); // ok var b; - f({ - x: b - }); // ok covariant subtype + f({ x: b }); // ok covariant subtype })(M || (M = {})); diff --git a/tests/baselines/reference/crashInResolveInterface.js b/tests/baselines/reference/crashInResolveInterface.js index 94c60a7cc8..85b6217726 100644 --- a/tests/baselines/reference/crashInResolveInterface.js +++ b/tests/baselines/reference/crashInResolveInterface.js @@ -20,8 +20,6 @@ interface C { //// [file1.js] var q1; -var x = q1.each(function (x) { - return c.log(x); -}); +var x = q1.each(function (x) { return c.log(x); }); //// [file2.js] /// diff --git a/tests/baselines/reference/customEventDetail.js b/tests/baselines/reference/customEventDetail.js index c88c6e677b..7207ecf062 100644 --- a/tests/baselines/reference/customEventDetail.js +++ b/tests/baselines/reference/customEventDetail.js @@ -8,8 +8,5 @@ var y = x.detail.name; //// [customEventDetail.js] var x; // valid since detail is any -x.initCustomEvent('hello', true, true, { - id: 12, - name: 'hello' -}); +x.initCustomEvent('hello', true, true, { id: 12, name: 'hello' }); var y = x.detail.name; diff --git a/tests/baselines/reference/debuggerEmit.js b/tests/baselines/reference/debuggerEmit.js index c2f730271b..8cf5dc69cd 100644 --- a/tests/baselines/reference/debuggerEmit.js +++ b/tests/baselines/reference/debuggerEmit.js @@ -3,7 +3,5 @@ var x = function () { debugger; } x(); //// [debuggerEmit.js] -var x = function () { - debugger; -}; +var x = function () { debugger; }; x(); diff --git a/tests/baselines/reference/declFileAliasUseBeforeDeclaration.js b/tests/baselines/reference/declFileAliasUseBeforeDeclaration.js index 30ba24ed40..7814e9641b 100644 --- a/tests/baselines/reference/declFileAliasUseBeforeDeclaration.js +++ b/tests/baselines/reference/declFileAliasUseBeforeDeclaration.js @@ -16,8 +16,7 @@ var Foo = (function () { })(); exports.Foo = Foo; //// [declFileAliasUseBeforeDeclaration_test.js] -function bar(a) { -} +function bar(a) { } exports.bar = bar; diff --git a/tests/baselines/reference/declFileForClassWithMultipleBaseClasses.js b/tests/baselines/reference/declFileForClassWithMultipleBaseClasses.js index 52d11836b1..5d7273098f 100644 --- a/tests/baselines/reference/declFileForClassWithMultipleBaseClasses.js +++ b/tests/baselines/reference/declFileForClassWithMultipleBaseClasses.js @@ -31,28 +31,22 @@ interface I extends A, B { var A = (function () { function A() { } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); var B = (function () { function B() { } - B.prototype.bar = function () { - }; + B.prototype.bar = function () { }; return B; })(); var D = (function () { function D() { } - D.prototype.baz = function () { - }; - D.prototype.bat = function () { - }; - D.prototype.foo = function () { - }; - D.prototype.bar = function () { - }; + D.prototype.baz = function () { }; + D.prototype.bat = function () { }; + D.prototype.foo = function () { }; + D.prototype.bar = function () { }; return D; })(); diff --git a/tests/baselines/reference/declFileForClassWithPrivateOverloadedFunction.js b/tests/baselines/reference/declFileForClassWithPrivateOverloadedFunction.js index 545b70f743..ee2dc8e83b 100644 --- a/tests/baselines/reference/declFileForClassWithPrivateOverloadedFunction.js +++ b/tests/baselines/reference/declFileForClassWithPrivateOverloadedFunction.js @@ -10,8 +10,7 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; + C.prototype.foo = function (x) { }; return C; })(); diff --git a/tests/baselines/reference/declFileGenericType.js b/tests/baselines/reference/declFileGenericType.js index 3c8120e8db..e01626a7ea 100644 --- a/tests/baselines/reference/declFileGenericType.js +++ b/tests/baselines/reference/declFileGenericType.js @@ -60,29 +60,17 @@ var C; return B; })(); C.B = B; - function F(x) { - return null; - } + function F(x) { return null; } C.F = F; - function F2(x) { - return null; - } + function F2(x) { return null; } C.F2 = F2; - function F3(x) { - return null; - } + function F3(x) { return null; } C.F3 = F3; - function F4(x) { - return null; - } + function F4(x) { return null; } C.F4 = F4; - function F5() { - return null; - } + function F5() { return null; } C.F5 = F5; - function F6(x) { - return null; - } + function F6(x) { return null; } C.F6 = F6; var D = (function () { function D(val) { @@ -98,8 +86,7 @@ exports.c = C.F2; exports.d = C.F3; exports.e = C.F4; exports.x = (new C.D(new C.A())).val; -function f() { -} +function f() { } exports.f = f; exports.g = C.F5(); var h = (function (_super) { diff --git a/tests/baselines/reference/declFileModuleAssignmentInObjectLiteralProperty.js b/tests/baselines/reference/declFileModuleAssignmentInObjectLiteralProperty.js index 400c53a171..443933069d 100644 --- a/tests/baselines/reference/declFileModuleAssignmentInObjectLiteralProperty.js +++ b/tests/baselines/reference/declFileModuleAssignmentInObjectLiteralProperty.js @@ -20,12 +20,8 @@ var m1; m1.c = c; })(m1 || (m1 = {})); var d = { - m1: { - m: m1 - }, - m2: { - c: m1.c - } + m1: { m: m1 }, + m2: { c: m1.c } }; diff --git a/tests/baselines/reference/declFileObjectLiteralWithAccessors.js b/tests/baselines/reference/declFileObjectLiteralWithAccessors.js index 7d7c6ee73d..85897bc2c9 100644 --- a/tests/baselines/reference/declFileObjectLiteralWithAccessors.js +++ b/tests/baselines/reference/declFileObjectLiteralWithAccessors.js @@ -15,12 +15,8 @@ point./*3*/x = 30; function makePoint(x) { return { b: 10, - get x() { - return x; - }, - set x(a) { - this.b = a; - } + get x() { return x; }, + set x(a) { this.b = a; } }; } ; diff --git a/tests/baselines/reference/declFileObjectLiteralWithOnlyGetter.js b/tests/baselines/reference/declFileObjectLiteralWithOnlyGetter.js index b3d4182963..dd39a30f7a 100644 --- a/tests/baselines/reference/declFileObjectLiteralWithOnlyGetter.js +++ b/tests/baselines/reference/declFileObjectLiteralWithOnlyGetter.js @@ -12,9 +12,7 @@ var /*2*/x = point./*3*/x; //// [declFileObjectLiteralWithOnlyGetter.js] function makePoint(x) { return { - get x() { - return x; - } + get x() { return x; } }; } ; diff --git a/tests/baselines/reference/declFileObjectLiteralWithOnlySetter.js b/tests/baselines/reference/declFileObjectLiteralWithOnlySetter.js index dae362caf3..e219e88505 100644 --- a/tests/baselines/reference/declFileObjectLiteralWithOnlySetter.js +++ b/tests/baselines/reference/declFileObjectLiteralWithOnlySetter.js @@ -13,9 +13,7 @@ point./*2*/x = 30; function makePoint(x) { return { b: 10, - set x(a) { - this.b = a; - } + set x(a) { this.b = a; } }; } ; diff --git a/tests/baselines/reference/declFilePrivateStatic.js b/tests/baselines/reference/declFilePrivateStatic.js index 5bec38e4de..326ce62171 100644 --- a/tests/baselines/reference/declFilePrivateStatic.js +++ b/tests/baselines/reference/declFilePrivateStatic.js @@ -18,33 +18,25 @@ class C { var C = (function () { function C() { } - C.a = function () { - }; - C.b = function () { - }; + C.a = function () { }; + C.b = function () { }; Object.defineProperty(C, "c", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); Object.defineProperty(C, "d", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); Object.defineProperty(C, "e", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); Object.defineProperty(C, "f", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/declFileRegressionTests.js b/tests/baselines/reference/declFileRegressionTests.js index 6178398ef3..a8bf23a8ea 100644 --- a/tests/baselines/reference/declFileRegressionTests.js +++ b/tests/baselines/reference/declFileRegressionTests.js @@ -8,13 +8,7 @@ var n = { w: null, x: '', y: () => { }, z: 32 }; //// [declFileRegressionTests.js] // 'null' not converted to 'any' in d.ts // function types not piped through correctly -var n = { - w: null, - x: '', - y: function () { - }, - z: 32 -}; +var n = { w: null, x: '', y: function () { }, z: 32 }; //// [declFileRegressionTests.d.ts] diff --git a/tests/baselines/reference/declFileRestParametersOfFunctionAndFunctionType.js b/tests/baselines/reference/declFileRestParametersOfFunctionAndFunctionType.js index 7c6122fc17..563551d67a 100644 --- a/tests/baselines/reference/declFileRestParametersOfFunctionAndFunctionType.js +++ b/tests/baselines/reference/declFileRestParametersOfFunctionAndFunctionType.js @@ -17,19 +17,11 @@ function f1() { args[_i - 0] = arguments[_i]; } } -function f2(x) { -} -function f3(x) { -} -function f4() { -} -function f5() { -} -var f6 = function () { - return [ - 10 - ]; -}; +function f2(x) { } +function f3(x) { } +function f4() { } +function f5() { } +var f6 = function () { return [10]; }; //// [declFileRestParametersOfFunctionAndFunctionType.d.ts] diff --git a/tests/baselines/reference/declFileTypeAnnotationArrayType.js b/tests/baselines/reference/declFileTypeAnnotationArrayType.js index 34c150cb99..0a9d04d6bc 100644 --- a/tests/baselines/reference/declFileTypeAnnotationArrayType.js +++ b/tests/baselines/reference/declFileTypeAnnotationArrayType.js @@ -79,60 +79,38 @@ var g = (function () { })(); // Just the name function foo() { - return [ - new c() - ]; + return [new c()]; } function foo2() { - return [ - new c() - ]; + return [new c()]; } // Qualified name function foo3() { - return [ - new m.c() - ]; + return [new m.c()]; } function foo4() { return m.c; } // Just the name with type arguments function foo5() { - return [ - new g() - ]; + return [new g()]; } function foo6() { - return [ - new g() - ]; + return [new g()]; } // Qualified name with type arguments function foo7() { - return [ - new m.g() - ]; + return [new m.g()]; } function foo8() { - return [ - new m.g() - ]; + return [new m.g()]; } // Array of function types function foo9() { - return [ - function () { - return new c(); - } - ]; + return [function () { return new c(); }]; } function foo10() { - return [ - function () { - return new c(); - } - ]; + return [function () { return new c(); }]; } diff --git a/tests/baselines/reference/declFileTypeAnnotationParenType.js b/tests/baselines/reference/declFileTypeAnnotationParenType.js index 7b8498ac2c..c61517c733 100644 --- a/tests/baselines/reference/declFileTypeAnnotationParenType.js +++ b/tests/baselines/reference/declFileTypeAnnotationParenType.js @@ -16,22 +16,10 @@ var c = (function () { } return c; })(); -var x = [ - function () { - return new c(); - } -]; -var y = [ - function () { - return new c(); - } -]; -var k = (function () { - return new c(); -}) || ""; -var l = (function () { - return new c(); -}) || ""; +var x = [function () { return new c(); }]; +var y = [function () { return new c(); }]; +var k = (function () { return new c(); }) || ""; +var l = (function () { return new c(); }) || ""; //// [declFileTypeAnnotationParenType.d.ts] diff --git a/tests/baselines/reference/declFileTypeAnnotationTupleType.js b/tests/baselines/reference/declFileTypeAnnotationTupleType.js index 3c610bb9d0..91d44c2b07 100644 --- a/tests/baselines/reference/declFileTypeAnnotationTupleType.js +++ b/tests/baselines/reference/declFileTypeAnnotationTupleType.js @@ -45,18 +45,9 @@ var g = (function () { return g; })(); // Just the name -var k = [ - new c(), - new m.c() -]; +var k = [new c(), new m.c()]; var l = k; -var x = [ - new g(), - new m.g(), - function () { - return new c(); - } -]; +var x = [new g(), new m.g(), function () { return new c(); }]; var y = x; diff --git a/tests/baselines/reference/declFileTypeAnnotationUnionType.js b/tests/baselines/reference/declFileTypeAnnotationUnionType.js index 40edf72d36..0a8e256ef2 100644 --- a/tests/baselines/reference/declFileTypeAnnotationUnionType.js +++ b/tests/baselines/reference/declFileTypeAnnotationUnionType.js @@ -51,12 +51,8 @@ var g = (function () { // Just the name var k = new c() || new m.c(); var l = new c() || new m.c(); -var x = new g() || new m.g() || (function () { - return new c(); -}); -var y = new g() || new m.g() || (function () { - return new c(); -}); +var x = new g() || new m.g() || (function () { return new c(); }); +var y = new g() || new m.g() || (function () { return new c(); }); //// [declFileTypeAnnotationUnionType.d.ts] diff --git a/tests/baselines/reference/declFileTypeofFunction.js b/tests/baselines/reference/declFileTypeofFunction.js index 2af519f411..656e02b8dd 100644 --- a/tests/baselines/reference/declFileTypeofFunction.js +++ b/tests/baselines/reference/declFileTypeofFunction.js @@ -34,12 +34,8 @@ function foo5(x: number) { } //// [declFileTypeofFunction.js] -function f() { - return undefined; -} -function g() { - return undefined; -} +function f() { return undefined; } +function g() { return undefined; } var b; function b1() { return b1; diff --git a/tests/baselines/reference/declFileTypeofInAnonymousType.js b/tests/baselines/reference/declFileTypeofInAnonymousType.js index 1a5071fd21..01025ed180 100644 --- a/tests/baselines/reference/declFileTypeofInAnonymousType.js +++ b/tests/baselines/reference/declFileTypeofInAnonymousType.js @@ -43,19 +43,11 @@ var b = { c: m1.c, m1: m1 }; -var c = { - m1: m1 -}; +var c = { m1: m1 }; var d = { - m: { - mod: m1 - }, - mc: { - cl: m1.c - }, - me: { - en: m1.e - }, + m: { mod: m1 }, + mc: { cl: m1.c }, + me: { en: m1.e }, mh: m1.e.holiday }; diff --git a/tests/baselines/reference/declInput-2.js b/tests/baselines/reference/declInput-2.js index 3ba5ae11bf..dcd37454ef 100644 --- a/tests/baselines/reference/declInput-2.js +++ b/tests/baselines/reference/declInput-2.js @@ -38,22 +38,12 @@ var M; var D = (function () { function D() { } - D.prototype.m232 = function () { - return null; - }; - D.prototype.m242 = function () { - return null; - }; - D.prototype.m252 = function () { - return null; - }; // don't generate - D.prototype.m26 = function (i) { - }; - D.prototype.m262 = function (i) { - }; - D.prototype.m3 = function () { - return new C(); - }; + D.prototype.m232 = function () { return null; }; + D.prototype.m242 = function () { return null; }; + D.prototype.m252 = function () { return null; }; // don't generate + D.prototype.m26 = function (i) { }; + D.prototype.m262 = function (i) { }; + D.prototype.m3 = function () { return new C(); }; return D; })(); M.D = D; diff --git a/tests/baselines/reference/declInput.js b/tests/baselines/reference/declInput.js index 538770668c..cd558c9340 100644 --- a/tests/baselines/reference/declInput.js +++ b/tests/baselines/reference/declInput.js @@ -14,16 +14,8 @@ class bar { var bar = (function () { function bar() { } - bar.prototype.f = function () { - return ''; - }; - bar.prototype.g = function () { - return { - a: null, - b: undefined, - c: void 4 - }; - }; + bar.prototype.f = function () { return ''; }; + bar.prototype.g = function () { return { a: null, b: undefined, c: void 4 }; }; bar.prototype.h = function (x, y, z) { if (x === void 0) { x = 4; } if (y === void 0) { y = null; } diff --git a/tests/baselines/reference/declInput3.js b/tests/baselines/reference/declInput3.js index 52328b01d6..3be31de3de 100644 --- a/tests/baselines/reference/declInput3.js +++ b/tests/baselines/reference/declInput3.js @@ -14,16 +14,8 @@ class bar { var bar = (function () { function bar() { } - bar.prototype.f = function () { - return ''; - }; - bar.prototype.g = function () { - return { - a: null, - b: undefined, - c: void 4 - }; - }; + bar.prototype.f = function () { return ''; }; + bar.prototype.g = function () { return { a: null, b: undefined, c: void 4 }; }; bar.prototype.h = function (x, y, z) { if (x === void 0) { x = 4; } if (y === void 0) { y = null; } diff --git a/tests/baselines/reference/declInput4.js b/tests/baselines/reference/declInput4.js index 18025c808f..07b6f091a1 100644 --- a/tests/baselines/reference/declInput4.js +++ b/tests/baselines/reference/declInput4.js @@ -32,14 +32,9 @@ var M; var D = (function () { function D() { } - D.prototype.m232 = function () { - return null; - }; - D.prototype.m242 = function () { - return null; - }; - D.prototype.m26 = function (i) { - }; + D.prototype.m232 = function () { return null; }; + D.prototype.m242 = function () { return null; }; + D.prototype.m26 = function (i) { }; return D; })(); M.D = D; diff --git a/tests/baselines/reference/declarationEmitDestructuringArrayPattern1.js b/tests/baselines/reference/declarationEmitDestructuringArrayPattern1.js index 7ee32cab16..088bb4e849 100644 --- a/tests/baselines/reference/declarationEmitDestructuringArrayPattern1.js +++ b/tests/baselines/reference/declarationEmitDestructuringArrayPattern1.js @@ -10,27 +10,11 @@ var [x2] = a; // emit x2: number | string var [x3, y3, z3] = a; // emit x3, y3, z3 //// [declarationEmitDestructuringArrayPattern1.js] -var _a = [ - 1, - "hello" -]; // Dont emit anything -var x = ([ - 1, - "hello" -])[0]; // emit x: number -var _b = [ - 1, - "hello" -], x1 = _b[0], y1 = _b[1]; // emit x1: number, y1: string -var _c = [ - 0, - 1, - 2 -], z1 = _c[2]; // emit z1: number -var a = [ - 1, - "hello" -]; +var _a = [1, "hello"]; // Dont emit anything +var x = ([1, "hello"])[0]; // emit x: number +var _b = [1, "hello"], x1 = _b[0], y1 = _b[1]; // emit x1: number, y1: string +var _c = [0, 1, 2], z1 = _c[2]; // emit z1: number +var a = [1, "hello"]; var x2 = a[0]; // emit x2: number | string var x3 = a[0], y3 = a[1], z3 = a[2]; // emit x3, y3, z3 diff --git a/tests/baselines/reference/declarationEmitDestructuringArrayPattern2.js b/tests/baselines/reference/declarationEmitDestructuringArrayPattern2.js index 5734b9bc6f..818b3a6f7a 100644 --- a/tests/baselines/reference/declarationEmitDestructuringArrayPattern2.js +++ b/tests/baselines/reference/declarationEmitDestructuringArrayPattern2.js @@ -11,50 +11,12 @@ var [a3, b3] = [[x13, y13], { x: x13, y: y13 }]; //// [declarationEmitDestructuringArrayPattern2.js] -var _a = [ - 1, - [ - "hello", - [ - true - ] - ] -], x10 = _a[0], _b = _a[1], y10 = _b[0], z10 = _b[1][0]; -var _c = [ - 1, - "hello" -], _d = _c[0], x11 = _d === void 0 ? 0 : _d, _e = _c[1], y11 = _e === void 0 ? "" : _e; +var _a = [1, ["hello", [true]]], x10 = _a[0], _b = _a[1], y10 = _b[0], z10 = _b[1][0]; +var _c = [1, "hello"], _d = _c[0], x11 = _d === void 0 ? 0 : _d, _e = _c[1], y11 = _e === void 0 ? "" : _e; var _f = [], a11 = _f[0], b11 = _f[1], c11 = _f[2]; -var _g = [ - 1, - [ - "hello", - { - x12: 5, - y12: true - } - ] -], a2 = _g[0], _h = _g[1], _j = _h === void 0 ? [ - "abc", - { - x12: 10, - y12: false - } -] : _h, b2 = _j[0], _k = _j[1], x12 = _k.x12, c2 = _k.y12; -var _l = [ - 1, - "hello" -], x13 = _l[0], y13 = _l[1]; -var _m = [ - [ - x13, - y13 - ], - { - x: x13, - y: y13 - } -], a3 = _m[0], b3 = _m[1]; +var _g = [1, ["hello", { x12: 5, y12: true }]], a2 = _g[0], _h = _g[1], _j = _h === void 0 ? ["abc", { x12: 10, y12: false }] : _h, b2 = _j[0], _k = _j[1], x12 = _k.x12, c2 = _k.y12; +var _l = [1, "hello"], x13 = _l[0], y13 = _l[1]; +var _m = [[x13, y13], { x: x13, y: y13 }], a3 = _m[0], b3 = _m[1]; //// [declarationEmitDestructuringArrayPattern2.d.ts] diff --git a/tests/baselines/reference/declarationEmitDestructuringArrayPattern3.js b/tests/baselines/reference/declarationEmitDestructuringArrayPattern3.js index 258fa17d7f..84ab9f242e 100644 --- a/tests/baselines/reference/declarationEmitDestructuringArrayPattern3.js +++ b/tests/baselines/reference/declarationEmitDestructuringArrayPattern3.js @@ -6,10 +6,7 @@ module M { //// [declarationEmitDestructuringArrayPattern3.js] var M; (function (M) { - _a = [ - 1, - 2 - ], M.a = _a[0], M.b = _a[1]; + _a = [1, 2], M.a = _a[0], M.b = _a[1]; var _a; })(M || (M = {})); diff --git a/tests/baselines/reference/declarationEmitDestructuringArrayPattern4.js b/tests/baselines/reference/declarationEmitDestructuringArrayPattern4.js index 97a8c20b73..f19a4a840b 100644 --- a/tests/baselines/reference/declarationEmitDestructuringArrayPattern4.js +++ b/tests/baselines/reference/declarationEmitDestructuringArrayPattern4.js @@ -10,46 +10,14 @@ var [x18, y18, ...a12] = [1, "hello", true]; var [x19, y19, z19, ...a13] = [1, "hello", true]; //// [declarationEmitDestructuringArrayPattern4.js] -var _a = [ - 1, - 2, - 3 -], a5 = _a.slice(0); -var _b = [ - 1, - 2, - 3 -], x14 = _b[0], a6 = _b.slice(1); -var _c = [ - 1, - 2, - 3 -], x15 = _c[0], y15 = _c[1], a7 = _c.slice(2); -var _d = [ - 1, - 2, - 3 -], x16 = _d[0], y16 = _d[1], z16 = _d[2], a8 = _d.slice(3); -var _e = [ - 1, - "hello", - true -], a9 = _e.slice(0); -var _f = [ - 1, - "hello", - true -], x17 = _f[0], a10 = _f.slice(1); -var _g = [ - 1, - "hello", - true -], x18 = _g[0], y18 = _g[1], a12 = _g.slice(2); -var _h = [ - 1, - "hello", - true -], x19 = _h[0], y19 = _h[1], z19 = _h[2], a13 = _h.slice(3); +var _a = [1, 2, 3], a5 = _a.slice(0); +var _b = [1, 2, 3], x14 = _b[0], a6 = _b.slice(1); +var _c = [1, 2, 3], x15 = _c[0], y15 = _c[1], a7 = _c.slice(2); +var _d = [1, 2, 3], x16 = _d[0], y16 = _d[1], z16 = _d[2], a8 = _d.slice(3); +var _e = [1, "hello", true], a9 = _e.slice(0); +var _f = [1, "hello", true], x17 = _f[0], a10 = _f.slice(1); +var _g = [1, "hello", true], x18 = _g[0], y18 = _g[1], a12 = _g.slice(2); +var _h = [1, "hello", true], x19 = _h[0], y19 = _h[1], z19 = _h[2], a13 = _h.slice(3); //// [declarationEmitDestructuringArrayPattern4.d.ts] diff --git a/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern.js b/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern.js index 9b48f418f5..d94da79ad9 100644 --- a/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern.js +++ b/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern.js @@ -23,52 +23,19 @@ module m { } //// [declarationEmitDestructuringObjectLiteralPattern.js] -var _a = { - x: 5, - y: "hello" -}; -var x4 = ({ - x4: 5, - y4: "hello" -}).x4; -var y5 = ({ - x5: 5, - y5: "hello" -}).y5; -var _b = { - x6: 5, - y6: "hello" -}, x6 = _b.x6, y6 = _b.y6; -var a1 = ({ - x7: 5, - y7: "hello" -}).x7; -var b1 = ({ - x8: 5, - y8: "hello" -}).y8; -var _c = { - x9: 5, - y9: "hello" -}, a2 = _c.x9, b2 = _c.y9; -var _d = { - a: 1, - b: { - a: "hello", - b: { - a: true - } - } -}, x11 = _d.a, _e = _d.b, y11 = _e.a, z11 = _e.b.a; +var _a = { x: 5, y: "hello" }; +var x4 = ({ x4: 5, y4: "hello" }).x4; +var y5 = ({ x5: 5, y5: "hello" }).y5; +var _b = { x6: 5, y6: "hello" }, x6 = _b.x6, y6 = _b.y6; +var a1 = ({ x7: 5, y7: "hello" }).x7; +var b1 = ({ x8: 5, y8: "hello" }).y8; +var _c = { x9: 5, y9: "hello" }, a2 = _c.x9, b2 = _c.y9; +var _d = { a: 1, b: { a: "hello", b: { a: true } } }, x11 = _d.a, _e = _d.b, y11 = _e.a, z11 = _e.b.a; function f15() { var a4 = "hello"; var b4 = 1; var c4 = true; - return { - a4: a4, - b4: b4, - c4: c4 - }; + return { a4: a4, b4: b4, c4: c4 }; } var _f = f15(), a4 = _f.a4, b4 = _f.b4, c4 = _f.c4; var m; diff --git a/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern1.js b/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern1.js index 889047185e..2c14e74303 100644 --- a/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern1.js +++ b/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern1.js @@ -9,34 +9,13 @@ var { y8: b1 } = { x8: 5, y8: "hello" }; var { x9: a2, y9: b2 } = { x9: 5, y9: "hello" }; //// [declarationEmitDestructuringObjectLiteralPattern1.js] -var _a = { - x: 5, - y: "hello" -}; -var x4 = ({ - x4: 5, - y4: "hello" -}).x4; -var y5 = ({ - x5: 5, - y5: "hello" -}).y5; -var _b = { - x6: 5, - y6: "hello" -}, x6 = _b.x6, y6 = _b.y6; -var a1 = ({ - x7: 5, - y7: "hello" -}).x7; -var b1 = ({ - x8: 5, - y8: "hello" -}).y8; -var _c = { - x9: 5, - y9: "hello" -}, a2 = _c.x9, b2 = _c.y9; +var _a = { x: 5, y: "hello" }; +var x4 = ({ x4: 5, y4: "hello" }).x4; +var y5 = ({ x5: 5, y5: "hello" }).y5; +var _b = { x6: 5, y6: "hello" }, x6 = _b.x6, y6 = _b.y6; +var a1 = ({ x7: 5, y7: "hello" }).x7; +var b1 = ({ x8: 5, y8: "hello" }).y8; +var _c = { x9: 5, y9: "hello" }, a2 = _c.x9, b2 = _c.y9; //// [declarationEmitDestructuringObjectLiteralPattern1.d.ts] diff --git a/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern2.js b/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern2.js index 140fc03780..7e5a3d9d2f 100644 --- a/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern2.js +++ b/tests/baselines/reference/declarationEmitDestructuringObjectLiteralPattern2.js @@ -15,24 +15,12 @@ module m { } //// [declarationEmitDestructuringObjectLiteralPattern2.js] -var _a = { - a: 1, - b: { - a: "hello", - b: { - a: true - } - } -}, x11 = _a.a, _b = _a.b, y11 = _b.a, z11 = _b.b.a; +var _a = { a: 1, b: { a: "hello", b: { a: true } } }, x11 = _a.a, _b = _a.b, y11 = _b.a, z11 = _b.b.a; function f15() { var a4 = "hello"; var b4 = 1; var c4 = true; - return { - a4: a4, - b4: b4, - c4: c4 - }; + return { a4: a4, b4: b4, c4: c4 }; } var _c = f15(), a4 = _c.a4, b4 = _c.b4, c4 = _c.c4; var m; diff --git a/tests/baselines/reference/declarationEmitDestructuringPrivacyError.js b/tests/baselines/reference/declarationEmitDestructuringPrivacyError.js index c076dca665..fa3cae9478 100644 --- a/tests/baselines/reference/declarationEmitDestructuringPrivacyError.js +++ b/tests/baselines/reference/declarationEmitDestructuringPrivacyError.js @@ -13,10 +13,6 @@ var m; } return c; })(); - _a = [ - 10, - new c(), - 30 - ], m.x = _a[0], m.y = _a[1], m.z = _a[2]; + _a = [10, new c(), 30], m.x = _a[0], m.y = _a[1], m.z = _a[2]; var _a; })(m || (m = {})); diff --git a/tests/baselines/reference/declarationEmit_nameConflicts.js b/tests/baselines/reference/declarationEmit_nameConflicts.js index 161224659f..ae517bb746 100644 --- a/tests/baselines/reference/declarationEmit_nameConflicts.js +++ b/tests/baselines/reference/declarationEmit_nameConflicts.js @@ -64,8 +64,7 @@ module.exports = f; var im = require('declarationEmit_nameConflicts_1'); var M; (function (M) { - function f() { - } + function f() { } M.f = f; var C = (function () { function C() { @@ -75,8 +74,7 @@ var M; M.C = C; var N; (function (N) { - function g() { - } + function g() { } N.g = g; ; })(N = M.N || (M.N = {})); @@ -89,8 +87,7 @@ var M; (function (M) { var P; (function (P) { - function f() { - } + function f() { } P.f = f; var C = (function () { function C() { @@ -100,8 +97,7 @@ var M; P.C = C; var N; (function (N) { - function g() { - } + function g() { } N.g = g; ; })(N = P.N || (P.N = {})); @@ -117,8 +113,7 @@ var M; (function (M) { var Q; (function (Q) { - function f() { - } + function f() { } Q.f = f; var C = (function () { function C() { @@ -128,8 +123,7 @@ var M; Q.C = C; var N; (function (N) { - function g() { - } + function g() { } N.g = g; ; })(N = Q.N || (Q.N = {})); diff --git a/tests/baselines/reference/declarationEmit_nameConflicts2.js b/tests/baselines/reference/declarationEmit_nameConflicts2.js index 43167f531d..2a228080c6 100644 --- a/tests/baselines/reference/declarationEmit_nameConflicts2.js +++ b/tests/baselines/reference/declarationEmit_nameConflicts2.js @@ -22,8 +22,7 @@ var X; (function (Y) { var base; (function (base) { - function f() { - } + function f() { } base.f = f; var C = (function () { function C() { diff --git a/tests/baselines/reference/declarationEmit_nameConflicts3.js b/tests/baselines/reference/declarationEmit_nameConflicts3.js index 848343362b..0d68c38cfd 100644 --- a/tests/baselines/reference/declarationEmit_nameConflicts3.js +++ b/tests/baselines/reference/declarationEmit_nameConflicts3.js @@ -37,20 +37,17 @@ var M; (function (M) { var D; (function (D) { - function f() { - } + function f() { } D.f = f; })(D = M.D || (M.D = {})); var C; (function (C) { - function f() { - } + function f() { } C.f = f; })(C = M.C || (M.C = {})); var E; (function (E) { - function f() { - } + function f() { } E.f = f; })(E = M.E || (M.E = {})); })(M || (M = {})); @@ -61,8 +58,7 @@ var M; var C = (function () { function C() { } - C.f = function () { - }; + C.f = function () { }; return C; })(); P.C = C; diff --git a/tests/baselines/reference/declarationEmit_protectedMembers.js b/tests/baselines/reference/declarationEmit_protectedMembers.js index dc8506b220..61a4ebdfca 100644 --- a/tests/baselines/reference/declarationEmit_protectedMembers.js +++ b/tests/baselines/reference/declarationEmit_protectedMembers.js @@ -65,11 +65,8 @@ var C1 = (function () { return this.x; }; Object.defineProperty(C1.prototype, "accessor", { - get: function () { - return 0; - }, - set: function (a) { - }, + get: function () { return 0; }, + set: function (a) { }, enumerable: true, configurable: true }); @@ -77,15 +74,12 @@ var C1 = (function () { return this.sx; }; Object.defineProperty(C1, "staticSetter", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); Object.defineProperty(C1, "staticGetter", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); @@ -118,9 +112,7 @@ var C3 = (function (_super) { return _super.sf.call(this); }; Object.defineProperty(C3, "staticGetter", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/declarationsAndAssignments.js b/tests/baselines/reference/declarationsAndAssignments.js index 6772a842a4..032f4cb0e6 100644 --- a/tests/baselines/reference/declarationsAndAssignments.js +++ b/tests/baselines/reference/declarationsAndAssignments.js @@ -182,35 +182,16 @@ function f21() { //// [declarationsAndAssignments.js] function f0() { - var _a = [ - 1, - "hello" - ]; - var x = ([ - 1, - "hello" - ])[0]; - var _b = [ - 1, - "hello" - ], x = _b[0], y = _b[1]; - var _c = [ - 1, - "hello" - ], x = _c[0], y = _c[1], z = _c[2]; // Error - var _d = [ - 0, - 1, - 2 - ], z = _d[2]; + var _a = [1, "hello"]; + var x = ([1, "hello"])[0]; + var _b = [1, "hello"], x = _b[0], y = _b[1]; + var _c = [1, "hello"], x = _c[0], y = _c[1], z = _c[2]; // Error + var _d = [0, 1, 2], z = _d[2]; var x; var y; } function f1() { - var a = [ - 1, - "hello" - ]; + var a = [1, "hello"]; var x = a[0]; var x = a[0], y = a[1]; var x = a[0], y = a[1], z = a[2]; @@ -219,161 +200,71 @@ function f1() { var z; } function f2() { - var _a = { - x: 5, - y: "hello" - }; - var x = ({ - x: 5, - y: "hello" - }).x; - var y = ({ - x: 5, - y: "hello" - }).y; - var _b = { - x: 5, - y: "hello" - }, x = _b.x, y = _b.y; + var _a = { x: 5, y: "hello" }; + var x = ({ x: 5, y: "hello" }).x; + var y = ({ x: 5, y: "hello" }).y; + var _b = { x: 5, y: "hello" }, x = _b.x, y = _b.y; var x; var y; - var a = ({ - x: 5, - y: "hello" - }).x; - var b = ({ - x: 5, - y: "hello" - }).y; - var _c = { - x: 5, - y: "hello" - }, a = _c.x, b = _c.y; + var a = ({ x: 5, y: "hello" }).x; + var b = ({ x: 5, y: "hello" }).y; + var _c = { x: 5, y: "hello" }, a = _c.x, b = _c.y; var a; var b; } function f3() { - var _a = [ - 1, - [ - "hello", - [ - true - ] - ] - ], x = _a[0], _b = _a[1], y = _b[0], z = _b[1][0]; + var _a = [1, ["hello", [true]]], x = _a[0], _b = _a[1], y = _b[0], z = _b[1][0]; var x; var y; var z; } function f4() { - var _a = { - a: 1, - b: { - a: "hello", - b: { - a: true - } - } - }, x = _a.a, _b = _a.b, y = _b.a, z = _b.b.a; + var _a = { a: 1, b: { a: "hello", b: { a: true } } }, x = _a.a, _b = _a.b, y = _b.a, z = _b.b.a; var x; var y; var z; } function f6() { - var _a = [ - 1, - "hello" - ], _b = _a[0], x = _b === void 0 ? 0 : _b, _c = _a[1], y = _c === void 0 ? "" : _c; + var _a = [1, "hello"], _b = _a[0], x = _b === void 0 ? 0 : _b, _c = _a[1], y = _c === void 0 ? "" : _c; var x; var y; } function f7() { - var _a = [ - 1, - "hello" - ], _b = _a[0], x = _b === void 0 ? 0 : _b, _c = _a[1], y = _c === void 0 ? 1 : _c; // Error, initializer for y must be string + var _a = [1, "hello"], _b = _a[0], x = _b === void 0 ? 0 : _b, _c = _a[1], y = _c === void 0 ? 1 : _c; // Error, initializer for y must be string var x; var y; } function f8() { var _a = [], a = _a[0], b = _a[1], c = _a[2]; // Ok, [] is an array - var _b = [ - 1 - ], d = _b[0], e = _b[1], f = _b[2]; // Error, [1] is a tuple + var _b = [1], d = _b[0], e = _b[1], f = _b[2]; // Error, [1] is a tuple } function f9() { var _a = {}, a = _a[0], b = _a[1]; // Error, not array type - var _b = { - 0: 10, - 1: 20 - }, c = _b[0], d = _b[1]; // Error, not array type - var _c = [ - 10, - 20 - ], e = _c[0], f = _c[1]; + var _b = { 0: 10, 1: 20 }, c = _b[0], d = _b[1]; // Error, not array type + var _c = [10, 20], e = _c[0], f = _c[1]; } function f10() { var _a = {}, a = _a.a, b = _a.b; // Error var _b = [], a = _b.a, b = _b.b; // Error } function f11() { - var _a = { - x: 10, - y: "hello" - }, a = _a.x, b = _a.y; - var _b = { - 0: 10, - 1: "hello" - }, a = _b[0], b = _b[1]; - var _c = { - "<": 10, - ">": "hello" - }, a = _c["<"], b = _c[">"]; - var _d = [ - 10, - "hello" - ], a = _d[0], b = _d[1]; + var _a = { x: 10, y: "hello" }, a = _a.x, b = _a.y; + var _b = { 0: 10, 1: "hello" }, a = _b[0], b = _b[1]; + var _c = { "<": 10, ">": "hello" }, a = _c["<"], b = _c[">"]; + var _d = [10, "hello"], a = _d[0], b = _d[1]; var a; var b; } function f12() { - var _a = [ - 1, - [ - "hello", - { - x: 5, - y: true - } - ] - ], a = _a[0], _b = _a[1], _c = _b === void 0 ? [ - "abc", - { - x: 10, - y: false - } - ] : _b, b = _c[0], _d = _c[1], x = _d.x, c = _d.y; + var _a = [1, ["hello", { x: 5, y: true }]], a = _a[0], _b = _a[1], _c = _b === void 0 ? ["abc", { x: 10, y: false }] : _b, b = _c[0], _d = _c[1], x = _d.x, c = _d.y; var a; var b; var x; var c; } function f13() { - var _a = [ - 1, - "hello" - ], x = _a[0], y = _a[1]; - var _b = [ - [ - x, - y - ], - { - x: x, - y: y - } - ], a = _b[0], b = _b[1]; + var _a = [1, "hello"], x = _a[0], y = _a[1]; + var _b = [[x, y], { x: x, y: y }], a = _b[0], b = _b[1]; } function f14(_a) { var _b = _a[0], a = _b === void 0 ? 1 : _b, _c = _a[1], _d = _c[0], b = _d === void 0 ? "hello" : _d, _e = _c[1], x = _e.x, _f = _e.y, c = _f === void 0 ? false : _f; @@ -381,51 +272,19 @@ function f14(_a) { var b; var c; } -f14([ - 2, - [ - "abc", - { - x: 0, - y: true - } - ] -]); -f14([ - 2, - [ - "abc", - { - x: 0 - } - ] -]); -f14([ - 2, - [ - "abc", - { - y: false - } - ] -]); // Error, no x +f14([2, ["abc", { x: 0, y: true }]]); +f14([2, ["abc", { x: 0 }]]); +f14([2, ["abc", { y: false }]]); // Error, no x var M; (function (M) { - _a = [ - 1, - 2 - ], M.a = _a[0], M.b = _a[1]; + _a = [1, 2], M.a = _a[0], M.b = _a[1]; var _a; })(M || (M = {})); function f15() { var a = "hello"; var b = 1; var c = true; - return { - a: a, - b: b, - c: c - }; + return { a: a, b: b, c: c }; } function f16() { var _a = f15(), a = _a.a, b = _a.b, c = _a.c; @@ -434,66 +293,27 @@ function f17(_a) { var _b = _a.a, a = _b === void 0 ? "" : _b, _c = _a.b, b = _c === void 0 ? 0 : _c, _d = _a.c, c = _d === void 0 ? false : _d; } f17({}); -f17({ - a: "hello" -}); -f17({ - c: true -}); +f17({ a: "hello" }); +f17({ c: true }); f17(f15()); function f18() { var a; var b; var aa; - (_a = { - a: a, - b: b - }, a = _a.a, b = _a.b, _a); - (_b = { - b: b, - a: a - }, a = _b.a, b = _b.b, _b); - _c = [ - a, - b - ], aa[0] = _c[0], b = _c[1]; - _d = [ - b, - a - ], a = _d[0], b = _d[1]; // Error - _e = [ - 2, - "def" - ], _f = _e[0], a = _f === void 0 ? 1 : _f, _g = _e[1], b = _g === void 0 ? "abc" : _g; + (_a = { a: a, b: b }, a = _a.a, b = _a.b, _a); + (_b = { b: b, a: a }, a = _b.a, b = _b.b, _b); + _c = [a, b], aa[0] = _c[0], b = _c[1]; + _d = [b, a], a = _d[0], b = _d[1]; // Error + _e = [2, "def"], _f = _e[0], a = _f === void 0 ? 1 : _f, _g = _e[1], b = _g === void 0 ? "abc" : _g; var _a, _b, _c, _d, _e, _f, _g; } function f19() { var a, b; - _a = [ - 1, - 2 - ], a = _a[0], b = _a[1]; - _b = [ - b, - a - ], a = _b[0], b = _b[1]; - (_c = { - b: b, - a: a - }, a = _c.a, b = _c.b, _c); - _d = ([ - [ - 2, - 3 - ] - ])[0], _e = _d === void 0 ? [ - 1, - 2 - ] : _d, a = _e[0], b = _e[1]; - var x = (_f = [ - 1, - 2 - ], a = _f[0], b = _f[1], _f); + _a = [1, 2], a = _a[0], b = _a[1]; + _b = [b, a], a = _b[0], b = _b[1]; + (_c = { b: b, a: a }, a = _c.a, b = _c.b, _c); + _d = ([[2, 3]])[0], _e = _d === void 0 ? [1, 2] : _d, a = _e[0], b = _e[1]; + var x = (_f = [1, 2], a = _f[0], b = _f[1], _f); var _a, _b, _c, _d, _e, _f; } function f20() { @@ -501,46 +321,14 @@ function f20() { var x; var y; var z; - var _a = [ - 1, - 2, - 3 - ], a = _a.slice(0); - var _b = [ - 1, - 2, - 3 - ], x = _b[0], a = _b.slice(1); - var _c = [ - 1, - 2, - 3 - ], x = _c[0], y = _c[1], a = _c.slice(2); - var _d = [ - 1, - 2, - 3 - ], x = _d[0], y = _d[1], z = _d[2], a = _d.slice(3); - _e = [ - 1, - 2, - 3 - ], a = _e.slice(0); - _f = [ - 1, - 2, - 3 - ], x = _f[0], a = _f.slice(1); - _g = [ - 1, - 2, - 3 - ], x = _g[0], y = _g[1], a = _g.slice(2); - _h = [ - 1, - 2, - 3 - ], x = _h[0], y = _h[1], z = _h[2], a = _h.slice(3); + var _a = [1, 2, 3], a = _a.slice(0); + var _b = [1, 2, 3], x = _b[0], a = _b.slice(1); + var _c = [1, 2, 3], x = _c[0], y = _c[1], a = _c.slice(2); + var _d = [1, 2, 3], x = _d[0], y = _d[1], z = _d[2], a = _d.slice(3); + _e = [1, 2, 3], a = _e.slice(0); + _f = [1, 2, 3], x = _f[0], a = _f.slice(1); + _g = [1, 2, 3], x = _g[0], y = _g[1], a = _g.slice(2); + _h = [1, 2, 3], x = _h[0], y = _h[1], z = _h[2], a = _h.slice(3); var _e, _f, _g, _h; } function f21() { @@ -548,45 +336,13 @@ function f21() { var x; var y; var z; - var _a = [ - 1, - "hello", - true - ], a = _a.slice(0); - var _b = [ - 1, - "hello", - true - ], x = _b[0], a = _b.slice(1); - var _c = [ - 1, - "hello", - true - ], x = _c[0], y = _c[1], a = _c.slice(2); - var _d = [ - 1, - "hello", - true - ], x = _d[0], y = _d[1], z = _d[2], a = _d.slice(3); - _e = [ - 1, - "hello", - true - ], a = _e.slice(0); - _f = [ - 1, - "hello", - true - ], x = _f[0], a = _f.slice(1); - _g = [ - 1, - "hello", - true - ], x = _g[0], y = _g[1], a = _g.slice(2); - _h = [ - 1, - "hello", - true - ], x = _h[0], y = _h[1], z = _h[2], a = _h.slice(3); + var _a = [1, "hello", true], a = _a.slice(0); + var _b = [1, "hello", true], x = _b[0], a = _b.slice(1); + var _c = [1, "hello", true], x = _c[0], y = _c[1], a = _c.slice(2); + var _d = [1, "hello", true], x = _d[0], y = _d[1], z = _d[2], a = _d.slice(3); + _e = [1, "hello", true], a = _e.slice(0); + _f = [1, "hello", true], x = _f[0], a = _f.slice(1); + _g = [1, "hello", true], x = _g[0], y = _g[1], a = _g.slice(2); + _h = [1, "hello", true], x = _h[0], y = _h[1], z = _h[2], a = _h.slice(3); var _e, _f, _g, _h; } diff --git a/tests/baselines/reference/decoratorOnClassAccessor1.js b/tests/baselines/reference/decoratorOnClassAccessor1.js index d78e776cb9..c8a96c4072 100644 --- a/tests/baselines/reference/decoratorOnClassAccessor1.js +++ b/tests/baselines/reference/decoratorOnClassAccessor1.js @@ -23,9 +23,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "accessor", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/decoratorOnClassAccessor2.js b/tests/baselines/reference/decoratorOnClassAccessor2.js index f1bfce9ea6..bffbfb4b70 100644 --- a/tests/baselines/reference/decoratorOnClassAccessor2.js +++ b/tests/baselines/reference/decoratorOnClassAccessor2.js @@ -23,9 +23,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "accessor", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/decoratorOnClassAccessor4.js b/tests/baselines/reference/decoratorOnClassAccessor4.js index 77dbc569e5..1b4853b69b 100644 --- a/tests/baselines/reference/decoratorOnClassAccessor4.js +++ b/tests/baselines/reference/decoratorOnClassAccessor4.js @@ -23,8 +23,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "accessor", { - set: function (value) { - }, + set: function (value) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/decoratorOnClassAccessor5.js b/tests/baselines/reference/decoratorOnClassAccessor5.js index bfd6518c59..eec246c7ea 100644 --- a/tests/baselines/reference/decoratorOnClassAccessor5.js +++ b/tests/baselines/reference/decoratorOnClassAccessor5.js @@ -23,8 +23,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "accessor", { - set: function (value) { - }, + set: function (value) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/decoratorOnClassAccessor6.js b/tests/baselines/reference/decoratorOnClassAccessor6.js index 905e3d3b2d..771d937634 100644 --- a/tests/baselines/reference/decoratorOnClassAccessor6.js +++ b/tests/baselines/reference/decoratorOnClassAccessor6.js @@ -14,5 +14,4 @@ var C = (function () { public; set; accessor(value, number); -{ -} +{ } diff --git a/tests/baselines/reference/decoratorOnClassMethod1.js b/tests/baselines/reference/decoratorOnClassMethod1.js index be9c00290f..b7230cca8b 100644 --- a/tests/baselines/reference/decoratorOnClassMethod1.js +++ b/tests/baselines/reference/decoratorOnClassMethod1.js @@ -22,8 +22,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { var C = (function () { function C() { } - C.prototype.method = function () { - }; + C.prototype.method = function () { }; Object.defineProperty(C.prototype, "method", __decorate([dec], C.prototype, "method", Object.getOwnPropertyDescriptor(C.prototype, "method"))); return C; })(); diff --git a/tests/baselines/reference/decoratorOnClassMethod10.js b/tests/baselines/reference/decoratorOnClassMethod10.js index 3dd38f806b..137a0c2839 100644 --- a/tests/baselines/reference/decoratorOnClassMethod10.js +++ b/tests/baselines/reference/decoratorOnClassMethod10.js @@ -22,8 +22,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { var C = (function () { function C() { } - C.prototype.method = function () { - }; + C.prototype.method = function () { }; Object.defineProperty(C.prototype, "method", __decorate([dec], C.prototype, "method", Object.getOwnPropertyDescriptor(C.prototype, "method"))); return C; })(); diff --git a/tests/baselines/reference/decoratorOnClassMethod2.js b/tests/baselines/reference/decoratorOnClassMethod2.js index b7df7b9ba9..ceddff2f15 100644 --- a/tests/baselines/reference/decoratorOnClassMethod2.js +++ b/tests/baselines/reference/decoratorOnClassMethod2.js @@ -22,8 +22,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { var C = (function () { function C() { } - C.prototype.method = function () { - }; + C.prototype.method = function () { }; Object.defineProperty(C.prototype, "method", __decorate([dec], C.prototype, "method", Object.getOwnPropertyDescriptor(C.prototype, "method"))); return C; })(); diff --git a/tests/baselines/reference/decoratorOnClassMethod3.js b/tests/baselines/reference/decoratorOnClassMethod3.js index 3a01184527..3ac97697e8 100644 --- a/tests/baselines/reference/decoratorOnClassMethod3.js +++ b/tests/baselines/reference/decoratorOnClassMethod3.js @@ -13,5 +13,4 @@ var C = (function () { })(); public; method(); -{ -} +{ } diff --git a/tests/baselines/reference/decoratorOnClassMethod4.js b/tests/baselines/reference/decoratorOnClassMethod4.js index 7021e5af32..55798a2e1d 100644 --- a/tests/baselines/reference/decoratorOnClassMethod4.js +++ b/tests/baselines/reference/decoratorOnClassMethod4.js @@ -20,8 +20,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { return value; }; class C { - [_a = "method"]() { - } + [_a = "method"]() { } } Object.defineProperty(C.prototype, _a, __decorate([dec], C.prototype, _a, Object.getOwnPropertyDescriptor(C.prototype, _a))); var _a; diff --git a/tests/baselines/reference/decoratorOnClassMethod5.js b/tests/baselines/reference/decoratorOnClassMethod5.js index 3bde0968ea..2fe671e1b5 100644 --- a/tests/baselines/reference/decoratorOnClassMethod5.js +++ b/tests/baselines/reference/decoratorOnClassMethod5.js @@ -20,8 +20,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { return value; }; class C { - [_a = "method"]() { - } + [_a = "method"]() { } } Object.defineProperty(C.prototype, _a, __decorate([dec()], C.prototype, _a, Object.getOwnPropertyDescriptor(C.prototype, _a))); var _a; diff --git a/tests/baselines/reference/decoratorOnClassMethod6.js b/tests/baselines/reference/decoratorOnClassMethod6.js index 126dc47ad2..2e828d6ad4 100644 --- a/tests/baselines/reference/decoratorOnClassMethod6.js +++ b/tests/baselines/reference/decoratorOnClassMethod6.js @@ -20,8 +20,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { return value; }; class C { - [_a = "method"]() { - } + [_a = "method"]() { } } Object.defineProperty(C.prototype, _a, __decorate([dec], C.prototype, _a, Object.getOwnPropertyDescriptor(C.prototype, _a))); var _a; diff --git a/tests/baselines/reference/decoratorOnClassMethod7.js b/tests/baselines/reference/decoratorOnClassMethod7.js index 34fbdb53ca..0b0f5abc4f 100644 --- a/tests/baselines/reference/decoratorOnClassMethod7.js +++ b/tests/baselines/reference/decoratorOnClassMethod7.js @@ -20,8 +20,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { return value; }; class C { - [_a = "method"]() { - } + [_a = "method"]() { } } Object.defineProperty(C.prototype, _a, __decorate([dec], C.prototype, _a, Object.getOwnPropertyDescriptor(C.prototype, _a))); var _a; diff --git a/tests/baselines/reference/decoratorOnClassMethod8.js b/tests/baselines/reference/decoratorOnClassMethod8.js index 629ff4e253..89afc66514 100644 --- a/tests/baselines/reference/decoratorOnClassMethod8.js +++ b/tests/baselines/reference/decoratorOnClassMethod8.js @@ -22,8 +22,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { var C = (function () { function C() { } - C.prototype.method = function () { - }; + C.prototype.method = function () { }; Object.defineProperty(C.prototype, "method", __decorate([dec], C.prototype, "method", Object.getOwnPropertyDescriptor(C.prototype, "method"))); return C; })(); diff --git a/tests/baselines/reference/decoratorOnClassMethodParameter1.js b/tests/baselines/reference/decoratorOnClassMethodParameter1.js index 1dcb057e53..dcd6c12352 100644 --- a/tests/baselines/reference/decoratorOnClassMethodParameter1.js +++ b/tests/baselines/reference/decoratorOnClassMethodParameter1.js @@ -22,8 +22,7 @@ var __decorate = this.__decorate || function (decorators, target, key, value) { var C = (function () { function C() { } - C.prototype.method = function (p) { - }; + C.prototype.method = function (p) { }; __decorate([dec], C.prototype, "method", 0); return C; })(); diff --git a/tests/baselines/reference/decrementOperatorWithAnyOtherType.js b/tests/baselines/reference/decrementOperatorWithAnyOtherType.js index 1263257291..34ea154daa 100644 --- a/tests/baselines/reference/decrementOperatorWithAnyOtherType.js +++ b/tests/baselines/reference/decrementOperatorWithAnyOtherType.js @@ -52,14 +52,8 @@ M.n--; // -- operator on any type var ANY; var ANY1; -var ANY2 = [ - "", - "" -]; -var obj = { - x: 1, - y: null -}; +var ANY2 = ["", ""]; +var obj = { x: 1, y: null }; var A = (function () { function A() { } diff --git a/tests/baselines/reference/decrementOperatorWithAnyOtherTypeInvalidOperations.js b/tests/baselines/reference/decrementOperatorWithAnyOtherTypeInvalidOperations.js index e5a73aea37..8e4f927a92 100644 --- a/tests/baselines/reference/decrementOperatorWithAnyOtherTypeInvalidOperations.js +++ b/tests/baselines/reference/decrementOperatorWithAnyOtherTypeInvalidOperations.js @@ -75,16 +75,9 @@ ANY2--; //// [decrementOperatorWithAnyOtherTypeInvalidOperations.js] // -- operator on any type var ANY1; -var ANY2 = [ - "", - "" -]; +var ANY2 = ["", ""]; var obj; -var obj1 = { - x: "", - y: function () { - } -}; +var obj1 = { x: "", y: function () { } }; function foo() { var a; return a; diff --git a/tests/baselines/reference/decrementOperatorWithNumberType.js b/tests/baselines/reference/decrementOperatorWithNumberType.js index faef864184..85ed9ca548 100644 --- a/tests/baselines/reference/decrementOperatorWithNumberType.js +++ b/tests/baselines/reference/decrementOperatorWithNumberType.js @@ -42,10 +42,7 @@ objA.a--, M.n--; //// [decrementOperatorWithNumberType.js] // -- operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; +var NUMBER1 = [1, 2]; var A = (function () { function A() { } diff --git a/tests/baselines/reference/decrementOperatorWithNumberTypeInvalidOperations.js b/tests/baselines/reference/decrementOperatorWithNumberTypeInvalidOperations.js index ccc5b6eaa1..34e862063c 100644 --- a/tests/baselines/reference/decrementOperatorWithNumberTypeInvalidOperations.js +++ b/tests/baselines/reference/decrementOperatorWithNumberTypeInvalidOperations.js @@ -49,19 +49,12 @@ foo()--; //// [decrementOperatorWithNumberTypeInvalidOperations.js] // -- operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; -function foo() { - return 1; -} +var NUMBER1 = [1, 2]; +function foo() { return 1; } var A = (function () { function A() { } - A.foo = function () { - return 1; - }; + A.foo = function () { return 1; }; return A; })(); var M; @@ -74,27 +67,11 @@ var ResultIsNumber1 = --NUMBER1; var ResultIsNumber2 = NUMBER1--; // number type literal var ResultIsNumber3 = --1; -var ResultIsNumber4 = --{ - x: 1, - y: 2 -}; -var ResultIsNumber5 = --{ - x: 1, - y: function (n) { - return n; - } -}; +var ResultIsNumber4 = --{ x: 1, y: 2 }; +var ResultIsNumber5 = --{ x: 1, y: function (n) { return n; } }; var ResultIsNumber6 = 1--; -var ResultIsNumber7 = { - x: 1, - y: 2 -}--; -var ResultIsNumber8 = { - x: 1, - y: function (n) { - return n; - } -}--; +var ResultIsNumber7 = { x: 1, y: 2 }--; +var ResultIsNumber8 = { x: 1, y: function (n) { return n; } }--; // number type expressions var ResultIsNumber9 = --foo(); var ResultIsNumber10 = --A.foo(); diff --git a/tests/baselines/reference/decrementOperatorWithUnsupportedBooleanType.js b/tests/baselines/reference/decrementOperatorWithUnsupportedBooleanType.js index 93737ea87c..2be74a64d8 100644 --- a/tests/baselines/reference/decrementOperatorWithUnsupportedBooleanType.js +++ b/tests/baselines/reference/decrementOperatorWithUnsupportedBooleanType.js @@ -57,15 +57,11 @@ objA.a--, M.n--; //// [decrementOperatorWithUnsupportedBooleanType.js] // -- operator on boolean type var BOOLEAN; -function foo() { - return true; -} +function foo() { return true; } var A = (function () { function A() { } - A.foo = function () { - return true; - }; + A.foo = function () { return true; }; return A; })(); var M; @@ -78,27 +74,11 @@ var ResultIsNumber1 = --BOOLEAN; var ResultIsNumber2 = BOOLEAN--; // boolean type literal var ResultIsNumber3 = --true; -var ResultIsNumber4 = --{ - x: true, - y: false -}; -var ResultIsNumber5 = --{ - x: true, - y: function (n) { - return n; - } -}; +var ResultIsNumber4 = --{ x: true, y: false }; +var ResultIsNumber5 = --{ x: true, y: function (n) { return n; } }; var ResultIsNumber6 = true--; -var ResultIsNumber7 = { - x: true, - y: false -}--; -var ResultIsNumber8 = { - x: true, - y: function (n) { - return n; - } -}--; +var ResultIsNumber7 = { x: true, y: false }--; +var ResultIsNumber8 = { x: true, y: function (n) { return n; } }--; // boolean type expressions var ResultIsNumber9 = --objA.a; var ResultIsNumber10 = --M.n; diff --git a/tests/baselines/reference/decrementOperatorWithUnsupportedStringType.js b/tests/baselines/reference/decrementOperatorWithUnsupportedStringType.js index e033acf3e1..430f9af963 100644 --- a/tests/baselines/reference/decrementOperatorWithUnsupportedStringType.js +++ b/tests/baselines/reference/decrementOperatorWithUnsupportedStringType.js @@ -68,19 +68,12 @@ objA.a--, M.n--; //// [decrementOperatorWithUnsupportedStringType.js] // -- operator on string type var STRING; -var STRING1 = [ - "", - "" -]; -function foo() { - return ""; -} +var STRING1 = ["", ""]; +function foo() { return ""; } var A = (function () { function A() { } - A.foo = function () { - return ""; - }; + A.foo = function () { return ""; }; return A; })(); var M; @@ -95,27 +88,11 @@ var ResultIsNumber3 = STRING--; var ResultIsNumber4 = STRING1--; // string type literal var ResultIsNumber5 = --""; -var ResultIsNumber6 = --{ - x: "", - y: "" -}; -var ResultIsNumber7 = --{ - x: "", - y: function (s) { - return s; - } -}; +var ResultIsNumber6 = --{ x: "", y: "" }; +var ResultIsNumber7 = --{ x: "", y: function (s) { return s; } }; var ResultIsNumber8 = ""--; -var ResultIsNumber9 = { - x: "", - y: "" -}--; -var ResultIsNumber10 = { - x: "", - y: function (s) { - return s; - } -}--; +var ResultIsNumber9 = { x: "", y: "" }--; +var ResultIsNumber10 = { x: "", y: function (s) { return s; } }--; // string type expressions var ResultIsNumber11 = --objA.a; var ResultIsNumber12 = --M.n; diff --git a/tests/baselines/reference/defaultArgsInFunctionExpressions.js b/tests/baselines/reference/defaultArgsInFunctionExpressions.js index a58905dd81..3f77c4430e 100644 --- a/tests/baselines/reference/defaultArgsInFunctionExpressions.js +++ b/tests/baselines/reference/defaultArgsInFunctionExpressions.js @@ -50,9 +50,7 @@ s = f2(); n = f2(); // Contextually type the default arg with the type annotation var f3 = function (a) { - if (a === void 0) { a = function (s) { - return s; - }; } + if (a === void 0) { a = function (s) { return s; }; } }; // Type check using the function's contextual type var f4 = function (a) { @@ -60,9 +58,7 @@ var f4 = function (a) { }; // Contextually type the default arg using the function's contextual type var f5 = function (a) { - if (a === void 0) { a = function (s) { - return s; - }; } + if (a === void 0) { a = function (s) { return s; }; } }; var U; (function (U) { diff --git a/tests/baselines/reference/defaultBestCommonTypesHaveDecls.js b/tests/baselines/reference/defaultBestCommonTypesHaveDecls.js index 98e135cc71..ad6181ba7c 100644 --- a/tests/baselines/reference/defaultBestCommonTypesHaveDecls.js +++ b/tests/baselines/reference/defaultBestCommonTypesHaveDecls.js @@ -20,13 +20,9 @@ var obj1; obj1.length; var obj2; obj2.length; -function concat(x, y) { - return null; -} +function concat(x, y) { return null; } var result = concat(1, ""); // error var elementCount = result.length; -function concat2(x, y) { - return null; -} +function concat2(x, y) { return null; } var result2 = concat2(1, ""); // result2 will be number|string var elementCount2 = result.length; diff --git a/tests/baselines/reference/defaultIndexProps1.js b/tests/baselines/reference/defaultIndexProps1.js index 63d8c70c9d..fc8fe52b9f 100644 --- a/tests/baselines/reference/defaultIndexProps1.js +++ b/tests/baselines/reference/defaultIndexProps1.js @@ -21,7 +21,5 @@ var Foo = (function () { })(); var f = new Foo(); var q = f["v"]; -var o = { - v: "Yo2" -}; +var o = { v: "Yo2" }; var q2 = o["v"]; diff --git a/tests/baselines/reference/defaultIndexProps2.js b/tests/baselines/reference/defaultIndexProps2.js index 6a175f0f56..7652e591cc 100644 --- a/tests/baselines/reference/defaultIndexProps2.js +++ b/tests/baselines/reference/defaultIndexProps2.js @@ -24,9 +24,7 @@ var Foo = (function () { })(); var f = new Foo(); // WScript.Echo(f[0]); -var o = { - v: "Yo2" -}; +var o = { v: "Yo2" }; // WScript.Echo(o[0]); 1[0]; var q = "s"[0]; diff --git a/tests/baselines/reference/deleteOperatorWithAnyOtherType.js b/tests/baselines/reference/deleteOperatorWithAnyOtherType.js index b4f9870c7e..e2a2be4d9a 100644 --- a/tests/baselines/reference/deleteOperatorWithAnyOtherType.js +++ b/tests/baselines/reference/deleteOperatorWithAnyOtherType.js @@ -65,16 +65,9 @@ delete M.n; // delete operator on any type var ANY; var ANY1; -var ANY2 = [ - "", - "" -]; +var ANY2 = ["", ""]; var obj; -var obj1 = { - x: "", - y: function () { - } -}; +var obj1 = { x: "", y: function () { } }; function foo() { var a; return a; diff --git a/tests/baselines/reference/deleteOperatorWithBooleanType.js b/tests/baselines/reference/deleteOperatorWithBooleanType.js index 2c913251c7..b0a60a2374 100644 --- a/tests/baselines/reference/deleteOperatorWithBooleanType.js +++ b/tests/baselines/reference/deleteOperatorWithBooleanType.js @@ -41,15 +41,11 @@ delete M.n; //// [deleteOperatorWithBooleanType.js] // delete operator on boolean type var BOOLEAN; -function foo() { - return true; -} +function foo() { return true; } var A = (function () { function A() { } - A.foo = function () { - return false; - }; + A.foo = function () { return false; }; return A; })(); var M; @@ -61,10 +57,7 @@ var objA = new A(); var ResultIsBoolean1 = delete BOOLEAN; // boolean type literal var ResultIsBoolean2 = delete true; -var ResultIsBoolean3 = delete { - x: true, - y: false -}; +var ResultIsBoolean3 = delete { x: true, y: false }; // boolean type expressions var ResultIsBoolean4 = delete objA.a; var ResultIsBoolean5 = delete M.n; diff --git a/tests/baselines/reference/deleteOperatorWithNumberType.js b/tests/baselines/reference/deleteOperatorWithNumberType.js index 50513247f6..bb70c55024 100644 --- a/tests/baselines/reference/deleteOperatorWithNumberType.js +++ b/tests/baselines/reference/deleteOperatorWithNumberType.js @@ -48,19 +48,12 @@ delete objA.a, M.n; //// [deleteOperatorWithNumberType.js] // delete operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; -function foo() { - return 1; -} +var NUMBER1 = [1, 2]; +function foo() { return 1; } var A = (function () { function A() { } - A.foo = function () { - return 1; - }; + A.foo = function () { return 1; }; return A; })(); var M; @@ -73,16 +66,8 @@ var ResultIsBoolean1 = delete NUMBER; var ResultIsBoolean2 = delete NUMBER1; // number type literal var ResultIsBoolean3 = delete 1; -var ResultIsBoolean4 = delete { - x: 1, - y: 2 -}; -var ResultIsBoolean5 = delete { - x: 1, - y: function (n) { - return n; - } -}; +var ResultIsBoolean4 = delete { x: 1, y: 2 }; +var ResultIsBoolean5 = delete { x: 1, y: function (n) { return n; } }; // number type expressions var ResultIsBoolean6 = delete objA.a; var ResultIsBoolean7 = delete M.n; diff --git a/tests/baselines/reference/deleteOperatorWithStringType.js b/tests/baselines/reference/deleteOperatorWithStringType.js index ddf4b82777..79246e2772 100644 --- a/tests/baselines/reference/deleteOperatorWithStringType.js +++ b/tests/baselines/reference/deleteOperatorWithStringType.js @@ -47,19 +47,12 @@ delete objA.a,M.n; //// [deleteOperatorWithStringType.js] // delete operator on string type var STRING; -var STRING1 = [ - "", - "abc" -]; -function foo() { - return "abc"; -} +var STRING1 = ["", "abc"]; +function foo() { return "abc"; } var A = (function () { function A() { } - A.foo = function () { - return ""; - }; + A.foo = function () { return ""; }; return A; })(); var M; @@ -72,16 +65,8 @@ var ResultIsBoolean1 = delete STRING; var ResultIsBoolean2 = delete STRING1; // string type literal var ResultIsBoolean3 = delete ""; -var ResultIsBoolean4 = delete { - x: "", - y: "" -}; -var ResultIsBoolean5 = delete { - x: "", - y: function (s) { - return s; - } -}; +var ResultIsBoolean4 = delete { x: "", y: "" }; +var ResultIsBoolean5 = delete { x: "", y: function (s) { return s; } }; // string type expressions var ResultIsBoolean6 = delete objA.a; var ResultIsBoolean7 = delete M.n; diff --git a/tests/baselines/reference/derivedClassConstructorWithoutSuperCall.js b/tests/baselines/reference/derivedClassConstructorWithoutSuperCall.js index e4ff8dd977..32e8cf4199 100644 --- a/tests/baselines/reference/derivedClassConstructorWithoutSuperCall.js +++ b/tests/baselines/reference/derivedClassConstructorWithoutSuperCall.js @@ -59,18 +59,14 @@ var Base2 = (function () { var Derived2 = (function (_super) { __extends(Derived2, _super); function Derived2() { - var r2 = function () { - return _super.call(this); - }; // error for misplaced super call (nested function) + var r2 = function () { return _super.call(this); }; // error for misplaced super call (nested function) } return Derived2; })(Base2); var Derived3 = (function (_super) { __extends(Derived3, _super); function Derived3() { - var r = function () { - _super.call(this); - }; // error + var r = function () { _super.call(this); }; // error } return Derived3; })(Base2); diff --git a/tests/baselines/reference/derivedClassIncludesInheritedMembers.js b/tests/baselines/reference/derivedClassIncludesInheritedMembers.js index db54affa6d..f2e816604d 100644 --- a/tests/baselines/reference/derivedClassIncludesInheritedMembers.js +++ b/tests/baselines/reference/derivedClassIncludesInheritedMembers.js @@ -50,25 +50,17 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base(x) { } - Base.prototype.b = function () { - }; + Base.prototype.b = function () { }; Object.defineProperty(Base.prototype, "c", { - get: function () { - return ''; - }, - set: function (v) { - }, + get: function () { return ''; }, + set: function (v) { }, enumerable: true, configurable: true }); - Base.s = function () { - }; + Base.s = function () { }; Object.defineProperty(Base, "t", { - get: function () { - return ''; - }, - set: function (v) { - }, + get: function () { return ''; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassOverridesProtectedMembers.js b/tests/baselines/reference/derivedClassOverridesProtectedMembers.js index 8c8b6a13c7..b66d356a73 100644 --- a/tests/baselines/reference/derivedClassOverridesProtectedMembers.js +++ b/tests/baselines/reference/derivedClassOverridesProtectedMembers.js @@ -48,25 +48,17 @@ var y; var Base = (function () { function Base(a) { } - Base.prototype.b = function (a) { - }; + Base.prototype.b = function (a) { }; Object.defineProperty(Base.prototype, "c", { - get: function () { - return x; - }, - set: function (v) { - }, + get: function () { return x; }, + set: function (v) { }, enumerable: true, configurable: true }); - Base.s = function (a) { - }; + Base.s = function (a) { }; Object.defineProperty(Base, "t", { - get: function () { - return x; - }, - set: function (v) { - }, + get: function () { return x; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -77,25 +69,17 @@ var Derived = (function (_super) { function Derived(a) { _super.call(this, x); } - Derived.prototype.b = function (a) { - }; + Derived.prototype.b = function (a) { }; Object.defineProperty(Derived.prototype, "c", { - get: function () { - return y; - }, - set: function (v) { - }, + get: function () { return y; }, + set: function (v) { }, enumerable: true, configurable: true }); - Derived.s = function (a) { - }; + Derived.s = function (a) { }; Object.defineProperty(Derived, "t", { - get: function () { - return y; - }, - set: function (a) { - }, + get: function () { return y; }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassOverridesProtectedMembers2.js b/tests/baselines/reference/derivedClassOverridesProtectedMembers2.js index 55bfd0e924..80f7456ab9 100644 --- a/tests/baselines/reference/derivedClassOverridesProtectedMembers2.js +++ b/tests/baselines/reference/derivedClassOverridesProtectedMembers2.js @@ -75,25 +75,17 @@ var y; var Base = (function () { function Base(a) { } - Base.prototype.b = function (a) { - }; + Base.prototype.b = function (a) { }; Object.defineProperty(Base.prototype, "c", { - get: function () { - return x; - }, - set: function (v) { - }, + get: function () { return x; }, + set: function (v) { }, enumerable: true, configurable: true }); - Base.s = function (a) { - }; + Base.s = function (a) { }; Object.defineProperty(Base, "t", { - get: function () { - return x; - }, - set: function (v) { - }, + get: function () { return x; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -105,25 +97,17 @@ var Derived = (function (_super) { function Derived(a) { _super.call(this, a); } - Derived.prototype.b = function (a) { - }; + Derived.prototype.b = function (a) { }; Object.defineProperty(Derived.prototype, "c", { - get: function () { - return y; - }, - set: function (v) { - }, + get: function () { return y; }, + set: function (v) { }, enumerable: true, configurable: true }); - Derived.s = function (a) { - }; + Derived.s = function (a) { }; Object.defineProperty(Derived, "t", { - get: function () { - return y; - }, - set: function (a) { - }, + get: function () { return y; }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassOverridesProtectedMembers3.js b/tests/baselines/reference/derivedClassOverridesProtectedMembers3.js index 0a228a04f7..cfb6116ee8 100644 --- a/tests/baselines/reference/derivedClassOverridesProtectedMembers3.js +++ b/tests/baselines/reference/derivedClassOverridesProtectedMembers3.js @@ -83,25 +83,17 @@ var y; var Base = (function () { function Base(a) { } - Base.prototype.b = function (a) { - }; + Base.prototype.b = function (a) { }; Object.defineProperty(Base.prototype, "c", { - get: function () { - return x; - }, - set: function (v) { - }, + get: function () { return x; }, + set: function (v) { }, enumerable: true, configurable: true }); - Base.s = function (a) { - }; + Base.s = function (a) { }; Object.defineProperty(Base, "t", { - get: function () { - return x; - }, - set: function (v) { - }, + get: function () { return x; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -121,8 +113,7 @@ var Derived2 = (function (_super) { function Derived2(a) { _super.call(this, a); } - Derived2.prototype.b = function (a) { - }; + Derived2.prototype.b = function (a) { }; return Derived2; })(Base); var Derived3 = (function (_super) { @@ -131,9 +122,7 @@ var Derived3 = (function (_super) { _super.call(this, a); } Object.defineProperty(Derived3.prototype, "c", { - get: function () { - return x; - }, + get: function () { return x; }, enumerable: true, configurable: true }); @@ -145,8 +134,7 @@ var Derived4 = (function (_super) { _super.call(this, a); } Object.defineProperty(Derived4.prototype, "c", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -171,8 +159,7 @@ var Derived7 = (function (_super) { function Derived7(a) { _super.call(this, a); } - Derived7.s = function (a) { - }; + Derived7.s = function (a) { }; return Derived7; })(Base); var Derived8 = (function (_super) { @@ -181,9 +168,7 @@ var Derived8 = (function (_super) { _super.call(this, a); } Object.defineProperty(Derived8, "t", { - get: function () { - return x; - }, + get: function () { return x; }, enumerable: true, configurable: true }); @@ -195,8 +180,7 @@ var Derived9 = (function (_super) { _super.call(this, a); } Object.defineProperty(Derived9, "t", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassOverridesPublicMembers.js b/tests/baselines/reference/derivedClassOverridesPublicMembers.js index f673d9ab85..9d7df0eee4 100644 --- a/tests/baselines/reference/derivedClassOverridesPublicMembers.js +++ b/tests/baselines/reference/derivedClassOverridesPublicMembers.js @@ -74,25 +74,17 @@ var y; var Base = (function () { function Base(a) { } - Base.prototype.b = function (a) { - }; + Base.prototype.b = function (a) { }; Object.defineProperty(Base.prototype, "c", { - get: function () { - return x; - }, - set: function (v) { - }, + get: function () { return x; }, + set: function (v) { }, enumerable: true, configurable: true }); - Base.s = function (a) { - }; + Base.s = function (a) { }; Object.defineProperty(Base, "t", { - get: function () { - return x; - }, - set: function (v) { - }, + get: function () { return x; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -103,25 +95,17 @@ var Derived = (function (_super) { function Derived(a) { _super.call(this, x); } - Derived.prototype.b = function (a) { - }; + Derived.prototype.b = function (a) { }; Object.defineProperty(Derived.prototype, "c", { - get: function () { - return y; - }, - set: function (v) { - }, + get: function () { return y; }, + set: function (v) { }, enumerable: true, configurable: true }); - Derived.s = function (a) { - }; + Derived.s = function (a) { }; Object.defineProperty(Derived, "t", { - get: function () { - return y; - }, - set: function (a) { - }, + get: function () { return y; }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassSuperCallsWithThisArg.js b/tests/baselines/reference/derivedClassSuperCallsWithThisArg.js index fb979ba603..1902b6f406 100644 --- a/tests/baselines/reference/derivedClassSuperCallsWithThisArg.js +++ b/tests/baselines/reference/derivedClassSuperCallsWithThisArg.js @@ -59,9 +59,7 @@ var Derived3 = (function (_super) { __extends(Derived3, _super); function Derived3(a) { var _this = this; - _super.call(this, function () { - return _this; - }); // error + _super.call(this, function () { return _this; }); // error this.a = a; } return Derived3; @@ -69,9 +67,7 @@ var Derived3 = (function (_super) { var Derived4 = (function (_super) { __extends(Derived4, _super); function Derived4(a) { - _super.call(this, function () { - return this; - }); // ok + _super.call(this, function () { return this; }); // ok this.a = a; } return Derived4; diff --git a/tests/baselines/reference/derivedClassTransitivity.js b/tests/baselines/reference/derivedClassTransitivity.js index 5374986154..2088fc1122 100644 --- a/tests/baselines/reference/derivedClassTransitivity.js +++ b/tests/baselines/reference/derivedClassTransitivity.js @@ -31,8 +31,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; + C.prototype.foo = function (x) { }; return C; })(); var D = (function (_super) { @@ -40,8 +39,7 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.foo = function () { - }; // ok to drop parameters + D.prototype.foo = function () { }; // ok to drop parameters return D; })(C); var E = (function (_super) { @@ -49,8 +47,7 @@ var E = (function (_super) { function E() { _super.apply(this, arguments); } - E.prototype.foo = function (x) { - }; // ok to add optional parameters + E.prototype.foo = function (x) { }; // ok to add optional parameters return E; })(D); var c; diff --git a/tests/baselines/reference/derivedClassTransitivity2.js b/tests/baselines/reference/derivedClassTransitivity2.js index 1b4bd58923..458aede164 100644 --- a/tests/baselines/reference/derivedClassTransitivity2.js +++ b/tests/baselines/reference/derivedClassTransitivity2.js @@ -31,8 +31,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - }; + C.prototype.foo = function (x, y) { }; return C; })(); var D = (function (_super) { @@ -40,8 +39,7 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.foo = function (x) { - }; // ok to drop parameters + D.prototype.foo = function (x) { }; // ok to drop parameters return D; })(C); var E = (function (_super) { @@ -49,8 +47,7 @@ var E = (function (_super) { function E() { _super.apply(this, arguments); } - E.prototype.foo = function (x, y) { - }; // ok to add optional parameters + E.prototype.foo = function (x, y) { }; // ok to add optional parameters return E; })(D); var c; diff --git a/tests/baselines/reference/derivedClassTransitivity3.js b/tests/baselines/reference/derivedClassTransitivity3.js index 3e548f5276..9768a8f5fa 100644 --- a/tests/baselines/reference/derivedClassTransitivity3.js +++ b/tests/baselines/reference/derivedClassTransitivity3.js @@ -31,8 +31,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - }; + C.prototype.foo = function (x, y) { }; return C; })(); var D = (function (_super) { @@ -40,8 +39,7 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.foo = function (x) { - }; // ok to drop parameters + D.prototype.foo = function (x) { }; // ok to drop parameters return D; })(C); var E = (function (_super) { @@ -49,8 +47,7 @@ var E = (function (_super) { function E() { _super.apply(this, arguments); } - E.prototype.foo = function (x, y) { - }; // ok to add optional parameters + E.prototype.foo = function (x, y) { }; // ok to add optional parameters return E; })(D); var c; diff --git a/tests/baselines/reference/derivedClassTransitivity4.js b/tests/baselines/reference/derivedClassTransitivity4.js index 5249c6aad2..abf1a3b5bd 100644 --- a/tests/baselines/reference/derivedClassTransitivity4.js +++ b/tests/baselines/reference/derivedClassTransitivity4.js @@ -31,8 +31,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; + C.prototype.foo = function (x) { }; return C; })(); var D = (function (_super) { @@ -40,8 +39,7 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.foo = function () { - }; // ok to drop parameters + D.prototype.foo = function () { }; // ok to drop parameters return D; })(C); var E = (function (_super) { @@ -49,8 +47,7 @@ var E = (function (_super) { function E() { _super.apply(this, arguments); } - E.prototype.foo = function (x) { - }; // ok to add optional parameters + E.prototype.foo = function (x) { }; // ok to add optional parameters return E; })(D); var c; diff --git a/tests/baselines/reference/derivedClassWithAny.js b/tests/baselines/reference/derivedClassWithAny.js index 0b568eaec9..8070e689bd 100644 --- a/tests/baselines/reference/derivedClassWithAny.js +++ b/tests/baselines/reference/derivedClassWithAny.js @@ -70,9 +70,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "X", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); @@ -125,9 +123,7 @@ var E = (function (_super) { _super.apply(this, arguments); } Object.defineProperty(E.prototype, "X", { - get: function () { - return ''; - }, + get: function () { return ''; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingProtectedInstance.js b/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingProtectedInstance.js index f802a22508..8b00c63205 100644 --- a/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingProtectedInstance.js +++ b/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingProtectedInstance.js @@ -36,11 +36,8 @@ var Base = (function () { return ''; }; Object.defineProperty(Base.prototype, "a", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -56,11 +53,8 @@ var Derived = (function (_super) { return ''; }; Object.defineProperty(Derived.prototype, "a", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingPublicInstance.js b/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingPublicInstance.js index fb0dee3e57..4ac57d159e 100644 --- a/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingPublicInstance.js +++ b/tests/baselines/reference/derivedClassWithPrivateInstanceShadowingPublicInstance.js @@ -46,11 +46,8 @@ var Base = (function () { return ''; }; Object.defineProperty(Base.prototype, "a", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -66,11 +63,8 @@ var Derived = (function (_super) { return ''; }; Object.defineProperty(Derived.prototype, "a", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassWithPrivateStaticShadowingProtectedStatic.js b/tests/baselines/reference/derivedClassWithPrivateStaticShadowingProtectedStatic.js index 558e230975..1037d3faaa 100644 --- a/tests/baselines/reference/derivedClassWithPrivateStaticShadowingProtectedStatic.js +++ b/tests/baselines/reference/derivedClassWithPrivateStaticShadowingProtectedStatic.js @@ -35,11 +35,8 @@ var Base = (function () { return ''; }; Object.defineProperty(Base, "a", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -55,11 +52,8 @@ var Derived = (function (_super) { return ''; }; Object.defineProperty(Derived, "a", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClassWithPrivateStaticShadowingPublicStatic.js b/tests/baselines/reference/derivedClassWithPrivateStaticShadowingPublicStatic.js index b2468f62d8..c5bfea288b 100644 --- a/tests/baselines/reference/derivedClassWithPrivateStaticShadowingPublicStatic.js +++ b/tests/baselines/reference/derivedClassWithPrivateStaticShadowingPublicStatic.js @@ -47,11 +47,8 @@ var Base = (function () { return ''; }; Object.defineProperty(Base, "a", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -68,11 +65,8 @@ var Derived = (function (_super) { return ''; }; Object.defineProperty(Derived, "a", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/derivedClasses.js b/tests/baselines/reference/derivedClasses.js index a0d6de6a81..e256313d27 100644 --- a/tests/baselines/reference/derivedClasses.js +++ b/tests/baselines/reference/derivedClasses.js @@ -44,9 +44,7 @@ var Red = (function (_super) { } Red.prototype.shade = function () { var _this = this; - var getHue = function () { - return _this.hue(); - }; + var getHue = function () { return _this.hue(); }; return getHue() + " red"; }; return Red; @@ -54,12 +52,8 @@ var Red = (function (_super) { var Color = (function () { function Color() { } - Color.prototype.shade = function () { - return "some shade"; - }; - Color.prototype.hue = function () { - return "some hue"; - }; + Color.prototype.shade = function () { return "some shade"; }; + Color.prototype.hue = function () { return "some hue"; }; return Color; })(); var Blue = (function (_super) { @@ -69,9 +63,7 @@ var Blue = (function (_super) { } Blue.prototype.shade = function () { var _this = this; - var getHue = function () { - return _this.hue(); - }; + var getHue = function () { return _this.hue(); }; return getHue() + " blue"; }; return Blue; diff --git a/tests/baselines/reference/derivedGenericClassWithAny.js b/tests/baselines/reference/derivedGenericClassWithAny.js index 677fadf387..4d1f0452be 100644 --- a/tests/baselines/reference/derivedGenericClassWithAny.js +++ b/tests/baselines/reference/derivedGenericClassWithAny.js @@ -53,9 +53,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "X", { - get: function () { - return null; - }, + get: function () { return null; }, enumerable: true, configurable: true }); @@ -98,9 +96,7 @@ var E = (function (_super) { _super.apply(this, arguments); } Object.defineProperty(E.prototype, "X", { - get: function () { - return ''; - } // error + get: function () { return ''; } // error , enumerable: true, configurable: true diff --git a/tests/baselines/reference/derivedTypeAccessesHiddenBaseCallViaSuperPropertyAccess.js b/tests/baselines/reference/derivedTypeAccessesHiddenBaseCallViaSuperPropertyAccess.js index 1ca6ce5945..39e87b620d 100644 --- a/tests/baselines/reference/derivedTypeAccessesHiddenBaseCallViaSuperPropertyAccess.js +++ b/tests/baselines/reference/derivedTypeAccessesHiddenBaseCallViaSuperPropertyAccess.js @@ -41,17 +41,9 @@ var Derived = (function (_super) { return null; }; Derived.prototype.bar = function () { - var r = _super.prototype.foo.call(this, { - a: 1 - }); // { a: number } - var r2 = _super.prototype.foo.call(this, { - a: 1, - b: 2 - }); // { a: number } - var r3 = this.foo({ - a: 1, - b: 2 - }); // { a: number; b: number; } + var r = _super.prototype.foo.call(this, { a: 1 }); // { a: number } + var r2 = _super.prototype.foo.call(this, { a: 1, b: 2 }); // { a: number } + var r3 = this.foo({ a: 1, b: 2 }); // { a: number; b: number; } }; return Derived; })(Base); diff --git a/tests/baselines/reference/derivedTypeDoesNotRequireExtendsClause.js b/tests/baselines/reference/derivedTypeDoesNotRequireExtendsClause.js index c70e3ff2ae..50c8aba1ef 100644 --- a/tests/baselines/reference/derivedTypeDoesNotRequireExtendsClause.js +++ b/tests/baselines/reference/derivedTypeDoesNotRequireExtendsClause.js @@ -49,7 +49,4 @@ var d1; var d2; b = d1; b = d2; -var r = [ - d1, - d2 -]; +var r = [d1, d2]; diff --git a/tests/baselines/reference/destructuringParameterProperties1.js b/tests/baselines/reference/destructuringParameterProperties1.js index 6d39d41cc1..cc16cc78de 100644 --- a/tests/baselines/reference/destructuringParameterProperties1.js +++ b/tests/baselines/reference/destructuringParameterProperties1.js @@ -52,34 +52,10 @@ var C3 = (function () { return C3; })(); var c1 = new C1([]); -c1 = new C1([ - "larry", - "{curly}", - "moe" -]); +c1 = new C1(["larry", "{curly}", "moe"]); var useC1Properties = c1.x === c1.y && c1.y === c1.z; -var c2 = new C2([ - "10", - 10, - !!10 -]); -var _a = [ - c2.x, - c2.y, - c2.z -], c2_x = _a[0], c2_y = _a[1], c2_z = _a[2]; -var c3 = new C3({ - x: 0, - y: "", - z: false -}); -c3 = new C3({ - x: 0, - "y": "y", - z: true -}); -var _b = [ - c3.x, - c3.y, - c3.z -], c3_x = _b[0], c3_y = _b[1], c3_z = _b[2]; +var c2 = new C2(["10", 10, !!10]); +var _a = [c2.x, c2.y, c2.z], c2_x = _a[0], c2_y = _a[1], c2_z = _a[2]; +var c3 = new C3({ x: 0, y: "", z: false }); +c3 = new C3({ x: 0, "y": "y", z: true }); +var _b = [c3.x, c3.y, c3.z], c3_x = _b[0], c3_y = _b[1], c3_z = _b[2]; diff --git a/tests/baselines/reference/destructuringParameterProperties2.js b/tests/baselines/reference/destructuringParameterProperties2.js index 7d7a89380a..27e190af62 100644 --- a/tests/baselines/reference/destructuringParameterProperties2.js +++ b/tests/baselines/reference/destructuringParameterProperties2.js @@ -50,33 +50,9 @@ var C1 = (function () { }; return C1; })(); -var x = new C1(undefined, [ - 0, - undefined, - "" -]); -var _a = [ - x.getA(), - x.getB(), - x.getC() -], x_a = _a[0], x_b = _a[1], x_c = _a[2]; -var y = new C1(10, [ - 0, - "", - true -]); -var _b = [ - y.getA(), - y.getB(), - y.getC() -], y_a = _b[0], y_b = _b[1], y_c = _b[2]; -var z = new C1(10, [ - undefined, - "", - null -]); -var _c = [ - z.getA(), - z.getB(), - z.getC() -], z_a = _c[0], z_b = _c[1], z_c = _c[2]; +var x = new C1(undefined, [0, undefined, ""]); +var _a = [x.getA(), x.getB(), x.getC()], x_a = _a[0], x_b = _a[1], x_c = _a[2]; +var y = new C1(10, [0, "", true]); +var _b = [y.getA(), y.getB(), y.getC()], y_a = _b[0], y_b = _b[1], y_c = _b[2]; +var z = new C1(10, [undefined, "", null]); +var _c = [z.getA(), z.getB(), z.getC()], z_a = _c[0], z_b = _c[1], z_c = _c[2]; diff --git a/tests/baselines/reference/destructuringParameterProperties3.js b/tests/baselines/reference/destructuringParameterProperties3.js index f9b89046ae..fe9e69d7e5 100644 --- a/tests/baselines/reference/destructuringParameterProperties3.js +++ b/tests/baselines/reference/destructuringParameterProperties3.js @@ -53,43 +53,11 @@ var C1 = (function () { }; return C1; })(); -var x = new C1(undefined, [ - 0, - true, - "" -]); -var _a = [ - x.getA(), - x.getB(), - x.getC() -], x_a = _a[0], x_b = _a[1], x_c = _a[2]; -var y = new C1(10, [ - 0, - true, - true -]); -var _b = [ - y.getA(), - y.getB(), - y.getC() -], y_a = _b[0], y_b = _b[1], y_c = _b[2]; -var z = new C1(10, [ - undefined, - "", - "" -]); -var _c = [ - z.getA(), - z.getB(), - z.getC() -], z_a = _c[0], z_b = _c[1], z_c = _c[2]; -var w = new C1(10, [ - undefined, - undefined, - undefined -]); -var _d = [ - z.getA(), - z.getB(), - z.getC() -], z_a = _d[0], z_b = _d[1], z_c = _d[2]; +var x = new C1(undefined, [0, true, ""]); +var _a = [x.getA(), x.getB(), x.getC()], x_a = _a[0], x_b = _a[1], x_c = _a[2]; +var y = new C1(10, [0, true, true]); +var _b = [y.getA(), y.getB(), y.getC()], y_a = _b[0], y_b = _b[1], y_c = _b[2]; +var z = new C1(10, [undefined, "", ""]); +var _c = [z.getA(), z.getB(), z.getC()], z_a = _c[0], z_b = _c[1], z_c = _c[2]; +var w = new C1(10, [undefined, undefined, undefined]); +var _d = [z.getA(), z.getB(), z.getC()], z_a = _d[0], z_b = _d[1], z_c = _d[2]; diff --git a/tests/baselines/reference/destructuringParameterProperties5.js b/tests/baselines/reference/destructuringParameterProperties5.js index 7575ebb3af..d9b1710ae8 100644 --- a/tests/baselines/reference/destructuringParameterProperties5.js +++ b/tests/baselines/reference/destructuringParameterProperties5.js @@ -22,19 +22,5 @@ var C1 = (function () { } return C1; })(); -var a = new C1([ - { - x1: 10, - x2: "", - x3: true - }, - "", - false -]); -var _a = [ - a.x1, - a.x2, - a.x3, - a.y, - a.z -], a_x1 = _a[0], a_x2 = _a[1], a_x3 = _a[2], a_y = _a[3], a_z = _a[4]; +var a = new C1([{ x1: 10, x2: "", x3: true }, "", false]); +var _a = [a.x1, a.x2, a.x3, a.y, a.z], a_x1 = _a[0], a_x2 = _a[1], a_x3 = _a[2], a_y = _a[3], a_z = _a[4]; diff --git a/tests/baselines/reference/detachedCommentAtStartOfConstructor1.js b/tests/baselines/reference/detachedCommentAtStartOfConstructor1.js index c0fe33d086..13312aea36 100644 --- a/tests/baselines/reference/detachedCommentAtStartOfConstructor1.js +++ b/tests/baselines/reference/detachedCommentAtStartOfConstructor1.js @@ -16,9 +16,7 @@ var TestFile = (function () { var _this = this; /// Test summary /// - var getMessage = function () { - return message + _this.name; - }; + var getMessage = function () { return message + _this.name; }; this.message = getMessage(); } return TestFile; diff --git a/tests/baselines/reference/detachedCommentAtStartOfConstructor2.js b/tests/baselines/reference/detachedCommentAtStartOfConstructor2.js index 97d8e2f3a3..754b432c7c 100644 --- a/tests/baselines/reference/detachedCommentAtStartOfConstructor2.js +++ b/tests/baselines/reference/detachedCommentAtStartOfConstructor2.js @@ -17,9 +17,7 @@ var TestFile = (function () { /// Test summary /// var _this = this; - var getMessage = function () { - return message + _this.name; - }; + var getMessage = function () { return message + _this.name; }; this.message = getMessage(); } return TestFile; diff --git a/tests/baselines/reference/detachedCommentAtStartOfFunctionBody1.js b/tests/baselines/reference/detachedCommentAtStartOfFunctionBody1.js index a37fdefe81..3bbea65541 100644 --- a/tests/baselines/reference/detachedCommentAtStartOfFunctionBody1.js +++ b/tests/baselines/reference/detachedCommentAtStartOfFunctionBody1.js @@ -17,9 +17,7 @@ var TestFile = (function () { /// Test summary /// /// - return function () { - return message + _this.name; - }; + return function () { return message + _this.name; }; }; return TestFile; })(); diff --git a/tests/baselines/reference/detachedCommentAtStartOfFunctionBody2.js b/tests/baselines/reference/detachedCommentAtStartOfFunctionBody2.js index e96bfa9347..2a0ac0a4f0 100644 --- a/tests/baselines/reference/detachedCommentAtStartOfFunctionBody2.js +++ b/tests/baselines/reference/detachedCommentAtStartOfFunctionBody2.js @@ -18,9 +18,7 @@ var TestFile = (function () { /// /// var _this = this; - return function () { - return message + _this.name; - }; + return function () { return message + _this.name; }; }; return TestFile; })(); diff --git a/tests/baselines/reference/disallowLineTerminatorBeforeArrow.js b/tests/baselines/reference/disallowLineTerminatorBeforeArrow.js index 610cbe62c1..7e292614d4 100644 --- a/tests/baselines/reference/disallowLineTerminatorBeforeArrow.js +++ b/tests/baselines/reference/disallowLineTerminatorBeforeArrow.js @@ -75,10 +75,8 @@ module m { //// [disallowLineTerminatorBeforeArrow.js] -var f1 = function () { -}; -var f2 = function (x, y) { -}; +var f1 = function () { }; +var f2 = function (x, y) { }; var f3 = function (x, y) { var rest = []; for (var _i = 2; _i < arguments.length; _i++) { @@ -134,25 +132,19 @@ var f13 = function (a) { return a; }; // Should be valid. -var f14 = function () { -}; +var f14 = function () { }; // Should be valid. -var f15 = function (a) { - return a; -}; +var f15 = function (a) { return a; }; // Should be valid. var f16 = function (a, b) { if (b === void 0) { b = 10; } return a + b; }; -function foo(func) { -} +function foo(func) { } foo(function () { return true; }); -foo(function () { - return false; -}); +foo(function () { return false; }); var m; (function (m) { var City = (function () { diff --git a/tests/baselines/reference/doNotWidenAtObjectLiteralPropertyAssignment.js b/tests/baselines/reference/doNotWidenAtObjectLiteralPropertyAssignment.js index b424436b99..b259f321f1 100644 --- a/tests/baselines/reference/doNotWidenAtObjectLiteralPropertyAssignment.js +++ b/tests/baselines/reference/doNotWidenAtObjectLiteralPropertyAssignment.js @@ -12,11 +12,4 @@ var test: IIntervalTreeNode[] = [{ interval: { begin: 0 }, children: null }]; // //// [doNotWidenAtObjectLiteralPropertyAssignment.js] -var test = [ - { - interval: { - begin: 0 - }, - children: null - } -]; // was error here because best common type is {} +var test = [{ interval: { begin: 0 }, children: null }]; // was error here because best common type is {} diff --git a/tests/baselines/reference/doWhileBreakStatements.js b/tests/baselines/reference/doWhileBreakStatements.js index 9162c62989..a2bc0d3c54 100644 --- a/tests/baselines/reference/doWhileBreakStatements.js +++ b/tests/baselines/reference/doWhileBreakStatements.js @@ -66,7 +66,6 @@ SEVEN: do while (true); while (true); EIGHT: do { - var fn = function () { - }; + var fn = function () { }; break EIGHT; } while (true); diff --git a/tests/baselines/reference/doWhileContinueStatements.js b/tests/baselines/reference/doWhileContinueStatements.js index a39495e162..7f73157fd9 100644 --- a/tests/baselines/reference/doWhileContinueStatements.js +++ b/tests/baselines/reference/doWhileContinueStatements.js @@ -66,7 +66,6 @@ SEVEN: do while (true); while (true); EIGHT: do { - var fn = function () { - }; + var fn = function () { }; continue EIGHT; } while (true); diff --git a/tests/baselines/reference/doWhileLoop.js b/tests/baselines/reference/doWhileLoop.js index 0c1abd7aed..6581bba09e 100644 --- a/tests/baselines/reference/doWhileLoop.js +++ b/tests/baselines/reference/doWhileLoop.js @@ -3,6 +3,5 @@ do { } while (false); var n; //// [doWhileLoop.js] -do { -} while (false); +do { } while (false); var n; diff --git a/tests/baselines/reference/dottedSymbolResolution1.js b/tests/baselines/reference/dottedSymbolResolution1.js index d5bdb6006d..a0ac7a38b8 100644 --- a/tests/baselines/reference/dottedSymbolResolution1.js +++ b/tests/baselines/reference/dottedSymbolResolution1.js @@ -29,8 +29,7 @@ function _setBarAndText(): void { var Base = (function () { function Base() { } - Base.prototype.foo = function () { - }; + Base.prototype.foo = function () { }; return Base; })(); function each(collection, callback) { diff --git a/tests/baselines/reference/downlevelLetConst12.js b/tests/baselines/reference/downlevelLetConst12.js index 9dc6982625..6437d17acc 100644 --- a/tests/baselines/reference/downlevelLetConst12.js +++ b/tests/baselines/reference/downlevelLetConst12.js @@ -17,10 +17,6 @@ const {a: baz4} = { a: 1 }; var foo; var bar = 1; var baz = ([])[0]; -var baz2 = ({ - a: 1 -}).a; +var baz2 = ({ a: 1 }).a; var baz3 = ([])[0]; -var baz4 = ({ - a: 1 -}).a; +var baz4 = ({ a: 1 }).a; diff --git a/tests/baselines/reference/downlevelLetConst13.js b/tests/baselines/reference/downlevelLetConst13.js index 95e89d5245..8324d697e9 100644 --- a/tests/baselines/reference/downlevelLetConst13.js +++ b/tests/baselines/reference/downlevelLetConst13.js @@ -24,32 +24,16 @@ export module M { // exported let\const bindings should not be renamed exports.foo = 10; exports.bar = "123"; -exports.bar1 = ([ - 1 -])[0]; -exports.bar2 = ([ - 2 -])[0]; -exports.bar3 = ({ - a: 1 -}).a; -exports.bar4 = ({ - a: 1 -}).a; +exports.bar1 = ([1])[0]; +exports.bar2 = ([2])[0]; +exports.bar3 = ({ a: 1 }).a; +exports.bar4 = ({ a: 1 }).a; var M; (function (M) { M.baz = 100; M.baz2 = true; - M.bar5 = ([ - 1 - ])[0]; - M.bar6 = ([ - 2 - ])[0]; - M.bar7 = ({ - a: 1 - }).a; - M.bar8 = ({ - a: 1 - }).a; + M.bar5 = ([1])[0]; + M.bar6 = ([2])[0]; + M.bar7 = ({ a: 1 }).a; + M.bar8 = ({ a: 1 }).a; })(M = exports.M || (exports.M = {})); diff --git a/tests/baselines/reference/downlevelLetConst14.js b/tests/baselines/reference/downlevelLetConst14.js index ac9444f9fa..d45cf10d3a 100644 --- a/tests/baselines/reference/downlevelLetConst14.js +++ b/tests/baselines/reference/downlevelLetConst14.js @@ -61,21 +61,13 @@ var z0, z1, z2, z3; { var x_1 = 20; use(x_1); - var z0_1 = ([ - 1 - ])[0]; + var z0_1 = ([1])[0]; use(z0_1); - var z1_1 = ([ - 1 - ])[0]; + var z1_1 = ([1])[0]; use(z1_1); - var z2_1 = ({ - a: 1 - }).a; + var z2_1 = ({ a: 1 }).a; use(z2_1); - var z3_1 = ({ - a: 1 - }).a; + var z3_1 = ({ a: 1 }).a; use(z3_1); } use(x); @@ -87,14 +79,10 @@ var z6; var y = true; { var y_1 = ""; - var z6_1 = ([ - true - ])[0]; + var z6_1 = ([true])[0]; { var y_2 = 1; - var z6_2 = ({ - a: 1 - }).a; + var z6_2 = ({ a: 1 }).a; use(y_2); use(z6_2); } @@ -107,14 +95,10 @@ var z = false; var z5 = 1; { var z_1 = ""; - var z5_1 = ([ - 5 - ])[0]; + var z5_1 = ([5])[0]; { var _z = 1; - var _z5 = ({ - a: 1 - }).a; + var _z5 = ({ a: 1 }).a; // try to step on generated name use(_z); } diff --git a/tests/baselines/reference/downlevelLetConst15.js b/tests/baselines/reference/downlevelLetConst15.js index f1b476c017..99522542d3 100644 --- a/tests/baselines/reference/downlevelLetConst15.js +++ b/tests/baselines/reference/downlevelLetConst15.js @@ -61,25 +61,13 @@ var z0, z1, z2, z3; { var x_1 = 20; use(x_1); - var z0_1 = ([ - 1 - ])[0]; + var z0_1 = ([1])[0]; use(z0_1); - var z1_1 = ([ - { - a: 1 - } - ])[0].a; + var z1_1 = ([{ a: 1 }])[0].a; use(z1_1); - var z2_1 = ({ - a: 1 - }).a; + var z2_1 = ({ a: 1 }).a; use(z2_1); - var z3_1 = ({ - a: { - b: 1 - } - }).a.b; + var z3_1 = ({ a: { b: 1 } }).a.b; use(z3_1); } use(x); @@ -91,14 +79,10 @@ var z6; var y = true; { var y_1 = ""; - var z6_1 = ([ - true - ])[0]; + var z6_1 = ([true])[0]; { var y_2 = 1; - var z6_2 = ({ - a: 1 - }).a; + var z6_2 = ({ a: 1 }).a; use(y_2); use(z6_2); } @@ -111,14 +95,10 @@ var z = false; var z5 = 1; { var z_1 = ""; - var z5_1 = ([ - 5 - ])[0]; + var z5_1 = ([5])[0]; { var _z = 1; - var _z5 = ({ - a: 1 - }).a; + var _z5 = ({ a: 1 }).a; // try to step on generated name use(_z); } diff --git a/tests/baselines/reference/downlevelLetConst16.js b/tests/baselines/reference/downlevelLetConst16.js index aefe2830ad..4765b50e0a 100644 --- a/tests/baselines/reference/downlevelLetConst16.js +++ b/tests/baselines/reference/downlevelLetConst16.js @@ -238,26 +238,18 @@ use(z); function foo1() { var x = 1; use(x); - var y = ([ - 1 - ])[0]; + var y = ([1])[0]; use(y); - var z = ({ - a: 1 - }).a; + var z = ({ a: 1 }).a; use(z); } function foo2() { { var x_1 = 1; use(x_1); - var y_1 = ([ - 1 - ])[0]; + var y_1 = ([1])[0]; use(y_1); - var z_1 = ({ - a: 1 - }).a; + var z_1 = ({ a: 1 }).a; use(z_1); } use(x); @@ -268,26 +260,18 @@ var A = (function () { A.prototype.m1 = function () { var x = 1; use(x); - var y = ([ - 1 - ])[0]; + var y = ([1])[0]; use(y); - var z = ({ - a: 1 - }).a; + var z = ({ a: 1 }).a; use(z); }; A.prototype.m2 = function () { { var x_2 = 1; use(x_2); - var y_2 = ([ - 1 - ])[0]; + var y_2 = ([1])[0]; use(y_2); - var z_2 = ({ - a: 1 - }).a; + var z_2 = ({ a: 1 }).a; use(z_2); } use(x); @@ -300,26 +284,18 @@ var B = (function () { B.prototype.m1 = function () { var x = 1; use(x); - var y = ([ - 1 - ])[0]; + var y = ([1])[0]; use(y); - var z = ({ - a: 1 - }).a; + var z = ({ a: 1 }).a; use(z); }; B.prototype.m2 = function () { { var x_3 = 1; use(x_3); - var y_3 = ([ - 1 - ])[0]; + var y_3 = ([1])[0]; use(y_3); - var z_3 = ({ - a: 1 - }).a; + var z_3 = ({ a: 1 }).a; use(z_3); } use(x); @@ -329,26 +305,18 @@ var B = (function () { function bar1() { var x = 1; use(x); - var y = ([ - 1 - ])[0]; + var y = ([1])[0]; use(y); - var z = ({ - a: 1 - }).a; + var z = ({ a: 1 }).a; use(z); } function bar2() { { var x_4 = 1; use(x_4); - var y_4 = ([ - 1 - ])[0]; + var y_4 = ([1])[0]; use(y_4); - var z_4 = ({ - a: 1 - }).a; + var z_4 = ({ a: 1 }).a; use(z_4); } use(x); @@ -357,13 +325,9 @@ var M1; (function (M1) { var x = 1; use(x); - var y = ([ - 1 - ])[0]; + var y = ([1])[0]; use(y); - var z = ({ - a: 1 - }).a; + var z = ({ a: 1 }).a; use(z); })(M1 || (M1 = {})); var M2; @@ -371,13 +335,9 @@ var M2; { var x_5 = 1; use(x_5); - var y_5 = ([ - 1 - ])[0]; + var y_5 = ([1])[0]; use(y_5); - var z_5 = ({ - a: 1 - }).a; + var z_5 = ({ a: 1 }).a; use(z_5); } use(x); @@ -386,13 +346,9 @@ var M3; (function (M3) { var x = 1; use(x); - var y = ([ - 1 - ])[0]; + var y = ([1])[0]; use(y); - var z = ({ - a: 1 - }).a; + var z = ({ a: 1 }).a; use(z); })(M3 || (M3 = {})); var M4; @@ -400,13 +356,9 @@ var M4; { var x_6 = 1; use(x_6); - var y_6 = ([ - 1 - ])[0]; + var y_6 = ([1])[0]; use(y_6); - var z_6 = ({ - a: 1 - }).a; + var z_6 = ({ a: 1 }).a; use(z_6); } use(x); @@ -420,9 +372,7 @@ function foo3() { for (var y_7 = ([])[0];;) { use(y_7); } - for (var z_7 = ({ - a: 1 - }).a;;) { + for (var z_7 = ({ a: 1 }).a;;) { use(z_7); } use(x); @@ -434,9 +384,7 @@ function foo4() { for (var y_8 = ([])[0];;) { use(y_8); } - for (var z_8 = ({ - a: 1 - }).a;;) { + for (var z_8 = ({ a: 1 }).a;;) { use(z_8); } use(x); diff --git a/tests/baselines/reference/downlevelLetConst18.js b/tests/baselines/reference/downlevelLetConst18.js index f3b2306d62..70b8cb9e34 100644 --- a/tests/baselines/reference/downlevelLetConst18.js +++ b/tests/baselines/reference/downlevelLetConst18.js @@ -33,45 +33,25 @@ for (let x; ;) { //// [downlevelLetConst18.js] 'use strict'; for (var x = void 0;;) { - function foo() { - x; - } + function foo() { x; } ; } for (var x = void 0;;) { - function foo() { - x; - } + function foo() { x; } ; } for (var x = void 0;;) { - (function () { - x; - })(); + (function () { x; })(); } for (var x = 1;;) { - (function () { - x; - })(); + (function () { x; })(); } for (var x = void 0;;) { - ({ - foo: function () { - x; - } - }); + ({ foo: function () { x; } }); } for (var x = void 0;;) { - ({ - get foo() { - return x; - } - }); + ({ get foo() { return x; } }); } for (var x = void 0;;) { - ({ - set foo(v) { - x; - } - }); + ({ set foo(v) { x; } }); } diff --git a/tests/baselines/reference/duplicateIdentifierInCatchBlock.js b/tests/baselines/reference/duplicateIdentifierInCatchBlock.js index 6d43b888f4..e440c06073 100644 --- a/tests/baselines/reference/duplicateIdentifierInCatchBlock.js +++ b/tests/baselines/reference/duplicateIdentifierInCatchBlock.js @@ -19,27 +19,20 @@ try { } catch (e) { //// [duplicateIdentifierInCatchBlock.js] var v; -try { -} +try { } catch (e) { - function v() { - } -} -function w() { -} -try { + function v() { } } +function w() { } +try { } catch (e) { var w; } -try { -} +try { } catch (e) { var x; - function x() { - } // error - function e() { - } // error + function x() { } // error + function e() { } // error var p; var p; // error } diff --git a/tests/baselines/reference/duplicateIdentifiersAcrossContainerBoundaries.js b/tests/baselines/reference/duplicateIdentifiersAcrossContainerBoundaries.js index 018d148f9c..6a567018d1 100644 --- a/tests/baselines/reference/duplicateIdentifiersAcrossContainerBoundaries.js +++ b/tests/baselines/reference/duplicateIdentifiersAcrossContainerBoundaries.js @@ -64,8 +64,7 @@ var M; })(M || (M = {})); var M; (function (M) { - function f() { - } + function f() { } M.f = f; })(M || (M = {})); var M; @@ -79,8 +78,7 @@ var M; })(M || (M = {})); var M; (function (M) { - function g() { - } + function g() { } })(M || (M = {})); var M; (function (M) { @@ -102,8 +100,7 @@ var M; })(M || (M = {})); var M; (function (M) { - function C() { - } // no error + function C() { } // no error })(M || (M = {})); var M; (function (M) { diff --git a/tests/baselines/reference/duplicateLocalVariable1.js b/tests/baselines/reference/duplicateLocalVariable1.js index d9ba04ae39..62e291f28c 100644 --- a/tests/baselines/reference/duplicateLocalVariable1.js +++ b/tests/baselines/reference/duplicateLocalVariable1.js @@ -361,9 +361,7 @@ var TestRunner = (function () { this.tests = []; } TestRunner.arrayCompare = function (arg1, arg2) { - return (arg1.every(function (val, index) { - return val === arg2[index]; - })); + return (arg1.every(function (val, index) { return val === arg2[index]; })); }; TestRunner.prototype.addTest = function (test) { this.tests.push(test); @@ -410,39 +408,11 @@ exports.TestRunner = TestRunner; exports.tests = (function () { var testRunner = new TestRunner(); // First 3 are for simple harness validation - testRunner.addTest(new TestCase("Basic test", function () { - return true; - })); - testRunner.addTest(new TestCase("Test for any error", function () { - throw new Error(); - return false; - }, "")); - testRunner.addTest(new TestCase("Test RegEx error message match", function () { - throw new Error("Should also pass"); - return false; - }, "Should [also]+ pass")); - testRunner.addTest(new TestCase("Test array compare true", function () { - return TestRunner.arrayCompare([ - 1, - 2, - 3 - ], [ - 1, - 2, - 3 - ]); - })); - testRunner.addTest(new TestCase("Test array compare false", function () { - return !TestRunner.arrayCompare([ - 3, - 2, - 3 - ], [ - 1, - 2, - 3 - ]); - })); + testRunner.addTest(new TestCase("Basic test", function () { return true; })); + testRunner.addTest(new TestCase("Test for any error", function () { throw new Error(); return false; }, "")); + testRunner.addTest(new TestCase("Test RegEx error message match", function () { throw new Error("Should also pass"); return false; }, "Should [also]+ pass")); + testRunner.addTest(new TestCase("Test array compare true", function () { return TestRunner.arrayCompare([1, 2, 3], [1, 2, 3]); })); + testRunner.addTest(new TestCase("Test array compare false", function () { return !TestRunner.arrayCompare([3, 2, 3], [1, 2, 3]); })); // File detection tests testRunner.addTest(new TestCase("Check file exists", function () { return FileManager.DirectoryManager.fileExists(TestFileDir + "\\Test.txt"); @@ -452,28 +422,38 @@ exports.tests = (function () { })); // File pattern matching tests testRunner.addTest(new TestCase("Check text file match", function () { - return (FileManager.FileBuffer.isTextFile("C:\\somedir\\readme.txt") && FileManager.FileBuffer.isTextFile("C:\\spaces path\\myapp.str") && FileManager.FileBuffer.isTextFile("C:\\somedir\\code.js")); + return (FileManager.FileBuffer.isTextFile("C:\\somedir\\readme.txt") && + FileManager.FileBuffer.isTextFile("C:\\spaces path\\myapp.str") && + FileManager.FileBuffer.isTextFile("C:\\somedir\\code.js")); })); testRunner.addTest(new TestCase("Check makefile match", function () { return FileManager.FileBuffer.isTextFile("C:\\some dir\\makefile"); })); testRunner.addTest(new TestCase("Check binary file doesn't match", function () { - return (!FileManager.FileBuffer.isTextFile("C:\\somedir\\app.exe") && !FileManager.FileBuffer.isTextFile("C:\\somedir\\my lib.dll")); + return (!FileManager.FileBuffer.isTextFile("C:\\somedir\\app.exe") && + !FileManager.FileBuffer.isTextFile("C:\\somedir\\my lib.dll")); })); // Command-line parameter tests testRunner.addTest(new TestCase("Check App defaults", function () { var app = new App.App([]); - return (app.fixLines === false && app.recurse === true && app.lineEndings === "CRLF" && app.matchPattern === undefined && app.rootDirectory === ".\\" && app.encodings[0] === "ascii" && app.encodings[1] === "utf8nobom"); + return (app.fixLines === false && + app.recurse === true && + app.lineEndings === "CRLF" && + app.matchPattern === undefined && + app.rootDirectory === ".\\" && + app.encodings[0] === "ascii" && + app.encodings[1] === "utf8nobom"); })); testRunner.addTest(new TestCase("Check App params", function () { - var app = new App.App([ - "-dir=C:\\test dir", - "-lineEndings=LF", - "-encodings=utf16be,ascii", - "-recurse=false", - "-fixlines" - ]); - return (app.fixLines === true && app.lineEndings === "LF" && app.recurse === false && app.matchPattern === undefined && app.rootDirectory === "C:\\test dir" && app.encodings[0] === "utf16be" && app.encodings[1] === "ascii" && app.encodings.length === 2); + var app = new App.App(["-dir=C:\\test dir", "-lineEndings=LF", "-encodings=utf16be,ascii", "-recurse=false", "-fixlines"]); + return (app.fixLines === true && + app.lineEndings === "LF" && + app.recurse === false && + app.matchPattern === undefined && + app.rootDirectory === "C:\\test dir" && + app.encodings[0] === "utf16be" && + app.encodings[1] === "ascii" && + app.encodings.length === 2); })); // File BOM detection tests testRunner.addTest(new TestCase("Check encoding detection no BOM", function () { @@ -507,19 +487,7 @@ exports.tests = (function () { for (var i = 0; i < 11; i++) { chars.push(fb.readByte()); } - return TestRunner.arrayCompare(chars, [ - 0x54, - 0xC3, - 0xA8, - 0xE1, - 0xB4, - 0xA3, - 0xE2, - 0x80, - 0xA0, - 0x0D, - 0x0A - ]); + return TestRunner.arrayCompare(chars, [0x54, 0xC3, 0xA8, 0xE1, 0xB4, 0xA3, 0xE2, 0x80, 0xA0, 0x0D, 0x0A]); })); testRunner.addTest(new TestCase("Check UTF8 decoding", function () { var fb = new FileManager.FileBuffer(TestFileDir + "\\UTF8BOM.txt"); @@ -527,26 +495,12 @@ exports.tests = (function () { for (var i = 0; i < 6; i++) { chars.push(fb.readUtf8CodePoint()); } - return TestRunner.arrayCompare(chars, [ - 0x0054, - 0x00E8, - 0x1D23, - 0x2020, - 0x000D, - 0x000A - ]); + return TestRunner.arrayCompare(chars, [0x0054, 0x00E8, 0x1D23, 0x2020, 0x000D, 0x000A]); })); testRunner.addTest(new TestCase("Check UTF8 encoding", function () { var fb = new FileManager.FileBuffer(20); fb.writeUtf8Bom(); - var chars = [ - 0x0054, - 0x00E8, - 0x1D23, - 0x2020, - 0x000D, - 0x000A - ]; + var chars = [0x0054, 0x00E8, 0x1D23, 0x2020, 0x000D, 0x000A]; for (var i in chars) { fb.writeUtf8CodePoint(chars[i]); } @@ -555,22 +509,7 @@ exports.tests = (function () { for (var i = 0; i < 14; i++) { bytes.push(fb.readByte()); } - var expected = [ - 0xEF, - 0xBB, - 0xBF, - 0x54, - 0xC3, - 0xA8, - 0xE1, - 0xB4, - 0xA3, - 0xE2, - 0x80, - 0xA0, - 0x0D, - 0x0A - ]; + var expected = [0xEF, 0xBB, 0xBF, 0x54, 0xC3, 0xA8, 0xE1, 0xB4, 0xA3, 0xE2, 0x80, 0xA0, 0x0D, 0x0A]; return TestRunner.arrayCompare(bytes, expected); })); // Test reading and writing files @@ -578,38 +517,14 @@ exports.tests = (function () { var filename = TestFileDir + "\\tmpUTF16LE.txt"; var fb = new FileManager.FileBuffer(14); fb.writeUtf16leBom(); - var chars = [ - 0x0054, - 0x00E8, - 0x1D23, - 0x2020, - 0x000D, - 0x000A - ]; - chars.forEach(function (val) { - fb.writeUtf16CodePoint(val, false); - }); + var chars = [0x0054, 0x00E8, 0x1D23, 0x2020, 0x000D, 0x000A]; + chars.forEach(function (val) { fb.writeUtf16CodePoint(val, false); }); fb.save(filename); var savedFile = new FileManager.FileBuffer(filename); if (savedFile.encoding !== 'utf16le') { throw Error("Incorrect encoding"); } - var expectedBytes = [ - 0xFF, - 0xFE, - 0x54, - 0x00, - 0xE8, - 0x00, - 0x23, - 0x1D, - 0x20, - 0x20, - 0x0D, - 0x00, - 0x0A, - 0x00 - ]; + var expectedBytes = [0xFF, 0xFE, 0x54, 0x00, 0xE8, 0x00, 0x23, 0x1D, 0x20, 0x20, 0x0D, 0x00, 0x0A, 0x00]; savedFile.index = 0; expectedBytes.forEach(function (val) { var byteVal = savedFile.readByte(); @@ -639,14 +554,7 @@ exports.tests = (function () { for (var i = 0; i < 6; i++) { codePoints.push(savedFile.readUtf16CodePoint(false)); } - var expectedCodePoints = [ - 0x10480, - 0x10481, - 0x10482, - 0x54, - 0x68, - 0x69 - ]; + var expectedCodePoints = [0x10480, 0x10481, 0x10482, 0x54, 0x68, 0x69]; return TestRunner.arrayCompare(codePoints, expectedCodePoints); })); testRunner.addTest(new TestCase("Read non-BMP utf8 chars", function () { @@ -658,52 +566,20 @@ exports.tests = (function () { for (var i = 0; i < 6; i++) { codePoints.push(savedFile.readUtf8CodePoint()); } - var expectedCodePoints = [ - 0x10480, - 0x10481, - 0x10482, - 0x54, - 0x68, - 0x69 - ]; + var expectedCodePoints = [0x10480, 0x10481, 0x10482, 0x54, 0x68, 0x69]; return TestRunner.arrayCompare(codePoints, expectedCodePoints); })); testRunner.addTest(new TestCase("Write non-BMP utf8 chars", function () { var filename = TestFileDir + "\\tmpUTF8nonBmp.txt"; var fb = new FileManager.FileBuffer(15); - var chars = [ - 0x10480, - 0x10481, - 0x10482, - 0x54, - 0x68, - 0x69 - ]; - chars.forEach(function (val) { - fb.writeUtf8CodePoint(val); - }); + var chars = [0x10480, 0x10481, 0x10482, 0x54, 0x68, 0x69]; + chars.forEach(function (val) { fb.writeUtf8CodePoint(val); }); fb.save(filename); var savedFile = new FileManager.FileBuffer(filename); if (savedFile.encoding !== 'utf8') { throw Error("Incorrect encoding"); } - var expectedBytes = [ - 0xF0, - 0x90, - 0x92, - 0x80, - 0xF0, - 0x90, - 0x92, - 0x81, - 0xF0, - 0x90, - 0x92, - 0x82, - 0x54, - 0x68, - 0x69 - ]; + var expectedBytes = [0xF0, 0x90, 0x92, 0x80, 0xF0, 0x90, 0x92, 0x81, 0xF0, 0x90, 0x92, 0x82, 0x54, 0x68, 0x69]; expectedBytes.forEach(function (val) { var byteVal = savedFile.readByte(); if (byteVal !== val) { diff --git a/tests/baselines/reference/duplicateLocalVariable2.js b/tests/baselines/reference/duplicateLocalVariable2.js index fdb6f5463c..a8370f3170 100644 --- a/tests/baselines/reference/duplicateLocalVariable2.js +++ b/tests/baselines/reference/duplicateLocalVariable2.js @@ -62,9 +62,7 @@ define(["require", "exports"], function (require, exports) { testRunner.addTest(new TestCase("Check UTF8 encoding", function () { var fb; fb.writeUtf8Bom(); - var chars = [ - 0x0054 - ]; + var chars = [0x0054]; for (var i in chars) { fb.writeUtf8CodePoint(chars[i]); } @@ -73,9 +71,7 @@ define(["require", "exports"], function (require, exports) { for (var i = 0; i < 14; i++) { bytes.push(fb.readByte()); } - var expected = [ - 0xEF - ]; + var expected = [0xEF]; return TestRunner.arrayCompare(bytes, expected); })); return testRunner; diff --git a/tests/baselines/reference/duplicateObjectLiteralProperty.js b/tests/baselines/reference/duplicateObjectLiteralProperty.js index 5bbeb433a0..9c629b211c 100644 --- a/tests/baselines/reference/duplicateObjectLiteralProperty.js +++ b/tests/baselines/reference/duplicateObjectLiteralProperty.js @@ -30,12 +30,7 @@ var x = { } }; var y = { - get a() { - return 0; - }, - set a(v) { - }, - get a() { - return 0; - } + get a() { return 0; }, + set a(v) { }, + get a() { return 0; } }; diff --git a/tests/baselines/reference/duplicateOverloadInTypeAugmentation1.js b/tests/baselines/reference/duplicateOverloadInTypeAugmentation1.js index ceaeac0d02..5f55a8b1d2 100644 --- a/tests/baselines/reference/duplicateOverloadInTypeAugmentation1.js +++ b/tests/baselines/reference/duplicateOverloadInTypeAugmentation1.js @@ -10,6 +10,4 @@ var r5 = a.reduce((x, y) => x + y); //// [duplicateOverloadInTypeAugmentation1.js] var a; -var r5 = a.reduce(function (x, y) { - return x + y; -}); +var r5 = a.reduce(function (x, y) { return x + y; }); diff --git a/tests/baselines/reference/duplicatePropertyNames.js b/tests/baselines/reference/duplicatePropertyNames.js index c5da2a1f39..c3cde82e2c 100644 --- a/tests/baselines/reference/duplicatePropertyNames.js +++ b/tests/baselines/reference/duplicatePropertyNames.js @@ -52,23 +52,17 @@ var b = { // duplicate property names are an error in all types var C = (function () { function C() { - this.baz = function () { - }; - this.baz = function () { - }; + this.baz = function () { }; + this.baz = function () { }; } - C.prototype.bar = function (x) { - }; - C.prototype.bar = function (x) { - }; + C.prototype.bar = function (x) { }; + C.prototype.bar = function (x) { }; return C; })(); var a; var b = { foo: '', foo: '', - bar: function () { - }, - bar: function () { - } + bar: function () { }, + bar: function () { } }; diff --git a/tests/baselines/reference/duplicateSymbolsExportMatching.js b/tests/baselines/reference/duplicateSymbolsExportMatching.js index e34ed7c8d0..89b5a210ec 100644 --- a/tests/baselines/reference/duplicateSymbolsExportMatching.js +++ b/tests/baselines/reference/duplicateSymbolsExportMatching.js @@ -93,8 +93,7 @@ define(["require", "exports"], function (require, exports) { (function (F) { var t; })(F || (F = {})); - function F() { - } + function F() { } M.F = F; // Only one error for duplicate identifier (don't consider visibility) })(M || (M = {})); var M; diff --git a/tests/baselines/reference/duplicateTypeParameters1.js b/tests/baselines/reference/duplicateTypeParameters1.js index 167688719a..990048a25d 100644 --- a/tests/baselines/reference/duplicateTypeParameters1.js +++ b/tests/baselines/reference/duplicateTypeParameters1.js @@ -3,5 +3,4 @@ function A() { } //// [duplicateTypeParameters1.js] -function A() { -} +function A() { } diff --git a/tests/baselines/reference/duplicateTypeParameters2.js b/tests/baselines/reference/duplicateTypeParameters2.js index c89f0d15fe..65dce28ad3 100644 --- a/tests/baselines/reference/duplicateTypeParameters2.js +++ b/tests/baselines/reference/duplicateTypeParameters2.js @@ -8,14 +8,12 @@ interface I {} var A = (function () { function A() { } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); var B = (function () { function B() { } - B.prototype.bar = function () { - }; + B.prototype.bar = function () { }; return B; })(); diff --git a/tests/baselines/reference/elaboratedErrors.js b/tests/baselines/reference/elaboratedErrors.js index c245c1a856..ae5877b2dd 100644 --- a/tests/baselines/reference/elaboratedErrors.js +++ b/tests/baselines/reference/elaboratedErrors.js @@ -27,8 +27,7 @@ y = x; //// [elaboratedErrors.js] -function fn(s) { -} +function fn(s) { } // This should issue a large error, not a small one var WorkerFS = (function () { function WorkerFS() { diff --git a/tests/baselines/reference/emitArrowFunction.js b/tests/baselines/reference/emitArrowFunction.js index 074febfa09..7e2617045a 100644 --- a/tests/baselines/reference/emitArrowFunction.js +++ b/tests/baselines/reference/emitArrowFunction.js @@ -8,10 +8,8 @@ foo(() => true); foo(() => { return false; }); //// [emitArrowFunction.js] -var f1 = function () { -}; -var f2 = function (x, y) { -}; +var f1 = function () { }; +var f2 = function (x, y) { }; var f3 = function (x, y) { var rest = []; for (var _i = 2; _i < arguments.length; _i++) { @@ -21,11 +19,6 @@ var f3 = function (x, y) { var f4 = function (x, y, z) { if (z === void 0) { z = 10; } }; -function foo(func) { -} -foo(function () { - return true; -}); -foo(function () { - return false; -}); +function foo(func) { } +foo(function () { return true; }); +foo(function () { return false; }); diff --git a/tests/baselines/reference/emitArrowFunctionAsIs.js b/tests/baselines/reference/emitArrowFunctionAsIs.js index 11df7903ad..c6586ee95a 100644 --- a/tests/baselines/reference/emitArrowFunctionAsIs.js +++ b/tests/baselines/reference/emitArrowFunctionAsIs.js @@ -5,9 +5,6 @@ var arrow2 = (a) => { }; var arrow3 = (a, b) => { }; //// [emitArrowFunctionAsIs.js] -var arrow1 = function (a) { -}; -var arrow2 = function (a) { -}; -var arrow3 = function (a, b) { -}; +var arrow1 = function (a) { }; +var arrow2 = function (a) { }; +var arrow3 = function (a, b) { }; diff --git a/tests/baselines/reference/emitArrowFunctionAsIsES6.js b/tests/baselines/reference/emitArrowFunctionAsIsES6.js index 9941434ae1..9876abdafc 100644 --- a/tests/baselines/reference/emitArrowFunctionAsIsES6.js +++ b/tests/baselines/reference/emitArrowFunctionAsIsES6.js @@ -5,9 +5,6 @@ var arrow2 = (a) => { }; var arrow3 = (a, b) => { }; //// [emitArrowFunctionAsIsES6.js] -var arrow1 = a => { -}; -var arrow2 = (a) => { -}; -var arrow3 = (a, b) => { -}; +var arrow1 = a => { }; +var arrow2 = (a) => { }; +var arrow3 = (a, b) => { }; diff --git a/tests/baselines/reference/emitArrowFunctionES6.js b/tests/baselines/reference/emitArrowFunctionES6.js index 6409fc9464..603b2737fc 100644 --- a/tests/baselines/reference/emitArrowFunctionES6.js +++ b/tests/baselines/reference/emitArrowFunctionES6.js @@ -9,17 +9,10 @@ foo(() => { return false; }); //// [emitArrowFunctionES6.js] -var f1 = () => { -}; -var f2 = (x, y) => { -}; -var f3 = (x, y, ...rest) => { -}; -var f4 = (x, y, z = 10) => { -}; -function foo(func) { -} +var f1 = () => { }; +var f2 = (x, y) => { }; +var f3 = (x, y, ...rest) => { }; +var f4 = (x, y, z = 10) => { }; +function foo(func) { } foo(() => true); -foo(() => { - return false; -}); +foo(() => { return false; }); diff --git a/tests/baselines/reference/emitArrowFunctionThisCapturing.js b/tests/baselines/reference/emitArrowFunctionThisCapturing.js index 25d9f7f100..ac4326ea50 100644 --- a/tests/baselines/reference/emitArrowFunctionThisCapturing.js +++ b/tests/baselines/reference/emitArrowFunctionThisCapturing.js @@ -22,8 +22,7 @@ var f1 = function () { var f2 = function (x) { _this.name = x; }; -function foo(func) { -} +function foo(func) { } foo(function () { _this.age = 100; return true; diff --git a/tests/baselines/reference/emitArrowFunctionThisCapturingES6.js b/tests/baselines/reference/emitArrowFunctionThisCapturingES6.js index bf235bc0ee..2a82ef9c80 100644 --- a/tests/baselines/reference/emitArrowFunctionThisCapturingES6.js +++ b/tests/baselines/reference/emitArrowFunctionThisCapturingES6.js @@ -21,8 +21,7 @@ var f1 = () => { var f2 = (x) => { this.name = x; }; -function foo(func) { -} +function foo(func) { } foo(() => { this.age = 100; return true; diff --git a/tests/baselines/reference/emitArrowFunctionWhenUsingArguments.js b/tests/baselines/reference/emitArrowFunctionWhenUsingArguments.js index 00a4c7aa05..589449fad6 100644 --- a/tests/baselines/reference/emitArrowFunctionWhenUsingArguments.js +++ b/tests/baselines/reference/emitArrowFunctionWhenUsingArguments.js @@ -45,8 +45,7 @@ function baz() { var arg = arguments[0]; }); } -function foo(inputFunc) { -} +function foo(inputFunc) { } foo(() => { var arg = arguments[0]; // error }); diff --git a/tests/baselines/reference/emitArrowFunctionWhenUsingArgumentsES6.js b/tests/baselines/reference/emitArrowFunctionWhenUsingArgumentsES6.js index 0deacd409d..2f84d0843d 100644 --- a/tests/baselines/reference/emitArrowFunctionWhenUsingArgumentsES6.js +++ b/tests/baselines/reference/emitArrowFunctionWhenUsingArgumentsES6.js @@ -45,8 +45,7 @@ function baz() { var arg = arguments[0]; }); } -function foo(inputFunc) { -} +function foo(inputFunc) { } foo(() => { var arg = arguments[0]; // error }); diff --git a/tests/baselines/reference/emitArrowFunctionsAsIs.js b/tests/baselines/reference/emitArrowFunctionsAsIs.js index ee8347dda3..cf773efb8b 100644 --- a/tests/baselines/reference/emitArrowFunctionsAsIs.js +++ b/tests/baselines/reference/emitArrowFunctionsAsIs.js @@ -5,9 +5,6 @@ var arrow2 = (a) => { }; var arrow3 = (a, b) => { }; //// [emitArrowFunctionsAsIs.js] -var arrow1 = function (a) { -}; -var arrow2 = function (a) { -}; -var arrow3 = function (a, b) { -}; +var arrow1 = function (a) { }; +var arrow2 = function (a) { }; +var arrow3 = function (a, b) { }; diff --git a/tests/baselines/reference/emitArrowFunctionsAsIsES6.js b/tests/baselines/reference/emitArrowFunctionsAsIsES6.js index 021e048ed8..32323a6597 100644 --- a/tests/baselines/reference/emitArrowFunctionsAsIsES6.js +++ b/tests/baselines/reference/emitArrowFunctionsAsIsES6.js @@ -5,9 +5,6 @@ var arrow2 = (a) => { }; var arrow3 = (a, b) => { }; //// [emitArrowFunctionsAsIsES6.js] -var arrow1 = a => { -}; -var arrow2 = (a) => { -}; -var arrow3 = (a, b) => { -}; +var arrow1 = a => { }; +var arrow2 = (a) => { }; +var arrow3 = (a, b) => { }; diff --git a/tests/baselines/reference/emitClassDeclarationWithConstructorInES6.js b/tests/baselines/reference/emitClassDeclarationWithConstructorInES6.js index 8c115b17e9..f74442e9fd 100644 --- a/tests/baselines/reference/emitClassDeclarationWithConstructorInES6.js +++ b/tests/baselines/reference/emitClassDeclarationWithConstructorInES6.js @@ -28,8 +28,7 @@ class B { class A { constructor(x) { } - foo() { - } + foo() { } } class B { constructor(x, z = "hello", ...args) { diff --git a/tests/baselines/reference/emitClassDeclarationWithExtensionInES6.js b/tests/baselines/reference/emitClassDeclarationWithExtensionInES6.js index 5c64aebd16..f31b5df0cb 100644 --- a/tests/baselines/reference/emitClassDeclarationWithExtensionInES6.js +++ b/tests/baselines/reference/emitClassDeclarationWithExtensionInES6.js @@ -25,12 +25,10 @@ class D extends C { //// [emitClassDeclarationWithExtensionInES6.js] class B { - baz(a, y = 10) { - } + baz(a, y = 10) { } } class C extends B { - foo() { - } + foo() { } baz(a, y) { super.baz(a, y); } diff --git a/tests/baselines/reference/emitClassDeclarationWithGetterSetterInES6.js b/tests/baselines/reference/emitClassDeclarationWithGetterSetterInES6.js index 68ccd1568e..ece24d691d 100644 --- a/tests/baselines/reference/emitClassDeclarationWithGetterSetterInES6.js +++ b/tests/baselines/reference/emitClassDeclarationWithGetterSetterInES6.js @@ -48,10 +48,7 @@ class C { } set ["computedname"](y) { } - set foo(a) { - } - static set bar(b) { - } - static set ["computedname"](b) { - } + set foo(a) { } + static set bar(b) { } + static set ["computedname"](b) { } } diff --git a/tests/baselines/reference/emitClassDeclarationWithLiteralPropertyNameInES6.js b/tests/baselines/reference/emitClassDeclarationWithLiteralPropertyNameInES6.js index d82750f276..961bd4041c 100644 --- a/tests/baselines/reference/emitClassDeclarationWithLiteralPropertyNameInES6.js +++ b/tests/baselines/reference/emitClassDeclarationWithLiteralPropertyNameInES6.js @@ -22,14 +22,10 @@ class B { this[0o23534] = "WORLD"; this[20] = "twenty"; } - "foo"() { - } - 0b1110() { - } - 11() { - } - interface() { - } + "foo"() { } + 0b1110() { } + 11() { } + interface() { } } B["hi"] = 10000; B[22] = "twenty-two"; diff --git a/tests/baselines/reference/emitClassDeclarationWithMethodInES6.js b/tests/baselines/reference/emitClassDeclarationWithMethodInES6.js index 20f58b4274..fc0a510461 100644 --- a/tests/baselines/reference/emitClassDeclarationWithMethodInES6.js +++ b/tests/baselines/reference/emitClassDeclarationWithMethodInES6.js @@ -24,35 +24,23 @@ class D { //// [emitClassDeclarationWithMethodInES6.js] class D { - foo() { - } - ["computedName"]() { - } - ["computedName"](a) { - } - ["computedName"](a) { - return 1; - } + foo() { } + ["computedName"]() { } + ["computedName"](a) { } + ["computedName"](a) { return 1; } bar() { return this._bar; } baz(a, x) { return "HELLO"; } - static ["computedname"]() { - } - static ["computedname"](a) { - } - static ["computedname"](a) { - return true; - } + static ["computedname"]() { } + static ["computedname"](a) { } + static ["computedname"](a) { return true; } static staticMethod() { var x = 1 + 2; return x; } - static foo(a) { - } - static bar(a) { - return 1; - } + static foo(a) { } + static bar(a) { return 1; } } diff --git a/tests/baselines/reference/emitClassDeclarationWithThisKeywordInES6.js b/tests/baselines/reference/emitClassDeclarationWithThisKeywordInES6.js index 14f74682c0..0098cddb1f 100644 --- a/tests/baselines/reference/emitClassDeclarationWithThisKeywordInES6.js +++ b/tests/baselines/reference/emitClassDeclarationWithThisKeywordInES6.js @@ -24,8 +24,7 @@ class B { this.x = 10; this.x = 10; } - static log(a) { - } + static log(a) { } foo() { B.log(this.x); } diff --git a/tests/baselines/reference/emitDefaultParametersFunctionES6.js b/tests/baselines/reference/emitDefaultParametersFunctionES6.js index f4084a16f6..0d1c9460fe 100644 --- a/tests/baselines/reference/emitDefaultParametersFunctionES6.js +++ b/tests/baselines/reference/emitDefaultParametersFunctionES6.js @@ -5,11 +5,7 @@ function bar(y = 10) { } function bar1(y = 10, ...rest) { } //// [emitDefaultParametersFunctionES6.js] -function foo(x, y = 10) { -} -function baz(x, y = 5, ...rest) { -} -function bar(y = 10) { -} -function bar1(y = 10, ...rest) { -} +function foo(x, y = 10) { } +function baz(x, y = 5, ...rest) { } +function bar(y = 10) { } +function bar1(y = 10, ...rest) { } diff --git a/tests/baselines/reference/emitDefaultParametersFunctionExpressionES6.js b/tests/baselines/reference/emitDefaultParametersFunctionExpressionES6.js index 5a49a200c6..f72c245b17 100644 --- a/tests/baselines/reference/emitDefaultParametersFunctionExpressionES6.js +++ b/tests/baselines/reference/emitDefaultParametersFunctionExpressionES6.js @@ -9,17 +9,10 @@ var y = (function (num = 10, boo = false, ...rest) { })() var z = (function (num: number, boo = false, ...rest) { })(10) //// [emitDefaultParametersFunctionExpressionES6.js] -var lambda1 = (y = "hello") => { -}; -var lambda2 = (x, y = "hello") => { -}; -var lambda3 = (x, y = "hello", ...rest) => { -}; -var lambda4 = (y = "hello", ...rest) => { -}; -var x = function (str = "hello", ...rest) { -}; -var y = (function (num = 10, boo = false, ...rest) { -})(); -var z = (function (num, boo = false, ...rest) { -})(10); +var lambda1 = (y = "hello") => { }; +var lambda2 = (x, y = "hello") => { }; +var lambda3 = (x, y = "hello", ...rest) => { }; +var lambda4 = (y = "hello", ...rest) => { }; +var x = function (str = "hello", ...rest) { }; +var y = (function (num = 10, boo = false, ...rest) { })(); +var z = (function (num, boo = false, ...rest) { })(10); diff --git a/tests/baselines/reference/emitDefaultParametersFunctionPropertyES6.js b/tests/baselines/reference/emitDefaultParametersFunctionPropertyES6.js index fce694a453..4a85f4a34b 100644 --- a/tests/baselines/reference/emitDefaultParametersFunctionPropertyES6.js +++ b/tests/baselines/reference/emitDefaultParametersFunctionPropertyES6.js @@ -8,12 +8,8 @@ var obj2 = { //// [emitDefaultParametersFunctionPropertyES6.js] var obj2 = { - func1(y = 10, ...rest) { - }, - func2(x = "hello") { - }, - func3(x, z, y = "hello") { - }, - func4(x, z, y = "hello", ...rest) { - }, + func1(y = 10, ...rest) { }, + func2(x = "hello") { }, + func3(x, z, y = "hello") { }, + func4(x, z, y = "hello", ...rest) { }, }; diff --git a/tests/baselines/reference/emitDefaultParametersMethodES6.js b/tests/baselines/reference/emitDefaultParametersMethodES6.js index 3981ddcba3..2b97e3e163 100644 --- a/tests/baselines/reference/emitDefaultParametersMethodES6.js +++ b/tests/baselines/reference/emitDefaultParametersMethodES6.js @@ -20,14 +20,10 @@ class E { class C { constructor(t, z, x, y = "hello") { } - foo(x, t = false) { - } - foo1(x, t = false, ...rest) { - } - bar(t = false) { - } - boo(t = false, ...rest) { - } + foo(x, t = false) { } + foo1(x, t = false, ...rest) { } + bar(t = false) { } + boo(t = false, ...rest) { } } class D { constructor(y = "hello") { diff --git a/tests/baselines/reference/emitRestParametersFunctionES6.js b/tests/baselines/reference/emitRestParametersFunctionES6.js index 242c40f252..a07b3a1317 100644 --- a/tests/baselines/reference/emitRestParametersFunctionES6.js +++ b/tests/baselines/reference/emitRestParametersFunctionES6.js @@ -3,7 +3,5 @@ function bar(...rest) { } function foo(x: number, y: string, ...rest) { } //// [emitRestParametersFunctionES6.js] -function bar(...rest) { -} -function foo(x, y, ...rest) { -} +function bar(...rest) { } +function foo(x, y, ...rest) { } diff --git a/tests/baselines/reference/emitRestParametersFunctionExpressionES6.js b/tests/baselines/reference/emitRestParametersFunctionExpressionES6.js index c7851db5e7..aa52a29b13 100644 --- a/tests/baselines/reference/emitRestParametersFunctionExpressionES6.js +++ b/tests/baselines/reference/emitRestParametersFunctionExpressionES6.js @@ -5,11 +5,7 @@ var funcExp2 = function (...rest) { } var funcExp3 = (function (...rest) { })() //// [emitRestParametersFunctionExpressionES6.js] -var funcExp = (...rest) => { -}; -var funcExp1 = (X, ...rest) => { -}; -var funcExp2 = function (...rest) { -}; -var funcExp3 = (function (...rest) { -})(); +var funcExp = (...rest) => { }; +var funcExp1 = (X, ...rest) => { }; +var funcExp2 = function (...rest) { }; +var funcExp3 = (function (...rest) { })(); diff --git a/tests/baselines/reference/emitRestParametersFunctionPropertyES6.js b/tests/baselines/reference/emitRestParametersFunctionPropertyES6.js index 87aa489ecf..122a1f6ed5 100644 --- a/tests/baselines/reference/emitRestParametersFunctionPropertyES6.js +++ b/tests/baselines/reference/emitRestParametersFunctionPropertyES6.js @@ -10,6 +10,5 @@ var obj2 = { //// [emitRestParametersFunctionPropertyES6.js] var obj; var obj2 = { - func(...rest) { - } + func(...rest) { } }; diff --git a/tests/baselines/reference/emitRestParametersMethodES6.js b/tests/baselines/reference/emitRestParametersMethodES6.js index fba6ed01e6..930cd109b6 100644 --- a/tests/baselines/reference/emitRestParametersMethodES6.js +++ b/tests/baselines/reference/emitRestParametersMethodES6.js @@ -18,16 +18,12 @@ class D { class C { constructor(name, ...rest) { } - bar(...rest) { - } - foo(x, ...rest) { - } + bar(...rest) { } + foo(x, ...rest) { } } class D { constructor(...rest) { } - bar(...rest) { - } - foo(x, ...rest) { - } + bar(...rest) { } + foo(x, ...rest) { } } diff --git a/tests/baselines/reference/emptyExpr.js b/tests/baselines/reference/emptyExpr.js index 4bda58e324..de3bddeba1 100644 --- a/tests/baselines/reference/emptyExpr.js +++ b/tests/baselines/reference/emptyExpr.js @@ -2,6 +2,4 @@ [{},] //// [emptyExpr.js] -[ - {}, -]; +[{},]; diff --git a/tests/baselines/reference/emptyTypeArgumentList.js b/tests/baselines/reference/emptyTypeArgumentList.js index 91fce39628..30093113be 100644 --- a/tests/baselines/reference/emptyTypeArgumentList.js +++ b/tests/baselines/reference/emptyTypeArgumentList.js @@ -3,6 +3,5 @@ function foo() { } foo<>(); //// [emptyTypeArgumentList.js] -function foo() { -} +function foo() { } foo(); diff --git a/tests/baselines/reference/enumAssignabilityInInheritance.js b/tests/baselines/reference/enumAssignabilityInInheritance.js index 065c561d9e..0143985425 100644 --- a/tests/baselines/reference/enumAssignabilityInInheritance.js +++ b/tests/baselines/reference/enumAssignabilityInInheritance.js @@ -144,8 +144,7 @@ var E2; E2[E2["A"] = 0] = "A"; })(E2 || (E2 = {})); var r4 = foo13(E.A); -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; diff --git a/tests/baselines/reference/enumBasics.js b/tests/baselines/reference/enumBasics.js index f6548f99b9..25aec5a72d 100644 --- a/tests/baselines/reference/enumBasics.js +++ b/tests/baselines/reference/enumBasics.js @@ -150,21 +150,9 @@ var E9; // (refer to .js to validate) // Enum constant members are propagated var doNotPropagate = [ - E8.B, - E7.A, - E4.Z, - E3.X, - E3.Y, - E3.Z + E8.B, E7.A, E4.Z, E3.X, E3.Y, E3.Z ]; // Enum computed members are not propagated var doPropagate = [ - E9.A, - E9.B, - E6.B, - E6.C, - E6.A, - E5.A, - E5.B, - E5.C + E9.A, E9.B, E6.B, E6.C, E6.A, E5.A, E5.B, E5.C ]; diff --git a/tests/baselines/reference/enumConflictsWithGlobalIdentifier.js b/tests/baselines/reference/enumConflictsWithGlobalIdentifier.js index d463073bb8..5c32fe5a16 100644 --- a/tests/baselines/reference/enumConflictsWithGlobalIdentifier.js +++ b/tests/baselines/reference/enumConflictsWithGlobalIdentifier.js @@ -11,5 +11,6 @@ var Position; (function (Position) { Position[Position["IgnoreRulesSpecific"] = 0] = "IgnoreRulesSpecific"; })(Position || (Position = {})); -var x = IgnoreRulesSpecific.; +var x = IgnoreRulesSpecific. +; var y = Position.IgnoreRulesSpecific; diff --git a/tests/baselines/reference/enumIndexer.js b/tests/baselines/reference/enumIndexer.js index 9862d787d2..561461229c 100644 --- a/tests/baselines/reference/enumIndexer.js +++ b/tests/baselines/reference/enumIndexer.js @@ -13,15 +13,6 @@ var MyEnumType; MyEnumType[MyEnumType["foo"] = 0] = "foo"; MyEnumType[MyEnumType["bar"] = 1] = "bar"; })(MyEnumType || (MyEnumType = {})); -var _arr = [ - { - key: 'foo' - }, - { - key: 'bar' - } -]; +var _arr = [{ key: 'foo' }, { key: 'bar' }]; var enumValue = MyEnumType.foo; -var x = _arr.map(function (o) { - return MyEnumType[o.key] === enumValue; -}); // these are not same type +var x = _arr.map(function (o) { return MyEnumType[o.key] === enumValue; }); // these are not same type diff --git a/tests/baselines/reference/enumIsNotASubtypeOfAnythingButNumber.js b/tests/baselines/reference/enumIsNotASubtypeOfAnythingButNumber.js index f9ac7661e3..d932985ad7 100644 --- a/tests/baselines/reference/enumIsNotASubtypeOfAnythingButNumber.js +++ b/tests/baselines/reference/enumIsNotASubtypeOfAnythingButNumber.js @@ -150,8 +150,7 @@ var E2; (function (E2) { E2[E2["A"] = 0] = "A"; })(E2 || (E2 = {})); -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; diff --git a/tests/baselines/reference/enumMemberResolution.js b/tests/baselines/reference/enumMemberResolution.js index c021eb8d47..ec27342471 100644 --- a/tests/baselines/reference/enumMemberResolution.js +++ b/tests/baselines/reference/enumMemberResolution.js @@ -12,6 +12,7 @@ var Position2; (function (Position2) { Position2[Position2["IgnoreRulesSpecific"] = 0] = "IgnoreRulesSpecific"; })(Position2 || (Position2 = {})); -var x = IgnoreRulesSpecific.; // error +var x = IgnoreRulesSpecific. +; // error var y = 1; var z = Position2.IgnoreRulesSpecific; // no error diff --git a/tests/baselines/reference/enumMerging.js b/tests/baselines/reference/enumMerging.js index d8d9373d3f..5dc5a475b4 100644 --- a/tests/baselines/reference/enumMerging.js +++ b/tests/baselines/reference/enumMerging.js @@ -95,14 +95,7 @@ var M1; EConst1[EConst1["F"] = 8] = "F"; })(M1.EConst1 || (M1.EConst1 = {})); var EConst1 = M1.EConst1; - var x = [ - EConst1.A, - EConst1.B, - EConst1.C, - EConst1.D, - EConst1.E, - EConst1.F - ]; + var x = [EConst1.A, EConst1.B, EConst1.C, EConst1.D, EConst1.E, EConst1.F]; })(M1 || (M1 = {})); // Enum with only computed members across 2 declarations with the same root module var M2; @@ -119,14 +112,7 @@ var M2; EComp2[EComp2["F"] = 'foo'.length] = "F"; })(M2.EComp2 || (M2.EComp2 = {})); var EComp2 = M2.EComp2; - var x = [ - EComp2.A, - EComp2.B, - EComp2.C, - EComp2.D, - EComp2.E, - EComp2.F - ]; + var x = [EComp2.A, EComp2.B, EComp2.C, EComp2.D, EComp2.E, EComp2.F]; })(M2 || (M2 = {})); // Enum with initializer in only one of two declarations with constant members with the same root module var M3; diff --git a/tests/baselines/reference/errorOnContextuallyTypedReturnType.js b/tests/baselines/reference/errorOnContextuallyTypedReturnType.js index 2a49ccd2b6..9e0c26b6be 100644 --- a/tests/baselines/reference/errorOnContextuallyTypedReturnType.js +++ b/tests/baselines/reference/errorOnContextuallyTypedReturnType.js @@ -4,7 +4,5 @@ var n2: () => boolean = function ():boolean { }; // expect an error here //// [errorOnContextuallyTypedReturnType.js] -var n1 = function () { -}; // expect an error here -var n2 = function () { -}; // expect an error here +var n1 = function () { }; // expect an error here +var n2 = function () { }; // expect an error here diff --git a/tests/baselines/reference/errorSuperPropertyAccess.js b/tests/baselines/reference/errorSuperPropertyAccess.js index 4ddcca530f..26ef99f269 100644 --- a/tests/baselines/reference/errorSuperPropertyAccess.js +++ b/tests/baselines/reference/errorSuperPropertyAccess.js @@ -172,14 +172,10 @@ var SomeBase = (function () { this.privateMember = 0; this.publicMember = 0; } - SomeBase.prototype.privateFunc = function () { - }; - SomeBase.prototype.publicFunc = function () { - }; - SomeBase.privateStaticFunc = function () { - }; - SomeBase.publicStaticFunc = function () { - }; + SomeBase.prototype.privateFunc = function () { }; + SomeBase.prototype.publicFunc = function () { }; + SomeBase.privateStaticFunc = function () { }; + SomeBase.publicStaticFunc = function () { }; SomeBase.privateStaticMember = 0; SomeBase.publicStaticMember = 0; return SomeBase; @@ -213,9 +209,7 @@ var SomeDerived1 = (function (_super) { _super.publicFunc.call(this); } var x = { - test: function () { - return _super.publicFunc.call(this); - } + test: function () { return _super.publicFunc.call(this); } }; }; return SomeDerived1; @@ -277,7 +271,4 @@ var SomeDerived3 = (function (_super) { return SomeDerived3; })(SomeBase); // In object literal -var obj = { - n: _super.wat, - p: _super.foo.call(this) -}; +var obj = { n: _super.wat, p: _super.foo.call(this) }; diff --git a/tests/baselines/reference/errorSupression1.js b/tests/baselines/reference/errorSupression1.js index 059530be45..53e40e585f 100644 --- a/tests/baselines/reference/errorSupression1.js +++ b/tests/baselines/reference/errorSupression1.js @@ -12,9 +12,7 @@ baz.concat("y"); var Foo = (function () { function Foo() { } - Foo.bar = function () { - return "x"; - }; + Foo.bar = function () { return "x"; }; return Foo; })(); var baz = Foo.b; diff --git a/tests/baselines/reference/errorsInGenericTypeReference.js b/tests/baselines/reference/errorsInGenericTypeReference.js index 6a9f62c5e4..03bf31a6a6 100644 --- a/tests/baselines/reference/errorsInGenericTypeReference.js +++ b/tests/baselines/reference/errorsInGenericTypeReference.js @@ -88,8 +88,7 @@ var Foo = (function () { var testClass1 = (function () { function testClass1() { } - testClass1.prototype.method = function () { - }; + testClass1.prototype.method = function () { }; return testClass1; })(); var tc1 = new testClass1(); @@ -105,15 +104,10 @@ var tc2 = new testClass2(); // error: could not find symbol V var testClass3 = (function () { function testClass3() { } - testClass3.prototype.testMethod1 = function () { - return null; - }; // error: could not find symbol V - testClass3.testMethod2 = function () { - return null; - }; // error: could not find symbol V + testClass3.prototype.testMethod1 = function () { return null; }; // error: could not find symbol V + testClass3.testMethod2 = function () { return null; }; // error: could not find symbol V Object.defineProperty(testClass3.prototype, "a", { - set: function (value) { - } // error: could not find symbol V + set: function (value) { } // error: could not find symbol V , enumerable: true, configurable: true @@ -121,12 +115,9 @@ var testClass3 = (function () { return testClass3; })(); // in function return type annotation -function testFunction1() { - return null; -} // error: could not find symbol V +function testFunction1() { return null; } // error: could not find symbol V // in paramter types -function testFunction2(p) { -} // error: could not find symbol V +function testFunction2(p) { } // error: could not find symbol V // in var type annotation var f; // error: could not find symbol V // in constraints @@ -138,8 +129,7 @@ var testClass4 = (function () { var testClass6 = (function () { function testClass6() { } - testClass6.prototype.method = function () { - }; // error: could not find symbol V + testClass6.prototype.method = function () { }; // error: could not find symbol V return testClass6; })(); // in extends clause diff --git a/tests/baselines/reference/es5ExportDefaultClassDeclaration.js b/tests/baselines/reference/es5ExportDefaultClassDeclaration.js index f25cf0f4ca..b5cfdb02f7 100644 --- a/tests/baselines/reference/es5ExportDefaultClassDeclaration.js +++ b/tests/baselines/reference/es5ExportDefaultClassDeclaration.js @@ -9,8 +9,7 @@ export default class C { var C = (function () { function C() { } - C.prototype.method = function () { - }; + C.prototype.method = function () { }; return C; })(); exports.default = C; diff --git a/tests/baselines/reference/es5ExportDefaultClassDeclaration2.js b/tests/baselines/reference/es5ExportDefaultClassDeclaration2.js index 4d29fce3c1..de0d109dad 100644 --- a/tests/baselines/reference/es5ExportDefaultClassDeclaration2.js +++ b/tests/baselines/reference/es5ExportDefaultClassDeclaration2.js @@ -9,8 +9,7 @@ export default class { var default_1 = (function () { function default_1() { } - default_1.prototype.method = function () { - }; + default_1.prototype.method = function () { }; return default_1; })(); exports.default = default_1; diff --git a/tests/baselines/reference/es5ExportDefaultFunctionDeclaration.js b/tests/baselines/reference/es5ExportDefaultFunctionDeclaration.js index e120a419fd..e98ce20828 100644 --- a/tests/baselines/reference/es5ExportDefaultFunctionDeclaration.js +++ b/tests/baselines/reference/es5ExportDefaultFunctionDeclaration.js @@ -4,9 +4,14 @@ export default function f() { } //// [es5ExportDefaultFunctionDeclaration.js] +<<<<<<< HEAD function f() { } exports.default = f; +======= +function f() { } +exports.f = f; +>>>>>>> master //// [es5ExportDefaultFunctionDeclaration.d.ts] diff --git a/tests/baselines/reference/es5ExportDefaultFunctionDeclaration2.js b/tests/baselines/reference/es5ExportDefaultFunctionDeclaration2.js index c274cc77d1..95a43270e0 100644 --- a/tests/baselines/reference/es5ExportDefaultFunctionDeclaration2.js +++ b/tests/baselines/reference/es5ExportDefaultFunctionDeclaration2.js @@ -4,8 +4,12 @@ export default function () { } //// [es5ExportDefaultFunctionDeclaration2.js] +<<<<<<< HEAD function default_1() { } +======= +function () { } +>>>>>>> master exports.default = default_1; diff --git a/tests/baselines/reference/es5ExportDefaultIdentifier.js b/tests/baselines/reference/es5ExportDefaultIdentifier.js index 81f2e9e0ac..739f3d6c10 100644 --- a/tests/baselines/reference/es5ExportDefaultIdentifier.js +++ b/tests/baselines/reference/es5ExportDefaultIdentifier.js @@ -6,8 +6,7 @@ export default f; //// [es5ExportDefaultIdentifier.js] -function f() { -} +function f() { } exports.f = f; exports.default = f; diff --git a/tests/baselines/reference/es5ExportEquals.js b/tests/baselines/reference/es5ExportEquals.js index 04a34b1e23..88d1da4201 100644 --- a/tests/baselines/reference/es5ExportEquals.js +++ b/tests/baselines/reference/es5ExportEquals.js @@ -6,8 +6,7 @@ export = f; //// [es5ExportEquals.js] -function f() { -} +function f() { } exports.f = f; module.exports = f; diff --git a/tests/baselines/reference/es5ModuleInternalNamedImports.js b/tests/baselines/reference/es5ModuleInternalNamedImports.js index 456ad30523..d7d120e8af 100644 --- a/tests/baselines/reference/es5ModuleInternalNamedImports.js +++ b/tests/baselines/reference/es5ModuleInternalNamedImports.js @@ -51,8 +51,7 @@ define(["require", "exports"], function (require, exports) { var x; })(M_M = M.M_M || (M.M_M = {})); // function - function M_F() { - } + function M_F() { } M.M_F = M_F; // enum (function (M_E) { diff --git a/tests/baselines/reference/es6ClassTest.js b/tests/baselines/reference/es6ClassTest.js index 5fd9f0e9b7..08c184a0df 100644 --- a/tests/baselines/reference/es6ClassTest.js +++ b/tests/baselines/reference/es6ClassTest.js @@ -112,12 +112,8 @@ var Foo = (function (_super) { this.x = x; this.gar = 5; } - Foo.prototype.bar = function () { - return 0; - }; - Foo.prototype.boo = function (x) { - return x; - }; + Foo.prototype.bar = function () { return 0; }; + Foo.prototype.boo = function (x) { return x; }; Foo.statVal = 0; return Foo; })(Bar); diff --git a/tests/baselines/reference/es6ClassTest2.js b/tests/baselines/reference/es6ClassTest2.js index 8ef7a2fa37..f23be04fd1 100644 --- a/tests/baselines/reference/es6ClassTest2.js +++ b/tests/baselines/reference/es6ClassTest2.js @@ -248,9 +248,7 @@ var SplatMonster = (function () { }; return SplatMonster; })(); -function foo() { - return true; -} +function foo() { return true; } var PrototypeMonster = (function () { function PrototypeMonster() { this.age = 1; @@ -302,10 +300,8 @@ var Visibility = (function () { this.x = 1; this.y = 2; } - Visibility.prototype.foo = function () { - }; - Visibility.prototype.bar = function () { - }; + Visibility.prototype.foo = function () { }; + Visibility.prototype.bar = function () { }; return Visibility; })(); var BaseClassWithConstructor = (function () { diff --git a/tests/baselines/reference/es6ClassTest3.js b/tests/baselines/reference/es6ClassTest3.js index 371a983d15..dc9f1c6715 100644 --- a/tests/baselines/reference/es6ClassTest3.js +++ b/tests/baselines/reference/es6ClassTest3.js @@ -22,10 +22,8 @@ var M; this.x = 1; this.y = 2; } - Visibility.prototype.foo = function () { - }; - Visibility.prototype.bar = function () { - }; + Visibility.prototype.foo = function () { }; + Visibility.prototype.bar = function () { }; return Visibility; })(); })(M || (M = {})); diff --git a/tests/baselines/reference/es6ClassTest8.js b/tests/baselines/reference/es6ClassTest8.js index 3c616e5e89..f96bbd16b0 100644 --- a/tests/baselines/reference/es6ClassTest8.js +++ b/tests/baselines/reference/es6ClassTest8.js @@ -41,9 +41,7 @@ class Camera { //// [es6ClassTest8.js] -function f1(x) { - return x; -} +function f1(x) { return x; } var C = (function () { function C() { var bar = (function () { @@ -59,21 +57,11 @@ var Vector = (function () { this.y = y; this.z = z; } - Vector.norm = function (v) { - return null; - }; - Vector.minus = function (v1, v2) { - return null; - }; - Vector.times = function (v1, v2) { - return null; - }; - Vector.cross = function (v1, v2) { - return null; - }; - Vector.dot = function (v1, v2) { - return null; - }; + Vector.norm = function (v) { return null; }; + Vector.minus = function (v1, v2) { return null; }; + Vector.times = function (v1, v2) { return null; }; + Vector.cross = function (v1, v2) { return null; }; + Vector.dot = function (v1, v2) { return null; }; return Vector; })(); var Camera = (function () { diff --git a/tests/baselines/reference/es6ClassTest9.js b/tests/baselines/reference/es6ClassTest9.js index d45c99d3b0..538fec5a2a 100644 --- a/tests/baselines/reference/es6ClassTest9.js +++ b/tests/baselines/reference/es6ClassTest9.js @@ -5,5 +5,4 @@ function foo() {} //// [es6ClassTest9.js] (); -function foo() { -} +function foo() { } diff --git a/tests/baselines/reference/es6ExportDefaultClassDeclaration.js b/tests/baselines/reference/es6ExportDefaultClassDeclaration.js index 2a25b5ac34..8162d6813b 100644 --- a/tests/baselines/reference/es6ExportDefaultClassDeclaration.js +++ b/tests/baselines/reference/es6ExportDefaultClassDeclaration.js @@ -7,8 +7,7 @@ export default class C { //// [es6ExportDefaultClassDeclaration.js] export default class C { - method() { - } + method() { } } diff --git a/tests/baselines/reference/es6ExportDefaultClassDeclaration2.js b/tests/baselines/reference/es6ExportDefaultClassDeclaration2.js index ac5d92b6c1..e2f8524fb0 100644 --- a/tests/baselines/reference/es6ExportDefaultClassDeclaration2.js +++ b/tests/baselines/reference/es6ExportDefaultClassDeclaration2.js @@ -7,8 +7,7 @@ export default class { //// [es6ExportDefaultClassDeclaration2.js] export default class { - method() { - } + method() { } } diff --git a/tests/baselines/reference/es6ExportDefaultFunctionDeclaration.js b/tests/baselines/reference/es6ExportDefaultFunctionDeclaration.js index ec5789203d..a30c8d7103 100644 --- a/tests/baselines/reference/es6ExportDefaultFunctionDeclaration.js +++ b/tests/baselines/reference/es6ExportDefaultFunctionDeclaration.js @@ -4,8 +4,7 @@ export default function f() { } //// [es6ExportDefaultFunctionDeclaration.js] -export default function f() { -} +export default function f() { } //// [es6ExportDefaultFunctionDeclaration.d.ts] diff --git a/tests/baselines/reference/es6ExportDefaultFunctionDeclaration2.js b/tests/baselines/reference/es6ExportDefaultFunctionDeclaration2.js index 80e37f18d2..46ed72dd23 100644 --- a/tests/baselines/reference/es6ExportDefaultFunctionDeclaration2.js +++ b/tests/baselines/reference/es6ExportDefaultFunctionDeclaration2.js @@ -4,8 +4,7 @@ export default function () { } //// [es6ExportDefaultFunctionDeclaration2.js] -export default function () { -} +export default function () { } //// [es6ExportDefaultFunctionDeclaration2.d.ts] diff --git a/tests/baselines/reference/es6ExportDefaultIdentifier.js b/tests/baselines/reference/es6ExportDefaultIdentifier.js index 5785220dfe..1fd3a38ff8 100644 --- a/tests/baselines/reference/es6ExportDefaultIdentifier.js +++ b/tests/baselines/reference/es6ExportDefaultIdentifier.js @@ -6,8 +6,7 @@ export default f; //// [es6ExportDefaultIdentifier.js] -export function f() { -} +export function f() { } export default f; diff --git a/tests/baselines/reference/es6ExportEquals.js b/tests/baselines/reference/es6ExportEquals.js index 68c5788c89..e4cf13758f 100644 --- a/tests/baselines/reference/es6ExportEquals.js +++ b/tests/baselines/reference/es6ExportEquals.js @@ -6,8 +6,7 @@ export = f; //// [es6ExportEquals.js] -export function f() { -} +export function f() { } //// [es6ExportEquals.d.ts] diff --git a/tests/baselines/reference/es6MemberScoping.js b/tests/baselines/reference/es6MemberScoping.js index 85f76a9393..7e70045ceb 100644 --- a/tests/baselines/reference/es6MemberScoping.js +++ b/tests/baselines/reference/es6MemberScoping.js @@ -30,8 +30,6 @@ var Foo = (function () { var Foo2 = (function () { function Foo2() { } - Foo2.Foo2 = function () { - return 0; - }; // should not be an error + Foo2.Foo2 = function () { return 0; }; // should not be an error return Foo2; })(); diff --git a/tests/baselines/reference/es6ModuleInternalNamedImports.js b/tests/baselines/reference/es6ModuleInternalNamedImports.js index db7c771eab..98504601d0 100644 --- a/tests/baselines/reference/es6ModuleInternalNamedImports.js +++ b/tests/baselines/reference/es6ModuleInternalNamedImports.js @@ -47,8 +47,7 @@ export var M; var x; })(M_M = M.M_M || (M.M_M = {})); // function - function M_F() { - } + function M_F() { } M.M_F = M_F; // enum (function (M_E) { diff --git a/tests/baselines/reference/es6ModuleInternalNamedImports2.js b/tests/baselines/reference/es6ModuleInternalNamedImports2.js index b080064306..9dee8153e5 100644 --- a/tests/baselines/reference/es6ModuleInternalNamedImports2.js +++ b/tests/baselines/reference/es6ModuleInternalNamedImports2.js @@ -49,8 +49,7 @@ export var M; var x; })(M_M = M.M_M || (M.M_M = {})); // function - function M_F() { - } + function M_F() { } M.M_F = M_F; // enum (function (M_E) { diff --git a/tests/baselines/reference/escapedIdentifiers.js b/tests/baselines/reference/escapedIdentifiers.js index dd06f3bbc8..7051d8d243 100644 --- a/tests/baselines/reference/escapedIdentifiers.js +++ b/tests/baselines/reference/escapedIdentifiers.js @@ -169,21 +169,13 @@ var classType2Object1 = new classType2(); classType2Object1.foo2 = 2; var classType2Object2 = new classType\u0032(); classType2Object2.foo2 = 2; -var interfaceType1Object1 = { - bar1: 0 -}; +var interfaceType1Object1 = { bar1: 0 }; interfaceType1Object1.bar1 = 2; -var interfaceType1Object2 = { - bar1: 0 -}; +var interfaceType1Object2 = { bar1: 0 }; interfaceType1Object2.bar1 = 2; -var interfaceType2Object1 = { - bar2: 0 -}; +var interfaceType2Object1 = { bar2: 0 }; interfaceType2Object1.bar2 = 2; -var interfaceType2Object2 = { - bar2: 0 -}; +var interfaceType2Object2 = { bar2: 0 }; interfaceType2Object2.bar2 = 2; // arguments var testClass = (function () { diff --git a/tests/baselines/reference/everyTypeWithAnnotationAndInitializer.js b/tests/baselines/reference/everyTypeWithAnnotationAndInitializer.js index ee447619bf..707801dc4e 100644 --- a/tests/baselines/reference/everyTypeWithAnnotationAndInitializer.js +++ b/tests/baselines/reference/everyTypeWithAnnotationAndInitializer.js @@ -59,9 +59,7 @@ var D = (function () { } return D; })(); -function F(x) { - return 42; -} +function F(x) { return 42; } var M; (function (M) { var A = (function () { @@ -70,9 +68,7 @@ var M; return A; })(); M.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } M.F2 = F2; })(M || (M = {})); var aNumber = 9.9; @@ -85,17 +81,11 @@ var aVoid = undefined; var anInterface = new C(); var aClass = new C(); var aGenericClass = new D(); -var anObjectLiteral = { - id: 12 -}; +var anObjectLiteral = { id: 12 }; var anOtherObjectLiteral = new C(); var aFunction = F; var anOtherFunction = F; -var aLambda = function (x) { - return 2; -}; +var aLambda = function (x) { return 2; }; var aModule = M; var aClassInModule = new M.A(); -var aFunctionInModule = function (x) { - return 'this is a string'; -}; +var aFunctionInModule = function (x) { return 'this is a string'; }; diff --git a/tests/baselines/reference/everyTypeWithAnnotationAndInvalidInitializer.js b/tests/baselines/reference/everyTypeWithAnnotationAndInvalidInitializer.js index 10f3fd9bf1..40e45bf7ec 100644 --- a/tests/baselines/reference/everyTypeWithAnnotationAndInvalidInitializer.js +++ b/tests/baselines/reference/everyTypeWithAnnotationAndInvalidInitializer.js @@ -65,12 +65,8 @@ var D = (function () { } return D; })(); -function F(x) { - return 42; -} -function F2(x) { - return x < 42; -} +function F(x) { return 42; } +function F2(x) { return x < 42; } var M; (function (M) { var A = (function () { @@ -79,9 +75,7 @@ var M; return A; })(); M.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } M.F2 = F2; })(M || (M = {})); var N; @@ -92,9 +86,7 @@ var N; return A; })(); N.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } N.F2 = F2; })(N || (N = {})); var aNumber = 'this is a string'; @@ -104,15 +96,11 @@ var aVoid = 9.9; var anInterface = new D(); var aClass = new D(); var aGenericClass = new C(); -var anObjectLiteral = { - id: 'a string' -}; +var anObjectLiteral = { id: 'a string' }; var anOtherObjectLiteral = new C(); var aFunction = F2; var anOtherFunction = F2; -var aLambda = function (x) { - return 'a string'; -}; +var aLambda = function (x) { return 'a string'; }; var aModule = N; var aClassInModule = new N.A(); var aFunctionInModule = F2; diff --git a/tests/baselines/reference/everyTypeWithInitializer.js b/tests/baselines/reference/everyTypeWithInitializer.js index aafefcc577..aae0a9fe29 100644 --- a/tests/baselines/reference/everyTypeWithInitializer.js +++ b/tests/baselines/reference/everyTypeWithInitializer.js @@ -60,9 +60,7 @@ var D = (function () { } return D; })(); -function F(x) { - return 42; -} +function F(x) { return 42; } var M; (function (M) { var A = (function () { @@ -71,9 +69,7 @@ var M; return A; })(); M.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } M.F2 = F2; })(M || (M = {})); var aNumber = 9.9; @@ -85,13 +81,9 @@ var anOtherAny = new C(); var anUndefined = undefined; var aClass = new C(); var aGenericClass = new D(); -var anObjectLiteral = { - id: 12 -}; +var anObjectLiteral = { id: 12 }; var aFunction = F; -var aLambda = function (x) { - return 2; -}; +var aLambda = function (x) { return 2; }; var aModule = M; var aClassInModule = new M.A(); var aFunctionInModule = M.F2; diff --git a/tests/baselines/reference/exportAlreadySeen.js b/tests/baselines/reference/exportAlreadySeen.js index e18c0bbf7f..68d30a697f 100644 --- a/tests/baselines/reference/exportAlreadySeen.js +++ b/tests/baselines/reference/exportAlreadySeen.js @@ -23,8 +23,7 @@ declare module A { var M; (function (M) { M.x = 1; - function f() { - } + function f() { } M.f = f; var N; (function (N) { diff --git a/tests/baselines/reference/exportAssignTypes.js b/tests/baselines/reference/exportAssignTypes.js index d4b74659dc..e898f798a7 100644 --- a/tests/baselines/reference/exportAssignTypes.js +++ b/tests/baselines/reference/exportAssignTypes.js @@ -63,16 +63,10 @@ module.exports = x; var x = true; module.exports = x; //// [expArray.js] -var x = [ - 1, - 2 -]; +var x = [1, 2]; module.exports = x; //// [expObject.js] -var x = { - answer: 42, - when: 1776 -}; +var x = { answer: 42, when: 1776 }; module.exports = x; //// [expAny.js] var x; diff --git a/tests/baselines/reference/exportAssignmentConstrainedGenericType.js b/tests/baselines/reference/exportAssignmentConstrainedGenericType.js index e974281246..b62cc8251b 100644 --- a/tests/baselines/reference/exportAssignmentConstrainedGenericType.js +++ b/tests/baselines/reference/exportAssignmentConstrainedGenericType.js @@ -24,8 +24,5 @@ module.exports = Foo; //// [foo_1.js] var foo = require("./foo_0"); var x = new foo(true); // Should error -var y = new foo({ - a: "test", - b: 42 -}); // Should be OK +var y = new foo({ a: "test", b: 42 }); // Should be OK var z = y.test.b; diff --git a/tests/baselines/reference/exportAssignmentFunction.js b/tests/baselines/reference/exportAssignmentFunction.js index 6d4336bd4b..825d0f983e 100644 --- a/tests/baselines/reference/exportAssignmentFunction.js +++ b/tests/baselines/reference/exportAssignmentFunction.js @@ -12,9 +12,7 @@ var n: number = fooFunc(); //// [exportAssignmentFunction_A.js] define(["require", "exports"], function (require, exports) { - function foo() { - return 0; - } + function foo() { return 0; } return foo; }); //// [exportAssignmentFunction_B.js] diff --git a/tests/baselines/reference/exportAssignmentMergedInterface.js b/tests/baselines/reference/exportAssignmentMergedInterface.js index fbcb99bc64..f99d7f3a46 100644 --- a/tests/baselines/reference/exportAssignmentMergedInterface.js +++ b/tests/baselines/reference/exportAssignmentMergedInterface.js @@ -31,11 +31,7 @@ define(["require", "exports"], function (require, exports) { x("test"); x(42); var y = x.b; - if (!!x.c) { - } - var z = { - x: 1, - y: 2 - }; + if (!!x.c) { } + var z = { x: 1, y: 2 }; z = x.d; }); diff --git a/tests/baselines/reference/exportCodeGen.js b/tests/baselines/reference/exportCodeGen.js index 1b1f934b2f..30ed0b07ae 100644 --- a/tests/baselines/reference/exportCodeGen.js +++ b/tests/baselines/reference/exportCodeGen.js @@ -94,8 +94,7 @@ var E; Color[Color["Red"] = 0] = "Red"; })(E.Color || (E.Color = {})); var Color = E.Color; - function fn() { - } + function fn() { } E.fn = fn; var C = (function () { function C() { @@ -116,8 +115,7 @@ var F; (function (Color) { Color[Color["Red"] = 0] = "Red"; })(Color || (Color = {})); - function fn() { - } + function fn() { } var C = (function () { function C() { } diff --git a/tests/baselines/reference/exportImportMultipleFiles.js b/tests/baselines/reference/exportImportMultipleFiles.js index 225b605f68..10909808ff 100644 --- a/tests/baselines/reference/exportImportMultipleFiles.js +++ b/tests/baselines/reference/exportImportMultipleFiles.js @@ -14,9 +14,7 @@ lib.math.add(3, 4); // Shouldnt be error //// [exportImportMultipleFiles_math.js] define(["require", "exports"], function (require, exports) { - function add(a, b) { - return a + b; - } + function add(a, b) { return a + b; } exports.add = add; }); //// [exportImportMultipleFiles_library.js] diff --git a/tests/baselines/reference/exportImportNonInstantiatedModule.js b/tests/baselines/reference/exportImportNonInstantiatedModule.js index 720fbfafc6..d9081efcd3 100644 --- a/tests/baselines/reference/exportImportNonInstantiatedModule.js +++ b/tests/baselines/reference/exportImportNonInstantiatedModule.js @@ -14,6 +14,4 @@ var x: B.A1.I = { x: 1 }; var B; (function (B) { })(B || (B = {})); -var x = { - x: 1 -}; +var x = { x: 1 }; diff --git a/tests/baselines/reference/exportImportNonInstantiatedModule2.js b/tests/baselines/reference/exportImportNonInstantiatedModule2.js index 575271dba3..2782a6f6f6 100644 --- a/tests/baselines/reference/exportImportNonInstantiatedModule2.js +++ b/tests/baselines/reference/exportImportNonInstantiatedModule2.js @@ -24,9 +24,7 @@ define(["require", "exports"], function (require, exports) { //// [consumer.js] define(["require", "exports"], function (require, exports) { function w() { - return { - name: 'value' - }; + return { name: 'value' }; } exports.w = w; }); diff --git a/tests/baselines/reference/exportNonVisibleType.js b/tests/baselines/reference/exportNonVisibleType.js index edd0e6988d..101c356d58 100644 --- a/tests/baselines/reference/exportNonVisibleType.js +++ b/tests/baselines/reference/exportNonVisibleType.js @@ -36,10 +36,7 @@ export = C1; // Should work, private type I1 of visible class C1 only used in pr //// [foo1.js] -var x = { - a: "test", - b: 42 -}; +var x = { a: "test", b: 42 }; module.exports = x; //// [foo2.js] var C1 = (function () { diff --git a/tests/baselines/reference/exportPrivateType.js b/tests/baselines/reference/exportPrivateType.js index 96acc83edb..11ccc037ef 100644 --- a/tests/baselines/reference/exportPrivateType.js +++ b/tests/baselines/reference/exportPrivateType.js @@ -41,9 +41,7 @@ var foo; var C2 = (function () { function C2() { } - C2.prototype.test = function () { - return true; - }; + C2.prototype.test = function () { return true; }; return C2; })(); // None of the types are exported, so per section 10.3, should all be errors diff --git a/tests/baselines/reference/exportStar-amd.js b/tests/baselines/reference/exportStar-amd.js index fb04aa208b..dcd2d126a3 100644 --- a/tests/baselines/reference/exportStar-amd.js +++ b/tests/baselines/reference/exportStar-amd.js @@ -37,8 +37,7 @@ define(["require", "exports"], function (require, exports) { //// [t2.js] define(["require", "exports"], function (require, exports) { exports.default = "hello"; - function foo() { - } + function foo() { } exports.foo = foo; }); //// [t3.js] diff --git a/tests/baselines/reference/exportStar.js b/tests/baselines/reference/exportStar.js index 9fca12af8b..d219a3650e 100644 --- a/tests/baselines/reference/exportStar.js +++ b/tests/baselines/reference/exportStar.js @@ -34,8 +34,7 @@ exports.x = 1; exports.y = 2; //// [t2.js] exports.default = "hello"; -function foo() { -} +function foo() { } exports.foo = foo; //// [t3.js] var x = "x"; diff --git a/tests/baselines/reference/exportedVariable1.js b/tests/baselines/reference/exportedVariable1.js index d1039e0db4..39eea8d34b 100644 --- a/tests/baselines/reference/exportedVariable1.js +++ b/tests/baselines/reference/exportedVariable1.js @@ -5,8 +5,6 @@ var upper = foo.name.toUpperCase(); //// [exportedVariable1.js] define(["require", "exports"], function (require, exports) { - exports.foo = { - name: "Bill" - }; + exports.foo = { name: "Bill" }; var upper = exports.foo.name.toUpperCase(); }); diff --git a/tests/baselines/reference/exportsAndImports1-amd.js b/tests/baselines/reference/exportsAndImports1-amd.js index 99c6fe8d43..fdc6d396ba 100644 --- a/tests/baselines/reference/exportsAndImports1-amd.js +++ b/tests/baselines/reference/exportsAndImports1-amd.js @@ -38,8 +38,7 @@ export { v, f, C, I, E, D, M, N, T, a }; define(["require", "exports"], function (require, exports) { var v = 1; exports.v = v; - function f() { - } + function f() { } exports.f = f; var C = (function () { function C() { diff --git a/tests/baselines/reference/exportsAndImports1.js b/tests/baselines/reference/exportsAndImports1.js index f381e6b724..87cb9e0fe1 100644 --- a/tests/baselines/reference/exportsAndImports1.js +++ b/tests/baselines/reference/exportsAndImports1.js @@ -37,8 +37,7 @@ export { v, f, C, I, E, D, M, N, T, a }; //// [t1.js] var v = 1; exports.v = v; -function f() { -} +function f() { } exports.f = f; var C = (function () { function C() { diff --git a/tests/baselines/reference/exportsAndImports3-amd.js b/tests/baselines/reference/exportsAndImports3-amd.js index 613598cc0e..f72d063e09 100644 --- a/tests/baselines/reference/exportsAndImports3-amd.js +++ b/tests/baselines/reference/exportsAndImports3-amd.js @@ -38,8 +38,7 @@ export { v, f, C, I, E, D, M, N, T, a }; define(["require", "exports"], function (require, exports) { exports.v = 1; exports.v1 = exports.v; - function f() { - } + function f() { } exports.f = f; exports.f1 = exports.f; var C = (function () { diff --git a/tests/baselines/reference/exportsAndImports3.js b/tests/baselines/reference/exportsAndImports3.js index f06a6f684d..56baead64c 100644 --- a/tests/baselines/reference/exportsAndImports3.js +++ b/tests/baselines/reference/exportsAndImports3.js @@ -37,8 +37,7 @@ export { v, f, C, I, E, D, M, N, T, a }; //// [t1.js] exports.v = 1; exports.v1 = exports.v; -function f() { -} +function f() { } exports.f = f; exports.f1 = exports.f; var C = (function () { diff --git a/tests/baselines/reference/extendAndImplementTheSameBaseType.js b/tests/baselines/reference/extendAndImplementTheSameBaseType.js index 836db4dc36..23c9127175 100644 --- a/tests/baselines/reference/extendAndImplementTheSameBaseType.js +++ b/tests/baselines/reference/extendAndImplementTheSameBaseType.js @@ -23,8 +23,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.bar = function () { - }; + C.prototype.bar = function () { }; return C; })(); var D = (function (_super) { @@ -32,8 +31,7 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.baz = function () { - }; + D.prototype.baz = function () { }; return D; })(C); var c; diff --git a/tests/baselines/reference/extendAndImplementTheSameBaseType2.js b/tests/baselines/reference/extendAndImplementTheSameBaseType2.js index 8311f4d6ce..234cc59ff7 100644 --- a/tests/baselines/reference/extendAndImplementTheSameBaseType2.js +++ b/tests/baselines/reference/extendAndImplementTheSameBaseType2.js @@ -36,8 +36,7 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.baz = function () { - }; + D.prototype.baz = function () { }; return D; })(C); var d = new D(); diff --git a/tests/baselines/reference/extendArray.js b/tests/baselines/reference/extendArray.js index 7809aa6bb2..6d5c026220 100644 --- a/tests/baselines/reference/extendArray.js +++ b/tests/baselines/reference/extendArray.js @@ -24,12 +24,8 @@ arr.collect = function (fn) { //// [extendArray.js] -var a = [ - 1, - 2 -]; -a.forEach(function (v, i, a) { -}); +var a = [1, 2]; +a.forEach(function (v, i, a) { }); var arr = Array.prototype; arr.collect = function (fn) { var res = []; diff --git a/tests/baselines/reference/extendNonClassSymbol1.js b/tests/baselines/reference/extendNonClassSymbol1.js index 47a602aefa..26f0c776dd 100644 --- a/tests/baselines/reference/extendNonClassSymbol1.js +++ b/tests/baselines/reference/extendNonClassSymbol1.js @@ -13,8 +13,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); var x = A; diff --git a/tests/baselines/reference/extendsClauseAlreadySeen.js b/tests/baselines/reference/extendsClauseAlreadySeen.js index 5c328e3913..820a691096 100644 --- a/tests/baselines/reference/extendsClauseAlreadySeen.js +++ b/tests/baselines/reference/extendsClauseAlreadySeen.js @@ -23,7 +23,6 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.baz = function () { - }; + D.prototype.baz = function () { }; return D; })(C); diff --git a/tests/baselines/reference/extendsClauseAlreadySeen2.js b/tests/baselines/reference/extendsClauseAlreadySeen2.js index 3f3b704931..ad88446c4c 100644 --- a/tests/baselines/reference/extendsClauseAlreadySeen2.js +++ b/tests/baselines/reference/extendsClauseAlreadySeen2.js @@ -23,7 +23,6 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.baz = function () { - }; + D.prototype.baz = function () { }; return D; })(C); diff --git a/tests/baselines/reference/externModule.js b/tests/baselines/reference/externModule.js index 0dc3d8e84c..719b68451a 100644 --- a/tests/baselines/reference/externModule.js +++ b/tests/baselines/reference/externModule.js @@ -42,8 +42,7 @@ n=XDate.UTC(1964,2,1); //// [externModule.js] declare; module; -{ -} +{ } var XDate = (function () { function XDate() { } diff --git a/tests/baselines/reference/externalModuleImmutableBindings.js b/tests/baselines/reference/externalModuleImmutableBindings.js index 546b593fa7..ed9b4c00af 100644 --- a/tests/baselines/reference/externalModuleImmutableBindings.js +++ b/tests/baselines/reference/externalModuleImmutableBindings.js @@ -70,43 +70,35 @@ stuff[n]++; (stuff['x'])++; (stuff['blah'])++; (stuff[n])++; -for (stuff.x in []) { -} +for (stuff.x in []) { } for (var _i = 0, _a = []; _i < _a.length; _i++) { stuff.x = _a[_i]; } -for (stuff['x'] in []) { -} +for (stuff['x'] in []) { } for (var _b = 0, _c = []; _b < _c.length; _b++) { stuff['x'] = _c[_b]; } -for (stuff.blah in []) { -} +for (stuff.blah in []) { } for (var _d = 0, _e = []; _d < _e.length; _d++) { stuff.blah = _e[_d]; } -for (stuff[n] in []) { -} +for (stuff[n] in []) { } for (var _f = 0, _g = []; _f < _g.length; _f++) { stuff[n] = _g[_f]; } -for ((stuff.x) in []) { -} +for ((stuff.x) in []) { } for (var _h = 0, _j = []; _h < _j.length; _h++) { (stuff.x) = _j[_h]; } -for ((stuff['x']) in []) { -} +for ((stuff['x']) in []) { } for (var _k = 0, _l = []; _k < _l.length; _k++) { (stuff['x']) = _l[_k]; } -for ((stuff.blah) in []) { -} +for ((stuff.blah) in []) { } for (var _m = 0, _o = []; _m < _o.length; _m++) { (stuff.blah) = _o[_m]; } -for ((stuff[n]) in []) { -} +for ((stuff[n]) in []) { } for (var _p = 0, _q = []; _p < _q.length; _p++) { (stuff[n]) = _q[_p]; } diff --git a/tests/baselines/reference/externalModuleReferenceOfImportDeclarationWithExportModifier.js b/tests/baselines/reference/externalModuleReferenceOfImportDeclarationWithExportModifier.js index 73ef9b6b29..f9c83c83cf 100644 --- a/tests/baselines/reference/externalModuleReferenceOfImportDeclarationWithExportModifier.js +++ b/tests/baselines/reference/externalModuleReferenceOfImportDeclarationWithExportModifier.js @@ -10,8 +10,7 @@ file1.foo(); //// [externalModuleReferenceOfImportDeclarationWithExportModifier_0.js] define(["require", "exports"], function (require, exports) { - function foo() { - } + function foo() { } exports.foo = foo; ; }); diff --git a/tests/baselines/reference/externalModuleRefernceResolutionOrderInImportDeclaration.js b/tests/baselines/reference/externalModuleRefernceResolutionOrderInImportDeclaration.js index edbdf6b90a..f1d1d9fb56 100644 --- a/tests/baselines/reference/externalModuleRefernceResolutionOrderInImportDeclaration.js +++ b/tests/baselines/reference/externalModuleRefernceResolutionOrderInImportDeclaration.js @@ -19,8 +19,7 @@ file1.bar(); //// [externalModuleRefernceResolutionOrderInImportDeclaration_file2.js] //// [externalModuleRefernceResolutionOrderInImportDeclaration_file1.js] -function foo() { -} +function foo() { } exports.foo = foo; ; //// [externalModuleRefernceResolutionOrderInImportDeclaration_file3.js] diff --git a/tests/baselines/reference/fatArrowfunctionAsType.js b/tests/baselines/reference/fatArrowfunctionAsType.js index bd2dc4310d..894267580c 100644 --- a/tests/baselines/reference/fatArrowfunctionAsType.js +++ b/tests/baselines/reference/fatArrowfunctionAsType.js @@ -7,7 +7,5 @@ b = c; //// [fatArrowfunctionAsType.js] -var c = function (x) { - return 42; -}; +var c = function (x) { return 42; }; b = c; diff --git a/tests/baselines/reference/fatarrowfunctions.js b/tests/baselines/reference/fatarrowfunctions.js index 1c74f39bed..eb57d1a981 100644 --- a/tests/baselines/reference/fatarrowfunctions.js +++ b/tests/baselines/reference/fatarrowfunctions.js @@ -49,70 +49,30 @@ var messenger = { function foo(x) { return x(); } -foo(function (x, y, z) { - return x + y + z; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function () { - return 0; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function (x, y, z) { - return x + y + z; -}); -foo(function () { - return 0; -}); -foo((function (x) { - return x; -})); -foo(function (x) { - return x * x; -}); -var y = function (x) { - return x * x; -}; -var z = function (x) { - return x * x; -}; -var w = function () { - return 3; -}; +foo(function (x, y, z) { return x + y + z; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function () { return 0; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function (x, y, z) { return x + y + z; }); +foo(function () { return 0; }); +foo((function (x) { return x; })); +foo(function (x) { return x * x; }); +var y = function (x) { return x * x; }; +var z = function (x) { return x * x; }; +var w = function () { return 3; }; function ternaryTest(isWhile) { - var f = isWhile ? function (n) { - return n > 0; - } : function (n) { - return n === 0; - }; + var f = isWhile ? function (n) { return n > 0; } : function (n) { return n === 0; }; } var messenger = { message: "Hello World", start: function () { var _this = this; - setTimeout(function () { - _this.message.toString(); - }, 3000); + setTimeout(function () { _this.message.toString(); }, 3000); } }; diff --git a/tests/baselines/reference/fatarrowfunctionsErrors.js b/tests/baselines/reference/fatarrowfunctionsErrors.js index 56fd91f3d1..2ac20f1966 100644 --- a/tests/baselines/reference/fatarrowfunctionsErrors.js +++ b/tests/baselines/reference/fatarrowfunctionsErrors.js @@ -20,28 +20,19 @@ foo(function () { } return 0; }); -foo((1), { - return: 0 -}); -foo(function (x) { - return x; -}); +foo((1), { return: 0 }); +foo(function (x) { return x; }); foo(function (x) { if (x === void 0) { x = 0; } return x; }); var y = x, number; x * x; -false ? (function () { - return null; -}) : null; +false ? (function () { return null; }) : null; // missing fatarrow -var x1 = function () { -}; -var x2 = function (a) { -}; -var x3 = function (a) { -}; +var x1 = function () { }; +var x2 = function (a) { }; +var x3 = function (a) { }; var x4 = function () { var a = []; for (var _i = 0; _i < arguments.length; _i++) { diff --git a/tests/baselines/reference/fatarrowfunctionsInFunctionParameterDefaults.js b/tests/baselines/reference/fatarrowfunctionsInFunctionParameterDefaults.js index e5c8134a4b..d73eec12bc 100644 --- a/tests/baselines/reference/fatarrowfunctionsInFunctionParameterDefaults.js +++ b/tests/baselines/reference/fatarrowfunctionsInFunctionParameterDefaults.js @@ -12,9 +12,7 @@ fn.call(4); // Should be 4 //// [fatarrowfunctionsInFunctionParameterDefaults.js] function fn(x, y) { var _this = this; - if (x === void 0) { x = function () { - return _this; - }; } + if (x === void 0) { x = function () { return _this; }; } if (y === void 0) { y = x(); } // should be 4 return y; diff --git a/tests/baselines/reference/fatarrowfunctionsOptionalArgs.js b/tests/baselines/reference/fatarrowfunctionsOptionalArgs.js index bdd8047716..e6e43f8bbf 100644 --- a/tests/baselines/reference/fatarrowfunctionsOptionalArgs.js +++ b/tests/baselines/reference/fatarrowfunctionsOptionalArgs.js @@ -134,39 +134,27 @@ foo( //// [fatarrowfunctionsOptionalArgs.js] // valid // no params -(function () { - return 1; -}); +(function () { return 1; }); // one param, no type -(function (arg) { - return 2; -}); +(function (arg) { return 2; }); // one param, no type -(function (arg) { - return 2; -}); +(function (arg) { return 2; }); // one param, no type with default value (function (arg) { if (arg === void 0) { arg = 1; } return 3; }); // one param, no type, optional -(function (arg) { - return 4; -}); +(function (arg) { return 4; }); // typed param -(function (arg) { - return 5; -}); +(function (arg) { return 5; }); // typed param with default value (function (arg) { if (arg === void 0) { arg = 0; } return 6; }); // optional param -(function (arg) { - return 7; -}); +(function (arg) { return 7; }); // var arg param (function () { var arg = []; @@ -176,28 +164,20 @@ foo( return 8; }); // multiple arguments -(function (arg1, arg2) { - return 12; -}); +(function (arg1, arg2) { return 12; }); (function (arg1, arg2) { if (arg1 === void 0) { arg1 = 1; } if (arg2 === void 0) { arg2 = 3; } return 13; }); -(function (arg1, arg2) { - return 14; -}); -(function (arg1, arg2) { - return 15; -}); +(function (arg1, arg2) { return 14; }); +(function (arg1, arg2) { return 15; }); (function (arg1, arg2) { if (arg1 === void 0) { arg1 = 0; } if (arg2 === void 0) { arg2 = 1; } return 16; }); -(function (arg1, arg2) { - return 17; -}); +(function (arg1, arg2) { return 17; }); (function (arg1) { var arg2 = []; for (var _i = 1; _i < arguments.length; _i++) { @@ -205,33 +185,21 @@ foo( } return 18; }); -(function (arg1, arg2) { - return 19; -}); +(function (arg1, arg2) { return 19; }); // in paren -(function () { - return 21; -}); -(function (arg) { - return 22; -}); +(function () { return 21; }); +(function (arg) { return 22; }); (function (arg) { if (arg === void 0) { arg = 1; } return 23; }); -(function (arg) { - return 24; -}); -(function (arg) { - return 25; -}); +(function (arg) { return 24; }); +(function (arg) { return 25; }); (function (arg) { if (arg === void 0) { arg = 0; } return 26; }); -(function (arg) { - return 27; -}); +(function (arg) { return 27; }); (function () { var arg = []; for (var _i = 0; _i < arguments.length; _i++) { @@ -240,29 +208,17 @@ foo( return 28; }); // in multiple paren -((((function (arg) { - return 32; -})))); +((((function (arg) { return 32; })))); // in ternary exression -false ? function () { - return 41; -} : null; -false ? function (arg) { - return 42; -} : null; +false ? function () { return 41; } : null; +false ? function (arg) { return 42; } : null; false ? function (arg) { if (arg === void 0) { arg = 1; } return 43; } : null; -false ? function (arg) { - return 44; -} : null; -false ? function (arg) { - return 45; -} : null; -false ? function (arg) { - return 46; -} : null; +false ? function (arg) { return 44; } : null; +false ? function (arg) { return 45; } : null; +false ? function (arg) { return 46; } : null; false ? function (arg) { if (arg === void 0) { arg = 0; } return 47; @@ -275,25 +231,15 @@ false ? function () { return 48; } : null; // in ternary exression within paren -false ? (function () { - return 51; -}) : null; -false ? (function (arg) { - return 52; -}) : null; +false ? (function () { return 51; }) : null; +false ? (function (arg) { return 52; }) : null; false ? (function (arg) { if (arg === void 0) { arg = 1; } return 53; }) : null; -false ? (function (arg) { - return 54; -}) : null; -false ? (function (arg) { - return 55; -}) : null; -false ? (function (arg) { - return 56; -}) : null; +false ? (function (arg) { return 54; }) : null; +false ? (function (arg) { return 55; }) : null; +false ? (function (arg) { return 56; }) : null; false ? (function (arg) { if (arg === void 0) { arg = 0; } return 57; @@ -306,25 +252,15 @@ false ? (function () { return 58; }) : null; // ternary exression's else clause -false ? null : function () { - return 61; -}; -false ? null : function (arg) { - return 62; -}; +false ? null : function () { return 61; }; +false ? null : function (arg) { return 62; }; false ? null : function (arg) { if (arg === void 0) { arg = 1; } return 63; }; -false ? null : function (arg) { - return 64; -}; -false ? null : function (arg) { - return 65; -}; -false ? null : function (arg) { - return 66; -}; +false ? null : function (arg) { return 64; }; +false ? null : function (arg) { return 65; }; +false ? null : function (arg) { return 66; }; false ? null : function (arg) { if (arg === void 0) { arg = 0; } return 67; @@ -337,48 +273,24 @@ false ? null : function () { return 68; }; // nested ternary expressions -(function (a) { - return a; -}) ? function (b) { - return b; -} : function (c) { - return c; -}; +(function (a) { return a; }) ? function (b) { return b; } : function (c) { return c; }; //multiple levels -(function (a) { - return a; -}); -(function (b) { - return function (c) { - return 81; - }; -}); -(function (c) { - return function (d) { - return 82; - }; -}); +(function (a) { return a; }); +(function (b) { return function (c) { return 81; }; }); +(function (c) { return function (d) { return 82; }; }); // In Expressions -(function (arg) { - return 90; -}) instanceof Function; +(function (arg) { return 90; }) instanceof Function; (function (arg) { if (arg === void 0) { arg = 1; } return 91; }) instanceof Function; -(function (arg) { - return 92; -}) instanceof Function; -(function (arg) { - return 93; -}) instanceof Function; +(function (arg) { return 92; }) instanceof Function; +(function (arg) { return 93; }) instanceof Function; (function (arg) { if (arg === void 0) { arg = 1; } return 94; }) instanceof Function; -(function (arg) { - return 95; -}) instanceof Function; +(function (arg) { return 95; }) instanceof Function; (function () { var arg = []; for (var _i = 0; _i < arguments.length; _i++) { @@ -386,14 +298,8 @@ false ? null : function () { } return 96; }) instanceof Function; -'' + (function (arg) { - return 100; -}); -(function (arg) { - return 0; -}) + '' + (function (arg) { - return 101; -}); +'' + (function (arg) { return 100; }); +(function (arg) { return 0; }) + '' + (function (arg) { return 101; }); (function (arg) { if (arg === void 0) { arg = 1; } return 0; @@ -401,16 +307,8 @@ false ? null : function () { if (arg === void 0) { arg = 2; } return 102; }); -(function (arg) { - return 0; -}) + '' + (function (arg) { - return 103; -}); -(function (arg) { - return 0; -}) + '' + (function (arg) { - return 104; -}); +(function (arg) { return 0; }) + '' + (function (arg) { return 103; }); +(function (arg) { return 0; }) + '' + (function (arg) { return 104; }); (function (arg) { if (arg === void 0) { arg = 1; } return 0; @@ -438,11 +336,7 @@ false ? null : function () { } return 107; }); -(function (arg1, arg2) { - return 0; -}) + '' + (function (arg1, arg2) { - return 108; -}); +(function (arg1, arg2) { return 0; }) + '' + (function (arg1, arg2) { return 108; }); (function (arg1) { var arg2 = []; for (var _i = 1; _i < arguments.length; _i++) { @@ -463,19 +357,9 @@ function foo() { arg[_i - 0] = arguments[_i]; } } -foo(function (a) { - return 110; -}, (function (a) { - return 111; -}), function (a) { +foo(function (a) { return 110; }, (function (a) { return 111; }), function (a) { return 112; -}, function (a) { - return 113; -}, function (a, b) { - return 114; -}, function (a) { - return 115; -}, function (a) { +}, function (a) { return 113; }, function (a, b) { return 114; }, function (a) { return 115; }, function (a) { if (a === void 0) { a = 0; } return 116; }, function (a) { @@ -497,14 +381,4 @@ foo(function (a) { c[_i - 2] = arguments[_i]; } return 120; -}, function (a) { - return function (b) { - return function (c) { - return 121; - }; - }; -}, false ? function (a) { - return 0; -} : function (b) { - return 122; -}); +}, function (a) { return function (b) { return function (c) { return 121; }; }; }, false ? function (a) { return 0; } : function (b) { return 122; }); diff --git a/tests/baselines/reference/fatarrowfunctionsOptionalArgsErrors1.js b/tests/baselines/reference/fatarrowfunctionsOptionalArgsErrors1.js index 0ee54452a9..428a085ca5 100644 --- a/tests/baselines/reference/fatarrowfunctionsOptionalArgsErrors1.js +++ b/tests/baselines/reference/fatarrowfunctionsOptionalArgsErrors1.js @@ -8,9 +8,7 @@ (arg1 = 1, arg2) => 1; //// [fatarrowfunctionsOptionalArgsErrors1.js] -(function (arg1, arg2) { - return 101; -}); +(function (arg1, arg2) { return 101; }); (function () { var arg = []; for (var _i = 0; _i < arguments.length; _i++) { diff --git a/tests/baselines/reference/fatarrowfunctionsOptionalArgsErrors4.js b/tests/baselines/reference/fatarrowfunctionsOptionalArgsErrors4.js index e662808106..dfd7e9f74d 100644 --- a/tests/baselines/reference/fatarrowfunctionsOptionalArgsErrors4.js +++ b/tests/baselines/reference/fatarrowfunctionsOptionalArgsErrors4.js @@ -42,19 +42,9 @@ false ? null : function (arg) { if (arg === void 0) { arg = 2; } return 106; }); -foo(function (a) { - return 110; -}, (function (a) { - return 111; -}), function (a) { +foo(function (a) { return 110; }, (function (a) { return 111; }), function (a) { return 112; -}, function (a) { - return 113; -}, function (a, b) { - return 114; -}, function (a) { - return 115; -}, function (a) { +}, function (a) { return 113; }, function (a, b) { return 114; }, function (a) { return 115; }, function (a) { if (a === void 0) { a = 0; } return 116; }, function (a) { @@ -76,14 +66,4 @@ foo(function (a) { c[_i - 2] = arguments[_i]; } return 120; -}, function (a) { - return function (b) { - return function (c) { - return 121; - }; - }; -}, false ? function (a) { - return 0; -} : function (b) { - return 122; -}); +}, function (a) { return function (b) { return function (c) { return 121; }; }; }, false ? function (a) { return 0; } : function (b) { return 122; }); diff --git a/tests/baselines/reference/fieldAndGetterWithSameName.js b/tests/baselines/reference/fieldAndGetterWithSameName.js index 64129ff936..ddd95b9e8f 100644 --- a/tests/baselines/reference/fieldAndGetterWithSameName.js +++ b/tests/baselines/reference/fieldAndGetterWithSameName.js @@ -10,9 +10,7 @@ define(["require", "exports"], function (require, exports) { function C() { } Object.defineProperty(C.prototype, "x", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/fixTypeParameterInSignatureWithRestParameters.js b/tests/baselines/reference/fixTypeParameterInSignatureWithRestParameters.js index d8521e56a1..dea003057c 100644 --- a/tests/baselines/reference/fixTypeParameterInSignatureWithRestParameters.js +++ b/tests/baselines/reference/fixTypeParameterInSignatureWithRestParameters.js @@ -3,6 +3,5 @@ function bar(item1: T, item2: T) { } bar(1, ""); // Should be ok //// [fixTypeParameterInSignatureWithRestParameters.js] -function bar(item1, item2) { -} +function bar(item1, item2) { } bar(1, ""); // Should be ok diff --git a/tests/baselines/reference/for-inStatements.js b/tests/baselines/reference/for-inStatements.js index 3787887923..3db07d878b 100644 --- a/tests/baselines/reference/for-inStatements.js +++ b/tests/baselines/reference/for-inStatements.js @@ -88,71 +88,38 @@ var __extends = this.__extends || function (d, b) { d.prototype = new __(); }; var aString; -for (aString in {}) { -} +for (aString in {}) { } var anAny; -for (anAny in {}) { -} -for (var x in {}) { -} -for (var x in []) { -} -for (var x in [ - 1, - 2, - 3, - 4, - 5 -]) { -} -function fn() { -} -for (var x in fn()) { -} -for (var x in /[a-z]/) { -} -for (var x in new Date()) { -} +for (anAny in {}) { } +for (var x in {}) { } +for (var x in []) { } +for (var x in [1, 2, 3, 4, 5]) { } +function fn() { } +for (var x in fn()) { } +for (var x in /[a-z]/) { } +for (var x in new Date()) { } var c, d, e; -for (var x in c || d) { -} -for (var x in e ? c : d) { -} -for (var x in 42 ? c : d) { -} -for (var x in '' ? c : d) { -} -for (var x in 42 ? d[x] : c[x]) { -} -for (var x in c[d]) { -} -for (var x in (function (x) { - return x; -})) { -} -for (var x in function (x, y) { - return x + y; -}) { -} +for (var x in c || d) { } +for (var x in e ? c : d) { } +for (var x in 42 ? c : d) { } +for (var x in '' ? c : d) { } +for (var x in 42 ? d[x] : c[x]) { } +for (var x in c[d]) { } +for (var x in (function (x) { return x; })) { } +for (var x in function (x, y) { return x + y; }) { } var A = (function () { function A() { } A.prototype.biz = function () { - for (var x in this.biz()) { - } - for (var x in this.biz) { - } - for (var x in this) { - } + for (var x in this.biz()) { } + for (var x in this.biz) { } + for (var x in this) { } return null; }; A.baz = function () { - for (var x in this) { - } - for (var x in this.baz) { - } - for (var x in this.baz()) { - } + for (var x in this) { } + for (var x in this.baz) { } + for (var x in this.baz()) { } return null; }; return A; @@ -163,23 +130,17 @@ var B = (function (_super) { _super.apply(this, arguments); } B.prototype.boz = function () { - for (var x in this.biz()) { - } - for (var x in this.biz) { - } - for (var x in this) { - } - for (var x in _super.prototype.biz) { - } - for (var x in _super.prototype.biz.call(this)) { - } + for (var x in this.biz()) { } + for (var x in this.biz) { } + for (var x in this) { } + for (var x in _super.prototype.biz) { } + for (var x in _super.prototype.biz.call(this)) { } return null; }; return B; })(A); var i; -for (var x in i[42]) { -} +for (var x in i[42]) { } var M; (function (M) { var X = (function () { @@ -189,16 +150,12 @@ var M; })(); M.X = X; })(M || (M = {})); -for (var x in M) { -} -for (var x in M.X) { -} +for (var x in M) { } +for (var x in M.X) { } var Color; (function (Color) { Color[Color["Red"] = 0] = "Red"; Color[Color["Blue"] = 1] = "Blue"; })(Color || (Color = {})); -for (var x in Color) { -} -for (var x in Color.Blue) { -} +for (var x in Color) { } +for (var x in Color.Blue) { } diff --git a/tests/baselines/reference/for-inStatementsDestructuring.js b/tests/baselines/reference/for-inStatementsDestructuring.js index 25a696f9fc..e5e00d5b3a 100644 --- a/tests/baselines/reference/for-inStatementsDestructuring.js +++ b/tests/baselines/reference/for-inStatementsDestructuring.js @@ -2,5 +2,4 @@ for (var [a, b] in []) {} //// [for-inStatementsDestructuring.js] -for (var _a = void 0, a = _a[0], b = _a[1] in []) { -} +for (var _a = void 0, a = _a[0], b = _a[1] in []) { } diff --git a/tests/baselines/reference/for-inStatementsDestructuring2.js b/tests/baselines/reference/for-inStatementsDestructuring2.js index 7051a5a058..41a6d30919 100644 --- a/tests/baselines/reference/for-inStatementsDestructuring2.js +++ b/tests/baselines/reference/for-inStatementsDestructuring2.js @@ -2,5 +2,4 @@ for (var {a, b} in []) {} //// [for-inStatementsDestructuring2.js] -for (var _a = void 0, a = _a.a, b = _a.b in []) { -} +for (var _a = void 0, a = _a.a, b = _a.b in []) { } diff --git a/tests/baselines/reference/for-inStatementsDestructuring3.js b/tests/baselines/reference/for-inStatementsDestructuring3.js index 2784e48708..0970740aca 100644 --- a/tests/baselines/reference/for-inStatementsDestructuring3.js +++ b/tests/baselines/reference/for-inStatementsDestructuring3.js @@ -4,8 +4,4 @@ for ([a, b] in []) { } //// [for-inStatementsDestructuring3.js] var a, b; -for ([ - a, - b -] in []) { -} +for ([a, b] in []) { } diff --git a/tests/baselines/reference/for-inStatementsDestructuring4.js b/tests/baselines/reference/for-inStatementsDestructuring4.js index 6eb5696024..0cce61ac96 100644 --- a/tests/baselines/reference/for-inStatementsDestructuring4.js +++ b/tests/baselines/reference/for-inStatementsDestructuring4.js @@ -4,8 +4,4 @@ for ({a, b} in []) { } //// [for-inStatementsDestructuring4.js] var a, b; -for ({ - a: a, - b: b -} in []) { -} +for ({ a: a, b: b } in []) { } diff --git a/tests/baselines/reference/for-inStatementsInvalid.js b/tests/baselines/reference/for-inStatementsInvalid.js index a485c8ba7c..6d42a550a0 100644 --- a/tests/baselines/reference/for-inStatementsInvalid.js +++ b/tests/baselines/reference/for-inStatementsInvalid.js @@ -71,60 +71,36 @@ var __extends = this.__extends || function (d, b) { d.prototype = new __(); }; var aNumber; -for (aNumber in {}) { -} +for (aNumber in {}) { } var aBoolean; -for (aBoolean in {}) { -} +for (aBoolean in {}) { } var aRegExp; -for (aRegExp in {}) { -} -for (var idx in {}) { -} -function fn() { -} -for (var x in fn()) { -} +for (aRegExp in {}) { } +for (var idx in {}) { } +function fn() { } +for (var x in fn()) { } var c, d, e; -for (var x in c || d) { -} -for (var x in e ? c : d) { -} -for (var x in 42 ? c : d) { -} -for (var x in '' ? c : d) { -} -for (var x in 42 ? d[x] : c[x]) { -} -for (var x in c[23]) { -} -for (var x in (function (x) { - return x; -})) { -} -for (var x in function (x, y) { - return x + y; -}) { -} +for (var x in c || d) { } +for (var x in e ? c : d) { } +for (var x in 42 ? c : d) { } +for (var x in '' ? c : d) { } +for (var x in 42 ? d[x] : c[x]) { } +for (var x in c[23]) { } +for (var x in (function (x) { return x; })) { } +for (var x in function (x, y) { return x + y; }) { } var A = (function () { function A() { } A.prototype.biz = function () { - for (var x in this.biz()) { - } - for (var x in this.biz) { - } - for (var x in this) { - } + for (var x in this.biz()) { } + for (var x in this.biz) { } + for (var x in this) { } return null; }; A.baz = function () { - for (var x in this) { - } - for (var x in this.baz) { - } - for (var x in this.baz()) { - } + for (var x in this) { } + for (var x in this.baz) { } + for (var x in this.baz()) { } return null; }; return A; @@ -135,20 +111,14 @@ var B = (function (_super) { _super.apply(this, arguments); } B.prototype.boz = function () { - for (var x in this.biz()) { - } - for (var x in this.biz) { - } - for (var x in this) { - } - for (var x in _super.prototype.biz) { - } - for (var x in _super.prototype.biz.call(this)) { - } + for (var x in this.biz()) { } + for (var x in this.biz) { } + for (var x in this) { } + for (var x in _super.prototype.biz) { } + for (var x in _super.prototype.biz.call(this)) { } return null; }; return B; })(A); var i; -for (var x in i[42]) { -} +for (var x in i[42]) { } diff --git a/tests/baselines/reference/for-of1.js b/tests/baselines/reference/for-of1.js index fb74d6eced..9df6a96d78 100644 --- a/tests/baselines/reference/for-of1.js +++ b/tests/baselines/reference/for-of1.js @@ -4,5 +4,4 @@ for (v of []) { } //// [for-of1.js] var v; -for (v of []) { -} +for (v of []) { } diff --git a/tests/baselines/reference/for-of10.js b/tests/baselines/reference/for-of10.js index 3b01719417..7fd05f5479 100644 --- a/tests/baselines/reference/for-of10.js +++ b/tests/baselines/reference/for-of10.js @@ -4,7 +4,4 @@ for (v of [0]) { } //// [for-of10.js] var v; -for (v of [ - 0 -]) { -} +for (v of [0]) { } diff --git a/tests/baselines/reference/for-of11.js b/tests/baselines/reference/for-of11.js index 58486c477e..055ed0039d 100644 --- a/tests/baselines/reference/for-of11.js +++ b/tests/baselines/reference/for-of11.js @@ -4,8 +4,4 @@ for (v of [0, ""]) { } //// [for-of11.js] var v; -for (v of [ - 0, - "" -]) { -} +for (v of [0, ""]) { } diff --git a/tests/baselines/reference/for-of12.js b/tests/baselines/reference/for-of12.js index f489eaa40f..6185ca8e33 100644 --- a/tests/baselines/reference/for-of12.js +++ b/tests/baselines/reference/for-of12.js @@ -4,8 +4,4 @@ for (v of [0, ""].values()) { } //// [for-of12.js] var v; -for (v of [ - 0, - "" -].values()) { -} +for (v of [0, ""].values()) { } diff --git a/tests/baselines/reference/for-of13.js b/tests/baselines/reference/for-of13.js index 87d908b42b..e66668f173 100644 --- a/tests/baselines/reference/for-of13.js +++ b/tests/baselines/reference/for-of13.js @@ -4,7 +4,4 @@ for (v of [""].values()) { } //// [for-of13.js] var v; -for (v of [ - "" -].values()) { -} +for (v of [""].values()) { } diff --git a/tests/baselines/reference/for-of14.js b/tests/baselines/reference/for-of14.js index 958e621c8a..42832f8e58 100644 --- a/tests/baselines/reference/for-of14.js +++ b/tests/baselines/reference/for-of14.js @@ -10,8 +10,7 @@ class StringIterator { //// [for-of14.js] var v; -for (v of new StringIterator) { -} // Should fail because the iterator is not iterable +for (v of new StringIterator) { } // Should fail because the iterator is not iterable class StringIterator { next() { return ""; diff --git a/tests/baselines/reference/for-of15.js b/tests/baselines/reference/for-of15.js index 2b4846ec8b..62232745c8 100644 --- a/tests/baselines/reference/for-of15.js +++ b/tests/baselines/reference/for-of15.js @@ -13,8 +13,7 @@ class StringIterator { //// [for-of15.js] var v; -for (v of new StringIterator) { -} // Should fail +for (v of new StringIterator) { } // Should fail class StringIterator { next() { return ""; diff --git a/tests/baselines/reference/for-of16.js b/tests/baselines/reference/for-of16.js index 1cdf72c26a..974be239fd 100644 --- a/tests/baselines/reference/for-of16.js +++ b/tests/baselines/reference/for-of16.js @@ -10,8 +10,7 @@ class StringIterator { //// [for-of16.js] var v; -for (v of new StringIterator) { -} // Should fail +for (v of new StringIterator) { } // Should fail class StringIterator { [Symbol.iterator]() { return this; diff --git a/tests/baselines/reference/for-of17.js b/tests/baselines/reference/for-of17.js index 3fb4fac91d..a392764700 100644 --- a/tests/baselines/reference/for-of17.js +++ b/tests/baselines/reference/for-of17.js @@ -16,8 +16,7 @@ class NumberIterator { //// [for-of17.js] var v; -for (v of new NumberIterator) { -} // Should succeed +for (v of new NumberIterator) { } // Should succeed class NumberIterator { next() { return { diff --git a/tests/baselines/reference/for-of18.js b/tests/baselines/reference/for-of18.js index ae3a9e130f..c31e6b6e8c 100644 --- a/tests/baselines/reference/for-of18.js +++ b/tests/baselines/reference/for-of18.js @@ -16,8 +16,7 @@ class StringIterator { //// [for-of18.js] var v; -for (v of new StringIterator) { -} // Should succeed +for (v of new StringIterator) { } // Should succeed class StringIterator { next() { return { diff --git a/tests/baselines/reference/for-of2.js b/tests/baselines/reference/for-of2.js index 49d3f76746..d7eceb7c49 100644 --- a/tests/baselines/reference/for-of2.js +++ b/tests/baselines/reference/for-of2.js @@ -4,5 +4,4 @@ for (v of []) { } //// [for-of2.js] const v; -for (v of []) { -} +for (v of []) { } diff --git a/tests/baselines/reference/for-of24.js b/tests/baselines/reference/for-of24.js index bb605011ef..b491851960 100644 --- a/tests/baselines/reference/for-of24.js +++ b/tests/baselines/reference/for-of24.js @@ -5,5 +5,4 @@ for (var v of x) { } //// [for-of24.js] var x; -for (var v of x) { -} +for (var v of x) { } diff --git a/tests/baselines/reference/for-of25.js b/tests/baselines/reference/for-of25.js index 2c85a4dc2f..5715f6e8a3 100644 --- a/tests/baselines/reference/for-of25.js +++ b/tests/baselines/reference/for-of25.js @@ -10,8 +10,7 @@ class StringIterator { //// [for-of25.js] var x; -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { [Symbol.iterator]() { return x; diff --git a/tests/baselines/reference/for-of26.js b/tests/baselines/reference/for-of26.js index e048caf100..33319f50ef 100644 --- a/tests/baselines/reference/for-of26.js +++ b/tests/baselines/reference/for-of26.js @@ -13,8 +13,7 @@ class StringIterator { //// [for-of26.js] var x; -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { next() { return x; diff --git a/tests/baselines/reference/for-of27.js b/tests/baselines/reference/for-of27.js index 8b44ca03ef..1ac3a1dfc4 100644 --- a/tests/baselines/reference/for-of27.js +++ b/tests/baselines/reference/for-of27.js @@ -6,7 +6,6 @@ class StringIterator { } //// [for-of27.js] -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { } diff --git a/tests/baselines/reference/for-of28.js b/tests/baselines/reference/for-of28.js index 69c8ccab72..78e8677481 100644 --- a/tests/baselines/reference/for-of28.js +++ b/tests/baselines/reference/for-of28.js @@ -9,8 +9,7 @@ class StringIterator { } //// [for-of28.js] -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { [Symbol.iterator]() { return this; diff --git a/tests/baselines/reference/for-of29.js b/tests/baselines/reference/for-of29.js index c369731bee..450cafbde8 100644 --- a/tests/baselines/reference/for-of29.js +++ b/tests/baselines/reference/for-of29.js @@ -8,5 +8,4 @@ for (var v of iterableWithOptionalIterator) { } //// [for-of29.js] var iterableWithOptionalIterator; -for (var v of iterableWithOptionalIterator) { -} +for (var v of iterableWithOptionalIterator) { } diff --git a/tests/baselines/reference/for-of3.js b/tests/baselines/reference/for-of3.js index f47802dac6..7ef2718770 100644 --- a/tests/baselines/reference/for-of3.js +++ b/tests/baselines/reference/for-of3.js @@ -4,5 +4,4 @@ for (v++ of []) { } //// [for-of3.js] var v; -for (v++ of []) { -} +for (v++ of []) { } diff --git a/tests/baselines/reference/for-of30.js b/tests/baselines/reference/for-of30.js index 0ed6caaf81..37316774c9 100644 --- a/tests/baselines/reference/for-of30.js +++ b/tests/baselines/reference/for-of30.js @@ -17,8 +17,7 @@ class StringIterator { } //// [for-of30.js] -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { constructor() { this.return = 0; diff --git a/tests/baselines/reference/for-of31.js b/tests/baselines/reference/for-of31.js index d38c1fa017..a92e827b91 100644 --- a/tests/baselines/reference/for-of31.js +++ b/tests/baselines/reference/for-of31.js @@ -15,8 +15,7 @@ class StringIterator { } //// [for-of31.js] -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { next() { return { diff --git a/tests/baselines/reference/for-of32.js b/tests/baselines/reference/for-of32.js index bce2097e3c..d25d16fbeb 100644 --- a/tests/baselines/reference/for-of32.js +++ b/tests/baselines/reference/for-of32.js @@ -2,5 +2,4 @@ for (var v of v) { } //// [for-of32.js] -for (var v of v) { -} +for (var v of v) { } diff --git a/tests/baselines/reference/for-of33.js b/tests/baselines/reference/for-of33.js index 66097f777c..b63aeedf77 100644 --- a/tests/baselines/reference/for-of33.js +++ b/tests/baselines/reference/for-of33.js @@ -8,8 +8,7 @@ class StringIterator { } //// [for-of33.js] -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { [Symbol.iterator]() { return v; diff --git a/tests/baselines/reference/for-of34.js b/tests/baselines/reference/for-of34.js index 568a9f7353..f61f04ea95 100644 --- a/tests/baselines/reference/for-of34.js +++ b/tests/baselines/reference/for-of34.js @@ -12,8 +12,7 @@ class StringIterator { } //// [for-of34.js] -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { next() { return v; diff --git a/tests/baselines/reference/for-of35.js b/tests/baselines/reference/for-of35.js index a157d5e2e8..c7d7c5890d 100644 --- a/tests/baselines/reference/for-of35.js +++ b/tests/baselines/reference/for-of35.js @@ -15,8 +15,7 @@ class StringIterator { } //// [for-of35.js] -for (var v of new StringIterator) { -} +for (var v of new StringIterator) { } class StringIterator { next() { return { diff --git a/tests/baselines/reference/for-of36.js b/tests/baselines/reference/for-of36.js index fb70b1d60c..1452369515 100644 --- a/tests/baselines/reference/for-of36.js +++ b/tests/baselines/reference/for-of36.js @@ -5,10 +5,7 @@ for (var v of tuple) { } //// [for-of36.js] -var tuple = [ - "", - true -]; +var tuple = ["", true]; for (var v of tuple) { v; } diff --git a/tests/baselines/reference/for-of37.js b/tests/baselines/reference/for-of37.js index cada43a632..472193e6cb 100644 --- a/tests/baselines/reference/for-of37.js +++ b/tests/baselines/reference/for-of37.js @@ -5,12 +5,7 @@ for (var v of map) { } //// [for-of37.js] -var map = new Map([ - [ - "", - true - ] -]); +var map = new Map([["", true]]); for (var v of map) { v; } diff --git a/tests/baselines/reference/for-of38.js b/tests/baselines/reference/for-of38.js index 48b697f906..1f0ac09682 100644 --- a/tests/baselines/reference/for-of38.js +++ b/tests/baselines/reference/for-of38.js @@ -6,12 +6,7 @@ for (var [k, v] of map) { } //// [for-of38.js] -var map = new Map([ - [ - "", - true - ] -]); +var map = new Map([["", true]]); for (var [k, v] of map) { k; v; diff --git a/tests/baselines/reference/for-of39.js b/tests/baselines/reference/for-of39.js index 3b7d8d9a56..91dbc56c0a 100644 --- a/tests/baselines/reference/for-of39.js +++ b/tests/baselines/reference/for-of39.js @@ -6,16 +6,7 @@ for (var [k, v] of map) { } //// [for-of39.js] -var map = new Map([ - [ - "", - true - ], - [ - "", - 0 - ] -]); +var map = new Map([["", true], ["", 0]]); for (var [k, v] of map) { k; v; diff --git a/tests/baselines/reference/for-of4.js b/tests/baselines/reference/for-of4.js index 03cef92c1f..147619d2fe 100644 --- a/tests/baselines/reference/for-of4.js +++ b/tests/baselines/reference/for-of4.js @@ -4,8 +4,6 @@ for (var v of [0]) { } //// [for-of4.js] -for (var v of [ - 0 -]) { +for (var v of [0]) { v; } diff --git a/tests/baselines/reference/for-of40.js b/tests/baselines/reference/for-of40.js index 06fc45adfa..243f81097d 100644 --- a/tests/baselines/reference/for-of40.js +++ b/tests/baselines/reference/for-of40.js @@ -6,12 +6,7 @@ for (var [k = "", v = false] of map) { } //// [for-of40.js] -var map = new Map([ - [ - "", - true - ] -]); +var map = new Map([["", true]]); for (var [k = "", v = false] of map) { k; v; diff --git a/tests/baselines/reference/for-of41.js b/tests/baselines/reference/for-of41.js index f3ae215c5b..0fa380c53c 100644 --- a/tests/baselines/reference/for-of41.js +++ b/tests/baselines/reference/for-of41.js @@ -6,16 +6,7 @@ for (var {x: [a], y: {p}} of array) { } //// [for-of41.js] -var array = [ - { - x: [ - 0 - ], - y: { - p: "" - } - } -]; +var array = [{ x: [0], y: { p: "" } }]; for (var { x: [a], y: { p } } of array) { a; p; diff --git a/tests/baselines/reference/for-of42.js b/tests/baselines/reference/for-of42.js index 774ce512e9..1fa9219df4 100644 --- a/tests/baselines/reference/for-of42.js +++ b/tests/baselines/reference/for-of42.js @@ -6,12 +6,7 @@ for (var {x: a, y: b} of array) { } //// [for-of42.js] -var array = [ - { - x: "", - y: 0 - } -]; +var array = [{ x: "", y: 0 }]; for (var { x: a, y: b } of array) { a; b; diff --git a/tests/baselines/reference/for-of43.js b/tests/baselines/reference/for-of43.js index dc8c9c885d..de3b4fcd9b 100644 --- a/tests/baselines/reference/for-of43.js +++ b/tests/baselines/reference/for-of43.js @@ -6,12 +6,7 @@ for (var {x: a = "", y: b = true} of array) { } //// [for-of43.js] -var array = [ - { - x: "", - y: 0 - } -]; +var array = [{ x: "", y: 0 }]; for (var { x: a = "", y: b = true } of array) { a; b; diff --git a/tests/baselines/reference/for-of44.js b/tests/baselines/reference/for-of44.js index 9d4745d136..087485ed73 100644 --- a/tests/baselines/reference/for-of44.js +++ b/tests/baselines/reference/for-of44.js @@ -6,20 +6,7 @@ for (var [num, strBoolSym] of array) { } //// [for-of44.js] -var array = [ - [ - 0, - "" - ], - [ - 0, - true - ], - [ - 1, - Symbol() - ] -]; +var array = [[0, ""], [0, true], [1, Symbol()]]; for (var [num, strBoolSym] of array) { num; strBoolSym; diff --git a/tests/baselines/reference/for-of45.js b/tests/baselines/reference/for-of45.js index 3394c50c21..1222b2dcdd 100644 --- a/tests/baselines/reference/for-of45.js +++ b/tests/baselines/reference/for-of45.js @@ -8,16 +8,8 @@ for ([k = "", v = false] of map) { //// [for-of45.js] var k, v; -var map = new Map([ - [ - "", - true - ] -]); -for ([ - k = "", - v = false -] of map) { +var map = new Map([["", true]]); +for ([k = "", v = false] of map) { k; v; } diff --git a/tests/baselines/reference/for-of46.js b/tests/baselines/reference/for-of46.js index 7146993513..2ea15936c5 100644 --- a/tests/baselines/reference/for-of46.js +++ b/tests/baselines/reference/for-of46.js @@ -8,16 +8,8 @@ for ([k = false, v = ""] of map) { //// [for-of46.js] var k, v; -var map = new Map([ - [ - "", - true - ] -]); -for ([ - k = false, - v = "" -] of map) { +var map = new Map([["", true]]); +for ([k = false, v = ""] of map) { k; v; } diff --git a/tests/baselines/reference/for-of47.js b/tests/baselines/reference/for-of47.js index f1e9295c36..d7e596d2ed 100644 --- a/tests/baselines/reference/for-of47.js +++ b/tests/baselines/reference/for-of47.js @@ -9,20 +9,12 @@ for ({x, y: y = E.x} of array) { //// [for-of47.js] var x, y; -var array = [ - { - x: "", - y: true - } -]; +var array = [{ x: "", y: true }]; var E; (function (E) { E[E["x"] = 0] = "x"; })(E || (E = {})); -for ({ - x, - y: y = E.x -} of array) { +for ({ x, y: y = E.x } of array) { x; y; } diff --git a/tests/baselines/reference/for-of48.js b/tests/baselines/reference/for-of48.js index 3030f07e60..2a5e4e32b9 100644 --- a/tests/baselines/reference/for-of48.js +++ b/tests/baselines/reference/for-of48.js @@ -9,20 +9,12 @@ for ({x, y = E.x} of array) { //// [for-of48.js] var x, y; -var array = [ - { - x: "", - y: true - } -]; +var array = [{ x: "", y: true }]; var E; (function (E) { E[E["x"] = 0] = "x"; })(E || (E = {})); -for ({ - x, - y: = E.x -} of array) { +for ({ x, y: = E.x } of array) { x; y; } diff --git a/tests/baselines/reference/for-of49.js b/tests/baselines/reference/for-of49.js index ad3bc415d1..ac7f99f360 100644 --- a/tests/baselines/reference/for-of49.js +++ b/tests/baselines/reference/for-of49.js @@ -8,18 +8,8 @@ for ([k, ...[v]] of map) { //// [for-of49.js] var k, v; -var map = new Map([ - [ - "", - true - ] -]); -for ([ - k, - ...[ - v - ] -] of map) { +var map = new Map([["", true]]); +for ([k, ...[v]] of map) { k; v; } diff --git a/tests/baselines/reference/for-of5.js b/tests/baselines/reference/for-of5.js index 374e1aa79a..4d93b0bd48 100644 --- a/tests/baselines/reference/for-of5.js +++ b/tests/baselines/reference/for-of5.js @@ -4,8 +4,6 @@ for (let v of [0]) { } //// [for-of5.js] -for (let v of [ - 0 -]) { +for (let v of [0]) { v; } diff --git a/tests/baselines/reference/for-of50.js b/tests/baselines/reference/for-of50.js index 21e6f1e732..a300812e6a 100644 --- a/tests/baselines/reference/for-of50.js +++ b/tests/baselines/reference/for-of50.js @@ -6,12 +6,7 @@ for (const [k, v] of map) { } //// [for-of50.js] -var map = new Map([ - [ - "", - true - ] -]); +var map = new Map([["", true]]); for (const [k, v] of map) { k; v; diff --git a/tests/baselines/reference/for-of51.js b/tests/baselines/reference/for-of51.js index 29b907b0f8..cae8c8b38f 100644 --- a/tests/baselines/reference/for-of51.js +++ b/tests/baselines/reference/for-of51.js @@ -2,5 +2,4 @@ for (let let of []) {} //// [for-of51.js] -for (let let of []) { -} +for (let let of []) { } diff --git a/tests/baselines/reference/for-of52.js b/tests/baselines/reference/for-of52.js index 066dd4f81a..48e1dca936 100644 --- a/tests/baselines/reference/for-of52.js +++ b/tests/baselines/reference/for-of52.js @@ -2,7 +2,4 @@ for (let [v, v] of [[]]) {} //// [for-of52.js] -for (let [v, v] of [ - [] -]) { -} +for (let [v, v] of [[]]) { } diff --git a/tests/baselines/reference/for-of55.js b/tests/baselines/reference/for-of55.js index 30baacc8b1..a0f949c6ce 100644 --- a/tests/baselines/reference/for-of55.js +++ b/tests/baselines/reference/for-of55.js @@ -5,9 +5,7 @@ for (let v of v) { } //// [for-of55.js] -let v = [ - 1 -]; +let v = [1]; for (let v of v) { v; } diff --git a/tests/baselines/reference/for-of56.js b/tests/baselines/reference/for-of56.js index 5d540151c1..0992b9c0bb 100644 --- a/tests/baselines/reference/for-of56.js +++ b/tests/baselines/reference/for-of56.js @@ -2,5 +2,4 @@ for (var let of []) {} //// [for-of56.js] -for (var let of []) { -} +for (var let of []) { } diff --git a/tests/baselines/reference/for-of6.js b/tests/baselines/reference/for-of6.js index f176488595..24e93e2a9f 100644 --- a/tests/baselines/reference/for-of6.js +++ b/tests/baselines/reference/for-of6.js @@ -4,8 +4,6 @@ for (v of [0]) { } //// [for-of6.js] -for (v of [ - 0 -]) { +for (v of [0]) { let v; } diff --git a/tests/baselines/reference/for-of7.js b/tests/baselines/reference/for-of7.js index 9bc205676d..04aadd9736 100644 --- a/tests/baselines/reference/for-of7.js +++ b/tests/baselines/reference/for-of7.js @@ -4,7 +4,4 @@ for (let v of [0]) { } //// [for-of7.js] v; -for (let v of [ - 0 -]) { -} +for (let v of [0]) { } diff --git a/tests/baselines/reference/for-of8.js b/tests/baselines/reference/for-of8.js index d521978044..f33d69166d 100644 --- a/tests/baselines/reference/for-of8.js +++ b/tests/baselines/reference/for-of8.js @@ -4,7 +4,4 @@ for (var v of [0]) { } //// [for-of8.js] v; -for (var v of [ - 0 -]) { -} +for (var v of [0]) { } diff --git a/tests/baselines/reference/for-of9.js b/tests/baselines/reference/for-of9.js index b53092414a..f96d353bd7 100644 --- a/tests/baselines/reference/for-of9.js +++ b/tests/baselines/reference/for-of9.js @@ -5,9 +5,5 @@ for (v of "hello") { } //// [for-of9.js] var v; -for (v of [ - "hello" -]) { -} -for (v of "hello") { -} +for (v of ["hello"]) { } +for (v of "hello") { } diff --git a/tests/baselines/reference/forBreakStatements.js b/tests/baselines/reference/forBreakStatements.js index 017837cded..9ed65627c9 100644 --- a/tests/baselines/reference/forBreakStatements.js +++ b/tests/baselines/reference/forBreakStatements.js @@ -61,7 +61,6 @@ SEVEN: for (;;) for (;;) break SEVEN; EIGHT: for (;;) { - var fn = function () { - }; + var fn = function () { }; break EIGHT; } diff --git a/tests/baselines/reference/forContinueStatements.js b/tests/baselines/reference/forContinueStatements.js index b1ace24f4b..34f70bb1fc 100644 --- a/tests/baselines/reference/forContinueStatements.js +++ b/tests/baselines/reference/forContinueStatements.js @@ -61,7 +61,6 @@ SEVEN: for (;;) for (;;) continue SEVEN; EIGHT: for (;;) { - var fn = function () { - }; + var fn = function () { }; continue EIGHT; } diff --git a/tests/baselines/reference/forInBreakStatements.js b/tests/baselines/reference/forInBreakStatements.js index 09f0071d4b..24b7cc57b8 100644 --- a/tests/baselines/reference/forInBreakStatements.js +++ b/tests/baselines/reference/forInBreakStatements.js @@ -61,7 +61,6 @@ SEVEN: for (var x in {}) for (var x in {}) break SEVEN; EIGHT: for (var x in {}) { - var fn = function () { - }; + var fn = function () { }; break EIGHT; } diff --git a/tests/baselines/reference/forInContinueStatements.js b/tests/baselines/reference/forInContinueStatements.js index 68cac5221a..8b036c5972 100644 --- a/tests/baselines/reference/forInContinueStatements.js +++ b/tests/baselines/reference/forInContinueStatements.js @@ -61,7 +61,6 @@ SEVEN: for (var x in {}) for (var x in {}) continue SEVEN; EIGHT: for (var x in {}) { - var fn = function () { - }; + var fn = function () { }; continue EIGHT; } diff --git a/tests/baselines/reference/forStatements.js b/tests/baselines/reference/forStatements.js index 12f1c691cc..39fdb6c887 100644 --- a/tests/baselines/reference/forStatements.js +++ b/tests/baselines/reference/forStatements.js @@ -57,9 +57,7 @@ var D = (function () { } return D; })(); -function F(x) { - return 42; -} +function F(x) { return 42; } var M; (function (M) { var A = (function () { @@ -68,50 +66,24 @@ var M; return A; })(); M.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } M.F2 = F2; })(M || (M = {})); -for (var aNumber = 9.9;;) { -} -for (var aString = 'this is a string';;) { -} -for (var aDate = new Date(12);;) { -} -for (var anObject = new Object();;) { -} -for (var anAny = null;;) { -} -for (var aSecondAny = undefined;;) { -} -for (var aVoid = undefined;;) { -} -for (var anInterface = new C();;) { -} -for (var aClass = new C();;) { -} -for (var aGenericClass = new D();;) { -} -for (var anObjectLiteral = { - id: 12 -};;) { -} -for (var anOtherObjectLiteral = new C();;) { -} -for (var aFunction = F;;) { -} -for (var anOtherFunction = F;;) { -} -for (var aLambda = function (x) { - return 2; -};;) { -} -for (var aModule = M;;) { -} -for (var aClassInModule = new M.A();;) { -} -for (var aFunctionInModule = function (x) { - return 'this is a string'; -};;) { -} +for (var aNumber = 9.9;;) { } +for (var aString = 'this is a string';;) { } +for (var aDate = new Date(12);;) { } +for (var anObject = new Object();;) { } +for (var anAny = null;;) { } +for (var aSecondAny = undefined;;) { } +for (var aVoid = undefined;;) { } +for (var anInterface = new C();;) { } +for (var aClass = new C();;) { } +for (var aGenericClass = new D();;) { } +for (var anObjectLiteral = { id: 12 };;) { } +for (var anOtherObjectLiteral = new C();;) { } +for (var aFunction = F;;) { } +for (var anOtherFunction = F;;) { } +for (var aLambda = function (x) { return 2; };;) { } +for (var aModule = M;;) { } +for (var aClassInModule = new M.A();;) { } +for (var aFunctionInModule = function (x) { return 'this is a string'; };;) { } diff --git a/tests/baselines/reference/forStatementsMultipleInvalidDecl.js b/tests/baselines/reference/forStatementsMultipleInvalidDecl.js index 40888c7ce8..2282136be3 100644 --- a/tests/baselines/reference/forStatementsMultipleInvalidDecl.js +++ b/tests/baselines/reference/forStatementsMultipleInvalidDecl.js @@ -77,9 +77,7 @@ var D = (function () { } return D; })(); -function F(x) { - return 42; -} +function F(x) { return 42; } var M; (function (M) { var A = (function () { @@ -88,58 +86,25 @@ var M; return A; })(); M.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } M.F2 = F2; })(M || (M = {})); // all of these are errors -for (var a;;) { -} -for (var a = 1;;) { -} -for (var a = 'a string';;) { -} -for (var a = new C();;) { -} -for (var a = new D();;) { -} -for (var a = M;;) { -} -for (var b;;) { -} -for (var b = new C();;) { -} -for (var b = new C2();;) { -} -for (var f = F;;) { -} -for (var f = function (x) { - return ''; -};;) { -} -for (var arr;;) { -} -for (var arr = [ - 1, - 2, - 3, - 4 -];;) { -} -for (var arr = [ - new C(), - new C2(), - new D() -];;) { -} -for (var arr2 = [ - new D() -];;) { -} -for (var arr2 = new Array();;) { -} -for (var m;;) { -} -for (var m = M.A;;) { -} +for (var a;;) { } +for (var a = 1;;) { } +for (var a = 'a string';;) { } +for (var a = new C();;) { } +for (var a = new D();;) { } +for (var a = M;;) { } +for (var b;;) { } +for (var b = new C();;) { } +for (var b = new C2();;) { } +for (var f = F;;) { } +for (var f = function (x) { return ''; };;) { } +for (var arr;;) { } +for (var arr = [1, 2, 3, 4];;) { } +for (var arr = [new C(), new C2(), new D()];;) { } +for (var arr2 = [new D()];;) { } +for (var arr2 = new Array();;) { } +for (var m;;) { } +for (var m = M.A;;) { } diff --git a/tests/baselines/reference/forStatementsMultipleValidDecl.js b/tests/baselines/reference/forStatementsMultipleValidDecl.js index aaf88edfe8..e95e37d63a 100644 --- a/tests/baselines/reference/forStatementsMultipleValidDecl.js +++ b/tests/baselines/reference/forStatementsMultipleValidDecl.js @@ -35,74 +35,29 @@ for (var a: typeof a; ;) { } //// [forStatementsMultipleValidDecl.js] // all expected to be valid -for (var x;;) { -} -for (var x = 2;;) { -} -for (var x = undefined;;) { -} +for (var x;;) { } +for (var x = 2;;) { } +for (var x = undefined;;) { } // new declaration space, making redeclaring x as a string valid function declSpace() { - for (var x = 'this is a string';;) { - } -} -for (var p;;) { -} -for (var p = { - x: 1, - y: 2 -};;) { -} -for (var p = { - x: 0, - y: undefined -};;) { -} -for (var p = { - x: 1, - y: undefined -};;) { -} -for (var p = { - x: 1, - y: 2 -};;) { -} -for (var p = { - x: 0, - y: undefined -};;) { -} -for (var p;;) { -} -for (var fn = function (s) { - return 42; -};;) { -} -for (var fn = function (s) { - return 3; -};;) { -} -for (var fn;;) { -} -for (var fn;;) { -} -for (var fn = null;;) { -} -for (var fn;;) { -} -for (var a;;) { -} -for (var a = [ - 'a', - 'b' -];;) { -} -for (var a = [];;) { -} -for (var a = [];;) { -} -for (var a = new Array();;) { -} -for (var a;;) { + for (var x = 'this is a string';;) { } } +for (var p;;) { } +for (var p = { x: 1, y: 2 };;) { } +for (var p = { x: 0, y: undefined };;) { } +for (var p = { x: 1, y: undefined };;) { } +for (var p = { x: 1, y: 2 };;) { } +for (var p = { x: 0, y: undefined };;) { } +for (var p;;) { } +for (var fn = function (s) { return 42; };;) { } +for (var fn = function (s) { return 3; };;) { } +for (var fn;;) { } +for (var fn;;) { } +for (var fn = null;;) { } +for (var fn;;) { } +for (var a;;) { } +for (var a = ['a', 'b'];;) { } +for (var a = [];;) { } +for (var a = [];;) { } +for (var a = new Array();;) { } +for (var a;;) { } diff --git a/tests/baselines/reference/funClodule.js b/tests/baselines/reference/funClodule.js index 8629ed6305..cc7dba7e47 100644 --- a/tests/baselines/reference/funClodule.js +++ b/tests/baselines/reference/funClodule.js @@ -20,12 +20,10 @@ module foo3 { class foo3 { } // Should error //// [funClodule.js] -function foo3() { -} +function foo3() { } var foo3; (function (foo3) { - function x() { - } + function x() { } foo3.x = x; })(foo3 || (foo3 = {})); var foo3 = (function () { diff --git a/tests/baselines/reference/funcdecl.js b/tests/baselines/reference/funcdecl.js index de080873b9..348d25bd67 100644 --- a/tests/baselines/reference/funcdecl.js +++ b/tests/baselines/reference/funcdecl.js @@ -115,8 +115,7 @@ function overload1(ns) { return ns.toString(); } var withOverloadSignature = overload1; -function f(n) { -} +function f(n) { } var m2; (function (m2) { function foo(n) { diff --git a/tests/baselines/reference/functionAndInterfaceWithSeparateErrors.js b/tests/baselines/reference/functionAndInterfaceWithSeparateErrors.js index 004e65d92a..d59cff501e 100644 --- a/tests/baselines/reference/functionAndInterfaceWithSeparateErrors.js +++ b/tests/baselines/reference/functionAndInterfaceWithSeparateErrors.js @@ -8,5 +8,4 @@ interface Foo { } //// [functionAndInterfaceWithSeparateErrors.js] -function Foo(n) { -} +function Foo(n) { } diff --git a/tests/baselines/reference/functionAndPropertyNameConflict.js b/tests/baselines/reference/functionAndPropertyNameConflict.js index 1368f8241d..28a2cd54c9 100644 --- a/tests/baselines/reference/functionAndPropertyNameConflict.js +++ b/tests/baselines/reference/functionAndPropertyNameConflict.js @@ -10,8 +10,7 @@ class C65 { var C65 = (function () { function C65() { } - C65.prototype.aaaaa = function () { - }; + C65.prototype.aaaaa = function () { }; Object.defineProperty(C65.prototype, "aaaaa", { get: function () { return 1; diff --git a/tests/baselines/reference/functionArgShadowing.js b/tests/baselines/reference/functionArgShadowing.js index c74570902e..451e46536e 100644 --- a/tests/baselines/reference/functionArgShadowing.js +++ b/tests/baselines/reference/functionArgShadowing.js @@ -18,15 +18,13 @@ class C { var A = (function () { function A() { } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); var B = (function () { function B() { } - B.prototype.bar = function () { - }; + B.prototype.bar = function () { }; return B; })(); function foo(x) { diff --git a/tests/baselines/reference/functionAssignment.js b/tests/baselines/reference/functionAssignment.js index 52b6694650..3237f53bf9 100644 --- a/tests/baselines/reference/functionAssignment.js +++ b/tests/baselines/reference/functionAssignment.js @@ -38,30 +38,19 @@ callb((a) =>{ a.length; }); //// [functionAssignment.js] -function f(n) { -} -f(function () { -}); +function f(n) { } +f(function () { }); var barbaz; var test; test.get(function (param) { - var x = barbaz.get(function () { - }); + var x = barbaz.get(function () { }); }); -function f2(n) { -} +function f2(n) { } f2(function () { var n = ''; n = 4; }); -function f3(a) { -} -f3({ - a: 0, - b: 0 -}); -function callb(a) { -} -callb(function (a) { - a.length; -}); +function f3(a) { } +f3({ a: 0, b: 0 }); +function callb(a) { } +callb(function (a) { a.length; }); diff --git a/tests/baselines/reference/functionAssignmentError.js b/tests/baselines/reference/functionAssignmentError.js index e19547096b..dd35ccb271 100644 --- a/tests/baselines/reference/functionAssignmentError.js +++ b/tests/baselines/reference/functionAssignmentError.js @@ -3,9 +3,5 @@ var func = function (){return "ONE";}; func = function (){return "ONE";}; //// [functionAssignmentError.js] -var func = function () { - return "ONE"; -}; -func = function () { - return "ONE"; -}; +var func = function () { return "ONE"; }; +func = function () { return "ONE"; }; diff --git a/tests/baselines/reference/functionCall1.js b/tests/baselines/reference/functionCall1.js index 8025ad5a6f..cb8c1a46a2 100644 --- a/tests/baselines/reference/functionCall1.js +++ b/tests/baselines/reference/functionCall1.js @@ -3,8 +3,6 @@ function foo():any{return ""}; var x = foo(); //// [functionCall1.js] -function foo() { - return ""; -} +function foo() { return ""; } ; var x = foo(); diff --git a/tests/baselines/reference/functionCall11.js b/tests/baselines/reference/functionCall11.js index 9c36dedba3..019ea213db 100644 --- a/tests/baselines/reference/functionCall11.js +++ b/tests/baselines/reference/functionCall11.js @@ -8,8 +8,7 @@ foo('foo', 1, 'bar'); //// [functionCall11.js] -function foo(a, b) { -} +function foo(a, b) { } foo('foo', 1); foo('foo'); foo(); diff --git a/tests/baselines/reference/functionCall12.js b/tests/baselines/reference/functionCall12.js index ca71c25a17..2c3396c209 100644 --- a/tests/baselines/reference/functionCall12.js +++ b/tests/baselines/reference/functionCall12.js @@ -9,8 +9,7 @@ foo('foo', 1, 3); //// [functionCall12.js] -function foo(a, b, c) { -} +function foo(a, b, c) { } foo('foo', 1); foo('foo'); foo(); diff --git a/tests/baselines/reference/functionCall2.js b/tests/baselines/reference/functionCall2.js index 5b6da37810..5351dc116f 100644 --- a/tests/baselines/reference/functionCall2.js +++ b/tests/baselines/reference/functionCall2.js @@ -3,8 +3,6 @@ function foo():number{return 1}; var x = foo(); //// [functionCall2.js] -function foo() { - return 1; -} +function foo() { return 1; } ; var x = foo(); diff --git a/tests/baselines/reference/functionCall3.js b/tests/baselines/reference/functionCall3.js index 0e229ccddb..74540c2ccf 100644 --- a/tests/baselines/reference/functionCall3.js +++ b/tests/baselines/reference/functionCall3.js @@ -3,9 +3,5 @@ function foo():any[]{return [1];} var x = foo(); //// [functionCall3.js] -function foo() { - return [ - 1 - ]; -} +function foo() { return [1]; } var x = foo(); diff --git a/tests/baselines/reference/functionCall4.js b/tests/baselines/reference/functionCall4.js index 05021c3356..0f937337d4 100644 --- a/tests/baselines/reference/functionCall4.js +++ b/tests/baselines/reference/functionCall4.js @@ -4,12 +4,8 @@ function bar():()=>any{return foo}; var x = bar(); //// [functionCall4.js] -function foo() { - return ""; -} +function foo() { return ""; } ; -function bar() { - return foo; -} +function bar() { return foo; } ; var x = bar(); diff --git a/tests/baselines/reference/functionCall5.js b/tests/baselines/reference/functionCall5.js index e6b0e049ef..dc7db4a995 100644 --- a/tests/baselines/reference/functionCall5.js +++ b/tests/baselines/reference/functionCall5.js @@ -13,8 +13,6 @@ var m1; })(); m1.c1 = c1; })(m1 || (m1 = {})); -function foo() { - return new m1.c1(); -} +function foo() { return new m1.c1(); } ; var x = foo(); diff --git a/tests/baselines/reference/functionCall6.js b/tests/baselines/reference/functionCall6.js index 21582666b9..01197a5fd8 100644 --- a/tests/baselines/reference/functionCall6.js +++ b/tests/baselines/reference/functionCall6.js @@ -7,8 +7,7 @@ foo(); //// [functionCall6.js] -function foo(a) { -} +function foo(a) { } ; foo('bar'); foo(2); diff --git a/tests/baselines/reference/functionCall7.js b/tests/baselines/reference/functionCall7.js index b32c21b589..cb30e5d8b2 100644 --- a/tests/baselines/reference/functionCall7.js +++ b/tests/baselines/reference/functionCall7.js @@ -18,9 +18,7 @@ var m1; })(); m1.c1 = c1; })(m1 || (m1 = {})); -function foo(a) { - a.a = 1; -} +function foo(a) { a.a = 1; } ; var myC = new m1.c1(); foo(myC); diff --git a/tests/baselines/reference/functionCall8.js b/tests/baselines/reference/functionCall8.js index 7eb5a9f60d..5859fdfb37 100644 --- a/tests/baselines/reference/functionCall8.js +++ b/tests/baselines/reference/functionCall8.js @@ -7,8 +7,7 @@ foo(); //// [functionCall8.js] -function foo(a) { -} +function foo(a) { } foo('foo'); foo('foo', 'bar'); foo(4); diff --git a/tests/baselines/reference/functionCall9.js b/tests/baselines/reference/functionCall9.js index d2d81a3ca0..bc7e112f0c 100644 --- a/tests/baselines/reference/functionCall9.js +++ b/tests/baselines/reference/functionCall9.js @@ -7,8 +7,7 @@ foo('foo', 1, 'bar'); foo(); //// [functionCall9.js] -function foo(a, b) { -} +function foo(a, b) { } ; foo('foo', 1); foo('foo'); diff --git a/tests/baselines/reference/functionConstraintSatisfaction.js b/tests/baselines/reference/functionConstraintSatisfaction.js index 20c5df0098..b874145617 100644 --- a/tests/baselines/reference/functionConstraintSatisfaction.js +++ b/tests/baselines/reference/functionConstraintSatisfaction.js @@ -63,9 +63,7 @@ function foo2(x: T, y: U) { //// [functionConstraintSatisfaction.js] // satisfaction of a constraint to Function, no errors expected -function foo(x) { - return x; -} +function foo(x) { return x; } var i; var C = (function () { function C() { @@ -76,18 +74,10 @@ var a; var b; var c; var r = foo(new Function()); -var r1 = foo(function (x) { - return x; -}); -var r2 = foo(function (x) { - return x; -}); -var r3 = foo(function (x) { - return x; -}); -var r4 = foo(function (x) { - return x; -}); +var r1 = foo(function (x) { return x; }); +var r2 = foo(function (x) { return x; }); +var r3 = foo(function (x) { return x; }); +var r4 = foo(function (x) { return x; }); var r5 = foo(i); var r6 = foo(C); var r7 = foo(b); @@ -101,18 +91,10 @@ var C2 = (function () { var a2; var b2; var c2; -var r9 = foo(function (x) { - return x; -}); -var r10 = foo(function (x) { - return x; -}); -var r11 = foo(function (x) { - return x; -}); -var r12 = foo(function (x, y) { - return x; -}); +var r9 = foo(function (x) { return x; }); +var r10 = foo(function (x) { return x; }); +var r11 = foo(function (x) { return x; }); +var r12 = foo(function (x, y) { return x; }); var r13 = foo(i2); var r14 = foo(C2); var r15 = foo(b2); diff --git a/tests/baselines/reference/functionConstraintSatisfaction2.js b/tests/baselines/reference/functionConstraintSatisfaction2.js index 4575775953..9e70a508cc 100644 --- a/tests/baselines/reference/functionConstraintSatisfaction2.js +++ b/tests/baselines/reference/functionConstraintSatisfaction2.js @@ -42,17 +42,11 @@ function fff(x: T, y: U) { //// [functionConstraintSatisfaction2.js] // satisfaction of a constraint to Function, all of these invocations are errors unless otherwise noted -function foo(x) { - return x; -} +function foo(x) { return x; } foo(1); -foo(function () { -}, 1); -foo(1, function () { -}); -function foo2(x) { - return x; -} +foo(function () { }, 1); +foo(1, function () { }); +function foo2(x) { return x; } var C = (function () { function C() { } @@ -66,17 +60,11 @@ var C2 = (function () { })(); var b2; var r = foo2(new Function()); -var r2 = foo2(function (x) { - return x; -}); +var r2 = foo2(function (x) { return x; }); var r6 = foo2(C); var r7 = foo2(b); -var r8 = foo2(function (x) { - return x; -}); // no error expected -var r11 = foo2(function (x, y) { - return x; -}); +var r8 = foo2(function (x) { return x; }); // no error expected +var r11 = foo2(function (x, y) { return x; }); var r13 = foo2(C2); var r14 = foo2(b2); var f2; diff --git a/tests/baselines/reference/functionConstraintSatisfaction3.js b/tests/baselines/reference/functionConstraintSatisfaction3.js index a33c2c6408..2c1bfa4d39 100644 --- a/tests/baselines/reference/functionConstraintSatisfaction3.js +++ b/tests/baselines/reference/functionConstraintSatisfaction3.js @@ -43,9 +43,7 @@ var r15 = foo(c2); //// [functionConstraintSatisfaction3.js] // satisfaction of a constraint to Function, no errors expected -function foo(x) { - return x; -} +function foo(x) { return x; } var i; var C = (function () { function C() { @@ -55,18 +53,10 @@ var C = (function () { var a; var b; var c; -var r1 = foo(function (x) { - return x; -}); -var r2 = foo(function (x) { - return x; -}); -var r3 = foo(function (x) { - return x; -}); -var r4 = foo(function (x) { - return x; -}); +var r1 = foo(function (x) { return x; }); +var r2 = foo(function (x) { return x; }); +var r3 = foo(function (x) { return x; }); +var r4 = foo(function (x) { return x; }); var r5 = foo(i); var r8 = foo(c); var i2; @@ -78,11 +68,7 @@ var C2 = (function () { var a2; var b2; var c2; -var r9 = foo(function (x) { - return x; -}); -var r10 = foo(function (x) { - return x; -}); +var r9 = foo(function (x) { return x; }); +var r10 = foo(function (x) { return x; }); var r12 = foo(i2); var r15 = foo(c2); diff --git a/tests/baselines/reference/functionExpressionAndLambdaMatchesFunction.js b/tests/baselines/reference/functionExpressionAndLambdaMatchesFunction.js index 2c882b8285..fe10f96f7b 100644 --- a/tests/baselines/reference/functionExpressionAndLambdaMatchesFunction.js +++ b/tests/baselines/reference/functionExpressionAndLambdaMatchesFunction.js @@ -14,11 +14,8 @@ var CDoc = (function () { function CDoc() { function doSomething(a) { } - doSomething(function () { - return undefined; - }); - doSomething(function () { - }); + doSomething(function () { return undefined; }); + doSomething(function () { }); } return CDoc; })(); diff --git a/tests/baselines/reference/functionExpressionInWithBlock.js b/tests/baselines/reference/functionExpressionInWithBlock.js index 5e06ad8169..f2353412d5 100644 --- a/tests/baselines/reference/functionExpressionInWithBlock.js +++ b/tests/baselines/reference/functionExpressionInWithBlock.js @@ -11,9 +11,7 @@ function x() { function x() { with ({}) { function f() { - (function () { - return this; - }); + (function () { return this; }); } } } diff --git a/tests/baselines/reference/functionExpressionReturningItself.js b/tests/baselines/reference/functionExpressionReturningItself.js index 8553d2da86..9485100164 100644 --- a/tests/baselines/reference/functionExpressionReturningItself.js +++ b/tests/baselines/reference/functionExpressionReturningItself.js @@ -2,9 +2,7 @@ var x = function somefn() { return somefn; }; //// [functionExpressionReturningItself.js] -var x = function somefn() { - return somefn; -}; +var x = function somefn() { return somefn; }; //// [functionExpressionReturningItself.d.ts] diff --git a/tests/baselines/reference/functionImplementationErrors.js b/tests/baselines/reference/functionImplementationErrors.js index 95b0d9e700..5eaf902733 100644 --- a/tests/baselines/reference/functionImplementationErrors.js +++ b/tests/baselines/reference/functionImplementationErrors.js @@ -96,14 +96,10 @@ var f3 = function () { // FunctionExpression with no return type annotation with return branch of number[] and other of string[] var f4 = function () { if (true) { - return [ - '' - ]; + return ['']; } else { - return [ - 1 - ]; + return [1]; } }; // Function implemetnation with non -void return type annotation with no return diff --git a/tests/baselines/reference/functionImplementations.js b/tests/baselines/reference/functionImplementations.js index e3a498dbeb..c478f892fd 100644 --- a/tests/baselines/reference/functionImplementations.js +++ b/tests/baselines/reference/functionImplementations.js @@ -164,8 +164,7 @@ var __extends = this.__extends || function (d, b) { d.prototype = new __(); }; // FunctionExpression with no return type annotation and no return statement returns void -var v = function () { -}(); +var v = function () { }(); // FunctionExpression f with no return type annotation and directly references f in its body returns any var a = function f() { return f; @@ -269,10 +268,7 @@ function opt1(n) { } // Function signature with optional parameter, no type annotation and initializer has initializer's widened type function opt2(n) { - if (n === void 0) { n = { - x: null, - y: undefined - }; } + if (n === void 0) { n = { x: null, y: undefined }; } var m = n; var m; } diff --git a/tests/baselines/reference/functionLiteral.js b/tests/baselines/reference/functionLiteral.js index bf42f9e859..8ee515e8f8 100644 --- a/tests/baselines/reference/functionLiteral.js +++ b/tests/baselines/reference/functionLiteral.js @@ -15,14 +15,10 @@ var z: new (x: number) => number; //// [functionLiteral.js] // basic valid forms of function literals -var x = function () { - return 1; -}; +var x = function () { return 1; }; var x; var y; var y; -var y2 = function (x) { - return x; -}; +var y2 = function (x) { return x; }; var z; var z; diff --git a/tests/baselines/reference/functionLiteralForOverloads.js b/tests/baselines/reference/functionLiteralForOverloads.js index 06631101e0..1a0bc874c4 100644 --- a/tests/baselines/reference/functionLiteralForOverloads.js +++ b/tests/baselines/reference/functionLiteralForOverloads.js @@ -23,15 +23,7 @@ var f4: { //// [functionLiteralForOverloads.js] // basic uses of function literals with overloads -var f = function (x) { - return x; -}; -var f2 = function (x) { - return x; -}; -var f3 = function (x) { - return x; -}; -var f4 = function (x) { - return x; -}; +var f = function (x) { return x; }; +var f2 = function (x) { return x; }; +var f3 = function (x) { return x; }; +var f4 = function (x) { return x; }; diff --git a/tests/baselines/reference/functionNameConflicts.js b/tests/baselines/reference/functionNameConflicts.js index 99ede14dfd..87b61e3733 100644 --- a/tests/baselines/reference/functionNameConflicts.js +++ b/tests/baselines/reference/functionNameConflicts.js @@ -32,22 +32,17 @@ function overrr() { //Function overload with different name from implementation signature var M; (function (M) { - function fn1() { - } + function fn1() { } var fn1; var fn2; - function fn2() { - } + function fn2() { } })(M || (M = {})); -function fn3() { -} +function fn3() { } var fn3; function func() { var fn4; - function fn4() { - } - function fn5() { - } + function fn4() { } + function fn5() { } var fn5; } function overrr() { diff --git a/tests/baselines/reference/functionOverloadAmbiguity1.js b/tests/baselines/reference/functionOverloadAmbiguity1.js index d53ec68c9d..2833ccbcdc 100644 --- a/tests/baselines/reference/functionOverloadAmbiguity1.js +++ b/tests/baselines/reference/functionOverloadAmbiguity1.js @@ -11,13 +11,7 @@ callb2((a) => { a.length; } ); // ok, chose first overload //// [functionOverloadAmbiguity1.js] -function callb(a) { -} -callb(function (a) { - a.length; -}); // error, chose first overload -function callb2(a) { -} -callb2(function (a) { - a.length; -}); // ok, chose first overload +function callb(a) { } +callb(function (a) { a.length; }); // error, chose first overload +function callb2(a) { } +callb2(function (a) { a.length; }); // ok, chose first overload diff --git a/tests/baselines/reference/functionOverloadErrors.js b/tests/baselines/reference/functionOverloadErrors.js index 623b0e6f4d..b0c0f44945 100644 --- a/tests/baselines/reference/functionOverloadErrors.js +++ b/tests/baselines/reference/functionOverloadErrors.js @@ -119,8 +119,7 @@ function initExpr() { } //// [functionOverloadErrors.js] -function fn1() { -} +function fn1() { } function fn2a() { } function fn2b() { @@ -128,52 +127,37 @@ function fn2b() { function fn3() { return null; } -function fn6() { -} -function fn7() { -} -function fn8() { -} -function fn9() { -} -function fn10() { -} -function fn11() { -} -function fn12() { -} +function fn6() { } +function fn7() { } +function fn8() { } +function fn9() { } +function fn10() { } +function fn11() { } +function fn12() { } //Function overloads that differ by accessibility var cls = (function () { function cls() { } - cls.prototype.f = function () { - }; - cls.prototype.g = function () { - }; + cls.prototype.f = function () { }; + cls.prototype.g = function () { }; return cls; })(); //Function overloads with differing export var M; (function (M) { - function fn1() { - } - function fn2() { - } + function fn1() { } + function fn2() { } M.fn2 = fn2; })(M || (M = {})); -function dfn1() { -} -function dfn2() { -} +function dfn1() { } +function dfn2() { } function fewerParams(n) { } -function fn13(n) { -} +function fn13(n) { } function fn14() { return 3; } function fn15() { return undefined; } -function initExpr() { -} +function initExpr() { } diff --git a/tests/baselines/reference/functionOverloadErrorsSyntax.js b/tests/baselines/reference/functionOverloadErrorsSyntax.js index 3706f4da74..1a5537d2de 100644 --- a/tests/baselines/reference/functionOverloadErrorsSyntax.js +++ b/tests/baselines/reference/functionOverloadErrorsSyntax.js @@ -12,9 +12,6 @@ function fn5() { } //// [functionOverloadErrorsSyntax.js] -function fn4a() { -} -function fn4b() { -} -function fn5() { -} +function fn4a() { } +function fn4b() { } +function fn5() { } diff --git a/tests/baselines/reference/functionOverloadImplementationOfWrongName.js b/tests/baselines/reference/functionOverloadImplementationOfWrongName.js index 6b66bc89ff..465753f104 100644 --- a/tests/baselines/reference/functionOverloadImplementationOfWrongName.js +++ b/tests/baselines/reference/functionOverloadImplementationOfWrongName.js @@ -4,5 +4,4 @@ function foo(x, y); function bar() { } //// [functionOverloadImplementationOfWrongName.js] -function bar() { -} +function bar() { } diff --git a/tests/baselines/reference/functionOverloadImplementationOfWrongName2.js b/tests/baselines/reference/functionOverloadImplementationOfWrongName2.js index c3008e7a6c..34cf73d323 100644 --- a/tests/baselines/reference/functionOverloadImplementationOfWrongName2.js +++ b/tests/baselines/reference/functionOverloadImplementationOfWrongName2.js @@ -4,5 +4,4 @@ function bar() { } function foo(x, y); //// [functionOverloadImplementationOfWrongName2.js] -function bar() { -} +function bar() { } diff --git a/tests/baselines/reference/functionOverloads.js b/tests/baselines/reference/functionOverloads.js index 5504b28662..7e38b8fe99 100644 --- a/tests/baselines/reference/functionOverloads.js +++ b/tests/baselines/reference/functionOverloads.js @@ -5,8 +5,6 @@ function foo(bar?: string): any { return "" }; var x = foo(5); //// [functionOverloads.js] -function foo(bar) { - return ""; -} +function foo(bar) { return ""; } ; var x = foo(5); diff --git a/tests/baselines/reference/functionOverloads1.js b/tests/baselines/reference/functionOverloads1.js index 695a9c3780..5b4acabd02 100644 --- a/tests/baselines/reference/functionOverloads1.js +++ b/tests/baselines/reference/functionOverloads1.js @@ -5,6 +5,4 @@ function foo():string { return "a" } //// [functionOverloads1.js] 1 + 1; -function foo() { - return "a"; -} +function foo() { return "a"; } diff --git a/tests/baselines/reference/functionOverloads10.js b/tests/baselines/reference/functionOverloads10.js index 2cd24bcd1c..08b71698dc 100644 --- a/tests/baselines/reference/functionOverloads10.js +++ b/tests/baselines/reference/functionOverloads10.js @@ -5,5 +5,4 @@ function foo(foo:any){ } //// [functionOverloads10.js] -function foo(foo) { -} +function foo(foo) { } diff --git a/tests/baselines/reference/functionOverloads11.js b/tests/baselines/reference/functionOverloads11.js index efc9c79312..8d85b0ffb7 100644 --- a/tests/baselines/reference/functionOverloads11.js +++ b/tests/baselines/reference/functionOverloads11.js @@ -4,6 +4,4 @@ function foo():string { return "" } //// [functionOverloads11.js] -function foo() { - return ""; -} +function foo() { return ""; } diff --git a/tests/baselines/reference/functionOverloads12.js b/tests/baselines/reference/functionOverloads12.js index ff789083ee..4681e43ee5 100644 --- a/tests/baselines/reference/functionOverloads12.js +++ b/tests/baselines/reference/functionOverloads12.js @@ -5,9 +5,7 @@ function foo():any { if (true) return ""; else return 0;} //// [functionOverloads12.js] -function foo() { - if (true) - return ""; - else - return 0; -} +function foo() { if (true) + return ""; +else + return 0; } diff --git a/tests/baselines/reference/functionOverloads13.js b/tests/baselines/reference/functionOverloads13.js index f9eb4d59e4..ff43c85e3d 100644 --- a/tests/baselines/reference/functionOverloads13.js +++ b/tests/baselines/reference/functionOverloads13.js @@ -5,6 +5,4 @@ function foo(bar?:number):any { return "" } //// [functionOverloads13.js] -function foo(bar) { - return ""; -} +function foo(bar) { return ""; } diff --git a/tests/baselines/reference/functionOverloads14.js b/tests/baselines/reference/functionOverloads14.js index e580c4e228..826b096290 100644 --- a/tests/baselines/reference/functionOverloads14.js +++ b/tests/baselines/reference/functionOverloads14.js @@ -5,8 +5,4 @@ function foo():{a:any;} { return {a:1} } //// [functionOverloads14.js] -function foo() { - return { - a: 1 - }; -} +function foo() { return { a: 1 }; } diff --git a/tests/baselines/reference/functionOverloads15.js b/tests/baselines/reference/functionOverloads15.js index 2b80df6630..fe0c90f82a 100644 --- a/tests/baselines/reference/functionOverloads15.js +++ b/tests/baselines/reference/functionOverloads15.js @@ -5,6 +5,4 @@ function foo(foo:{a:string; b?:number;}):any { return "" } //// [functionOverloads15.js] -function foo(foo) { - return ""; -} +function foo(foo) { return ""; } diff --git a/tests/baselines/reference/functionOverloads16.js b/tests/baselines/reference/functionOverloads16.js index ebf82febd1..a0fdaa8889 100644 --- a/tests/baselines/reference/functionOverloads16.js +++ b/tests/baselines/reference/functionOverloads16.js @@ -5,6 +5,4 @@ function foo(foo:{a:string; b?:number;}):any { return "" } //// [functionOverloads16.js] -function foo(foo) { - return ""; -} +function foo(foo) { return ""; } diff --git a/tests/baselines/reference/functionOverloads17.js b/tests/baselines/reference/functionOverloads17.js index ef1a9e765f..3a5dcd8191 100644 --- a/tests/baselines/reference/functionOverloads17.js +++ b/tests/baselines/reference/functionOverloads17.js @@ -4,8 +4,4 @@ function foo():{a:string;} { return {a:""} } //// [functionOverloads17.js] -function foo() { - return { - a: "" - }; -} +function foo() { return { a: "" }; } diff --git a/tests/baselines/reference/functionOverloads18.js b/tests/baselines/reference/functionOverloads18.js index 65a16c2896..8c196831e4 100644 --- a/tests/baselines/reference/functionOverloads18.js +++ b/tests/baselines/reference/functionOverloads18.js @@ -4,8 +4,4 @@ function foo(bar:{a:string;}) { return {a:""} } //// [functionOverloads18.js] -function foo(bar) { - return { - a: "" - }; -} +function foo(bar) { return { a: "" }; } diff --git a/tests/baselines/reference/functionOverloads19.js b/tests/baselines/reference/functionOverloads19.js index d5749d3eef..4183f6a48b 100644 --- a/tests/baselines/reference/functionOverloads19.js +++ b/tests/baselines/reference/functionOverloads19.js @@ -5,8 +5,4 @@ function foo(bar:{a:any;}) { return {a:""} } //// [functionOverloads19.js] -function foo(bar) { - return { - a: "" - }; -} +function foo(bar) { return { a: "" }; } diff --git a/tests/baselines/reference/functionOverloads2.js b/tests/baselines/reference/functionOverloads2.js index 7e9eb45d23..39a58663cf 100644 --- a/tests/baselines/reference/functionOverloads2.js +++ b/tests/baselines/reference/functionOverloads2.js @@ -5,8 +5,6 @@ function foo(bar: any): any { return bar }; var x = foo(true); //// [functionOverloads2.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } ; var x = foo(true); diff --git a/tests/baselines/reference/functionOverloads20.js b/tests/baselines/reference/functionOverloads20.js index 012f2ce09c..4f259a8853 100644 --- a/tests/baselines/reference/functionOverloads20.js +++ b/tests/baselines/reference/functionOverloads20.js @@ -5,6 +5,4 @@ function foo(bar:{a:any;}): string {return ""} //// [functionOverloads20.js] -function foo(bar) { - return ""; -} +function foo(bar) { return ""; } diff --git a/tests/baselines/reference/functionOverloads21.js b/tests/baselines/reference/functionOverloads21.js index 78fb1fe011..6e69169efb 100644 --- a/tests/baselines/reference/functionOverloads21.js +++ b/tests/baselines/reference/functionOverloads21.js @@ -5,6 +5,4 @@ function foo(bar:{a:any; b?:string;}[]) { return 0 } //// [functionOverloads21.js] -function foo(bar) { - return 0; -} +function foo(bar) { return 0; } diff --git a/tests/baselines/reference/functionOverloads22.js b/tests/baselines/reference/functionOverloads22.js index d682b44182..54b745d96d 100644 --- a/tests/baselines/reference/functionOverloads22.js +++ b/tests/baselines/reference/functionOverloads22.js @@ -5,10 +5,4 @@ function foo(bar:any):{a:any;b?:any;}[] { return [{a:""}] } //// [functionOverloads22.js] -function foo(bar) { - return [ - { - a: "" - } - ]; -} +function foo(bar) { return [{ a: "" }]; } diff --git a/tests/baselines/reference/functionOverloads23.js b/tests/baselines/reference/functionOverloads23.js index d8cac7eb8e..aa3a7172ad 100644 --- a/tests/baselines/reference/functionOverloads23.js +++ b/tests/baselines/reference/functionOverloads23.js @@ -5,6 +5,4 @@ function foo(bar:(a?)=>void) { return 0 } //// [functionOverloads23.js] -function foo(bar) { - return 0; -} +function foo(bar) { return 0; } diff --git a/tests/baselines/reference/functionOverloads24.js b/tests/baselines/reference/functionOverloads24.js index 5ff4e248c0..8fcc3c8190 100644 --- a/tests/baselines/reference/functionOverloads24.js +++ b/tests/baselines/reference/functionOverloads24.js @@ -5,7 +5,4 @@ function foo(bar:any):(a)=>void { return function(){} } //// [functionOverloads24.js] -function foo(bar) { - return function () { - }; -} +function foo(bar) { return function () { }; } diff --git a/tests/baselines/reference/functionOverloads25.js b/tests/baselines/reference/functionOverloads25.js index bbaef49892..d466aa82d2 100644 --- a/tests/baselines/reference/functionOverloads25.js +++ b/tests/baselines/reference/functionOverloads25.js @@ -6,8 +6,6 @@ var x = foo(); //// [functionOverloads25.js] -function foo(bar) { - return ''; -} +function foo(bar) { return ''; } ; var x = foo(); diff --git a/tests/baselines/reference/functionOverloads26.js b/tests/baselines/reference/functionOverloads26.js index 088c06147b..bc4d017b9b 100644 --- a/tests/baselines/reference/functionOverloads26.js +++ b/tests/baselines/reference/functionOverloads26.js @@ -6,7 +6,5 @@ var x = foo('baz'); //// [functionOverloads26.js] -function foo(bar) { - return ''; -} +function foo(bar) { return ''; } var x = foo('baz'); diff --git a/tests/baselines/reference/functionOverloads27.js b/tests/baselines/reference/functionOverloads27.js index 2b11b1f6c4..199905d821 100644 --- a/tests/baselines/reference/functionOverloads27.js +++ b/tests/baselines/reference/functionOverloads27.js @@ -6,7 +6,5 @@ var x = foo(5); //// [functionOverloads27.js] -function foo(bar) { - return ''; -} +function foo(bar) { return ''; } var x = foo(5); diff --git a/tests/baselines/reference/functionOverloads28.js b/tests/baselines/reference/functionOverloads28.js index 566972ee25..d10ef52e2b 100644 --- a/tests/baselines/reference/functionOverloads28.js +++ b/tests/baselines/reference/functionOverloads28.js @@ -6,8 +6,6 @@ var t:any; var x = foo(t); //// [functionOverloads28.js] -function foo(bar) { - return ''; -} +function foo(bar) { return ''; } var t; var x = foo(t); diff --git a/tests/baselines/reference/functionOverloads29.js b/tests/baselines/reference/functionOverloads29.js index c828bb9591..edc1ea178b 100644 --- a/tests/baselines/reference/functionOverloads29.js +++ b/tests/baselines/reference/functionOverloads29.js @@ -6,7 +6,5 @@ var x = foo(); //// [functionOverloads29.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } var x = foo(); diff --git a/tests/baselines/reference/functionOverloads30.js b/tests/baselines/reference/functionOverloads30.js index 27b1436b6f..bc7593a077 100644 --- a/tests/baselines/reference/functionOverloads30.js +++ b/tests/baselines/reference/functionOverloads30.js @@ -6,7 +6,5 @@ var x = foo('bar'); //// [functionOverloads30.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } var x = foo('bar'); diff --git a/tests/baselines/reference/functionOverloads31.js b/tests/baselines/reference/functionOverloads31.js index 01cee2c342..2c2a15821a 100644 --- a/tests/baselines/reference/functionOverloads31.js +++ b/tests/baselines/reference/functionOverloads31.js @@ -6,7 +6,5 @@ var x = foo(5); //// [functionOverloads31.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } var x = foo(5); diff --git a/tests/baselines/reference/functionOverloads32.js b/tests/baselines/reference/functionOverloads32.js index 4e0efa98b0..a5557042df 100644 --- a/tests/baselines/reference/functionOverloads32.js +++ b/tests/baselines/reference/functionOverloads32.js @@ -6,8 +6,6 @@ var baz:number; var x = foo(baz); //// [functionOverloads32.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } var baz; var x = foo(baz); diff --git a/tests/baselines/reference/functionOverloads33.js b/tests/baselines/reference/functionOverloads33.js index 0c01cd54d1..98bcc09b8b 100644 --- a/tests/baselines/reference/functionOverloads33.js +++ b/tests/baselines/reference/functionOverloads33.js @@ -6,7 +6,5 @@ var x = foo(5); //// [functionOverloads33.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } var x = foo(5); diff --git a/tests/baselines/reference/functionOverloads34.js b/tests/baselines/reference/functionOverloads34.js index 48ac2b5fc5..3d4311e419 100644 --- a/tests/baselines/reference/functionOverloads34.js +++ b/tests/baselines/reference/functionOverloads34.js @@ -6,7 +6,5 @@ var x = foo(); //// [functionOverloads34.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } var x = foo(); diff --git a/tests/baselines/reference/functionOverloads35.js b/tests/baselines/reference/functionOverloads35.js index 64ff527dee..b25ac6c3c5 100644 --- a/tests/baselines/reference/functionOverloads35.js +++ b/tests/baselines/reference/functionOverloads35.js @@ -6,9 +6,5 @@ var x = foo({a:1}); //// [functionOverloads35.js] -function foo(bar) { - return bar; -} -var x = foo({ - a: 1 -}); +function foo(bar) { return bar; } +var x = foo({ a: 1 }); diff --git a/tests/baselines/reference/functionOverloads36.js b/tests/baselines/reference/functionOverloads36.js index 3872aa3191..4e790917d9 100644 --- a/tests/baselines/reference/functionOverloads36.js +++ b/tests/baselines/reference/functionOverloads36.js @@ -6,9 +6,5 @@ var x = foo({a:'foo'}); //// [functionOverloads36.js] -function foo(bar) { - return bar; -} -var x = foo({ - a: 'foo' -}); +function foo(bar) { return bar; } +var x = foo({ a: 'foo' }); diff --git a/tests/baselines/reference/functionOverloads37.js b/tests/baselines/reference/functionOverloads37.js index f9e6130dbd..c4e0d4fd18 100644 --- a/tests/baselines/reference/functionOverloads37.js +++ b/tests/baselines/reference/functionOverloads37.js @@ -6,7 +6,5 @@ var x = foo(); //// [functionOverloads37.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } var x = foo(); diff --git a/tests/baselines/reference/functionOverloads38.js b/tests/baselines/reference/functionOverloads38.js index fa8aa4693b..c973cbe7b6 100644 --- a/tests/baselines/reference/functionOverloads38.js +++ b/tests/baselines/reference/functionOverloads38.js @@ -6,11 +6,5 @@ var x = foo([{a:1}]); //// [functionOverloads38.js] -function foo(bar) { - return bar; -} -var x = foo([ - { - a: 1 - } -]); +function foo(bar) { return bar; } +var x = foo([{ a: 1 }]); diff --git a/tests/baselines/reference/functionOverloads39.js b/tests/baselines/reference/functionOverloads39.js index 218c3e9f69..ad4ded394d 100644 --- a/tests/baselines/reference/functionOverloads39.js +++ b/tests/baselines/reference/functionOverloads39.js @@ -6,11 +6,5 @@ var x = foo([{a:true}]); //// [functionOverloads39.js] -function foo(bar) { - return bar; -} -var x = foo([ - { - a: true - } -]); +function foo(bar) { return bar; } +var x = foo([{ a: true }]); diff --git a/tests/baselines/reference/functionOverloads4.js b/tests/baselines/reference/functionOverloads4.js index b428f6938b..3a1ff2ced3 100644 --- a/tests/baselines/reference/functionOverloads4.js +++ b/tests/baselines/reference/functionOverloads4.js @@ -3,6 +3,4 @@ function foo():number; function foo():string { return "a" } //// [functionOverloads4.js] -function foo() { - return "a"; -} +function foo() { return "a"; } diff --git a/tests/baselines/reference/functionOverloads40.js b/tests/baselines/reference/functionOverloads40.js index 3ad42e1b91..11edff26a4 100644 --- a/tests/baselines/reference/functionOverloads40.js +++ b/tests/baselines/reference/functionOverloads40.js @@ -6,11 +6,5 @@ var x = foo([{a:'bar'}]); //// [functionOverloads40.js] -function foo(bar) { - return bar; -} -var x = foo([ - { - a: 'bar' - } -]); +function foo(bar) { return bar; } +var x = foo([{ a: 'bar' }]); diff --git a/tests/baselines/reference/functionOverloads41.js b/tests/baselines/reference/functionOverloads41.js index 449250dd1c..dd730e25b3 100644 --- a/tests/baselines/reference/functionOverloads41.js +++ b/tests/baselines/reference/functionOverloads41.js @@ -6,9 +6,5 @@ var x = foo([{}]); //// [functionOverloads41.js] -function foo(bar) { - return bar; -} -var x = foo([ - {} -]); +function foo(bar) { return bar; } +var x = foo([{}]); diff --git a/tests/baselines/reference/functionOverloads42.js b/tests/baselines/reference/functionOverloads42.js index 0f87b5139d..979bfa86d6 100644 --- a/tests/baselines/reference/functionOverloads42.js +++ b/tests/baselines/reference/functionOverloads42.js @@ -6,11 +6,5 @@ var x = foo([{a:'s'}]); //// [functionOverloads42.js] -function foo(bar) { - return bar; -} -var x = foo([ - { - a: 's' - } -]); +function foo(bar) { return bar; } +var x = foo([{ a: 's' }]); diff --git a/tests/baselines/reference/functionOverloads5.js b/tests/baselines/reference/functionOverloads5.js index 15507a9fb6..b59154d241 100644 --- a/tests/baselines/reference/functionOverloads5.js +++ b/tests/baselines/reference/functionOverloads5.js @@ -9,7 +9,6 @@ class baz { var baz = (function () { function baz() { } - baz.prototype.foo = function (bar) { - }; + baz.prototype.foo = function (bar) { }; return baz; })(); diff --git a/tests/baselines/reference/functionOverloads6.js b/tests/baselines/reference/functionOverloads6.js index b7f9fd8c1f..2c19b376dc 100644 --- a/tests/baselines/reference/functionOverloads6.js +++ b/tests/baselines/reference/functionOverloads6.js @@ -10,7 +10,6 @@ class foo { var foo = (function () { function foo() { } - foo.fnOverload = function (foo) { - }; + foo.fnOverload = function (foo) { }; return foo; })(); diff --git a/tests/baselines/reference/functionOverloads7.js b/tests/baselines/reference/functionOverloads7.js index 52cac83af7..540abf9eb8 100644 --- a/tests/baselines/reference/functionOverloads7.js +++ b/tests/baselines/reference/functionOverloads7.js @@ -14,9 +14,7 @@ class foo { var foo = (function () { function foo() { } - foo.prototype.bar = function (foo) { - return "foo"; - }; + foo.prototype.bar = function (foo) { return "foo"; }; foo.prototype.n = function () { var foo = this.bar(); foo = this.bar("test"); diff --git a/tests/baselines/reference/functionOverloads8.js b/tests/baselines/reference/functionOverloads8.js index 08c2c0b65a..55539a6165 100644 --- a/tests/baselines/reference/functionOverloads8.js +++ b/tests/baselines/reference/functionOverloads8.js @@ -5,6 +5,4 @@ function foo(foo?:any){ return '' } //// [functionOverloads8.js] -function foo(foo) { - return ''; -} +function foo(foo) { return ''; } diff --git a/tests/baselines/reference/functionOverloads9.js b/tests/baselines/reference/functionOverloads9.js index 53cc0385a5..9d2ae21f4f 100644 --- a/tests/baselines/reference/functionOverloads9.js +++ b/tests/baselines/reference/functionOverloads9.js @@ -5,8 +5,6 @@ var x = foo('foo'); //// [functionOverloads9.js] -function foo(foo) { - return ''; -} +function foo(foo) { return ''; } ; var x = foo('foo'); diff --git a/tests/baselines/reference/functionReturn.js b/tests/baselines/reference/functionReturn.js index bfcd12e2b9..c433eec190 100644 --- a/tests/baselines/reference/functionReturn.js +++ b/tests/baselines/reference/functionReturn.js @@ -15,16 +15,12 @@ function f5(): string { } //// [functionReturn.js] -function f0() { -} +function f0() { } function f1() { var n = f0(); } -function f2() { -} -function f3() { - return; -} +function f2() { } +function f3() { return; } function f4() { return ''; return; diff --git a/tests/baselines/reference/functionType.js b/tests/baselines/reference/functionType.js index c2d6eea784..6e3edc7347 100644 --- a/tests/baselines/reference/functionType.js +++ b/tests/baselines/reference/functionType.js @@ -7,7 +7,6 @@ salt.apply("hello", []); //// [functionType.js] -function salt() { -} +function salt() { } salt.apply("hello", []); (new Function("return 5"))(); diff --git a/tests/baselines/reference/functionTypeArgumentAssignmentCompat.js b/tests/baselines/reference/functionTypeArgumentAssignmentCompat.js index b4ed20e9ed..15080e99d7 100644 --- a/tests/baselines/reference/functionTypeArgumentAssignmentCompat.js +++ b/tests/baselines/reference/functionTypeArgumentAssignmentCompat.js @@ -15,9 +15,7 @@ console.log(s); //// [functionTypeArgumentAssignmentCompat.js] var f; -var g = function () { - return []; -}; +var g = function () { return []; }; f = g; var s = f("str").toUpperCase(); console.log(s); diff --git a/tests/baselines/reference/functionWithAnyReturnTypeAndNoReturnExpression.js b/tests/baselines/reference/functionWithAnyReturnTypeAndNoReturnExpression.js index 6bca14b063..dae960bad6 100644 --- a/tests/baselines/reference/functionWithAnyReturnTypeAndNoReturnExpression.js +++ b/tests/baselines/reference/functionWithAnyReturnTypeAndNoReturnExpression.js @@ -6,9 +6,6 @@ var f3 = (): any => { }; //// [functionWithAnyReturnTypeAndNoReturnExpression.js] // All should be allowed -function f() { -} -var f2 = function () { -}; -var f3 = function () { -}; +function f() { } +var f2 = function () { }; +var f3 = function () { }; diff --git a/tests/baselines/reference/functionWithDefaultParameterWithNoStatements10.js b/tests/baselines/reference/functionWithDefaultParameterWithNoStatements10.js index a72b15a1b9..f312966ea4 100644 --- a/tests/baselines/reference/functionWithDefaultParameterWithNoStatements10.js +++ b/tests/baselines/reference/functionWithDefaultParameterWithNoStatements10.js @@ -6,12 +6,8 @@ function bar(a = [0]) { //// [functionWithDefaultParameterWithNoStatements10.js] function foo(a) { - if (a === void 0) { a = [ - 0 - ]; } + if (a === void 0) { a = [0]; } } function bar(a) { - if (a === void 0) { a = [ - 0 - ]; } + if (a === void 0) { a = [0]; } } diff --git a/tests/baselines/reference/functionWithDefaultParameterWithNoStatements13.js b/tests/baselines/reference/functionWithDefaultParameterWithNoStatements13.js index db98c6353c..7fcbae7254 100644 --- a/tests/baselines/reference/functionWithDefaultParameterWithNoStatements13.js +++ b/tests/baselines/reference/functionWithDefaultParameterWithNoStatements13.js @@ -9,12 +9,8 @@ function bar(a = [1 + 1]) { //// [functionWithDefaultParameterWithNoStatements13.js] var v; function foo(a) { - if (a === void 0) { a = [ - 1 + 1 - ]; } + if (a === void 0) { a = [1 + 1]; } } function bar(a) { - if (a === void 0) { a = [ - 1 + 1 - ]; } + if (a === void 0) { a = [1 + 1]; } } diff --git a/tests/baselines/reference/functionWithMultipleReturnStatements2.js b/tests/baselines/reference/functionWithMultipleReturnStatements2.js index 396c4a8d9c..4674c6db95 100644 --- a/tests/baselines/reference/functionWithMultipleReturnStatements2.js +++ b/tests/baselines/reference/functionWithMultipleReturnStatements2.js @@ -166,22 +166,18 @@ function f10() { // returns number => void function f11() { if (true) { - return function (x) { - }; + return function (x) { }; } else { - return function (x) { - }; + return function (x) { }; } } // returns Object => void function f12() { if (true) { - return function (x) { - }; + return function (x) { }; } else { - return function (x) { - }; + return function (x) { }; } } diff --git a/tests/baselines/reference/functionsMissingReturnStatementsAndExpressions.js b/tests/baselines/reference/functionsMissingReturnStatementsAndExpressions.js index ae8e7d9c91..592a03d715 100644 --- a/tests/baselines/reference/functionsMissingReturnStatementsAndExpressions.js +++ b/tests/baselines/reference/functionsMissingReturnStatementsAndExpressions.js @@ -228,7 +228,8 @@ var C = (function () { // Not fine, since we can *only* consist of a single throw statement // if no return statements are present but we are a get accessor. throw null; - throw undefined.; + throw undefined. + ; }, enumerable: true, configurable: true diff --git a/tests/baselines/reference/functionsWithModifiersInBlocks1.js b/tests/baselines/reference/functionsWithModifiersInBlocks1.js index 1d381bccfe..757fe50974 100644 --- a/tests/baselines/reference/functionsWithModifiersInBlocks1.js +++ b/tests/baselines/reference/functionsWithModifiersInBlocks1.js @@ -7,7 +7,6 @@ //// [functionsWithModifiersInBlocks1.js] { - function f() { - } + function f() { } exports.f = f; } diff --git a/tests/baselines/reference/funduleSplitAcrossFiles.js b/tests/baselines/reference/funduleSplitAcrossFiles.js index 330fbcdec7..bb59338a63 100644 --- a/tests/baselines/reference/funduleSplitAcrossFiles.js +++ b/tests/baselines/reference/funduleSplitAcrossFiles.js @@ -10,8 +10,7 @@ module D { D.y; //// [funduleSplitAcrossFiles_function.js] -function D() { -} +function D() { } //// [funduleSplitAcrossFiles_module.js] var D; (function (D) { diff --git a/tests/baselines/reference/fuzzy.js b/tests/baselines/reference/fuzzy.js index 4729b59e2c..b98a9ced10 100644 --- a/tests/baselines/reference/fuzzy.js +++ b/tests/baselines/reference/fuzzy.js @@ -38,20 +38,13 @@ var M; this.x = x; } C.prototype.works = function () { - return ({ - anything: 1 - }); + return ({ anything: 1 }); }; C.prototype.doesntWork = function () { - return { - anything: 1, - oneI: this - }; + return { anything: 1, oneI: this }; }; C.prototype.worksToo = function () { - return ({ - oneI: this - }); + return ({ oneI: this }); }; return C; })(); diff --git a/tests/baselines/reference/generatedContextualTyping.js b/tests/baselines/reference/generatedContextualTyping.js index ec79d3a752..a88929669f 100644 --- a/tests/baselines/reference/generatedContextualTyping.js +++ b/tests/baselines/reference/generatedContextualTyping.js @@ -381,2973 +381,1072 @@ var Derived2 = (function (_super) { return Derived2; })(Base); var b = new Base(), d1 = new Derived1(), d2 = new Derived2(); -var x1 = function () { - return [ - d1, - d2 - ]; -}; -var x2 = function () { - return [ - d1, - d2 - ]; -}; -var x3 = function named() { - return [ - d1, - d2 - ]; -}; -var x4 = function () { - return [ - d1, - d2 - ]; -}; -var x5 = function () { - return [ - d1, - d2 - ]; -}; -var x6 = function named() { - return [ - d1, - d2 - ]; -}; -var x7 = [ - d1, - d2 -]; -var x8 = [ - d1, - d2 -]; -var x9 = [ - d1, - d2 -]; -var x10 = { - n: [ - d1, - d2 - ] -}; -var x11 = function (n) { - var n; - return null; -}; -var x12 = { - func: function (n) { - return [ - d1, - d2 - ]; - } -}; +var x1 = function () { return [d1, d2]; }; +var x2 = function () { return [d1, d2]; }; +var x3 = function named() { return [d1, d2]; }; +var x4 = function () { return [d1, d2]; }; +var x5 = function () { return [d1, d2]; }; +var x6 = function named() { return [d1, d2]; }; +var x7 = [d1, d2]; +var x8 = [d1, d2]; +var x9 = [d1, d2]; +var x10 = { n: [d1, d2] }; +var x11 = function (n) { var n; return null; }; +var x12 = { func: function (n) { return [d1, d2]; } }; var x13 = (function () { function x13() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x13; })(); var x14 = (function () { function x14() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x14; })(); var x15 = (function () { function x15() { - this.member = function named() { - return [ - d1, - d2 - ]; - }; + this.member = function named() { return [d1, d2]; }; } return x15; })(); var x16 = (function () { function x16() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x16; })(); var x17 = (function () { function x17() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x17; })(); var x18 = (function () { function x18() { - this.member = function named() { - return [ - d1, - d2 - ]; - }; + this.member = function named() { return [d1, d2]; }; } return x18; })(); var x19 = (function () { function x19() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x19; })(); var x20 = (function () { function x20() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x20; })(); var x21 = (function () { function x21() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x21; })(); var x22 = (function () { function x22() { - this.member = { - n: [ - d1, - d2 - ] - }; + this.member = { n: [d1, d2] }; } return x22; })(); var x23 = (function () { function x23() { - this.member = function (n) { - var n; - return null; - }; + this.member = function (n) { var n; return null; }; } return x23; })(); var x24 = (function () { function x24() { - this.member = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; + this.member = { func: function (n) { return [d1, d2]; } }; } return x24; })(); var x25 = (function () { function x25() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x25; })(); var x26 = (function () { function x26() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x26; })(); var x27 = (function () { function x27() { - this.member = function named() { - return [ - d1, - d2 - ]; - }; + this.member = function named() { return [d1, d2]; }; } return x27; })(); var x28 = (function () { function x28() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x28; })(); var x29 = (function () { function x29() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x29; })(); var x30 = (function () { function x30() { - this.member = function named() { - return [ - d1, - d2 - ]; - }; + this.member = function named() { return [d1, d2]; }; } return x30; })(); var x31 = (function () { function x31() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x31; })(); var x32 = (function () { function x32() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x32; })(); var x33 = (function () { function x33() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x33; })(); var x34 = (function () { function x34() { - this.member = { - n: [ - d1, - d2 - ] - }; + this.member = { n: [d1, d2] }; } return x34; })(); var x35 = (function () { function x35() { - this.member = function (n) { - var n; - return null; - }; + this.member = function (n) { var n; return null; }; } return x35; })(); var x36 = (function () { function x36() { - this.member = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; + this.member = { func: function (n) { return [d1, d2]; } }; } return x36; })(); var x37 = (function () { function x37() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x37; })(); var x38 = (function () { function x38() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x38; })(); var x39 = (function () { function x39() { - this.member = function named() { - return [ - d1, - d2 - ]; - }; + this.member = function named() { return [d1, d2]; }; } return x39; })(); var x40 = (function () { function x40() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x40; })(); var x41 = (function () { function x41() { - this.member = function () { - return [ - d1, - d2 - ]; - }; + this.member = function () { return [d1, d2]; }; } return x41; })(); var x42 = (function () { function x42() { - this.member = function named() { - return [ - d1, - d2 - ]; - }; + this.member = function named() { return [d1, d2]; }; } return x42; })(); var x43 = (function () { function x43() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x43; })(); var x44 = (function () { function x44() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x44; })(); var x45 = (function () { function x45() { - this.member = [ - d1, - d2 - ]; + this.member = [d1, d2]; } return x45; })(); var x46 = (function () { function x46() { - this.member = { - n: [ - d1, - d2 - ] - }; + this.member = { n: [d1, d2] }; } return x46; })(); var x47 = (function () { function x47() { - this.member = function (n) { - var n; - return null; - }; + this.member = function (n) { var n; return null; }; } return x47; })(); var x48 = (function () { function x48() { - this.member = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; + this.member = { func: function (n) { return [d1, d2]; } }; } return x48; })(); var x49 = (function () { function x49() { } - x49.member = function () { - return [ - d1, - d2 - ]; - }; + x49.member = function () { return [d1, d2]; }; return x49; })(); var x50 = (function () { function x50() { } - x50.member = function () { - return [ - d1, - d2 - ]; - }; + x50.member = function () { return [d1, d2]; }; return x50; })(); var x51 = (function () { function x51() { } - x51.member = function named() { - return [ - d1, - d2 - ]; - }; + x51.member = function named() { return [d1, d2]; }; return x51; })(); var x52 = (function () { function x52() { } - x52.member = function () { - return [ - d1, - d2 - ]; - }; + x52.member = function () { return [d1, d2]; }; return x52; })(); var x53 = (function () { function x53() { } - x53.member = function () { - return [ - d1, - d2 - ]; - }; + x53.member = function () { return [d1, d2]; }; return x53; })(); var x54 = (function () { function x54() { } - x54.member = function named() { - return [ - d1, - d2 - ]; - }; + x54.member = function named() { return [d1, d2]; }; return x54; })(); var x55 = (function () { function x55() { } - x55.member = [ - d1, - d2 - ]; + x55.member = [d1, d2]; return x55; })(); var x56 = (function () { function x56() { } - x56.member = [ - d1, - d2 - ]; + x56.member = [d1, d2]; return x56; })(); var x57 = (function () { function x57() { } - x57.member = [ - d1, - d2 - ]; + x57.member = [d1, d2]; return x57; })(); var x58 = (function () { function x58() { } - x58.member = { - n: [ - d1, - d2 - ] - }; + x58.member = { n: [d1, d2] }; return x58; })(); var x59 = (function () { function x59() { } - x59.member = function (n) { - var n; - return null; - }; + x59.member = function (n) { var n; return null; }; return x59; })(); var x60 = (function () { function x60() { } - x60.member = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; + x60.member = { func: function (n) { return [d1, d2]; } }; return x60; })(); var x61 = (function () { function x61() { } - x61.member = function () { - return [ - d1, - d2 - ]; - }; + x61.member = function () { return [d1, d2]; }; return x61; })(); var x62 = (function () { function x62() { } - x62.member = function () { - return [ - d1, - d2 - ]; - }; + x62.member = function () { return [d1, d2]; }; return x62; })(); var x63 = (function () { function x63() { } - x63.member = function named() { - return [ - d1, - d2 - ]; - }; + x63.member = function named() { return [d1, d2]; }; return x63; })(); var x64 = (function () { function x64() { } - x64.member = function () { - return [ - d1, - d2 - ]; - }; + x64.member = function () { return [d1, d2]; }; return x64; })(); var x65 = (function () { function x65() { } - x65.member = function () { - return [ - d1, - d2 - ]; - }; + x65.member = function () { return [d1, d2]; }; return x65; })(); var x66 = (function () { function x66() { } - x66.member = function named() { - return [ - d1, - d2 - ]; - }; + x66.member = function named() { return [d1, d2]; }; return x66; })(); var x67 = (function () { function x67() { } - x67.member = [ - d1, - d2 - ]; + x67.member = [d1, d2]; return x67; })(); var x68 = (function () { function x68() { } - x68.member = [ - d1, - d2 - ]; + x68.member = [d1, d2]; return x68; })(); var x69 = (function () { function x69() { } - x69.member = [ - d1, - d2 - ]; + x69.member = [d1, d2]; return x69; })(); var x70 = (function () { function x70() { } - x70.member = { - n: [ - d1, - d2 - ] - }; + x70.member = { n: [d1, d2] }; return x70; })(); var x71 = (function () { function x71() { } - x71.member = function (n) { - var n; - return null; - }; + x71.member = function (n) { var n; return null; }; return x71; })(); var x72 = (function () { function x72() { } - x72.member = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; + x72.member = { func: function (n) { return [d1, d2]; } }; return x72; })(); var x73 = (function () { function x73() { } - x73.member = function () { - return [ - d1, - d2 - ]; - }; + x73.member = function () { return [d1, d2]; }; return x73; })(); var x74 = (function () { function x74() { } - x74.member = function () { - return [ - d1, - d2 - ]; - }; + x74.member = function () { return [d1, d2]; }; return x74; })(); var x75 = (function () { function x75() { } - x75.member = function named() { - return [ - d1, - d2 - ]; - }; + x75.member = function named() { return [d1, d2]; }; return x75; })(); var x76 = (function () { function x76() { } - x76.member = function () { - return [ - d1, - d2 - ]; - }; + x76.member = function () { return [d1, d2]; }; return x76; })(); var x77 = (function () { function x77() { } - x77.member = function () { - return [ - d1, - d2 - ]; - }; + x77.member = function () { return [d1, d2]; }; return x77; })(); var x78 = (function () { function x78() { } - x78.member = function named() { - return [ - d1, - d2 - ]; - }; + x78.member = function named() { return [d1, d2]; }; return x78; })(); var x79 = (function () { function x79() { } - x79.member = [ - d1, - d2 - ]; + x79.member = [d1, d2]; return x79; })(); var x80 = (function () { function x80() { } - x80.member = [ - d1, - d2 - ]; + x80.member = [d1, d2]; return x80; })(); var x81 = (function () { function x81() { } - x81.member = [ - d1, - d2 - ]; + x81.member = [d1, d2]; return x81; })(); var x82 = (function () { function x82() { } - x82.member = { - n: [ - d1, - d2 - ] - }; + x82.member = { n: [d1, d2] }; return x82; })(); var x83 = (function () { function x83() { } - x83.member = function (n) { - var n; - return null; - }; + x83.member = function (n) { var n; return null; }; return x83; })(); var x84 = (function () { function x84() { } - x84.member = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; + x84.member = { func: function (n) { return [d1, d2]; } }; return x84; })(); var x85 = (function () { function x85(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } } return x85; })(); var x86 = (function () { function x86(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } } return x86; })(); var x87 = (function () { function x87(parm) { - if (parm === void 0) { parm = function named() { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function named() { return [d1, d2]; }; } } return x87; })(); var x88 = (function () { function x88(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } } return x88; })(); var x89 = (function () { function x89(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } } return x89; })(); var x90 = (function () { function x90(parm) { - if (parm === void 0) { parm = function named() { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function named() { return [d1, d2]; }; } } return x90; })(); var x91 = (function () { function x91(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } } return x91; })(); var x92 = (function () { function x92(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } } return x92; })(); var x93 = (function () { function x93(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } } return x93; })(); var x94 = (function () { function x94(parm) { - if (parm === void 0) { parm = { - n: [ - d1, - d2 - ] - }; } + if (parm === void 0) { parm = { n: [d1, d2] }; } } return x94; })(); var x95 = (function () { function x95(parm) { - if (parm === void 0) { parm = function (n) { - var n; - return null; - }; } + if (parm === void 0) { parm = function (n) { var n; return null; }; } } return x95; })(); var x96 = (function () { function x96(parm) { - if (parm === void 0) { parm = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; } + if (parm === void 0) { parm = { func: function (n) { return [d1, d2]; } }; } } return x96; })(); var x97 = (function () { function x97(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } this.parm = parm; } return x97; })(); var x98 = (function () { function x98(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } this.parm = parm; } return x98; })(); var x99 = (function () { function x99(parm) { - if (parm === void 0) { parm = function named() { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function named() { return [d1, d2]; }; } this.parm = parm; } return x99; })(); var x100 = (function () { function x100(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } this.parm = parm; } return x100; })(); var x101 = (function () { function x101(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } this.parm = parm; } return x101; })(); var x102 = (function () { function x102(parm) { - if (parm === void 0) { parm = function named() { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function named() { return [d1, d2]; }; } this.parm = parm; } return x102; })(); var x103 = (function () { function x103(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } this.parm = parm; } return x103; })(); var x104 = (function () { function x104(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } this.parm = parm; } return x104; })(); var x105 = (function () { function x105(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } this.parm = parm; } return x105; })(); var x106 = (function () { function x106(parm) { - if (parm === void 0) { parm = { - n: [ - d1, - d2 - ] - }; } + if (parm === void 0) { parm = { n: [d1, d2] }; } this.parm = parm; } return x106; })(); var x107 = (function () { function x107(parm) { - if (parm === void 0) { parm = function (n) { - var n; - return null; - }; } + if (parm === void 0) { parm = function (n) { var n; return null; }; } this.parm = parm; } return x107; })(); var x108 = (function () { function x108(parm) { - if (parm === void 0) { parm = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; } + if (parm === void 0) { parm = { func: function (n) { return [d1, d2]; } }; } this.parm = parm; } return x108; })(); var x109 = (function () { function x109(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } this.parm = parm; } return x109; })(); var x110 = (function () { function x110(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } this.parm = parm; } return x110; })(); var x111 = (function () { function x111(parm) { - if (parm === void 0) { parm = function named() { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function named() { return [d1, d2]; }; } this.parm = parm; } return x111; })(); var x112 = (function () { function x112(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } this.parm = parm; } return x112; })(); var x113 = (function () { function x113(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } this.parm = parm; } return x113; })(); var x114 = (function () { function x114(parm) { - if (parm === void 0) { parm = function named() { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function named() { return [d1, d2]; }; } this.parm = parm; } return x114; })(); var x115 = (function () { function x115(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } this.parm = parm; } return x115; })(); var x116 = (function () { function x116(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } this.parm = parm; } return x116; })(); var x117 = (function () { function x117(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } this.parm = parm; } return x117; })(); var x118 = (function () { function x118(parm) { - if (parm === void 0) { parm = { - n: [ - d1, - d2 - ] - }; } + if (parm === void 0) { parm = { n: [d1, d2] }; } this.parm = parm; } return x118; })(); var x119 = (function () { function x119(parm) { - if (parm === void 0) { parm = function (n) { - var n; - return null; - }; } + if (parm === void 0) { parm = function (n) { var n; return null; }; } this.parm = parm; } return x119; })(); var x120 = (function () { function x120(parm) { - if (parm === void 0) { parm = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; } + if (parm === void 0) { parm = { func: function (n) { return [d1, d2]; } }; } this.parm = parm; } return x120; })(); function x121(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } } function x122(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } } function x123(parm) { - if (parm === void 0) { parm = function named() { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function named() { return [d1, d2]; }; } } function x124(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } } function x125(parm) { - if (parm === void 0) { parm = function () { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function () { return [d1, d2]; }; } } function x126(parm) { - if (parm === void 0) { parm = function named() { - return [ - d1, - d2 - ]; - }; } + if (parm === void 0) { parm = function named() { return [d1, d2]; }; } } function x127(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } } function x128(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } } function x129(parm) { - if (parm === void 0) { parm = [ - d1, - d2 - ]; } + if (parm === void 0) { parm = [d1, d2]; } } function x130(parm) { - if (parm === void 0) { parm = { - n: [ - d1, - d2 - ] - }; } + if (parm === void 0) { parm = { n: [d1, d2] }; } } function x131(parm) { - if (parm === void 0) { parm = function (n) { - var n; - return null; - }; } + if (parm === void 0) { parm = function (n) { var n; return null; }; } } function x132(parm) { - if (parm === void 0) { parm = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; } + if (parm === void 0) { parm = { func: function (n) { return [d1, d2]; } }; } } -function x133() { - return function () { - return [ - d1, - d2 - ]; - }; -} -function x134() { - return function () { - return [ - d1, - d2 - ]; - }; -} -function x135() { - return function named() { - return [ - d1, - d2 - ]; - }; -} -function x136() { - return function () { - return [ - d1, - d2 - ]; - }; -} -function x137() { - return function () { - return [ - d1, - d2 - ]; - }; -} -function x138() { - return function named() { - return [ - d1, - d2 - ]; - }; -} -function x139() { - return [ - d1, - d2 - ]; -} -function x140() { - return [ - d1, - d2 - ]; -} -function x141() { - return [ - d1, - d2 - ]; -} -function x142() { - return { - n: [ - d1, - d2 - ] - }; -} -function x143() { - return function (n) { - var n; - return null; - }; -} -function x144() { - return { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; -} -function x145() { - return function () { - return [ - d1, - d2 - ]; - }; - return function () { - return [ - d1, - d2 - ]; - }; -} -function x146() { - return function () { - return [ - d1, - d2 - ]; - }; - return function () { - return [ - d1, - d2 - ]; - }; -} -function x147() { - return function named() { - return [ - d1, - d2 - ]; - }; - return function named() { - return [ - d1, - d2 - ]; - }; -} -function x148() { - return function () { - return [ - d1, - d2 - ]; - }; - return function () { - return [ - d1, - d2 - ]; - }; -} -function x149() { - return function () { - return [ - d1, - d2 - ]; - }; - return function () { - return [ - d1, - d2 - ]; - }; -} -function x150() { - return function named() { - return [ - d1, - d2 - ]; - }; - return function named() { - return [ - d1, - d2 - ]; - }; -} -function x151() { - return [ - d1, - d2 - ]; - return [ - d1, - d2 - ]; -} -function x152() { - return [ - d1, - d2 - ]; - return [ - d1, - d2 - ]; -} -function x153() { - return [ - d1, - d2 - ]; - return [ - d1, - d2 - ]; -} -function x154() { - return { - n: [ - d1, - d2 - ] - }; - return { - n: [ - d1, - d2 - ] - }; -} -function x155() { - return function (n) { - var n; - return null; - }; - return function (n) { - var n; - return null; - }; -} -function x156() { - return { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; - return { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; -} -var x157 = function () { - return function () { - return [ - d1, - d2 - ]; - }; -}; -var x158 = function () { - return function () { - return [ - d1, - d2 - ]; - }; -}; -var x159 = function () { - return function named() { - return [ - d1, - d2 - ]; - }; -}; -var x160 = function () { - return function () { - return [ - d1, - d2 - ]; - }; -}; -var x161 = function () { - return function () { - return [ - d1, - d2 - ]; - }; -}; -var x162 = function () { - return function named() { - return [ - d1, - d2 - ]; - }; -}; -var x163 = function () { - return [ - d1, - d2 - ]; -}; -var x164 = function () { - return [ - d1, - d2 - ]; -}; -var x165 = function () { - return [ - d1, - d2 - ]; -}; -var x166 = function () { - return { - n: [ - d1, - d2 - ] - }; -}; -var x167 = function () { - return function (n) { - var n; - return null; - }; -}; -var x168 = function () { - return { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; -}; -var x169 = function () { - return function () { - return [ - d1, - d2 - ]; - }; -}; -var x170 = function () { - return function () { - return [ - d1, - d2 - ]; - }; -}; -var x171 = function () { - return function named() { - return [ - d1, - d2 - ]; - }; -}; -var x172 = function () { - return function () { - return [ - d1, - d2 - ]; - }; -}; -var x173 = function () { - return function () { - return [ - d1, - d2 - ]; - }; -}; -var x174 = function () { - return function named() { - return [ - d1, - d2 - ]; - }; -}; -var x175 = function () { - return [ - d1, - d2 - ]; -}; -var x176 = function () { - return [ - d1, - d2 - ]; -}; -var x177 = function () { - return [ - d1, - d2 - ]; -}; -var x178 = function () { - return { - n: [ - d1, - d2 - ] - }; -}; -var x179 = function () { - return function (n) { - var n; - return null; - }; -}; -var x180 = function () { - return { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; -}; +function x133() { return function () { return [d1, d2]; }; } +function x134() { return function () { return [d1, d2]; }; } +function x135() { return function named() { return [d1, d2]; }; } +function x136() { return function () { return [d1, d2]; }; } +function x137() { return function () { return [d1, d2]; }; } +function x138() { return function named() { return [d1, d2]; }; } +function x139() { return [d1, d2]; } +function x140() { return [d1, d2]; } +function x141() { return [d1, d2]; } +function x142() { return { n: [d1, d2] }; } +function x143() { return function (n) { var n; return null; }; } +function x144() { return { func: function (n) { return [d1, d2]; } }; } +function x145() { return function () { return [d1, d2]; }; return function () { return [d1, d2]; }; } +function x146() { return function () { return [d1, d2]; }; return function () { return [d1, d2]; }; } +function x147() { return function named() { return [d1, d2]; }; return function named() { return [d1, d2]; }; } +function x148() { return function () { return [d1, d2]; }; return function () { return [d1, d2]; }; } +function x149() { return function () { return [d1, d2]; }; return function () { return [d1, d2]; }; } +function x150() { return function named() { return [d1, d2]; }; return function named() { return [d1, d2]; }; } +function x151() { return [d1, d2]; return [d1, d2]; } +function x152() { return [d1, d2]; return [d1, d2]; } +function x153() { return [d1, d2]; return [d1, d2]; } +function x154() { return { n: [d1, d2] }; return { n: [d1, d2] }; } +function x155() { return function (n) { var n; return null; }; return function (n) { var n; return null; }; } +function x156() { return { func: function (n) { return [d1, d2]; } }; return { func: function (n) { return [d1, d2]; } }; } +var x157 = function () { return function () { return [d1, d2]; }; }; +var x158 = function () { return function () { return [d1, d2]; }; }; +var x159 = function () { return function named() { return [d1, d2]; }; }; +var x160 = function () { return function () { return [d1, d2]; }; }; +var x161 = function () { return function () { return [d1, d2]; }; }; +var x162 = function () { return function named() { return [d1, d2]; }; }; +var x163 = function () { return [d1, d2]; }; +var x164 = function () { return [d1, d2]; }; +var x165 = function () { return [d1, d2]; }; +var x166 = function () { return { n: [d1, d2] }; }; +var x167 = function () { return function (n) { var n; return null; }; }; +var x168 = function () { return { func: function (n) { return [d1, d2]; } }; }; +var x169 = function () { return function () { return [d1, d2]; }; }; +var x170 = function () { return function () { return [d1, d2]; }; }; +var x171 = function () { return function named() { return [d1, d2]; }; }; +var x172 = function () { return function () { return [d1, d2]; }; }; +var x173 = function () { return function () { return [d1, d2]; }; }; +var x174 = function () { return function named() { return [d1, d2]; }; }; +var x175 = function () { return [d1, d2]; }; +var x176 = function () { return [d1, d2]; }; +var x177 = function () { return [d1, d2]; }; +var x178 = function () { return { n: [d1, d2] }; }; +var x179 = function () { return function (n) { var n; return null; }; }; +var x180 = function () { return { func: function (n) { return [d1, d2]; } }; }; var x181; (function (x181) { - var t = function () { - return [ - d1, - d2 - ]; - }; + var t = function () { return [d1, d2]; }; })(x181 || (x181 = {})); var x182; (function (x182) { - var t = function () { - return [ - d1, - d2 - ]; - }; + var t = function () { return [d1, d2]; }; })(x182 || (x182 = {})); var x183; (function (x183) { - var t = function named() { - return [ - d1, - d2 - ]; - }; + var t = function named() { return [d1, d2]; }; })(x183 || (x183 = {})); var x184; (function (x184) { - var t = function () { - return [ - d1, - d2 - ]; - }; + var t = function () { return [d1, d2]; }; })(x184 || (x184 = {})); var x185; (function (x185) { - var t = function () { - return [ - d1, - d2 - ]; - }; + var t = function () { return [d1, d2]; }; })(x185 || (x185 = {})); var x186; (function (x186) { - var t = function named() { - return [ - d1, - d2 - ]; - }; + var t = function named() { return [d1, d2]; }; })(x186 || (x186 = {})); var x187; (function (x187) { - var t = [ - d1, - d2 - ]; + var t = [d1, d2]; })(x187 || (x187 = {})); var x188; (function (x188) { - var t = [ - d1, - d2 - ]; + var t = [d1, d2]; })(x188 || (x188 = {})); var x189; (function (x189) { - var t = [ - d1, - d2 - ]; + var t = [d1, d2]; })(x189 || (x189 = {})); var x190; (function (x190) { - var t = { - n: [ - d1, - d2 - ] - }; + var t = { n: [d1, d2] }; })(x190 || (x190 = {})); var x191; (function (x191) { - var t = function (n) { - var n; - return null; - }; + var t = function (n) { var n; return null; }; })(x191 || (x191 = {})); var x192; (function (x192) { - var t = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; + var t = { func: function (n) { return [d1, d2]; } }; })(x192 || (x192 = {})); var x193; (function (x193) { - x193.t = function () { - return [ - d1, - d2 - ]; - }; + x193.t = function () { return [d1, d2]; }; })(x193 || (x193 = {})); var x194; (function (x194) { - x194.t = function () { - return [ - d1, - d2 - ]; - }; + x194.t = function () { return [d1, d2]; }; })(x194 || (x194 = {})); var x195; (function (x195) { - x195.t = function named() { - return [ - d1, - d2 - ]; - }; + x195.t = function named() { return [d1, d2]; }; })(x195 || (x195 = {})); var x196; (function (x196) { - x196.t = function () { - return [ - d1, - d2 - ]; - }; + x196.t = function () { return [d1, d2]; }; })(x196 || (x196 = {})); var x197; (function (x197) { - x197.t = function () { - return [ - d1, - d2 - ]; - }; + x197.t = function () { return [d1, d2]; }; })(x197 || (x197 = {})); var x198; (function (x198) { - x198.t = function named() { - return [ - d1, - d2 - ]; - }; + x198.t = function named() { return [d1, d2]; }; })(x198 || (x198 = {})); var x199; (function (x199) { - x199.t = [ - d1, - d2 - ]; + x199.t = [d1, d2]; })(x199 || (x199 = {})); var x200; (function (x200) { - x200.t = [ - d1, - d2 - ]; + x200.t = [d1, d2]; })(x200 || (x200 = {})); var x201; (function (x201) { - x201.t = [ - d1, - d2 - ]; + x201.t = [d1, d2]; })(x201 || (x201 = {})); var x202; (function (x202) { - x202.t = { - n: [ - d1, - d2 - ] - }; + x202.t = { n: [d1, d2] }; })(x202 || (x202 = {})); var x203; (function (x203) { - x203.t = function (n) { - var n; - return null; - }; + x203.t = function (n) { var n; return null; }; })(x203 || (x203 = {})); var x204; (function (x204) { - x204.t = { - func: function (n) { - return [ - d1, - d2 - ]; - } - }; + x204.t = { func: function (n) { return [d1, d2]; } }; })(x204 || (x204 = {})); -var x206 = function () { - return [ - d1, - d2 - ]; -}; -var x207 = function named() { - return [ - d1, - d2 - ]; -}; -var x209 = function () { - return [ - d1, - d2 - ]; -}; -var x210 = function named() { - return [ - d1, - d2 - ]; -}; -var x211 = [ - d1, - d2 -]; -var x212 = [ - d1, - d2 -]; -var x213 = [ - d1, - d2 -]; -var x214 = { - n: [ - d1, - d2 - ] -}; -var x216 = { - func: function (n) { - return [ - d1, - d2 - ]; - } -}; -var x217 = undefined || function () { - return [ - d1, - d2 - ]; -}; -var x218 = undefined || function named() { - return [ - d1, - d2 - ]; -}; -var x219 = undefined || function () { - return [ - d1, - d2 - ]; -}; -var x220 = undefined || function named() { - return [ - d1, - d2 - ]; -}; -var x221 = undefined || [ - d1, - d2 -]; -var x222 = undefined || [ - d1, - d2 -]; -var x223 = undefined || [ - d1, - d2 -]; -var x224 = undefined || { - n: [ - d1, - d2 - ] -}; +var x206 = function () { return [d1, d2]; }; +var x207 = function named() { return [d1, d2]; }; +var x209 = function () { return [d1, d2]; }; +var x210 = function named() { return [d1, d2]; }; +var x211 = [d1, d2]; +var x212 = [d1, d2]; +var x213 = [d1, d2]; +var x214 = { n: [d1, d2] }; +var x216 = { func: function (n) { return [d1, d2]; } }; +var x217 = undefined || function () { return [d1, d2]; }; +var x218 = undefined || function named() { return [d1, d2]; }; +var x219 = undefined || function () { return [d1, d2]; }; +var x220 = undefined || function named() { return [d1, d2]; }; +var x221 = undefined || [d1, d2]; +var x222 = undefined || [d1, d2]; +var x223 = undefined || [d1, d2]; +var x224 = undefined || { n: [d1, d2] }; var x225; -x225 = function () { - return [ - d1, - d2 - ]; -}; +x225 = function () { return [d1, d2]; }; var x226; -x226 = function () { - return [ - d1, - d2 - ]; -}; +x226 = function () { return [d1, d2]; }; var x227; -x227 = function named() { - return [ - d1, - d2 - ]; -}; +x227 = function named() { return [d1, d2]; }; var x228; -x228 = function () { - return [ - d1, - d2 - ]; -}; +x228 = function () { return [d1, d2]; }; var x229; -x229 = function () { - return [ - d1, - d2 - ]; -}; +x229 = function () { return [d1, d2]; }; var x230; -x230 = function named() { - return [ - d1, - d2 - ]; -}; +x230 = function named() { return [d1, d2]; }; var x231; -x231 = [ - d1, - d2 -]; +x231 = [d1, d2]; var x232; -x232 = [ - d1, - d2 -]; +x232 = [d1, d2]; var x233; -x233 = [ - d1, - d2 -]; +x233 = [d1, d2]; var x234; -x234 = { - n: [ - d1, - d2 - ] -}; +x234 = { n: [d1, d2] }; var x235; -x235 = function (n) { - var n; - return null; -}; +x235 = function (n) { var n; return null; }; var x236; -x236 = { - func: function (n) { - return [ - d1, - d2 - ]; - } -}; -var x237 = { - n: function () { - return [ - d1, - d2 - ]; - } -}; -var x238 = { - n: function () { - return [ - d1, - d2 - ]; - } -}; -var x239 = { - n: function named() { - return [ - d1, - d2 - ]; - } -}; -var x240 = { - n: function () { - return [ - d1, - d2 - ]; - } -}; -var x241 = { - n: function () { - return [ - d1, - d2 - ]; - } -}; -var x242 = { - n: function named() { - return [ - d1, - d2 - ]; - } -}; -var x243 = { - n: [ - d1, - d2 - ] -}; -var x244 = { - n: [ - d1, - d2 - ] -}; -var x245 = { - n: [ - d1, - d2 - ] -}; -var x246 = { - n: { - n: [ - d1, - d2 - ] - } -}; -var x247 = { - n: function (n) { - var n; - return null; - } -}; -var x248 = { - n: { - func: function (n) { - return [ - d1, - d2 - ]; - } - } -}; -var x252 = [ - function () { - return [ - d1, - d2 - ]; - } -]; -var x253 = [ - function () { - return [ - d1, - d2 - ]; - } -]; -var x254 = [ - function named() { - return [ - d1, - d2 - ]; - } -]; -var x255 = [ - [ - d1, - d2 - ] -]; -var x256 = [ - [ - d1, - d2 - ] -]; -var x257 = [ - [ - d1, - d2 - ] -]; -var x258 = [ - { - n: [ - d1, - d2 - ] - } -]; -var x260 = [ - { - func: function (n) { - return [ - d1, - d2 - ]; - } - } -]; -var x261 = function () { - return [ - d1, - d2 - ]; -} || undefined; -var x262 = function named() { - return [ - d1, - d2 - ]; -} || undefined; -var x263 = function () { - return [ - d1, - d2 - ]; -} || undefined; -var x264 = function named() { - return [ - d1, - d2 - ]; -} || undefined; -var x265 = [ - d1, - d2 -] || undefined; -var x266 = [ - d1, - d2 -] || undefined; -var x267 = [ - d1, - d2 -] || undefined; -var x268 = { - n: [ - d1, - d2 - ] -} || undefined; -var x269 = undefined || function () { - return [ - d1, - d2 - ]; -}; -var x270 = undefined || function named() { - return [ - d1, - d2 - ]; -}; -var x271 = undefined || function () { - return [ - d1, - d2 - ]; -}; -var x272 = undefined || function named() { - return [ - d1, - d2 - ]; -}; -var x273 = undefined || [ - d1, - d2 -]; -var x274 = undefined || [ - d1, - d2 -]; -var x275 = undefined || [ - d1, - d2 -]; -var x276 = undefined || { - n: [ - d1, - d2 - ] -}; -var x277 = function () { - return [ - d1, - d2 - ]; -} || function () { - return [ - d1, - d2 - ]; -}; -var x278 = function named() { - return [ - d1, - d2 - ]; -} || function named() { - return [ - d1, - d2 - ]; -}; -var x279 = function () { - return [ - d1, - d2 - ]; -} || function () { - return [ - d1, - d2 - ]; -}; -var x280 = function named() { - return [ - d1, - d2 - ]; -} || function named() { - return [ - d1, - d2 - ]; -}; -var x281 = [ - d1, - d2 -] || [ - d1, - d2 -]; -var x282 = [ - d1, - d2 -] || [ - d1, - d2 -]; -var x283 = [ - d1, - d2 -] || [ - d1, - d2 -]; -var x284 = { - n: [ - d1, - d2 - ] -} || { - n: [ - d1, - d2 - ] -}; -var x285 = true ? function () { - return [ - d1, - d2 - ]; -} : function () { - return [ - d1, - d2 - ]; -}; -var x286 = true ? function () { - return [ - d1, - d2 - ]; -} : function () { - return [ - d1, - d2 - ]; -}; -var x287 = true ? function named() { - return [ - d1, - d2 - ]; -} : function named() { - return [ - d1, - d2 - ]; -}; -var x288 = true ? function () { - return [ - d1, - d2 - ]; -} : function () { - return [ - d1, - d2 - ]; -}; -var x289 = true ? function () { - return [ - d1, - d2 - ]; -} : function () { - return [ - d1, - d2 - ]; -}; -var x290 = true ? function named() { - return [ - d1, - d2 - ]; -} : function named() { - return [ - d1, - d2 - ]; -}; -var x291 = true ? [ - d1, - d2 -] : [ - d1, - d2 -]; -var x292 = true ? [ - d1, - d2 -] : [ - d1, - d2 -]; -var x293 = true ? [ - d1, - d2 -] : [ - d1, - d2 -]; -var x294 = true ? { - n: [ - d1, - d2 - ] -} : { - n: [ - d1, - d2 - ] -}; -var x295 = true ? function (n) { - var n; - return null; -} : function (n) { - var n; - return null; -}; -var x296 = true ? { - func: function (n) { - return [ - d1, - d2 - ]; - } -} : { - func: function (n) { - return [ - d1, - d2 - ]; - } -}; -var x297 = true ? undefined : function () { - return [ - d1, - d2 - ]; -}; -var x298 = true ? undefined : function () { - return [ - d1, - d2 - ]; -}; -var x299 = true ? undefined : function named() { - return [ - d1, - d2 - ]; -}; -var x300 = true ? undefined : function () { - return [ - d1, - d2 - ]; -}; -var x301 = true ? undefined : function () { - return [ - d1, - d2 - ]; -}; -var x302 = true ? undefined : function named() { - return [ - d1, - d2 - ]; -}; -var x303 = true ? undefined : [ - d1, - d2 -]; -var x304 = true ? undefined : [ - d1, - d2 -]; -var x305 = true ? undefined : [ - d1, - d2 -]; -var x306 = true ? undefined : { - n: [ - d1, - d2 - ] -}; -var x307 = true ? undefined : function (n) { - var n; - return null; -}; -var x308 = true ? undefined : { - func: function (n) { - return [ - d1, - d2 - ]; - } -}; -var x309 = true ? function () { - return [ - d1, - d2 - ]; -} : undefined; -var x310 = true ? function () { - return [ - d1, - d2 - ]; -} : undefined; -var x311 = true ? function named() { - return [ - d1, - d2 - ]; -} : undefined; -var x312 = true ? function () { - return [ - d1, - d2 - ]; -} : undefined; -var x313 = true ? function () { - return [ - d1, - d2 - ]; -} : undefined; -var x314 = true ? function named() { - return [ - d1, - d2 - ]; -} : undefined; -var x315 = true ? [ - d1, - d2 -] : undefined; -var x316 = true ? [ - d1, - d2 -] : undefined; -var x317 = true ? [ - d1, - d2 -] : undefined; -var x318 = true ? { - n: [ - d1, - d2 - ] -} : undefined; -var x319 = true ? function (n) { - var n; - return null; -} : undefined; -var x320 = true ? { - func: function (n) { - return [ - d1, - d2 - ]; - } -} : undefined; -function x321(n) { -} +x236 = { func: function (n) { return [d1, d2]; } }; +var x237 = { n: function () { return [d1, d2]; } }; +var x238 = { n: function () { return [d1, d2]; } }; +var x239 = { n: function named() { return [d1, d2]; } }; +var x240 = { n: function () { return [d1, d2]; } }; +var x241 = { n: function () { return [d1, d2]; } }; +var x242 = { n: function named() { return [d1, d2]; } }; +var x243 = { n: [d1, d2] }; +var x244 = { n: [d1, d2] }; +var x245 = { n: [d1, d2] }; +var x246 = { n: { n: [d1, d2] } }; +var x247 = { n: function (n) { var n; return null; } }; +var x248 = { n: { func: function (n) { return [d1, d2]; } } }; +var x252 = [function () { return [d1, d2]; }]; +var x253 = [function () { return [d1, d2]; }]; +var x254 = [function named() { return [d1, d2]; }]; +var x255 = [[d1, d2]]; +var x256 = [[d1, d2]]; +var x257 = [[d1, d2]]; +var x258 = [{ n: [d1, d2] }]; +var x260 = [{ func: function (n) { return [d1, d2]; } }]; +var x261 = function () { return [d1, d2]; } || undefined; +var x262 = function named() { return [d1, d2]; } || undefined; +var x263 = function () { return [d1, d2]; } || undefined; +var x264 = function named() { return [d1, d2]; } || undefined; +var x265 = [d1, d2] || undefined; +var x266 = [d1, d2] || undefined; +var x267 = [d1, d2] || undefined; +var x268 = { n: [d1, d2] } || undefined; +var x269 = undefined || function () { return [d1, d2]; }; +var x270 = undefined || function named() { return [d1, d2]; }; +var x271 = undefined || function () { return [d1, d2]; }; +var x272 = undefined || function named() { return [d1, d2]; }; +var x273 = undefined || [d1, d2]; +var x274 = undefined || [d1, d2]; +var x275 = undefined || [d1, d2]; +var x276 = undefined || { n: [d1, d2] }; +var x277 = function () { return [d1, d2]; } || function () { return [d1, d2]; }; +var x278 = function named() { return [d1, d2]; } || function named() { return [d1, d2]; }; +var x279 = function () { return [d1, d2]; } || function () { return [d1, d2]; }; +var x280 = function named() { return [d1, d2]; } || function named() { return [d1, d2]; }; +var x281 = [d1, d2] || [d1, d2]; +var x282 = [d1, d2] || [d1, d2]; +var x283 = [d1, d2] || [d1, d2]; +var x284 = { n: [d1, d2] } || { n: [d1, d2] }; +var x285 = true ? function () { return [d1, d2]; } : function () { return [d1, d2]; }; +var x286 = true ? function () { return [d1, d2]; } : function () { return [d1, d2]; }; +var x287 = true ? function named() { return [d1, d2]; } : function named() { return [d1, d2]; }; +var x288 = true ? function () { return [d1, d2]; } : function () { return [d1, d2]; }; +var x289 = true ? function () { return [d1, d2]; } : function () { return [d1, d2]; }; +var x290 = true ? function named() { return [d1, d2]; } : function named() { return [d1, d2]; }; +var x291 = true ? [d1, d2] : [d1, d2]; +var x292 = true ? [d1, d2] : [d1, d2]; +var x293 = true ? [d1, d2] : [d1, d2]; +var x294 = true ? { n: [d1, d2] } : { n: [d1, d2] }; +var x295 = true ? function (n) { var n; return null; } : function (n) { var n; return null; }; +var x296 = true ? { func: function (n) { return [d1, d2]; } } : { func: function (n) { return [d1, d2]; } }; +var x297 = true ? undefined : function () { return [d1, d2]; }; +var x298 = true ? undefined : function () { return [d1, d2]; }; +var x299 = true ? undefined : function named() { return [d1, d2]; }; +var x300 = true ? undefined : function () { return [d1, d2]; }; +var x301 = true ? undefined : function () { return [d1, d2]; }; +var x302 = true ? undefined : function named() { return [d1, d2]; }; +var x303 = true ? undefined : [d1, d2]; +var x304 = true ? undefined : [d1, d2]; +var x305 = true ? undefined : [d1, d2]; +var x306 = true ? undefined : { n: [d1, d2] }; +var x307 = true ? undefined : function (n) { var n; return null; }; +var x308 = true ? undefined : { func: function (n) { return [d1, d2]; } }; +var x309 = true ? function () { return [d1, d2]; } : undefined; +var x310 = true ? function () { return [d1, d2]; } : undefined; +var x311 = true ? function named() { return [d1, d2]; } : undefined; +var x312 = true ? function () { return [d1, d2]; } : undefined; +var x313 = true ? function () { return [d1, d2]; } : undefined; +var x314 = true ? function named() { return [d1, d2]; } : undefined; +var x315 = true ? [d1, d2] : undefined; +var x316 = true ? [d1, d2] : undefined; +var x317 = true ? [d1, d2] : undefined; +var x318 = true ? { n: [d1, d2] } : undefined; +var x319 = true ? function (n) { var n; return null; } : undefined; +var x320 = true ? { func: function (n) { return [d1, d2]; } } : undefined; +function x321(n) { } ; -x321(function () { - return [ - d1, - d2 - ]; -}); -function x322(n) { -} +x321(function () { return [d1, d2]; }); +function x322(n) { } ; -x322(function () { - return [ - d1, - d2 - ]; -}); -function x323(n) { -} +x322(function () { return [d1, d2]; }); +function x323(n) { } ; -x323(function named() { - return [ - d1, - d2 - ]; -}); -function x324(n) { -} +x323(function named() { return [d1, d2]; }); +function x324(n) { } ; -x324(function () { - return [ - d1, - d2 - ]; -}); -function x325(n) { -} +x324(function () { return [d1, d2]; }); +function x325(n) { } ; -x325(function () { - return [ - d1, - d2 - ]; -}); -function x326(n) { -} +x325(function () { return [d1, d2]; }); +function x326(n) { } ; -x326(function named() { - return [ - d1, - d2 - ]; -}); -function x327(n) { -} +x326(function named() { return [d1, d2]; }); +function x327(n) { } ; -x327([ - d1, - d2 -]); -function x328(n) { -} +x327([d1, d2]); +function x328(n) { } ; -x328([ - d1, - d2 -]); -function x329(n) { -} +x328([d1, d2]); +function x329(n) { } ; -x329([ - d1, - d2 -]); -function x330(n) { -} +x329([d1, d2]); +function x330(n) { } ; -x330({ - n: [ - d1, - d2 - ] -}); -function x331(n) { -} +x330({ n: [d1, d2] }); +function x331(n) { } ; -x331(function (n) { - var n; - return null; -}); -function x332(n) { -} +x331(function (n) { var n; return null; }); +function x332(n) { } ; -x332({ - func: function (n) { - return [ - d1, - d2 - ]; - } -}); -var x333 = function (n) { - return n; -}; -x333(function () { - return [ - d1, - d2 - ]; -}); -var x334 = function (n) { - return n; -}; -x334(function () { - return [ - d1, - d2 - ]; -}); -var x335 = function (n) { - return n; -}; -x335(function named() { - return [ - d1, - d2 - ]; -}); -var x336 = function (n) { - return n; -}; -x336(function () { - return [ - d1, - d2 - ]; -}); -var x337 = function (n) { - return n; -}; -x337(function () { - return [ - d1, - d2 - ]; -}); -var x338 = function (n) { - return n; -}; -x338(function named() { - return [ - d1, - d2 - ]; -}); -var x339 = function (n) { - return n; -}; -x339([ - d1, - d2 -]); -var x340 = function (n) { - return n; -}; -x340([ - d1, - d2 -]); -var x341 = function (n) { - return n; -}; -x341([ - d1, - d2 -]); -var x342 = function (n) { - return n; -}; -x342({ - n: [ - d1, - d2 - ] -}); -var x343 = function (n) { - return n; -}; -x343(function (n) { - var n; - return null; -}); -var x344 = function (n) { - return n; -}; -x344({ - func: function (n) { - return [ - d1, - d2 - ]; - } -}); -var x345 = function (n) { -}; -x345(function () { - return [ - d1, - d2 - ]; -}); -var x346 = function (n) { -}; -x346(function () { - return [ - d1, - d2 - ]; -}); -var x347 = function (n) { -}; -x347(function named() { - return [ - d1, - d2 - ]; -}); -var x348 = function (n) { -}; -x348(function () { - return [ - d1, - d2 - ]; -}); -var x349 = function (n) { -}; -x349(function () { - return [ - d1, - d2 - ]; -}); -var x350 = function (n) { -}; -x350(function named() { - return [ - d1, - d2 - ]; -}); -var x351 = function (n) { -}; -x351([ - d1, - d2 -]); -var x352 = function (n) { -}; -x352([ - d1, - d2 -]); -var x353 = function (n) { -}; -x353([ - d1, - d2 -]); -var x354 = function (n) { -}; -x354({ - n: [ - d1, - d2 - ] -}); -var x355 = function (n) { -}; -x355(function (n) { - var n; - return null; -}); -var x356 = function (n) { -}; -x356({ - func: function (n) { - return [ - d1, - d2 - ]; - } -}); +x332({ func: function (n) { return [d1, d2]; } }); +var x333 = function (n) { return n; }; +x333(function () { return [d1, d2]; }); +var x334 = function (n) { return n; }; +x334(function () { return [d1, d2]; }); +var x335 = function (n) { return n; }; +x335(function named() { return [d1, d2]; }); +var x336 = function (n) { return n; }; +x336(function () { return [d1, d2]; }); +var x337 = function (n) { return n; }; +x337(function () { return [d1, d2]; }); +var x338 = function (n) { return n; }; +x338(function named() { return [d1, d2]; }); +var x339 = function (n) { return n; }; +x339([d1, d2]); +var x340 = function (n) { return n; }; +x340([d1, d2]); +var x341 = function (n) { return n; }; +x341([d1, d2]); +var x342 = function (n) { return n; }; +x342({ n: [d1, d2] }); +var x343 = function (n) { return n; }; +x343(function (n) { var n; return null; }); +var x344 = function (n) { return n; }; +x344({ func: function (n) { return [d1, d2]; } }); +var x345 = function (n) { }; +x345(function () { return [d1, d2]; }); +var x346 = function (n) { }; +x346(function () { return [d1, d2]; }); +var x347 = function (n) { }; +x347(function named() { return [d1, d2]; }); +var x348 = function (n) { }; +x348(function () { return [d1, d2]; }); +var x349 = function (n) { }; +x349(function () { return [d1, d2]; }); +var x350 = function (n) { }; +x350(function named() { return [d1, d2]; }); +var x351 = function (n) { }; +x351([d1, d2]); +var x352 = function (n) { }; +x352([d1, d2]); +var x353 = function (n) { }; +x353([d1, d2]); +var x354 = function (n) { }; +x354({ n: [d1, d2] }); +var x355 = function (n) { }; +x355(function (n) { var n; return null; }); +var x356 = function (n) { }; +x356({ func: function (n) { return [d1, d2]; } }); diff --git a/tests/baselines/reference/generativeRecursionWithTypeOf.js b/tests/baselines/reference/generativeRecursionWithTypeOf.js index 599751ebde..2b7eebfd11 100644 --- a/tests/baselines/reference/generativeRecursionWithTypeOf.js +++ b/tests/baselines/reference/generativeRecursionWithTypeOf.js @@ -14,8 +14,7 @@ module M { var C = (function () { function C() { } - C.foo = function (x) { - }; + C.foo = function (x) { }; return C; })(); var M; diff --git a/tests/baselines/reference/genericArgumentCallSigAssignmentCompat.js b/tests/baselines/reference/genericArgumentCallSigAssignmentCompat.js index 321400fc24..dd06b855b6 100644 --- a/tests/baselines/reference/genericArgumentCallSigAssignmentCompat.js +++ b/tests/baselines/reference/genericArgumentCallSigAssignmentCompat.js @@ -23,13 +23,6 @@ _.all([true], _.identity); //// [genericArgumentCallSigAssignmentCompat.js] // No error, Call signatures of types '(value: T) => T' and 'Underscore.Iterator<{}, boolean>' are compatible when instantiated with any. // Ideally, we would not have a generic signature here, because it should be instantiated with {} during inferential typing -_.all([ - true, - 1, - null, - 'yes' -], _.identity); +_.all([true, 1, null, 'yes'], _.identity); // Ok, because fixing makes us infer boolean for T -_.all([ - true -], _.identity); +_.all([true], _.identity); diff --git a/tests/baselines/reference/genericArray1.js b/tests/baselines/reference/genericArray1.js index e698d33907..b0bfcd2201 100644 --- a/tests/baselines/reference/genericArray1.js +++ b/tests/baselines/reference/genericArray1.js @@ -26,13 +26,7 @@ interface String{ length: number; } */ -var lengths = [ - "a", - "b", - "c" -].map(function (x) { - return x.length; -}); +var lengths = ["a", "b", "c"].map(function (x) { return x.length; }); //// [genericArray1.d.ts] diff --git a/tests/baselines/reference/genericArrayMethods1.js b/tests/baselines/reference/genericArrayMethods1.js index e6cebcb220..c7fca1ee6b 100644 --- a/tests/baselines/reference/genericArrayMethods1.js +++ b/tests/baselines/reference/genericArrayMethods1.js @@ -3,7 +3,4 @@ var x:string[] = [0,1].slice(0); // this should be an error //// [genericArrayMethods1.js] -var x = [ - 0, - 1 -].slice(0); // this should be an error +var x = [0, 1].slice(0); // this should be an error diff --git a/tests/baselines/reference/genericAssignmentCompatOfFunctionSignatures1.js b/tests/baselines/reference/genericAssignmentCompatOfFunctionSignatures1.js index 6f1928a260..9b7d5b713e 100644 --- a/tests/baselines/reference/genericAssignmentCompatOfFunctionSignatures1.js +++ b/tests/baselines/reference/genericAssignmentCompatOfFunctionSignatures1.js @@ -6,9 +6,7 @@ x1 = x2; x2 = x1; //// [genericAssignmentCompatOfFunctionSignatures1.js] -var x1 = function foo3(x, z) { -}; -var x2 = function foo3(x, z) { -}; +var x1 = function foo3(x, z) { }; +var x2 = function foo3(x, z) { }; x1 = x2; x2 = x1; diff --git a/tests/baselines/reference/genericAssignmentCompatWithInterfaces1.js b/tests/baselines/reference/genericAssignmentCompatWithInterfaces1.js index 7f82cc6afb..70f70ae07b 100644 --- a/tests/baselines/reference/genericAssignmentCompatWithInterfaces1.js +++ b/tests/baselines/reference/genericAssignmentCompatWithInterfaces1.js @@ -23,21 +23,13 @@ var a4: I = >z; var A = (function () { function A() { } - A.prototype.compareTo = function (other) { - return 1; - }; + A.prototype.compareTo = function (other) { return 1; }; return A; })(); -var z = { - x: new A() -}; -var a1 = { - x: new A() -}; +var z = { x: new A() }; +var a1 = { x: new A() }; var a2 = function () { - var z = { - x: new A() - }; + var z = { x: new A() }; return z; }(); var a3 = z; diff --git a/tests/baselines/reference/genericCallWithArrayLiteralArgs.js b/tests/baselines/reference/genericCallWithArrayLiteralArgs.js index ebc49f37c0..ba8c2884ff 100644 --- a/tests/baselines/reference/genericCallWithArrayLiteralArgs.js +++ b/tests/baselines/reference/genericCallWithArrayLiteralArgs.js @@ -17,29 +17,11 @@ var r6 = foo([1, '']); // Object[] function foo(t) { return t; } -var r = foo([ - 1, - 2 -]); // number[] -var r = foo([ - 1, - 2 -]); // number[] -var ra = foo([ - 1, - 2 -]); // any[] +var r = foo([1, 2]); // number[] +var r = foo([1, 2]); // number[] +var ra = foo([1, 2]); // any[] var r2 = foo([]); // any[] var r3 = foo([]); // number[] -var r4 = foo([ - 1, - '' -]); // {}[] -var r5 = foo([ - 1, - '' -]); // any[] -var r6 = foo([ - 1, - '' -]); // Object[] +var r4 = foo([1, '']); // {}[] +var r5 = foo([1, '']); // any[] +var r6 = foo([1, '']); // Object[] diff --git a/tests/baselines/reference/genericCallWithFixedArguments.js b/tests/baselines/reference/genericCallWithFixedArguments.js index 10c0e2b496..e588c0d113 100644 --- a/tests/baselines/reference/genericCallWithFixedArguments.js +++ b/tests/baselines/reference/genericCallWithFixedArguments.js @@ -11,17 +11,14 @@ g(7) // the parameter list is fixed, so this should not error var A = (function () { function A() { } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); var B = (function () { function B() { } - B.prototype.bar = function () { - }; + B.prototype.bar = function () { }; return B; })(); -function g(x) { -} +function g(x) { } g(7); // the parameter list is fixed, so this should not error diff --git a/tests/baselines/reference/genericCallWithFunctionTypedArguments.js b/tests/baselines/reference/genericCallWithFunctionTypedArguments.js index b6f2839bae..30d4ed353f 100644 --- a/tests/baselines/reference/genericCallWithFunctionTypedArguments.js +++ b/tests/baselines/reference/genericCallWithFunctionTypedArguments.js @@ -42,53 +42,25 @@ function other(t: T, u: U) { function foo(x) { return x(null); } -var r = foo(function (x) { - return ''; -}); // {} -var r2 = foo(function (x) { - return ''; -}); // string -var r3 = foo(function (x) { - return ''; -}); // {} +var r = foo(function (x) { return ''; }); // {} +var r2 = foo(function (x) { return ''; }); // string +var r3 = foo(function (x) { return ''; }); // {} function foo2(x, cb) { return cb(x); } -var r4 = foo2(1, function (a) { - return ''; -}); // string, contextual signature instantiation is applied to generic functions -var r5 = foo2(1, function (a) { - return ''; -}); // string -var r6 = foo2('', function (a) { - return 1; -}); +var r4 = foo2(1, function (a) { return ''; }); // string, contextual signature instantiation is applied to generic functions +var r5 = foo2(1, function (a) { return ''; }); // string +var r6 = foo2('', function (a) { return 1; }); function foo3(x, cb, y) { return cb(x); } -var r7 = foo3(1, function (a) { - return ''; -}, ''); // string -var r8 = foo3(1, function (a) { - return ''; -}, 1); // error -var r9 = foo3(1, function (a) { - return ''; -}, ''); // string +var r7 = foo3(1, function (a) { return ''; }, ''); // string +var r8 = foo3(1, function (a) { return ''; }, 1); // error +var r9 = foo3(1, function (a) { return ''; }, ''); // string function other(t, u) { - var r10 = foo2(1, function (x) { - return ''; - }); // error - var r10 = foo2(1, function (x) { - return ''; - }); // string - var r11 = foo3(1, function (x) { - return ''; - }, ''); // error - var r11b = foo3(1, function (x) { - return ''; - }, 1); // error - var r12 = foo3(1, function (a) { - return ''; - }, 1); // error + var r10 = foo2(1, function (x) { return ''; }); // error + var r10 = foo2(1, function (x) { return ''; }); // string + var r11 = foo3(1, function (x) { return ''; }, ''); // error + var r11b = foo3(1, function (x) { return ''; }, 1); // error + var r12 = foo3(1, function (a) { return ''; }, 1); // error } diff --git a/tests/baselines/reference/genericCallWithFunctionTypedArguments5.js b/tests/baselines/reference/genericCallWithFunctionTypedArguments5.js index 1675b582d4..4e3e20071b 100644 --- a/tests/baselines/reference/genericCallWithFunctionTypedArguments5.js +++ b/tests/baselines/reference/genericCallWithFunctionTypedArguments5.js @@ -27,40 +27,16 @@ var r7 = foo({ cb: () => '' }); // string function foo(arg) { return arg.cb(null); } -var arg = { - cb: function (x) { - return ''; - } -}; +var arg = { cb: function (x) { return ''; } }; var r = foo(arg); // {} // more args not allowed -var r2 = foo({ - cb: function (x, y) { - return ''; - } -}); // error -var r3 = foo({ - cb: function (x, y) { - return ''; - } -}); // error +var r2 = foo({ cb: function (x, y) { return ''; } }); // error +var r3 = foo({ cb: function (x, y) { return ''; } }); // error function foo2(arg) { return arg.cb(null, null); } // fewer args ok var r4 = foo(arg); // {} -var r5 = foo({ - cb: function (x) { - return ''; - } -}); // {} -var r6 = foo({ - cb: function (x) { - return ''; - } -}); // string -var r7 = foo({ - cb: function () { - return ''; - } -}); // string +var r5 = foo({ cb: function (x) { return ''; } }); // {} +var r6 = foo({ cb: function (x) { return ''; } }); // string +var r7 = foo({ cb: function () { return ''; } }); // string diff --git a/tests/baselines/reference/genericCallWithGenericSignatureArguments.js b/tests/baselines/reference/genericCallWithGenericSignatureArguments.js index 0f39ae16de..17094dae69 100644 --- a/tests/baselines/reference/genericCallWithGenericSignatureArguments.js +++ b/tests/baselines/reference/genericCallWithGenericSignatureArguments.js @@ -50,61 +50,21 @@ function foo(a, b) { return r; } //var r1 = foo((x: number) => 1, (x: string) => ''); // error -var r1b = foo(function (x) { - return 1; -}, function (x) { - return ''; -}); // {} => {} -var r2 = foo(function (x) { - return null; -}, function (x) { - return ''; -}); // Object => Object -var r3 = foo(function (x) { - return 1; -}, function (x) { - return null; -}); // number => number -var r3ii = foo(function (x) { - return 1; -}, function (x) { - return 1; -}); // number => number +var r1b = foo(function (x) { return 1; }, function (x) { return ''; }); // {} => {} +var r2 = foo(function (x) { return null; }, function (x) { return ''; }); // Object => Object +var r3 = foo(function (x) { return 1; }, function (x) { return null; }); // number => number +var r3ii = foo(function (x) { return 1; }, function (x) { return 1; }); // number => number var a; var b; -var r4 = foo(function (x) { - return a; -}, function (x) { - return b; -}); // typeof a => typeof a -var r5 = foo(function (x) { - return b; -}, function (x) { - return a; -}); // typeof b => typeof b +var r4 = foo(function (x) { return a; }, function (x) { return b; }); // typeof a => typeof a +var r5 = foo(function (x) { return b; }, function (x) { return a; }); // typeof b => typeof b function other(x) { - var r6 = foo(function (a) { - return a; - }, function (b) { - return b; - }); // T => T - var r6b = foo(function (a) { - return a; - }, function (b) { - return b; - }); // {} => {} + var r6 = foo(function (a) { return a; }, function (b) { return b; }); // T => T + var r6b = foo(function (a) { return a; }, function (b) { return b; }); // {} => {} } function other2(x) { - var r7 = foo(function (a) { - return a; - }, function (b) { - return b; - }); // T => T - var r7b = foo(function (a) { - return a; - }, function (b) { - return b; - }); // {} => {} + var r7 = foo(function (a) { return a; }, function (b) { return b; }); // T => T + var r7b = foo(function (a) { return a; }, function (b) { return b; }); // {} => {} var r8 = r7(null); // BUG 835518 //var r9 = r7(new Date()); @@ -114,9 +74,5 @@ function foo2(a, b) { return r; } function other3(x) { - var r8 = foo2(function (a) { - return a; - }, function (b) { - return b; - }); // Date => Date + var r8 = foo2(function (a) { return a; }, function (b) { return b; }); // Date => Date } diff --git a/tests/baselines/reference/genericCallWithGenericSignatureArguments2.js b/tests/baselines/reference/genericCallWithGenericSignatureArguments2.js index 758852a918..1aabe9cfa2 100644 --- a/tests/baselines/reference/genericCallWithGenericSignatureArguments2.js +++ b/tests/baselines/reference/genericCallWithGenericSignatureArguments2.js @@ -82,17 +82,9 @@ var onlyT; var r; return r; } - var r1 = foo(function (x) { - return 1; - }, function (x) { - return ''; - }); + var r1 = foo(function (x) { return 1; }, function (x) { return ''; }); function other2(x) { - var r7 = foo(function (a) { - return a; - }, function (b) { - return b; - }); // T => T + var r7 = foo(function (a) { return a; }, function (b) { return b; }); // T => T // BUG 835518 var r9 = r7(new Date()); // should be ok var r10 = r7(1); // error @@ -102,16 +94,8 @@ var onlyT; return r; } function other3(x) { - var r7 = foo2(function (a) { - return a; - }, function (b) { - return b; - }); // error - var r7b = foo2(function (a) { - return a; - }, function (b) { - return b; - }); // valid, T is inferred to be Date + var r7 = foo2(function (a) { return a; }, function (b) { return b; }); // error + var r7b = foo2(function (a) { return a; }, function (b) { return b; }); // valid, T is inferred to be Date } var E; (function (E) { @@ -125,11 +109,7 @@ var onlyT; var r; return r; } - var r7 = foo3(E.A, function (x) { - return E.A; - }, function (x) { - return F.A; - }); // error + var r7 = foo3(E.A, function (x) { return E.A; }, function (x) { return F.A; }); // error })(onlyT || (onlyT = {})); var TU; (function (TU) { @@ -137,17 +117,9 @@ var TU; var r; return r; } - var r1 = foo(function (x) { - return 1; - }, function (x) { - return ''; - }); + var r1 = foo(function (x) { return 1; }, function (x) { return ''; }); function other2(x) { - var r7 = foo(function (a) { - return a; - }, function (b) { - return b; - }); + var r7 = foo(function (a) { return a; }, function (b) { return b; }); var r9 = r7(new Date()); var r10 = r7(1); } @@ -156,16 +128,8 @@ var TU; return r; } function other3(x) { - var r7 = foo2(function (a) { - return a; - }, function (b) { - return b; - }); - var r7b = foo2(function (a) { - return a; - }, function (b) { - return b; - }); + var r7 = foo2(function (a) { return a; }, function (b) { return b; }); + var r7b = foo2(function (a) { return a; }, function (b) { return b; }); } var E; (function (E) { @@ -179,9 +143,5 @@ var TU; var r; return r; } - var r7 = foo3(E.A, function (x) { - return E.A; - }, function (x) { - return F.A; - }); + var r7 = foo3(E.A, function (x) { return E.A; }, function (x) { return F.A; }); })(TU || (TU = {})); diff --git a/tests/baselines/reference/genericCallWithGenericSignatureArguments3.js b/tests/baselines/reference/genericCallWithGenericSignatureArguments3.js index b7cc833b9d..36566033a4 100644 --- a/tests/baselines/reference/genericCallWithGenericSignatureArguments3.js +++ b/tests/baselines/reference/genericCallWithGenericSignatureArguments3.js @@ -40,36 +40,12 @@ function foo(x, a, b) { var r; return r; } -var r1 = foo('', function (x) { - return ''; -}, function (x) { - return null; -}); // any => any -var r1ii = foo('', function (x) { - return ''; -}, function (x) { - return null; -}); // string => string -var r2 = foo('', function (x) { - return ''; -}, function (x) { - return ''; -}); // string => string -var r3 = foo(null, function (x) { - return ''; -}, function (x) { - return ''; -}); // Object => Object -var r4 = foo(null, function (x) { - return ''; -}, function (x) { - return ''; -}); // any => any -var r5 = foo(new Object(), function (x) { - return ''; -}, function (x) { - return ''; -}); // Object => Object +var r1 = foo('', function (x) { return ''; }, function (x) { return null; }); // any => any +var r1ii = foo('', function (x) { return ''; }, function (x) { return null; }); // string => string +var r2 = foo('', function (x) { return ''; }, function (x) { return ''; }); // string => string +var r3 = foo(null, function (x) { return ''; }, function (x) { return ''; }); // Object => Object +var r4 = foo(null, function (x) { return ''; }, function (x) { return ''; }); // any => any +var r5 = foo(new Object(), function (x) { return ''; }, function (x) { return ''; }); // Object => Object var E; (function (E) { E[E["A"] = 0] = "A"; @@ -78,42 +54,14 @@ var F; (function (F) { F[F["A"] = 0] = "A"; })(F || (F = {})); -var r6 = foo(E.A, function (x) { - return E.A; -}, function (x) { - return F.A; -}); // number => number +var r6 = foo(E.A, function (x) { return E.A; }, function (x) { return F.A; }); // number => number function foo2(x, a, b) { var r; return r; } -var r8 = foo2('', function (x) { - return ''; -}, function (x) { - return null; -}); // string => string -var r9 = foo2(null, function (x) { - return ''; -}, function (x) { - return ''; -}); // any => any -var r10 = foo2(null, function (x) { - return ''; -}, function (x) { - return ''; -}); // Object => Object +var r8 = foo2('', function (x) { return ''; }, function (x) { return null; }); // string => string +var r9 = foo2(null, function (x) { return ''; }, function (x) { return ''; }); // any => any +var r10 = foo2(null, function (x) { return ''; }, function (x) { return ''; }); // Object => Object var x; -var r11 = foo2(x, function (a1) { - return function (n) { - return 1; - }; -}, function (a2) { - return 2; -}); // error -var r12 = foo2(x, function (a1) { - return function (n) { - return 1; - }; -}, function (a2) { - return 2; -}); // error +var r11 = foo2(x, function (a1) { return function (n) { return 1; }; }, function (a2) { return 2; }); // error +var r12 = foo2(x, function (a1) { return function (n) { return 1; }; }, function (a2) { return 2; }); // error diff --git a/tests/baselines/reference/genericCallWithNonGenericArgs1.js b/tests/baselines/reference/genericCallWithNonGenericArgs1.js index 2282c64e85..4f5239630a 100644 --- a/tests/baselines/reference/genericCallWithNonGenericArgs1.js +++ b/tests/baselines/reference/genericCallWithNonGenericArgs1.js @@ -4,6 +4,5 @@ f(null) //// [genericCallWithNonGenericArgs1.js] -function f(x) { -} +function f(x) { } f(null); diff --git a/tests/baselines/reference/genericCallWithObjectLiteralArgs.js b/tests/baselines/reference/genericCallWithObjectLiteralArgs.js index 17ca4ad937..2515bbef29 100644 --- a/tests/baselines/reference/genericCallWithObjectLiteralArgs.js +++ b/tests/baselines/reference/genericCallWithObjectLiteralArgs.js @@ -12,19 +12,7 @@ var r4 = foo({ bar: 1, baz: '' }); // T = Object function foo(x) { return x; } -var r = foo({ - bar: 1, - baz: '' -}); // error -var r2 = foo({ - bar: 1, - baz: 1 -}); // T = number -var r3 = foo({ - bar: foo, - baz: foo -}); // T = typeof foo -var r4 = foo({ - bar: 1, - baz: '' -}); // T = Object +var r = foo({ bar: 1, baz: '' }); // error +var r2 = foo({ bar: 1, baz: 1 }); // T = number +var r3 = foo({ bar: foo, baz: foo }); // T = typeof foo +var r4 = foo({ bar: 1, baz: '' }); // T = Object diff --git a/tests/baselines/reference/genericCallWithObjectLiteralArguments1.js b/tests/baselines/reference/genericCallWithObjectLiteralArguments1.js index 92564c0a13..f140caaac6 100644 --- a/tests/baselines/reference/genericCallWithObjectLiteralArguments1.js +++ b/tests/baselines/reference/genericCallWithObjectLiteralArguments1.js @@ -8,27 +8,10 @@ var x4 = foo({ x: "", y: 4 }, ""); var x5 = foo({ x: "", y: 4 }, ""); //// [genericCallWithObjectLiteralArguments1.js] -function foo(n, m) { - return m; -} +function foo(n, m) { return m; } // these are all errors -var x = foo({ - x: 3, - y: "" -}, 4); -var x2 = foo({ - x: 3, - y: "" -}, 4); -var x3 = foo({ - x: 3, - y: "" -}, 4); -var x4 = foo({ - x: "", - y: 4 -}, ""); -var x5 = foo({ - x: "", - y: 4 -}, ""); +var x = foo({ x: 3, y: "" }, 4); +var x2 = foo({ x: 3, y: "" }, 4); +var x3 = foo({ x: 3, y: "" }, 4); +var x4 = foo({ x: "", y: 4 }, ""); +var x5 = foo({ x: "", y: 4 }, ""); diff --git a/tests/baselines/reference/genericCallWithObjectTypeArgs2.js b/tests/baselines/reference/genericCallWithObjectTypeArgs2.js index aa478a7fbe..3a72feff97 100644 --- a/tests/baselines/reference/genericCallWithObjectTypeArgs2.js +++ b/tests/baselines/reference/genericCallWithObjectTypeArgs2.js @@ -60,27 +60,13 @@ var Derived2 = (function (_super) { })(Base); // returns {}[] function f(a) { - return [ - a.x, - a.y - ]; + return [a.x, a.y]; } -var r = f({ - x: new Derived(), - y: new Derived2() -}); // {}[] -var r2 = f({ - x: new Base(), - y: new Derived2() -}); // {}[] +var r = f({ x: new Derived(), y: new Derived2() }); // {}[] +var r2 = f({ x: new Base(), y: new Derived2() }); // {}[] function f2(a) { - return function (x) { - return a.y; - }; + return function (x) { return a.y; }; } -var r3 = f2({ - x: new Derived(), - y: new Derived2() -}); // Derived => Derived2 +var r3 = f2({ x: new Derived(), y: new Derived2() }); // Derived => Derived2 var i; var r4 = f2(i); // Base => Derived diff --git a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints2.js b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints2.js index e530187859..c1f0945ba1 100644 --- a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints2.js +++ b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints2.js @@ -63,14 +63,8 @@ function f(x) { var r; return r; } -var r = f({ - foo: new Base(), - bar: new Derived() -}); -var r2 = f({ - foo: new Derived(), - bar: new Derived() -}); +var r = f({ foo: new Base(), bar: new Derived() }); +var r2 = f({ foo: new Derived(), bar: new Derived() }); function f2(x) { var r; return r; @@ -80,13 +74,7 @@ var r3 = f2(i); function f3(x, y) { return y(null); } -var r4 = f3(new Base(), function (x) { - return x; -}); -var r5 = f3(new Derived(), function (x) { - return x; -}); +var r4 = f3(new Base(), function (x) { return x; }); +var r5 = f3(new Derived(), function (x) { return x; }); var r6 = f3(null, null); // any -var r7 = f3(null, function (x) { - return x; -}); // any +var r7 = f3(null, function (x) { return x; }); // any diff --git a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints3.js b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints3.js index 9dca38866c..b9c722f80b 100644 --- a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints3.js +++ b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints3.js @@ -68,32 +68,17 @@ function f(a) { var r; return r; } -var r1 = f({ - x: new Derived(), - y: new Derived2() -}); // error because neither is supertype of the other +var r1 = f({ x: new Derived(), y: new Derived2() }); // error because neither is supertype of the other function f2(a) { var r; return r; } -var r2 = f2({ - x: new Derived(), - y: new Derived2() -}); // ok -var r3 = f2({ - x: new Derived(), - y: new Derived2() -}); // ok +var r2 = f2({ x: new Derived(), y: new Derived2() }); // ok +var r3 = f2({ x: new Derived(), y: new Derived2() }); // ok function f3(y, x) { return y(null); } // all ok - second argument is processed before x is fixed -var r4 = f3(function (x) { - return x; -}, new Base()); -var r5 = f3(function (x) { - return x; -}, new Derived()); -var r6 = f3(function (x) { - return x; -}, null); +var r4 = f3(function (x) { return x; }, new Base()); +var r5 = f3(function (x) { return x; }, new Derived()); +var r6 = f3(function (x) { return x; }, null); diff --git a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints4.js b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints4.js index 2872777d1b..10d32ddeae 100644 --- a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints4.js +++ b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints4.js @@ -46,29 +46,19 @@ var D = (function () { return D; })(); function foo(t, t2) { - return function (x) { - return t2; - }; + return function (x) { return t2; }; } var c; var d; var r = foo(c, d); var r2 = foo(d, c); // error because C does not extend D -var r3 = foo(c, { - x: '', - foo: c -}); +var r3 = foo(c, { x: '', foo: c }); var r4 = foo(null, null); var r5 = foo({}, null); var r6 = foo(null, {}); var r7 = foo({}, {}); -var r8 = foo(function () { -}, function () { -}); -var r9 = foo(function () { -}, function () { - return 1; -}); +var r8 = foo(function () { }, function () { }); +var r9 = foo(function () { }, function () { return 1; }); function other() { var r4 = foo(c, d); var r5 = foo(c, d); // error diff --git a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints5.js b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints5.js index c0432cfcac..95b98767a0 100644 --- a/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints5.js +++ b/tests/baselines/reference/genericCallWithObjectTypeArgsAndConstraints5.js @@ -37,17 +37,12 @@ var D = (function () { return D; })(); function foo(t, t2) { - return function (x) { - return t2; - }; + return function (x) { return t2; }; } var c; var d; var r2 = foo(d, c); // the constraints are self-referencing, no downstream error -var r9 = foo(function () { - return 1; -}, function () { -}); // the constraints are self-referencing, no downstream error +var r9 = foo(function () { return 1; }, function () { }); // the constraints are self-referencing, no downstream error function other() { var r5 = foo(c, d); // error } diff --git a/tests/baselines/reference/genericCallWithOverloadedFunctionTypedArguments.js b/tests/baselines/reference/genericCallWithOverloadedFunctionTypedArguments.js index b66c9ccf6c..dea5948242 100644 --- a/tests/baselines/reference/genericCallWithOverloadedFunctionTypedArguments.js +++ b/tests/baselines/reference/genericCallWithOverloadedFunctionTypedArguments.js @@ -54,44 +54,28 @@ var NonGenericParameter; return cb; } var r = foo4(a); - var r2 = foo4(function (x) { - return x; - }); - var r4 = foo4(function (x) { - return x; - }); + var r2 = foo4(function (x) { return x; }); + var r4 = foo4(function (x) { return x; }); })(NonGenericParameter || (NonGenericParameter = {})); var GenericParameter; (function (GenericParameter) { function foo5(cb) { return cb; } - var r5 = foo5(function (x) { - return x; - }); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed]. T is any + var r5 = foo5(function (x) { return x; }); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed]. T is any var a; var r7 = foo5(a); // any => string (+1 overload) function foo6(cb) { return cb; } - var r8 = foo6(function (x) { - return x; - }); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed]. T is any - var r9 = foo6(function (x) { - return ''; - }); // any => string (+1 overload) - var r11 = foo6(function (x, y) { - return ''; - }); // any => string (+1 overload) + var r8 = foo6(function (x) { return x; }); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed]. T is any + var r9 = foo6(function (x) { return ''; }); // any => string (+1 overload) + var r11 = foo6(function (x, y) { return ''; }); // any => string (+1 overload) function foo7(x, cb) { return cb; } - var r12 = foo7(1, function (x) { - return x; - }); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed] - var r13 = foo7(1, function (x) { - return ''; - }); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed] + var r12 = foo7(1, function (x) { return x; }); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed] + var r13 = foo7(1, function (x) { return ''; }); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed] var a; var r14 = foo7(1, a); // any => string (+1 overload) [inferences are made for T, but lambda not contextually typed] })(GenericParameter || (GenericParameter = {})); diff --git a/tests/baselines/reference/genericCallWithOverloadedFunctionTypedArguments2.js b/tests/baselines/reference/genericCallWithOverloadedFunctionTypedArguments2.js index e61e2b06b4..b4f96f6794 100644 --- a/tests/baselines/reference/genericCallWithOverloadedFunctionTypedArguments2.js +++ b/tests/baselines/reference/genericCallWithOverloadedFunctionTypedArguments2.js @@ -46,31 +46,22 @@ var NonGenericParameter; function foo4(cb) { return cb; } - var r3 = foo4(function (x) { - var r; - return r; - }); // ok + var r3 = foo4(function (x) { var r; return r; }); // ok })(NonGenericParameter || (NonGenericParameter = {})); var GenericParameter; (function (GenericParameter) { function foo5(cb) { return cb; } - var r6 = foo5(function (x) { - return x; - }); // ok + var r6 = foo5(function (x) { return x; }); // ok function foo6(cb) { return cb; } - var r10 = foo6(function (x, y) { - return ''; - }); // error + var r10 = foo6(function (x, y) { return ''; }); // error function foo7(x, cb) { return cb; } - var r13 = foo7(1, function (x) { - return x; - }); // ok + var r13 = foo7(1, function (x) { return x; }); // ok var a; var r14 = foo7(1, a); // ok })(GenericParameter || (GenericParameter = {})); diff --git a/tests/baselines/reference/genericCallWithTupleType.js b/tests/baselines/reference/genericCallWithTupleType.js index fa29f01384..296a6dad63 100644 --- a/tests/baselines/reference/genericCallWithTupleType.js +++ b/tests/baselines/reference/genericCallWithTupleType.js @@ -29,48 +29,18 @@ i2.tuple1 = [{}]; var i1; var i2; // no error -i1.tuple1 = [ - "foo", - 5 -]; +i1.tuple1 = ["foo", 5]; var e1 = i1.tuple1[0]; // string var e2 = i1.tuple1[1]; // number -i1.tuple1 = [ - "foo", - 5, - false, - true -]; +i1.tuple1 = ["foo", 5, false, true]; var e3 = i1.tuple1[2]; // {} -i1.tuple1[3] = { - a: "string" -}; +i1.tuple1[3] = { a: "string" }; var e4 = i1.tuple1[3]; // {} -i2.tuple1 = [ - "foo", - 5 -]; -i2.tuple1 = [ - "foo", - "bar" -]; -i2.tuple1 = [ - 5, - "bar" -]; -i2.tuple1 = [ - {}, - {} -]; +i2.tuple1 = ["foo", 5]; +i2.tuple1 = ["foo", "bar"]; +i2.tuple1 = [5, "bar"]; +i2.tuple1 = [{}, {}]; // error -i1.tuple1 = [ - 5, - "foo" -]; -i1.tuple1 = [ - {}, - {} -]; -i2.tuple1 = [ - {} -]; +i1.tuple1 = [5, "foo"]; +i1.tuple1 = [{}, {}]; +i2.tuple1 = [{}]; diff --git a/tests/baselines/reference/genericCallbacksAndClassHierarchy.js b/tests/baselines/reference/genericCallbacksAndClassHierarchy.js index 682cd6010f..e63c7a9827 100644 --- a/tests/baselines/reference/genericCallbacksAndClassHierarchy.js +++ b/tests/baselines/reference/genericCallbacksAndClassHierarchy.js @@ -56,13 +56,11 @@ var M; function D() { } D.prototype._subscribe = function (viewModel) { - var f = function (newValue) { - }; + var f = function (newValue) { }; var v = viewModel.value; // both of these should work v.subscribe(f); - v.subscribe(function (newValue) { - }); + v.subscribe(function (newValue) { }); }; return D; })(); diff --git a/tests/baselines/reference/genericCallsWithoutParens.js b/tests/baselines/reference/genericCallsWithoutParens.js index e51ed55224..a479fbab37 100644 --- a/tests/baselines/reference/genericCallsWithoutParens.js +++ b/tests/baselines/reference/genericCallsWithoutParens.js @@ -10,8 +10,7 @@ var c = new C; // parse error //// [genericCallsWithoutParens.js] -function f() { -} +function f() { } var r = f(); // parse error var C = (function () { function C() { diff --git a/tests/baselines/reference/genericChainedCalls.js b/tests/baselines/reference/genericChainedCalls.js index 48bc37101c..a738e19023 100644 --- a/tests/baselines/reference/genericChainedCalls.js +++ b/tests/baselines/reference/genericChainedCalls.js @@ -15,20 +15,9 @@ var s3 = s2.func(num => num.toString()) //// [genericChainedCalls.js] -var r1 = v1.func(function (num) { - return num.toString(); -}).func(function (str) { - return str.length; -}) // error, number doesn't have a length -.func(function (num) { - return num.toString(); -}); -var s1 = v1.func(function (num) { - return num.toString(); -}); -var s2 = s1.func(function (str) { - return str.length; -}); // should also error -var s3 = s2.func(function (num) { - return num.toString(); -}); +var r1 = v1.func(function (num) { return num.toString(); }) + .func(function (str) { return str.length; }) // error, number doesn't have a length + .func(function (num) { return num.toString(); }); +var s1 = v1.func(function (num) { return num.toString(); }); +var s2 = s1.func(function (str) { return str.length; }); // should also error +var s3 = s2.func(function (num) { return num.toString(); }); diff --git a/tests/baselines/reference/genericClassPropertyInheritanceSpecialization.js b/tests/baselines/reference/genericClassPropertyInheritanceSpecialization.js index 8d1e87cb49..4f26e35d1b 100644 --- a/tests/baselines/reference/genericClassPropertyInheritanceSpecialization.js +++ b/tests/baselines/reference/genericClassPropertyInheritanceSpecialization.js @@ -91,11 +91,8 @@ var Portal; var Validator = (function () { function Validator(message) { } - Validator.prototype.destroy = function () { - }; - Validator.prototype._validate = function (value) { - return 0; - }; + Validator.prototype.destroy = function () { }; + Validator.prototype._validate = function (value) { return 0; }; return Validator; })(); Validators.Validator = Validator; diff --git a/tests/baselines/reference/genericClassWithFunctionTypedMemberArguments.js b/tests/baselines/reference/genericClassWithFunctionTypedMemberArguments.js index 4aab45f522..5156c4d6b1 100644 --- a/tests/baselines/reference/genericClassWithFunctionTypedMemberArguments.js +++ b/tests/baselines/reference/genericClassWithFunctionTypedMemberArguments.js @@ -78,15 +78,9 @@ var ImmediatelyFix; return C; })(); var c = new C(); - var r = c.foo(function (x) { - return ''; - }); // {} - var r2 = c.foo(function (x) { - return ''; - }); // string - var r3 = c.foo(function (x) { - return ''; - }); // {} + var r = c.foo(function (x) { return ''; }); // {} + var r2 = c.foo(function (x) { return ''; }); // string + var r3 = c.foo(function (x) { return ''; }); // {} var C2 = (function () { function C2() { } @@ -96,12 +90,8 @@ var ImmediatelyFix; return C2; })(); var c2 = new C2(); - var ra = c2.foo(function (x) { - return 1; - }); // number - var r3a = c2.foo(function (x) { - return 1; - }); // number + var ra = c2.foo(function (x) { return 1; }); // number + var r3a = c2.foo(function (x) { return 1; }); // number })(ImmediatelyFix || (ImmediatelyFix = {})); var WithCandidates; (function (WithCandidates) { @@ -114,15 +104,9 @@ var WithCandidates; return C; })(); var c; - var r4 = c.foo2(1, function (a) { - return ''; - }); // string, contextual signature instantiation is applied to generic functions - var r5 = c.foo2(1, function (a) { - return ''; - }); // string - var r6 = c.foo2('', function (a) { - return 1; - }); // number + var r4 = c.foo2(1, function (a) { return ''; }); // string, contextual signature instantiation is applied to generic functions + var r5 = c.foo2(1, function (a) { return ''; }); // string + var r6 = c.foo2('', function (a) { return 1; }); // number var C2 = (function () { function C2() { } @@ -132,12 +116,8 @@ var WithCandidates; return C2; })(); var c2; - var r7 = c2.foo3(1, function (a) { - return ''; - }, ''); // string - var r8 = c2.foo3(1, function (a) { - return ''; - }, ''); // string + var r7 = c2.foo3(1, function (a) { return ''; }, ''); // string + var r8 = c2.foo3(1, function (a) { return ''; }, ''); // string var C3 = (function () { function C3() { } @@ -148,20 +128,10 @@ var WithCandidates; })(); var c3; function other(t, u) { - var r10 = c.foo2(1, function (x) { - return ''; - }); // error - var r10 = c.foo2(1, function (x) { - return ''; - }); // string - var r11 = c3.foo3(1, function (x) { - return ''; - }, ''); // error - var r11b = c3.foo3(1, function (x) { - return ''; - }, 1); // error - var r12 = c3.foo3(1, function (a) { - return ''; - }, 1); // error + var r10 = c.foo2(1, function (x) { return ''; }); // error + var r10 = c.foo2(1, function (x) { return ''; }); // string + var r11 = c3.foo3(1, function (x) { return ''; }, ''); // error + var r11b = c3.foo3(1, function (x) { return ''; }, 1); // error + var r12 = c3.foo3(1, function (a) { return ''; }, 1); // error } })(WithCandidates || (WithCandidates = {})); diff --git a/tests/baselines/reference/genericClassWithStaticsUsingTypeArguments.js b/tests/baselines/reference/genericClassWithStaticsUsingTypeArguments.js index 4aca0e3752..4caeacd19e 100644 --- a/tests/baselines/reference/genericClassWithStaticsUsingTypeArguments.js +++ b/tests/baselines/reference/genericClassWithStaticsUsingTypeArguments.js @@ -25,14 +25,9 @@ var Foo = (function () { Foo.f = function (xs) { return xs.reverse(); }; - Foo.a = function (n) { - }; + Foo.a = function (n) { }; Foo.c = []; - Foo.d = false || (function (x) { - return x || undefined; - })(null); - Foo.e = function (x) { - return null; - }; + Foo.d = false || (function (x) { return x || undefined; })(null); + Foo.e = function (x) { return null; }; return Foo; })(); diff --git a/tests/baselines/reference/genericCloduleInModule.js b/tests/baselines/reference/genericCloduleInModule.js index f393873569..92c519aa01 100644 --- a/tests/baselines/reference/genericCloduleInModule.js +++ b/tests/baselines/reference/genericCloduleInModule.js @@ -18,10 +18,8 @@ var A; var B = (function () { function B() { } - B.prototype.foo = function () { - }; - B.bar = function () { - }; + B.prototype.foo = function () { }; + B.bar = function () { }; return B; })(); A.B = B; diff --git a/tests/baselines/reference/genericCloduleInModule2.js b/tests/baselines/reference/genericCloduleInModule2.js index 1cb3bd6640..bb8021ffe8 100644 --- a/tests/baselines/reference/genericCloduleInModule2.js +++ b/tests/baselines/reference/genericCloduleInModule2.js @@ -21,10 +21,8 @@ var A; var B = (function () { function B() { } - B.prototype.foo = function () { - }; - B.bar = function () { - }; + B.prototype.foo = function () { }; + B.bar = function () { }; return B; })(); A.B = B; diff --git a/tests/baselines/reference/genericCombinators2.js b/tests/baselines/reference/genericCombinators2.js index af11f05619..a23f163a90 100644 --- a/tests/baselines/reference/genericCombinators2.js +++ b/tests/baselines/reference/genericCombinators2.js @@ -19,10 +19,6 @@ var r5b = _.map(c2, rf1); //// [genericCombinators2.js] var _; var c2; -var rf1 = function (x, y) { - return x.toFixed(); -}; -var r5a = _.map(c2, function (x, y) { - return x.toFixed(); -}); +var rf1 = function (x, y) { return x.toFixed(); }; +var r5a = _.map(c2, function (x, y) { return x.toFixed(); }); var r5b = _.map(c2, rf1); diff --git a/tests/baselines/reference/genericConstraintDeclaration.js b/tests/baselines/reference/genericConstraintDeclaration.js index cdf93d676d..6e3f8d5ff8 100644 --- a/tests/baselines/reference/genericConstraintDeclaration.js +++ b/tests/baselines/reference/genericConstraintDeclaration.js @@ -12,9 +12,7 @@ class List{ var List = (function () { function List() { } - List.empty = function () { - return null; - }; + List.empty = function () { return null; }; return List; })(); diff --git a/tests/baselines/reference/genericConstraintSatisfaction1.js b/tests/baselines/reference/genericConstraintSatisfaction1.js index b7438e6c45..9436e62b3b 100644 --- a/tests/baselines/reference/genericConstraintSatisfaction1.js +++ b/tests/baselines/reference/genericConstraintSatisfaction1.js @@ -9,6 +9,4 @@ x.f({s: 1}) //// [genericConstraintSatisfaction1.js] var x; -x.f({ - s: 1 -}); +x.f({ s: 1 }); diff --git a/tests/baselines/reference/genericContextualTypingSpecialization.js b/tests/baselines/reference/genericContextualTypingSpecialization.js index a577db15d3..75d8b995fa 100644 --- a/tests/baselines/reference/genericContextualTypingSpecialization.js +++ b/tests/baselines/reference/genericContextualTypingSpecialization.js @@ -4,6 +4,4 @@ b.reduce((c, d) => c + d, 0); // should not error on '+' //// [genericContextualTypingSpecialization.js] var b; -b.reduce(function (c, d) { - return c + d; -}, 0); // should not error on '+' +b.reduce(function (c, d) { return c + d; }, 0); // should not error on '+' diff --git a/tests/baselines/reference/genericFunctionHasFreshTypeArgs.js b/tests/baselines/reference/genericFunctionHasFreshTypeArgs.js index 77cad2cc87..30d57403ae 100644 --- a/tests/baselines/reference/genericFunctionHasFreshTypeArgs.js +++ b/tests/baselines/reference/genericFunctionHasFreshTypeArgs.js @@ -3,11 +3,6 @@ function f(p: (x: T) => void) { }; f(x => f(y => x = y)); //// [genericFunctionHasFreshTypeArgs.js] -function f(p) { -} +function f(p) { } ; -f(function (x) { - return f(function (y) { - return x = y; - }); -}); +f(function (x) { return f(function (y) { return x = y; }); }); diff --git a/tests/baselines/reference/genericFunctionSpecializations1.js b/tests/baselines/reference/genericFunctionSpecializations1.js index 2935959b69..c1043f792b 100644 --- a/tests/baselines/reference/genericFunctionSpecializations1.js +++ b/tests/baselines/reference/genericFunctionSpecializations1.js @@ -6,7 +6,5 @@ function foo4(test: string); // valid function foo4(test: T) { } //// [genericFunctionSpecializations1.js] -function foo3(test) { -} -function foo4(test) { -} +function foo3(test) { } +function foo4(test) { } diff --git a/tests/baselines/reference/genericFunctionTypedArgumentsAreFixed.js b/tests/baselines/reference/genericFunctionTypedArgumentsAreFixed.js index c1a8daa6a1..e9db28578f 100644 --- a/tests/baselines/reference/genericFunctionTypedArgumentsAreFixed.js +++ b/tests/baselines/reference/genericFunctionTypedArgumentsAreFixed.js @@ -3,8 +3,4 @@ declare function map(f: (x: T) => U, xs: T[]): U[]; map((a) => a.length, [1]); //// [genericFunctionTypedArgumentsAreFixed.js] -map(function (a) { - return a.length; -}, [ - 1 -]); +map(function (a) { return a.length; }, [1]); diff --git a/tests/baselines/reference/genericFunctions0.js b/tests/baselines/reference/genericFunctions0.js index 408abdb9ce..b52f058352 100644 --- a/tests/baselines/reference/genericFunctions0.js +++ b/tests/baselines/reference/genericFunctions0.js @@ -4,9 +4,7 @@ function foo (x: T) { return x; } var x = foo(5); // 'x' should be number //// [genericFunctions0.js] -function foo(x) { - return x; -} +function foo(x) { return x; } var x = foo(5); // 'x' should be number diff --git a/tests/baselines/reference/genericFunctions1.js b/tests/baselines/reference/genericFunctions1.js index 25cc91820b..d9bb341389 100644 --- a/tests/baselines/reference/genericFunctions1.js +++ b/tests/baselines/reference/genericFunctions1.js @@ -4,9 +4,7 @@ function foo (x: T) { return x; } var x = foo(5); // 'x' should be number //// [genericFunctions1.js] -function foo(x) { - return x; -} +function foo(x) { return x; } var x = foo(5); // 'x' should be number diff --git a/tests/baselines/reference/genericFunctions2.js b/tests/baselines/reference/genericFunctions2.js index ec01cc885b..f14c1be6dc 100644 --- a/tests/baselines/reference/genericFunctions2.js +++ b/tests/baselines/reference/genericFunctions2.js @@ -8,9 +8,7 @@ var lengths = map(myItems, x => x.length); //// [genericFunctions2.js] var myItems; -var lengths = map(myItems, function (x) { - return x.length; -}); +var lengths = map(myItems, function (x) { return x.length; }); //// [genericFunctions2.d.ts] diff --git a/tests/baselines/reference/genericFunctionsWithOptionalParameters3.js b/tests/baselines/reference/genericFunctionsWithOptionalParameters3.js index 2a5ce0a333..9ad885a899 100644 --- a/tests/baselines/reference/genericFunctionsWithOptionalParameters3.js +++ b/tests/baselines/reference/genericFunctionsWithOptionalParameters3.js @@ -19,26 +19,13 @@ var r5 = utils.mapReduce(c, f1, f2); var Collection = (function () { function Collection() { } - Collection.prototype.add = function (x) { - }; + Collection.prototype.add = function (x) { }; return Collection; })(); var utils; var c = new Collection(); -var r3 = utils.mapReduce(c, function (x) { - return 1; -}, function (y) { - return new Date(); -}); -var r4 = utils.mapReduce(c, function (x) { - return 1; -}, function (y) { - return new Date(); -}); -var f1 = function (x) { - return 1; -}; -var f2 = function (y) { - return new Date(); -}; +var r3 = utils.mapReduce(c, function (x) { return 1; }, function (y) { return new Date(); }); +var r4 = utils.mapReduce(c, function (x) { return 1; }, function (y) { return new Date(); }); +var f1 = function (x) { return 1; }; +var f2 = function (y) { return new Date(); }; var r5 = utils.mapReduce(c, f1, f2); diff --git a/tests/baselines/reference/genericFunduleInModule.js b/tests/baselines/reference/genericFunduleInModule.js index 5a85a46a39..95700edeca 100644 --- a/tests/baselines/reference/genericFunduleInModule.js +++ b/tests/baselines/reference/genericFunduleInModule.js @@ -12,9 +12,7 @@ A.B(1); //// [genericFunduleInModule.js] var A; (function (A) { - function B(x) { - return x; - } + function B(x) { return x; } A.B = B; var B; (function (B) { diff --git a/tests/baselines/reference/genericFunduleInModule2.js b/tests/baselines/reference/genericFunduleInModule2.js index 6b5a0a74e2..956e9129ec 100644 --- a/tests/baselines/reference/genericFunduleInModule2.js +++ b/tests/baselines/reference/genericFunduleInModule2.js @@ -15,9 +15,7 @@ A.B(1); //// [genericFunduleInModule2.js] var A; (function (A) { - function B(x) { - return x; - } + function B(x) { return x; } A.B = B; })(A || (A = {})); var A; diff --git a/tests/baselines/reference/genericImplements.js b/tests/baselines/reference/genericImplements.js index 17d3d2c0d2..b8d295153a 100644 --- a/tests/baselines/reference/genericImplements.js +++ b/tests/baselines/reference/genericImplements.js @@ -37,26 +37,20 @@ var B = (function () { var X = (function () { function X() { } - X.prototype.f = function () { - return undefined; - }; + X.prototype.f = function () { return undefined; }; return X; })(); // { f: () => { b; } } // OK var Y = (function () { function Y() { } - Y.prototype.f = function () { - return undefined; - }; + Y.prototype.f = function () { return undefined; }; return Y; })(); // { f: () => { a; } } // OK var Z = (function () { function Z() { } - Z.prototype.f = function () { - return undefined; - }; + Z.prototype.f = function () { return undefined; }; return Z; })(); // { f: () => T } diff --git a/tests/baselines/reference/genericInference1.js b/tests/baselines/reference/genericInference1.js index 26a9297029..dc81b9a955 100644 --- a/tests/baselines/reference/genericInference1.js +++ b/tests/baselines/reference/genericInference1.js @@ -2,10 +2,4 @@ ['a', 'b', 'c'].map(x => x.length); //// [genericInference1.js] -[ - 'a', - 'b', - 'c' -].map(function (x) { - return x.length; -}); +['a', 'b', 'c'].map(function (x) { return x.length; }); diff --git a/tests/baselines/reference/genericInterfaceTypeCall.js b/tests/baselines/reference/genericInterfaceTypeCall.js index f171fa6e36..7f5f586ec1 100644 --- a/tests/baselines/reference/genericInterfaceTypeCall.js +++ b/tests/baselines/reference/genericInterfaceTypeCall.js @@ -17,9 +17,5 @@ test.fail2(arg => foo.reject(arg)); // Error: Supplied parameters do not match a //// [genericInterfaceTypeCall.js] var foo; var test; -test.fail(function (arg) { - return foo.reject(arg); -}); -test.fail2(function (arg) { - return foo.reject(arg); -}); // Error: Supplied parameters do not match any signature of call target +test.fail(function (arg) { return foo.reject(arg); }); +test.fail2(function (arg) { return foo.reject(arg); }); // Error: Supplied parameters do not match any signature of call target diff --git a/tests/baselines/reference/genericLambaArgWithoutTypeArguments.js b/tests/baselines/reference/genericLambaArgWithoutTypeArguments.js index f57f6713c9..e1cc5cadbd 100644 --- a/tests/baselines/reference/genericLambaArgWithoutTypeArguments.js +++ b/tests/baselines/reference/genericLambaArgWithoutTypeArguments.js @@ -12,6 +12,4 @@ foo((arg: Foo) => { return arg.x; }); function foo(a) { return null; } -foo(function (arg) { - return arg.x; -}); +foo(function (arg) { return arg.x; }); diff --git a/tests/baselines/reference/genericMergedDeclarationUsingTypeParameter.js b/tests/baselines/reference/genericMergedDeclarationUsingTypeParameter.js index 5d4ecdc083..9b0fbf4bca 100644 --- a/tests/baselines/reference/genericMergedDeclarationUsingTypeParameter.js +++ b/tests/baselines/reference/genericMergedDeclarationUsingTypeParameter.js @@ -7,9 +7,7 @@ module foo { //// [genericMergedDeclarationUsingTypeParameter.js] -function foo(y, z) { - return y; -} +function foo(y, z) { return y; } var foo; (function (foo) { foo.x; diff --git a/tests/baselines/reference/genericMethodOverspecialization.js b/tests/baselines/reference/genericMethodOverspecialization.js index 04d1466cfc..6ec28922af 100644 --- a/tests/baselines/reference/genericMethodOverspecialization.js +++ b/tests/baselines/reference/genericMethodOverspecialization.js @@ -27,13 +27,7 @@ var widths:number[] = elements.map(function (e) { // should not error //// [genericMethodOverspecialization.js] -var names = [ - "list", - "table1", - "table2", - "table3", - "summary" -]; +var names = ["list", "table1", "table2", "table3", "summary"]; var elements = names.map(function (name) { return document.getElementById(name); }); diff --git a/tests/baselines/reference/genericObjectLitReturnType.js b/tests/baselines/reference/genericObjectLitReturnType.js index 327da9ce0f..826f5233b5 100644 --- a/tests/baselines/reference/genericObjectLitReturnType.js +++ b/tests/baselines/reference/genericObjectLitReturnType.js @@ -15,11 +15,7 @@ t1.a = 5; // Should not error: t1 should have type {a: number}, instead has type var X = (function () { function X() { } - X.prototype.f = function (t) { - return { - a: t - }; - }; + X.prototype.f = function (t) { return { a: t }; }; return X; })(); var x; diff --git a/tests/baselines/reference/genericOfACloduleType1.js b/tests/baselines/reference/genericOfACloduleType1.js index 435575b015..1f115aa486 100644 --- a/tests/baselines/reference/genericOfACloduleType1.js +++ b/tests/baselines/reference/genericOfACloduleType1.js @@ -16,9 +16,7 @@ var g2 = new G() // was: error Type reference cannot refer to container 'M. var G = (function () { function G() { } - G.prototype.bar = function (x) { - return x; - }; + G.prototype.bar = function (x) { return x; }; return G; })(); var M; @@ -26,8 +24,7 @@ var M; var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); M.C = C; diff --git a/tests/baselines/reference/genericOfACloduleType2.js b/tests/baselines/reference/genericOfACloduleType2.js index 4c73addcf7..1d671289cb 100644 --- a/tests/baselines/reference/genericOfACloduleType2.js +++ b/tests/baselines/reference/genericOfACloduleType2.js @@ -19,9 +19,7 @@ module N { var G = (function () { function G() { } - G.prototype.bar = function (x) { - return x; - }; + G.prototype.bar = function (x) { return x; }; return G; })(); var M; @@ -29,8 +27,7 @@ var M; var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); M.C = C; diff --git a/tests/baselines/reference/genericOverloadSignatures.js b/tests/baselines/reference/genericOverloadSignatures.js index ec4c9ba74d..45a21d5a33 100644 --- a/tests/baselines/reference/genericOverloadSignatures.js +++ b/tests/baselines/reference/genericOverloadSignatures.js @@ -31,8 +31,7 @@ interface D { } //// [genericOverloadSignatures.js] -function f(a) { -} +function f(a) { } var C2 = (function () { function C2() { } diff --git a/tests/baselines/reference/genericParameterAssignability1.js b/tests/baselines/reference/genericParameterAssignability1.js index ae8eb4348d..a6a465b408 100644 --- a/tests/baselines/reference/genericParameterAssignability1.js +++ b/tests/baselines/reference/genericParameterAssignability1.js @@ -4,10 +4,6 @@ var r = (x: T) => x; r = f; // should be allowed //// [genericParameterAssignability1.js] -function f(x) { - return null; -} -var r = function (x) { - return x; -}; +function f(x) { return null; } +var r = function (x) { return x; }; r = f; // should be allowed diff --git a/tests/baselines/reference/genericPrototypeProperty.js b/tests/baselines/reference/genericPrototypeProperty.js index c38cdb753a..fb6f9b7884 100644 --- a/tests/baselines/reference/genericPrototypeProperty.js +++ b/tests/baselines/reference/genericPrototypeProperty.js @@ -13,9 +13,7 @@ var r3 = r.foo(null); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var r = C.prototype; diff --git a/tests/baselines/reference/genericRecursiveImplicitConstructorErrors3.js b/tests/baselines/reference/genericRecursiveImplicitConstructorErrors3.js index 11113b778d..e01c904534 100644 --- a/tests/baselines/reference/genericRecursiveImplicitConstructorErrors3.js +++ b/tests/baselines/reference/genericRecursiveImplicitConstructorErrors3.js @@ -69,7 +69,10 @@ var TypeScript; }; PullTypeSymbol.prototype.getScopedNameEx = function (scopeSymbol, useConstraintInName, getPrettyTypeName, getTypeParamMarkerInfo) { if (this.isArray()) { - var elementMemberName = this._elementType ? (this._elementType.isArray() || this._elementType.isNamedTypeSymbol() ? this._elementType.getScopedNameEx(scopeSymbol, false, getPrettyTypeName, getTypeParamMarkerInfo) : this._elementType.getMemberTypeNameEx(false, scopeSymbol, getPrettyTypeName)) : 1; + var elementMemberName = this._elementType ? + (this._elementType.isArray() || this._elementType.isNamedTypeSymbol() ? + this._elementType.getScopedNameEx(scopeSymbol, false, getPrettyTypeName, getTypeParamMarkerInfo) : + this._elementType.getMemberTypeNameEx(false, scopeSymbol, getPrettyTypeName)) : 1; return TypeScript.MemberName.create(elementMemberName, "", "[]"); } }; diff --git a/tests/baselines/reference/genericReduce.js b/tests/baselines/reference/genericReduce.js index c725df8d8e..ac160e4386 100644 --- a/tests/baselines/reference/genericReduce.js +++ b/tests/baselines/reference/genericReduce.js @@ -14,27 +14,14 @@ n3.toExponential(2); // should error if 'n3' is correctly type 'string' n3.charAt(0); // should not error if 'n3' is correctly type 'string' //// [genericReduce.js] -var a = [ - "An", - "array", - "of", - "strings" -]; -var b = a.map(function (s) { - return s.length; -}); -var n1 = b.reduce(function (x, y) { - return x + y; -}); -var n2 = b.reduceRight(function (x, y) { - return x + y; -}); +var a = ["An", "array", "of", "strings"]; +var b = a.map(function (s) { return s.length; }); +var n1 = b.reduce(function (x, y) { return x + y; }); +var n2 = b.reduceRight(function (x, y) { return x + y; }); n1.x = "fail"; // should error, as 'n1' should be type 'number', not 'any'. n1.toExponential(2); // should not error if 'n1' is correctly number. n2.x = "fail"; // should error, as 'n2' should be type 'number', not 'any'. n2.toExponential(2); // should not error if 'n2' is correctly number. -var n3 = b.reduce(function (x, y) { - return x + y; -}, ""); // Initial value is of type string +var n3 = b.reduce(function (x, y) { return x + y; }, ""); // Initial value is of type string n3.toExponential(2); // should error if 'n3' is correctly type 'string' n3.charAt(0); // should not error if 'n3' is correctly type 'string' diff --git a/tests/baselines/reference/genericRestArgs.js b/tests/baselines/reference/genericRestArgs.js index 4c2ddcf0cd..75c88d7cbf 100644 --- a/tests/baselines/reference/genericRestArgs.js +++ b/tests/baselines/reference/genericRestArgs.js @@ -25,11 +25,7 @@ var a1Gb = makeArrayG(1, ""); var a1Gc = makeArrayG(1, ""); var a1Gd = makeArrayG(1, ""); // error function makeArrayGOpt(item1, item2, item3) { - return [ - item1, - item2, - item3 - ]; + return [item1, item2, item3]; } var a2Ga = makeArrayGOpt(1, ""); var a2Gb = makeArrayG(1, ""); diff --git a/tests/baselines/reference/genericReturnTypeFromGetter1.js b/tests/baselines/reference/genericReturnTypeFromGetter1.js index 208b12308e..741c721834 100644 --- a/tests/baselines/reference/genericReturnTypeFromGetter1.js +++ b/tests/baselines/reference/genericReturnTypeFromGetter1.js @@ -14,9 +14,7 @@ define(["require", "exports"], function (require, exports) { function DbSet() { } Object.defineProperty(DbSet.prototype, "entityType", { - get: function () { - return this._entityType; - } // used to ICE without return type annotation + get: function () { return this._entityType; } // used to ICE without return type annotation , enumerable: true, configurable: true diff --git a/tests/baselines/reference/genericReversingTypeParameters.js b/tests/baselines/reference/genericReversingTypeParameters.js index 0e51b0256e..2a52c2e9ba 100644 --- a/tests/baselines/reference/genericReversingTypeParameters.js +++ b/tests/baselines/reference/genericReversingTypeParameters.js @@ -14,12 +14,8 @@ var r2b = i.get(1); var BiMap = (function () { function BiMap() { } - BiMap.prototype.get = function (key) { - return null; - }; - BiMap.prototype.inverse = function () { - return null; - }; + BiMap.prototype.get = function (key) { return null; }; + BiMap.prototype.inverse = function () { return null; }; return BiMap; })(); var b = new BiMap(); diff --git a/tests/baselines/reference/genericReversingTypeParameters2.js b/tests/baselines/reference/genericReversingTypeParameters2.js index eb904f4a2e..4f4bc564f8 100644 --- a/tests/baselines/reference/genericReversingTypeParameters2.js +++ b/tests/baselines/reference/genericReversingTypeParameters2.js @@ -13,12 +13,8 @@ var r2b = i.get(1); var BiMap = (function () { function BiMap() { } - BiMap.prototype.get = function (key) { - return null; - }; - BiMap.prototype.inverse = function () { - return null; - }; + BiMap.prototype.get = function (key) { return null; }; + BiMap.prototype.inverse = function () { return null; }; return BiMap; })(); var b = new BiMap(); diff --git a/tests/baselines/reference/genericSpecializations1.js b/tests/baselines/reference/genericSpecializations1.js index 3df2c5581b..3e59fceff9 100644 --- a/tests/baselines/reference/genericSpecializations1.js +++ b/tests/baselines/reference/genericSpecializations1.js @@ -19,24 +19,18 @@ class StringFoo3 implements IFoo { var IntFooBad = (function () { function IntFooBad() { } - IntFooBad.prototype.foo = function (x) { - return null; - }; + IntFooBad.prototype.foo = function (x) { return null; }; return IntFooBad; })(); var StringFoo2 = (function () { function StringFoo2() { } - StringFoo2.prototype.foo = function (x) { - return null; - }; + StringFoo2.prototype.foo = function (x) { return null; }; return StringFoo2; })(); var StringFoo3 = (function () { function StringFoo3() { } - StringFoo3.prototype.foo = function (x) { - return null; - }; + StringFoo3.prototype.foo = function (x) { return null; }; return StringFoo3; })(); diff --git a/tests/baselines/reference/genericSpecializations2.js b/tests/baselines/reference/genericSpecializations2.js index 666ea43eeb..8497d2db8b 100644 --- a/tests/baselines/reference/genericSpecializations2.js +++ b/tests/baselines/reference/genericSpecializations2.js @@ -31,24 +31,18 @@ var IFoo = (function () { var IntFooBad = (function () { function IntFooBad() { } - IntFooBad.prototype.foo = function (x) { - return null; - }; + IntFooBad.prototype.foo = function (x) { return null; }; return IntFooBad; })(); var StringFoo2 = (function () { function StringFoo2() { } - StringFoo2.prototype.foo = function (x) { - return null; - }; + StringFoo2.prototype.foo = function (x) { return null; }; return StringFoo2; })(); var StringFoo3 = (function () { function StringFoo3() { } - StringFoo3.prototype.foo = function (x) { - return null; - }; + StringFoo3.prototype.foo = function (x) { return null; }; return StringFoo3; })(); diff --git a/tests/baselines/reference/genericSpecializations3.js b/tests/baselines/reference/genericSpecializations3.js index 8d15776116..3c582ae31f 100644 --- a/tests/baselines/reference/genericSpecializations3.js +++ b/tests/baselines/reference/genericSpecializations3.js @@ -41,27 +41,21 @@ iFoo.foo(1); var IntFooBad = (function () { function IntFooBad() { } - IntFooBad.prototype.foo = function (x) { - return null; - }; + IntFooBad.prototype.foo = function (x) { return null; }; return IntFooBad; })(); var intFooBad; var IntFoo = (function () { function IntFoo() { } - IntFoo.prototype.foo = function (x) { - return null; - }; + IntFoo.prototype.foo = function (x) { return null; }; return IntFoo; })(); var intFoo; var StringFoo2 = (function () { function StringFoo2() { } - StringFoo2.prototype.foo = function (x) { - return null; - }; + StringFoo2.prototype.foo = function (x) { return null; }; return StringFoo2; })(); var stringFoo2; @@ -71,9 +65,7 @@ stringFoo2 = intFoo; // error var StringFoo3 = (function () { function StringFoo3() { } - StringFoo3.prototype.foo = function (x) { - return null; - }; + StringFoo3.prototype.foo = function (x) { return null; }; return StringFoo3; })(); var stringFoo3; diff --git a/tests/baselines/reference/genericStaticAnyTypeFunction.js b/tests/baselines/reference/genericStaticAnyTypeFunction.js index 055e6b4f68..6816afec91 100644 --- a/tests/baselines/reference/genericStaticAnyTypeFunction.js +++ b/tests/baselines/reference/genericStaticAnyTypeFunction.js @@ -25,9 +25,7 @@ var A = (function () { A.one = function (source, value) { return source; }; - A.goo = function () { - return 0; - }; + A.goo = function () { return 0; }; A.two = function (source) { return this.one(source, 42); // should not error }; diff --git a/tests/baselines/reference/genericTypeArgumentInference1.js b/tests/baselines/reference/genericTypeArgumentInference1.js index 8bf6f35cb3..48c279f52c 100644 --- a/tests/baselines/reference/genericTypeArgumentInference1.js +++ b/tests/baselines/reference/genericTypeArgumentInference1.js @@ -17,16 +17,7 @@ var r4 = _.all([true], _.identity); //// [genericTypeArgumentInference1.js] -var r = _.all([ - true, - 1, - null, - 'yes' -], _.identity); -var r2 = _.all([ - true -], _.identity); +var r = _.all([true, 1, null, 'yes'], _.identity); +var r2 = _.all([true], _.identity); var r3 = _.all([], _.identity); -var r4 = _.all([ - true -], _.identity); +var r4 = _.all([true], _.identity); diff --git a/tests/baselines/reference/genericTypeAssertions1.js b/tests/baselines/reference/genericTypeAssertions1.js index 02a22aa5c8..54637007d9 100644 --- a/tests/baselines/reference/genericTypeAssertions1.js +++ b/tests/baselines/reference/genericTypeAssertions1.js @@ -8,8 +8,7 @@ var r2: A = >>foo; // error var A = (function () { function A() { } - A.prototype.foo = function (x) { - }; + A.prototype.foo = function (x) { }; return A; })(); var foo = new A(); diff --git a/tests/baselines/reference/genericTypeAssertions2.js b/tests/baselines/reference/genericTypeAssertions2.js index c7acecb5e4..3c904c7a30 100644 --- a/tests/baselines/reference/genericTypeAssertions2.js +++ b/tests/baselines/reference/genericTypeAssertions2.js @@ -23,8 +23,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function (x) { - }; + A.prototype.foo = function (x) { }; return A; })(); var B = (function (_super) { diff --git a/tests/baselines/reference/genericTypeAssertions3.js b/tests/baselines/reference/genericTypeAssertions3.js index 19a477c142..b67a277654 100644 --- a/tests/baselines/reference/genericTypeAssertions3.js +++ b/tests/baselines/reference/genericTypeAssertions3.js @@ -4,9 +4,5 @@ var s = < (x: T) => T > ((x: any) => { return null; }); // no error //// [genericTypeAssertions3.js] -var r = (function (x) { - return null; -}); // bug was 'could not find dotted symbol T' on x's annotation in the type assertion instead of no error -var s = (function (x) { - return null; -}); // no error +var r = (function (x) { return null; }); // bug was 'could not find dotted symbol T' on x's annotation in the type assertion instead of no error +var s = (function (x) { return null; }); // no error diff --git a/tests/baselines/reference/genericTypeAssertions4.js b/tests/baselines/reference/genericTypeAssertions4.js index d04b6cbe10..a607fb0742 100644 --- a/tests/baselines/reference/genericTypeAssertions4.js +++ b/tests/baselines/reference/genericTypeAssertions4.js @@ -35,9 +35,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - return ""; - }; + A.prototype.foo = function () { return ""; }; return A; })(); var B = (function (_super) { @@ -45,9 +43,7 @@ var B = (function (_super) { function B() { _super.apply(this, arguments); } - B.prototype.bar = function () { - return 1; - }; + B.prototype.bar = function () { return 1; }; return B; })(A); var C = (function (_super) { @@ -55,9 +51,7 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype.baz = function () { - return 1; - }; + C.prototype.baz = function () { return 1; }; return C; })(A); var a; diff --git a/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument.js b/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument.js index dbda607483..4be1cce27a 100644 --- a/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument.js +++ b/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument.js @@ -55,18 +55,9 @@ var c; var a; var b; var d; -var e = function (x) { - var y; - return y; -}; -function f(x) { - var y; - return y; -} -var g = function f(x) { - var y; - return y; -}; +var e = function (x) { var y; return y; }; +function f(x) { var y; return y; } +var g = function f(x) { var y; return y; }; var D = (function (_super) { __extends(D, _super); function D() { @@ -95,9 +86,7 @@ var D3 = (function () { } return D3; })(); -function h(x) { -} -function i(x) { -} +function h(x) { } +function i(x) { } var j = null; var k = null; diff --git a/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument2.js b/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument2.js index f6a2207370..803d499705 100644 --- a/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument2.js +++ b/tests/baselines/reference/genericTypeReferenceWithoutTypeArgument2.js @@ -50,18 +50,9 @@ var c; var a; var b; var d; -var e = function (x) { - var y; - return y; -}; -function f(x) { - var y; - return y; -} -var g = function f(x) { - var y; - return y; -}; +var e = function (x) { var y; return y; }; +function f(x) { var y; return y; } +var g = function f(x) { var y; return y; }; var D = (function (_super) { __extends(D, _super); function D() { @@ -76,9 +67,7 @@ var D2 = (function (_super) { } return D2; })(M.C); -function h(x) { -} -function i(x) { -} +function h(x) { } +function i(x) { } var j = null; var k = null; diff --git a/tests/baselines/reference/genericTypeReferencesRequireTypeArgs.js b/tests/baselines/reference/genericTypeReferencesRequireTypeArgs.js index 69bc1c372b..90ad9e1ff9 100644 --- a/tests/baselines/reference/genericTypeReferencesRequireTypeArgs.js +++ b/tests/baselines/reference/genericTypeReferencesRequireTypeArgs.js @@ -15,9 +15,7 @@ var i2: I; // should be an error var C = (function () { function C() { } - C.prototype.foo = function () { - return null; - }; + C.prototype.foo = function () { return null; }; return C; })(); var c1; // error diff --git a/tests/baselines/reference/genericTypeWithNonGenericBaseMisMatch.js b/tests/baselines/reference/genericTypeWithNonGenericBaseMisMatch.js index 4cd7eb4165..1a57b866d9 100644 --- a/tests/baselines/reference/genericTypeWithNonGenericBaseMisMatch.js +++ b/tests/baselines/reference/genericTypeWithNonGenericBaseMisMatch.js @@ -13,8 +13,7 @@ var i: I = x; // Should not be allowed -- type of 'f' is incompatible with 'I' var X = (function () { function X() { } - X.prototype.f = function (a) { - }; + X.prototype.f = function (a) { }; return X; })(); var x = new X(); diff --git a/tests/baselines/reference/genericWithIndexerOfTypeParameterType2.js b/tests/baselines/reference/genericWithIndexerOfTypeParameterType2.js index f0a5743054..fdd2e470a5 100644 --- a/tests/baselines/reference/genericWithIndexerOfTypeParameterType2.js +++ b/tests/baselines/reference/genericWithIndexerOfTypeParameterType2.js @@ -33,8 +33,7 @@ define(["require", "exports"], function (require, exports) { function List() { _super.apply(this, arguments); } - List.prototype.Bar = function () { - }; + List.prototype.Bar = function () { }; return List; })(Collection); exports.List = List; diff --git a/tests/baselines/reference/genericWithOpenTypeParameters1.js b/tests/baselines/reference/genericWithOpenTypeParameters1.js index afdce73cb1..9020276701 100644 --- a/tests/baselines/reference/genericWithOpenTypeParameters1.js +++ b/tests/baselines/reference/genericWithOpenTypeParameters1.js @@ -15,22 +15,12 @@ var f4 = (x: B) => { return x.foo(1); } // no error var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var x; x.foo(1); // no error -var f = function (x) { - return x.foo(1); -}; // error -var f2 = function (x) { - return x.foo(1); -}; // error -var f3 = function (x) { - return x.foo(1); -}; // error -var f4 = function (x) { - return x.foo(1); -}; // no error +var f = function (x) { return x.foo(1); }; // error +var f2 = function (x) { return x.foo(1); }; // error +var f3 = function (x) { return x.foo(1); }; // error +var f4 = function (x) { return x.foo(1); }; // no error diff --git a/tests/baselines/reference/genericsAndHigherOrderFunctions.js b/tests/baselines/reference/genericsAndHigherOrderFunctions.js index ad03dccbca..f2e6ef58f2 100644 --- a/tests/baselines/reference/genericsAndHigherOrderFunctions.js +++ b/tests/baselines/reference/genericsAndHigherOrderFunctions.js @@ -21,15 +21,11 @@ var foo: (g: (x: K) => N) => // no errors expected var combine = function (f) { return function (g) { - return function (x) { - return f(g(x)); - }; + return function (x) { return f(g(x)); }; }; }; var foo = function (g) { return function (h) { - return function (f) { - return h(combine(f)(g)); - }; + return function (f) { return h(combine(f)(g)); }; }; }; diff --git a/tests/baselines/reference/genericsManyTypeParameters.js b/tests/baselines/reference/genericsManyTypeParameters.js index 09cb7658c1..491f0c4116 100644 --- a/tests/baselines/reference/genericsManyTypeParameters.js +++ b/tests/baselines/reference/genericsManyTypeParameters.js @@ -61,114 +61,22 @@ function Foo< //// [genericsManyTypeParameters.js] function Foo(x1, y1, z1, a1, b1, c1, x2, y2, z2, a2, b2, c2, x3, y3, z3, a3, b3, c3, x4, y4, z4, a4, b4, c4, x5, y5, z5, a5, b5, c5, x6, y6, z6, a6, b6, c6, x7, y7, z7, a7, b7, c7, x8, y8, z8, a8, b8, c8, x9, y9, z9, a9, b9, c9, x10, y12, z10, a10, b10, c10, x11, y13, z11, a11, b11, c11, x12, y14, z12, a12, b12, c12, x13, y15, z13, a13, b13, c13, x14, y16, z14, a14, b14, c14, x15, y17, z15, a15, b15, c15, x16, y18, z16, a16, b16, c16, x17, y19, z17, a17, b17, c17, x18, y10, z18, a18, b18, c18) { - return [ - x1, - y1, - z1, - a1, - b1, - c1, - x2, - y2, - z2, - a2, - b2, - c2, - x3, - y3, - z3, - a3, - b3, - c3, - x4, - y4, - z4, - a4, - b4, - c4, - x5, - y5, - z5, - a5, - b5, - c5, - x6, - y6, - z6, - a6, - b6, - c6, - x7, - y7, - z7, - a7, - b7, - c7, - x8, - y8, - z8, - a8, - b8, - c8, - x9, - y9, - z9, - a9, - b9, - c9, - x10, - y12, - z10, - a10, - b10, - c10, - x11, - y13, - z11, - a11, - b11, - c11, - x12, - y14, - z12, - a12, - b12, - c12, - x13, - y15, - z13, - a13, - b13, - c13, - x14, - y16, - z14, - a14, - b14, - c14, - x15, - y17, - z15, - a15, - b15, - c15, - x16, - y18, - z16, - a16, - b16, - c16, - x17, - y19, - z17, - a17, - b17, - c17, - x18, - y10, - z18, - a18, - b18, - c18 - ]; + return [x1, y1, z1, a1, b1, c1, + x2, y2, z2, a2, b2, c2, + x3, y3, z3, a3, b3, c3, + x4, y4, z4, a4, b4, c4, + x5, y5, z5, a5, b5, c5, + x6, y6, z6, a6, b6, c6, + x7, y7, z7, a7, b7, c7, + x8, y8, z8, a8, b8, c8, + x9, y9, z9, a9, b9, c9, + x10, y12, z10, a10, b10, c10, + x11, y13, z11, a11, b11, c11, + x12, y14, z12, a12, b12, c12, + x13, y15, z13, a13, b13, c13, + x14, y16, z14, a14, b14, c14, + x15, y17, z15, a15, b15, c15, + x16, y18, z16, a16, b16, c16, + x17, y19, z17, a17, b17, c17, + x18, y10, z18, a18, b18, c18]; } diff --git a/tests/baselines/reference/genericsWithDuplicateTypeParameters1.js b/tests/baselines/reference/genericsWithDuplicateTypeParameters1.js index f7f638f10e..72eeb1ab68 100644 --- a/tests/baselines/reference/genericsWithDuplicateTypeParameters1.js +++ b/tests/baselines/reference/genericsWithDuplicateTypeParameters1.js @@ -17,25 +17,16 @@ var m = { } //// [genericsWithDuplicateTypeParameters1.js] -function f() { -} -function f2(a, b) { - return null; -} +function f() { } +function f2(a, b) { return null; } var C = (function () { function C() { } - C.prototype.f = function () { - }; - C.prototype.f2 = function (a, b) { - return null; - }; + C.prototype.f = function () { }; + C.prototype.f2 = function (a, b) { return null; }; return C; })(); var m = { - a: function f() { - }, - b: function f2(a, b) { - return null; - } + a: function f() { }, + b: function f2(a, b) { return null; } }; diff --git a/tests/baselines/reference/genericsWithoutTypeParameters1.js b/tests/baselines/reference/genericsWithoutTypeParameters1.js index b4bc079cf8..41abffcb85 100644 --- a/tests/baselines/reference/genericsWithoutTypeParameters1.js +++ b/tests/baselines/reference/genericsWithoutTypeParameters1.js @@ -37,29 +37,17 @@ function f(x: T): A { var C = (function () { function C() { } - C.prototype.foo = function () { - return null; - }; + C.prototype.foo = function () { return null; }; return C; })(); var c1; var i1; var c2; var i2; -function foo(x, y) { -} -function foo2(x, y) { -} -var x = { - a: new C() -}; -var x2 = { - a: { - bar: function () { - return 1; - } - } -}; +function foo(x, y) { } +function foo2(x, y) { } +var x = { a: new C() }; +var x2 = { a: { bar: function () { return 1; } } }; var D = (function () { function D() { } diff --git a/tests/baselines/reference/getAndSetAsMemberNames.js b/tests/baselines/reference/getAndSetAsMemberNames.js index 22f99920fb..8b036cd0f7 100644 --- a/tests/baselines/reference/getAndSetAsMemberNames.js +++ b/tests/baselines/reference/getAndSetAsMemberNames.js @@ -49,16 +49,11 @@ var C4 = (function () { })(); var C5 = (function () { function C5() { - this.set = function () { - return true; - }; + this.set = function () { return true; }; } - C5.prototype.get = function () { - return true; - }; + C5.prototype.get = function () { return true; }; Object.defineProperty(C5.prototype, "t", { - set: function (x) { - }, + set: function (x) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/getAndSetNotIdenticalType.js b/tests/baselines/reference/getAndSetNotIdenticalType.js index 7e77fc25d0..e6eb7fecc8 100644 --- a/tests/baselines/reference/getAndSetNotIdenticalType.js +++ b/tests/baselines/reference/getAndSetNotIdenticalType.js @@ -14,8 +14,7 @@ var C = (function () { get: function () { return 1; }, - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/getsetReturnTypes.js b/tests/baselines/reference/getsetReturnTypes.js index 55d7e9285b..27b6fc52fe 100644 --- a/tests/baselines/reference/getsetReturnTypes.js +++ b/tests/baselines/reference/getsetReturnTypes.js @@ -10,9 +10,7 @@ var y: number = makePoint(2).x; //// [getsetReturnTypes.js] function makePoint(x) { return { - get x() { - return x; - } + get x() { return x; } }; } ; diff --git a/tests/baselines/reference/getterSetterNonAccessor.js b/tests/baselines/reference/getterSetterNonAccessor.js index e234574d73..c28337ff7b 100644 --- a/tests/baselines/reference/getterSetterNonAccessor.js +++ b/tests/baselines/reference/getterSetterNonAccessor.js @@ -10,11 +10,8 @@ Object.defineProperty({}, "0", ({ //// [getterSetterNonAccessor.js] -function getFunc() { - return 0; -} -function setFunc(v) { -} +function getFunc() { return 0; } +function setFunc(v) { } Object.defineProperty({}, "0", ({ get: getFunc, set: setFunc, diff --git a/tests/baselines/reference/gettersAndSetters.js b/tests/baselines/reference/gettersAndSetters.js index ded5421340..92f959e598 100644 --- a/tests/baselines/reference/gettersAndSetters.js +++ b/tests/baselines/reference/gettersAndSetters.js @@ -46,31 +46,21 @@ var C = (function () { function C() { this.fooBack = ""; this.bazBack = ""; - this.get = function () { - }; // ok - this.set = function () { - }; // ok + this.get = function () { }; // ok + this.set = function () { }; // ok } Object.defineProperty(C.prototype, "Foo", { - get: function () { - return this.fooBack; - } // ok + get: function () { return this.fooBack; } // ok , - set: function (foo) { - this.fooBack = foo; - } // ok + set: function (foo) { this.fooBack = foo; } // ok , enumerable: true, configurable: true }); Object.defineProperty(C, "Bar", { - get: function () { - return C.barBack; - } // ok + get: function () { return C.barBack; } // ok , - set: function (bar) { - C.barBack = bar; - } // ok + set: function (bar) { C.barBack = bar; } // ok , enumerable: true, configurable: true @@ -86,16 +76,7 @@ C.Bar = "barv"; var baz = c.Baz; c.Baz = "bazv"; // The Foo accessors' return and param types should be contextually typed to the Foo field -var o = { - get Foo() { - return 0; - }, - set Foo(val) { - val; - } -}; // o +var o = { get Foo() { return 0; }, set Foo(val) { val; } }; // o var ofg = o.Foo; o.Foo = 0; -var i = function (n) { - return n; -}; +var i = function (n) { return n; }; diff --git a/tests/baselines/reference/gettersAndSettersAccessibility.js b/tests/baselines/reference/gettersAndSettersAccessibility.js index 9a7564ec96..e0cfa3d17c 100644 --- a/tests/baselines/reference/gettersAndSettersAccessibility.js +++ b/tests/baselines/reference/gettersAndSettersAccessibility.js @@ -10,11 +10,8 @@ var C99 = (function () { function C99() { } Object.defineProperty(C99.prototype, "Baz", { - get: function () { - return 0; - }, - set: function (n) { - } // error - accessors do not agree in visibility + get: function () { return 0; }, + set: function (n) { } // error - accessors do not agree in visibility , enumerable: true, configurable: true diff --git a/tests/baselines/reference/gettersAndSettersErrors.js b/tests/baselines/reference/gettersAndSettersErrors.js index 514a69b251..d92f0d833f 100644 --- a/tests/baselines/reference/gettersAndSettersErrors.js +++ b/tests/baselines/reference/gettersAndSettersErrors.js @@ -22,23 +22,17 @@ var C = (function () { this.Foo = 0; // error - duplicate identifier Foo - confirmed } Object.defineProperty(C.prototype, "Foo", { - get: function () { - return "foo"; - } // ok + get: function () { return "foo"; } // ok , - set: function (foo) { - } // ok + set: function (foo) { } // ok , enumerable: true, configurable: true }); Object.defineProperty(C.prototype, "Goo", { - get: function (v) { - return null; - } // error - getters must not have a parameter + get: function (v) { return null; } // error - getters must not have a parameter , - set: function (v) { - } // error - setters must not specify a return type + set: function (v) { } // error - setters must not specify a return type , enumerable: true, configurable: true @@ -49,11 +43,8 @@ var E = (function () { function E() { } Object.defineProperty(E.prototype, "Baz", { - get: function () { - return 0; - }, - set: function (n) { - } // error - accessors do not agree in visibility + get: function () { return 0; }, + set: function (n) { } // error - accessors do not agree in visibility , enumerable: true, configurable: true diff --git a/tests/baselines/reference/gettersAndSettersTypesAgree.js b/tests/baselines/reference/gettersAndSettersTypesAgree.js index 695a77a001..91d3d84498 100644 --- a/tests/baselines/reference/gettersAndSettersTypesAgree.js +++ b/tests/baselines/reference/gettersAndSettersTypesAgree.js @@ -15,40 +15,22 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - get: function () { - return "foo"; - } // ok + get: function () { return "foo"; } // ok , - set: function (foo) { - } // ok - type inferred from getter return statement + set: function (foo) { } // ok - type inferred from getter return statement , enumerable: true, configurable: true }); Object.defineProperty(C.prototype, "Bar", { - get: function () { - return "foo"; - } // ok + get: function () { return "foo"; } // ok , - set: function (bar) { - } // ok - type must be declared + set: function (bar) { } // ok - type must be declared , enumerable: true, configurable: true }); return C; })(); -var o1 = { - get Foo() { - return 0; - }, - set Foo(val) { - } -}; // ok - types agree (inference) -var o2 = { - get Foo() { - return 0; - }, - set Foo(val) { - } -}; // ok - types agree +var o1 = { get Foo() { return 0; }, set Foo(val) { } }; // ok - types agree (inference) +var o2 = { get Foo() { return 0; }, set Foo(val) { } }; // ok - types agree diff --git a/tests/baselines/reference/giant.js b/tests/baselines/reference/giant.js index cc532ff43d..4409933bb1 100644 --- a/tests/baselines/reference/giant.js +++ b/tests/baselines/reference/giant.js @@ -697,55 +697,45 @@ define(["require", "exports"], function (require, exports) { MAX DEPTH 3 LEVELS */ var V; - function F() { - } + function F() { } ; var C = (function () { function C() { } - C.prototype.pF = function () { - }; - C.prototype.rF = function () { - }; - C.prototype.pgF = function () { - }; + C.prototype.pF = function () { }; + C.prototype.rF = function () { }; + C.prototype.pgF = function () { }; Object.defineProperty(C.prototype, "pgF", { get: function () { }, enumerable: true, configurable: true }); - C.prototype.psF = function (param) { - }; + C.prototype.psF = function (param) { }; Object.defineProperty(C.prototype, "psF", { set: function (param) { }, enumerable: true, configurable: true }); - C.prototype.rgF = function () { - }; + C.prototype.rgF = function () { }; Object.defineProperty(C.prototype, "rgF", { get: function () { }, enumerable: true, configurable: true }); - C.prototype.rsF = function (param) { - }; + C.prototype.rsF = function (param) { }; Object.defineProperty(C.prototype, "rsF", { set: function (param) { }, enumerable: true, configurable: true }); - C.tF = function () { - }; - C.tsF = function (param) { - }; + C.tF = function () { }; + C.tsF = function (param) { }; Object.defineProperty(C, "tsF", { set: function (param) { }, enumerable: true, configurable: true }); - C.tgF = function () { - }; + C.tgF = function () { }; Object.defineProperty(C, "tgF", { get: function () { }, enumerable: true, @@ -756,55 +746,45 @@ define(["require", "exports"], function (require, exports) { var M; (function (M_1) { var V; - function F() { - } + function F() { } ; var C = (function () { function C() { } - C.prototype.pF = function () { - }; - C.prototype.rF = function () { - }; - C.prototype.pgF = function () { - }; + C.prototype.pF = function () { }; + C.prototype.rF = function () { }; + C.prototype.pgF = function () { }; Object.defineProperty(C.prototype, "pgF", { get: function () { }, enumerable: true, configurable: true }); - C.prototype.psF = function (param) { - }; + C.prototype.psF = function (param) { }; Object.defineProperty(C.prototype, "psF", { set: function (param) { }, enumerable: true, configurable: true }); - C.prototype.rgF = function () { - }; + C.prototype.rgF = function () { }; Object.defineProperty(C.prototype, "rgF", { get: function () { }, enumerable: true, configurable: true }); - C.prototype.rsF = function (param) { - }; + C.prototype.rsF = function (param) { }; Object.defineProperty(C.prototype, "rsF", { set: function (param) { }, enumerable: true, configurable: true }); - C.tF = function () { - }; - C.tsF = function (param) { - }; + C.tF = function () { }; + C.tsF = function (param) { }; Object.defineProperty(C, "tsF", { set: function (param) { }, enumerable: true, configurable: true }); - C.tgF = function () { - }; + C.tgF = function () { }; Object.defineProperty(C, "tgF", { get: function () { }, enumerable: true, @@ -815,8 +795,7 @@ define(["require", "exports"], function (require, exports) { var M; (function (M) { var V; - function F() { - } + function F() { } ; var C = (function () { function C() { @@ -827,8 +806,7 @@ define(["require", "exports"], function (require, exports) { ; ; M.eV; - function eF() { - } + function eF() { } M.eF = eF; ; var eC = (function () { @@ -845,56 +823,46 @@ define(["require", "exports"], function (require, exports) { ; })(M || (M = {})); M_1.eV; - function eF() { - } + function eF() { } M_1.eF = eF; ; var eC = (function () { function eC() { } - eC.prototype.pF = function () { - }; - eC.prototype.rF = function () { - }; - eC.prototype.pgF = function () { - }; + eC.prototype.pF = function () { }; + eC.prototype.rF = function () { }; + eC.prototype.pgF = function () { }; Object.defineProperty(eC.prototype, "pgF", { get: function () { }, enumerable: true, configurable: true }); - eC.prototype.psF = function (param) { - }; + eC.prototype.psF = function (param) { }; Object.defineProperty(eC.prototype, "psF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.prototype.rgF = function () { - }; + eC.prototype.rgF = function () { }; Object.defineProperty(eC.prototype, "rgF", { get: function () { }, enumerable: true, configurable: true }); - eC.prototype.rsF = function (param) { - }; + eC.prototype.rsF = function (param) { }; Object.defineProperty(eC.prototype, "rsF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.tF = function () { - }; - eC.tsF = function (param) { - }; + eC.tF = function () { }; + eC.tsF = function (param) { }; Object.defineProperty(eC, "tsF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.tgF = function () { - }; + eC.tgF = function () { }; Object.defineProperty(eC, "tgF", { get: function () { }, enumerable: true, @@ -906,8 +874,7 @@ define(["require", "exports"], function (require, exports) { var eM; (function (eM) { var V; - function F() { - } + function F() { } ; var C = (function () { function C() { @@ -918,8 +885,7 @@ define(["require", "exports"], function (require, exports) { ; ; eM.eV; - function eF() { - } + function eF() { } eM.eF = eF; ; var eC = (function () { @@ -938,56 +904,46 @@ define(["require", "exports"], function (require, exports) { ; })(M || (M = {})); exports.eV; - function eF() { - } + function eF() { } exports.eF = eF; ; var eC = (function () { function eC() { } - eC.prototype.pF = function () { - }; - eC.prototype.rF = function () { - }; - eC.prototype.pgF = function () { - }; + eC.prototype.pF = function () { }; + eC.prototype.rF = function () { }; + eC.prototype.pgF = function () { }; Object.defineProperty(eC.prototype, "pgF", { get: function () { }, enumerable: true, configurable: true }); - eC.prototype.psF = function (param) { - }; + eC.prototype.psF = function (param) { }; Object.defineProperty(eC.prototype, "psF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.prototype.rgF = function () { - }; + eC.prototype.rgF = function () { }; Object.defineProperty(eC.prototype, "rgF", { get: function () { }, enumerable: true, configurable: true }); - eC.prototype.rsF = function (param) { - }; + eC.prototype.rsF = function (param) { }; Object.defineProperty(eC.prototype, "rsF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.tF = function () { - }; - eC.tsF = function (param) { - }; + eC.tF = function () { }; + eC.tsF = function (param) { }; Object.defineProperty(eC, "tsF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.tgF = function () { - }; + eC.tgF = function () { }; Object.defineProperty(eC, "tgF", { get: function () { }, enumerable: true, @@ -999,55 +955,45 @@ define(["require", "exports"], function (require, exports) { var eM; (function (eM_1) { var V; - function F() { - } + function F() { } ; var C = (function () { function C() { } - C.prototype.pF = function () { - }; - C.prototype.rF = function () { - }; - C.prototype.pgF = function () { - }; + C.prototype.pF = function () { }; + C.prototype.rF = function () { }; + C.prototype.pgF = function () { }; Object.defineProperty(C.prototype, "pgF", { get: function () { }, enumerable: true, configurable: true }); - C.prototype.psF = function (param) { - }; + C.prototype.psF = function (param) { }; Object.defineProperty(C.prototype, "psF", { set: function (param) { }, enumerable: true, configurable: true }); - C.prototype.rgF = function () { - }; + C.prototype.rgF = function () { }; Object.defineProperty(C.prototype, "rgF", { get: function () { }, enumerable: true, configurable: true }); - C.prototype.rsF = function (param) { - }; + C.prototype.rsF = function (param) { }; Object.defineProperty(C.prototype, "rsF", { set: function (param) { }, enumerable: true, configurable: true }); - C.tF = function () { - }; - C.tsF = function (param) { - }; + C.tF = function () { }; + C.tsF = function (param) { }; Object.defineProperty(C, "tsF", { set: function (param) { }, enumerable: true, configurable: true }); - C.tgF = function () { - }; + C.tgF = function () { }; Object.defineProperty(C, "tgF", { get: function () { }, enumerable: true, @@ -1058,8 +1004,7 @@ define(["require", "exports"], function (require, exports) { var M; (function (M) { var V; - function F() { - } + function F() { } ; var C = (function () { function C() { @@ -1070,8 +1015,7 @@ define(["require", "exports"], function (require, exports) { ; ; M.eV; - function eF() { - } + function eF() { } M.eF = eF; ; var eC = (function () { @@ -1088,56 +1032,46 @@ define(["require", "exports"], function (require, exports) { ; })(M || (M = {})); eM_1.eV; - function eF() { - } + function eF() { } eM_1.eF = eF; ; var eC = (function () { function eC() { } - eC.prototype.pF = function () { - }; - eC.prototype.rF = function () { - }; - eC.prototype.pgF = function () { - }; + eC.prototype.pF = function () { }; + eC.prototype.rF = function () { }; + eC.prototype.pgF = function () { }; Object.defineProperty(eC.prototype, "pgF", { get: function () { }, enumerable: true, configurable: true }); - eC.prototype.psF = function (param) { - }; + eC.prototype.psF = function (param) { }; Object.defineProperty(eC.prototype, "psF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.prototype.rgF = function () { - }; + eC.prototype.rgF = function () { }; Object.defineProperty(eC.prototype, "rgF", { get: function () { }, enumerable: true, configurable: true }); - eC.prototype.rsF = function (param) { - }; + eC.prototype.rsF = function (param) { }; Object.defineProperty(eC.prototype, "rsF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.tF = function () { - }; - eC.tsF = function (param) { - }; + eC.tF = function () { }; + eC.tsF = function (param) { }; Object.defineProperty(eC, "tsF", { set: function (param) { }, enumerable: true, configurable: true }); - eC.tgF = function () { - }; + eC.tgF = function () { }; Object.defineProperty(eC, "tgF", { get: function () { }, enumerable: true, @@ -1149,8 +1083,7 @@ define(["require", "exports"], function (require, exports) { var eM; (function (eM) { var V; - function F() { - } + function F() { } ; var C = (function () { function C() { @@ -1161,8 +1094,7 @@ define(["require", "exports"], function (require, exports) { ; ; eM.eV; - function eF() { - } + function eF() { } eM.eF = eF; ; var eC = (function () { diff --git a/tests/baselines/reference/globalThisCapture.js b/tests/baselines/reference/globalThisCapture.js index 5e724d77e0..b854e754a3 100644 --- a/tests/baselines/reference/globalThisCapture.js +++ b/tests/baselines/reference/globalThisCapture.js @@ -11,9 +11,7 @@ parts[0]; //// [globalThisCapture.js] var _this = this; // Add a lambda to ensure global 'this' capture is triggered -(function () { - return _this.window; -}); +(function () { return _this.window; }); var parts = []; // Ensure that the generated code is correct parts[0]; diff --git a/tests/baselines/reference/grammarAmbiguities.js b/tests/baselines/reference/grammarAmbiguities.js index ee81d947ff..f603bd1023 100644 --- a/tests/baselines/reference/grammarAmbiguities.js +++ b/tests/baselines/reference/grammarAmbiguities.js @@ -12,12 +12,8 @@ f(g < A, B > +(7)); // Should error //// [grammarAmbiguities.js] -function f(n) { - return null; -} -function g(x) { - return null; -} +function f(n) { return null; } +function g(x) { return null; } var A, B; f(g(7)); f(g < A, B > 7); // Should error diff --git a/tests/baselines/reference/grammarAmbiguities1.js b/tests/baselines/reference/grammarAmbiguities1.js index cb6e4b7547..1917acb712 100644 --- a/tests/baselines/reference/grammarAmbiguities1.js +++ b/tests/baselines/reference/grammarAmbiguities1.js @@ -14,23 +14,17 @@ f(g < A, B > +(7)); var A = (function () { function A() { } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); var B = (function () { function B() { } - B.prototype.bar = function () { - }; + B.prototype.bar = function () { }; return B; })(); -function f(x) { - return x; -} -function g(x) { - return f(x); -} +function f(x) { return x; } +function g(x) { return f(x); } g(7); f(g(7)); f(g < A, B > 7); diff --git a/tests/baselines/reference/heterogeneousArrayAndOverloads.js b/tests/baselines/reference/heterogeneousArrayAndOverloads.js index f18cef7130..b816b87e3d 100644 --- a/tests/baselines/reference/heterogeneousArrayAndOverloads.js +++ b/tests/baselines/reference/heterogeneousArrayAndOverloads.js @@ -15,25 +15,12 @@ class arrTest { var arrTest = (function () { function arrTest() { } - arrTest.prototype.test = function (arg1) { - }; + arrTest.prototype.test = function (arg1) { }; arrTest.prototype.callTest = function () { - this.test([ - 1, - 2, - 3, - 5 - ]); - this.test([ - "hi" - ]); + this.test([1, 2, 3, 5]); + this.test(["hi"]); this.test([]); - this.test([ - 1, - 2, - "hi", - 5 - ]); // Error + this.test([1, 2, "hi", 5]); // Error }; return arrTest; })(); diff --git a/tests/baselines/reference/heterogeneousArrayLiterals.js b/tests/baselines/reference/heterogeneousArrayLiterals.js index 51d316a4f4..4ac929305c 100644 --- a/tests/baselines/reference/heterogeneousArrayLiterals.js +++ b/tests/baselines/reference/heterogeneousArrayLiterals.js @@ -139,106 +139,20 @@ var __extends = this.__extends || function (d, b) { __.prototype = b.prototype; d.prototype = new __(); }; -var a = [ - 1, - '' -]; // {}[] -var b = [ - 1, - null -]; // number[] -var c = [ - 1, - '', - null -]; // {}[] -var d = [ - {}, - 1 -]; // {}[] -var e = [ - {}, - Object -]; // {}[] -var f = [ - [], - [ - 1 - ] -]; // number[][] -var g = [ - [ - 1 - ], - [ - '' - ] -]; // {}[] -var h = [ - { - foo: 1, - bar: '' - }, - { - foo: 2 - } -]; // {foo: number}[] -var i = [ - { - foo: 1, - bar: '' - }, - { - foo: '' - } -]; // {}[] -var j = [ - function () { - return 1; - }, - function () { - return ''; - } -]; // {}[] -var k = [ - function () { - return 1; - }, - function () { - return 1; - } -]; // { (): number }[] -var l = [ - function () { - return 1; - }, - function () { - return null; - } -]; // { (): any }[] -var m = [ - function () { - return 1; - }, - function () { - return ''; - }, - function () { - return null; - } -]; // { (): any }[] -var n = [ - [ - function () { - return 1; - } - ], - [ - function () { - return ''; - } - ] -]; // {}[] +var a = [1, '']; // {}[] +var b = [1, null]; // number[] +var c = [1, '', null]; // {}[] +var d = [{}, 1]; // {}[] +var e = [{}, Object]; // {}[] +var f = [[], [1]]; // number[][] +var g = [[1], ['']]; // {}[] +var h = [{ foo: 1, bar: '' }, { foo: 2 }]; // {foo: number}[] +var i = [{ foo: 1, bar: '' }, { foo: '' }]; // {}[] +var j = [function () { return 1; }, function () { return ''; }]; // {}[] +var k = [function () { return 1; }, function () { return 1; }]; // { (): number }[] +var l = [function () { return 1; }, function () { return null; }]; // { (): any }[] +var m = [function () { return 1; }, function () { return ''; }, function () { return null; }]; // { (): any }[] +var n = [[function () { return 1; }], [function () { return ''; }]]; // {}[] var Base = (function () { function Base() { } @@ -263,312 +177,69 @@ var derived; var derived2; var Derived; (function (Derived) { - var h = [ - { - foo: base, - basear: derived - }, - { - foo: base - } - ]; // {foo: Base}[] - var i = [ - { - foo: base, - basear: derived - }, - { - foo: derived - } - ]; // {foo: Derived}[] - var j = [ - function () { - return base; - }, - function () { - return derived; - } - ]; // { {}: Base } - var k = [ - function () { - return base; - }, - function () { - return 1; - } - ]; // {}[]~ - var l = [ - function () { - return base; - }, - function () { - return null; - } - ]; // { (): any }[] - var m = [ - function () { - return base; - }, - function () { - return derived; - }, - function () { - return null; - } - ]; // { (): any }[] - var n = [ - [ - function () { - return base; - } - ], - [ - function () { - return derived; - } - ] - ]; // { (): Base }[] - var o = [ - derived, - derived2 - ]; // {}[] - var p = [ - derived, - derived2, - base - ]; // Base[] - var q = [ - [ - function () { - return derived2; - } - ], - [ - function () { - return derived; - } - ] - ]; // {}[] + var h = [{ foo: base, basear: derived }, { foo: base }]; // {foo: Base}[] + var i = [{ foo: base, basear: derived }, { foo: derived }]; // {foo: Derived}[] + var j = [function () { return base; }, function () { return derived; }]; // { {}: Base } + var k = [function () { return base; }, function () { return 1; }]; // {}[]~ + var l = [function () { return base; }, function () { return null; }]; // { (): any }[] + var m = [function () { return base; }, function () { return derived; }, function () { return null; }]; // { (): any }[] + var n = [[function () { return base; }], [function () { return derived; }]]; // { (): Base }[] + var o = [derived, derived2]; // {}[] + var p = [derived, derived2, base]; // Base[] + var q = [[function () { return derived2; }], [function () { return derived; }]]; // {}[] })(Derived || (Derived = {})); var WithContextualType; (function (WithContextualType) { // no errors - var a = [ - derived, - derived2 - ]; - var b = [ - null - ]; + var a = [derived, derived2]; + var b = [null]; var c = []; - var d = [ - function () { - return derived; - }, - function () { - return derived2; - } - ]; + var d = [function () { return derived; }, function () { return derived2; }]; })(WithContextualType || (WithContextualType = {})); function foo(t, u) { - var a = [ - t, - t - ]; // T[] - var b = [ - t, - null - ]; // T[] - var c = [ - t, - u - ]; // {}[] - var d = [ - t, - 1 - ]; // {}[] - var e = [ - function () { - return t; - }, - function () { - return u; - } - ]; // {}[] - var f = [ - function () { - return t; - }, - function () { - return u; - }, - function () { - return null; - } - ]; // { (): any }[] + var a = [t, t]; // T[] + var b = [t, null]; // T[] + var c = [t, u]; // {}[] + var d = [t, 1]; // {}[] + var e = [function () { return t; }, function () { return u; }]; // {}[] + var f = [function () { return t; }, function () { return u; }, function () { return null; }]; // { (): any }[] } function foo2(t, u) { - var a = [ - t, - t - ]; // T[] - var b = [ - t, - null - ]; // T[] - var c = [ - t, - u - ]; // {}[] - var d = [ - t, - 1 - ]; // {}[] - var e = [ - function () { - return t; - }, - function () { - return u; - } - ]; // {}[] - var f = [ - function () { - return t; - }, - function () { - return u; - }, - function () { - return null; - } - ]; // { (): any }[] - var g = [ - t, - base - ]; // Base[] - var h = [ - t, - derived - ]; // Derived[] - var i = [ - u, - base - ]; // Base[] - var j = [ - u, - derived - ]; // Derived[] + var a = [t, t]; // T[] + var b = [t, null]; // T[] + var c = [t, u]; // {}[] + var d = [t, 1]; // {}[] + var e = [function () { return t; }, function () { return u; }]; // {}[] + var f = [function () { return t; }, function () { return u; }, function () { return null; }]; // { (): any }[] + var g = [t, base]; // Base[] + var h = [t, derived]; // Derived[] + var i = [u, base]; // Base[] + var j = [u, derived]; // Derived[] } function foo3(t, u) { - var a = [ - t, - t - ]; // T[] - var b = [ - t, - null - ]; // T[] - var c = [ - t, - u - ]; // {}[] - var d = [ - t, - 1 - ]; // {}[] - var e = [ - function () { - return t; - }, - function () { - return u; - } - ]; // {}[] - var f = [ - function () { - return t; - }, - function () { - return u; - }, - function () { - return null; - } - ]; // { (): any }[] - var g = [ - t, - base - ]; // Base[] - var h = [ - t, - derived - ]; // Derived[] - var i = [ - u, - base - ]; // Base[] - var j = [ - u, - derived - ]; // Derived[] + var a = [t, t]; // T[] + var b = [t, null]; // T[] + var c = [t, u]; // {}[] + var d = [t, 1]; // {}[] + var e = [function () { return t; }, function () { return u; }]; // {}[] + var f = [function () { return t; }, function () { return u; }, function () { return null; }]; // { (): any }[] + var g = [t, base]; // Base[] + var h = [t, derived]; // Derived[] + var i = [u, base]; // Base[] + var j = [u, derived]; // Derived[] } function foo4(t, u) { - var a = [ - t, - t - ]; // T[] - var b = [ - t, - null - ]; // T[] - var c = [ - t, - u - ]; // BUG 821629 - var d = [ - t, - 1 - ]; // {}[] - var e = [ - function () { - return t; - }, - function () { - return u; - } - ]; // {}[] - var f = [ - function () { - return t; - }, - function () { - return u; - }, - function () { - return null; - } - ]; // { (): any }[] - var g = [ - t, - base - ]; // Base[] - var h = [ - t, - derived - ]; // Derived[] - var i = [ - u, - base - ]; // Base[] - var j = [ - u, - derived - ]; // Derived[] - var k = [ - t, - u - ]; + var a = [t, t]; // T[] + var b = [t, null]; // T[] + var c = [t, u]; // BUG 821629 + var d = [t, 1]; // {}[] + var e = [function () { return t; }, function () { return u; }]; // {}[] + var f = [function () { return t; }, function () { return u; }, function () { return null; }]; // { (): any }[] + var g = [t, base]; // Base[] + var h = [t, derived]; // Derived[] + var i = [u, base]; // Base[] + var j = [u, derived]; // Derived[] + var k = [t, u]; } //function foo3(t: T, u: U) { // var a = [t, t]; // T[] diff --git a/tests/baselines/reference/ifDoWhileStatements.js b/tests/baselines/reference/ifDoWhileStatements.js index db23ea4681..793094584b 100644 --- a/tests/baselines/reference/ifDoWhileStatements.js +++ b/tests/baselines/reference/ifDoWhileStatements.js @@ -186,12 +186,8 @@ var D = (function () { } return D; })(); -function F(x) { - return 42; -} -function F2(x) { - return x < 42; -} +function F(x) { return 42; } +function F2(x) { return x < 42; } var M; (function (M) { var A = (function () { @@ -200,9 +196,7 @@ var M; return A; })(); M.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } M.F2 = F2; })(M || (M = {})); var N; @@ -213,216 +207,101 @@ var N; return A; })(); N.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } N.F2 = F2; })(N || (N = {})); // literals -if (true) { -} -while (true) { -} -do { -} while (true); -if (null) { -} -while (null) { -} -do { -} while (null); -if (undefined) { -} -while (undefined) { -} -do { -} while (undefined); -if (0.0) { -} -while (0.0) { -} -do { -} while (0.0); -if ('a string') { -} -while ('a string') { -} -do { -} while ('a string'); -if ('') { -} -while ('') { -} -do { -} while (''); -if (/[a-z]/) { -} -while (/[a-z]/) { -} -do { -} while (/[a-z]/); -if ([]) { -} -while ([]) { -} -do { -} while ([]); -if ([ - 1, - 2 -]) { -} -while ([ - 1, - 2 -]) { -} -do { -} while ([ - 1, - 2 -]); -if ({}) { -} -while ({}) { -} -do { -} while ({}); -if ({ - x: 1, - y: 'a' -}) { -} -while ({ - x: 1, - y: 'a' -}) { -} -do { -} while ({ - x: 1, - y: 'a' -}); -if (function () { - return 43; -}) { -} -while (function () { - return 43; -}) { -} -do { -} while (function () { - return 43; -}); -if (new C()) { -} -while (new C()) { -} -do { -} while (new C()); -if (new D()) { -} -while (new D()) { -} -do { -} while (new D()); +if (true) { } +while (true) { } +do { } while (true); +if (null) { } +while (null) { } +do { } while (null); +if (undefined) { } +while (undefined) { } +do { } while (undefined); +if (0.0) { } +while (0.0) { } +do { } while (0.0); +if ('a string') { } +while ('a string') { } +do { } while ('a string'); +if ('') { } +while ('') { } +do { } while (''); +if (/[a-z]/) { } +while (/[a-z]/) { } +do { } while (/[a-z]/); +if ([]) { } +while ([]) { } +do { } while ([]); +if ([1, 2]) { } +while ([1, 2]) { } +do { } while ([1, 2]); +if ({}) { } +while ({}) { } +do { } while ({}); +if ({ x: 1, y: 'a' }) { } +while ({ x: 1, y: 'a' }) { } +do { } while ({ x: 1, y: 'a' }); +if (function () { return 43; }) { } +while (function () { return 43; }) { } +do { } while (function () { return 43; }); +if (new C()) { } +while (new C()) { } +do { } while (new C()); +if (new D()) { } +while (new D()) { } +do { } while (new D()); // references var a = true; -if (a) { -} -while (a) { -} -do { -} while (a); +if (a) { } +while (a) { } +do { } while (a); var b = null; -if (b) { -} -while (b) { -} -do { -} while (b); +if (b) { } +while (b) { } +do { } while (b); var c = undefined; -if (c) { -} -while (c) { -} -do { -} while (c); +if (c) { } +while (c) { } +do { } while (c); var d = 0.0; -if (d) { -} -while (d) { -} -do { -} while (d); +if (d) { } +while (d) { } +do { } while (d); var e = 'a string'; -if (e) { -} -while (e) { -} -do { -} while (e); +if (e) { } +while (e) { } +do { } while (e); var f = ''; -if (f) { -} -while (f) { -} -do { -} while (f); +if (f) { } +while (f) { } +do { } while (f); var g = /[a-z]/; -if (g) { -} -while (g) { -} -do { -} while (g); +if (g) { } +while (g) { } +do { } while (g); var h = []; -if (h) { -} -while (h) { -} -do { -} while (h); -var i = [ - 1, - 2 -]; -if (i) { -} -while (i) { -} -do { -} while (i); +if (h) { } +while (h) { } +do { } while (h); +var i = [1, 2]; +if (i) { } +while (i) { } +do { } while (i); var j = {}; -if (j) { -} -while (j) { -} -do { -} while (j); -var k = { - x: 1, - y: 'a' -}; -if (k) { -} -while (k) { -} -do { -} while (k); -function fn(x) { - return null; -} -if (fn()) { -} -while (fn()) { -} -do { -} while (fn()); -if (fn) { -} -while (fn) { -} -do { -} while (fn); +if (j) { } +while (j) { } +do { } while (j); +var k = { x: 1, y: 'a' }; +if (k) { } +while (k) { } +do { } while (k); +function fn(x) { return null; } +if (fn()) { } +while (fn()) { } +do { } while (fn()); +if (fn) { } +while (fn) { } +do { } while (fn); diff --git a/tests/baselines/reference/illegalSuperCallsInConstructor.js b/tests/baselines/reference/illegalSuperCallsInConstructor.js index 5fbad149b9..0bdcebed9c 100644 --- a/tests/baselines/reference/illegalSuperCallsInConstructor.js +++ b/tests/baselines/reference/illegalSuperCallsInConstructor.js @@ -35,15 +35,9 @@ var Base = (function () { var Derived = (function (_super) { __extends(Derived, _super); function Derived() { - var r2 = function () { - return _super.call(this); - }; - var r3 = function () { - _super.call(this); - }; - var r4 = function () { - _super.call(this); - }; + var r2 = function () { return _super.call(this); }; + var r3 = function () { _super.call(this); }; + var r4 = function () { _super.call(this); }; var r5 = { get foo() { _super.call(this); diff --git a/tests/baselines/reference/implementsClauseAlreadySeen.js b/tests/baselines/reference/implementsClauseAlreadySeen.js index 84823c13fa..abb2888661 100644 --- a/tests/baselines/reference/implementsClauseAlreadySeen.js +++ b/tests/baselines/reference/implementsClauseAlreadySeen.js @@ -15,7 +15,6 @@ var C = (function () { var D = (function () { function D() { } - D.prototype.baz = function () { - }; + D.prototype.baz = function () { }; return D; })(); diff --git a/tests/baselines/reference/implicitAnyCastedValue.js b/tests/baselines/reference/implicitAnyCastedValue.js index bc0855c838..be6bd1bfef 100644 --- a/tests/baselines/reference/implicitAnyCastedValue.js +++ b/tests/baselines/reference/implicitAnyCastedValue.js @@ -160,7 +160,4 @@ function multipleRets2(x) { var bar1 = null; var bar2 = undefined; var bar3 = 0; -var array = [ - null, - undefined -]; +var array = [null, undefined]; diff --git a/tests/baselines/reference/implicitAnyDeclareFunctionExprWithoutFormalType.js b/tests/baselines/reference/implicitAnyDeclareFunctionExprWithoutFormalType.js index cba7602d04..9bfad713d8 100644 --- a/tests/baselines/reference/implicitAnyDeclareFunctionExprWithoutFormalType.js +++ b/tests/baselines/reference/implicitAnyDeclareFunctionExprWithoutFormalType.js @@ -19,32 +19,15 @@ var lambda10 = function temp1() { return 5; } //// [implicitAnyDeclareFunctionExprWithoutFormalType.js] // these should be errors for implicit any parameter -var lambda = function (l1) { -}; // Error at "l1" -var lambd2 = function (ll1, ll2) { -}; // Error at "ll1" -var lamda3 = function myLambda3(myParam) { -}; -var lamda4 = function () { - return null; -}; +var lambda = function (l1) { }; // Error at "l1" +var lambd2 = function (ll1, ll2) { }; // Error at "ll1" +var lamda3 = function myLambda3(myParam) { }; +var lamda4 = function () { return null; }; // these should be error for implicit any return type -var lambda5 = function temp() { - return null; -}; -var lambda6 = function () { - return null; -}; -var lambda7 = function temp() { - return undefined; -}; -var lambda8 = function () { - return undefined; -}; +var lambda5 = function temp() { return null; }; +var lambda6 = function () { return null; }; +var lambda7 = function temp() { return undefined; }; +var lambda8 = function () { return undefined; }; // this shouldn't be an error -var lambda9 = function () { - return 5; -}; -var lambda10 = function temp1() { - return 5; -}; +var lambda9 = function () { return 5; }; +var lambda10 = function temp1() { return 5; }; diff --git a/tests/baselines/reference/implicitAnyDeclareFunctionWithoutFormalType.js b/tests/baselines/reference/implicitAnyDeclareFunctionWithoutFormalType.js index 6332f44448..c13479daff 100644 --- a/tests/baselines/reference/implicitAnyDeclareFunctionWithoutFormalType.js +++ b/tests/baselines/reference/implicitAnyDeclareFunctionWithoutFormalType.js @@ -13,14 +13,11 @@ function noError2(x: number, y: string) { }; //// [implicitAnyDeclareFunctionWithoutFormalType.js] // these should be errors -function foo(x) { -} +function foo(x) { } ; -function bar(x, y) { -} +function bar(x, y) { } ; // error at "y"; no error at "x" -function func2(a, b, c) { -} +function func2(a, b, c) { } ; // error at "a,b,c" function func3() { var args = []; @@ -40,6 +37,5 @@ function noError1(x, y) { if (y === void 0) { y = 2; } } ; -function noError2(x, y) { -} +function noError2(x, y) { } ; diff --git a/tests/baselines/reference/implicitAnyDeclareMemberWithoutType2.js b/tests/baselines/reference/implicitAnyDeclareMemberWithoutType2.js index 1a49449529..59d625fff4 100644 --- a/tests/baselines/reference/implicitAnyDeclareMemberWithoutType2.js +++ b/tests/baselines/reference/implicitAnyDeclareMemberWithoutType2.js @@ -15,7 +15,6 @@ var C = (function () { function C(c1, c2, c3) { this.x = null; // error at "x" } // error at "c1, c2" - C.prototype.funcOfC = function (f1, f2, f3) { - }; // error at "f1,f2" + C.prototype.funcOfC = function (f1, f2, f3) { }; // error at "f1,f2" return C; })(); diff --git a/tests/baselines/reference/implicitAnyDeclareVariablesWithoutTypeAndInit.js b/tests/baselines/reference/implicitAnyDeclareVariablesWithoutTypeAndInit.js index ae09bf2e40..e3c44e9b78 100644 --- a/tests/baselines/reference/implicitAnyDeclareVariablesWithoutTypeAndInit.js +++ b/tests/baselines/reference/implicitAnyDeclareVariablesWithoutTypeAndInit.js @@ -14,8 +14,7 @@ var x1: any; var y1 = new x1; //// [implicitAnyDeclareVariablesWithoutTypeAndInit.js] // this should be an error var x; // error at "x" -function func(k) { -} +function func(k) { } ; //error at "k" func(x); // this shouldn't be an error diff --git a/tests/baselines/reference/implicitAnyFromCircularInference.js b/tests/baselines/reference/implicitAnyFromCircularInference.js index b2ea707d17..d818ea1710 100644 --- a/tests/baselines/reference/implicitAnyFromCircularInference.js +++ b/tests/baselines/reference/implicitAnyFromCircularInference.js @@ -58,21 +58,15 @@ var b; var c; // Error expected var d; -function f() { - return f; -} +function f() { return f; } // Error expected -function g() { - return g(); -} +function g() { return g(); } // Error expected var f1 = function () { return f1(); }; // Error expected -var f2 = function () { - return f2(); -}; +var f2 = function () { return f2(); }; // Error expected function h() { return foo(); @@ -80,9 +74,7 @@ function h() { return h() || "hello"; } } -function foo(x) { - return "abc"; -} +function foo(x) { return "abc"; } var C = (function () { function C() { // Error expected diff --git a/tests/baselines/reference/implicitAnyFunctionInvocationWithAnyArguements.js b/tests/baselines/reference/implicitAnyFunctionInvocationWithAnyArguements.js index 21a3171b43..bc5b945366 100644 --- a/tests/baselines/reference/implicitAnyFunctionInvocationWithAnyArguements.js +++ b/tests/baselines/reference/implicitAnyFunctionInvocationWithAnyArguements.js @@ -38,42 +38,28 @@ var newC2 = new C([], null) //// [implicitAnyFunctionInvocationWithAnyArguements.js] // this should be errors var arg0 = null; // error at "arg0" -var anyArray = [ - null, - undefined -]; // error at array literal +var anyArray = [null, undefined]; // error at array literal var objL; // error at "y,z" var funcL; -function temp1(arg1) { -} // error at "temp1" -function testFunctionExprC(subReplace) { -} -function testFunctionExprC2(eq) { -} +function temp1(arg1) { } // error at "temp1" +function testFunctionExprC(subReplace) { } +function testFunctionExprC2(eq) { } ; -function testObjLiteral(objLit) { -} +function testObjLiteral(objLit) { } ; -function testFuncLiteral(funcLit) { -} +function testFuncLiteral(funcLit) { } ; // this should not be an error -testFunctionExprC2(function (v1, v2) { - return 1; -}); +testFunctionExprC2(function (v1, v2) { return 1; }); testObjLiteral(objL); testFuncLiteral(funcL); var k = temp1(null); var result = temp1(arg0); var result1 = temp1(anyArray); -function noError(variable, array) { -} +function noError(variable, array) { } noError(null, []); noError(undefined, []); -noError(null, [ - null, - undefined -]); +noError(null, [null, undefined]); noError(undefined, anyArray); var C = (function () { function C(emtpyArray, variable) { diff --git a/tests/baselines/reference/implicitAnyFunctionReturnNullOrUndefined.js b/tests/baselines/reference/implicitAnyFunctionReturnNullOrUndefined.js index 699b57603e..82eb56fbde 100644 --- a/tests/baselines/reference/implicitAnyFunctionReturnNullOrUndefined.js +++ b/tests/baselines/reference/implicitAnyFunctionReturnNullOrUndefined.js @@ -26,12 +26,8 @@ undefinedWidenFunction(); //// [implicitAnyFunctionReturnNullOrUndefined.js] // this should be an error -function nullWidenFunction() { - return null; -} // error at "nullWidenFunction" -function undefinedWidenFunction() { - return undefined; -} // error at "undefinedWidenFunction" +function nullWidenFunction() { return null; } // error at "nullWidenFunction" +function undefinedWidenFunction() { return undefined; } // error at "undefinedWidenFunction" var C = (function () { function C() { } @@ -44,18 +40,10 @@ var C = (function () { return C; })(); // this should not be an error -function foo1() { - return null; -} -function bar1() { - return undefined; -} -function fooBar() { - return 1; -} -function fooFoo() { - return 5; -} +function foo1() { return null; } +function bar1() { return undefined; } +function fooBar() { return 1; } +function fooFoo() { return 5; } // this should not be an error as the error is raised by expr above nullWidenFunction(); undefinedWidenFunction(); diff --git a/tests/baselines/reference/implicitAnyGenericTypeInference.js b/tests/baselines/reference/implicitAnyGenericTypeInference.js index 37ef042f26..583ab7f0b0 100644 --- a/tests/baselines/reference/implicitAnyGenericTypeInference.js +++ b/tests/baselines/reference/implicitAnyGenericTypeInference.js @@ -10,9 +10,5 @@ var r = c.compareTo(1, ''); //// [implicitAnyGenericTypeInference.js] var c; -c = { - compareTo: function (x, y) { - return y; - } -}; +c = { compareTo: function (x, y) { return y; } }; var r = c.compareTo(1, ''); diff --git a/tests/baselines/reference/implicitAnyGenerics.js b/tests/baselines/reference/implicitAnyGenerics.js index a5c98590a8..daea0dfe54 100644 --- a/tests/baselines/reference/implicitAnyGenerics.js +++ b/tests/baselines/reference/implicitAnyGenerics.js @@ -46,9 +46,7 @@ var d2 = new D(1); var d3 = new D(1); var d4 = new D(1); var d5 = new D(null); -function foo() { - return null; -} +function foo() { return null; } ; foo(); foo(); diff --git a/tests/baselines/reference/implicitAnyInCatch.js b/tests/baselines/reference/implicitAnyInCatch.js index 29a2e03a13..c35e92372e 100644 --- a/tests/baselines/reference/implicitAnyInCatch.js +++ b/tests/baselines/reference/implicitAnyInCatch.js @@ -16,14 +16,11 @@ class C { //// [implicitAnyInCatch.js] // this should not be an error -try { -} +try { } catch (error) { - if (error.number === -2147024809) { - } -} -for (var key in this) { + if (error.number === -2147024809) { } } +for (var key in this) { } var C = (function () { function C() { } diff --git a/tests/baselines/reference/implicitAnyNewExprLackConstructorSignature.js b/tests/baselines/reference/implicitAnyNewExprLackConstructorSignature.js index 4218d9a9a2..9e558122b1 100644 --- a/tests/baselines/reference/implicitAnyNewExprLackConstructorSignature.js +++ b/tests/baselines/reference/implicitAnyNewExprLackConstructorSignature.js @@ -3,7 +3,5 @@ function Point() { this.x = 3; } var x: any = new Point(); // error at "new" //// [implicitAnyNewExprLackConstructorSignature.js] -function Point() { - this.x = 3; -} +function Point() { this.x = 3; } var x = new Point(); // error at "new" diff --git a/tests/baselines/reference/implicitAnyWidenToAny.js b/tests/baselines/reference/implicitAnyWidenToAny.js index 01ad0dcb9b..838593a88e 100644 --- a/tests/baselines/reference/implicitAnyWidenToAny.js +++ b/tests/baselines/reference/implicitAnyWidenToAny.js @@ -31,10 +31,7 @@ var obj1 = anyReturnFunc(); // these should be errors var x = null; // error at "x" var x1 = undefined; // error at "x1" -var widenArray = [ - null, - undefined -]; // error at "widenArray" +var widenArray = [null, undefined]; // error at "widenArray" var emptyArray = []; // error at "emptyArray" // these should not be error var AnimalObj = (function () { @@ -47,28 +44,13 @@ var bar = "Hello World"; var foo1 = null; var foo2 = undefined; var temp = 5; -var c = { - x: null -}; -var array1 = [ - "Bob", - 2 -]; +var c = { x: null }; +var array1 = ["Bob", 2]; var array2 = []; -var array3 = [ - null, - undefined -]; -var array4 = [ - null, - undefined -]; -var array5 = [ - null, - undefined -]; +var array3 = [null, undefined]; +var array4 = [null, undefined]; +var array5 = [null, undefined]; var objLit; -function anyReturnFunc() { -} +function anyReturnFunc() { } var obj0 = new objLit(1); var obj1 = anyReturnFunc(); diff --git a/tests/baselines/reference/importAliasAnExternalModuleInsideAnInternalModule.js b/tests/baselines/reference/importAliasAnExternalModuleInsideAnInternalModule.js index 35992b86fe..3329fb810a 100644 --- a/tests/baselines/reference/importAliasAnExternalModuleInsideAnInternalModule.js +++ b/tests/baselines/reference/importAliasAnExternalModuleInsideAnInternalModule.js @@ -17,8 +17,7 @@ module m_private { //// [importAliasAnExternalModuleInsideAnInternalModule_file0.js] var m; (function (m) { - function foo() { - } + function foo() { } m.foo = foo; })(m = exports.m || (exports.m = {})); //// [importAliasAnExternalModuleInsideAnInternalModule_file1.js] diff --git a/tests/baselines/reference/importAliasIdentifiers.js b/tests/baselines/reference/importAliasIdentifiers.js index 620fdf1386..7bd15b28c6 100644 --- a/tests/baselines/reference/importAliasIdentifiers.js +++ b/tests/baselines/reference/importAliasIdentifiers.js @@ -69,27 +69,18 @@ var clodule = (function () { })(); var clodule; (function (clodule) { - var Point = { - x: 0, - y: 0 - }; + var Point = { x: 0, y: 0 }; })(clodule || (clodule = {})); var clolias = clodule; var p; var p; var p; function fundule() { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; } var fundule; (function (fundule) { - var Point = { - x: 0, - y: 0 - }; + var Point = { x: 0, y: 0 }; })(fundule || (fundule = {})); var funlias = fundule; var p; diff --git a/tests/baselines/reference/importAsBaseClass.js b/tests/baselines/reference/importAsBaseClass.js index 9e52c4dd06..8114e88ca4 100644 --- a/tests/baselines/reference/importAsBaseClass.js +++ b/tests/baselines/reference/importAsBaseClass.js @@ -14,9 +14,7 @@ class Hello extends Greeter { } var Greeter = (function () { function Greeter() { } - Greeter.prototype.greet = function () { - return 'greet'; - }; + Greeter.prototype.greet = function () { return 'greet'; }; return Greeter; })(); exports.Greeter = Greeter; diff --git a/tests/baselines/reference/importDecl.js b/tests/baselines/reference/importDecl.js index d6f2855908..9d4839e5e7 100644 --- a/tests/baselines/reference/importDecl.js +++ b/tests/baselines/reference/importDecl.js @@ -89,9 +89,7 @@ var d = (function () { })(); exports.d = d; exports.x; -function foo() { - return null; -} +function foo() { return null; } exports.foo = foo; //// [importDecl_require1.js] var d = (function () { @@ -101,9 +99,7 @@ var d = (function () { })(); exports.d = d; var x; -function foo() { - return null; -} +function foo() { return null; } exports.foo = foo; //// [importDecl_require2.js] var d = (function () { @@ -113,9 +109,7 @@ var d = (function () { })(); exports.d = d; exports.x; -function foo() { - return null; -} +function foo() { return null; } exports.foo = foo; //// [importDecl_require3.js] var d = (function () { @@ -125,14 +119,10 @@ var d = (function () { })(); exports.d = d; exports.x; -function foo() { - return null; -} +function foo() { return null; } exports.foo = foo; //// [importDecl_require4.js] -function foo2() { - return null; -} +function foo2() { return null; } exports.foo2 = foo2; //// [importDecl_1.js] /// diff --git a/tests/baselines/reference/importInTypePosition.js b/tests/baselines/reference/importInTypePosition.js index 08f7078cca..c0d64a4ef7 100644 --- a/tests/baselines/reference/importInTypePosition.js +++ b/tests/baselines/reference/importInTypePosition.js @@ -39,8 +39,5 @@ var C; (function (C) { var m; var p; - var p = { - x: 0, - y: 0 - }; + var p = { x: 0, y: 0 }; })(C || (C = {})); diff --git a/tests/baselines/reference/importStatements.js b/tests/baselines/reference/importStatements.js index dddbadbcc7..b8d06a3546 100644 --- a/tests/baselines/reference/importStatements.js +++ b/tests/baselines/reference/importStatements.js @@ -52,10 +52,7 @@ var C; (function (C) { var m; var p; - var p = { - x: 0, - y: 0 - }; + var p = { x: 0, y: 0 }; })(C || (C = {})); // code gen expected var D; diff --git a/tests/baselines/reference/importStatementsInterfaces.js b/tests/baselines/reference/importStatementsInterfaces.js index bb24aeb0f6..4f7bb44756 100644 --- a/tests/baselines/reference/importStatementsInterfaces.js +++ b/tests/baselines/reference/importStatementsInterfaces.js @@ -47,11 +47,7 @@ var C; (function (C) { var m; var p; - var p = { - x: 0, - y: 0, - z: 0 - }; + var p = { x: 0, y: 0, z: 0 }; })(C || (C = {})); // no code gen expected var D; diff --git a/tests/baselines/reference/importedModuleAddToGlobal.js b/tests/baselines/reference/importedModuleAddToGlobal.js index a848ccb504..015631dc96 100644 --- a/tests/baselines/reference/importedModuleAddToGlobal.js +++ b/tests/baselines/reference/importedModuleAddToGlobal.js @@ -28,7 +28,5 @@ var B; })(B || (B = {})); var C; (function (C) { - function hello() { - return null; - } + function hello() { return null; } })(C || (C = {})); diff --git a/tests/baselines/reference/inOperator.js b/tests/baselines/reference/inOperator.js index 1407ef9d59..10059bcf2b 100644 --- a/tests/baselines/reference/inOperator.js +++ b/tests/baselines/reference/inOperator.js @@ -14,12 +14,9 @@ if (y in c) { } //// [inOperator.js] var a = []; -for (var x in a) { -} -if (3 in a) { -} +for (var x in a) { } +if (3 in a) { } var b = '' in 0; var c; var y; -if (y in c) { -} +if (y in c) { } diff --git a/tests/baselines/reference/inOperatorWithFunction.js b/tests/baselines/reference/inOperatorWithFunction.js index f06e95ff6b..bc293ca2c4 100644 --- a/tests/baselines/reference/inOperatorWithFunction.js +++ b/tests/baselines/reference/inOperatorWithFunction.js @@ -4,9 +4,5 @@ fn("a" in { "a": true }); //// [inOperatorWithFunction.js] -var fn = function (val) { - return val; -}; -fn("a" in { - "a": true -}); +var fn = function (val) { return val; }; +fn("a" in { "a": true }); diff --git a/tests/baselines/reference/incompatibleTypes.js b/tests/baselines/reference/incompatibleTypes.js index a0b4d0f9ca..7e24afecf5 100644 --- a/tests/baselines/reference/incompatibleTypes.js +++ b/tests/baselines/reference/incompatibleTypes.js @@ -102,18 +102,12 @@ var C4 = (function () { } return C4; })(); -function if1(a) { -} +function if1(a) { } var c1; var c2; if1(c1); -function of1(a) { - return null; -} -of1({ - e: 0, - f: 0 -}); +function of1(a) { return null; } +of1({ e: 0, f: 0 }); function foo(fn) { } function bar() { @@ -122,25 +116,7 @@ function bar() { map = {}; }); } -var o1 = { - e: 0, - f: 0 -}; -var a1 = [ - { - e: 0, - f: 0 - }, - { - e: 0, - f: 0 - }, - { - e: 0, - g: 0 - } -]; +var o1 = { e: 0, f: 0 }; +var a1 = [{ e: 0, f: 0 }, { e: 0, f: 0 }, { e: 0, g: 0 }]; var i1c1 = 5; -var fp1 = function (a) { - return 0; -}; +var fp1 = function (a) { return 0; }; diff --git a/tests/baselines/reference/incompleteObjectLiteral1.js b/tests/baselines/reference/incompleteObjectLiteral1.js index 6859267fee..ecdbe86604 100644 --- a/tests/baselines/reference/incompleteObjectLiteral1.js +++ b/tests/baselines/reference/incompleteObjectLiteral1.js @@ -3,7 +3,5 @@ var tt = { aa; } var x = tt; //// [incompleteObjectLiteral1.js] -var tt = { - aa: -}; +var tt = { aa: }; var x = tt; diff --git a/tests/baselines/reference/incrementOperatorWithAnyOtherType.js b/tests/baselines/reference/incrementOperatorWithAnyOtherType.js index 7fd47a937a..4c9d570d07 100644 --- a/tests/baselines/reference/incrementOperatorWithAnyOtherType.js +++ b/tests/baselines/reference/incrementOperatorWithAnyOtherType.js @@ -52,14 +52,8 @@ M.n++; // ++ operator on any type var ANY; var ANY1; -var ANY2 = [ - "", - "" -]; -var obj = { - x: 1, - y: null -}; +var ANY2 = ["", ""]; +var obj = { x: 1, y: null }; var A = (function () { function A() { } diff --git a/tests/baselines/reference/incrementOperatorWithAnyOtherTypeInvalidOperations.js b/tests/baselines/reference/incrementOperatorWithAnyOtherTypeInvalidOperations.js index 3e1c47faed..6f76fba6d8 100644 --- a/tests/baselines/reference/incrementOperatorWithAnyOtherTypeInvalidOperations.js +++ b/tests/baselines/reference/incrementOperatorWithAnyOtherTypeInvalidOperations.js @@ -72,16 +72,9 @@ ANY2++; //// [incrementOperatorWithAnyOtherTypeInvalidOperations.js] // ++ operator on any type var ANY1; -var ANY2 = [ - 1, - 2 -]; +var ANY2 = [1, 2]; var obj; -var obj1 = { - x: "", - y: function () { - } -}; +var obj1 = { x: "", y: function () { } }; function foo() { var a; return a; diff --git a/tests/baselines/reference/incrementOperatorWithNumberType.js b/tests/baselines/reference/incrementOperatorWithNumberType.js index e8312c5e5f..09365833e3 100644 --- a/tests/baselines/reference/incrementOperatorWithNumberType.js +++ b/tests/baselines/reference/incrementOperatorWithNumberType.js @@ -42,10 +42,7 @@ objA.a++, M.n++; //// [incrementOperatorWithNumberType.js] // ++ operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; +var NUMBER1 = [1, 2]; var A = (function () { function A() { } diff --git a/tests/baselines/reference/incrementOperatorWithNumberTypeInvalidOperations.js b/tests/baselines/reference/incrementOperatorWithNumberTypeInvalidOperations.js index 4629f10a96..eb9cd94928 100644 --- a/tests/baselines/reference/incrementOperatorWithNumberTypeInvalidOperations.js +++ b/tests/baselines/reference/incrementOperatorWithNumberTypeInvalidOperations.js @@ -49,19 +49,12 @@ foo()++; //// [incrementOperatorWithNumberTypeInvalidOperations.js] // ++ operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; -function foo() { - return 1; -} +var NUMBER1 = [1, 2]; +function foo() { return 1; } var A = (function () { function A() { } - A.foo = function () { - return 1; - }; + A.foo = function () { return 1; }; return A; })(); var M; @@ -74,27 +67,11 @@ var ResultIsNumber1 = ++NUMBER1; var ResultIsNumber2 = NUMBER1++; // number type literal var ResultIsNumber3 = ++1; -var ResultIsNumber4 = ++{ - x: 1, - y: 2 -}; -var ResultIsNumber5 = ++{ - x: 1, - y: function (n) { - return n; - } -}; +var ResultIsNumber4 = ++{ x: 1, y: 2 }; +var ResultIsNumber5 = ++{ x: 1, y: function (n) { return n; } }; var ResultIsNumber6 = 1++; -var ResultIsNumber7 = { - x: 1, - y: 2 -}++; -var ResultIsNumber8 = { - x: 1, - y: function (n) { - return n; - } -}++; +var ResultIsNumber7 = { x: 1, y: 2 }++; +var ResultIsNumber8 = { x: 1, y: function (n) { return n; } }++; // number type expressions var ResultIsNumber9 = ++foo(); var ResultIsNumber10 = ++A.foo(); diff --git a/tests/baselines/reference/incrementOperatorWithUnsupportedBooleanType.js b/tests/baselines/reference/incrementOperatorWithUnsupportedBooleanType.js index 09549a71a0..6a974443f7 100644 --- a/tests/baselines/reference/incrementOperatorWithUnsupportedBooleanType.js +++ b/tests/baselines/reference/incrementOperatorWithUnsupportedBooleanType.js @@ -57,15 +57,11 @@ objA.a++, M.n++; //// [incrementOperatorWithUnsupportedBooleanType.js] // ++ operator on boolean type var BOOLEAN; -function foo() { - return true; -} +function foo() { return true; } var A = (function () { function A() { } - A.foo = function () { - return true; - }; + A.foo = function () { return true; }; return A; })(); var M; @@ -78,27 +74,11 @@ var ResultIsNumber1 = ++BOOLEAN; var ResultIsNumber2 = BOOLEAN++; // boolean type literal var ResultIsNumber3 = ++true; -var ResultIsNumber4 = ++{ - x: true, - y: false -}; -var ResultIsNumber5 = ++{ - x: true, - y: function (n) { - return n; - } -}; +var ResultIsNumber4 = ++{ x: true, y: false }; +var ResultIsNumber5 = ++{ x: true, y: function (n) { return n; } }; var ResultIsNumber6 = true++; -var ResultIsNumber7 = { - x: true, - y: false -}++; -var ResultIsNumber8 = { - x: true, - y: function (n) { - return n; - } -}++; +var ResultIsNumber7 = { x: true, y: false }++; +var ResultIsNumber8 = { x: true, y: function (n) { return n; } }++; // boolean type expressions var ResultIsNumber9 = ++objA.a; var ResultIsNumber10 = ++M.n; diff --git a/tests/baselines/reference/incrementOperatorWithUnsupportedStringType.js b/tests/baselines/reference/incrementOperatorWithUnsupportedStringType.js index 5abb2cd8b7..82bf03cd83 100644 --- a/tests/baselines/reference/incrementOperatorWithUnsupportedStringType.js +++ b/tests/baselines/reference/incrementOperatorWithUnsupportedStringType.js @@ -68,19 +68,12 @@ objA.a++, M.n++; //// [incrementOperatorWithUnsupportedStringType.js] // ++ operator on string type var STRING; -var STRING1 = [ - "", - "" -]; -function foo() { - return ""; -} +var STRING1 = ["", ""]; +function foo() { return ""; } var A = (function () { function A() { } - A.foo = function () { - return ""; - }; + A.foo = function () { return ""; }; return A; })(); var M; @@ -95,27 +88,11 @@ var ResultIsNumber3 = STRING++; var ResultIsNumber4 = STRING1++; // string type literal var ResultIsNumber5 = ++""; -var ResultIsNumber6 = ++{ - x: "", - y: "" -}; -var ResultIsNumber7 = ++{ - x: "", - y: function (s) { - return s; - } -}; +var ResultIsNumber6 = ++{ x: "", y: "" }; +var ResultIsNumber7 = ++{ x: "", y: function (s) { return s; } }; var ResultIsNumber8 = ""++; -var ResultIsNumber9 = { - x: "", - y: "" -}++; -var ResultIsNumber10 = { - x: "", - y: function (s) { - return s; - } -}++; +var ResultIsNumber9 = { x: "", y: "" }++; +var ResultIsNumber10 = { x: "", y: function (s) { return s; } }++; // string type expressions var ResultIsNumber11 = ++objA.a; var ResultIsNumber12 = ++M.n; diff --git a/tests/baselines/reference/indexSignaturesInferentialTyping.js b/tests/baselines/reference/indexSignaturesInferentialTyping.js index fc1525eda0..53636be716 100644 --- a/tests/baselines/reference/indexSignaturesInferentialTyping.js +++ b/tests/baselines/reference/indexSignaturesInferentialTyping.js @@ -9,25 +9,9 @@ var x4 = bar({ zero: 0, one: 1 }); // type should be number //// [indexSignaturesInferentialTyping.js] -function foo(items) { - return undefined; -} -function bar(items) { - return undefined; -} -var x1 = foo({ - 0: 0, - 1: 1 -}); // type should be number -var x2 = foo({ - zero: 0, - one: 1 -}); -var x3 = bar({ - 0: 0, - 1: 1 -}); -var x4 = bar({ - zero: 0, - one: 1 -}); // type should be number +function foo(items) { return undefined; } +function bar(items) { return undefined; } +var x1 = foo({ 0: 0, 1: 1 }); // type should be number +var x2 = foo({ zero: 0, one: 1 }); +var x3 = bar({ 0: 0, 1: 1 }); +var x4 = bar({ zero: 0, one: 1 }); // type should be number diff --git a/tests/baselines/reference/indexer.js b/tests/baselines/reference/indexer.js index 12c28236d8..97e734a029 100644 --- a/tests/baselines/reference/indexer.js +++ b/tests/baselines/reference/indexer.js @@ -11,12 +11,5 @@ var jq:JQuery={ 0: { id : "a" }, 1: { id : "b" } }; jq[0].id; //// [indexer.js] -var jq = { - 0: { - id: "a" - }, - 1: { - id: "b" - } -}; +var jq = { 0: { id: "a" }, 1: { id: "b" } }; jq[0].id; diff --git a/tests/baselines/reference/indexerA.js b/tests/baselines/reference/indexerA.js index 2a377c3436..5216026f71 100644 --- a/tests/baselines/reference/indexerA.js +++ b/tests/baselines/reference/indexerA.js @@ -21,12 +21,5 @@ var JQuery = (function () { } return JQuery; })(); -var jq = { - 0: { - id: "a" - }, - 1: { - id: "b" - } -}; +var jq = { 0: { id: "a" }, 1: { id: "b" } }; jq[0].id; diff --git a/tests/baselines/reference/indexerWithTuple.js b/tests/baselines/reference/indexerWithTuple.js index b73b5e80a8..91d90792e6 100644 --- a/tests/baselines/reference/indexerWithTuple.js +++ b/tests/baselines/reference/indexerWithTuple.js @@ -33,25 +33,10 @@ var eleUnion25 = unionTuple2["0"]; // boolean var eleUnion26 = unionTuple2["1"]; // string | number //// [indexerWithTuple.js] -var strNumTuple = [ - "foo", - 10 -]; -var numTupleTuple = [ - 10, - [ - "bar", - 20 - ] -]; -var unionTuple1 = [ - 10, - "foo" -]; -var unionTuple2 = [ - true, - "foo" -]; +var strNumTuple = ["foo", 10]; +var numTupleTuple = [10, ["bar", 20]]; +var unionTuple1 = [10, "foo"]; +var unionTuple2 = [true, "foo"]; // no error var idx0 = 0; var idx1 = 1; diff --git a/tests/baselines/reference/inferSecondaryParameter.js b/tests/baselines/reference/inferSecondaryParameter.js index a02e10b557..24689aa949 100644 --- a/tests/baselines/reference/inferSecondaryParameter.js +++ b/tests/baselines/reference/inferSecondaryParameter.js @@ -11,10 +11,7 @@ b.m("test", function (bug) { //// [inferSecondaryParameter.js] // type inference on 'bug' should give 'any' -var b = { - m: function (test, fn) { - } -}; +var b = { m: function (test, fn) { } }; b.m("test", function (bug) { var a = bug; }); diff --git a/tests/baselines/reference/inferTypeArgumentsInSignatureWithRestParameters.js b/tests/baselines/reference/inferTypeArgumentsInSignatureWithRestParameters.js index 194d9198d2..97fefc0571 100644 --- a/tests/baselines/reference/inferTypeArgumentsInSignatureWithRestParameters.js +++ b/tests/baselines/reference/inferTypeArgumentsInSignatureWithRestParameters.js @@ -30,15 +30,8 @@ function h(nonarray) { args[_i - 1] = arguments[_i]; } } -function i(array, opt) { -} -var a = [ - 1, - 2, - 3, - 4, - 5 -]; +function i(array, opt) { } +var a = [1, 2, 3, 4, 5]; f(a); // OK g(a); // OK h(a); // OK diff --git a/tests/baselines/reference/inferenceFromParameterlessLambda.js b/tests/baselines/reference/inferenceFromParameterlessLambda.js index c1b970dee6..40c18c9afe 100644 --- a/tests/baselines/reference/inferenceFromParameterlessLambda.js +++ b/tests/baselines/reference/inferenceFromParameterlessLambda.js @@ -11,11 +11,6 @@ foo(n => n.length, () => 'hi'); //// [inferenceFromParameterlessLambda.js] -function foo(o, i) { -} +function foo(o, i) { } // Infer string from second argument because it isn't context sensitive -foo(function (n) { - return n.length; -}, function () { - return 'hi'; -}); +foo(function (n) { return n.length; }, function () { return 'hi'; }); diff --git a/tests/baselines/reference/inferentialTypingWithFunctionType2.js b/tests/baselines/reference/inferentialTypingWithFunctionType2.js index 758f0e2746..a3215a19e2 100644 --- a/tests/baselines/reference/inferentialTypingWithFunctionType2.js +++ b/tests/baselines/reference/inferentialTypingWithFunctionType2.js @@ -8,8 +8,4 @@ var x = [1, 2, 3].map(identity)[0]; function identity(a) { return a; } -var x = [ - 1, - 2, - 3 -].map(identity)[0]; +var x = [1, 2, 3].map(identity)[0]; diff --git a/tests/baselines/reference/inferentialTypingWithFunctionTypeNested.js b/tests/baselines/reference/inferentialTypingWithFunctionTypeNested.js index b9b6f9e4bd..aeb9a84077 100644 --- a/tests/baselines/reference/inferentialTypingWithFunctionTypeNested.js +++ b/tests/baselines/reference/inferentialTypingWithFunctionTypeNested.js @@ -5,8 +5,4 @@ declare function identity(y: V): V; var s = map("", () => { return { x: identity }; }); //// [inferentialTypingWithFunctionTypeNested.js] -var s = map("", function () { - return { - x: identity - }; -}); +var s = map("", function () { return { x: identity }; }); diff --git a/tests/baselines/reference/inferentialTypingWithFunctionTypeSyntacticScenarios.js b/tests/baselines/reference/inferentialTypingWithFunctionTypeSyntacticScenarios.js index b41a9f6240..2f5eea63a8 100644 --- a/tests/baselines/reference/inferentialTypingWithFunctionTypeSyntacticScenarios.js +++ b/tests/baselines/reference/inferentialTypingWithFunctionTypeSyntacticScenarios.js @@ -36,16 +36,12 @@ s = map("", ("", identity)); //// [inferentialTypingWithFunctionTypeSyntacticScenarios.js] var s; // dotted name -var dottedIdentity = { - x: identity -}; +var dottedIdentity = { x: identity }; s = map("", dottedIdentity.x); // index expression s = map("", dottedIdentity['x']); // function call -s = map("", (function () { - return identity; -})()); +s = map("", (function () { return identity; })()); var ic; s = map("", new ic()); // assignment diff --git a/tests/baselines/reference/inferentialTypingWithFunctionTypeZip.js b/tests/baselines/reference/inferentialTypingWithFunctionTypeZip.js index 0e413f9b17..35f0928378 100644 --- a/tests/baselines/reference/inferentialTypingWithFunctionTypeZip.js +++ b/tests/baselines/reference/inferentialTypingWithFunctionTypeZip.js @@ -7,11 +7,5 @@ var i = result[0].x; // number //// [inferentialTypingWithFunctionTypeZip.js] var pair; var zipWith; -var result = zipWith([ - 1, - 2 -], [ - 'a', - 'b' -], pair); +var result = zipWith([1, 2], ['a', 'b'], pair); var i = result[0].x; // number diff --git a/tests/baselines/reference/inferentialTypingWithObjectLiteralProperties.js b/tests/baselines/reference/inferentialTypingWithObjectLiteralProperties.js index af2b936b2a..216604dd4d 100644 --- a/tests/baselines/reference/inferentialTypingWithObjectLiteralProperties.js +++ b/tests/baselines/reference/inferentialTypingWithObjectLiteralProperties.js @@ -10,21 +10,5 @@ f({ x: [1] }, { x: [null] }).x[0] = "" // was error TS2011: Cannot convert 'stri function f(x, y) { return x; } -f({ - x: [ - null - ] -}, { - x: [ - 1 - ] -}).x[0] = ""; // ok -f({ - x: [ - 1 - ] -}, { - x: [ - null - ] -}).x[0] = ""; // was error TS2011: Cannot convert 'string' to 'number'. +f({ x: [null] }, { x: [1] }).x[0] = ""; // ok +f({ x: [1] }, { x: [null] }).x[0] = ""; // was error TS2011: Cannot convert 'string' to 'number'. diff --git a/tests/baselines/reference/inheritance.js b/tests/baselines/reference/inheritance.js index 1fca887a9b..f7a274b199 100644 --- a/tests/baselines/reference/inheritance.js +++ b/tests/baselines/reference/inheritance.js @@ -79,13 +79,9 @@ var ND = (function (_super) { })(N); var Good = (function () { function Good() { - this.f = function () { - return 0; - }; + this.f = function () { return 0; }; } - Good.prototype.g = function () { - return 0; - }; + Good.prototype.g = function () { return 0; }; return Good; })(); var Baad = (function (_super) { @@ -93,11 +89,7 @@ var Baad = (function (_super) { function Baad() { _super.apply(this, arguments); } - Baad.prototype.f = function () { - return 0; - }; - Baad.prototype.g = function (n) { - return 0; - }; + Baad.prototype.f = function () { return 0; }; + Baad.prototype.g = function (n) { return 0; }; return Baad; })(Good); diff --git a/tests/baselines/reference/inheritance1.js b/tests/baselines/reference/inheritance1.js index e6dbd35e0d..f00a46922b 100644 --- a/tests/baselines/reference/inheritance1.js +++ b/tests/baselines/reference/inheritance1.js @@ -78,8 +78,7 @@ var Button = (function (_super) { function Button() { _super.apply(this, arguments); } - Button.prototype.select = function () { - }; + Button.prototype.select = function () { }; return Button; })(Control); var TextBox = (function (_super) { @@ -87,8 +86,7 @@ var TextBox = (function (_super) { function TextBox() { _super.apply(this, arguments); } - TextBox.prototype.select = function () { - }; + TextBox.prototype.select = function () { }; return TextBox; })(Control); var ImageBase = (function (_super) { @@ -108,15 +106,13 @@ var Image1 = (function (_super) { var Locations = (function () { function Locations() { } - Locations.prototype.select = function () { - }; + Locations.prototype.select = function () { }; return Locations; })(); var Locations1 = (function () { function Locations1() { } - Locations1.prototype.select = function () { - }; + Locations1.prototype.select = function () { }; return Locations1; })(); var sc; diff --git a/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollision.js b/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollision.js index 45293ec302..4544df2dcf 100644 --- a/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollision.js +++ b/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollision.js @@ -20,8 +20,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.myMethod = function () { - }; + A.prototype.myMethod = function () { }; return A; })(); var B = (function (_super) { @@ -36,7 +35,6 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype.myMethod = function () { - }; + C.prototype.myMethod = function () { }; return C; })(B); diff --git a/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollisionWithPublicMember.js b/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollisionWithPublicMember.js index 339511df6b..df6e594317 100644 --- a/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollisionWithPublicMember.js +++ b/tests/baselines/reference/inheritanceGrandParentPrivateMemberCollisionWithPublicMember.js @@ -20,8 +20,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.myMethod = function () { - }; + A.prototype.myMethod = function () { }; return A; })(); var B = (function (_super) { @@ -36,7 +35,6 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype.myMethod = function () { - }; + C.prototype.myMethod = function () { }; return C; })(B); diff --git a/tests/baselines/reference/inheritanceGrandParentPublicMemberCollisionWithPrivateMember.js b/tests/baselines/reference/inheritanceGrandParentPublicMemberCollisionWithPrivateMember.js index f69a4962db..682a8ab440 100644 --- a/tests/baselines/reference/inheritanceGrandParentPublicMemberCollisionWithPrivateMember.js +++ b/tests/baselines/reference/inheritanceGrandParentPublicMemberCollisionWithPrivateMember.js @@ -20,8 +20,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.myMethod = function () { - }; + A.prototype.myMethod = function () { }; return A; })(); var B = (function (_super) { @@ -36,7 +35,6 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype.myMethod = function () { - }; + C.prototype.myMethod = function () { }; return C; })(B); diff --git a/tests/baselines/reference/inheritedFunctionAssignmentCompatibility.js b/tests/baselines/reference/inheritedFunctionAssignmentCompatibility.js index 49fd1e4058..85801ca704 100644 --- a/tests/baselines/reference/inheritedFunctionAssignmentCompatibility.js +++ b/tests/baselines/reference/inheritedFunctionAssignmentCompatibility.js @@ -9,11 +9,6 @@ fn(function (a, b) { return true; }) //// [inheritedFunctionAssignmentCompatibility.js] -function fn(cb) { -} -fn(function (a, b) { - return true; -}); -fn(function (a, b) { - return true; -}); +function fn(cb) { } +fn(function (a, b) { return true; }); +fn(function (a, b) { return true; }); diff --git a/tests/baselines/reference/initializePropertiesWithRenamedLet.js b/tests/baselines/reference/initializePropertiesWithRenamedLet.js index 1d34d7c13f..d4f985bea5 100644 --- a/tests/baselines/reference/initializePropertiesWithRenamedLet.js +++ b/tests/baselines/reference/initializePropertiesWithRenamedLet.js @@ -20,27 +20,15 @@ if (true) { var x0; if (true) { var x0_1; - var obj1 = { - x0: x0_1 - }; - var obj2 = { - x0: x0_1 - }; + var obj1 = { x0: x0_1 }; + var obj2 = { x0: x0_1 }; } var x, y, z; if (true) { - var x_1 = ({ - x: 0 - }).x; - var y_1 = ({ - y: 0 - }).y; + var x_1 = ({ x: 0 }).x; + var y_1 = ({ y: 0 }).y; var z_1; - (_a = { - z: 0 - }, z_1 = _a.z, _a); - (_b = { - z: 0 - }, z_1 = _b.z, _b); + (_a = { z: 0 }, z_1 = _a.z, _a); + (_b = { z: 0 }, z_1 = _b.z, _b); } var _a, _b; diff --git a/tests/baselines/reference/innerBoundLambdaEmit.js b/tests/baselines/reference/innerBoundLambdaEmit.js index 2921cad55d..c09cc8e5a6 100644 --- a/tests/baselines/reference/innerBoundLambdaEmit.js +++ b/tests/baselines/reference/innerBoundLambdaEmit.js @@ -18,6 +18,5 @@ var M; return Foo; })(); M.Foo = Foo; - var bar = function () { - }; + var bar = function () { }; })(M || (M = {})); diff --git a/tests/baselines/reference/innerFunc.js b/tests/baselines/reference/innerFunc.js index 1676d0789d..c790c09e27 100644 --- a/tests/baselines/reference/innerFunc.js +++ b/tests/baselines/reference/innerFunc.js @@ -14,17 +14,13 @@ module M { //// [innerFunc.js] function salt() { - function pepper() { - return 5; - } + function pepper() { return 5; } return pepper(); } var M; (function (M) { function tungsten() { - function oxygen() { - return 6; - } + function oxygen() { return 6; } ; return oxygen(); } diff --git a/tests/baselines/reference/innerModExport1.js b/tests/baselines/reference/innerModExport1.js index d61e79f239..cbeced3704 100644 --- a/tests/baselines/reference/innerModExport1.js +++ b/tests/baselines/reference/innerModExport1.js @@ -28,18 +28,12 @@ var Outer; { var non_export_var = 0; Outer.export_var = 1; - function NonExportFunc() { - return 0; - } - function ExportFunc() { - return 0; - } + function NonExportFunc() { return 0; } + function ExportFunc() { return 0; } Outer.ExportFunc = ExportFunc; } Outer.outer_var_export = 0; - function outerFuncExport() { - return 0; - } + function outerFuncExport() { return 0; } Outer.outerFuncExport = outerFuncExport; })(Outer || (Outer = {})); Outer.ExportFunc(); diff --git a/tests/baselines/reference/innerModExport2.js b/tests/baselines/reference/innerModExport2.js index 26399879e6..a1526daf6f 100644 --- a/tests/baselines/reference/innerModExport2.js +++ b/tests/baselines/reference/innerModExport2.js @@ -29,19 +29,13 @@ var Outer; { var non_export_var = 0; Outer.export_var = 1; - function NonExportFunc() { - return 0; - } - function ExportFunc() { - return 0; - } + function NonExportFunc() { return 0; } + function ExportFunc() { return 0; } Outer.ExportFunc = ExportFunc; } var export_var; Outer.outer_var_export = 0; - function outerFuncExport() { - return 0; - } + function outerFuncExport() { return 0; } Outer.outerFuncExport = outerFuncExport; })(Outer || (Outer = {})); Outer.NonExportFunc(); diff --git a/tests/baselines/reference/innerOverloads.js b/tests/baselines/reference/innerOverloads.js index 184b644406..19e3fa7890 100644 --- a/tests/baselines/reference/innerOverloads.js +++ b/tests/baselines/reference/innerOverloads.js @@ -14,9 +14,7 @@ var x = outer(); // should work //// [innerOverloads.js] function outer() { - function inner(a) { - return a; - } + function inner(a) { return a; } return inner(0); } var x = outer(); // should work diff --git a/tests/baselines/reference/instanceAndStaticDeclarations1.js b/tests/baselines/reference/instanceAndStaticDeclarations1.js index 1396e2bcfa..7dbd6dcbe7 100644 --- a/tests/baselines/reference/instanceAndStaticDeclarations1.js +++ b/tests/baselines/reference/instanceAndStaticDeclarations1.js @@ -24,9 +24,7 @@ var Point = (function () { var dy = this.y - p.y; return Math.sqrt(dx * dx + dy * dy); }; - Point.distance = function (p1, p2) { - return p1.distance(p2); - }; + Point.distance = function (p1, p2) { return p1.distance(p2); }; Point.origin = new Point(0, 0); return Point; })(); diff --git a/tests/baselines/reference/instanceMemberAssignsToClassPrototype.js b/tests/baselines/reference/instanceMemberAssignsToClassPrototype.js index 28f7296f0e..51c38282a7 100644 --- a/tests/baselines/reference/instanceMemberAssignsToClassPrototype.js +++ b/tests/baselines/reference/instanceMemberAssignsToClassPrototype.js @@ -17,18 +17,12 @@ var C = (function () { function C() { } C.prototype.foo = function () { - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; }; C.prototype.bar = function (x) { - C.prototype.bar = function () { - }; // error - C.prototype.bar = function (x) { - return x; - }; // ok - C.prototype.bar = function (x) { - return 1; - }; // ok + C.prototype.bar = function () { }; // error + C.prototype.bar = function (x) { return x; }; // ok + C.prototype.bar = function (x) { return 1; }; // ok return 1; }; return C; diff --git a/tests/baselines/reference/instancePropertiesInheritedIntoClassType.js b/tests/baselines/reference/instancePropertiesInheritedIntoClassType.js index eca12f7b1a..7ab3b4a0aa 100644 --- a/tests/baselines/reference/instancePropertiesInheritedIntoClassType.js +++ b/tests/baselines/reference/instancePropertiesInheritedIntoClassType.js @@ -60,14 +60,11 @@ var NonGeneric; get: function () { return 1; }, - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); - C.prototype.fn = function () { - return this; - }; + C.prototype.fn = function () { return this; }; return C; })(); var D = (function (_super) { @@ -95,14 +92,11 @@ var Generic; get: function () { return null; }, - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); - C.prototype.fn = function () { - return this; - }; + C.prototype.fn = function () { return this; }; return C; })(); var D = (function (_super) { diff --git a/tests/baselines/reference/instancePropertyInClassType.js b/tests/baselines/reference/instancePropertyInClassType.js index b2df44db6f..863f18de32 100644 --- a/tests/baselines/reference/instancePropertyInClassType.js +++ b/tests/baselines/reference/instancePropertyInClassType.js @@ -50,14 +50,11 @@ var NonGeneric; get: function () { return 1; }, - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); - C.prototype.fn = function () { - return this; - }; + C.prototype.fn = function () { return this; }; return C; })(); var c = new C(1, 2); @@ -78,14 +75,11 @@ var Generic; get: function () { return null; }, - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); - C.prototype.fn = function () { - return this; - }; + C.prototype.fn = function () { return this; }; return C; })(); var c = new C(1, ''); diff --git a/tests/baselines/reference/instanceofOperatorWithInvalidOperands.js b/tests/baselines/reference/instanceofOperatorWithInvalidOperands.js index 8309b7e7c0..9f83181a14 100644 --- a/tests/baselines/reference/instanceofOperatorWithInvalidOperands.js +++ b/tests/baselines/reference/instanceofOperatorWithInvalidOperands.js @@ -50,8 +50,7 @@ var rc1 = '' instanceof {}; var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); var x; diff --git a/tests/baselines/reference/instantiateNonGenericTypeWithTypeArguments.js b/tests/baselines/reference/instantiateNonGenericTypeWithTypeArguments.js index 15e4239eb0..3d7d2a7d01 100644 --- a/tests/baselines/reference/instantiateNonGenericTypeWithTypeArguments.js +++ b/tests/baselines/reference/instantiateNonGenericTypeWithTypeArguments.js @@ -27,8 +27,7 @@ var C = (function () { return C; })(); var c = new C(); -function Foo() { -} +function Foo() { } var r = new Foo(); var f; var r2 = new f(); diff --git a/tests/baselines/reference/instantiatedModule.js b/tests/baselines/reference/instantiatedModule.js index 2b1871aea9..8cabdeabe4 100644 --- a/tests/baselines/reference/instantiatedModule.js +++ b/tests/baselines/reference/instantiatedModule.js @@ -82,10 +82,7 @@ var M2; function Point() { } Point.Origin = function () { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; }; return Point; })(); diff --git a/tests/baselines/reference/intTypeCheck.js b/tests/baselines/reference/intTypeCheck.js index 41f648610b..fbbe1bb5d0 100644 --- a/tests/baselines/reference/intTypeCheck.js +++ b/tests/baselines/reference/intTypeCheck.js @@ -209,8 +209,7 @@ var obj87: i8 = new {}; var Base = (function () { function Base() { } - Base.prototype.foo = function () { - }; + Base.prototype.foo = function () { }; return Base; })(); var anyVar; @@ -220,22 +219,15 @@ var anyVar; var obj0; var obj1 = { p: null, - p3: function () { - return 0; - }, - p6: function (pa1) { - return 0; - }, - p7: function (pa1, pa2) { - return 0; - } + p3: function () { return 0; }, + p6: function (pa1) { return 0; }, + p7: function (pa1, pa2) { return 0; } }; var obj2 = new Object(); var obj3 = new obj0; var obj4 = new Base; var obj5 = null; -var obj6 = function () { -}; +var obj6 = function () { }; //var obj7: i1 = function foo() { }; var obj8 = anyVar; var obj9 = new < i1 > anyVar; @@ -249,9 +241,7 @@ var obj13 = new Object(); var obj14 = new obj11; var obj15 = new Base; var obj16 = null; -var obj17 = function () { - return 0; -}; +var obj17 = function () { return 0; }; //var obj18: i2 = function foo() { }; var obj19 = anyVar; var obj20 = new < i2 > anyVar; @@ -265,8 +255,7 @@ var obj24 = new Object(); var obj25 = new obj22; var obj26 = new Base; var obj27 = null; -var obj28 = function () { -}; +var obj28 = function () { }; //var obj29: i3 = function foo() { }; var obj30 = anyVar; var obj31 = new < i3 > anyVar; @@ -280,8 +269,7 @@ var obj35 = new Object(); var obj36 = new obj33; var obj37 = new Base; var obj38 = null; -var obj39 = function () { -}; +var obj39 = function () { }; //var obj40: i4 = function foo() { }; var obj41 = anyVar; var obj42 = new < i4 > anyVar; @@ -295,8 +283,7 @@ var obj46 = new Object(); var obj47 = new obj44; var obj48 = new Base; var obj49 = null; -var obj50 = function () { -}; +var obj50 = function () { }; //var obj51: i5 = function foo() { }; var obj52 = anyVar; var obj53 = new < i5 > anyVar; @@ -310,8 +297,7 @@ var obj57 = new Object(); var obj58 = new obj55; var obj59 = new Base; var obj60 = null; -var obj61 = function () { -}; +var obj61 = function () { }; //var obj62: i6 = function foo() { }; var obj63 = anyVar; var obj64 = new < i6 > anyVar; @@ -325,8 +311,7 @@ var obj68 = new Object(); var obj69 = new obj66; var obj70 = new Base; var obj71 = null; -var obj72 = function () { -}; +var obj72 = function () { }; //var obj73: i7 = function foo() { }; var obj74 = anyVar; var obj75 = new < i7 > anyVar; @@ -340,8 +325,7 @@ var obj79 = new Object(); var obj80 = new obj77; var obj81 = new Base; var obj82 = null; -var obj83 = function () { -}; +var obj83 = function () { }; //var obj84: i8 = function foo() { }; var obj85 = anyVar; var obj86 = new < i8 > anyVar; diff --git a/tests/baselines/reference/interface0.js b/tests/baselines/reference/interface0.js index 63feadfc4c..aecdb91e8a 100644 --- a/tests/baselines/reference/interface0.js +++ b/tests/baselines/reference/interface0.js @@ -7,6 +7,4 @@ var y: Generic = { x: 3 }; //// [interface0.js] -var y = { - x: 3 -}; +var y = { x: 3 }; diff --git a/tests/baselines/reference/interfaceAssignmentCompat.js b/tests/baselines/reference/interfaceAssignmentCompat.js index 7ddd22ee86..edaebbd38a 100644 --- a/tests/baselines/reference/interfaceAssignmentCompat.js +++ b/tests/baselines/reference/interfaceAssignmentCompat.js @@ -72,15 +72,9 @@ var M; function test() { var x = []; var result = ""; - x[0] = { - color: Color.Brown - }; - x[1] = { - color: Color.Blue - }; - x[2] = { - color: Color.Green - }; + x[0] = { color: Color.Brown }; + x[1] = { color: Color.Blue }; + x[2] = { color: Color.Green }; x = x.sort(CompareYeux); // parameter mismatch // type of z inferred from specialized array type var z = x.sort(CompareEyes); // ok diff --git a/tests/baselines/reference/interfaceContextualType.js b/tests/baselines/reference/interfaceContextualType.js index 996b8fc98d..2dbdb958d6 100644 --- a/tests/baselines/reference/interfaceContextualType.js +++ b/tests/baselines/reference/interfaceContextualType.js @@ -27,15 +27,11 @@ var Bug = (function () { } Bug.prototype.ok = function () { this.values = {}; - this.values['comments'] = { - italic: true - }; + this.values['comments'] = { italic: true }; }; Bug.prototype.shouldBeOK = function () { this.values = { - comments: { - italic: true - } + comments: { italic: true } }; }; return Bug; diff --git a/tests/baselines/reference/interfaceDeclaration2.js b/tests/baselines/reference/interfaceDeclaration2.js index 0bd59c065e..30f9df0fac 100644 --- a/tests/baselines/reference/interfaceDeclaration2.js +++ b/tests/baselines/reference/interfaceDeclaration2.js @@ -19,6 +19,5 @@ var I2 = (function () { } return I2; })(); -function I3() { -} +function I3() { } var I4; diff --git a/tests/baselines/reference/interfaceDeclaration4.js b/tests/baselines/reference/interfaceDeclaration4.js index 576479c2be..728ef7156e 100644 --- a/tests/baselines/reference/interfaceDeclaration4.js +++ b/tests/baselines/reference/interfaceDeclaration4.js @@ -69,5 +69,4 @@ var C3 = (function () { return C3; })(); I1; -{ -} +{ } diff --git a/tests/baselines/reference/interfaceExtendingClass.js b/tests/baselines/reference/interfaceExtendingClass.js index 39db746091..f1232d7824 100644 --- a/tests/baselines/reference/interfaceExtendingClass.js +++ b/tests/baselines/reference/interfaceExtendingClass.js @@ -23,8 +23,7 @@ i = f; var Foo = (function () { function Foo() { } - Foo.prototype.y = function () { - }; + Foo.prototype.y = function () { }; Object.defineProperty(Foo.prototype, "Z", { get: function () { return 1; diff --git a/tests/baselines/reference/interfaceExtendingClass2.js b/tests/baselines/reference/interfaceExtendingClass2.js index b0958717aa..6e6605e245 100644 --- a/tests/baselines/reference/interfaceExtendingClass2.js +++ b/tests/baselines/reference/interfaceExtendingClass2.js @@ -19,8 +19,7 @@ interface I2 extends Foo { // error var Foo = (function () { function Foo() { } - Foo.prototype.y = function () { - }; + Foo.prototype.y = function () { }; Object.defineProperty(Foo.prototype, "Z", { get: function () { return 1; diff --git a/tests/baselines/reference/interfaceExtendsClass1.js b/tests/baselines/reference/interfaceExtendsClass1.js index 5903726c05..d376f2dca9 100644 --- a/tests/baselines/reference/interfaceExtendsClass1.js +++ b/tests/baselines/reference/interfaceExtendsClass1.js @@ -35,8 +35,7 @@ var Button = (function (_super) { function Button() { _super.apply(this, arguments); } - Button.prototype.select = function () { - }; + Button.prototype.select = function () { }; return Button; })(Control); var TextBox = (function (_super) { @@ -44,8 +43,7 @@ var TextBox = (function (_super) { function TextBox() { _super.apply(this, arguments); } - TextBox.prototype.select = function () { - }; + TextBox.prototype.select = function () { }; return TextBox; })(Control); var Image = (function (_super) { @@ -58,7 +56,6 @@ var Image = (function (_super) { var Location = (function () { function Location() { } - Location.prototype.select = function () { - }; + Location.prototype.select = function () { }; return Location; })(); diff --git a/tests/baselines/reference/interfaceExtendsClassWithPrivate1.js b/tests/baselines/reference/interfaceExtendsClassWithPrivate1.js index 4cf0281ac7..521a71199a 100644 --- a/tests/baselines/reference/interfaceExtendsClassWithPrivate1.js +++ b/tests/baselines/reference/interfaceExtendsClassWithPrivate1.js @@ -38,9 +38,7 @@ var C = (function () { function C() { this.x = 1; } - C.prototype.foo = function (x) { - return x; - }; + C.prototype.foo = function (x) { return x; }; return C; })(); var D = (function (_super) { @@ -48,14 +46,9 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.prototype.foo = function (x) { - return x; - }; - D.prototype.other = function (x) { - return x; - }; - D.prototype.bar = function () { - }; + D.prototype.foo = function (x) { return x; }; + D.prototype.other = function (x) { return x; }; + D.prototype.bar = function () { }; return D; })(C); var c; diff --git a/tests/baselines/reference/interfaceExtendsClassWithPrivate2.js b/tests/baselines/reference/interfaceExtendsClassWithPrivate2.js index 5805302d7d..c177f2e7a9 100644 --- a/tests/baselines/reference/interfaceExtendsClassWithPrivate2.js +++ b/tests/baselines/reference/interfaceExtendsClassWithPrivate2.js @@ -34,9 +34,7 @@ var C = (function () { function C() { this.x = 1; } - C.prototype.foo = function (x) { - return x; - }; + C.prototype.foo = function (x) { return x; }; return C; })(); var D = (function (_super) { @@ -46,14 +44,9 @@ var D = (function (_super) { this.x = 2; this.y = 3; } - D.prototype.foo = function (x) { - return x; - }; - D.prototype.other = function (x) { - return x; - }; - D.prototype.bar = function () { - }; + D.prototype.foo = function (x) { return x; }; + D.prototype.other = function (x) { return x; }; + D.prototype.bar = function () { }; return D; })(C); var D2 = (function (_super) { @@ -62,13 +55,8 @@ var D2 = (function (_super) { _super.apply(this, arguments); this.x = ""; } - D2.prototype.foo = function (x) { - return x; - }; - D2.prototype.other = function (x) { - return x; - }; - D2.prototype.bar = function () { - }; + D2.prototype.foo = function (x) { return x; }; + D2.prototype.other = function (x) { return x; }; + D2.prototype.bar = function () { }; return D2; })(C); diff --git a/tests/baselines/reference/interfaceImplementation1.js b/tests/baselines/reference/interfaceImplementation1.js index ce82a24f63..8f02596682 100644 --- a/tests/baselines/reference/interfaceImplementation1.js +++ b/tests/baselines/reference/interfaceImplementation1.js @@ -50,8 +50,7 @@ c["foo"]; var C1 = (function () { function C1() { } - C1.prototype.iFn = function (n, s) { - }; + C1.prototype.iFn = function (n, s) { }; return C1; })(); var C2 = (function () { diff --git a/tests/baselines/reference/interfaceImplementation3.js b/tests/baselines/reference/interfaceImplementation3.js index 626c92e83d..da85de545c 100644 --- a/tests/baselines/reference/interfaceImplementation3.js +++ b/tests/baselines/reference/interfaceImplementation3.js @@ -19,7 +19,6 @@ class C4 implements I1 { var C4 = (function () { function C4() { } - C4.prototype.iFn = function () { - }; + C4.prototype.iFn = function () { }; return C4; })(); diff --git a/tests/baselines/reference/interfaceImplementation4.js b/tests/baselines/reference/interfaceImplementation4.js index 94565d1b22..4a093381b5 100644 --- a/tests/baselines/reference/interfaceImplementation4.js +++ b/tests/baselines/reference/interfaceImplementation4.js @@ -17,7 +17,6 @@ class C5 implements I1 { var C5 = (function () { function C5() { } - C5.prototype.iFn = function () { - }; + C5.prototype.iFn = function () { }; return C5; })(); diff --git a/tests/baselines/reference/interfaceImplementation5.js b/tests/baselines/reference/interfaceImplementation5.js index 667c5f045e..c710eda84f 100644 --- a/tests/baselines/reference/interfaceImplementation5.js +++ b/tests/baselines/reference/interfaceImplementation5.js @@ -36,9 +36,7 @@ var C1 = (function () { function C1() { } Object.defineProperty(C1.prototype, "getset1", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); @@ -48,8 +46,7 @@ var C2 = (function () { function C2() { } Object.defineProperty(C2.prototype, "getset1", { - set: function (baz) { - }, + set: function (baz) { }, enumerable: true, configurable: true }); @@ -59,11 +56,8 @@ var C3 = (function () { function C3() { } Object.defineProperty(C3.prototype, "getset1", { - get: function () { - return 1; - }, - set: function (baz) { - }, + get: function () { return 1; }, + set: function (baz) { }, enumerable: true, configurable: true }); @@ -73,10 +67,7 @@ var C4 = (function () { function C4() { } Object.defineProperty(C4.prototype, "getset1", { - get: function () { - var x; - return x; - }, + get: function () { var x; return x; }, enumerable: true, configurable: true }); @@ -86,8 +77,7 @@ var C5 = (function () { function C5() { } Object.defineProperty(C5.prototype, "getset1", { - set: function (baz) { - }, + set: function (baz) { }, enumerable: true, configurable: true }); @@ -97,12 +87,8 @@ var C6 = (function () { function C6() { } Object.defineProperty(C6.prototype, "getset1", { - get: function () { - var x; - return x; - }, - set: function (baz) { - }, + get: function () { var x; return x; }, + set: function (baz) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/interfaceImplementation6.js b/tests/baselines/reference/interfaceImplementation6.js index c9bd9113e7..4feb6804db 100644 --- a/tests/baselines/reference/interfaceImplementation6.js +++ b/tests/baselines/reference/interfaceImplementation6.js @@ -44,9 +44,7 @@ define(["require", "exports"], function (require, exports) { })(); var Test = (function () { function Test() { - this.pt = { - item: 1 - }; + this.pt = { item: 1 }; } return Test; })(); diff --git a/tests/baselines/reference/interfaceImplementation7.js b/tests/baselines/reference/interfaceImplementation7.js index 6345fe93a3..2813d7ee0f 100644 --- a/tests/baselines/reference/interfaceImplementation7.js +++ b/tests/baselines/reference/interfaceImplementation7.js @@ -14,8 +14,6 @@ class C1 implements i4 { var C1 = (function () { function C1() { } - C1.prototype.name = function () { - return ""; - }; + C1.prototype.name = function () { return ""; }; return C1; })(); diff --git a/tests/baselines/reference/interfaceNaming1.js b/tests/baselines/reference/interfaceNaming1.js index e16f186379..2abd2106b2 100644 --- a/tests/baselines/reference/interfaceNaming1.js +++ b/tests/baselines/reference/interfaceNaming1.js @@ -6,6 +6,5 @@ interface & { } //// [interfaceNaming1.js] interface; -{ -} +{ } interface & {}; diff --git a/tests/baselines/reference/interfaceSubtyping.js b/tests/baselines/reference/interfaceSubtyping.js index 840ce79d86..4300498578 100644 --- a/tests/baselines/reference/interfaceSubtyping.js +++ b/tests/baselines/reference/interfaceSubtyping.js @@ -14,8 +14,6 @@ var Camera = (function () { function Camera(str) { this.str = str; } - Camera.prototype.foo = function () { - return "s"; - }; + Camera.prototype.foo = function () { return "s"; }; return Camera; })(); diff --git a/tests/baselines/reference/interfaceWithPropertyOfEveryType.js b/tests/baselines/reference/interfaceWithPropertyOfEveryType.js index e10b83297b..90c0d257d6 100644 --- a/tests/baselines/reference/interfaceWithPropertyOfEveryType.js +++ b/tests/baselines/reference/interfaceWithPropertyOfEveryType.js @@ -48,8 +48,7 @@ var C = (function () { } return C; })(); -function f1() { -} +function f1() { } var M; (function (M) { M.y = 1; @@ -64,16 +63,10 @@ var a = { c: true, d: {}, e: null, - f: [ - 1 - ], + f: [1], g: {}, - h: function (x) { - return 1; - }, - i: function (x) { - return x; - }, + h: function (x) { return 1; }, + i: function (x) { return x; }, j: null, k: new C(), l: f1, diff --git a/tests/baselines/reference/interfaceWithPropertyThatIsPrivateInBaseType2.js b/tests/baselines/reference/interfaceWithPropertyThatIsPrivateInBaseType2.js index 01907f410e..d53ec04c18 100644 --- a/tests/baselines/reference/interfaceWithPropertyThatIsPrivateInBaseType2.js +++ b/tests/baselines/reference/interfaceWithPropertyThatIsPrivateInBaseType2.js @@ -19,14 +19,12 @@ interface Foo2 extends Base2 { // error var Base = (function () { function Base() { } - Base.prototype.x = function () { - }; + Base.prototype.x = function () { }; return Base; })(); var Base2 = (function () { function Base2() { } - Base2.prototype.x = function () { - }; + Base2.prototype.x = function () { }; return Base2; })(); diff --git a/tests/baselines/reference/invalidDoWhileBreakStatements.js b/tests/baselines/reference/invalidDoWhileBreakStatements.js index e6617ef98c..807d58a8fe 100644 --- a/tests/baselines/reference/invalidDoWhileBreakStatements.js +++ b/tests/baselines/reference/invalidDoWhileBreakStatements.js @@ -60,8 +60,7 @@ THREE: do { // break forward do { break FIVE; - FIVE: do { - } while (true); + FIVE: do { } while (true); } while (true); // label on non-loop statement NINE: var y = 12; diff --git a/tests/baselines/reference/invalidDoWhileContinueStatements.js b/tests/baselines/reference/invalidDoWhileContinueStatements.js index d32ccfe007..21a10a3451 100644 --- a/tests/baselines/reference/invalidDoWhileContinueStatements.js +++ b/tests/baselines/reference/invalidDoWhileContinueStatements.js @@ -60,8 +60,7 @@ THREE: do { // continue forward do { continue FIVE; - FIVE: do { - } while (true); + FIVE: do { } while (true); } while (true); // label on non-loop statement NINE: var y = 12; diff --git a/tests/baselines/reference/invalidForBreakStatements.js b/tests/baselines/reference/invalidForBreakStatements.js index abcd078ff2..5e3430ecb4 100644 --- a/tests/baselines/reference/invalidForBreakStatements.js +++ b/tests/baselines/reference/invalidForBreakStatements.js @@ -58,8 +58,7 @@ THREE: for (;;) { // break forward for (;;) { break FIVE; - FIVE: for (;;) { - } + FIVE: for (;;) { } } // label on non-loop statement NINE: var y = 12; diff --git a/tests/baselines/reference/invalidForContinueStatements.js b/tests/baselines/reference/invalidForContinueStatements.js index af0eba2a59..2db1ce69ed 100644 --- a/tests/baselines/reference/invalidForContinueStatements.js +++ b/tests/baselines/reference/invalidForContinueStatements.js @@ -58,8 +58,7 @@ THREE: for (;;) { // continue forward for (;;) { continue FIVE; - FIVE: for (;;) { - } + FIVE: for (;;) { } } // label on non-loop statement NINE: var y = 12; diff --git a/tests/baselines/reference/invalidForInBreakStatements.js b/tests/baselines/reference/invalidForInBreakStatements.js index bf383613c3..1784b9a57a 100644 --- a/tests/baselines/reference/invalidForInBreakStatements.js +++ b/tests/baselines/reference/invalidForInBreakStatements.js @@ -59,8 +59,7 @@ THREE: for (var x in {}) { // break forward for (var x in {}) { break FIVE; - FIVE: for (var x in {}) { - } + FIVE: for (var x in {}) { } } // label on non-loop statement NINE: var y = 12; diff --git a/tests/baselines/reference/invalidForInContinueStatements.js b/tests/baselines/reference/invalidForInContinueStatements.js index d40dbd80ca..94020d00f2 100644 --- a/tests/baselines/reference/invalidForInContinueStatements.js +++ b/tests/baselines/reference/invalidForInContinueStatements.js @@ -59,8 +59,7 @@ THREE: for (var x in {}) { // continue forward for (var x in {}) { continue FIVE; - FIVE: for (var x in {}) { - } + FIVE: for (var x in {}) { } } // label on non-loop statement NINE: var y = 12; diff --git a/tests/baselines/reference/invalidModuleWithVarStatements.js b/tests/baselines/reference/invalidModuleWithVarStatements.js index 4014709d36..caa6b24f00 100644 --- a/tests/baselines/reference/invalidModuleWithVarStatements.js +++ b/tests/baselines/reference/invalidModuleWithVarStatements.js @@ -35,8 +35,7 @@ var Y; })(Y || (Y = {})); var Y2; (function (Y2) { - function fn(x) { - } + function fn(x) { } })(Y2 || (Y2 = {})); var Y4; (function (Y4) { @@ -44,8 +43,7 @@ var Y4; })(Y4 || (Y4 = {})); var YY; (function (YY) { - function fn(x) { - } + function fn(x) { } })(YY || (YY = {})); var YY2; (function (YY2) { @@ -53,6 +51,5 @@ var YY2; })(YY2 || (YY2 = {})); var YY3; (function (YY3) { - function fn(x) { - } + function fn(x) { } })(YY3 || (YY3 = {})); diff --git a/tests/baselines/reference/invalidMultipleVariableDeclarations.js b/tests/baselines/reference/invalidMultipleVariableDeclarations.js index 62ea392be2..824bee9222 100644 --- a/tests/baselines/reference/invalidMultipleVariableDeclarations.js +++ b/tests/baselines/reference/invalidMultipleVariableDeclarations.js @@ -77,9 +77,7 @@ var D = (function () { } return D; })(); -function F(x) { - return 42; -} +function F(x) { return 42; } var M; (function (M) { var A = (function () { @@ -88,9 +86,7 @@ var M; return A; })(); M.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } M.F2 = F2; })(M || (M = {})); // all of these are errors @@ -104,24 +100,11 @@ var b; var b = new C(); var b = new C2(); var f = F; -var f = function (x) { - return ''; -}; +var f = function (x) { return ''; }; var arr; -var arr = [ - 1, - 2, - 3, - 4 -]; -var arr = [ - new C(), - new C2(), - new D() -]; -var arr2 = [ - new D() -]; +var arr = [1, 2, 3, 4]; +var arr = [new C(), new C2(), new D()]; +var arr2 = [new D()]; var arr2 = new Array(); var m; var m = M.A; diff --git a/tests/baselines/reference/invalidReturnStatements.js b/tests/baselines/reference/invalidReturnStatements.js index df6f6da675..d637158780 100644 --- a/tests/baselines/reference/invalidReturnStatements.js +++ b/tests/baselines/reference/invalidReturnStatements.js @@ -28,21 +28,15 @@ var __extends = this.__extends || function (d, b) { d.prototype = new __(); }; // all the following should be error -function fn1() { -} -function fn2() { -} -function fn3() { -} -function fn4() { -} -function fn7() { -} // should be valid: any includes void +function fn1() { } +function fn2() { } +function fn3() { } +function fn4() { } +function fn7() { } // should be valid: any includes void var C = (function () { function C() { } - C.prototype.dispose = function () { - }; + C.prototype.dispose = function () { }; return C; })(); var D = (function (_super) { @@ -52,11 +46,5 @@ var D = (function (_super) { } return D; })(C); -function fn10() { - return { - id: 12 - }; -} -function fn11() { - return new C(); -} +function fn10() { return { id: 12 }; } +function fn11() { return new C(); } diff --git a/tests/baselines/reference/invalidStaticField.js b/tests/baselines/reference/invalidStaticField.js index 5521af05c8..620c019fc1 100644 --- a/tests/baselines/reference/invalidStaticField.js +++ b/tests/baselines/reference/invalidStaticField.js @@ -6,9 +6,7 @@ class B { static NOT_NULL = new B(); } var A = (function () { function A() { } - A.prototype.foo = function () { - return B.NULL; - }; + A.prototype.foo = function () { return B.NULL; }; return A; })(); var B = (function () { diff --git a/tests/baselines/reference/invalidTryStatements.js b/tests/baselines/reference/invalidTryStatements.js index 8afadf41b4..343ad6e058 100644 --- a/tests/baselines/reference/invalidTryStatements.js +++ b/tests/baselines/reference/invalidTryStatements.js @@ -21,16 +21,10 @@ function fn() { var x; // ensure x is 'Any' } // no type annotation allowed - try { - } - catch (z) { - } - try { - } - catch (a) { - } - try { - } - catch (y) { - } + try { } + catch (z) { } + try { } + catch (a) { } + try { } + catch (y) { } } diff --git a/tests/baselines/reference/invalidTryStatements2.js b/tests/baselines/reference/invalidTryStatements2.js index d2ef92ac83..1b2976dc4e 100644 --- a/tests/baselines/reference/invalidTryStatements2.js +++ b/tests/baselines/reference/invalidTryStatements2.js @@ -36,20 +36,16 @@ function fn() { } try { } - catch (x) { - } // error missing try - finally { - } // potential error; can be absorbed by the 'catch' + catch (x) { } // error missing try + finally { } // potential error; can be absorbed by the 'catch' } function fn2() { try { } - finally { - } // error missing try + finally { } // error missing try try { } // error missing try - catch (x) { - } // error missing try + catch (x) { } // error missing try // no error try { } diff --git a/tests/baselines/reference/invalidTypeOfTarget.js b/tests/baselines/reference/invalidTypeOfTarget.js index 88128d15e8..52b39f3c76 100644 --- a/tests/baselines/reference/invalidTypeOfTarget.js +++ b/tests/baselines/reference/invalidTypeOfTarget.js @@ -15,6 +15,5 @@ var x3 = 1; var x4 = ''; var x5; var x6 = null; -var x7 = function f() { -}; +var x7 = function f() { }; var x8 = /123/; diff --git a/tests/baselines/reference/invalidUndefinedAssignments.js b/tests/baselines/reference/invalidUndefinedAssignments.js index 7617e5eae8..dc846900eb 100644 --- a/tests/baselines/reference/invalidUndefinedAssignments.js +++ b/tests/baselines/reference/invalidUndefinedAssignments.js @@ -44,7 +44,6 @@ var M; M.x = 1; })(M || (M = {})); M = x; -function i(a) { -} +function i(a) { } // BUG 767030 i = x; diff --git a/tests/baselines/reference/invalidUndefinedValues.js b/tests/baselines/reference/invalidUndefinedValues.js index 9361f43bba..a0ed1b4f98 100644 --- a/tests/baselines/reference/invalidUndefinedValues.js +++ b/tests/baselines/reference/invalidUndefinedValues.js @@ -54,10 +54,7 @@ var M; M.x = 1; })(M || (M = {})); x = M; -x = { - f: function () { - } -}; +x = { f: function () { } }; function f(a) { x = a; } diff --git a/tests/baselines/reference/invalidVoidAssignments.js b/tests/baselines/reference/invalidVoidAssignments.js index b821b0ca79..1ce03d1382 100644 --- a/tests/baselines/reference/invalidVoidAssignments.js +++ b/tests/baselines/reference/invalidVoidAssignments.js @@ -59,7 +59,4 @@ var E; })(E || (E = {})); x = E; x = E.A; -x = { - f: function () { - } -}; +x = { f: function () { } }; diff --git a/tests/baselines/reference/invalidVoidValues.js b/tests/baselines/reference/invalidVoidValues.js index 13f2d681f2..409df03ef3 100644 --- a/tests/baselines/reference/invalidVoidValues.js +++ b/tests/baselines/reference/invalidVoidValues.js @@ -46,10 +46,7 @@ var a; x = a; var b; x = b; -x = { - f: function () { - } -}; +x = { f: function () { } }; var M; (function (M) { M.x = 1; diff --git a/tests/baselines/reference/invalidWhileBreakStatements.js b/tests/baselines/reference/invalidWhileBreakStatements.js index a8e261f036..7f10a08d65 100644 --- a/tests/baselines/reference/invalidWhileBreakStatements.js +++ b/tests/baselines/reference/invalidWhileBreakStatements.js @@ -59,8 +59,7 @@ THREE: while (true) { // break forward while (true) { break FIVE; - FIVE: while (true) { - } + FIVE: while (true) { } } // label on non-loop statement NINE: var y = 12; diff --git a/tests/baselines/reference/invalidWhileContinueStatements.js b/tests/baselines/reference/invalidWhileContinueStatements.js index 544314bf68..b8234bf960 100644 --- a/tests/baselines/reference/invalidWhileContinueStatements.js +++ b/tests/baselines/reference/invalidWhileContinueStatements.js @@ -59,8 +59,7 @@ THREE: while (true) { // continue forward while (true) { continue FIVE; - FIVE: while (true) { - } + FIVE: while (true) { } } // label on non-loop statement NINE: var y = 12; diff --git a/tests/baselines/reference/ipromise4.js b/tests/baselines/reference/ipromise4.js index 5b65e0818c..98660aa582 100644 --- a/tests/baselines/reference/ipromise4.js +++ b/tests/baselines/reference/ipromise4.js @@ -18,10 +18,5 @@ p.then(function (x) { return "hello"; } ).then(function (x) { return x } ); // s //// [ipromise4.js] var p = null; -p.then(function (x) { -}); // should not error -p.then(function (x) { - return "hello"; -}).then(function (x) { - return x; -}); // should not error +p.then(function (x) { }); // should not error +p.then(function (x) { return "hello"; }).then(function (x) { return x; }); // should not error diff --git a/tests/baselines/reference/iterableContextualTyping1.js b/tests/baselines/reference/iterableContextualTyping1.js index 12943b4689..8621bbd841 100644 --- a/tests/baselines/reference/iterableContextualTyping1.js +++ b/tests/baselines/reference/iterableContextualTyping1.js @@ -2,6 +2,4 @@ var iter: Iterable<(x: string) => number> = [s => s.length]; //// [iterableContextualTyping1.js] -var iter = [ - s => s.length -]; +var iter = [s => s.length]; diff --git a/tests/baselines/reference/keywordField.js b/tests/baselines/reference/keywordField.js index b6b54de206..581d5afa14 100644 --- a/tests/baselines/reference/keywordField.js +++ b/tests/baselines/reference/keywordField.js @@ -13,8 +13,6 @@ var q = a["if"]; //// [keywordField.js] var obj = {}; obj.if = 1; -var a = { - if: "test" -}; +var a = { if: "test" }; var n = a.if; var q = a["if"]; diff --git a/tests/baselines/reference/lambdaExpression.js b/tests/baselines/reference/lambdaExpression.js index ece70d217f..dc5c94c8b3 100644 --- a/tests/baselines/reference/lambdaExpression.js +++ b/tests/baselines/reference/lambdaExpression.js @@ -6,11 +6,7 @@ var x = 0; //// [lambdaExpression.js] -(function () { - return 0; -}); // Needs to be wrapped in parens to be a valid expression (not declaration) +(function () { return 0; }); // Needs to be wrapped in parens to be a valid expression (not declaration) var y = 0; -(function () { - return 0; -}); +(function () { return 0; }); var x = 0; diff --git a/tests/baselines/reference/lambdaParamTypes.js b/tests/baselines/reference/lambdaParamTypes.js index bc2858e9b4..3bd212512e 100644 --- a/tests/baselines/reference/lambdaParamTypes.js +++ b/tests/baselines/reference/lambdaParamTypes.js @@ -24,45 +24,16 @@ thing.doSomething((x, y) => y.name.toExponential(0)); //// [lambdaParamTypes.js] -var thing = create([ - { - name: "bob", - id: 24 - }, - { - name: "doug", - id: 32 - } -]); +var thing = create([{ name: "bob", id: 24 }, { name: "doug", id: 32 }]); // Below should all be OK -thing.doSomething(function (x, y) { - return x.name.charAt(0); -}); // x.name should be string, so should be OK -thing.doSomething(function (x, y) { - return x.id.toExponential(0); -}); // x.id should be string, so should be OK -thing.doSomething(function (x, y) { - return y.name.charAt(0); -}); // x.name should be string, so should be OK -thing.doSomething(function (x, y) { - return y.id.toExponential(0); -}); // x.id should be string, so should be OK +thing.doSomething(function (x, y) { return x.name.charAt(0); }); // x.name should be string, so should be OK +thing.doSomething(function (x, y) { return x.id.toExponential(0); }); // x.id should be string, so should be OK +thing.doSomething(function (x, y) { return y.name.charAt(0); }); // x.name should be string, so should be OK +thing.doSomething(function (x, y) { return y.id.toExponential(0); }); // x.id should be string, so should be OK // Below should all be in error -thing.doSomething(function (x, y) { - return x.foo; -}); // no such property on x -thing.doSomething(function (x, y) { - return y.foo; -}); // no such property on y -thing.doSomething(function (x, y) { - return x.id.charAt(0); -}); // x.id should be number, no charAt member -thing.doSomething(function (x, y) { - return x.name.toExponential(0); -}); // x.name should be string, no toExponential member -thing.doSomething(function (x, y) { - return y.id.charAt(0); -}); -thing.doSomething(function (x, y) { - return y.name.toExponential(0); -}); +thing.doSomething(function (x, y) { return x.foo; }); // no such property on x +thing.doSomething(function (x, y) { return y.foo; }); // no such property on y +thing.doSomething(function (x, y) { return x.id.charAt(0); }); // x.id should be number, no charAt member +thing.doSomething(function (x, y) { return x.name.toExponential(0); }); // x.name should be string, no toExponential member +thing.doSomething(function (x, y) { return y.id.charAt(0); }); +thing.doSomething(function (x, y) { return y.name.toExponential(0); }); diff --git a/tests/baselines/reference/lambdaPropSelf.js b/tests/baselines/reference/lambdaPropSelf.js index 5211dcc47c..8d1b16e143 100644 --- a/tests/baselines/reference/lambdaPropSelf.js +++ b/tests/baselines/reference/lambdaPropSelf.js @@ -28,9 +28,7 @@ var Person = (function () { function Person(name, children) { var _this = this; this.name = name; - this.addChild = function () { - return _this.children.push("New child"); - }; + this.addChild = function () { return _this.children.push("New child"); }; this.children = ko.observableArray(children); } return Person; diff --git a/tests/baselines/reference/lastPropertyInLiteralWins.js b/tests/baselines/reference/lastPropertyInLiteralWins.js index 19ec4e2100..999fe45841 100644 --- a/tests/baselines/reference/lastPropertyInLiteralWins.js +++ b/tests/baselines/reference/lastPropertyInLiteralWins.js @@ -21,14 +21,10 @@ function test(thing) { thing.thunk("str"); } test({ - thunk: function (str) { - }, - thunk: function (num) { - } + thunk: function (str) { }, + thunk: function (num) { } }); test({ - thunk: function (num) { - }, - thunk: function (str) { - } + thunk: function (num) { }, + thunk: function (str) { } }); diff --git a/tests/baselines/reference/letAndVarRedeclaration.js b/tests/baselines/reference/letAndVarRedeclaration.js index 35222660b6..fd4bfe67ca 100644 --- a/tests/baselines/reference/letAndVarRedeclaration.js +++ b/tests/baselines/reference/letAndVarRedeclaration.js @@ -55,13 +55,11 @@ module M2 { //// [letAndVarRedeclaration.js] let e0; var e0; -function e0() { -} +function e0() { } function f0() { let x1; var x1; - function x1() { - } + function x1() { } } function f1() { let x; @@ -69,16 +67,14 @@ function f1() { var x; } { - function x() { - } + function x() { } } } var M0; (function (M0) { let x2; var x2; - function x2() { - } + function x2() { } })(M0 || (M0 = {})); var M1; (function (M1) { @@ -87,8 +83,7 @@ var M1; var x2; } { - function x2() { - } + function x2() { } } })(M1 || (M1 = {})); let x11; diff --git a/tests/baselines/reference/letDeclarations-access.js b/tests/baselines/reference/letDeclarations-access.js index 404c287631..6ae289d220 100644 --- a/tests/baselines/reference/letDeclarations-access.js +++ b/tests/baselines/reference/letDeclarations-access.js @@ -58,11 +58,9 @@ x--; ++x; --x; var a = x + 1; -function f(v) { -} +function f(v) { } f(x); -if (x) { -} +if (x) { } x; (x); -x; diff --git a/tests/baselines/reference/letDeclarations-es5.js b/tests/baselines/reference/letDeclarations-es5.js index 1d4eb4afcb..d8761ccbc6 100644 --- a/tests/baselines/reference/letDeclarations-es5.js +++ b/tests/baselines/reference/letDeclarations-es5.js @@ -20,7 +20,5 @@ var l3, l4, l5, l6; var l7 = false; var l8 = 23; var l9 = 0, l10 = "", l11 = null; -for (var l11_1 in {}) { -} -for (var l12 = 0; l12 < 9; l12++) { -} +for (var l11_1 in {}) { } +for (var l12 = 0; l12 < 9; l12++) { } diff --git a/tests/baselines/reference/letDeclarations.js b/tests/baselines/reference/letDeclarations.js index bc186b732f..8acb82204e 100644 --- a/tests/baselines/reference/letDeclarations.js +++ b/tests/baselines/reference/letDeclarations.js @@ -20,10 +20,8 @@ let l3, l4, l5, l6; let l7 = false; let l8 = 23; let l9 = 0, l10 = "", l11 = null; -for (let l11 in {}) { -} -for (let l12 = 0; l12 < 9; l12++) { -} +for (let l11 in {}) { } +for (let l12 = 0; l12 < 9; l12++) { } //// [letDeclarations.d.ts] diff --git a/tests/baselines/reference/letInLetOrConstDeclarations.js b/tests/baselines/reference/letInLetOrConstDeclarations.js index 6560ea8491..ee23abc4e4 100644 --- a/tests/baselines/reference/letInLetOrConstDeclarations.js +++ b/tests/baselines/reference/letInLetOrConstDeclarations.js @@ -14,8 +14,7 @@ //// [letInLetOrConstDeclarations.js] { let let = 1; // should error - for (let let in []) { - } // should error + for (let let in []) { } // should error } { const let = 1; // should error diff --git a/tests/baselines/reference/letInNonStrictMode.js b/tests/baselines/reference/letInNonStrictMode.js index af21ce3281..8a431535ae 100644 --- a/tests/baselines/reference/letInNonStrictMode.js +++ b/tests/baselines/reference/letInNonStrictMode.js @@ -3,9 +3,5 @@ let [x] = [1]; let {a: y} = {a: 1}; //// [letInNonStrictMode.js] -var x = ([ - 1 -])[0]; -var y = ({ - a: 1 -}).a; +var x = ([1])[0]; +var y = ({ a: 1 }).a; diff --git a/tests/baselines/reference/lift.js b/tests/baselines/reference/lift.js index 21c09aaeb5..33f8200530 100644 --- a/tests/baselines/reference/lift.js +++ b/tests/baselines/reference/lift.js @@ -37,11 +37,7 @@ var C = (function (_super) { var x = 10 + w; var ll = x * w; } - C.prototype.liftxyz = function () { - return x + z + this.y; - }; - C.prototype.liftxylocllz = function () { - return x + z + this.y + this.ll; - }; + C.prototype.liftxyz = function () { return x + z + this.y; }; + C.prototype.liftxylocllz = function () { return x + z + this.y + this.ll; }; return C; })(B); diff --git a/tests/baselines/reference/literals-negative.js b/tests/baselines/reference/literals-negative.js index c0c9624e6f..39fd4ea38a 100644 --- a/tests/baselines/reference/literals-negative.js +++ b/tests/baselines/reference/literals-negative.js @@ -17,8 +17,6 @@ if(null === isVoid()) { } var n = (null); var s = (null); var b = (n); -function isVoid() { -} +function isVoid() { } // Expected error: Values of type null and void cannot be compared -if (null === isVoid()) { -} +if (null === isVoid()) { } diff --git a/tests/baselines/reference/localImportNameVsGlobalName.js b/tests/baselines/reference/localImportNameVsGlobalName.js index 8ba7ec567a..45ecdc4745 100644 --- a/tests/baselines/reference/localImportNameVsGlobalName.js +++ b/tests/baselines/reference/localImportNameVsGlobalName.js @@ -27,8 +27,7 @@ var Keyboard; var App; (function (App) { var Key = Keyboard.Key; - function foo(key) { - } + function foo(key) { } App.foo = foo; foo(Key.UP); foo(Key.DOWN); diff --git a/tests/baselines/reference/logicalNotOperatorWithAnyOtherType.js b/tests/baselines/reference/logicalNotOperatorWithAnyOtherType.js index 891faacd4a..2836673923 100644 --- a/tests/baselines/reference/logicalNotOperatorWithAnyOtherType.js +++ b/tests/baselines/reference/logicalNotOperatorWithAnyOtherType.js @@ -63,16 +63,9 @@ var ResultIsBoolean21 = !!!(ANY + ANY1); // ! operator on any type var ANY; var ANY1; -var ANY2 = [ - "", - "" -]; +var ANY2 = ["", ""]; var obj; -var obj1 = { - x: "", - y: function () { - } -}; +var obj1 = { x: "", y: function () { } }; function foo() { var a; return a; diff --git a/tests/baselines/reference/logicalNotOperatorWithBooleanType.js b/tests/baselines/reference/logicalNotOperatorWithBooleanType.js index 6f16fbfa2e..107bd9a88e 100644 --- a/tests/baselines/reference/logicalNotOperatorWithBooleanType.js +++ b/tests/baselines/reference/logicalNotOperatorWithBooleanType.js @@ -41,15 +41,11 @@ var ResultIsBoolean = !!BOOLEAN; //// [logicalNotOperatorWithBooleanType.js] // ! operator on boolean type var BOOLEAN; -function foo() { - return true; -} +function foo() { return true; } var A = (function () { function A() { } - A.foo = function () { - return false; - }; + A.foo = function () { return false; }; return A; })(); var M; @@ -61,10 +57,7 @@ var objA = new A(); var ResultIsBoolean1 = !BOOLEAN; // boolean type literal var ResultIsBoolean2 = !true; -var ResultIsBoolean3 = !{ - x: true, - y: false -}; +var ResultIsBoolean3 = !{ x: true, y: false }; // boolean type expressions var ResultIsBoolean4 = !objA.a; var ResultIsBoolean5 = !M.n; diff --git a/tests/baselines/reference/logicalNotOperatorWithNumberType.js b/tests/baselines/reference/logicalNotOperatorWithNumberType.js index 7beba45ba0..0d0601cad2 100644 --- a/tests/baselines/reference/logicalNotOperatorWithNumberType.js +++ b/tests/baselines/reference/logicalNotOperatorWithNumberType.js @@ -48,19 +48,12 @@ var ResultIsBoolean13 = !!!(NUMBER + NUMBER); //// [logicalNotOperatorWithNumberType.js] // ! operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; -function foo() { - return 1; -} +var NUMBER1 = [1, 2]; +function foo() { return 1; } var A = (function () { function A() { } - A.foo = function () { - return 1; - }; + A.foo = function () { return 1; }; return A; })(); var M; @@ -73,16 +66,8 @@ var ResultIsBoolean1 = !NUMBER; var ResultIsBoolean2 = !NUMBER1; // number type literal var ResultIsBoolean3 = !1; -var ResultIsBoolean4 = !{ - x: 1, - y: 2 -}; -var ResultIsBoolean5 = !{ - x: 1, - y: function (n) { - return n; - } -}; +var ResultIsBoolean4 = !{ x: 1, y: 2 }; +var ResultIsBoolean5 = !{ x: 1, y: function (n) { return n; } }; // number type expressions var ResultIsBoolean6 = !objA.a; var ResultIsBoolean7 = !M.n; diff --git a/tests/baselines/reference/logicalNotOperatorWithStringType.js b/tests/baselines/reference/logicalNotOperatorWithStringType.js index 571857cb6b..7f75814d60 100644 --- a/tests/baselines/reference/logicalNotOperatorWithStringType.js +++ b/tests/baselines/reference/logicalNotOperatorWithStringType.js @@ -47,19 +47,12 @@ var ResultIsBoolean14 = !!!(STRING + STRING); //// [logicalNotOperatorWithStringType.js] // ! operator on string type var STRING; -var STRING1 = [ - "", - "abc" -]; -function foo() { - return "abc"; -} +var STRING1 = ["", "abc"]; +function foo() { return "abc"; } var A = (function () { function A() { } - A.foo = function () { - return ""; - }; + A.foo = function () { return ""; }; return A; })(); var M; @@ -72,16 +65,8 @@ var ResultIsBoolean1 = !STRING; var ResultIsBoolean2 = !STRING1; // string type literal var ResultIsBoolean3 = !""; -var ResultIsBoolean4 = !{ - x: "", - y: "" -}; -var ResultIsBoolean5 = !{ - x: "", - y: function (s) { - return s; - } -}; +var ResultIsBoolean4 = !{ x: "", y: "" }; +var ResultIsBoolean5 = !{ x: "", y: function (s) { return s; } }; // string type expressions var ResultIsBoolean6 = !objA.a; var ResultIsBoolean7 = !M.n; diff --git a/tests/baselines/reference/logicalOrExpressionIsContextuallyTyped.js b/tests/baselines/reference/logicalOrExpressionIsContextuallyTyped.js index 12e55119c3..64bdc87157 100644 --- a/tests/baselines/reference/logicalOrExpressionIsContextuallyTyped.js +++ b/tests/baselines/reference/logicalOrExpressionIsContextuallyTyped.js @@ -11,10 +11,4 @@ var r: { a: string } = { a: '', b: 123 } || { a: '', b: true }; // If the || expression is contextually typed, the operands are contextually typed by the // same type and the result is of the best common type of the contextual type and the two // operand types. -var r = { - a: '', - b: 123 -} || { - a: '', - b: true -}; +var r = { a: '', b: 123 } || { a: '', b: true }; diff --git a/tests/baselines/reference/logicalOrExpressionIsNotContextuallyTyped.js b/tests/baselines/reference/logicalOrExpressionIsNotContextuallyTyped.js index 0731cb620a..73e1c33a4e 100644 --- a/tests/baselines/reference/logicalOrExpressionIsNotContextuallyTyped.js +++ b/tests/baselines/reference/logicalOrExpressionIsNotContextuallyTyped.js @@ -17,6 +17,4 @@ var r = a || ((a) => a.toLowerCase()); // operand types. var a; // bug 786110 -var r = a || (function (a) { - return a.toLowerCase(); -}); +var r = a || (function (a) { return a.toLowerCase(); }); diff --git a/tests/baselines/reference/logicalOrOperatorWithTypeParameters.js b/tests/baselines/reference/logicalOrOperatorWithTypeParameters.js index b73a314406..e0fca87efa 100644 --- a/tests/baselines/reference/logicalOrOperatorWithTypeParameters.js +++ b/tests/baselines/reference/logicalOrOperatorWithTypeParameters.js @@ -42,8 +42,6 @@ function fn2(t, u, v) { function fn3(t, u) { var r1 = t || u; var r2 = t || u; - var r3 = t || { - a: '' - }; + var r3 = t || { a: '' }; var r4 = t || u; } diff --git a/tests/baselines/reference/matchingOfObjectLiteralConstraints.js b/tests/baselines/reference/matchingOfObjectLiteralConstraints.js index 13d9e0e05e..1d19359894 100644 --- a/tests/baselines/reference/matchingOfObjectLiteralConstraints.js +++ b/tests/baselines/reference/matchingOfObjectLiteralConstraints.js @@ -5,8 +5,5 @@ foo2({ y: "foo" }, "foo"); //// [matchingOfObjectLiteralConstraints.js] -function foo2(x, z) { -} -foo2({ - y: "foo" -}, "foo"); +function foo2(x, z) { } +foo2({ y: "foo" }, "foo"); diff --git a/tests/baselines/reference/maxConstraints.js b/tests/baselines/reference/maxConstraints.js index 4ea37d3050..b2098ccaf2 100644 --- a/tests/baselines/reference/maxConstraints.js +++ b/tests/baselines/reference/maxConstraints.js @@ -9,7 +9,5 @@ var max2: Comparer = (x, y) => { return (x.compareTo(y) > 0) ? x : y }; var maxResult = max2(1, 2); //// [maxConstraints.js] -var max2 = function (x, y) { - return (x.compareTo(y) > 0) ? x : y; -}; +var max2 = function (x, y) { return (x.compareTo(y) > 0) ? x : y; }; var maxResult = max2(1, 2); diff --git a/tests/baselines/reference/memberFunctionsWithPrivateOverloads.js b/tests/baselines/reference/memberFunctionsWithPrivateOverloads.js index dc347e9558..584bafad6f 100644 --- a/tests/baselines/reference/memberFunctionsWithPrivateOverloads.js +++ b/tests/baselines/reference/memberFunctionsWithPrivateOverloads.js @@ -53,27 +53,19 @@ var r4 = D.bar(''); // error var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - }; - C.prototype.bar = function (x, y) { - }; - C.foo = function (x, y) { - }; - C.bar = function (x, y) { - }; + C.prototype.foo = function (x, y) { }; + C.prototype.bar = function (x, y) { }; + C.foo = function (x, y) { }; + C.bar = function (x, y) { }; return C; })(); var D = (function () { function D() { } - D.prototype.foo = function (x, y) { - }; - D.prototype.bar = function (x, y) { - }; - D.foo = function (x, y) { - }; - D.bar = function (x, y) { - }; + D.prototype.foo = function (x, y) { }; + D.prototype.bar = function (x, y) { }; + D.foo = function (x, y) { }; + D.bar = function (x, y) { }; return D; })(); var c; diff --git a/tests/baselines/reference/memberFunctionsWithPublicOverloads.js b/tests/baselines/reference/memberFunctionsWithPublicOverloads.js index 5eaf894f54..efdd6efaff 100644 --- a/tests/baselines/reference/memberFunctionsWithPublicOverloads.js +++ b/tests/baselines/reference/memberFunctionsWithPublicOverloads.js @@ -44,26 +44,18 @@ class D { var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - }; - C.prototype.bar = function (x, y) { - }; - C.foo = function (x, y) { - }; - C.bar = function (x, y) { - }; + C.prototype.foo = function (x, y) { }; + C.prototype.bar = function (x, y) { }; + C.foo = function (x, y) { }; + C.bar = function (x, y) { }; return C; })(); var D = (function () { function D() { } - D.prototype.foo = function (x, y) { - }; - D.prototype.bar = function (x, y) { - }; - D.foo = function (x, y) { - }; - D.bar = function (x, y) { - }; + D.prototype.foo = function (x, y) { }; + D.prototype.bar = function (x, y) { }; + D.foo = function (x, y) { }; + D.bar = function (x, y) { }; return D; })(); diff --git a/tests/baselines/reference/memberFunctionsWithPublicPrivateOverloads.js b/tests/baselines/reference/memberFunctionsWithPublicPrivateOverloads.js index 2726756c80..7738bf4fe4 100644 --- a/tests/baselines/reference/memberFunctionsWithPublicPrivateOverloads.js +++ b/tests/baselines/reference/memberFunctionsWithPublicPrivateOverloads.js @@ -66,35 +66,23 @@ var r2 = d.foo(2); // error var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - }; - C.prototype.bar = function (x, y) { - }; - C.foo = function (x, y) { - }; - C.prototype.baz = function (x, y) { - }; - C.bar = function (x, y) { - }; - C.baz = function (x, y) { - }; + C.prototype.foo = function (x, y) { }; + C.prototype.bar = function (x, y) { }; + C.foo = function (x, y) { }; + C.prototype.baz = function (x, y) { }; + C.bar = function (x, y) { }; + C.baz = function (x, y) { }; return C; })(); var D = (function () { function D() { } - D.prototype.foo = function (x, y) { - }; - D.prototype.bar = function (x, y) { - }; - D.prototype.baz = function (x, y) { - }; - D.foo = function (x, y) { - }; - D.bar = function (x, y) { - }; - D.baz = function (x, y) { - }; + D.prototype.foo = function (x, y) { }; + D.prototype.bar = function (x, y) { }; + D.prototype.baz = function (x, y) { }; + D.foo = function (x, y) { }; + D.bar = function (x, y) { }; + D.baz = function (x, y) { }; return D; })(); var c; diff --git a/tests/baselines/reference/mergedDeclarations1.js b/tests/baselines/reference/mergedDeclarations1.js index 9dc432f94a..641ff031de 100644 --- a/tests/baselines/reference/mergedDeclarations1.js +++ b/tests/baselines/reference/mergedDeclarations1.js @@ -18,10 +18,7 @@ var b = point.equals(p1, p2); //// [mergedDeclarations1.js] function point(x, y) { - return { - x: x, - y: y - }; + return { x: x, y: y }; } var point; (function (point) { diff --git a/tests/baselines/reference/mergedDeclarations4.js b/tests/baselines/reference/mergedDeclarations4.js index a3dab29ff7..64fad6bd59 100644 --- a/tests/baselines/reference/mergedDeclarations4.js +++ b/tests/baselines/reference/mergedDeclarations4.js @@ -21,8 +21,7 @@ M.f.hello; //// [mergedDeclarations4.js] var M; (function (M) { - function f() { - } + function f() { } M.f = f; f(); M.f(); diff --git a/tests/baselines/reference/mergedModuleDeclarationCodeGen2.js b/tests/baselines/reference/mergedModuleDeclarationCodeGen2.js index 06a590194f..bb7c34e4ac 100644 --- a/tests/baselines/reference/mergedModuleDeclarationCodeGen2.js +++ b/tests/baselines/reference/mergedModuleDeclarationCodeGen2.js @@ -15,8 +15,7 @@ var my; (function (data) { var foo; (function (foo) { - function buz() { - } + function buz() { } foo.buz = buz; })(foo = data.foo || (data.foo = {})); })(data = my.data || (my.data = {})); diff --git a/tests/baselines/reference/mergedModuleDeclarationCodeGen3.js b/tests/baselines/reference/mergedModuleDeclarationCodeGen3.js index 43c55ed829..4a002e88f3 100644 --- a/tests/baselines/reference/mergedModuleDeclarationCodeGen3.js +++ b/tests/baselines/reference/mergedModuleDeclarationCodeGen3.js @@ -13,8 +13,7 @@ var my; (function (my) { var data; (function (data) { - function buz() { - } + function buz() { } data.buz = buz; })(data = my.data || (my.data = {})); })(my || (my = {})); diff --git a/tests/baselines/reference/mergedModuleDeclarationCodeGen4.js b/tests/baselines/reference/mergedModuleDeclarationCodeGen4.js index af7f5bacef..3e4a2dcd30 100644 --- a/tests/baselines/reference/mergedModuleDeclarationCodeGen4.js +++ b/tests/baselines/reference/mergedModuleDeclarationCodeGen4.js @@ -27,8 +27,7 @@ var superContain; (function (buz) { var data; (function (data) { - function foo() { - } + function foo() { } data.foo = foo; })(data = buz.data || (buz.data = {})); })(buz = my.buz || (my.buz = {})); diff --git a/tests/baselines/reference/mergedModuleDeclarationCodeGen5.js b/tests/baselines/reference/mergedModuleDeclarationCodeGen5.js index 4bbad2e567..44ab49d24e 100644 --- a/tests/baselines/reference/mergedModuleDeclarationCodeGen5.js +++ b/tests/baselines/reference/mergedModuleDeclarationCodeGen5.js @@ -25,11 +25,9 @@ var M; (function (buz) { var plop; (function (plop) { - function doom() { - } + function doom() { } plop.doom = doom; - function M() { - } + function M() { } plop.M = M; })(plop = buz.plop || (buz.plop = {})); })(buz = M_1.buz || (M_1.buz = {})); @@ -40,10 +38,8 @@ var M; (function (buz_1) { var plop; (function (plop_1) { - function gunk() { - } - function buz() { - } + function gunk() { } + function buz() { } var fudge = (function () { function fudge() { } diff --git a/tests/baselines/reference/methodContainingLocalFunction.js b/tests/baselines/reference/methodContainingLocalFunction.js index 36487e3ad7..f2f336d38b 100644 --- a/tests/baselines/reference/methodContainingLocalFunction.js +++ b/tests/baselines/reference/methodContainingLocalFunction.js @@ -56,8 +56,7 @@ var BugExhibition = (function () { function BugExhibition() { } BugExhibition.prototype.exhibitBug = function () { - function localFunction() { - } + function localFunction() { } var x; x = localFunction; }; @@ -68,8 +67,7 @@ var BugExhibition2 = (function () { } Object.defineProperty(BugExhibition2, "exhibitBug", { get: function () { - function localFunction() { - } + function localFunction() { } var x; x = localFunction; return null; @@ -83,8 +81,7 @@ var BugExhibition3 = (function () { function BugExhibition3() { } BugExhibition3.prototype.exhibitBug = function () { - function localGenericFunction(u) { - } + function localGenericFunction(u) { } var x; x = localGenericFunction; }; @@ -94,8 +91,7 @@ var C = (function () { function C() { } C.prototype.exhibit = function () { - var funcExpr = function (u) { - }; + var funcExpr = function (u) { }; var x; x = funcExpr; }; @@ -104,8 +100,7 @@ var C = (function () { var M; (function (M) { function exhibitBug() { - function localFunction() { - } + function localFunction() { } var x; x = localFunction; } @@ -114,8 +109,7 @@ var M; var E; (function (E) { E[E["A"] = (function () { - function localFunction() { - } + function localFunction() { } var x; x = localFunction; return 0; diff --git a/tests/baselines/reference/mismatchedExplicitTypeParameterAndArgumentType.js b/tests/baselines/reference/mismatchedExplicitTypeParameterAndArgumentType.js index 0315f0c7a6..0465ea46f5 100644 --- a/tests/baselines/reference/mismatchedExplicitTypeParameterAndArgumentType.js +++ b/tests/baselines/reference/mismatchedExplicitTypeParameterAndArgumentType.js @@ -15,44 +15,12 @@ var r8 = map([1, ""], (x) => x.toString()); //// [mismatchedExplicitTypeParameterAndArgumentType.js] function map(xs, f) { var ys = []; - xs.forEach(function (x) { - return ys.push(f(x)); - }); + xs.forEach(function (x) { return ys.push(f(x)); }); return ys; } -var r0 = map([ - 1, - "" -], function (x) { - return x.toString(); -}); -var r5 = map([ - 1, - "" -], function (x) { - return x.toString(); -}); -var r6 = map([ - 1, - "" -], function (x) { - return x.toString(); -}); -var r7 = map([ - 1, - "" -], function (x) { - return x.toString(); -}); // error -var r7b = map([ - 1, - "" -], function (x) { - return x.toString(); -}); // error -var r8 = map([ - 1, - "" -], function (x) { - return x.toString(); -}); +var r0 = map([1, ""], function (x) { return x.toString(); }); +var r5 = map([1, ""], function (x) { return x.toString(); }); +var r6 = map([1, ""], function (x) { return x.toString(); }); +var r7 = map([1, ""], function (x) { return x.toString(); }); // error +var r7b = map([1, ""], function (x) { return x.toString(); }); // error +var r8 = map([1, ""], function (x) { return x.toString(); }); diff --git a/tests/baselines/reference/missingSelf.js b/tests/baselines/reference/missingSelf.js index a0400aa4b2..56dcc4f9fa 100644 --- a/tests/baselines/reference/missingSelf.js +++ b/tests/baselines/reference/missingSelf.js @@ -22,11 +22,8 @@ c2.b(); var CalcButton = (function () { function CalcButton() { } - CalcButton.prototype.a = function () { - this.onClick(); - }; - CalcButton.prototype.onClick = function () { - }; + CalcButton.prototype.a = function () { this.onClick(); }; + CalcButton.prototype.onClick = function () { }; return CalcButton; })(); var CalcButton2 = (function () { @@ -34,12 +31,9 @@ var CalcButton2 = (function () { } CalcButton2.prototype.b = function () { var _this = this; - (function () { - return _this.onClick(); - }); - }; - CalcButton2.prototype.onClick = function () { + (function () { return _this.onClick(); }); }; + CalcButton2.prototype.onClick = function () { }; return CalcButton2; })(); var c = new CalcButton(); diff --git a/tests/baselines/reference/missingTypeArguments2.js b/tests/baselines/reference/missingTypeArguments2.js index fe4b7c7dd7..bc5c1d88f4 100644 --- a/tests/baselines/reference/missingTypeArguments2.js +++ b/tests/baselines/reference/missingTypeArguments2.js @@ -13,9 +13,6 @@ var A = (function () { return A; })(); var x; -(function (a) { -}); +(function (a) { }); var y; -(function () { - return null; -}); +(function () { return null; }); diff --git a/tests/baselines/reference/mixingFunctionAndAmbientModule1.js b/tests/baselines/reference/mixingFunctionAndAmbientModule1.js index 3105c92330..db1bc28a14 100644 --- a/tests/baselines/reference/mixingFunctionAndAmbientModule1.js +++ b/tests/baselines/reference/mixingFunctionAndAmbientModule1.js @@ -45,13 +45,11 @@ module E { //// [mixingFunctionAndAmbientModule1.js] var A; (function (A) { - function My(s) { - } + function My(s) { } })(A || (A = {})); var B; (function (B) { - function My(s) { - } + function My(s) { } })(B || (B = {})); var C; (function (C) { diff --git a/tests/baselines/reference/mixingStaticAndInstanceOverloads.js b/tests/baselines/reference/mixingStaticAndInstanceOverloads.js index 5949528077..22367461c2 100644 --- a/tests/baselines/reference/mixingStaticAndInstanceOverloads.js +++ b/tests/baselines/reference/mixingStaticAndInstanceOverloads.js @@ -39,37 +39,31 @@ class C5 { var C1 = (function () { function C1() { } - C1.foo1 = function (a) { - }; + C1.foo1 = function (a) { }; return C1; })(); var C2 = (function () { function C2() { } - C2.prototype.foo2 = function (a) { - }; + C2.prototype.foo2 = function (a) { }; return C2; })(); var C3 = (function () { function C3() { } - C3.prototype.foo3 = function (a) { - }; + C3.prototype.foo3 = function (a) { }; return C3; })(); var C4 = (function () { function C4() { } - C4.foo4 = function (a) { - }; + C4.foo4 = function (a) { }; return C4; })(); var C5 = (function () { function C5() { } - C5.prototype.foo5 = function (a) { - }; - C5.foo5 = function (a) { - }; + C5.prototype.foo5 = function (a) { }; + C5.foo5 = function (a) { }; return C5; })(); diff --git a/tests/baselines/reference/modFunctionCrash.js b/tests/baselines/reference/modFunctionCrash.js index f216788c0e..0d4f62eae6 100644 --- a/tests/baselines/reference/modFunctionCrash.js +++ b/tests/baselines/reference/modFunctionCrash.js @@ -7,6 +7,4 @@ declare module Q { Q.f(function() {this;}); //// [modFunctionCrash.js] -Q.f(function () { - this; -}); +Q.f(function () { this; }); diff --git a/tests/baselines/reference/moduleCodeGenTest5.js b/tests/baselines/reference/moduleCodeGenTest5.js index 6f56f44c68..afc1ce23e3 100644 --- a/tests/baselines/reference/moduleCodeGenTest5.js +++ b/tests/baselines/reference/moduleCodeGenTest5.js @@ -24,17 +24,14 @@ var v = E2.B; //// [moduleCodeGenTest5.js] exports.x = 0; var y = 0; -function f1() { -} +function f1() { } exports.f1 = f1; -function f2() { -} +function f2() { } var C1 = (function () { function C1() { this.p1 = 0; } - C1.prototype.p2 = function () { - }; + C1.prototype.p2 = function () { }; return C1; })(); exports.C1 = C1; @@ -42,8 +39,7 @@ var C2 = (function () { function C2() { this.p1 = 0; } - C2.prototype.p2 = function () { - }; + C2.prototype.p2 = function () { }; return C2; })(); (function (E1) { diff --git a/tests/baselines/reference/moduleInTypePosition1.js b/tests/baselines/reference/moduleInTypePosition1.js index 92fcd5b16e..972bbae63d 100644 --- a/tests/baselines/reference/moduleInTypePosition1.js +++ b/tests/baselines/reference/moduleInTypePosition1.js @@ -19,5 +19,4 @@ var Promise = (function () { })(); exports.Promise = Promise; //// [moduleInTypePosition1_1.js] -var x = function (w1) { -}; +var x = function (w1) { }; diff --git a/tests/baselines/reference/moduleKeywordRepeatError.js b/tests/baselines/reference/moduleKeywordRepeatError.js index 8ec656f22a..385bce001a 100644 --- a/tests/baselines/reference/moduleKeywordRepeatError.js +++ b/tests/baselines/reference/moduleKeywordRepeatError.js @@ -6,5 +6,4 @@ module.module { } //// [moduleKeywordRepeatError.js] // "module.module { }" should raise a syntax error module.module; -{ -} +{ } diff --git a/tests/baselines/reference/moduleMemberWithoutTypeAnnotation1.js b/tests/baselines/reference/moduleMemberWithoutTypeAnnotation1.js index 63ccf613a7..1467ec18b9 100644 --- a/tests/baselines/reference/moduleMemberWithoutTypeAnnotation1.js +++ b/tests/baselines/reference/moduleMemberWithoutTypeAnnotation1.js @@ -102,8 +102,7 @@ var TypeScript; (function (TypeScript) { var Syntax; (function (Syntax) { - function childIndex() { - } + function childIndex() { } Syntax.childIndex = childIndex; var VariableWidthTokenWithTrailingTrivia = (function () { function VariableWidthTokenWithTrailingTrivia() { diff --git a/tests/baselines/reference/moduleNewExportBug.js b/tests/baselines/reference/moduleNewExportBug.js index 51e1bb2414..ce40915b2f 100644 --- a/tests/baselines/reference/moduleNewExportBug.js +++ b/tests/baselines/reference/moduleNewExportBug.js @@ -19,8 +19,7 @@ var mod1; var C = (function () { function C() { } - C.prototype.moo = function () { - }; + C.prototype.moo = function () { }; return C; })(); })(mod1 || (mod1 = {})); diff --git a/tests/baselines/reference/moduleReopenedTypeOtherBlock.js b/tests/baselines/reference/moduleReopenedTypeOtherBlock.js index d2dc938872..951c558ddf 100644 --- a/tests/baselines/reference/moduleReopenedTypeOtherBlock.js +++ b/tests/baselines/reference/moduleReopenedTypeOtherBlock.js @@ -23,9 +23,7 @@ var M; var C2 = (function () { function C2() { } - C2.prototype.f = function () { - return null; - }; + C2.prototype.f = function () { return null; }; return C2; })(); M.C2 = C2; diff --git a/tests/baselines/reference/moduleReopenedTypeSameBlock.js b/tests/baselines/reference/moduleReopenedTypeSameBlock.js index c3546f20b2..92e7e9e522 100644 --- a/tests/baselines/reference/moduleReopenedTypeSameBlock.js +++ b/tests/baselines/reference/moduleReopenedTypeSameBlock.js @@ -21,9 +21,7 @@ var M; var C2 = (function () { function C2() { } - C2.prototype.f = function () { - return null; - }; + C2.prototype.f = function () { return null; }; return C2; })(); M.C2 = C2; diff --git a/tests/baselines/reference/moduleScoping.js b/tests/baselines/reference/moduleScoping.js index 1bcf1dbea0..cbe435e570 100644 --- a/tests/baselines/reference/moduleScoping.js +++ b/tests/baselines/reference/moduleScoping.js @@ -26,24 +26,15 @@ var x = v2; // Should be global v2 of type number again var v1 = "sausages"; // Global scope //// [file2.js] var v2 = 42; // Global scope -var v4 = function () { - return 5; -}; +var v4 = function () { return 5; }; //// [file3.js] exports.v3 = true; -var v2 = [ - 1, - 2, - 3 -]; // Module scope. Should not appear in global scope +var v2 = [1, 2, 3]; // Module scope. Should not appear in global scope //// [file4.js] var file3 = require('./file3'); var t1 = v1; var t2 = v2; var t3 = file3.v3; -var v4 = { - a: true, - b: NaN -}; // Should shadow global v2 in this module +var v4 = { a: true, b: NaN }; // Should shadow global v2 in this module //// [file5.js] var x = v2; // Should be global v2 of type number again diff --git a/tests/baselines/reference/moduleSymbolMerging.js b/tests/baselines/reference/moduleSymbolMerging.js index 0a812a62e0..d43fff1378 100644 --- a/tests/baselines/reference/moduleSymbolMerging.js +++ b/tests/baselines/reference/moduleSymbolMerging.js @@ -22,9 +22,7 @@ var A; })(A || (A = {})); var B; (function (B) { - function f() { - return null; - } + function f() { return null; } B.f = f; })(B || (B = {})); diff --git a/tests/baselines/reference/moduleUnassignedVariable.js b/tests/baselines/reference/moduleUnassignedVariable.js index 179a2577ad..1765342efc 100644 --- a/tests/baselines/reference/moduleUnassignedVariable.js +++ b/tests/baselines/reference/moduleUnassignedVariable.js @@ -12,11 +12,7 @@ module Bar { var Bar; (function (Bar) { Bar.a = 1; - function fooA() { - return Bar.a; - } // Correct: return Bar.a + function fooA() { return Bar.a; } // Correct: return Bar.a Bar.b; - function fooB() { - return Bar.b; - } // Incorrect: return b + function fooB() { return Bar.b; } // Incorrect: return b })(Bar || (Bar = {})); diff --git a/tests/baselines/reference/moduleVisibilityTest1.js b/tests/baselines/reference/moduleVisibilityTest1.js index 8f129f545d..f4655513be 100644 --- a/tests/baselines/reference/moduleVisibilityTest1.js +++ b/tests/baselines/reference/moduleVisibilityTest1.js @@ -70,15 +70,11 @@ c.someMethodThatCallsAnOuterMethod(); //// [moduleVisibilityTest1.js] var OuterMod; (function (OuterMod) { - function someExportedOuterFunc() { - return -1; - } + function someExportedOuterFunc() { return -1; } OuterMod.someExportedOuterFunc = someExportedOuterFunc; var OuterInnerMod; (function (OuterInnerMod) { - function someExportedOuterInnerFunc() { - return "foo"; - } + function someExportedOuterInnerFunc() { return "foo"; } OuterInnerMod.someExportedOuterInnerFunc = someExportedOuterInnerFunc; })(OuterInnerMod = OuterMod.OuterInnerMod || (OuterMod.OuterInnerMod = {})); })(OuterMod || (OuterMod = {})); @@ -87,9 +83,7 @@ var M; (function (M) { var InnerMod; (function (InnerMod) { - function someExportedInnerFunc() { - return -2; - } + function someExportedInnerFunc() { return -2; } InnerMod.someExportedInnerFunc = someExportedInnerFunc; })(InnerMod = M.InnerMod || (M.InnerMod = {})); (function (E) { @@ -109,30 +103,18 @@ var M; var C = (function () { function C() { this.someProp = 1; - function someInnerFunc() { - return 2; - } + function someInnerFunc() { return 2; } var someInnerVar = 3; } - C.prototype.someMethodThatCallsAnOuterMethod = function () { - return OuterInnerAlias.someExportedOuterInnerFunc(); - }; - C.prototype.someMethodThatCallsAnInnerMethod = function () { - return InnerMod.someExportedInnerFunc(); - }; - C.prototype.someMethodThatCallsAnOuterInnerMethod = function () { - return OuterMod.someExportedOuterFunc(); - }; - C.prototype.someMethod = function () { - return 0; - }; + C.prototype.someMethodThatCallsAnOuterMethod = function () { return OuterInnerAlias.someExportedOuterInnerFunc(); }; + C.prototype.someMethodThatCallsAnInnerMethod = function () { return InnerMod.someExportedInnerFunc(); }; + C.prototype.someMethodThatCallsAnOuterInnerMethod = function () { return OuterMod.someExportedOuterFunc(); }; + C.prototype.someMethod = function () { return 0; }; return C; })(); M.C = C; var someModuleVar = 4; - function someModuleFunction() { - return 5; - } + function someModuleFunction() { return 5; } })(M || (M = {})); var M; (function (M) { diff --git a/tests/baselines/reference/moduleVisibilityTest2.js b/tests/baselines/reference/moduleVisibilityTest2.js index 63ecaf0c13..9102bd17ae 100644 --- a/tests/baselines/reference/moduleVisibilityTest2.js +++ b/tests/baselines/reference/moduleVisibilityTest2.js @@ -71,15 +71,11 @@ c.someMethodThatCallsAnOuterMethod(); //// [moduleVisibilityTest2.js] var OuterMod; (function (OuterMod) { - function someExportedOuterFunc() { - return -1; - } + function someExportedOuterFunc() { return -1; } OuterMod.someExportedOuterFunc = someExportedOuterFunc; var OuterInnerMod; (function (OuterInnerMod) { - function someExportedOuterInnerFunc() { - return "foo"; - } + function someExportedOuterInnerFunc() { return "foo"; } OuterInnerMod.someExportedOuterInnerFunc = someExportedOuterInnerFunc; })(OuterInnerMod = OuterMod.OuterInnerMod || (OuterMod.OuterInnerMod = {})); })(OuterMod || (OuterMod = {})); @@ -88,9 +84,7 @@ var M; (function (M) { var InnerMod; (function (InnerMod) { - function someExportedInnerFunc() { - return -2; - } + function someExportedInnerFunc() { return -2; } InnerMod.someExportedInnerFunc = someExportedInnerFunc; })(InnerMod || (InnerMod = {})); var E; @@ -110,30 +104,18 @@ var M; var C = (function () { function C() { this.someProp = 1; - function someInnerFunc() { - return 2; - } + function someInnerFunc() { return 2; } var someInnerVar = 3; } - C.prototype.someMethodThatCallsAnOuterMethod = function () { - return OuterInnerAlias.someExportedOuterInnerFunc(); - }; - C.prototype.someMethodThatCallsAnInnerMethod = function () { - return InnerMod.someExportedInnerFunc(); - }; - C.prototype.someMethodThatCallsAnOuterInnerMethod = function () { - return OuterMod.someExportedOuterFunc(); - }; - C.prototype.someMethod = function () { - return 0; - }; + C.prototype.someMethodThatCallsAnOuterMethod = function () { return OuterInnerAlias.someExportedOuterInnerFunc(); }; + C.prototype.someMethodThatCallsAnInnerMethod = function () { return InnerMod.someExportedInnerFunc(); }; + C.prototype.someMethodThatCallsAnOuterInnerMethod = function () { return OuterMod.someExportedOuterFunc(); }; + C.prototype.someMethod = function () { return 0; }; return C; })(); M.C = C; var someModuleVar = 4; - function someModuleFunction() { - return 5; - } + function someModuleFunction() { return 5; } })(M || (M = {})); var M; (function (M) { diff --git a/tests/baselines/reference/moduleWithStatementsOfEveryKind.js b/tests/baselines/reference/moduleWithStatementsOfEveryKind.js index cab0d35aa5..8ce4cb693f 100644 --- a/tests/baselines/reference/moduleWithStatementsOfEveryKind.js +++ b/tests/baselines/reference/moduleWithStatementsOfEveryKind.js @@ -112,11 +112,7 @@ var A; var fn = function (s) { return 'hello ' + s; }; - var ol = { - s: 'hello', - id: 2, - isvalid: true - }; + var ol = { s: 'hello', id: 2, isvalid: true }; })(A || (A = {})); var Y; (function (Y) { @@ -170,9 +166,5 @@ var Y; Y.fn = function (s) { return 'hello ' + s; }; - Y.ol = { - s: 'hello', - id: 2, - isvalid: true - }; + Y.ol = { s: 'hello', id: 2, isvalid: true }; })(Y || (Y = {})); diff --git a/tests/baselines/reference/multiCallOverloads.js b/tests/baselines/reference/multiCallOverloads.js index 85b008d52b..d4e765c551 100644 --- a/tests/baselines/reference/multiCallOverloads.js +++ b/tests/baselines/reference/multiCallOverloads.js @@ -14,15 +14,10 @@ load(function(z?) {}) // this shouldn't be an error //// [multiCallOverloads.js] -function load(f) { -} -var f1 = function (z) { -}; -var f2 = function (z) { -}; +function load(f) { } +var f1 = function (z) { }; +var f2 = function (z) { }; load(f1); // ok load(f2); // ok -load(function () { -}); // this shouldn’t be an error -load(function (z) { -}); // this shouldn't be an error +load(function () { }); // this shouldn’t be an error +load(function (z) { }); // this shouldn't be an error diff --git a/tests/baselines/reference/multiLinePropertyAccessAndArrowFunctionIndent1.js b/tests/baselines/reference/multiLinePropertyAccessAndArrowFunctionIndent1.js index 4d0317a50a..2ada9f1bb5 100644 --- a/tests/baselines/reference/multiLinePropertyAccessAndArrowFunctionIndent1.js +++ b/tests/baselines/reference/multiLinePropertyAccessAndArrowFunctionIndent1.js @@ -7,8 +7,8 @@ return this.edit(role) //// [multiLinePropertyAccessAndArrowFunctionIndent1.js] var _this = this; -return this.edit(role).then(function (role) { - return _this.roleService.add(role).then(function (data) { - return data.data; - }); +return this.edit(role) + .then(function (role) { + return _this.roleService.add(role) + .then(function (data) { return data.data; }); }); diff --git a/tests/baselines/reference/multiModuleClodule1.js b/tests/baselines/reference/multiModuleClodule1.js index a64abd8168..9f6d7b5014 100644 --- a/tests/baselines/reference/multiModuleClodule1.js +++ b/tests/baselines/reference/multiModuleClodule1.js @@ -22,12 +22,9 @@ c.foo = C.foo; var C = (function () { function C(x) { } - C.prototype.foo = function () { - }; - C.prototype.bar = function () { - }; - C.boo = function () { - }; + C.prototype.foo = function () { }; + C.prototype.bar = function () { }; + C.boo = function () { }; return C; })(); var C; @@ -37,12 +34,9 @@ var C; })(C || (C = {})); var C; (function (C) { - function foo() { - } + function foo() { } C.foo = foo; - function baz() { - return ''; - } + function baz() { return ''; } })(C || (C = {})); var c = new C(C.x); c.foo = C.foo; diff --git a/tests/baselines/reference/multiModuleFundule1.js b/tests/baselines/reference/multiModuleFundule1.js index f643ed5ee4..6aa9cb959b 100644 --- a/tests/baselines/reference/multiModuleFundule1.js +++ b/tests/baselines/reference/multiModuleFundule1.js @@ -13,16 +13,14 @@ var r2 = new C(2); // using void returning function as constructor var r3 = C.foo(); //// [multiModuleFundule1.js] -function C(x) { -} +function C(x) { } var C; (function (C) { C.x = 1; })(C || (C = {})); var C; (function (C) { - function foo() { - } + function foo() { } C.foo = foo; })(C || (C = {})); var r = C(2); diff --git a/tests/baselines/reference/multipleInheritance.js b/tests/baselines/reference/multipleInheritance.js index 9cab77f3db..269d5c2ea1 100644 --- a/tests/baselines/reference/multipleInheritance.js +++ b/tests/baselines/reference/multipleInheritance.js @@ -97,13 +97,9 @@ var ND = (function (_super) { })(N); var Good = (function () { function Good() { - this.f = function () { - return 0; - }; + this.f = function () { return 0; }; } - Good.prototype.g = function () { - return 0; - }; + Good.prototype.g = function () { return 0; }; return Good; })(); var Baad = (function (_super) { @@ -111,11 +107,7 @@ var Baad = (function (_super) { function Baad() { _super.apply(this, arguments); } - Baad.prototype.f = function () { - return 0; - }; - Baad.prototype.g = function (n) { - return 0; - }; + Baad.prototype.f = function () { return 0; }; + Baad.prototype.g = function (n) { return 0; }; return Baad; })(Good); diff --git a/tests/baselines/reference/multipleNumericIndexers.js b/tests/baselines/reference/multipleNumericIndexers.js index 31bd84e535..638cf01569 100644 --- a/tests/baselines/reference/multipleNumericIndexers.js +++ b/tests/baselines/reference/multipleNumericIndexers.js @@ -40,10 +40,7 @@ var C = (function () { return C; })(); var a; -var b = { - 1: '', - "2": '' -}; +var b = { 1: '', "2": '' }; var C2 = (function () { function C2() { } diff --git a/tests/baselines/reference/multipleStringIndexers.js b/tests/baselines/reference/multipleStringIndexers.js index b914b20565..55dd816e42 100644 --- a/tests/baselines/reference/multipleStringIndexers.js +++ b/tests/baselines/reference/multipleStringIndexers.js @@ -39,9 +39,7 @@ var C = (function () { return C; })(); var a; -var b = { - y: '' -}; +var b = { y: '' }; var C2 = (function () { function C2() { } diff --git a/tests/baselines/reference/mutrec.js b/tests/baselines/reference/mutrec.js index ba6c8ade03..1d1ccb4e90 100644 --- a/tests/baselines/reference/mutrec.js +++ b/tests/baselines/reference/mutrec.js @@ -43,15 +43,11 @@ g(i4); //// [mutrec.js] -function f(p) { - return p; -} +function f(p) { return p; } ; var b; f(b); -function g(p) { - return p; -} +function g(p) { return p; } ; var i2; g(i2); diff --git a/tests/baselines/reference/mutuallyRecursiveGenericBaseTypes2.js b/tests/baselines/reference/mutuallyRecursiveGenericBaseTypes2.js index 585a3d2178..76fd13aa32 100644 --- a/tests/baselines/reference/mutuallyRecursiveGenericBaseTypes2.js +++ b/tests/baselines/reference/mutuallyRecursiveGenericBaseTypes2.js @@ -20,9 +20,7 @@ var __extends = this.__extends || function (d, b) { var foo = (function () { function foo() { } - foo.prototype.bar = function () { - return null; - }; + foo.prototype.bar = function () { return null; }; return foo; })(); var foo2 = (function (_super) { diff --git a/tests/baselines/reference/nameCollisions.js b/tests/baselines/reference/nameCollisions.js index 51b66adcef..2cfaba9499 100644 --- a/tests/baselines/reference/nameCollisions.js +++ b/tests/baselines/reference/nameCollisions.js @@ -76,10 +76,8 @@ var T; })(); // error var w; var f; - function f() { - } //error - function f2() { - } + function f() { } //error + function f2() { } var f2; // error var i; var C = (function () { @@ -87,17 +85,14 @@ var T; } return C; })(); - function C() { - } // error - function C2() { - } + function C() { } // error + function C2() { } var C2 = (function () { function C2() { } return C2; })(); // error - function fi() { - } + function fi() { } var cli = (function () { function cli() { } diff --git a/tests/baselines/reference/nameCollisionsInPropertyAssignments.js b/tests/baselines/reference/nameCollisionsInPropertyAssignments.js index 4c2634d881..1f3631e03b 100644 --- a/tests/baselines/reference/nameCollisionsInPropertyAssignments.js +++ b/tests/baselines/reference/nameCollisionsInPropertyAssignments.js @@ -4,8 +4,4 @@ var y = { x() { x++; } }; //// [nameCollisionsInPropertyAssignments.js] var x = 1; -var y = { - x: function () { - x++; - } -}; +var y = { x: function () { x++; } }; diff --git a/tests/baselines/reference/negateOperatorWithAnyOtherType.js b/tests/baselines/reference/negateOperatorWithAnyOtherType.js index 453b032e00..8418bbbe46 100644 --- a/tests/baselines/reference/negateOperatorWithAnyOtherType.js +++ b/tests/baselines/reference/negateOperatorWithAnyOtherType.js @@ -57,16 +57,9 @@ var ResultIsNumber15 = -(ANY - ANY1); // - operator on any type var ANY; var ANY1; -var ANY2 = [ - "", - "" -]; +var ANY2 = ["", ""]; var obj; -var obj1 = { - x: "", - y: function () { - } -}; +var obj1 = { x: "", y: function () { } }; function foo() { var a; return a; diff --git a/tests/baselines/reference/negateOperatorWithBooleanType.js b/tests/baselines/reference/negateOperatorWithBooleanType.js index f50382de65..9442f54490 100644 --- a/tests/baselines/reference/negateOperatorWithBooleanType.js +++ b/tests/baselines/reference/negateOperatorWithBooleanType.js @@ -38,15 +38,11 @@ var ResultIsNumber7 = -A.foo(); //// [negateOperatorWithBooleanType.js] // - operator on boolean type var BOOLEAN; -function foo() { - return true; -} +function foo() { return true; } var A = (function () { function A() { } - A.foo = function () { - return false; - }; + A.foo = function () { return false; }; return A; })(); var M; @@ -58,10 +54,7 @@ var objA = new A(); var ResultIsNumber1 = -BOOLEAN; // boolean type literal var ResultIsNumber2 = -true; -var ResultIsNumber3 = -{ - x: true, - y: false -}; +var ResultIsNumber3 = -{ x: true, y: false }; // boolean type expressions var ResultIsNumber4 = -objA.a; var ResultIsNumber5 = -M.n; diff --git a/tests/baselines/reference/negateOperatorWithNumberType.js b/tests/baselines/reference/negateOperatorWithNumberType.js index 90cb9c073b..5fa83e088c 100644 --- a/tests/baselines/reference/negateOperatorWithNumberType.js +++ b/tests/baselines/reference/negateOperatorWithNumberType.js @@ -44,19 +44,12 @@ var ResultIsNumber11 = -(NUMBER - NUMBER); //// [negateOperatorWithNumberType.js] // - operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; -function foo() { - return 1; -} +var NUMBER1 = [1, 2]; +function foo() { return 1; } var A = (function () { function A() { } - A.foo = function () { - return 1; - }; + A.foo = function () { return 1; }; return A; })(); var M; @@ -69,16 +62,8 @@ var ResultIsNumber1 = -NUMBER; var ResultIsNumber2 = -NUMBER1; // number type literal var ResultIsNumber3 = -1; -var ResultIsNumber4 = -{ - x: 1, - y: 2 -}; -var ResultIsNumber5 = -{ - x: 1, - y: function (n) { - return n; - } -}; +var ResultIsNumber4 = -{ x: 1, y: 2 }; +var ResultIsNumber5 = -{ x: 1, y: function (n) { return n; } }; // number type expressions var ResultIsNumber6 = -objA.a; var ResultIsNumber7 = -M.n; diff --git a/tests/baselines/reference/negateOperatorWithStringType.js b/tests/baselines/reference/negateOperatorWithStringType.js index 153a592109..bdbc4a3d66 100644 --- a/tests/baselines/reference/negateOperatorWithStringType.js +++ b/tests/baselines/reference/negateOperatorWithStringType.js @@ -43,19 +43,12 @@ var ResultIsNumber12 = -STRING.charAt(0); //// [negateOperatorWithStringType.js] // - operator on string type var STRING; -var STRING1 = [ - "", - "abc" -]; -function foo() { - return "abc"; -} +var STRING1 = ["", "abc"]; +function foo() { return "abc"; } var A = (function () { function A() { } - A.foo = function () { - return ""; - }; + A.foo = function () { return ""; }; return A; })(); var M; @@ -68,16 +61,8 @@ var ResultIsNumber1 = -STRING; var ResultIsNumber2 = -STRING1; // string type literal var ResultIsNumber3 = -""; -var ResultIsNumber4 = -{ - x: "", - y: "" -}; -var ResultIsNumber5 = -{ - x: "", - y: function (s) { - return s; - } -}; +var ResultIsNumber4 = -{ x: "", y: "" }; +var ResultIsNumber5 = -{ x: "", y: function (s) { return s; } }; // string type expressions var ResultIsNumber6 = -objA.a; var ResultIsNumber7 = -M.n; diff --git a/tests/baselines/reference/nestedClassDeclaration.js b/tests/baselines/reference/nestedClassDeclaration.js index c7f0ffe34f..70445b3372 100644 --- a/tests/baselines/reference/nestedClassDeclaration.js +++ b/tests/baselines/reference/nestedClassDeclaration.js @@ -30,13 +30,11 @@ var C2 = (function () { } return C2; })(); -function foo() { -} +function foo() { } var C3 = (function () { function C3() { } return C3; })(); var x = { - class: C4 -}, _a = void 0; + class: C4 }, _a = void 0; diff --git a/tests/baselines/reference/nestedModules.js b/tests/baselines/reference/nestedModules.js index fe3af5ae69..f146990ec8 100644 --- a/tests/baselines/reference/nestedModules.js +++ b/tests/baselines/reference/nestedModules.js @@ -37,10 +37,7 @@ var A; (function (A) { var B; (function (B) { - var Point = { - x: 0, - y: 0 - }; // bug 832088: could not find module 'C' + var Point = { x: 0, y: 0 }; // bug 832088: could not find module 'C' })(B = A.B || (A.B = {})); })(A || (A = {})); var M2; diff --git a/tests/baselines/reference/nestedRecursiveLambda.js b/tests/baselines/reference/nestedRecursiveLambda.js index eff3da0e21..0273b5691e 100644 --- a/tests/baselines/reference/nestedRecursiveLambda.js +++ b/tests/baselines/reference/nestedRecursiveLambda.js @@ -8,26 +8,8 @@ void(r =>(r => r)); //// [nestedRecursiveLambda.js] function f(a) { - void (function (r) { - return (function (r) { - return r; - }); - }); + void (function (r) { return (function (r) { return r; }); }); } -f((function (r) { - return (function (r) { - return r; - }); -})); -void (function (r) { - return (function (r) { - return r; - }); -}); -[ - (function (r) { - return (function (r) { - return r; - }); - }) -]; +f((function (r) { return (function (r) { return r; }); })); +void (function (r) { return (function (r) { return r; }); }); +[(function (r) { return (function (r) { return r; }); })]; diff --git a/tests/baselines/reference/nestedSelf.js b/tests/baselines/reference/nestedSelf.js index b61a095667..9c0feaa887 100644 --- a/tests/baselines/reference/nestedSelf.js +++ b/tests/baselines/reference/nestedSelf.js @@ -17,13 +17,7 @@ var M; } C.prototype.foo = function () { var _this = this; - [ - 1, - 2, - 3 - ].map(function (x) { - return _this.n * x; - }); + [1, 2, 3].map(function (x) { return _this.n * x; }); }; return C; })(); diff --git a/tests/baselines/reference/newExpressionWithCast.js b/tests/baselines/reference/newExpressionWithCast.js index 6ce025a426..8743d9b83b 100644 --- a/tests/baselines/reference/newExpressionWithCast.js +++ b/tests/baselines/reference/newExpressionWithCast.js @@ -15,15 +15,12 @@ var test3 = new (Test3)(); //// [newExpressionWithCast.js] -function Test() { -} +function Test() { } // valid but error with noImplicitAny var test = new Test(); -function Test2() { -} +function Test2() { } // parse error var test2 = new < any > Test2(); -function Test3() { -} +function Test3() { } // valid with noImplicitAny var test3 = new Test3(); diff --git a/tests/baselines/reference/newFunctionImplicitAny.js b/tests/baselines/reference/newFunctionImplicitAny.js index 9f8d303680..459c7d581d 100644 --- a/tests/baselines/reference/newFunctionImplicitAny.js +++ b/tests/baselines/reference/newFunctionImplicitAny.js @@ -6,6 +6,5 @@ var test = new Test(); //// [newFunctionImplicitAny.js] // No implicit any error given when newing a function (up for debate) -function Test() { -} +function Test() { } var test = new Test(); diff --git a/tests/baselines/reference/newOperatorConformance.js b/tests/baselines/reference/newOperatorConformance.js index 4e5c209bbf..a04b10dc8f 100644 --- a/tests/baselines/reference/newOperatorConformance.js +++ b/tests/baselines/reference/newOperatorConformance.js @@ -104,8 +104,7 @@ function newFn2(s) { var p; } // Construct expression of void returning function -function fnVoid() { -} +function fnVoid() { } var t = new fnVoid(); var t; // Chained new expressions diff --git a/tests/baselines/reference/newOperatorErrorCases.js b/tests/baselines/reference/newOperatorErrorCases.js index 8a44d51fb5..b893beba02 100644 --- a/tests/baselines/reference/newOperatorErrorCases.js +++ b/tests/baselines/reference/newOperatorErrorCases.js @@ -65,7 +65,5 @@ var c1 = new T; var c1; var c2 = new T(); // Parse error // Construct expression of non-void returning function -function fnNumber() { - return 32; -} +function fnNumber() { return 32; } var s = new fnNumber(); // Error diff --git a/tests/baselines/reference/noCollisionThisExpressionAndClassInGlobal.js b/tests/baselines/reference/noCollisionThisExpressionAndClassInGlobal.js index 4ddb34b094..8a485a2ebe 100644 --- a/tests/baselines/reference/noCollisionThisExpressionAndClassInGlobal.js +++ b/tests/baselines/reference/noCollisionThisExpressionAndClassInGlobal.js @@ -9,6 +9,4 @@ var _this = (function () { } return _this; })(); -var f = function () { - return _this; -}; +var f = function () { return _this; }; diff --git a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInAccessors.js b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInAccessors.js index 4e74658236..727b1b6087 100644 --- a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInAccessors.js +++ b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInAccessors.js @@ -50,23 +50,19 @@ var class1 = (function () { Object.defineProperty(class1.prototype, "a", { get: function () { var x2 = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; return 10; }, set: function (val) { var x2 = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; }, enumerable: true, @@ -81,22 +77,18 @@ var class2 = (function () { get: function () { var _this = 2; var x2 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; return 10; }, set: function (val) { var _this = 2; var x2 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; }, enumerable: true, diff --git a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInConstructor.js b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInConstructor.js index ce86ca4730..a01996848b 100644 --- a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInConstructor.js +++ b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInConstructor.js @@ -25,12 +25,10 @@ class class2 { var class1 = (function () { function class1() { var x2 = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; } return class1; @@ -39,11 +37,9 @@ var class2 = (function () { function class2() { var _this = 2; var x2 = { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; } return class2; diff --git a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInFunction.js b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInFunction.js index d144a78fae..bdb5563368 100644 --- a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInFunction.js +++ b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInFunction.js @@ -11,7 +11,5 @@ function x() { var console; function x() { var _this = 5; - (function (x) { - console.log(_this); - }); + (function (x) { console.log(_this); }); } diff --git a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInLambda.js b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInLambda.js index 487751bd49..83f21d1042 100644 --- a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInLambda.js +++ b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInLambda.js @@ -10,13 +10,9 @@ alert(x.doStuff(x => alert(x))); //// [noCollisionThisExpressionAndLocalVarInLambda.js] var x = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; -alert(x.doStuff(function (x) { - return alert(x); -})); +alert(x.doStuff(function (x) { return alert(x); })); diff --git a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInMethod.js b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInMethod.js index f91039b6c6..b7e9cc7561 100644 --- a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInMethod.js +++ b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInMethod.js @@ -26,22 +26,18 @@ var a = (function () { } a.prototype.method1 = function () { return { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; }; a.prototype.method2 = function () { var _this = 2; return { - doStuff: function (callback) { - return function () { - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + return callback(_this); + }; } }; }; return a; diff --git a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInProperty.js b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInProperty.js index 374a812ba4..da989bed26 100644 --- a/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInProperty.js +++ b/tests/baselines/reference/noCollisionThisExpressionAndLocalVarInProperty.js @@ -23,12 +23,10 @@ class class2 { var class1 = (function () { function class1() { this.prop1 = { - doStuff: function (callback) { - return function () { - var _this = 2; - return callback(_this); - }; - } + doStuff: function (callback) { return function () { + var _this = 2; + return callback(_this); + }; } }; } return class1; @@ -36,11 +34,9 @@ var class1 = (function () { var class2 = (function () { function class2() { this.prop1 = { - doStuff: function (callback) { - return function () { - return callback(10); - }; - } + doStuff: function (callback) { return function () { + return callback(10); + }; } }; var _this = 2; } diff --git a/tests/baselines/reference/noCollisionThisExpressionAndVarInGlobal.js b/tests/baselines/reference/noCollisionThisExpressionAndVarInGlobal.js index c0377976e9..bea476ed09 100644 --- a/tests/baselines/reference/noCollisionThisExpressionAndVarInGlobal.js +++ b/tests/baselines/reference/noCollisionThisExpressionAndVarInGlobal.js @@ -4,6 +4,4 @@ var f = () => _this; //// [noCollisionThisExpressionAndVarInGlobal.js] var _this = 1; -var f = function () { - return _this; -}; +var f = function () { return _this; }; diff --git a/tests/baselines/reference/noCollisionThisExpressionInFunctionAndVarInGlobal.js b/tests/baselines/reference/noCollisionThisExpressionInFunctionAndVarInGlobal.js index c34ad4c97b..b367768182 100644 --- a/tests/baselines/reference/noCollisionThisExpressionInFunctionAndVarInGlobal.js +++ b/tests/baselines/reference/noCollisionThisExpressionInFunctionAndVarInGlobal.js @@ -12,7 +12,5 @@ var console; var _this = 5; function x() { var _this = this; - (function (x) { - console.log(_this); - }); + (function (x) { console.log(_this); }); } diff --git a/tests/baselines/reference/noConstraintInReturnType1.js b/tests/baselines/reference/noConstraintInReturnType1.js index 747cbfdf75..0402f9d83c 100644 --- a/tests/baselines/reference/noConstraintInReturnType1.js +++ b/tests/baselines/reference/noConstraintInReturnType1.js @@ -8,9 +8,7 @@ class List { var List = (function () { function List() { } - List.empty = function () { - return null; - }; + List.empty = function () { return null; }; return List; })(); diff --git a/tests/baselines/reference/noImplicitAnyForIn.js b/tests/baselines/reference/noImplicitAnyForIn.js index 067a553e2d..c8743936a9 100644 --- a/tests/baselines/reference/noImplicitAnyForIn.js +++ b/tests/baselines/reference/noImplicitAnyForIn.js @@ -32,16 +32,7 @@ var n = [[]] || []; for (n[idx++] in m); //// [noImplicitAnyForIn.js] -var x = [ - [ - 1, - 2, - 3 - ], - [ - "hello" - ] -]; +var x = [[1, 2, 3], ["hello"]]; for (var i in x) { for (var j in x[i]) { //Should yield an implicit 'any' error @@ -59,16 +50,8 @@ for (var a in x) { var c = a || b; } var idx = 0; -var m = [ - 1, - 2, - 3, - 4, - 5 -]; +var m = [1, 2, 3, 4, 5]; // Should yield an implicit 'any' error. -var n = [ - [] -] || []; +var n = [[]] || []; for (n[idx++] in m) ; diff --git a/tests/baselines/reference/noImplicitAnyForMethodParameters.js b/tests/baselines/reference/noImplicitAnyForMethodParameters.js index 379cf85b5e..fc5b94d476 100644 --- a/tests/baselines/reference/noImplicitAnyForMethodParameters.js +++ b/tests/baselines/reference/noImplicitAnyForMethodParameters.js @@ -18,14 +18,12 @@ class D { var C = (function () { function C() { } - C.prototype.foo = function (a) { - }; // OK - non-ambient class and private method - error + C.prototype.foo = function (a) { }; // OK - non-ambient class and private method - error return C; })(); var D = (function () { function D() { } - D.prototype.foo = function (a) { - }; // OK - non-ambient class and public method - error + D.prototype.foo = function (a) { }; // OK - non-ambient class and public method - error return D; })(); diff --git a/tests/baselines/reference/noImplicitAnyInCastExpression.js b/tests/baselines/reference/noImplicitAnyInCastExpression.js index 4e23b91527..1b7cc59c7c 100644 --- a/tests/baselines/reference/noImplicitAnyInCastExpression.js +++ b/tests/baselines/reference/noImplicitAnyInCastExpression.js @@ -19,15 +19,8 @@ interface IFoo { //// [noImplicitAnyInCastExpression.js] // verify no noImplictAny errors reported with cast expression // Expr type not assignable to target type -{ - a: null -}; +{ a: null }; // Expr type assignable to target type -{ - a: 2, - b: undefined -}; +{ a: 2, b: undefined }; // Neither types is assignable to each other -{ - c: null -}; +{ c: null }; diff --git a/tests/baselines/reference/noImplicitAnyInContextuallyTypesFunctionParamter.js b/tests/baselines/reference/noImplicitAnyInContextuallyTypesFunctionParamter.js index f14810c801..7722165fd2 100644 --- a/tests/baselines/reference/noImplicitAnyInContextuallyTypesFunctionParamter.js +++ b/tests/baselines/reference/noImplicitAnyInContextuallyTypesFunctionParamter.js @@ -5,10 +5,5 @@ regexMatchList.forEach(match => ''.replace(match, '')); //// [noImplicitAnyInContextuallyTypesFunctionParamter.js] -var regexMatchList = [ - '', - '' -]; -regexMatchList.forEach(function (match) { - return ''.replace(match, ''); -}); +var regexMatchList = ['', '']; +regexMatchList.forEach(function (match) { return ''.replace(match, ''); }); diff --git a/tests/baselines/reference/noImplicitAnyParametersInBareFunctions.js b/tests/baselines/reference/noImplicitAnyParametersInBareFunctions.js index 6be6170214..8efe32d314 100644 --- a/tests/baselines/reference/noImplicitAnyParametersInBareFunctions.js +++ b/tests/baselines/reference/noImplicitAnyParametersInBareFunctions.js @@ -46,20 +46,15 @@ var f14 = (x, ...r) => ""; //// [noImplicitAnyParametersInBareFunctions.js] // No implicit-'any' errors. -function f1() { -} +function f1() { } // Implicit-'any' error for x. -function f2(x) { -} +function f2(x) { } // No implicit-'any' errors. -function f3(x) { -} +function f3(x) { } // Implicit-'any' errors for x, y, and z. -function f4(x, y, z) { -} +function f4(x, y, z) { } // Implicit-'any' errors for x, and z. -function f5(x, y, z) { -} +function f5(x, y, z) { } // Implicit-'any[]' error for r. function f6() { var r = []; @@ -74,24 +69,15 @@ function f7(x) { r[_i - 1] = arguments[_i]; } } -function f8(x3, y3) { -} +function f8(x3, y3) { } // No implicit-'any' errors. -var f9 = function () { - return ""; -}; +var f9 = function () { return ""; }; // Implicit-'any' errors for x. -var f10 = function (x) { - return ""; -}; +var f10 = function (x) { return ""; }; // Implicit-'any' errors for x, y, and z. -var f11 = function (x, y, z) { - return ""; -}; +var f11 = function (x, y, z) { return ""; }; // Implicit-'any' errors for x and z. -var f12 = function (x, y, z) { - return ""; -}; +var f12 = function (x, y, z) { return ""; }; // Implicit-'any[]' error for r. var f13 = function () { var r = []; diff --git a/tests/baselines/reference/noImplicitAnyParametersInClass.js b/tests/baselines/reference/noImplicitAnyParametersInClass.js index 1460d07b72..0873935b60 100644 --- a/tests/baselines/reference/noImplicitAnyParametersInClass.js +++ b/tests/baselines/reference/noImplicitAnyParametersInClass.js @@ -96,21 +96,13 @@ class C { var C = (function () { function C() { // No implicit-'any' errors. - this.pub_f9 = function () { - return ""; - }; + this.pub_f9 = function () { return ""; }; // Implicit-'any' errors for x. - this.pub_f10 = function (x) { - return ""; - }; + this.pub_f10 = function (x) { return ""; }; // Implicit-'any' errors for x, y, and z. - this.pub_f11 = function (x, y, z) { - return ""; - }; + this.pub_f11 = function (x, y, z) { return ""; }; // Implicit-'any' errors for x and z. - this.pub_f12 = function (x, y, z) { - return ""; - }; + this.pub_f12 = function (x, y, z) { return ""; }; // Implicit-'any[]' error for r. this.pub_f13 = function () { var r = []; @@ -128,21 +120,13 @@ var C = (function () { return ""; }; // No implicit-'any' errors. - this.priv_f9 = function () { - return ""; - }; + this.priv_f9 = function () { return ""; }; // Implicit-'any' errors for x. - this.priv_f10 = function (x) { - return ""; - }; + this.priv_f10 = function (x) { return ""; }; // Implicit-'any' errors for x, y, and z. - this.priv_f11 = function (x, y, z) { - return ""; - }; + this.priv_f11 = function (x, y, z) { return ""; }; // Implicit-'any' errors for x and z. - this.priv_f12 = function (x, y, z) { - return ""; - }; + this.priv_f12 = function (x, y, z) { return ""; }; // Implicit-'any[]' error for r. this.priv_f13 = function () { var r = []; @@ -161,20 +145,15 @@ var C = (function () { }; } // No implicit-'any' errors. - C.prototype.pub_f1 = function () { - }; + C.prototype.pub_f1 = function () { }; // Implicit-'any' errors for x. - C.prototype.pub_f2 = function (x) { - }; + C.prototype.pub_f2 = function (x) { }; // No implicit-'any' errors. - C.prototype.pub_f3 = function (x) { - }; + C.prototype.pub_f3 = function (x) { }; // Implicit-'any' errors for x, y, and z. - C.prototype.pub_f4 = function (x, y, z) { - }; + C.prototype.pub_f4 = function (x, y, z) { }; // Implicit-'any' errors for x, and z. - C.prototype.pub_f5 = function (x, y, z) { - }; + C.prototype.pub_f5 = function (x, y, z) { }; // Implicit-'any[]' errors for r. C.prototype.pub_f6 = function () { var r = []; @@ -189,24 +168,18 @@ var C = (function () { r[_i - 1] = arguments[_i]; } }; - C.prototype.pub_f8 = function (x3, y3) { - }; + C.prototype.pub_f8 = function (x3, y3) { }; /////////////////////////////////////////// // No implicit-'any' errors. - C.prototype.priv_f1 = function () { - }; + C.prototype.priv_f1 = function () { }; // Implicit-'any' errors for x. - C.prototype.priv_f2 = function (x) { - }; + C.prototype.priv_f2 = function (x) { }; // No implicit-'any' errors. - C.prototype.priv_f3 = function (x) { - }; + C.prototype.priv_f3 = function (x) { }; // Implicit-'any' errors for x, y, and z. - C.prototype.priv_f4 = function (x, y, z) { - }; + C.prototype.priv_f4 = function (x, y, z) { }; // Implicit-'any' errors for x, and z. - C.prototype.priv_f5 = function (x, y, z) { - }; + C.prototype.priv_f5 = function (x, y, z) { }; // Implicit-'any[]' errors for r. C.prototype.priv_f6 = function () { var r = []; @@ -221,7 +194,6 @@ var C = (function () { r[_i - 1] = arguments[_i]; } }; - C.prototype.priv_f8 = function (x3, y3) { - }; + C.prototype.priv_f8 = function (x3, y3) { }; return C; })(); diff --git a/tests/baselines/reference/noImplicitAnyParametersInModule.js b/tests/baselines/reference/noImplicitAnyParametersInModule.js index d89c4229c7..e7f3020555 100644 --- a/tests/baselines/reference/noImplicitAnyParametersInModule.js +++ b/tests/baselines/reference/noImplicitAnyParametersInModule.js @@ -50,20 +50,15 @@ module M { var M; (function (M) { // No implicit-'any' errors. - function m_f1() { - } + function m_f1() { } // Implicit-'any' error for x. - function m_f2(x) { - } + function m_f2(x) { } // No implicit-'any' errors. - function m_f3(x) { - } + function m_f3(x) { } // Implicit-'any' errors for x, y, and z. - function m_f4(x, y, z) { - } + function m_f4(x, y, z) { } // Implicit-'any' errors for x and z. - function m_f5(x, y, z) { - } + function m_f5(x, y, z) { } // Implicit-'any[]' error for r. function m_f6() { var r = []; @@ -78,24 +73,15 @@ var M; r[_i - 1] = arguments[_i]; } } - function m_f8(x3, y3) { - } + function m_f8(x3, y3) { } // No implicit-'any' errors. - var m_f9 = function () { - return ""; - }; + var m_f9 = function () { return ""; }; // Implicit-'any' error for x. - var m_f10 = function (x) { - return ""; - }; + var m_f10 = function (x) { return ""; }; // Implicit-'any' errors for x, y, and z. - var m_f11 = function (x, y, z) { - return ""; - }; + var m_f11 = function (x, y, z) { return ""; }; // Implicit-'any' errors for x and z. - var m_f12 = function (x, y, z) { - return ""; - }; + var m_f12 = function (x, y, z) { return ""; }; // Implicit-'any[]' errors for r. var m_f13 = function () { var r = []; diff --git a/tests/baselines/reference/noImplicitAnyWithOverloads.js b/tests/baselines/reference/noImplicitAnyWithOverloads.js index 3bce6e18ba..fd56b6e0d7 100644 --- a/tests/baselines/reference/noImplicitAnyWithOverloads.js +++ b/tests/baselines/reference/noImplicitAnyWithOverloads.js @@ -10,8 +10,5 @@ function callb(a) { } callb((a) => { a.foo; }); // error, chose first overload //// [noImplicitAnyWithOverloads.js] -function callb(a) { -} -callb(function (a) { - a.foo; -}); // error, chose first overload +function callb(a) { } +callb(function (a) { a.foo; }); // error, chose first overload diff --git a/tests/baselines/reference/noSelfOnVars.js b/tests/baselines/reference/noSelfOnVars.js index 2e1f5080c2..913e3a23ba 100644 --- a/tests/baselines/reference/noSelfOnVars.js +++ b/tests/baselines/reference/noSelfOnVars.js @@ -9,7 +9,6 @@ function foo() { //// [noSelfOnVars.js] function foo() { - function bar() { - } + function bar() { } var x = bar; } diff --git a/tests/baselines/reference/nonInstantiatedModule.js b/tests/baselines/reference/nonInstantiatedModule.js index ff7ea10358..fc3ad19546 100644 --- a/tests/baselines/reference/nonInstantiatedModule.js +++ b/tests/baselines/reference/nonInstantiatedModule.js @@ -62,10 +62,7 @@ var M2; var Point; (function (Point) { function Origin() { - return { - x: 0, - y: 0 - }; + return { x: 0, y: 0 }; } Point.Origin = Origin; })(Point = M2.Point || (M2.Point = {})); diff --git a/tests/baselines/reference/null.js b/tests/baselines/reference/null.js index c82cb3ab43..499d690184 100644 --- a/tests/baselines/reference/null.js +++ b/tests/baselines/reference/null.js @@ -38,7 +38,4 @@ function g() { return null; return 3; } -var w = { - x: null, - y: 3 -}; +var w = { x: null, y: 3 }; diff --git a/tests/baselines/reference/nullIsSubtypeOfEverythingButUndefined.js b/tests/baselines/reference/nullIsSubtypeOfEverythingButUndefined.js index b47a591444..646a347453 100644 --- a/tests/baselines/reference/nullIsSubtypeOfEverythingButUndefined.js +++ b/tests/baselines/reference/nullIsSubtypeOfEverythingButUndefined.js @@ -108,22 +108,12 @@ var r4 = true ? new Date() : null; var r4 = true ? null : new Date(); var r5 = true ? /1/ : null; var r5 = true ? null : /1/; -var r6 = true ? { - foo: 1 -} : null; -var r6 = true ? null : { - foo: 1 -}; -var r7 = true ? function () { -} : null; -var r7 = true ? null : function () { -}; -var r8 = true ? function (x) { - return x; -} : null; -var r8b = true ? null : function (x) { - return x; -}; // type parameters not identical across declarations +var r6 = true ? { foo: 1 } : null; +var r6 = true ? null : { foo: 1 }; +var r7 = true ? function () { } : null; +var r7 = true ? null : function () { }; +var r8 = true ? function (x) { return x; } : null; +var r8b = true ? null : function (x) { return x; }; // type parameters not identical across declarations var i1; var r9 = true ? i1 : null; var r9 = true ? null : i1; @@ -151,8 +141,7 @@ var r13 = true ? E : null; var r13 = true ? null : E; var r14 = true ? E.A : null; var r14 = true ? null : E.A; -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; diff --git a/tests/baselines/reference/numberAsInLHS.js b/tests/baselines/reference/numberAsInLHS.js index bcc1bcf7b8..d2fee353ab 100644 --- a/tests/baselines/reference/numberAsInLHS.js +++ b/tests/baselines/reference/numberAsInLHS.js @@ -2,7 +2,4 @@ 3 in [0, 1] //// [numberAsInLHS.js] -3 in [ - 0, - 1 -]; +3 in [0, 1]; diff --git a/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations.js b/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations.js index 339f674b9d..cf08bb9821 100644 --- a/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations.js +++ b/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations.js @@ -106,8 +106,7 @@ var C = (function () { get: function () { return ''; }, - set: function (v) { - } // ok + set: function (v) { } // ok , enumerable: true, configurable: true @@ -115,8 +114,7 @@ var C = (function () { C.prototype.foo = function () { return ''; }; - C.foo = function () { - }; // ok + C.foo = function () { }; // ok Object.defineProperty(C, "X", { get: function () { return 1; @@ -131,8 +129,7 @@ var a; var b = { a: '', b: 1, - c: function () { - }, + c: function () { }, "d": '', "e": 1, 1.0: '', @@ -143,8 +140,7 @@ var b = { get X() { return ''; }, - set X(v) { - }, + set X(v) { }, foo: function () { return ''; } diff --git a/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations2.js b/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations2.js index 1cfd94a0c9..0474abef39 100644 --- a/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations2.js +++ b/tests/baselines/reference/numericIndexerConstrainsPropertyDeclarations2.js @@ -56,9 +56,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - return ''; - }; + A.prototype.foo = function () { return ''; }; return A; })(); var B = (function (_super) { @@ -66,9 +64,7 @@ var B = (function (_super) { function B() { _super.apply(this, arguments); } - B.prototype.bar = function () { - return ''; - }; + B.prototype.bar = function () { return ''; }; return B; })(A); var Foo = (function () { diff --git a/tests/baselines/reference/numericIndexerConstraint1.js b/tests/baselines/reference/numericIndexerConstraint1.js index 9587863a03..ed51e3af06 100644 --- a/tests/baselines/reference/numericIndexerConstraint1.js +++ b/tests/baselines/reference/numericIndexerConstraint1.js @@ -8,8 +8,7 @@ var result: Foo = x["one"]; // error var Foo = (function () { function Foo() { } - Foo.prototype.foo = function () { - }; + Foo.prototype.foo = function () { }; return Foo; })(); var x; diff --git a/tests/baselines/reference/numericIndexerConstraint2.js b/tests/baselines/reference/numericIndexerConstraint2.js index edc9df36a1..4d8ce742e7 100644 --- a/tests/baselines/reference/numericIndexerConstraint2.js +++ b/tests/baselines/reference/numericIndexerConstraint2.js @@ -8,8 +8,7 @@ x = a; var Foo = (function () { function Foo() { } - Foo.prototype.foo = function () { - }; + Foo.prototype.foo = function () { }; return Foo; })(); var x; diff --git a/tests/baselines/reference/numericIndexerConstraint4.js b/tests/baselines/reference/numericIndexerConstraint4.js index cbbf6b68c4..531c450e7e 100644 --- a/tests/baselines/reference/numericIndexerConstraint4.js +++ b/tests/baselines/reference/numericIndexerConstraint4.js @@ -30,6 +30,4 @@ var B = (function (_super) { } return B; })(A); -var x = { - data: new B() -}; +var x = { data: new B() }; diff --git a/tests/baselines/reference/numericIndexerConstraint5.js b/tests/baselines/reference/numericIndexerConstraint5.js index b068445439..3ad19f75d0 100644 --- a/tests/baselines/reference/numericIndexerConstraint5.js +++ b/tests/baselines/reference/numericIndexerConstraint5.js @@ -3,8 +3,5 @@ var x = { name: "x", 0: new Date() }; var z: { [name: number]: string } = x; //// [numericIndexerConstraint5.js] -var x = { - name: "x", - 0: new Date() -}; +var x = { name: "x", 0: new Date() }; var z = x; diff --git a/tests/baselines/reference/numericIndexingResults.js b/tests/baselines/reference/numericIndexingResults.js index 043bf3265e..70c6e15d15 100644 --- a/tests/baselines/reference/numericIndexingResults.js +++ b/tests/baselines/reference/numericIndexingResults.js @@ -85,20 +85,14 @@ var r3 = a['3']; var r4 = a[1]; var r5 = a[2]; var r6 = a[3]; -var b = { - 1: '', - "2": '' -}; +var b = { 1: '', "2": '' }; var r1a = b['1']; var r2a = b['2']; var r3 = b['3']; var r4 = b[1]; var r5 = b[2]; var r6 = b[3]; -var b2 = { - 1: '', - "2": '' -}; +var b2 = { 1: '', "2": '' }; var r1b = b2['1']; var r2b = b2['2']; var r3 = b2['3']; diff --git a/tests/baselines/reference/objectLitIndexerContextualType.js b/tests/baselines/reference/objectLitIndexerContextualType.js index a6124814cf..f0cf90724b 100644 --- a/tests/baselines/reference/objectLitIndexerContextualType.js +++ b/tests/baselines/reference/objectLitIndexerContextualType.js @@ -26,22 +26,14 @@ y = { var x; var y; x = { - s: function (t) { - return t * t; - } + s: function (t) { return t * t; } }; x = { - 0: function (t) { - return t * t; - } + 0: function (t) { return t * t; } }; y = { - s: function (t) { - return t * t; - } + s: function (t) { return t * t; } }; y = { - 0: function (t) { - return t * t; - } + 0: function (t) { return t * t; } }; diff --git a/tests/baselines/reference/objectLitStructuralTypeMismatch.js b/tests/baselines/reference/objectLitStructuralTypeMismatch.js index c24f742f08..380b8a2aac 100644 --- a/tests/baselines/reference/objectLitStructuralTypeMismatch.js +++ b/tests/baselines/reference/objectLitStructuralTypeMismatch.js @@ -4,6 +4,4 @@ var x: { a: number; } = { b: 5 }; //// [objectLitStructuralTypeMismatch.js] // Shouldn't compile -var x = { - b: 5 -}; +var x = { b: 5 }; diff --git a/tests/baselines/reference/objectLitTargetTypeCallSite.js b/tests/baselines/reference/objectLitTargetTypeCallSite.js index 76cd4c660d..999b889e41 100644 --- a/tests/baselines/reference/objectLitTargetTypeCallSite.js +++ b/tests/baselines/reference/objectLitTargetTypeCallSite.js @@ -9,7 +9,4 @@ process({a:true,b:"y"}); function process(x) { return x.a; } -process({ - a: true, - b: "y" -}); +process({ a: true, b: "y" }); diff --git a/tests/baselines/reference/objectLiteral1.js b/tests/baselines/reference/objectLiteral1.js index 7d625c8e81..ebeabd011b 100644 --- a/tests/baselines/reference/objectLiteral1.js +++ b/tests/baselines/reference/objectLiteral1.js @@ -2,7 +2,4 @@ var v30 = {a:1, b:2}; //// [objectLiteral1.js] -var v30 = { - a: 1, - b: 2 -}; +var v30 = { a: 1, b: 2 }; diff --git a/tests/baselines/reference/objectLiteral2.js b/tests/baselines/reference/objectLiteral2.js index b517d99b05..189e495c5f 100644 --- a/tests/baselines/reference/objectLiteral2.js +++ b/tests/baselines/reference/objectLiteral2.js @@ -2,7 +2,4 @@ var v30 = {a:1, b:2}, v31; //// [objectLiteral2.js] -var v30 = { - a: 1, - b: 2 -}, v31; +var v30 = { a: 1, b: 2 }, v31; diff --git a/tests/baselines/reference/objectLiteralArraySpecialization.js b/tests/baselines/reference/objectLiteralArraySpecialization.js index 9f704adba0..0a48a3dccd 100644 --- a/tests/baselines/reference/objectLiteralArraySpecialization.js +++ b/tests/baselines/reference/objectLiteralArraySpecialization.js @@ -9,16 +9,5 @@ thing.doSomething((x, y) => x.name === "bob"); // should not error //// [objectLiteralArraySpecialization.js] -var thing = create([ - { - name: "bob", - id: 24 - }, - { - name: "doug", - id: 32 - } -]); // should not error -thing.doSomething(function (x, y) { - return x.name === "bob"; -}); // should not error +var thing = create([{ name: "bob", id: 24 }, { name: "doug", id: 32 }]); // should not error +thing.doSomething(function (x, y) { return x.name === "bob"; }); // should not error diff --git a/tests/baselines/reference/objectLiteralContextualTyping.js b/tests/baselines/reference/objectLiteralContextualTyping.js index c61452c205..4868604275 100644 --- a/tests/baselines/reference/objectLiteralContextualTyping.js +++ b/tests/baselines/reference/objectLiteralContextualTyping.js @@ -29,23 +29,13 @@ var b: {}; //// [objectLiteralContextualTyping.js] // Tests related to #1774 -var x = foo({ - name: "Sprocket" -}); +var x = foo({ name: "Sprocket" }); var x; -var y = foo({ - name: "Sprocket", - description: "Bumpy wheel" -}); +var y = foo({ name: "Sprocket", description: "Bumpy wheel" }); var y; -var z = foo({ - name: "Sprocket", - description: false -}); +var z = foo({ name: "Sprocket", description: false }); var z; -var w = foo({ - a: 10 -}); +var w = foo({ a: 10 }); var w; var b = bar({}); var b; diff --git a/tests/baselines/reference/objectLiteralErrors.js b/tests/baselines/reference/objectLiteralErrors.js index ac1ab2ec10..4dccc78b67 100644 --- a/tests/baselines/reference/objectLiteralErrors.js +++ b/tests/baselines/reference/objectLiteralErrors.js @@ -48,210 +48,44 @@ var g3 = { get a(): number { return undefined; }, set a(n: string) { } }; //// [objectLiteralErrors.js] // Multiple properties with the same name -var e1 = { - a: 0, - a: 0 -}; -var e2 = { - a: '', - a: '' -}; -var e3 = { - a: 0, - a: '' -}; -var e4 = { - a: true, - a: false -}; -var e5 = { - a: {}, - a: {} -}; -var e6 = { - a: 0, - 'a': 0 -}; -var e7 = { - 'a': 0, - a: 0 -}; -var e8 = { - 'a': 0, - "a": 0 -}; -var e9 = { - 'a': 0, - 'a': 0 -}; -var e10 = { - "a": 0, - 'a': 0 -}; -var e11 = { - 1.0: 0, - '1': 0 -}; -var e12 = { - 0: 0, - 0: 0 -}; -var e13 = { - 0: 0, - 0: 0 -}; -var e14 = { - 0: 0, - 0x0: 0 -}; -var e14 = { - 0: 0, - 000: 0 -}; -var e15 = { - "100": 0, - 1e2: 0 -}; -var e16 = { - 0x20: 0, - 3.2e1: 0 -}; -var e17 = { - a: 0, - b: 1, - a: 0 -}; +var e1 = { a: 0, a: 0 }; +var e2 = { a: '', a: '' }; +var e3 = { a: 0, a: '' }; +var e4 = { a: true, a: false }; +var e5 = { a: {}, a: {} }; +var e6 = { a: 0, 'a': 0 }; +var e7 = { 'a': 0, a: 0 }; +var e8 = { 'a': 0, "a": 0 }; +var e9 = { 'a': 0, 'a': 0 }; +var e10 = { "a": 0, 'a': 0 }; +var e11 = { 1.0: 0, '1': 0 }; +var e12 = { 0: 0, 0: 0 }; +var e13 = { 0: 0, 0: 0 }; +var e14 = { 0: 0, 0x0: 0 }; +var e14 = { 0: 0, 000: 0 }; +var e15 = { "100": 0, 1e2: 0 }; +var e16 = { 0x20: 0, 3.2e1: 0 }; +var e17 = { a: 0, b: 1, a: 0 }; // Accessor and property with the same name -var f1 = { - a: 0, - get a() { - return 0; - } -}; -var f2 = { - a: '', - get a() { - return ''; - } -}; -var f3 = { - a: 0, - get a() { - return ''; - } -}; -var f4 = { - a: true, - get a() { - return false; - } -}; -var f5 = { - a: {}, - get a() { - return {}; - } -}; -var f6 = { - a: 0, - get 'a'() { - return 0; - } -}; -var f7 = { - 'a': 0, - get a() { - return 0; - } -}; -var f8 = { - 'a': 0, - get "a"() { - return 0; - } -}; -var f9 = { - 'a': 0, - get 'a'() { - return 0; - } -}; -var f10 = { - "a": 0, - get 'a'() { - return 0; - } -}; -var f11 = { - 1.0: 0, - get '1'() { - return 0; - } -}; -var f12 = { - 0: 0, - get 0() { - return 0; - } -}; -var f13 = { - 0: 0, - get 0() { - return 0; - } -}; -var f14 = { - 0: 0, - get 0x0() { - return 0; - } -}; -var f14 = { - 0: 0, - get 000() { - return 0; - } -}; -var f15 = { - "100": 0, - get 1e2() { - return 0; - } -}; -var f16 = { - 0x20: 0, - get 3.2e1() { - return 0; - } -}; -var f17 = { - a: 0, - get b() { - return 1; - }, - get a() { - return 0; - } -}; +var f1 = { a: 0, get a() { return 0; } }; +var f2 = { a: '', get a() { return ''; } }; +var f3 = { a: 0, get a() { return ''; } }; +var f4 = { a: true, get a() { return false; } }; +var f5 = { a: {}, get a() { return {}; } }; +var f6 = { a: 0, get 'a'() { return 0; } }; +var f7 = { 'a': 0, get a() { return 0; } }; +var f8 = { 'a': 0, get "a"() { return 0; } }; +var f9 = { 'a': 0, get 'a'() { return 0; } }; +var f10 = { "a": 0, get 'a'() { return 0; } }; +var f11 = { 1.0: 0, get '1'() { return 0; } }; +var f12 = { 0: 0, get 0() { return 0; } }; +var f13 = { 0: 0, get 0() { return 0; } }; +var f14 = { 0: 0, get 0x0() { return 0; } }; +var f14 = { 0: 0, get 000() { return 0; } }; +var f15 = { "100": 0, get 1e2() { return 0; } }; +var f16 = { 0x20: 0, get 3.2e1() { return 0; } }; +var f17 = { a: 0, get b() { return 1; }, get a() { return 0; } }; // Get and set accessor with mismatched type annotations -var g1 = { - get a() { - return 4; - }, - set a(n) { - } -}; -var g2 = { - get a() { - return 4; - }, - set a(n) { - } -}; -var g3 = { - get a() { - return undefined; - }, - set a(n) { - } -}; +var g1 = { get a() { return 4; }, set a(n) { } }; +var g2 = { get a() { return 4; }, set a(n) { } }; +var g3 = { get a() { return undefined; }, set a(n) { } }; diff --git a/tests/baselines/reference/objectLiteralErrorsES3.js b/tests/baselines/reference/objectLiteralErrorsES3.js index f2910c37c3..031a68fd10 100644 --- a/tests/baselines/reference/objectLiteralErrorsES3.js +++ b/tests/baselines/reference/objectLiteralErrorsES3.js @@ -7,19 +7,6 @@ var e3 = { get a() { return ''; }, set a(n) { } }; //// [objectLiteralErrorsES3.js] -var e1 = { - get a() { - return 4; - } -}; -var e2 = { - set a(n) { - } -}; -var e3 = { - get a() { - return ''; - }, - set a(n) { - } -}; +var e1 = { get a() { return 4; } }; +var e2 = { set a(n) { } }; +var e3 = { get a() { return ''; }, set a(n) { } }; diff --git a/tests/baselines/reference/objectLiteralFunctionArgContextualTyping.js b/tests/baselines/reference/objectLiteralFunctionArgContextualTyping.js index b0f18da34d..7f9bdc5c54 100644 --- a/tests/baselines/reference/objectLiteralFunctionArgContextualTyping.js +++ b/tests/baselines/reference/objectLiteralFunctionArgContextualTyping.js @@ -14,31 +14,10 @@ f2({ toString: (s: string) => s }) // error, missing property value from ArgsStr f2({ value: '', toString: (s) => s.uhhh }) // error //// [objectLiteralFunctionArgContextualTyping.js] -function f2(args) { -} -f2({ - hello: 1 -}); // error -f2({ - value: '' -}); // missing toString satisfied by Object's member -f2({ - value: '', - what: 1 -}); // missing toString satisfied by Object's member -f2({ - toString: function (s) { - return s; - } -}); // error, missing property value from ArgsString -f2({ - toString: function (s) { - return s; - } -}); // error, missing property value from ArgsString -f2({ - value: '', - toString: function (s) { - return s.uhhh; - } -}); // error +function f2(args) { } +f2({ hello: 1 }); // error +f2({ value: '' }); // missing toString satisfied by Object's member +f2({ value: '', what: 1 }); // missing toString satisfied by Object's member +f2({ toString: function (s) { return s; } }); // error, missing property value from ArgsString +f2({ toString: function (s) { return s; } }); // error, missing property value from ArgsString +f2({ value: '', toString: function (s) { return s.uhhh; } }); // error diff --git a/tests/baselines/reference/objectLiteralFunctionArgContextualTyping2.js b/tests/baselines/reference/objectLiteralFunctionArgContextualTyping2.js index 73d22c8dd5..96d1106e1f 100644 --- a/tests/baselines/reference/objectLiteralFunctionArgContextualTyping2.js +++ b/tests/baselines/reference/objectLiteralFunctionArgContextualTyping2.js @@ -14,31 +14,10 @@ f2({ toString: (s: string) => s }) f2({ value: '', toString: (s) => s.uhhh }) //// [objectLiteralFunctionArgContextualTyping2.js] -function f2(args) { -} -f2({ - hello: 1 -}); -f2({ - value: '' -}); -f2({ - value: '', - what: 1 -}); -f2({ - toString: function (s) { - return s; - } -}); -f2({ - toString: function (s) { - return s; - } -}); -f2({ - value: '', - toString: function (s) { - return s.uhhh; - } -}); +function f2(args) { } +f2({ hello: 1 }); +f2({ value: '' }); +f2({ value: '', what: 1 }); +f2({ toString: function (s) { return s; } }); +f2({ toString: function (s) { return s; } }); +f2({ value: '', toString: function (s) { return s.uhhh; } }); diff --git a/tests/baselines/reference/objectLiteralGettersAndSetters.js b/tests/baselines/reference/objectLiteralGettersAndSetters.js index bdaf0966e1..d226c2c556 100644 --- a/tests/baselines/reference/objectLiteralGettersAndSetters.js +++ b/tests/baselines/reference/objectLiteralGettersAndSetters.js @@ -85,139 +85,40 @@ var getParamType3 = { //// [objectLiteralGettersAndSetters.js] // Get and set accessor with the same name -var sameName1a = { - get 'a'() { - return ''; - }, - set a(n) { - var p = n; - var p; - } -}; -var sameName2a = { - get 0.0() { - return ''; - }, - set 0(n) { - var p = n; - var p; - } -}; -var sameName3a = { - get 0x20() { - return ''; - }, - set 3.2e1(n) { - var p = n; - var p; - } -}; -var sameName4a = { - get ''() { - return ''; - }, - set ""(n) { - var p = n; - var p; - } -}; -var sameName5a = { - get '\t'() { - return ''; - }, - set '\t'(n) { - var p = n; - var p; - } -}; -var sameName6a = { - get 'a'() { - return ''; - }, - set a(n) { - var p = n; - var p; - } -}; +var sameName1a = { get 'a'() { return ''; }, set a(n) { var p = n; var p; } }; +var sameName2a = { get 0.0() { return ''; }, set 0(n) { var p = n; var p; } }; +var sameName3a = { get 0x20() { return ''; }, set 3.2e1(n) { var p = n; var p; } }; +var sameName4a = { get ''() { return ''; }, set ""(n) { var p = n; var p; } }; +var sameName5a = { get '\t'() { return ''; }, set '\t'(n) { var p = n; var p; } }; +var sameName6a = { get 'a'() { return ''; }, set a(n) { var p = n; var p; } }; // PropertyName CallSignature{FunctionBody} is equivalent to PropertyName:function CallSignature{FunctionBody} -var callSig1 = { - num: function (n) { - return ''; - } -}; +var callSig1 = { num: function (n) { return ''; } }; var callSig1; -var callSig2 = { - num: function (n) { - return ''; - } -}; +var callSig2 = { num: function (n) { return ''; } }; var callSig2; -var callSig3 = { - num: function (n) { - return ''; - } -}; +var callSig3 = { num: function (n) { return ''; } }; var callSig3; // Get accessor only, type of the property is the annotated return type of the get accessor -var getter1 = { - get x() { - return undefined; - } -}; +var getter1 = { get x() { return undefined; } }; var getter1; // Get accessor only, type of the property is the inferred return type of the get accessor -var getter2 = { - get x() { - return ''; - } -}; +var getter2 = { get x() { return ''; } }; var getter2; // Set accessor only, type of the property is the param type of the set accessor -var setter1 = { - set x(n) { - } -}; +var setter1 = { set x(n) { } }; var setter1; // Set accessor only, type of the property is Any for an unannotated set accessor -var setter2 = { - set x(n) { - } -}; +var setter2 = { set x(n) { } }; var setter2; var anyVar; // Get and set accessor with matching type annotations -var sameType1 = { - get x() { - return undefined; - }, - set x(n) { - } -}; -var sameType2 = { - get x() { - return undefined; - }, - set x(n) { - } -}; -var sameType3 = { - get x() { - return undefined; - }, - set x(n) { - } -}; -var sameType4 = { - get x() { - return undefined; - }, - set x(n) { - } -}; +var sameType1 = { get x() { return undefined; }, set x(n) { } }; +var sameType2 = { get x() { return undefined; }, set x(n) { } }; +var sameType3 = { get x() { return undefined; }, set x(n) { } }; +var sameType4 = { get x() { return undefined; }, set x(n) { } }; // Type of unannotated get accessor return type is the type annotation of the set accessor param var setParamType1 = { - set n(x) { - }, + set n(x) { }, get n() { return function (t) { var p; @@ -232,8 +133,7 @@ var setParamType2 = { var p = t; }; }, - set n(x) { - } + set n(x) { } }; // Type of unannotated set accessor parameter is the return type annotation of the get accessor var getParamType1 = { @@ -241,14 +141,10 @@ var getParamType1 = { var y = x; var y; }, - get n() { - return ''; - } + get n() { return ''; } }; var getParamType2 = { - get n() { - return ''; - }, + get n() { return ''; }, set n(x) { var y = x; var y; @@ -256,9 +152,7 @@ var getParamType2 = { }; // Type of unannotated accessors is the inferred return type of the get accessor var getParamType3 = { - get n() { - return ''; - }, + get n() { return ''; }, set n(x) { var y = x; var y; diff --git a/tests/baselines/reference/objectLiteralIndexerErrors.js b/tests/baselines/reference/objectLiteralIndexerErrors.js index 2c61974309..5e0159015d 100644 --- a/tests/baselines/reference/objectLiteralIndexerErrors.js +++ b/tests/baselines/reference/objectLiteralIndexerErrors.js @@ -18,11 +18,5 @@ o1 = { x: c, 0: a }; // string indexer is any, number indexer is A var a; var b; var c; -var o1 = { - x: b, - 0: a -}; // both indexers are A -o1 = { - x: c, - 0: a -}; // string indexer is any, number indexer is A +var o1 = { x: b, 0: a }; // both indexers are A +o1 = { x: c, 0: a }; // string indexer is any, number indexer is A diff --git a/tests/baselines/reference/objectLiteralIndexers.js b/tests/baselines/reference/objectLiteralIndexers.js index 97bb3ee78c..c36cbfc757 100644 --- a/tests/baselines/reference/objectLiteralIndexers.js +++ b/tests/baselines/reference/objectLiteralIndexers.js @@ -19,15 +19,6 @@ o1 = { x: c, 0: b }; // string indexer is any, number indexer is B var a; var b; var c; -var o1 = { - x: a, - 0: b -}; // string indexer is A, number indexer is B -o1 = { - x: b, - 0: c -}; // both indexers are any -o1 = { - x: c, - 0: b -}; // string indexer is any, number indexer is B +var o1 = { x: a, 0: b }; // string indexer is A, number indexer is B +o1 = { x: b, 0: c }; // both indexers are any +o1 = { x: c, 0: b }; // string indexer is any, number indexer is B diff --git a/tests/baselines/reference/objectLiteralMemberWithModifiers1.js b/tests/baselines/reference/objectLiteralMemberWithModifiers1.js index 998bc29274..a4389d49bd 100644 --- a/tests/baselines/reference/objectLiteralMemberWithModifiers1.js +++ b/tests/baselines/reference/objectLiteralMemberWithModifiers1.js @@ -2,7 +2,4 @@ var v = { public foo() { } } //// [objectLiteralMemberWithModifiers1.js] -var v = { - foo: function () { - } -}; +var v = { foo: function () { } }; diff --git a/tests/baselines/reference/objectLiteralMemberWithModifiers2.js b/tests/baselines/reference/objectLiteralMemberWithModifiers2.js index d8cb4a3ad4..ffe2b6678d 100644 --- a/tests/baselines/reference/objectLiteralMemberWithModifiers2.js +++ b/tests/baselines/reference/objectLiteralMemberWithModifiers2.js @@ -2,7 +2,4 @@ var v = { public get foo() { } } //// [objectLiteralMemberWithModifiers2.js] -var v = { - get foo() { - } -}; +var v = { get foo() { } }; diff --git a/tests/baselines/reference/objectLiteralMemberWithQuestionMark1.js b/tests/baselines/reference/objectLiteralMemberWithQuestionMark1.js index 539c7a1cca..62f7a6eefe 100644 --- a/tests/baselines/reference/objectLiteralMemberWithQuestionMark1.js +++ b/tests/baselines/reference/objectLiteralMemberWithQuestionMark1.js @@ -2,7 +2,4 @@ var v = { foo?() { } } //// [objectLiteralMemberWithQuestionMark1.js] -var v = { - foo: function () { - } -}; +var v = { foo: function () { } }; diff --git a/tests/baselines/reference/objectLiteralMemberWithoutBlock1.js b/tests/baselines/reference/objectLiteralMemberWithoutBlock1.js index b8cd54803a..d6a8579be0 100644 --- a/tests/baselines/reference/objectLiteralMemberWithoutBlock1.js +++ b/tests/baselines/reference/objectLiteralMemberWithoutBlock1.js @@ -2,6 +2,4 @@ var v = { foo(); } //// [objectLiteralMemberWithoutBlock1.js] -var v = { - foo: function () { } -}; +var v = { foo: function () { } }; diff --git a/tests/baselines/reference/objectLiteralParameterResolution.js b/tests/baselines/reference/objectLiteralParameterResolution.js index 1d68062360..5912a2229b 100644 --- a/tests/baselines/reference/objectLiteralParameterResolution.js +++ b/tests/baselines/reference/objectLiteralParameterResolution.js @@ -23,9 +23,7 @@ var s = $.extend({ success: wrapSuccessCallback(requestContext, callback), error: wrapErrorCallback(requestContext, errorCallback), dataType: "json", - converters: { - "text json": "" - }, + converters: { "text json": "" }, traditional: true, timeout: 12 }, ""); diff --git a/tests/baselines/reference/objectLiteralReferencingInternalProperties.js b/tests/baselines/reference/objectLiteralReferencingInternalProperties.js index 1215dda92a..793fa0c588 100644 --- a/tests/baselines/reference/objectLiteralReferencingInternalProperties.js +++ b/tests/baselines/reference/objectLiteralReferencingInternalProperties.js @@ -2,7 +2,4 @@ var a = { b: 10, c: b }; // Should give error for attempting to reference b. //// [objectLiteralReferencingInternalProperties.js] -var a = { - b: 10, - c: b -}; // Should give error for attempting to reference b. +var a = { b: 10, c: b }; // Should give error for attempting to reference b. diff --git a/tests/baselines/reference/objectLiteralShorthandProperties.js b/tests/baselines/reference/objectLiteralShorthandProperties.js index 776b2bbe45..bc18ecfb94 100644 --- a/tests/baselines/reference/objectLiteralShorthandProperties.js +++ b/tests/baselines/reference/objectLiteralShorthandProperties.js @@ -32,8 +32,7 @@ var x3 = { a: 0, b: b, c: c, - d: function () { - }, + d: function () { }, x3: x3, parent: x3 }; diff --git a/tests/baselines/reference/objectLiteralShorthandPropertiesAssignment.js b/tests/baselines/reference/objectLiteralShorthandPropertiesAssignment.js index f9b1e2caa9..251098eb6c 100644 --- a/tests/baselines/reference/objectLiteralShorthandPropertiesAssignment.js +++ b/tests/baselines/reference/objectLiteralShorthandPropertiesAssignment.js @@ -17,30 +17,12 @@ var person3: { name: string; id:number } = bar("Hello", 5); //// [objectLiteralShorthandPropertiesAssignment.js] var id = 10000; var name = "my name"; -var person = { - name: name, - id: id -}; -function foo(obj) { -} +var person = { name: name, id: id }; +function foo(obj) { } ; -function bar(name, id) { - return { - name: name, - id: id - }; -} -function bar1(name, id) { - return { - name: name - }; -} -function baz(name, id) { - return { - name: name, - id: id - }; -} +function bar(name, id) { return { name: name, id: id }; } +function bar1(name, id) { return { name: name }; } +function baz(name, id) { return { name: name, id: id }; } foo(person); var person1 = bar("Hello", 5); var person2 = bar("Hello", 5); diff --git a/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentES6.js b/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentES6.js index 4b21d8052e..247ec56d12 100644 --- a/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentES6.js +++ b/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentES6.js @@ -17,30 +17,12 @@ var person3: { name: string; id: number } = bar("Hello", 5); //// [objectLiteralShorthandPropertiesAssignmentES6.js] var id = 10000; var name = "my name"; -var person = { - name, - id -}; -function foo(obj) { -} +var person = { name, id }; +function foo(obj) { } ; -function bar(name, id) { - return { - name, - id - }; -} -function bar1(name, id) { - return { - name - }; -} -function baz(name, id) { - return { - name, - id - }; -} +function bar(name, id) { return { name, id }; } +function bar1(name, id) { return { name }; } +function baz(name, id) { return { name, id }; } foo(person); var person1 = bar("Hello", 5); var person2 = bar("Hello", 5); diff --git a/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentError.js b/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentError.js index 4f99576c30..8e2d7f8035 100644 --- a/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentError.js +++ b/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentError.js @@ -13,21 +13,9 @@ bar({ name, id }); // error //// [objectLiteralShorthandPropertiesAssignmentError.js] var id = 10000; var name = "my name"; -var person = { - name: name, - id: id -}; // error +var person = { name: name, id: id }; // error var person1 = name, id; ; // error: can't use short-hand property assignment in type position -function foo(name, id) { - return { - name: name, - id: id - }; -} // error -function bar(obj) { -} -bar({ - name: name, - id: id -}); // error +function foo(name, id) { return { name: name, id: id }; } // error +function bar(obj) { } +bar({ name: name, id: id }); // error diff --git a/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentErrorFromMissingIdentifier.js b/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentErrorFromMissingIdentifier.js index 1ccdb27486..71449746ad 100644 --- a/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentErrorFromMissingIdentifier.js +++ b/tests/baselines/reference/objectLiteralShorthandPropertiesAssignmentErrorFromMissingIdentifier.js @@ -11,22 +11,9 @@ var person2: { name: string, id: number } = bar("hello", 5); //// [objectLiteralShorthandPropertiesAssignmentErrorFromMissingIdentifier.js] var id = 10000; var name = "my name"; -var person = { - name: name, - id: id -}; // error -function bar(name, id) { - return { - name: name, - id: id - }; -} // error -function foo(name, id) { - return { - name: name, - id: id - }; -} // error +var person = { name: name, id: id }; // error +function bar(name, id) { return { name: name, id: id }; } // error +function foo(name, id) { return { name: name, id: id }; } // error var person1 = name, id; ; // error : Can't use shorthand in the type position var person2 = bar("hello", 5); diff --git a/tests/baselines/reference/objectLiteralShorthandPropertiesES6.js b/tests/baselines/reference/objectLiteralShorthandPropertiesES6.js index c65087a8da..9b19bdc8b5 100644 --- a/tests/baselines/reference/objectLiteralShorthandPropertiesES6.js +++ b/tests/baselines/reference/objectLiteralShorthandPropertiesES6.js @@ -32,8 +32,7 @@ var x3 = { a: 0, b, c, - d() { - }, + d() { }, x3, parent: x3 }; diff --git a/tests/baselines/reference/objectLiteralShorthandPropertiesErrorFromNotUsingIdentifier.js b/tests/baselines/reference/objectLiteralShorthandPropertiesErrorFromNotUsingIdentifier.js index 3c457178b3..b72f0351b9 100644 --- a/tests/baselines/reference/objectLiteralShorthandPropertiesErrorFromNotUsingIdentifier.js +++ b/tests/baselines/reference/objectLiteralShorthandPropertiesErrorFromNotUsingIdentifier.js @@ -25,10 +25,8 @@ var v = { class }; // error var y = { "stringLiteral": , 42: , - get e() { - }, - set f() { - }, + get e() { }, + set f() { }, this: , super: , var: , @@ -37,13 +35,7 @@ var y = { }; var x = { a: .b, - a: [ - "ss" - ], - a: [ - 1 - ] + a: ["ss"], + a: [1] }; -var v = { - class: -}; // error +var v = { class: }; // error diff --git a/tests/baselines/reference/objectLiteralShorthandPropertiesFunctionArgument.js b/tests/baselines/reference/objectLiteralShorthandPropertiesFunctionArgument.js index 65eed2eace..860abc24b1 100644 --- a/tests/baselines/reference/objectLiteralShorthandPropertiesFunctionArgument.js +++ b/tests/baselines/reference/objectLiteralShorthandPropertiesFunctionArgument.js @@ -13,14 +13,7 @@ var obj = { name: name, id: id }; //// [objectLiteralShorthandPropertiesFunctionArgument.js] var id = 10000; var name = "my name"; -var person = { - name: name, - id: id -}; -function foo(p) { -} +var person = { name: name, id: id }; +function foo(p) { } foo(person); -var obj = { - name: name, - id: id -}; +var obj = { name: name, id: id }; diff --git a/tests/baselines/reference/objectLiteralShorthandPropertiesFunctionArgument2.js b/tests/baselines/reference/objectLiteralShorthandPropertiesFunctionArgument2.js index 3f396091d0..7e9d2e7ca8 100644 --- a/tests/baselines/reference/objectLiteralShorthandPropertiesFunctionArgument2.js +++ b/tests/baselines/reference/objectLiteralShorthandPropertiesFunctionArgument2.js @@ -11,10 +11,6 @@ foo(person); // error //// [objectLiteralShorthandPropertiesFunctionArgument2.js] var id = 10000; var name = "my name"; -var person = { - name: name, - id: id -}; -function foo(p) { -} +var person = { name: name, id: id }; +function foo(p) { } foo(person); // error diff --git a/tests/baselines/reference/objectLiteralWithSemicolons1.js b/tests/baselines/reference/objectLiteralWithSemicolons1.js index 85aa5f268c..b820b14428 100644 --- a/tests/baselines/reference/objectLiteralWithSemicolons1.js +++ b/tests/baselines/reference/objectLiteralWithSemicolons1.js @@ -2,8 +2,4 @@ var v = { a; b; c } //// [objectLiteralWithSemicolons1.js] -var v = { - a: , - b: , - c: c -}; +var v = { a: , b: , c: c }; diff --git a/tests/baselines/reference/objectLiteralWithSemicolons4.js b/tests/baselines/reference/objectLiteralWithSemicolons4.js index 9e1e3dea4b..a01d52548e 100644 --- a/tests/baselines/reference/objectLiteralWithSemicolons4.js +++ b/tests/baselines/reference/objectLiteralWithSemicolons4.js @@ -5,5 +5,4 @@ var v = { //// [objectLiteralWithSemicolons4.js] var v = { - a: -}; + a: }; diff --git a/tests/baselines/reference/objectLiteralWithSemicolons5.js b/tests/baselines/reference/objectLiteralWithSemicolons5.js index 36fef30ad7..1c9c4ddf54 100644 --- a/tests/baselines/reference/objectLiteralWithSemicolons5.js +++ b/tests/baselines/reference/objectLiteralWithSemicolons5.js @@ -2,10 +2,4 @@ var v = { foo() { }; a: b; get baz() { }; } //// [objectLiteralWithSemicolons5.js] -var v = { - foo: function () { - }, - a: b, - get baz() { - } -}; +var v = { foo: function () { }, a: b, get baz() { } }; diff --git a/tests/baselines/reference/objectTypeHidingMembersOfExtendedObject.js b/tests/baselines/reference/objectTypeHidingMembersOfExtendedObject.js index fa41e57e22..16268c1331 100644 --- a/tests/baselines/reference/objectTypeHidingMembersOfExtendedObject.js +++ b/tests/baselines/reference/objectTypeHidingMembersOfExtendedObject.js @@ -76,8 +76,7 @@ var B = (function (_super) { var C = (function () { function C() { } - C.prototype.valueOf = function () { - }; + C.prototype.valueOf = function () { }; return C; })(); var c; @@ -91,8 +90,7 @@ var r2b = i.data; var r2c = r2b['hm']; // should be 'Object' var r2d = i['hm']; // should be 'any' var a = { - valueOf: function () { - }, + valueOf: function () { }, data: new B() }; var r3 = a.valueOf(); diff --git a/tests/baselines/reference/objectTypeHidingMembersOfObject.js b/tests/baselines/reference/objectTypeHidingMembersOfObject.js index 113329cf8b..291cc1858f 100644 --- a/tests/baselines/reference/objectTypeHidingMembersOfObject.js +++ b/tests/baselines/reference/objectTypeHidingMembersOfObject.js @@ -32,8 +32,7 @@ var r4: void = b.valueOf(); var C = (function () { function C() { } - C.prototype.valueOf = function () { - }; + C.prototype.valueOf = function () { }; return C; })(); var c; @@ -41,8 +40,7 @@ var r1 = c.valueOf(); var i; var r2 = i.valueOf(); var a = { - valueOf: function () { - } + valueOf: function () { } }; var r3 = a.valueOf(); var b; diff --git a/tests/baselines/reference/objectTypeHidingMembersOfObjectAssignmentCompat.js b/tests/baselines/reference/objectTypeHidingMembersOfObjectAssignmentCompat.js index 93d985f798..5ae0c2fb1b 100644 --- a/tests/baselines/reference/objectTypeHidingMembersOfObjectAssignmentCompat.js +++ b/tests/baselines/reference/objectTypeHidingMembersOfObjectAssignmentCompat.js @@ -29,16 +29,14 @@ i = o; // ok var C = (function () { function C() { } - C.prototype.toString = function () { - }; + C.prototype.toString = function () { }; return C; })(); var c; o = c; // error c = o; // ok var a = { - toString: function () { - } + toString: function () { } }; o = a; // error a = o; // ok diff --git a/tests/baselines/reference/objectTypeHidingMembersOfObjectAssignmentCompat2.js b/tests/baselines/reference/objectTypeHidingMembersOfObjectAssignmentCompat2.js index b8a5aa87ae..7a2b5e2ec2 100644 --- a/tests/baselines/reference/objectTypeHidingMembersOfObjectAssignmentCompat2.js +++ b/tests/baselines/reference/objectTypeHidingMembersOfObjectAssignmentCompat2.js @@ -29,17 +29,14 @@ i = o; // error var C = (function () { function C() { } - C.prototype.toString = function () { - return 1; - }; + C.prototype.toString = function () { return 1; }; return C; })(); var c; o = c; // error c = o; // error var a = { - toString: function () { - } + toString: function () { } }; o = a; // error a = o; // ok diff --git a/tests/baselines/reference/objectTypesIdentity.js b/tests/baselines/reference/objectTypesIdentity.js index b757c18ac4..7eccee2365 100644 --- a/tests/baselines/reference/objectTypesIdentity.js +++ b/tests/baselines/reference/objectTypesIdentity.js @@ -106,40 +106,21 @@ var C = (function () { return C; })(); var a; -var b = { - foo: '' -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { foo: '' }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentity2.js b/tests/baselines/reference/objectTypesIdentity2.js index f721fb04b5..87057754ca 100644 --- a/tests/baselines/reference/objectTypesIdentity2.js +++ b/tests/baselines/reference/objectTypesIdentity2.js @@ -87,28 +87,15 @@ var E; (function (E) { E[E["A"] = 0] = "A"; })(E || (E = {})); -var b = { - foo: E.A -}; -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { foo: E.A }; +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithCallSignatures.js b/tests/baselines/reference/objectTypesIdentityWithCallSignatures.js index 3465085bda..0c6952291f 100644 --- a/tests/baselines/reference/objectTypesIdentityWithCallSignatures.js +++ b/tests/baselines/reference/objectTypesIdentityWithCallSignatures.js @@ -105,68 +105,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return ''; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return ''; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithCallSignatures2.js b/tests/baselines/reference/objectTypesIdentityWithCallSignatures2.js index 5a45e4b5af..43473d88e0 100644 --- a/tests/baselines/reference/objectTypesIdentityWithCallSignatures2.js +++ b/tests/baselines/reference/objectTypesIdentityWithCallSignatures2.js @@ -105,68 +105,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return ''; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return ''; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithCallSignatures3.js b/tests/baselines/reference/objectTypesIdentityWithCallSignatures3.js index 289ba25bf6..f4cfc8dc60 100644 --- a/tests/baselines/reference/objectTypesIdentityWithCallSignatures3.js +++ b/tests/baselines/reference/objectTypesIdentityWithCallSignatures3.js @@ -42,17 +42,10 @@ function foo15(x: any) { } //// [objectTypesIdentityWithCallSignatures3.js] // object types are identical structurally var a; -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo14b(x) { -} -function foo15(x) { -} +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo13(x) { } +function foo14(x) { } +function foo14b(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithCallSignaturesDifferingParamCounts.js b/tests/baselines/reference/objectTypesIdentityWithCallSignaturesDifferingParamCounts.js index c258bc277d..498867f0a0 100644 --- a/tests/baselines/reference/objectTypesIdentityWithCallSignaturesDifferingParamCounts.js +++ b/tests/baselines/reference/objectTypesIdentityWithCallSignaturesDifferingParamCounts.js @@ -105,68 +105,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x, y) { - return null; - }; + B.prototype.foo = function (x, y) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - return null; - }; + C.prototype.foo = function (x, y) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return ''; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return ''; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithCallSignaturesDifferingParamCounts2.js b/tests/baselines/reference/objectTypesIdentityWithCallSignaturesDifferingParamCounts2.js index fe84b3e6b9..98b17767b7 100644 --- a/tests/baselines/reference/objectTypesIdentityWithCallSignaturesDifferingParamCounts2.js +++ b/tests/baselines/reference/objectTypesIdentityWithCallSignaturesDifferingParamCounts2.js @@ -46,19 +46,11 @@ function foo15(x: any) { } //// [objectTypesIdentityWithCallSignaturesDifferingParamCounts2.js] // object types are identical structurally var a; -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo14b(x) { -} -function foo15(x) { -} +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo13(x) { } +function foo14(x) { } +function foo14b(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithCallSignaturesWithOverloads.js b/tests/baselines/reference/objectTypesIdentityWithCallSignaturesWithOverloads.js index 29cb6f3cd5..54400ad81d 100644 --- a/tests/baselines/reference/objectTypesIdentityWithCallSignaturesWithOverloads.js +++ b/tests/baselines/reference/objectTypesIdentityWithCallSignaturesWithOverloads.js @@ -121,68 +121,41 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; var b = { - foo: function (x) { - return ''; - } + foo: function (x) { return ''; } }; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithComplexConstraints.js b/tests/baselines/reference/objectTypesIdentityWithComplexConstraints.js index 9f16153da3..ca9db28223 100644 --- a/tests/baselines/reference/objectTypesIdentityWithComplexConstraints.js +++ b/tests/baselines/reference/objectTypesIdentityWithComplexConstraints.js @@ -15,5 +15,4 @@ function foo(x: B); // error after constraints above made illegal function foo(x: any) { } //// [objectTypesIdentityWithComplexConstraints.js] -function foo(x) { -} +function foo(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithConstructSignatures.js b/tests/baselines/reference/objectTypesIdentityWithConstructSignatures.js index caf28cd05d..91208da5b9 100644 --- a/tests/baselines/reference/objectTypesIdentityWithConstructSignatures.js +++ b/tests/baselines/reference/objectTypesIdentityWithConstructSignatures.js @@ -105,35 +105,19 @@ var C = (function () { return C; })(); var a; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo15(x) { -} +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithConstructSignatures2.js b/tests/baselines/reference/objectTypesIdentityWithConstructSignatures2.js index 641524de5a..87067b6be2 100644 --- a/tests/baselines/reference/objectTypesIdentityWithConstructSignatures2.js +++ b/tests/baselines/reference/objectTypesIdentityWithConstructSignatures2.js @@ -91,36 +91,18 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x) { - return ''; - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { new: function (x) { return ''; } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithConstructSignaturesDifferingParamCounts.js b/tests/baselines/reference/objectTypesIdentityWithConstructSignaturesDifferingParamCounts.js index 171dd5c351..c95159ed99 100644 --- a/tests/baselines/reference/objectTypesIdentityWithConstructSignaturesDifferingParamCounts.js +++ b/tests/baselines/reference/objectTypesIdentityWithConstructSignaturesDifferingParamCounts.js @@ -91,36 +91,18 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x) { - return ''; - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { new: function (x) { return ''; } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignatures.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignatures.js index f366e79341..c8bed1a47a 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignatures.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignatures.js @@ -105,68 +105,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return x; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return x; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignatures2.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignatures2.js index 9d18420434..6ef5d15fd9 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignatures2.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignatures2.js @@ -105,68 +105,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x, y) { - return null; - }; + A.prototype.foo = function (x, y) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x, y) { - return null; - }; + B.prototype.foo = function (x, y) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - return null; - }; + C.prototype.foo = function (x, y) { return null; }; return C; })(); var a; -var b = { - foo: function (x, y) { - return x; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x, y) { return x; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints.js index b5b7f6414e..2b83064afe 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints.js @@ -109,68 +109,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return ''; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return ''; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints2.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints2.js index cc1957eef3..1f9c5fa525 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints2.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints2.js @@ -121,80 +121,47 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x, y) { - return null; - }; + A.prototype.foo = function (x, y) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x, y) { - return null; - }; + B.prototype.foo = function (x, y) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - return null; - }; + C.prototype.foo = function (x, y) { return null; }; return C; })(); var D = (function () { function D() { } - D.prototype.foo = function (x, y) { - return null; - }; + D.prototype.foo = function (x, y) { return null; }; return D; })(); var a; -var b = { - foo: function (x, y) { - return ''; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo5c(x) { -} -function foo6c(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x, y) { return ''; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo5c(x) { } +function foo6c(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints3.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints3.js index 9774cbd2b4..21106b56b0 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints3.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByConstraints3.js @@ -140,80 +140,47 @@ var Two = (function () { var A = (function () { function A() { } - A.prototype.foo = function (x, y) { - return null; - }; + A.prototype.foo = function (x, y) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x, y) { - return null; - }; + B.prototype.foo = function (x, y) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - return null; - }; + C.prototype.foo = function (x, y) { return null; }; return C; })(); var D = (function () { function D() { } - D.prototype.foo = function (x, y) { - return null; - }; + D.prototype.foo = function (x, y) { return null; }; return D; })(); var a; -var b = { - foo: function (x, y) { - return ''; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo5c(x) { -} -function foo6c(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x, y) { return ''; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo5c(x) { } +function foo6c(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByReturnType.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByReturnType.js index ac686014aa..99188347d3 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByReturnType.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByReturnType.js @@ -109,68 +109,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return null; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return null; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByReturnType2.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByReturnType2.js index e25e379bde..10d72bde0b 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByReturnType2.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingByReturnType2.js @@ -109,68 +109,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return null; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return null; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts.js index 48e98f904b..5a20dfdecb 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts.js @@ -105,68 +105,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return x; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return x; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts2.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts2.js index 944fb7d984..6bfd019dc8 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts2.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts2.js @@ -43,17 +43,10 @@ function foo15(x: any) { } //// [objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterCounts2.js] // object types are identical structurally var a; -function foo1(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo14b(x) { -} -function foo15(x) { -} +function foo1(x) { } +function foo2(x) { } +function foo3(x) { } +function foo13(x) { } +function foo14(x) { } +function foo14b(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterNames.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterNames.js index 518bbe550e..ec9c786b89 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterNames.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesDifferingTypeParameterNames.js @@ -105,68 +105,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x) { - return null; - }; + A.prototype.foo = function (x) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x) { - return null; - }; + B.prototype.foo = function (x) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x) { - return null; - }; + C.prototype.foo = function (x) { return null; }; return C; })(); var a; -var b = { - foo: function (x) { - return x; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x) { return x; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams.js index f84341e589..a4af2bc820 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams.js @@ -109,68 +109,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x, y) { - return null; - }; + A.prototype.foo = function (x, y) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x, y) { - return null; - }; + B.prototype.foo = function (x, y) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - return null; - }; + C.prototype.foo = function (x, y) { return null; }; return C; })(); var a; -var b = { - foo: function (x, y) { - return x; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x, y) { return x; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams2.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams2.js index ea38510982..28b2f978b5 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams2.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams2.js @@ -109,68 +109,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x, y) { - return null; - }; + A.prototype.foo = function (x, y) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x, y) { - return null; - }; + B.prototype.foo = function (x, y) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - return null; - }; + C.prototype.foo = function (x, y) { return null; }; return C; })(); var a; -var b = { - foo: function (x, y) { - return x; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x, y) { return x; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams3.js b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams3.js index 34acdef859..de9b4859fa 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams3.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericCallSignaturesOptionalParams3.js @@ -109,68 +109,39 @@ function foo15(x: any) { } var A = (function () { function A() { } - A.prototype.foo = function (x, y) { - return null; - }; + A.prototype.foo = function (x, y) { return null; }; return A; })(); var B = (function () { function B() { } - B.prototype.foo = function (x, y) { - return null; - }; + B.prototype.foo = function (x, y) { return null; }; return B; })(); var C = (function () { function C() { } - C.prototype.foo = function (x, y) { - return null; - }; + C.prototype.foo = function (x, y) { return null; }; return C; })(); var a; -var b = { - foo: function (x, y) { - return x; - } -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { foo: function (x, y) { return x; } }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints.js index b252fc7f8f..fdc67d4b84 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints.js @@ -92,34 +92,17 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x) { - return ''; - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { new: function (x) { return ''; } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints2.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints2.js index e6450471a4..11dcdf0a60 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints2.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints2.js @@ -109,38 +109,19 @@ var D = (function () { return D; })(); var a; -var b = { - new: function (x, y) { - return ''; - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5c(x) { -} -function foo6c(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { new: function (x, y) { return ''; } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5c(x) { } +function foo6c(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints3.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints3.js index 0a276be9f7..5c6f59eef2 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints3.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByConstraints3.js @@ -128,38 +128,19 @@ var D = (function () { return D; })(); var a; -var b = { - new: function (x, y) { - return ''; - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5c(x) { -} -function foo6c(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { new: function (x, y) { return ''; } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5c(x) { } +function foo6c(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByReturnType.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByReturnType.js index e1c64ed0ec..556d1bcaee 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByReturnType.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByReturnType.js @@ -99,38 +99,19 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x) { - return null; - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { new: function (x) { return null; } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByReturnType2.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByReturnType2.js index ade431026d..68c32cb0e7 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByReturnType2.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingByReturnType2.js @@ -95,36 +95,18 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x) { - return null; - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} +var b = { new: function (x) { return null; } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingTypeParameterCounts.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingTypeParameterCounts.js index 014b4126f2..789e02d2d7 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingTypeParameterCounts.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingTypeParameterCounts.js @@ -87,34 +87,17 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x) { - return x; - } -}; -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { new: function (x) { return x; } }; +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingTypeParameterNames.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingTypeParameterNames.js index d30a3a798a..5a501d0583 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingTypeParameterNames.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesDifferingTypeParameterNames.js @@ -87,34 +87,17 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x) { - return new C(x); - } -}; -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { new: function (x) { return new C(x); } }; +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams.js index f71ef509ca..685a8441d9 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams.js @@ -91,34 +91,17 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x, y) { - return new C(x, y); - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { new: function (x, y) { return new C(x, y); } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams2.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams2.js index 00994a57fc..f16d69acaa 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams2.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams2.js @@ -91,34 +91,17 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x, y) { - return new C(x, y); - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { new: function (x, y) { return new C(x, y); } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams3.js b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams3.js index 572a9db5d3..25c628e9e1 100644 --- a/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams3.js +++ b/tests/baselines/reference/objectTypesIdentityWithGenericConstructSignaturesOptionalParams3.js @@ -91,34 +91,17 @@ var C = (function () { return C; })(); var a; -var b = { - new: function (x, y) { - return new C(x, y); - } -}; // not a construct signature, function called new -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo12b(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { new: function (x, y) { return new C(x, y); } }; // not a construct signature, function called new +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo12b(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers1.js b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers1.js index e49566c553..1dc6505456 100644 --- a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers1.js +++ b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers1.js @@ -160,52 +160,27 @@ var PB = (function (_super) { return PB; })(B); var a; -var b = { - foo: '' -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo5c(x) { -} -function foo5d(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo11b(x) { -} -function foo11c(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} -function foo16(x) { -} +var b = { foo: '' }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo5c(x) { } +function foo5d(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo11b(x) { } +function foo11c(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } +function foo16(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers2.js b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers2.js index ae00306f39..e2fd1b99bf 100644 --- a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers2.js +++ b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers2.js @@ -175,52 +175,27 @@ var PB = (function (_super) { return PB; })(B); var a; -var b = { - foo: null -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo5c(x) { -} -function foo5d(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo11b(x) { -} -function foo11c(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} -function foo16(x) { -} +var b = { foo: null }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo5c(x) { } +function foo5d(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo11b(x) { } +function foo11c(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } +function foo16(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers3.js b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers3.js index cc9d605153..11d64efc9d 100644 --- a/tests/baselines/reference/objectTypesIdentityWithNumericIndexers3.js +++ b/tests/baselines/reference/objectTypesIdentityWithNumericIndexers3.js @@ -160,52 +160,27 @@ var PB = (function (_super) { return PB; })(B); var a; -var b = { - foo: '' -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo5c(x) { -} -function foo5d(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo11b(x) { -} -function foo11c(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} -function foo16(x) { -} +var b = { foo: '' }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo5c(x) { } +function foo5d(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo11b(x) { } +function foo11c(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } +function foo16(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithOptionality.js b/tests/baselines/reference/objectTypesIdentityWithOptionality.js index 4fe529a134..2a61cda1bb 100644 --- a/tests/baselines/reference/objectTypesIdentityWithOptionality.js +++ b/tests/baselines/reference/objectTypesIdentityWithOptionality.js @@ -74,24 +74,13 @@ var C = (function () { return C; })(); var a; -var b = { - foo: '' -}; -function foo2(x) { -} -function foo3(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo10(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { foo: '' }; +function foo2(x) { } +function foo3(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo10(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithPrivates.js b/tests/baselines/reference/objectTypesIdentityWithPrivates.js index e8072e7f18..5c8a0afed7 100644 --- a/tests/baselines/reference/objectTypesIdentityWithPrivates.js +++ b/tests/baselines/reference/objectTypesIdentityWithPrivates.js @@ -158,52 +158,27 @@ var PB = (function (_super) { return PB; })(B); var a; -var b = { - foo: '' -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo5c(x) { -} -function foo5d(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo11b(x) { -} -function foo11c(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} -function foo16(x) { -} +var b = { foo: '' }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo5c(x) { } +function foo5d(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo11b(x) { } +function foo11c(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } +function foo16(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithPrivates2.js b/tests/baselines/reference/objectTypesIdentityWithPrivates2.js index 4e62e7b551..36c3e67c70 100644 --- a/tests/baselines/reference/objectTypesIdentityWithPrivates2.js +++ b/tests/baselines/reference/objectTypesIdentityWithPrivates2.js @@ -58,17 +58,11 @@ var D = (function (_super) { } return D; })(C); -function foo1(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} +function foo1(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } var r = foo4(new C()); var r = foo4(new D()); -function foo5(x) { -} -function foo6(x) { -} +function foo5(x) { } +function foo6(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithPublics.js b/tests/baselines/reference/objectTypesIdentityWithPublics.js index 59b6e315c1..7c36eb48f2 100644 --- a/tests/baselines/reference/objectTypesIdentityWithPublics.js +++ b/tests/baselines/reference/objectTypesIdentityWithPublics.js @@ -106,40 +106,21 @@ var C = (function () { return C; })(); var a; -var b = { - foo: '' -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} +var b = { foo: '' }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithStringIndexers.js b/tests/baselines/reference/objectTypesIdentityWithStringIndexers.js index f9abb67895..37c5537aa4 100644 --- a/tests/baselines/reference/objectTypesIdentityWithStringIndexers.js +++ b/tests/baselines/reference/objectTypesIdentityWithStringIndexers.js @@ -160,52 +160,27 @@ var PB = (function (_super) { return PB; })(B); var a; -var b = { - foo: '' -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo5c(x) { -} -function foo5d(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo11b(x) { -} -function foo11c(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} -function foo16(x) { -} +var b = { foo: '' }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo5c(x) { } +function foo5d(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo11b(x) { } +function foo11c(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } +function foo16(x) { } diff --git a/tests/baselines/reference/objectTypesIdentityWithStringIndexers2.js b/tests/baselines/reference/objectTypesIdentityWithStringIndexers2.js index 6bb5369122..e90dc8598e 100644 --- a/tests/baselines/reference/objectTypesIdentityWithStringIndexers2.js +++ b/tests/baselines/reference/objectTypesIdentityWithStringIndexers2.js @@ -175,52 +175,27 @@ var PB = (function (_super) { return PB; })(B); var a; -var b = { - foo: null -}; -function foo1(x) { -} -function foo1b(x) { -} -function foo1c(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} -function foo5b(x) { -} -function foo5c(x) { -} -function foo5d(x) { -} -function foo6(x) { -} -function foo7(x) { -} -function foo8(x) { -} -function foo9(x) { -} -function foo10(x) { -} -function foo11(x) { -} -function foo11b(x) { -} -function foo11c(x) { -} -function foo12(x) { -} -function foo13(x) { -} -function foo14(x) { -} -function foo15(x) { -} -function foo16(x) { -} +var b = { foo: null }; +function foo1(x) { } +function foo1b(x) { } +function foo1c(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } +function foo5b(x) { } +function foo5c(x) { } +function foo5d(x) { } +function foo6(x) { } +function foo7(x) { } +function foo8(x) { } +function foo9(x) { } +function foo10(x) { } +function foo11(x) { } +function foo11b(x) { } +function foo11c(x) { } +function foo12(x) { } +function foo13(x) { } +function foo14(x) { } +function foo15(x) { } +function foo16(x) { } diff --git a/tests/baselines/reference/objectTypesWithOptionalProperties2.js b/tests/baselines/reference/objectTypesWithOptionalProperties2.js index 3faa10447b..cf0d113c24 100644 --- a/tests/baselines/reference/objectTypesWithOptionalProperties2.js +++ b/tests/baselines/reference/objectTypesWithOptionalProperties2.js @@ -42,7 +42,5 @@ var C2 = (function () { return C2; })(); var b = { - x: function () { - }, - 1: // error + x: function () { }, 1: // error }; diff --git a/tests/baselines/reference/optionalAccessorsInInterface1.js b/tests/baselines/reference/optionalAccessorsInInterface1.js index cf6a795b6b..dd274b133e 100644 --- a/tests/baselines/reference/optionalAccessorsInInterface1.js +++ b/tests/baselines/reference/optionalAccessorsInInterface1.js @@ -17,13 +17,5 @@ defineMyProperty2({}, "name", { get: function () { return 5; } }); //// [optionalAccessorsInInterface1.js] -defineMyProperty({}, "name", { - get: function () { - return 5; - } -}); -defineMyProperty2({}, "name", { - get: function () { - return 5; - } -}); +defineMyProperty({}, "name", { get: function () { return 5; } }); +defineMyProperty2({}, "name", { get: function () { return 5; } }); diff --git a/tests/baselines/reference/optionalBindingParameters1.js b/tests/baselines/reference/optionalBindingParameters1.js index e2286bf40b..536cb1e567 100644 --- a/tests/baselines/reference/optionalBindingParameters1.js +++ b/tests/baselines/reference/optionalBindingParameters1.js @@ -12,13 +12,5 @@ foo([false, 0, ""]); function foo(_a) { var x = _a[0], y = _a[1], z = _a[2]; } -foo([ - "", - 0, - false -]); -foo([ - false, - 0, - "" -]); +foo(["", 0, false]); +foo([false, 0, ""]); diff --git a/tests/baselines/reference/optionalBindingParameters2.js b/tests/baselines/reference/optionalBindingParameters2.js index f9c55ebd4a..04e1138561 100644 --- a/tests/baselines/reference/optionalBindingParameters2.js +++ b/tests/baselines/reference/optionalBindingParameters2.js @@ -12,13 +12,5 @@ foo({ x: false, y: 0, z: "" }); function foo(_a) { var x = _a.x, y = _a.y, z = _a.z; } -foo({ - x: "", - y: 0, - z: false -}); -foo({ - x: false, - y: 0, - z: "" -}); +foo({ x: "", y: 0, z: false }); +foo({ x: false, y: 0, z: "" }); diff --git a/tests/baselines/reference/optionalBindingParametersInOverloads1.js b/tests/baselines/reference/optionalBindingParametersInOverloads1.js index 40f60108aa..3658efa72c 100644 --- a/tests/baselines/reference/optionalBindingParametersInOverloads1.js +++ b/tests/baselines/reference/optionalBindingParametersInOverloads1.js @@ -16,13 +16,5 @@ function foo() { rest[_i - 0] = arguments[_i]; } } -foo([ - "", - 0, - false -]); -foo([ - false, - 0, - "" -]); +foo(["", 0, false]); +foo([false, 0, ""]); diff --git a/tests/baselines/reference/optionalBindingParametersInOverloads2.js b/tests/baselines/reference/optionalBindingParametersInOverloads2.js index 18e4c10fc9..1ddfdae4f0 100644 --- a/tests/baselines/reference/optionalBindingParametersInOverloads2.js +++ b/tests/baselines/reference/optionalBindingParametersInOverloads2.js @@ -16,13 +16,5 @@ function foo() { rest[_i - 0] = arguments[_i]; } } -foo({ - x: "", - y: 0, - z: false -}); -foo({ - x: false, - y: 0, - z: "" -}); +foo({ x: "", y: 0, z: false }); +foo({ x: false, y: 0, z: "" }); diff --git a/tests/baselines/reference/optionalConstructorArgInSuper.js b/tests/baselines/reference/optionalConstructorArgInSuper.js index 45c0e032cd..5204d7f830 100644 --- a/tests/baselines/reference/optionalConstructorArgInSuper.js +++ b/tests/baselines/reference/optionalConstructorArgInSuper.js @@ -20,8 +20,7 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base(opt) { } - Base.prototype.foo = function (other) { - }; + Base.prototype.foo = function (other) { }; return Base; })(); var Derived = (function (_super) { diff --git a/tests/baselines/reference/optionalFunctionArgAssignability.js b/tests/baselines/reference/optionalFunctionArgAssignability.js index bca4206006..c82a47e88d 100644 --- a/tests/baselines/reference/optionalFunctionArgAssignability.js +++ b/tests/baselines/reference/optionalFunctionArgAssignability.js @@ -9,10 +9,6 @@ a = b; // error because number is not assignable to string //// [optionalFunctionArgAssignability.js] -var a = function then(onFulfill, onReject) { - return null; -}; -var b = function then(onFulFill, onReject) { - return null; -}; +var a = function then(onFulfill, onReject) { return null; }; +var b = function then(onFulFill, onReject) { return null; }; a = b; // error because number is not assignable to string diff --git a/tests/baselines/reference/optionalParamArgsTest.js b/tests/baselines/reference/optionalParamArgsTest.js index 6837c024ff..5598f8d087 100644 --- a/tests/baselines/reference/optionalParamArgsTest.js +++ b/tests/baselines/reference/optionalParamArgsTest.js @@ -139,12 +139,8 @@ var C1 = (function () { if (p === void 0) { p = 0; } this.n = 0; } - C1.prototype.C1M1 = function () { - return 0; - }; // returning C1M1A1 will result in "Unresolved symbol C1M1A1" - C1.prototype.C1M2 = function (C1M2A1) { - return C1M2A1; - }; // will return C1M1A2 without complaint + C1.prototype.C1M1 = function () { return 0; }; // returning C1M1A1 will result in "Unresolved symbol C1M1A1" + C1.prototype.C1M2 = function (C1M2A1) { return C1M2A1; }; // will return C1M1A2 without complaint // C1M3 contains all optional parameters C1.prototype.C1M3 = function (C1M3A1, C1M3A2) { if (C1M3A1 === void 0) { C1M3A1 = 0; } @@ -152,9 +148,7 @@ var C1 = (function () { return C1M3A1 + C1M3A2; }; // C1M4 contains a mix of optional and non-optional parameters - C1.prototype.C1M4 = function (C1M4A1, C1M4A2) { - return C1M4A1 + C1M4A2; - }; + C1.prototype.C1M4 = function (C1M4A1, C1M4A2) { return C1M4A1 + C1M4A2; }; C1.prototype.C1M5 = function (C1M5A1, C1M5A2, C1M5A3) { if (C1M5A2 === void 0) { C1M5A2 = 0; } return C1M5A1 + C1M5A2; @@ -175,34 +169,22 @@ var C2 = (function (_super) { } return C2; })(C1); -function F1() { - return 0; -} -function F2(F2A1) { - return F2A1; -} +function F1() { return 0; } +function F2(F2A1) { return F2A1; } function F3(F3A1, F3A2) { if (F3A1 === void 0) { F3A1 = 0; } if (F3A2 === void 0) { F3A2 = F3A1; } return F3A1 + F3A2; } -function F4(F4A1, F4A2) { - return F4A1 + F4A2; -} -var L1 = function () { - return 0; -}; -var L2 = function (L2A1) { - return L2A1; -}; +function F4(F4A1, F4A2) { return F4A1 + F4A2; } +var L1 = function () { return 0; }; +var L2 = function (L2A1) { return L2A1; }; var L3 = function (L3A1, L3A2) { if (L3A1 === void 0) { L3A1 = 0; } if (L3A2 === void 0) { L3A2 = L3A1; } return L3A1 + L3A2; }; -var L4 = function (L4A1, L4A2) { - return L4A1 + L4A2; -}; +var L4 = function (L4A1, L4A2) { return L4A1 + L4A2; }; var c1o1 = new C1(5); var i1o1 = new C1(5); // Valid @@ -264,17 +246,6 @@ function fnOpt1(id, children, expectedPath, isRoot) { if (children === void 0) { children = []; } if (expectedPath === void 0) { expectedPath = []; } } -function fnOpt2(id, children, expectedPath, isRoot) { -} -fnOpt1(1, [ - 2, - 3 -], [ - 1 -], true); -fnOpt2(1, [ - 2, - 3 -], [ - 1 -], true); +function fnOpt2(id, children, expectedPath, isRoot) { } +fnOpt1(1, [2, 3], [1], true); +fnOpt2(1, [2, 3], [1], true); diff --git a/tests/baselines/reference/optionalParamInOverride.js b/tests/baselines/reference/optionalParamInOverride.js index 0a094c6534..cfdfce368d 100644 --- a/tests/baselines/reference/optionalParamInOverride.js +++ b/tests/baselines/reference/optionalParamInOverride.js @@ -17,8 +17,7 @@ var __extends = this.__extends || function (d, b) { var Z = (function () { function Z() { } - Z.prototype.func = function () { - }; + Z.prototype.func = function () { }; return Z; })(); var Y = (function (_super) { @@ -26,7 +25,6 @@ var Y = (function (_super) { function Y() { _super.apply(this, arguments); } - Y.prototype.func = function (value) { - }; + Y.prototype.func = function (value) { }; return Y; })(Z); diff --git a/tests/baselines/reference/optionalPropertiesTest.js b/tests/baselines/reference/optionalPropertiesTest.js index 3c68b90fdd..617db8d618 100644 --- a/tests/baselines/reference/optionalPropertiesTest.js +++ b/tests/baselines/reference/optionalPropertiesTest.js @@ -43,21 +43,10 @@ test10_1 = test10_2; //// [optionalPropertiesTest.js] var x; var foo; -foo = { - id: 1234 -}; // Ok -foo = { - id: 1234, - name: "test" -}; // Ok -foo = { - name: "test" -}; // Error, id missing -foo = { - id: 1234, - print: function () { - } -}; // Ok +foo = { id: 1234 }; // Ok +foo = { id: 1234, name: "test" }; // Ok +foo = { name: "test" }; // Error, id missing +foo = { id: 1234, print: function () { } }; // Ok var s = foo.name || "default"; if (foo.print !== undefined) foo.print(); @@ -69,21 +58,11 @@ var test1 = {}; var test2 = {}; var test3 = {}; var test4 = {}; -var test5 = { - M: function () { - } -}; -var test6 = { - M: 5 -}; -var test7 = { - M: function () { - } -}; +var test5 = { M: function () { } }; +var test6 = { M: 5 }; +var test7 = { M: function () { } }; test7 = {}; -var test8 = { - M: 5 -}; +var test8 = { M: 5 }; test8 = {}; var test9_1; var test9_2; diff --git a/tests/baselines/reference/optionalSetterParam.js b/tests/baselines/reference/optionalSetterParam.js index 4b9b7f0136..1632f33be9 100644 --- a/tests/baselines/reference/optionalSetterParam.js +++ b/tests/baselines/reference/optionalSetterParam.js @@ -10,8 +10,7 @@ var foo = (function () { function foo() { } Object.defineProperty(foo.prototype, "bar", { - set: function (param) { - }, + set: function (param) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/orderMattersForSignatureGroupIdentity.js b/tests/baselines/reference/orderMattersForSignatureGroupIdentity.js index 66129a5d0b..9a04ea28fb 100644 --- a/tests/baselines/reference/orderMattersForSignatureGroupIdentity.js +++ b/tests/baselines/reference/orderMattersForSignatureGroupIdentity.js @@ -27,13 +27,7 @@ w({ s: "", n: 0 }).toLowerCase(); //// [orderMattersForSignatureGroupIdentity.js] var v; var v; -v({ - s: "", - n: 0 -}).toLowerCase(); +v({ s: "", n: 0 }).toLowerCase(); var w; var w; -w({ - s: "", - n: 0 -}).toLowerCase(); +w({ s: "", n: 0 }).toLowerCase(); diff --git a/tests/baselines/reference/overEagerReturnTypeSpecialization.js b/tests/baselines/reference/overEagerReturnTypeSpecialization.js index 3d91a6f2fa..90fcc388b7 100644 --- a/tests/baselines/reference/overEagerReturnTypeSpecialization.js +++ b/tests/baselines/reference/overEagerReturnTypeSpecialization.js @@ -16,15 +16,7 @@ var r2: I1 = v1.func(num => num.toString()) // Correctly returns an I1 -.func(function (str) { - return str.length; -}); // should error -var r2 = v1.func(function (num) { - return num.toString(); -}) // Correctly returns an I1 -.func(function (str) { - return str.length; -}); // should be ok +var r1 = v1.func(function (num) { return num.toString(); }) // Correctly returns an I1 + .func(function (str) { return str.length; }); // should error +var r2 = v1.func(function (num) { return num.toString(); }) // Correctly returns an I1 + .func(function (str) { return str.length; }); // should be ok diff --git a/tests/baselines/reference/overloadAssignmentCompat.js b/tests/baselines/reference/overloadAssignmentCompat.js index f6767f6f33..2d4bd93184 100644 --- a/tests/baselines/reference/overloadAssignmentCompat.js +++ b/tests/baselines/reference/overloadAssignmentCompat.js @@ -65,7 +65,5 @@ function attr2(nameOrMap, value) { return "s"; } } -function foo() { - return "a"; -} +function foo() { return "a"; } ; diff --git a/tests/baselines/reference/overloadCallTest.js b/tests/baselines/reference/overloadCallTest.js index f7eb97fc9e..38930b7aea 100644 --- a/tests/baselines/reference/overloadCallTest.js +++ b/tests/baselines/reference/overloadCallTest.js @@ -18,9 +18,7 @@ class foo { //// [overloadCallTest.js] var foo = (function () { function foo() { - function bar(foo) { - return "foo"; - } + function bar(foo) { return "foo"; } ; var test = bar("test"); var goo = bar(); diff --git a/tests/baselines/reference/overloadModifiersMustAgree.js b/tests/baselines/reference/overloadModifiersMustAgree.js index 8cb537c441..3f9f7eb141 100644 --- a/tests/baselines/reference/overloadModifiersMustAgree.js +++ b/tests/baselines/reference/overloadModifiersMustAgree.js @@ -19,9 +19,7 @@ interface I { var baz = (function () { function baz() { } - baz.prototype.foo = function (bar) { - }; // error - access modifiers do not agree + baz.prototype.foo = function (bar) { }; // error - access modifiers do not agree return baz; })(); -function bar(s) { -} +function bar(s) { } diff --git a/tests/baselines/reference/overloadOnConstConstraintChecks1.js b/tests/baselines/reference/overloadOnConstConstraintChecks1.js index a59ca2ceda..eb61358611 100644 --- a/tests/baselines/reference/overloadOnConstConstraintChecks1.js +++ b/tests/baselines/reference/overloadOnConstConstraintChecks1.js @@ -32,8 +32,7 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base() { } - Base.prototype.foo = function () { - }; + Base.prototype.foo = function () { }; return Base; })(); var Derived1 = (function (_super) { @@ -41,8 +40,7 @@ var Derived1 = (function (_super) { function Derived1() { _super.apply(this, arguments); } - Derived1.prototype.bar = function () { - }; + Derived1.prototype.bar = function () { }; return Derived1; })(Base); var Derived2 = (function (_super) { @@ -50,8 +48,7 @@ var Derived2 = (function (_super) { function Derived2() { _super.apply(this, arguments); } - Derived2.prototype.baz = function () { - }; + Derived2.prototype.baz = function () { }; return Derived2; })(Base); var Derived3 = (function (_super) { @@ -59,8 +56,7 @@ var Derived3 = (function (_super) { function Derived3() { _super.apply(this, arguments); } - Derived3.prototype.biz = function () { - }; + Derived3.prototype.biz = function () { }; return Derived3; })(Base); var D = (function () { diff --git a/tests/baselines/reference/overloadOnConstConstraintChecks2.js b/tests/baselines/reference/overloadOnConstConstraintChecks2.js index 071b937263..25759d0a83 100644 --- a/tests/baselines/reference/overloadOnConstConstraintChecks2.js +++ b/tests/baselines/reference/overloadOnConstConstraintChecks2.js @@ -35,8 +35,7 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(A); function foo(name) { diff --git a/tests/baselines/reference/overloadOnConstConstraintChecks3.js b/tests/baselines/reference/overloadOnConstConstraintChecks3.js index 961411bf6e..5980c852f4 100644 --- a/tests/baselines/reference/overloadOnConstConstraintChecks3.js +++ b/tests/baselines/reference/overloadOnConstConstraintChecks3.js @@ -37,8 +37,7 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(A); function foo(name) { diff --git a/tests/baselines/reference/overloadOnConstConstraintChecks4.js b/tests/baselines/reference/overloadOnConstConstraintChecks4.js index 5192afc35a..b2ae112575 100644 --- a/tests/baselines/reference/overloadOnConstConstraintChecks4.js +++ b/tests/baselines/reference/overloadOnConstConstraintChecks4.js @@ -45,8 +45,7 @@ var C = (function (_super) { function C() { _super.apply(this, arguments); } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(A); function foo(name) { diff --git a/tests/baselines/reference/overloadOnConstInObjectLiteralImplementingAnInterface.js b/tests/baselines/reference/overloadOnConstInObjectLiteralImplementingAnInterface.js index 4ef71de6d3..9bd8ca3a27 100644 --- a/tests/baselines/reference/overloadOnConstInObjectLiteralImplementingAnInterface.js +++ b/tests/baselines/reference/overloadOnConstInObjectLiteralImplementingAnInterface.js @@ -6,7 +6,4 @@ interface I { var i2: I = { x1: (a: number, cb: (x: 'hi') => number) => { } }; // error //// [overloadOnConstInObjectLiteralImplementingAnInterface.js] -var i2 = { - x1: function (a, cb) { - } -}; // error +var i2 = { x1: function (a, cb) { } }; // error diff --git a/tests/baselines/reference/overloadOnConstNoAnyImplementation.js b/tests/baselines/reference/overloadOnConstNoAnyImplementation.js index a17acae935..0c2f330b5e 100644 --- a/tests/baselines/reference/overloadOnConstNoAnyImplementation.js +++ b/tests/baselines/reference/overloadOnConstNoAnyImplementation.js @@ -24,13 +24,7 @@ function x1(a, cb) { cb('uh'); cb(1); // error } -var cb = function (x) { - return 1; -}; +var cb = function (x) { return 1; }; x1(1, cb); -x1(1, function (x) { - return 1; -}); // error -x1(1, function (x) { - return 1; -}); +x1(1, function (x) { return 1; }); // error +x1(1, function (x) { return 1; }); diff --git a/tests/baselines/reference/overloadOnConstNoAnyImplementation2.js b/tests/baselines/reference/overloadOnConstNoAnyImplementation2.js index 6c66c23f1f..52f6639e35 100644 --- a/tests/baselines/reference/overloadOnConstNoAnyImplementation2.js +++ b/tests/baselines/reference/overloadOnConstNoAnyImplementation2.js @@ -35,15 +35,7 @@ var C = (function () { return C; })(); var c; -c.x1(1, function (x) { - return 1; -}); -c.x1(1, function (x) { - return 1; -}); -c.x1(1, function (x) { - return 1; -}); -c.x1(1, function (x) { - return 1; -}); +c.x1(1, function (x) { return 1; }); +c.x1(1, function (x) { return 1; }); +c.x1(1, function (x) { return 1; }); +c.x1(1, function (x) { return 1; }); diff --git a/tests/baselines/reference/overloadOnConstNoNonSpecializedSignature.js b/tests/baselines/reference/overloadOnConstNoNonSpecializedSignature.js index 33cc9c81b2..980dfcb214 100644 --- a/tests/baselines/reference/overloadOnConstNoNonSpecializedSignature.js +++ b/tests/baselines/reference/overloadOnConstNoNonSpecializedSignature.js @@ -9,7 +9,6 @@ class C { var C = (function () { function C() { } - C.prototype.x1 = function (a) { - }; + C.prototype.x1 = function (a) { }; return C; })(); diff --git a/tests/baselines/reference/overloadOnConstNoStringImplementation.js b/tests/baselines/reference/overloadOnConstNoStringImplementation.js index 1fbf18d854..65fd6d0756 100644 --- a/tests/baselines/reference/overloadOnConstNoStringImplementation.js +++ b/tests/baselines/reference/overloadOnConstNoStringImplementation.js @@ -24,13 +24,7 @@ function x2(a, cb) { cb('uh'); cb(1); } -var cb = function (x) { - return 1; -}; +var cb = function (x) { return 1; }; x2(1, cb); // error -x2(1, function (x) { - return 1; -}); // error -x2(1, function (x) { - return 1; -}); +x2(1, function (x) { return 1; }); // error +x2(1, function (x) { return 1; }); diff --git a/tests/baselines/reference/overloadOnConstNoStringImplementation2.js b/tests/baselines/reference/overloadOnConstNoStringImplementation2.js index f51f84acb2..71d7a4e4a3 100644 --- a/tests/baselines/reference/overloadOnConstNoStringImplementation2.js +++ b/tests/baselines/reference/overloadOnConstNoStringImplementation2.js @@ -34,15 +34,7 @@ var C = (function () { return C; })(); var c; -c.x1(1, function (x) { - return 1; -}); -c.x1(1, function (x) { - return 1; -}); -c.x1(1, function (x) { - return 1; -}); -c.x1(1, function (x) { - return 1; -}); +c.x1(1, function (x) { return 1; }); +c.x1(1, function (x) { return 1; }); +c.x1(1, function (x) { return 1; }); +c.x1(1, function (x) { return 1; }); diff --git a/tests/baselines/reference/overloadOnConstantsInvalidOverload1.js b/tests/baselines/reference/overloadOnConstantsInvalidOverload1.js index f4037c3f66..cf9bc526b5 100644 --- a/tests/baselines/reference/overloadOnConstantsInvalidOverload1.js +++ b/tests/baselines/reference/overloadOnConstantsInvalidOverload1.js @@ -21,8 +21,7 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base() { } - Base.prototype.foo = function () { - }; + Base.prototype.foo = function () { }; return Base; })(); var Derived1 = (function (_super) { @@ -30,8 +29,7 @@ var Derived1 = (function (_super) { function Derived1() { _super.apply(this, arguments); } - Derived1.prototype.bar = function () { - }; + Derived1.prototype.bar = function () { }; return Derived1; })(Base); var Derived2 = (function (_super) { @@ -39,8 +37,7 @@ var Derived2 = (function (_super) { function Derived2() { _super.apply(this, arguments); } - Derived2.prototype.baz = function () { - }; + Derived2.prototype.baz = function () { }; return Derived2; })(Base); var Derived3 = (function (_super) { @@ -48,8 +45,7 @@ var Derived3 = (function (_super) { function Derived3() { _super.apply(this, arguments); } - Derived3.prototype.biz = function () { - }; + Derived3.prototype.biz = function () { }; return Derived3; })(Base); function foo(name) { diff --git a/tests/baselines/reference/overloadResolution.js b/tests/baselines/reference/overloadResolution.js index db042846c7..1ee5e077c0 100644 --- a/tests/baselines/reference/overloadResolution.js +++ b/tests/baselines/reference/overloadResolution.js @@ -127,16 +127,12 @@ var SomeDerived3 = (function (_super) { } return SomeDerived3; })(SomeBase); -function fn1() { - return null; -} +function fn1() { return null; } var s = fn1(undefined); var s; // No candidate overloads found fn1({}); // Error -function fn2() { - return undefined; -} +function fn2() { return undefined; } var d = fn2(0, undefined); var d; // Generic and non - generic overload where generic overload is the only candidate when called without type arguments @@ -145,9 +141,7 @@ var s = fn2(0, ''); fn2('', 0); // Error // Generic and non - generic overload where non - generic overload is the only candidate when called without type arguments fn2('', 0); // OK -function fn3() { - return null; -} +function fn3() { return null; } var s = fn3(3); var s = fn3('', 3, ''); var n = fn3(5, 5, 5); @@ -158,8 +152,7 @@ var s = fn3('', '', ''); var n = fn3('', '', 3); // Generic overloads with differing arity called with type argument count that doesn't match any overload fn3(); // Error -function fn4() { -} +function fn4() { } fn4('', 3); fn4(3, ''); // Error fn4('', 3); // Error @@ -174,12 +167,6 @@ fn4(null, null); // Error // Generic overloads with constraints called without type arguments but with types that do not satisfy the constraints fn4(true, null); // Error fn4(null, true); // Error -function fn5() { - return undefined; -} -var n = fn5(function (n) { - return n.toFixed(); -}); -var s = fn5(function (n) { - return n.substr(0); -}); +function fn5() { return undefined; } +var n = fn5(function (n) { return n.toFixed(); }); +var s = fn5(function (n) { return n.substr(0); }); diff --git a/tests/baselines/reference/overloadResolutionClassConstructors.js b/tests/baselines/reference/overloadResolutionClassConstructors.js index 8b4e4316fa..2571a0e02d 100644 --- a/tests/baselines/reference/overloadResolutionClassConstructors.js +++ b/tests/baselines/reference/overloadResolutionClassConstructors.js @@ -198,12 +198,6 @@ var fn5 = (function () { } return fn5; })(); -new fn5(function (n) { - return n.toFixed(); -}); -new fn5(function (n) { - return n.substr(0); -}); -new fn5(function (n) { - return n.blah; -}); // Error +new fn5(function (n) { return n.toFixed(); }); +new fn5(function (n) { return n.substr(0); }); +new fn5(function (n) { return n.blah; }); // Error diff --git a/tests/baselines/reference/overloadResolutionConstructors.js b/tests/baselines/reference/overloadResolutionConstructors.js index 3967016075..9e10215b1c 100644 --- a/tests/baselines/reference/overloadResolutionConstructors.js +++ b/tests/baselines/reference/overloadResolutionConstructors.js @@ -177,9 +177,5 @@ new fn4(null, null); // Error new fn4(true, null); // Error new fn4(null, true); // Error var fn5; -var n = new fn5(function (n) { - return n.toFixed(); -}); -var s = new fn5(function (n) { - return n.substr(0); -}); +var n = new fn5(function (n) { return n.toFixed(); }); +var s = new fn5(function (n) { return n.substr(0); }); diff --git a/tests/baselines/reference/overloadResolutionOverCTLambda.js b/tests/baselines/reference/overloadResolutionOverCTLambda.js index 84e8bb56ec..18ad08c9c8 100644 --- a/tests/baselines/reference/overloadResolutionOverCTLambda.js +++ b/tests/baselines/reference/overloadResolutionOverCTLambda.js @@ -3,8 +3,5 @@ function foo(b: (item: number) => boolean) { } foo(a => a); // can not convert (number)=>bool to (number)=>number //// [overloadResolutionOverCTLambda.js] -function foo(b) { -} -foo(function (a) { - return a; -}); // can not convert (number)=>bool to (number)=>number +function foo(b) { } +foo(function (a) { return a; }); // can not convert (number)=>bool to (number)=>number diff --git a/tests/baselines/reference/overloadResolutionOverNonCTLambdas.js b/tests/baselines/reference/overloadResolutionOverNonCTLambdas.js index 86e84ced58..170f2dd213 100644 --- a/tests/baselines/reference/overloadResolutionOverNonCTLambdas.js +++ b/tests/baselines/reference/overloadResolutionOverNonCTLambdas.js @@ -43,18 +43,14 @@ var Bugs; rest[_i - 1] = arguments[_i]; } var index = rest[0]; - return typeof args[index] !== 'undefined' ? args[index] : match; + return typeof args[index] !== 'undefined' + ? args[index] + : match; }); return result; } })(Bugs || (Bugs = {})); -function bug3(f) { - return f("s"); -} -function fprime(x) { - return x; -} +function bug3(f) { return f("s"); } +function fprime(x) { return x; } bug3(fprime); -bug3(function (x) { - return x; -}); +bug3(function (x) { return x; }); diff --git a/tests/baselines/reference/overloadResolutionOverNonCTObjectLit.js b/tests/baselines/reference/overloadResolutionOverNonCTObjectLit.js index e2b11529c3..cf125bebbf 100644 --- a/tests/baselines/reference/overloadResolutionOverNonCTObjectLit.js +++ b/tests/baselines/reference/overloadResolutionOverNonCTObjectLit.js @@ -26,17 +26,7 @@ var Bugs; (function (Bugs) { function bug3() { var tokens = []; - tokens.push({ - startIndex: 1, - type: '', - bracket: 3 - }); - tokens.push(({ - startIndex: 1, - type: '', - bracket: 3, - state: null, - length: 10 - })); + tokens.push({ startIndex: 1, type: '', bracket: 3 }); + tokens.push(({ startIndex: 1, type: '', bracket: 3, state: null, length: 10 })); } })(Bugs || (Bugs = {})); diff --git a/tests/baselines/reference/overloadResolutionTest1.js b/tests/baselines/reference/overloadResolutionTest1.js index 2d813e6eff..60b99ebf7b 100644 --- a/tests/baselines/reference/overloadResolutionTest1.js +++ b/tests/baselines/reference/overloadResolutionTest1.js @@ -26,47 +26,17 @@ function foo4(bar:{a:any;}):any{ return bar }; var x = foo4({a:true}); // error //// [overloadResolutionTest1.js] -function foo(bar) { - return bar; -} +function foo(bar) { return bar; } ; -var x1 = foo([ - { - a: true - } -]); // works -var x11 = foo([ - { - a: 0 - } -]); // works -var x111 = foo([ - { - a: "s" - } -]); // error - does not match any signature -var x1111 = foo([ - { - a: null - } -]); // works - ambiguous call is resolved to be the first in the overload set so this returns a string -function foo2(bar) { - return bar; -} +var x1 = foo([{ a: true }]); // works +var x11 = foo([{ a: 0 }]); // works +var x111 = foo([{ a: "s" }]); // error - does not match any signature +var x1111 = foo([{ a: null }]); // works - ambiguous call is resolved to be the first in the overload set so this returns a string +function foo2(bar) { return bar; } ; -var x2 = foo2({ - a: 0 -}); // works -var x3 = foo2({ - a: true -}); // works -var x4 = foo2({ - a: "s" -}); // error -function foo4(bar) { - return bar; -} +var x2 = foo2({ a: 0 }); // works +var x3 = foo2({ a: true }); // works +var x4 = foo2({ a: "s" }); // error +function foo4(bar) { return bar; } ; -var x = foo4({ - a: true -}); // error +var x = foo4({ a: true }); // error diff --git a/tests/baselines/reference/overloadWithCallbacksWithDifferingOptionalityOnArgs.js b/tests/baselines/reference/overloadWithCallbacksWithDifferingOptionalityOnArgs.js index 0a1a87091c..0306385526 100644 --- a/tests/baselines/reference/overloadWithCallbacksWithDifferingOptionalityOnArgs.js +++ b/tests/baselines/reference/overloadWithCallbacksWithDifferingOptionalityOnArgs.js @@ -7,11 +7,6 @@ x2((x) => 1 ); //// [overloadWithCallbacksWithDifferingOptionalityOnArgs.js] -function x2(callback) { -} -x2(function () { - return 1; -}); -x2(function (x) { - return 1; -}); +function x2(callback) { } +x2(function () { return 1; }); +x2(function (x) { return 1; }); diff --git a/tests/baselines/reference/overloadingOnConstants1.js b/tests/baselines/reference/overloadingOnConstants1.js index e325e7ad8c..7ebeeb2890 100644 --- a/tests/baselines/reference/overloadingOnConstants1.js +++ b/tests/baselines/reference/overloadingOnConstants1.js @@ -35,8 +35,7 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base() { } - Base.prototype.foo = function () { - }; + Base.prototype.foo = function () { }; return Base; })(); var Derived1 = (function (_super) { @@ -44,8 +43,7 @@ var Derived1 = (function (_super) { function Derived1() { _super.apply(this, arguments); } - Derived1.prototype.bar = function () { - }; + Derived1.prototype.bar = function () { }; return Derived1; })(Base); var Derived2 = (function (_super) { @@ -53,8 +51,7 @@ var Derived2 = (function (_super) { function Derived2() { _super.apply(this, arguments); } - Derived2.prototype.baz = function () { - }; + Derived2.prototype.baz = function () { }; return Derived2; })(Base); var Derived3 = (function (_super) { @@ -62,8 +59,7 @@ var Derived3 = (function (_super) { function Derived3() { _super.apply(this, arguments); } - Derived3.prototype.biz = function () { - }; + Derived3.prototype.biz = function () { }; return Derived3; })(Base); var d2; diff --git a/tests/baselines/reference/overloadingStaticFunctionsInFunctions.js b/tests/baselines/reference/overloadingStaticFunctionsInFunctions.js index 7e926a6250..591826725b 100644 --- a/tests/baselines/reference/overloadingStaticFunctionsInFunctions.js +++ b/tests/baselines/reference/overloadingStaticFunctionsInFunctions.js @@ -10,6 +10,5 @@ function boo() { test(); test(name, string); test(name ? : any); - { - } + { } } diff --git a/tests/baselines/reference/overloadresolutionWithConstraintCheckingDeferred.js b/tests/baselines/reference/overloadresolutionWithConstraintCheckingDeferred.js index 1eff021f56..63b4a2b1e9 100644 --- a/tests/baselines/reference/overloadresolutionWithConstraintCheckingDeferred.js +++ b/tests/baselines/reference/overloadresolutionWithConstraintCheckingDeferred.js @@ -28,12 +28,8 @@ var G = (function () { } return G; })(); -var result = foo(function (x) { - return new G(x); -}); // x has type D, new G(x) fails, so first overload is picked. -var result2 = foo(function (x) { - return new G(x); -}); // x has type D, new G(x) fails, so first overload is picked. +var result = foo(function (x) { return new G(x); }); // x has type D, new G(x) fails, so first overload is picked. +var result2 = foo(function (x) { return new G(x); }); // x has type D, new G(x) fails, so first overload is picked. var result3 = foo(function (x) { var y; // error that D does not satisfy constraint, y is of type G, entire call to foo is an error return y; diff --git a/tests/baselines/reference/overloadsInDifferentContainersDisagreeOnAmbient.js b/tests/baselines/reference/overloadsInDifferentContainersDisagreeOnAmbient.js index 4d0ac15c71..42c371dd21 100644 --- a/tests/baselines/reference/overloadsInDifferentContainersDisagreeOnAmbient.js +++ b/tests/baselines/reference/overloadsInDifferentContainersDisagreeOnAmbient.js @@ -11,7 +11,6 @@ module M { //// [overloadsInDifferentContainersDisagreeOnAmbient.js] var M; (function (M) { - function f() { - } + function f() { } M.f = f; })(M || (M = {})); diff --git a/tests/baselines/reference/overloadsWithProvisionalErrors.js b/tests/baselines/reference/overloadsWithProvisionalErrors.js index f684f1b12a..c7fb4785d0 100644 --- a/tests/baselines/reference/overloadsWithProvisionalErrors.js +++ b/tests/baselines/reference/overloadsWithProvisionalErrors.js @@ -10,17 +10,6 @@ func(s => ({ a: blah })); // Two errors here, one for blah not being defined, an //// [overloadsWithProvisionalErrors.js] var func; -func(function (s) { - return ({}); -}); // Error for no applicable overload (object type is missing a and b) -func(function (s) { - return ({ - a: blah, - b: 3 - }); -}); // Only error inside the function, but not outside (since it would be applicable if not for the provisional error) -func(function (s) { - return ({ - a: blah - }); -}); // Two errors here, one for blah not being defined, and one for the overload since it would not be applicable anyway +func(function (s) { return ({}); }); // Error for no applicable overload (object type is missing a and b) +func(function (s) { return ({ a: blah, b: 3 }); }); // Only error inside the function, but not outside (since it would be applicable if not for the provisional error) +func(function (s) { return ({ a: blah }); }); // Two errors here, one for blah not being defined, and one for the overload since it would not be applicable anyway diff --git a/tests/baselines/reference/overloadsWithinClasses.js b/tests/baselines/reference/overloadsWithinClasses.js index 79f3c332be..4ac612502c 100644 --- a/tests/baselines/reference/overloadsWithinClasses.js +++ b/tests/baselines/reference/overloadsWithinClasses.js @@ -27,17 +27,14 @@ class X { var foo = (function () { function foo() { } - foo.fnOverload = function () { - }; - foo.fnOverload = function (foo) { - }; // error + foo.fnOverload = function () { }; + foo.fnOverload = function (foo) { }; // error return foo; })(); var bar = (function () { function bar() { } - bar.fnOverload = function (foo) { - }; // no error + bar.fnOverload = function (foo) { }; // no error return bar; })(); var X = (function () { diff --git a/tests/baselines/reference/parameterInitializersForwardReferencing.js b/tests/baselines/reference/parameterInitializersForwardReferencing.js index 61b116980a..188a104f3a 100644 --- a/tests/baselines/reference/parameterInitializersForwardReferencing.js +++ b/tests/baselines/reference/parameterInitializersForwardReferencing.js @@ -74,17 +74,11 @@ function outside() { } } function defaultArgFunction(a, b) { - if (a === void 0) { a = function () { - return b; - }; } + if (a === void 0) { a = function () { return b; }; } if (b === void 0) { b = 1; } } function defaultArgArrow(a, b) { - if (a === void 0) { a = function () { - return function () { - return b; - }; - }; } + if (a === void 0) { a = function () { return function () { return b; }; }; } if (b === void 0) { b = 3; } } var C = (function () { @@ -107,8 +101,6 @@ var x = function (a, b, c) { }; // Should not produce errors - can reference later parameters if they occur within a function expression initializer. function f(a, b, c) { - if (b === void 0) { b = function () { - return c; - }; } + if (b === void 0) { b = function () { return c; }; } if (c === void 0) { c = b(); } } diff --git a/tests/baselines/reference/parametersWithNoAnnotationAreAny.js b/tests/baselines/reference/parametersWithNoAnnotationAreAny.js index d0b4846064..a8d06125d2 100644 --- a/tests/baselines/reference/parametersWithNoAnnotationAreAny.js +++ b/tests/baselines/reference/parametersWithNoAnnotationAreAny.js @@ -30,18 +30,10 @@ var b = { } //// [parametersWithNoAnnotationAreAny.js] -function foo(x) { - return x; -} -var f = function foo(x) { - return x; -}; -var f2 = function (x) { - return x; -}; -var f3 = function (x) { - return x; -}; +function foo(x) { return x; } +var f = function foo(x) { return x; }; +var f2 = function (x) { return x; }; +var f3 = function (x) { return x; }; var C = (function () { function C() { } @@ -58,7 +50,5 @@ var b = { a: function foo(x) { return x; }, - b: function (x) { - return x; - } + b: function (x) { return x; } }; diff --git a/tests/baselines/reference/parenthesizedContexualTyping1.js b/tests/baselines/reference/parenthesizedContexualTyping1.js index cd3a293739..2f1e9ff62f 100644 --- a/tests/baselines/reference/parenthesizedContexualTyping1.js +++ b/tests/baselines/reference/parenthesizedContexualTyping1.js @@ -33,82 +33,20 @@ var obj2: ObjType = ({ x: x => (x, undefined), y: y => (y, undefined) }); function fun(g, x) { return g(x); } -var a = fun(function (x) { - return x; -}, 10); -var b = fun((function (x) { - return x; -}), 10); -var c = fun(((function (x) { - return x; -})), 10); -var d = fun((((function (x) { - return x; -}))), 10); -var e = fun(function (x) { - return x; -}, function (x) { - return x; -}, 10); -var f = fun((function (x) { - return x; -}), (function (x) { - return x; -}), 10); -var g = fun(((function (x) { - return x; -})), ((function (x) { - return x; -})), 10); -var h = fun((((function (x) { - return x; -}))), ((function (x) { - return x; -})), 10); +var a = fun(function (x) { return x; }, 10); +var b = fun((function (x) { return x; }), 10); +var c = fun(((function (x) { return x; })), 10); +var d = fun((((function (x) { return x; }))), 10); +var e = fun(function (x) { return x; }, function (x) { return x; }, 10); +var f = fun((function (x) { return x; }), (function (x) { return x; }), 10); +var g = fun(((function (x) { return x; })), ((function (x) { return x; })), 10); +var h = fun((((function (x) { return x; }))), ((function (x) { return x; })), 10); // Ternaries in parens -var i = fun((Math.random() < 0.5 ? function (x) { - return x; -} : function (x) { - return undefined; -}), 10); -var j = fun((Math.random() < 0.5 ? (function (x) { - return x; -}) : (function (x) { - return undefined; -})), 10); -var k = fun((Math.random() < 0.5 ? (function (x) { - return x; -}) : (function (x) { - return undefined; -})), function (x) { - return x; -}, 10); -var l = fun(((Math.random() < 0.5 ? ((function (x) { - return x; -})) : ((function (x) { - return undefined; -})))), ((function (x) { - return x; -})), 10); -var lambda1 = function (x) { - return x; -}; -var lambda2 = (function (x) { - return x; -}); -var obj1 = { - x: function (x) { - return (x, undefined); - }, - y: function (y) { - return (y, undefined); - } -}; -var obj2 = ({ - x: function (x) { - return (x, undefined); - }, - y: function (y) { - return (y, undefined); - } -}); +var i = fun((Math.random() < 0.5 ? function (x) { return x; } : function (x) { return undefined; }), 10); +var j = fun((Math.random() < 0.5 ? (function (x) { return x; }) : (function (x) { return undefined; })), 10); +var k = fun((Math.random() < 0.5 ? (function (x) { return x; }) : (function (x) { return undefined; })), function (x) { return x; }, 10); +var l = fun(((Math.random() < 0.5 ? ((function (x) { return x; })) : ((function (x) { return undefined; })))), ((function (x) { return x; })), 10); +var lambda1 = function (x) { return x; }; +var lambda2 = (function (x) { return x; }); +var obj1 = { x: function (x) { return (x, undefined); }, y: function (y) { return (y, undefined); } }; +var obj2 = ({ x: function (x) { return (x, undefined); }, y: function (y) { return (y, undefined); } }); diff --git a/tests/baselines/reference/parenthesizedContexualTyping2.js b/tests/baselines/reference/parenthesizedContexualTyping2.js index 68aa28386e..993a10ba49 100644 --- a/tests/baselines/reference/parenthesizedContexualTyping2.js +++ b/tests/baselines/reference/parenthesizedContexualTyping2.js @@ -49,102 +49,20 @@ function fun() { } return undefined; } -var a = fun(function (x) { - x(undefined); - return x; -}, 10); -var b = fun((function (x) { - x(undefined); - return x; -}), 10); -var c = fun(((function (x) { - x(undefined); - return x; -})), 10); -var d = fun((((function (x) { - x(undefined); - return x; -}))), 10); -var e = fun(function (x) { - x(undefined); - return x; -}, function (x) { - x(undefined); - return x; -}, 10); -var f = fun((function (x) { - x(undefined); - return x; -}), (function (x) { - x(undefined); - return x; -}), 10); -var g = fun(((function (x) { - x(undefined); - return x; -})), ((function (x) { - x(undefined); - return x; -})), 10); -var h = fun((((function (x) { - x(undefined); - return x; -}))), ((function (x) { - x(undefined); - return x; -})), 10); +var a = fun(function (x) { x(undefined); return x; }, 10); +var b = fun((function (x) { x(undefined); return x; }), 10); +var c = fun(((function (x) { x(undefined); return x; })), 10); +var d = fun((((function (x) { x(undefined); return x; }))), 10); +var e = fun(function (x) { x(undefined); return x; }, function (x) { x(undefined); return x; }, 10); +var f = fun((function (x) { x(undefined); return x; }), (function (x) { x(undefined); return x; }), 10); +var g = fun(((function (x) { x(undefined); return x; })), ((function (x) { x(undefined); return x; })), 10); +var h = fun((((function (x) { x(undefined); return x; }))), ((function (x) { x(undefined); return x; })), 10); // Ternaries in parens -var i = fun((Math.random() < 0.5 ? function (x) { - x(undefined); - return x; -} : function (x) { - return undefined; -}), 10); -var j = fun((Math.random() < 0.5 ? (function (x) { - x(undefined); - return x; -}) : (function (x) { - return undefined; -})), 10); -var k = fun((Math.random() < 0.5 ? (function (x) { - x(undefined); - return x; -}) : (function (x) { - return undefined; -})), function (x) { - x(undefined); - return x; -}, 10); -var l = fun(((Math.random() < 0.5 ? ((function (x) { - x(undefined); - return x; -})) : ((function (x) { - return undefined; -})))), ((function (x) { - x(undefined); - return x; -})), 10); -var lambda1 = function (x) { - x(undefined); - return x; -}; -var lambda2 = (function (x) { - x(undefined); - return x; -}); -var obj1 = { - x: function (x) { - return (x, undefined); - }, - y: function (y) { - return (y, undefined); - } -}; -var obj2 = ({ - x: function (x) { - return (x, undefined); - }, - y: function (y) { - return (y, undefined); - } -}); +var i = fun((Math.random() < 0.5 ? function (x) { x(undefined); return x; } : function (x) { return undefined; }), 10); +var j = fun((Math.random() < 0.5 ? (function (x) { x(undefined); return x; }) : (function (x) { return undefined; })), 10); +var k = fun((Math.random() < 0.5 ? (function (x) { x(undefined); return x; }) : (function (x) { return undefined; })), function (x) { x(undefined); return x; }, 10); +var l = fun(((Math.random() < 0.5 ? ((function (x) { x(undefined); return x; })) : ((function (x) { return undefined; })))), ((function (x) { x(undefined); return x; })), 10); +var lambda1 = function (x) { x(undefined); return x; }; +var lambda2 = (function (x) { x(undefined); return x; }); +var obj1 = { x: function (x) { return (x, undefined); }, y: function (y) { return (y, undefined); } }; +var obj2 = ({ x: function (x) { return (x, undefined); }, y: function (y) { return (y, undefined); } }); diff --git a/tests/baselines/reference/parse1.js b/tests/baselines/reference/parse1.js index 08af81bda1..4804e31adc 100644 --- a/tests/baselines/reference/parse1.js +++ b/tests/baselines/reference/parse1.js @@ -8,5 +8,6 @@ function foo() { //// [parse1.js] var bar = 42; function foo() { - bar.; + bar. + ; } diff --git a/tests/baselines/reference/parseClassDeclarationInStrictModeByDefaultInES6.js b/tests/baselines/reference/parseClassDeclarationInStrictModeByDefaultInES6.js index 2a8d75dde6..4a80f478b4 100644 --- a/tests/baselines/reference/parseClassDeclarationInStrictModeByDefaultInES6.js +++ b/tests/baselines/reference/parseClassDeclarationInStrictModeByDefaultInES6.js @@ -13,10 +13,8 @@ class C { constructor() { this.interface = 10; } - implements() { - } - foo(arguments) { - } + implements() { } + foo(arguments) { } bar(eval) { arguments = "hello"; } diff --git a/tests/baselines/reference/parseTypes.js b/tests/baselines/reference/parseTypes.js index 193533de04..08cc9f2a6b 100644 --- a/tests/baselines/reference/parseTypes.js +++ b/tests/baselines/reference/parseTypes.js @@ -18,13 +18,9 @@ var x = null; var y = null; var z = null; var w = null; -function f() { - return 3; -} +function f() { return 3; } ; -function g(s) { - true; -} +function g(s) { true; } ; y = f; y = g; diff --git a/tests/baselines/reference/parser15.4.4.14-9-2.js b/tests/baselines/reference/parser15.4.4.14-9-2.js index e9a29e7eea..0f533cd9a2 100644 --- a/tests/baselines/reference/parser15.4.4.14-9-2.js +++ b/tests/baselines/reference/parser15.4.4.14-9-2.js @@ -37,15 +37,14 @@ runTestCase(testcase); * @description Array.prototype.indexOf must return correct index (Number) */ function testcase() { - var obj = { - toString: function () { - return 0; - } - }; + var obj = { toString: function () { return 0; } }; var one = 1; var _float = -(4 / 3); var a = new Array(false, undefined, null, "0", obj, -1.3333333333333, "str", -0, true, +0, one, 1, 0, false, _float, -(4 / 3)); - if (a.indexOf(-(4 / 3)) === 14 && a.indexOf(0) === 7 && a.indexOf(-0) === 7 && a.indexOf(1) === 10) { + if (a.indexOf(-(4 / 3)) === 14 && + a.indexOf(0) === 7 && + a.indexOf(-0) === 7 && + a.indexOf(1) === 10) { return true; } } diff --git a/tests/baselines/reference/parser509667.js b/tests/baselines/reference/parser509667.js index 21e0bc55ce..0938613b29 100644 --- a/tests/baselines/reference/parser509667.js +++ b/tests/baselines/reference/parser509667.js @@ -16,7 +16,8 @@ var Foo = (function () { function Foo() { } Foo.prototype.f1 = function () { - if (this.) + if (this. + ) ; }; Foo.prototype.f2 = function () { diff --git a/tests/baselines/reference/parser509669.js b/tests/baselines/reference/parser509669.js index e4ce2b9031..3fa4cf696c 100644 --- a/tests/baselines/reference/parser509669.js +++ b/tests/baselines/reference/parser509669.js @@ -5,6 +5,5 @@ function foo():any { //// [parser509669.js] function foo() { - return function () { - }; + return function () { }; } diff --git a/tests/baselines/reference/parser512097.js b/tests/baselines/reference/parser512097.js index c495e68c84..ce73dadf3b 100644 --- a/tests/baselines/reference/parser512097.js +++ b/tests/baselines/reference/parser512097.js @@ -5,8 +5,6 @@ if (true) { } //// [parser512097.js] -var tt = { - aa: -}; // After this point, no useful parsing occurs in the entire file +var tt = { aa: }; // After this point, no useful parsing occurs in the entire file if (true) { } diff --git a/tests/baselines/reference/parser521128.js b/tests/baselines/reference/parser521128.js index e16cbad6c3..2471f740d7 100644 --- a/tests/baselines/reference/parser521128.js +++ b/tests/baselines/reference/parser521128.js @@ -3,5 +3,4 @@ module.module { } //// [parser521128.js] module.module; -{ -} +{ } diff --git a/tests/baselines/reference/parser536727.js b/tests/baselines/reference/parser536727.js index 39b0d66f6c..fe086d8d3b 100644 --- a/tests/baselines/reference/parser536727.js +++ b/tests/baselines/reference/parser536727.js @@ -13,14 +13,8 @@ foo(x); function foo(f) { return f(""); } -var g = function (x) { - return x + "blah"; -}; -var x = function () { - return g; -}; +var g = function (x) { return x + "blah"; }; +var x = function () { return g; }; foo(g); -foo(function () { - return g; -}); +foo(function () { return g; }); foo(x); diff --git a/tests/baselines/reference/parser553699.js b/tests/baselines/reference/parser553699.js index f245ecc344..8570780e74 100644 --- a/tests/baselines/reference/parser553699.js +++ b/tests/baselines/reference/parser553699.js @@ -12,8 +12,7 @@ class Bar { var Foo = (function () { function Foo() { } - Foo.prototype.banana = function (x) { - }; + Foo.prototype.banana = function (x) { }; return Foo; })(); var Bar = (function () { diff --git a/tests/baselines/reference/parserAccessibilityAfterStatic10.js b/tests/baselines/reference/parserAccessibilityAfterStatic10.js index feded66fe9..6756a57ce7 100644 --- a/tests/baselines/reference/parserAccessibilityAfterStatic10.js +++ b/tests/baselines/reference/parserAccessibilityAfterStatic10.js @@ -9,7 +9,6 @@ static public intI() {} var Outer = (function () { function Outer() { } - Outer.intI = function () { - }; + Outer.intI = function () { }; return Outer; })(); diff --git a/tests/baselines/reference/parserAccessibilityAfterStatic11.js b/tests/baselines/reference/parserAccessibilityAfterStatic11.js index 094202014a..8b16153b79 100644 --- a/tests/baselines/reference/parserAccessibilityAfterStatic11.js +++ b/tests/baselines/reference/parserAccessibilityAfterStatic11.js @@ -9,7 +9,6 @@ static public() {} var Outer = (function () { function Outer() { } - Outer.public = function () { - }; + Outer.public = function () { }; return Outer; })(); diff --git a/tests/baselines/reference/parserAccessibilityAfterStatic14.js b/tests/baselines/reference/parserAccessibilityAfterStatic14.js index b2a6be7464..4455936a85 100644 --- a/tests/baselines/reference/parserAccessibilityAfterStatic14.js +++ b/tests/baselines/reference/parserAccessibilityAfterStatic14.js @@ -9,7 +9,6 @@ static public() {} var Outer = (function () { function Outer() { } - Outer.public = function () { - }; + Outer.public = function () { }; return Outer; })(); diff --git a/tests/baselines/reference/parserAccessibilityAfterStatic7.js b/tests/baselines/reference/parserAccessibilityAfterStatic7.js index a2bc5c7fba..2d94be8ea5 100644 --- a/tests/baselines/reference/parserAccessibilityAfterStatic7.js +++ b/tests/baselines/reference/parserAccessibilityAfterStatic7.js @@ -9,7 +9,6 @@ static public intI() {} var Outer = (function () { function Outer() { } - Outer.intI = function () { - }; + Outer.intI = function () { }; return Outer; })(); diff --git a/tests/baselines/reference/parserAccessors1.js b/tests/baselines/reference/parserAccessors1.js index b4cc809e7b..6b47a46ede 100644 --- a/tests/baselines/reference/parserAccessors1.js +++ b/tests/baselines/reference/parserAccessors1.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserAccessors10.js b/tests/baselines/reference/parserAccessors10.js index f1bed41ede..d5d7e89a7d 100644 --- a/tests/baselines/reference/parserAccessors10.js +++ b/tests/baselines/reference/parserAccessors10.js @@ -5,6 +5,5 @@ var v = { //// [parserAccessors10.js] var v = { - get foo() { - } + get foo() { } }; diff --git a/tests/baselines/reference/parserAccessors2.js b/tests/baselines/reference/parserAccessors2.js index 71cbd6f466..482daa74a6 100644 --- a/tests/baselines/reference/parserAccessors2.js +++ b/tests/baselines/reference/parserAccessors2.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserAccessors3.js b/tests/baselines/reference/parserAccessors3.js index f5f9c43fb4..287f607725 100644 --- a/tests/baselines/reference/parserAccessors3.js +++ b/tests/baselines/reference/parserAccessors3.js @@ -2,7 +2,4 @@ var v = { get Foo() { } }; //// [parserAccessors3.js] -var v = { - get Foo() { - } -}; +var v = { get Foo() { } }; diff --git a/tests/baselines/reference/parserAccessors4.js b/tests/baselines/reference/parserAccessors4.js index 24ee1bbcdc..0716078a8c 100644 --- a/tests/baselines/reference/parserAccessors4.js +++ b/tests/baselines/reference/parserAccessors4.js @@ -2,7 +2,4 @@ var v = { set Foo(a) { } }; //// [parserAccessors4.js] -var v = { - set Foo(a) { - } -}; +var v = { set Foo(a) { } }; diff --git a/tests/baselines/reference/parserAccessors7.js b/tests/baselines/reference/parserAccessors7.js index be3802979b..4b7f2d5586 100644 --- a/tests/baselines/reference/parserAccessors7.js +++ b/tests/baselines/reference/parserAccessors7.js @@ -2,7 +2,4 @@ var v = { get foo(v: number) { } }; //// [parserAccessors7.js] -var v = { - get foo(v) { - } -}; +var v = { get foo(v) { } }; diff --git a/tests/baselines/reference/parserAccessors8.js b/tests/baselines/reference/parserAccessors8.js index 3bb926521e..18fb445407 100644 --- a/tests/baselines/reference/parserAccessors8.js +++ b/tests/baselines/reference/parserAccessors8.js @@ -2,7 +2,4 @@ var v = { set foo() { } } //// [parserAccessors8.js] -var v = { - set foo() { - } -}; +var v = { set foo() { } }; diff --git a/tests/baselines/reference/parserAccessors9.js b/tests/baselines/reference/parserAccessors9.js index ad52d9827b..448d93a2c0 100644 --- a/tests/baselines/reference/parserAccessors9.js +++ b/tests/baselines/reference/parserAccessors9.js @@ -2,7 +2,4 @@ var v = { set foo(a, b) { } } //// [parserAccessors9.js] -var v = { - set foo(a, b) { - } -}; +var v = { set foo(a, b) { } }; diff --git a/tests/baselines/reference/parserAmbiguityWithBinaryOperator1.js b/tests/baselines/reference/parserAmbiguityWithBinaryOperator1.js index 18a1dee3e9..6c74814917 100644 --- a/tests/baselines/reference/parserAmbiguityWithBinaryOperator1.js +++ b/tests/baselines/reference/parserAmbiguityWithBinaryOperator1.js @@ -7,6 +7,5 @@ function f1() { //// [parserAmbiguityWithBinaryOperator1.js] function f1() { var a, b, c; - if (a < b || b > (c + 1)) { - } + if (a < b || b > (c + 1)) { } } diff --git a/tests/baselines/reference/parserAmbiguityWithBinaryOperator2.js b/tests/baselines/reference/parserAmbiguityWithBinaryOperator2.js index 9589d57e3a..6cd6de58d4 100644 --- a/tests/baselines/reference/parserAmbiguityWithBinaryOperator2.js +++ b/tests/baselines/reference/parserAmbiguityWithBinaryOperator2.js @@ -7,6 +7,5 @@ function f() { //// [parserAmbiguityWithBinaryOperator2.js] function f() { var a, b, c; - if (a < b && b > (c + 1)) { - } + if (a < b && b > (c + 1)) { } } diff --git a/tests/baselines/reference/parserAmbiguityWithBinaryOperator3.js b/tests/baselines/reference/parserAmbiguityWithBinaryOperator3.js index 95745263c7..e3df289477 100644 --- a/tests/baselines/reference/parserAmbiguityWithBinaryOperator3.js +++ b/tests/baselines/reference/parserAmbiguityWithBinaryOperator3.js @@ -8,6 +8,5 @@ function f() { //// [parserAmbiguityWithBinaryOperator3.js] function f() { var a, b, c; - if (a < b && b < (c + 1)) { - } + if (a < b && b < (c + 1)) { } } diff --git a/tests/baselines/reference/parserAmbiguityWithBinaryOperator4.js b/tests/baselines/reference/parserAmbiguityWithBinaryOperator4.js index cdcec030ae..a6ba380112 100644 --- a/tests/baselines/reference/parserAmbiguityWithBinaryOperator4.js +++ b/tests/baselines/reference/parserAmbiguityWithBinaryOperator4.js @@ -7,6 +7,5 @@ function g() { //// [parserAmbiguityWithBinaryOperator4.js] function g() { var a, b, c; - if (a(c + 1)) { - } + if (a(c + 1)) { } } diff --git a/tests/baselines/reference/parserArrayLiteralExpression10.js b/tests/baselines/reference/parserArrayLiteralExpression10.js index 5f49958b86..986d3045dc 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression10.js +++ b/tests/baselines/reference/parserArrayLiteralExpression10.js @@ -2,7 +2,4 @@ var v = [1,1,]; //// [parserArrayLiteralExpression10.js] -var v = [ - 1, - 1, -]; +var v = [1, 1,]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression11.js b/tests/baselines/reference/parserArrayLiteralExpression11.js index 79b4bf3518..24ab8968fe 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression11.js +++ b/tests/baselines/reference/parserArrayLiteralExpression11.js @@ -2,8 +2,4 @@ var v = [1,,1]; //// [parserArrayLiteralExpression11.js] -var v = [ - 1, - , - 1 -]; +var v = [1, , 1]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression12.js b/tests/baselines/reference/parserArrayLiteralExpression12.js index 1ad1bc4012..6795ef2990 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression12.js +++ b/tests/baselines/reference/parserArrayLiteralExpression12.js @@ -2,9 +2,4 @@ var v = [1,,,1]; //// [parserArrayLiteralExpression12.js] -var v = [ - 1, - , - , - 1 -]; +var v = [1, , , 1]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression13.js b/tests/baselines/reference/parserArrayLiteralExpression13.js index 78b0854828..504663e5ce 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression13.js +++ b/tests/baselines/reference/parserArrayLiteralExpression13.js @@ -2,10 +2,4 @@ var v = [1,,1,,1]; //// [parserArrayLiteralExpression13.js] -var v = [ - 1, - , - 1, - , - 1 -]; +var v = [1, , 1, , 1]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression14.js b/tests/baselines/reference/parserArrayLiteralExpression14.js index 188b9e734f..eeb13dc53a 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression14.js +++ b/tests/baselines/reference/parserArrayLiteralExpression14.js @@ -2,16 +2,4 @@ var v = [,,1,1,,1,,1,1,,1]; //// [parserArrayLiteralExpression14.js] -var v = [ - , - , - 1, - 1, - , - 1, - , - 1, - 1, - , - 1 -]; +var v = [, , 1, 1, , 1, , 1, 1, , 1]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression15.js b/tests/baselines/reference/parserArrayLiteralExpression15.js index 4894a874be..84ab9dac24 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression15.js +++ b/tests/baselines/reference/parserArrayLiteralExpression15.js @@ -2,16 +2,4 @@ var v = [,,1,1,,1,,1,1,,1,]; //// [parserArrayLiteralExpression15.js] -var v = [ - , - , - 1, - 1, - , - 1, - , - 1, - 1, - , - 1, -]; +var v = [, , 1, 1, , 1, , 1, 1, , 1,]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression2.js b/tests/baselines/reference/parserArrayLiteralExpression2.js index 587b4180ec..1fb26155eb 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression2.js +++ b/tests/baselines/reference/parserArrayLiteralExpression2.js @@ -2,6 +2,4 @@ var v = [,]; //// [parserArrayLiteralExpression2.js] -var v = [ - , -]; +var v = [,]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression3.js b/tests/baselines/reference/parserArrayLiteralExpression3.js index 45a9c945ba..2d7d19fc2c 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression3.js +++ b/tests/baselines/reference/parserArrayLiteralExpression3.js @@ -2,7 +2,4 @@ var v = [,,]; //// [parserArrayLiteralExpression3.js] -var v = [ - , - , -]; +var v = [, ,]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression4.js b/tests/baselines/reference/parserArrayLiteralExpression4.js index 7a69500ba7..2287897338 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression4.js +++ b/tests/baselines/reference/parserArrayLiteralExpression4.js @@ -2,8 +2,4 @@ var v = [,,,]; //// [parserArrayLiteralExpression4.js] -var v = [ - , - , - , -]; +var v = [, , ,]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression5.js b/tests/baselines/reference/parserArrayLiteralExpression5.js index 1affdb1ac3..43b784b2e5 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression5.js +++ b/tests/baselines/reference/parserArrayLiteralExpression5.js @@ -2,6 +2,4 @@ var v = [1]; //// [parserArrayLiteralExpression5.js] -var v = [ - 1 -]; +var v = [1]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression6.js b/tests/baselines/reference/parserArrayLiteralExpression6.js index b5831c7345..28cd901f4a 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression6.js +++ b/tests/baselines/reference/parserArrayLiteralExpression6.js @@ -2,7 +2,4 @@ var v = [,1]; //// [parserArrayLiteralExpression6.js] -var v = [ - , - 1 -]; +var v = [, 1]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression7.js b/tests/baselines/reference/parserArrayLiteralExpression7.js index e10cf021a7..b302e87e35 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression7.js +++ b/tests/baselines/reference/parserArrayLiteralExpression7.js @@ -2,6 +2,4 @@ var v = [1,]; //// [parserArrayLiteralExpression7.js] -var v = [ - 1, -]; +var v = [1,]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression8.js b/tests/baselines/reference/parserArrayLiteralExpression8.js index 6d8b252521..223a86db22 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression8.js +++ b/tests/baselines/reference/parserArrayLiteralExpression8.js @@ -2,7 +2,4 @@ var v = [,1,]; //// [parserArrayLiteralExpression8.js] -var v = [ - , - 1, -]; +var v = [, 1,]; diff --git a/tests/baselines/reference/parserArrayLiteralExpression9.js b/tests/baselines/reference/parserArrayLiteralExpression9.js index d44d072eb5..5043f522dd 100644 --- a/tests/baselines/reference/parserArrayLiteralExpression9.js +++ b/tests/baselines/reference/parserArrayLiteralExpression9.js @@ -2,7 +2,4 @@ var v = [1,1]; //// [parserArrayLiteralExpression9.js] -var v = [ - 1, - 1 -]; +var v = [1, 1]; diff --git a/tests/baselines/reference/parserArrowFunctionExpression1.js b/tests/baselines/reference/parserArrowFunctionExpression1.js index 5ab29fee64..e4ae59fdb9 100644 --- a/tests/baselines/reference/parserArrowFunctionExpression1.js +++ b/tests/baselines/reference/parserArrowFunctionExpression1.js @@ -2,5 +2,4 @@ var v = (public x: string) => { }; //// [parserArrowFunctionExpression1.js] -var v = function (x) { -}; +var v = function (x) { }; diff --git a/tests/baselines/reference/parserArrowFunctionExpression2.js b/tests/baselines/reference/parserArrowFunctionExpression2.js index 5059cf3218..9004468ec7 100644 --- a/tests/baselines/reference/parserArrowFunctionExpression2.js +++ b/tests/baselines/reference/parserArrowFunctionExpression2.js @@ -2,6 +2,5 @@ a = () => { } || a //// [parserArrowFunctionExpression2.js] -a = function () { -}; +a = function () { }; || a; diff --git a/tests/baselines/reference/parserArrowFunctionExpression3.js b/tests/baselines/reference/parserArrowFunctionExpression3.js index 68ea230d87..9e6b270610 100644 --- a/tests/baselines/reference/parserArrowFunctionExpression3.js +++ b/tests/baselines/reference/parserArrowFunctionExpression3.js @@ -2,5 +2,4 @@ a = (() => { } || a) //// [parserArrowFunctionExpression3.js] -a = (function () { -}) || a; +a = (function () { }) || a; diff --git a/tests/baselines/reference/parserArrowFunctionExpression4.js b/tests/baselines/reference/parserArrowFunctionExpression4.js index 53aaee9e6f..e77a42162c 100644 --- a/tests/baselines/reference/parserArrowFunctionExpression4.js +++ b/tests/baselines/reference/parserArrowFunctionExpression4.js @@ -2,5 +2,4 @@ a = (() => { }, a) //// [parserArrowFunctionExpression4.js] -a = (function () { -}, a); +a = (function () { }, a); diff --git a/tests/baselines/reference/parserCastVersusArrowFunction1.js b/tests/baselines/reference/parserCastVersusArrowFunction1.js index 63a19924d3..df46753b9e 100644 --- a/tests/baselines/reference/parserCastVersusArrowFunction1.js +++ b/tests/baselines/reference/parserCastVersusArrowFunction1.js @@ -11,16 +11,10 @@ var v = (a, b); var v = (a = 1, b = 2); //// [parserCastVersusArrowFunction1.js] -var v = function () { - return 1; -}; +var v = function () { return 1; }; var v = a; -var v = function (a) { - return 1; -}; -var v = function (a, b) { - return 1; -}; +var v = function (a) { return 1; }; +var v = function (a, b) { return 1; }; var v = function (a, b) { if (a === void 0) { a = 1; } if (b === void 0) { b = 2; } diff --git a/tests/baselines/reference/parserClass1.js b/tests/baselines/reference/parserClass1.js index 1245da3363..eb1d17566a 100644 --- a/tests/baselines/reference/parserClass1.js +++ b/tests/baselines/reference/parserClass1.js @@ -13,21 +13,11 @@ var NullLogger = (function () { function NullLogger() { } - NullLogger.prototype.information = function () { - return false; - }; - NullLogger.prototype.debug = function () { - return false; - }; - NullLogger.prototype.warning = function () { - return false; - }; - NullLogger.prototype.error = function () { - return false; - }; - NullLogger.prototype.fatal = function () { - return false; - }; + NullLogger.prototype.information = function () { return false; }; + NullLogger.prototype.debug = function () { return false; }; + NullLogger.prototype.warning = function () { return false; }; + NullLogger.prototype.error = function () { return false; }; + NullLogger.prototype.fatal = function () { return false; }; NullLogger.prototype.log = function (s) { }; return NullLogger; diff --git a/tests/baselines/reference/parserClassDeclaration11.js b/tests/baselines/reference/parserClassDeclaration11.js index 80a27d71e6..078d3553a4 100644 --- a/tests/baselines/reference/parserClassDeclaration11.js +++ b/tests/baselines/reference/parserClassDeclaration11.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserClassDeclaration13.js b/tests/baselines/reference/parserClassDeclaration13.js index dcb704ae1d..93ce76fb16 100644 --- a/tests/baselines/reference/parserClassDeclaration13.js +++ b/tests/baselines/reference/parserClassDeclaration13.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype.bar = function () { - }; + C.prototype.bar = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserClassDeclaration16.js b/tests/baselines/reference/parserClassDeclaration16.js index 7048980597..a6a92d73af 100644 --- a/tests/baselines/reference/parserClassDeclaration16.js +++ b/tests/baselines/reference/parserClassDeclaration16.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserClassDeclaration19.js b/tests/baselines/reference/parserClassDeclaration19.js index 5b77e263ec..7900aa4d55 100644 --- a/tests/baselines/reference/parserClassDeclaration19.js +++ b/tests/baselines/reference/parserClassDeclaration19.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype["foo"] = function () { - }; + C.prototype["foo"] = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserClassDeclaration20.js b/tests/baselines/reference/parserClassDeclaration20.js index 68d97b66bb..7c99f2d8ee 100644 --- a/tests/baselines/reference/parserClassDeclaration20.js +++ b/tests/baselines/reference/parserClassDeclaration20.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype["0"] = function () { - }; + C.prototype["0"] = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserClassDeclaration21.js b/tests/baselines/reference/parserClassDeclaration21.js index 248f10e868..fa4cef46e0 100644 --- a/tests/baselines/reference/parserClassDeclaration21.js +++ b/tests/baselines/reference/parserClassDeclaration21.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype[1] = function () { - }; + C.prototype[1] = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserClassDeclaration22.js b/tests/baselines/reference/parserClassDeclaration22.js index 60f708d483..596f7a4474 100644 --- a/tests/baselines/reference/parserClassDeclaration22.js +++ b/tests/baselines/reference/parserClassDeclaration22.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype["bar"] = function () { - }; + C.prototype["bar"] = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserCommaInTypeMemberList2.js b/tests/baselines/reference/parserCommaInTypeMemberList2.js index 9593bdea98..fd79326b7b 100644 --- a/tests/baselines/reference/parserCommaInTypeMemberList2.js +++ b/tests/baselines/reference/parserCommaInTypeMemberList2.js @@ -3,6 +3,4 @@ var s = $.extend< { workItem: any }, { workItem: any, width: string }>({ workIte //// [parserCommaInTypeMemberList2.js] -var s = $.extend({ - workItem: this._workItem -}, {}); +var s = $.extend({ workItem: this._workItem }, {}); diff --git a/tests/baselines/reference/parserComputedPropertyName1.js b/tests/baselines/reference/parserComputedPropertyName1.js index 4a42b2e97e..ee5b0a22cb 100644 --- a/tests/baselines/reference/parserComputedPropertyName1.js +++ b/tests/baselines/reference/parserComputedPropertyName1.js @@ -2,6 +2,4 @@ var v = { [e] }; //// [parserComputedPropertyName1.js] -var v = { - [e]: -}; +var v = { [e]: }; diff --git a/tests/baselines/reference/parserComputedPropertyName12.js b/tests/baselines/reference/parserComputedPropertyName12.js index 71cf1d352f..c78f2f15ff 100644 --- a/tests/baselines/reference/parserComputedPropertyName12.js +++ b/tests/baselines/reference/parserComputedPropertyName12.js @@ -5,6 +5,5 @@ class C { //// [parserComputedPropertyName12.js] class C { - [e]() { - } + [e]() { } } diff --git a/tests/baselines/reference/parserComputedPropertyName17.js b/tests/baselines/reference/parserComputedPropertyName17.js index cfff46e52f..f1fc4caacb 100644 --- a/tests/baselines/reference/parserComputedPropertyName17.js +++ b/tests/baselines/reference/parserComputedPropertyName17.js @@ -2,7 +2,4 @@ var v = { set [e](v) { } } //// [parserComputedPropertyName17.js] -var v = { - set [e](v) { - } -}; +var v = { set [e](v) { } }; diff --git a/tests/baselines/reference/parserComputedPropertyName2.js b/tests/baselines/reference/parserComputedPropertyName2.js index ea8532945a..f3c41f963f 100644 --- a/tests/baselines/reference/parserComputedPropertyName2.js +++ b/tests/baselines/reference/parserComputedPropertyName2.js @@ -2,6 +2,4 @@ var v = { [e]: 1 }; //// [parserComputedPropertyName2.js] -var v = { - [e]: 1 -}; +var v = { [e]: 1 }; diff --git a/tests/baselines/reference/parserComputedPropertyName24.js b/tests/baselines/reference/parserComputedPropertyName24.js index 8fc0a5be3a..8c72afde62 100644 --- a/tests/baselines/reference/parserComputedPropertyName24.js +++ b/tests/baselines/reference/parserComputedPropertyName24.js @@ -5,6 +5,5 @@ class C { //// [parserComputedPropertyName24.js] class C { - set [e](v) { - } + set [e](v) { } } diff --git a/tests/baselines/reference/parserComputedPropertyName3.js b/tests/baselines/reference/parserComputedPropertyName3.js index b3c8cc27bf..70273ed501 100644 --- a/tests/baselines/reference/parserComputedPropertyName3.js +++ b/tests/baselines/reference/parserComputedPropertyName3.js @@ -2,7 +2,4 @@ var v = { [e]() { } }; //// [parserComputedPropertyName3.js] -var v = { - [e]() { - } -}; +var v = { [e]() { } }; diff --git a/tests/baselines/reference/parserComputedPropertyName33.js b/tests/baselines/reference/parserComputedPropertyName33.js index 64239bc128..ab80967c21 100644 --- a/tests/baselines/reference/parserComputedPropertyName33.js +++ b/tests/baselines/reference/parserComputedPropertyName33.js @@ -12,5 +12,4 @@ class C { this[e] = 0[e2](); } } -{ -} +{ } diff --git a/tests/baselines/reference/parserComputedPropertyName38.js b/tests/baselines/reference/parserComputedPropertyName38.js index e5c9512ad2..e47f5233a7 100644 --- a/tests/baselines/reference/parserComputedPropertyName38.js +++ b/tests/baselines/reference/parserComputedPropertyName38.js @@ -6,5 +6,4 @@ class C { //// [parserComputedPropertyName38.js] class C { } -(() => { -}); +(() => { }); diff --git a/tests/baselines/reference/parserComputedPropertyName39.js b/tests/baselines/reference/parserComputedPropertyName39.js index cee81ccc3d..541d196538 100644 --- a/tests/baselines/reference/parserComputedPropertyName39.js +++ b/tests/baselines/reference/parserComputedPropertyName39.js @@ -8,5 +8,4 @@ class C { "use strict"; class C { } -(() => { -}); +(() => { }); diff --git a/tests/baselines/reference/parserComputedPropertyName4.js b/tests/baselines/reference/parserComputedPropertyName4.js index 679733529a..e456ca74f9 100644 --- a/tests/baselines/reference/parserComputedPropertyName4.js +++ b/tests/baselines/reference/parserComputedPropertyName4.js @@ -2,7 +2,4 @@ var v = { get [e]() { } }; //// [parserComputedPropertyName4.js] -var v = { - get [e]() { - } -}; +var v = { get [e]() { } }; diff --git a/tests/baselines/reference/parserComputedPropertyName40.js b/tests/baselines/reference/parserComputedPropertyName40.js index 417e37067d..3d9091bd64 100644 --- a/tests/baselines/reference/parserComputedPropertyName40.js +++ b/tests/baselines/reference/parserComputedPropertyName40.js @@ -5,6 +5,5 @@ class C { //// [parserComputedPropertyName40.js] class C { - [a ? "" : ""]() { - } + [a ? "" : ""]() { } } diff --git a/tests/baselines/reference/parserComputedPropertyName5.js b/tests/baselines/reference/parserComputedPropertyName5.js index 956b885bff..b94acd5523 100644 --- a/tests/baselines/reference/parserComputedPropertyName5.js +++ b/tests/baselines/reference/parserComputedPropertyName5.js @@ -2,7 +2,4 @@ var v = { public get [e]() { } }; //// [parserComputedPropertyName5.js] -var v = { - get [e]() { - } -}; +var v = { get [e]() { } }; diff --git a/tests/baselines/reference/parserComputedPropertyName6.js b/tests/baselines/reference/parserComputedPropertyName6.js index b18bb6ff30..b60ad66a9d 100644 --- a/tests/baselines/reference/parserComputedPropertyName6.js +++ b/tests/baselines/reference/parserComputedPropertyName6.js @@ -2,7 +2,4 @@ var v = { [e]: 1, [e + e]: 2 }; //// [parserComputedPropertyName6.js] -var v = { - [e]: 1, - [e + e]: 2 -}; +var v = { [e]: 1, [e + e]: 2 }; diff --git a/tests/baselines/reference/parserES3Accessors1.js b/tests/baselines/reference/parserES3Accessors1.js index 4900c1f32d..b4d0b9d657 100644 --- a/tests/baselines/reference/parserES3Accessors1.js +++ b/tests/baselines/reference/parserES3Accessors1.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserES3Accessors2.js b/tests/baselines/reference/parserES3Accessors2.js index 08259f2655..3d18e8ac28 100644 --- a/tests/baselines/reference/parserES3Accessors2.js +++ b/tests/baselines/reference/parserES3Accessors2.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserES3Accessors3.js b/tests/baselines/reference/parserES3Accessors3.js index c7dc2e3cea..f623fc546f 100644 --- a/tests/baselines/reference/parserES3Accessors3.js +++ b/tests/baselines/reference/parserES3Accessors3.js @@ -2,7 +2,4 @@ var v = { get Foo() { } }; //// [parserES3Accessors3.js] -var v = { - get Foo() { - } -}; +var v = { get Foo() { } }; diff --git a/tests/baselines/reference/parserES3Accessors4.js b/tests/baselines/reference/parserES3Accessors4.js index 9133c29a02..2bc5c9d1f7 100644 --- a/tests/baselines/reference/parserES3Accessors4.js +++ b/tests/baselines/reference/parserES3Accessors4.js @@ -2,7 +2,4 @@ var v = { set Foo(a) { } }; //// [parserES3Accessors4.js] -var v = { - set Foo(a) { - } -}; +var v = { set Foo(a) { } }; diff --git a/tests/baselines/reference/parserES5ComputedPropertyName3.js b/tests/baselines/reference/parserES5ComputedPropertyName3.js index 85a031fdfa..2606746795 100644 --- a/tests/baselines/reference/parserES5ComputedPropertyName3.js +++ b/tests/baselines/reference/parserES5ComputedPropertyName3.js @@ -3,7 +3,6 @@ var v = { [e]() { } }; //// [parserES5ComputedPropertyName3.js] var v = (_a = {}, - _a[e] = function () { - }, + _a[e] = function () { }, _a); var _a; diff --git a/tests/baselines/reference/parserES5ComputedPropertyName4.js b/tests/baselines/reference/parserES5ComputedPropertyName4.js index 5233471b6f..378624af08 100644 --- a/tests/baselines/reference/parserES5ComputedPropertyName4.js +++ b/tests/baselines/reference/parserES5ComputedPropertyName4.js @@ -3,11 +3,6 @@ var v = { get [e]() { } }; //// [parserES5ComputedPropertyName4.js] var v = (_a = {}, - _a[e] = Object.defineProperty({ - get: function () { - }, - enumerable: true, - configurable: true - }), + _a[e] = Object.defineProperty({ get: function () { }, enumerable: true, configurable: true }), _a); var _a; diff --git a/tests/baselines/reference/parserES5ForOfStatement17.js b/tests/baselines/reference/parserES5ForOfStatement17.js index 29b4f32b91..7995c4c689 100644 --- a/tests/baselines/reference/parserES5ForOfStatement17.js +++ b/tests/baselines/reference/parserES5ForOfStatement17.js @@ -2,5 +2,4 @@ for (var of; ;) { } //// [parserES5ForOfStatement17.js] -for (var of;;) { -} +for (var of;;) { } diff --git a/tests/baselines/reference/parserES5ForOfStatement19.js b/tests/baselines/reference/parserES5ForOfStatement19.js index 3838461a64..7ed0d5a333 100644 --- a/tests/baselines/reference/parserES5ForOfStatement19.js +++ b/tests/baselines/reference/parserES5ForOfStatement19.js @@ -2,5 +2,4 @@ for (var of in of) { } //// [parserES5ForOfStatement19.js] -for (var of in of) { -} +for (var of in of) { } diff --git a/tests/baselines/reference/parserES5ForOfStatement20.js b/tests/baselines/reference/parserES5ForOfStatement20.js index 74fceaef68..c51cbbc2a3 100644 --- a/tests/baselines/reference/parserES5ForOfStatement20.js +++ b/tests/baselines/reference/parserES5ForOfStatement20.js @@ -2,5 +2,4 @@ for (var of = 0 in of) { } //// [parserES5ForOfStatement20.js] -for (var of = 0 in of) { -} +for (var of = 0 in of) { } diff --git a/tests/baselines/reference/parserES5SymbolProperty7.js b/tests/baselines/reference/parserES5SymbolProperty7.js index b6096b798d..102d10af41 100644 --- a/tests/baselines/reference/parserES5SymbolProperty7.js +++ b/tests/baselines/reference/parserES5SymbolProperty7.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype[Symbol.toStringTag] = function () { - }; + C.prototype[Symbol.toStringTag] = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserErrantSemicolonInClass1.js b/tests/baselines/reference/parserErrantSemicolonInClass1.js index 56eb342716..f761b04ca7 100644 --- a/tests/baselines/reference/parserErrantSemicolonInClass1.js +++ b/tests/baselines/reference/parserErrantSemicolonInClass1.js @@ -39,8 +39,7 @@ class a { var a = (function () { function a(ns) { } - a.prototype.pgF = function () { - }; + a.prototype.pgF = function () { }; Object.defineProperty(a.prototype, "d", { get: function () { return 30; @@ -52,10 +51,7 @@ var a = (function () { }); Object.defineProperty(a, "p2", { get: function () { - return { - x: 30, - y: 40 - }; + return { x: 30, y: 40 }; }, enumerable: true, configurable: true diff --git a/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression1.js b/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression1.js index bea1ae993a..c33dbc2a62 100644 --- a/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression1.js +++ b/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression1.js @@ -3,12 +3,5 @@ var v = [1, 2, 3 4, 5, 6, 7]; //// [parserErrorRecoveryArrayLiteralExpression1.js] -var v = [ - 1, - 2, - 3, - 4, - 5, - 6, - 7 -]; +var v = [1, 2, 3, + 4, 5, 6, 7]; diff --git a/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression2.js b/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression2.js index c56dcd4ad9..0bfe59964d 100644 --- a/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression2.js +++ b/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression2.js @@ -5,13 +5,5 @@ var points = [-0.6961439251899719, 1.207661509513855, 0.19374050199985504, -0 //// [parserErrorRecoveryArrayLiteralExpression2.js] -var points = [ - -0.6961439251899719, - 1.207661509513855, - 0.19374050199985504, - -0, - .7042760848999023, - 1.1955541372299194, - 0.19600726664066315, - -0.7120069861412048 -]; +var points = [-0.6961439251899719, 1.207661509513855, 0.19374050199985504, -0, + .7042760848999023, 1.1955541372299194, 0.19600726664066315, -0.7120069861412048]; diff --git a/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression3.js b/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression3.js index a40433ba46..c366c750cc 100644 --- a/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression3.js +++ b/tests/baselines/reference/parserErrorRecoveryArrayLiteralExpression3.js @@ -4,11 +4,6 @@ var texCoords = [2, 2, 0.5000001192092895, 0.8749999 ; 403953552, 0.500000119209 //// [parserErrorRecoveryArrayLiteralExpression3.js] -var texCoords = [ - 2, - 2, - 0.5000001192092895, - 0.8749999 -]; +var texCoords = [2, 2, 0.5000001192092895, 0.8749999]; 403953552, 0.5000001192092895, 0.8749999403953552; ; diff --git a/tests/baselines/reference/parserErrorRecovery_Block1.js b/tests/baselines/reference/parserErrorRecovery_Block1.js index cdcd5856fa..e2bc5f89a3 100644 --- a/tests/baselines/reference/parserErrorRecovery_Block1.js +++ b/tests/baselines/reference/parserErrorRecovery_Block1.js @@ -6,6 +6,7 @@ function f() { //// [parserErrorRecovery_Block1.js] function f() { - 1 + ; + 1 + + ; return; } diff --git a/tests/baselines/reference/parserErrorRecovery_Block3.js b/tests/baselines/reference/parserErrorRecovery_Block3.js index 30183fb7d8..55b0a4d65e 100644 --- a/tests/baselines/reference/parserErrorRecovery_Block3.js +++ b/tests/baselines/reference/parserErrorRecovery_Block3.js @@ -10,8 +10,7 @@ class C { var C = (function () { function C() { } - C.prototype.a = function () { - }; + C.prototype.a = function () { }; C.prototype.b = function () { }; return C; diff --git a/tests/baselines/reference/parserErrorRecovery_IncompleteMemberVariable1.js b/tests/baselines/reference/parserErrorRecovery_IncompleteMemberVariable1.js index c26b16b5a0..ae2509c3f4 100644 --- a/tests/baselines/reference/parserErrorRecovery_IncompleteMemberVariable1.js +++ b/tests/baselines/reference/parserErrorRecovery_IncompleteMemberVariable1.js @@ -41,9 +41,7 @@ var Shapes; this.con = "hello"; } // Instance member - Point.prototype.getDist = function () { - return Math.sqrt(this.x * this.x + this.y * this.y); - }; + Point.prototype.getDist = function () { return Math.sqrt(this.x * this.x + this.y * this.y); }; // Static member Point.origin = new Point(0, 0); return Point; diff --git a/tests/baselines/reference/parserErrorRecovery_IncompleteMemberVariable2.js b/tests/baselines/reference/parserErrorRecovery_IncompleteMemberVariable2.js index 866f96a803..4936b1ea8b 100644 --- a/tests/baselines/reference/parserErrorRecovery_IncompleteMemberVariable2.js +++ b/tests/baselines/reference/parserErrorRecovery_IncompleteMemberVariable2.js @@ -41,9 +41,7 @@ var Shapes; this.con = "hello"; } // Instance member - Point.prototype.getDist = function () { - return Math.sqrt(this.x * this.x + this.y * this.y); - }; + Point.prototype.getDist = function () { return Math.sqrt(this.x * this.x + this.y * this.y); }; // Static member Point.origin = new Point(0, 0); return Point; diff --git a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral1.js b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral1.js index 04085a4b59..dbf89fec52 100644 --- a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral1.js +++ b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral1.js @@ -2,7 +2,4 @@ var v = { a: 1 b: 2 } //// [parserErrorRecovery_ObjectLiteral1.js] -var v = { - a: 1, - b: 2 -}; +var v = { a: 1, b: 2 }; diff --git a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral2.js b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral2.js index 3c258ef406..6a703759ff 100644 --- a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral2.js +++ b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral2.js @@ -3,7 +3,5 @@ var v = { a return; //// [parserErrorRecovery_ObjectLiteral2.js] -var v = { - a: , - return: -}; +var v = { a: , + return: }; diff --git a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral3.js b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral3.js index 49902122ac..eecf45fea4 100644 --- a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral3.js +++ b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral3.js @@ -3,7 +3,5 @@ var v = { a: return; //// [parserErrorRecovery_ObjectLiteral3.js] -var v = { - a: , - return: -}; +var v = { a: , + return: }; diff --git a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral4.js b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral4.js index b096210050..87a1a31437 100644 --- a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral4.js +++ b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral4.js @@ -3,7 +3,5 @@ var v = { a: 1 return; //// [parserErrorRecovery_ObjectLiteral4.js] -var v = { - a: 1, - return: -}; +var v = { a: 1, + return: }; diff --git a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral5.js b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral5.js index 6b691e376c..97e618946a 100644 --- a/tests/baselines/reference/parserErrorRecovery_ObjectLiteral5.js +++ b/tests/baselines/reference/parserErrorRecovery_ObjectLiteral5.js @@ -3,7 +3,5 @@ var v = { a: 1, return; //// [parserErrorRecovery_ObjectLiteral5.js] -var v = { - a: 1, - return: -}; +var v = { a: 1, + return: }; diff --git a/tests/baselines/reference/parserErrorRecovery_ParameterList6.js b/tests/baselines/reference/parserErrorRecovery_ParameterList6.js index e83c045208..060ad14766 100644 --- a/tests/baselines/reference/parserErrorRecovery_ParameterList6.js +++ b/tests/baselines/reference/parserErrorRecovery_ParameterList6.js @@ -11,5 +11,4 @@ var Foo = (function () { return Foo; })(); break ; -{ -} +{ } diff --git a/tests/baselines/reference/parserErrorRecovery_SwitchStatement1.js b/tests/baselines/reference/parserErrorRecovery_SwitchStatement1.js index 63591985d1..4d8008639c 100644 --- a/tests/baselines/reference/parserErrorRecovery_SwitchStatement1.js +++ b/tests/baselines/reference/parserErrorRecovery_SwitchStatement1.js @@ -10,8 +10,10 @@ switch (e) { //// [parserErrorRecovery_SwitchStatement1.js] switch (e) { case 1: - 1 + ; + 1 + + ; case 2: - 1 + ; + 1 + + ; default: } diff --git a/tests/baselines/reference/parserForOfStatement17.js b/tests/baselines/reference/parserForOfStatement17.js index 38ee81e71f..a6e2aee79a 100644 --- a/tests/baselines/reference/parserForOfStatement17.js +++ b/tests/baselines/reference/parserForOfStatement17.js @@ -2,5 +2,4 @@ for (var of; ;) { } //// [parserForOfStatement17.js] -for (var of;;) { -} +for (var of;;) { } diff --git a/tests/baselines/reference/parserForOfStatement18.js b/tests/baselines/reference/parserForOfStatement18.js index 519d92f335..c30fbb6085 100644 --- a/tests/baselines/reference/parserForOfStatement18.js +++ b/tests/baselines/reference/parserForOfStatement18.js @@ -2,5 +2,4 @@ for (var of of of) { } //// [parserForOfStatement18.js] -for (var of of of) { -} +for (var of of of) { } diff --git a/tests/baselines/reference/parserForOfStatement19.js b/tests/baselines/reference/parserForOfStatement19.js index 9b6a5c8da2..c838e8c71e 100644 --- a/tests/baselines/reference/parserForOfStatement19.js +++ b/tests/baselines/reference/parserForOfStatement19.js @@ -2,5 +2,4 @@ for (var of in of) { } //// [parserForOfStatement19.js] -for (var of in of) { -} +for (var of in of) { } diff --git a/tests/baselines/reference/parserForOfStatement20.js b/tests/baselines/reference/parserForOfStatement20.js index 7190bbeb1d..8599238d85 100644 --- a/tests/baselines/reference/parserForOfStatement20.js +++ b/tests/baselines/reference/parserForOfStatement20.js @@ -2,5 +2,4 @@ for (var of = 0 in of) { } //// [parserForOfStatement20.js] -for (var of = 0 in of) { -} +for (var of = 0 in of) { } diff --git a/tests/baselines/reference/parserForOfStatement21.js b/tests/baselines/reference/parserForOfStatement21.js index 593582e035..5db883e18a 100644 --- a/tests/baselines/reference/parserForOfStatement21.js +++ b/tests/baselines/reference/parserForOfStatement21.js @@ -2,5 +2,4 @@ for (var of of) { } //// [parserForOfStatement21.js] -for ( of of) { -} +for ( of of) { } diff --git a/tests/baselines/reference/parserFunctionDeclaration4.js b/tests/baselines/reference/parserFunctionDeclaration4.js index 285f36e683..a36a41e080 100644 --- a/tests/baselines/reference/parserFunctionDeclaration4.js +++ b/tests/baselines/reference/parserFunctionDeclaration4.js @@ -3,5 +3,4 @@ function foo(); function bar() { } //// [parserFunctionDeclaration4.js] -function bar() { -} +function bar() { } diff --git a/tests/baselines/reference/parserFunctionDeclaration5.js b/tests/baselines/reference/parserFunctionDeclaration5.js index 1c80f842c0..fd35c14675 100644 --- a/tests/baselines/reference/parserFunctionDeclaration5.js +++ b/tests/baselines/reference/parserFunctionDeclaration5.js @@ -3,5 +3,4 @@ function foo(); function foo() { } //// [parserFunctionDeclaration5.js] -function foo() { -} +function foo() { } diff --git a/tests/baselines/reference/parserFunctionDeclaration6.js b/tests/baselines/reference/parserFunctionDeclaration6.js index 6f877b07b1..05afe2d33a 100644 --- a/tests/baselines/reference/parserFunctionDeclaration6.js +++ b/tests/baselines/reference/parserFunctionDeclaration6.js @@ -6,6 +6,5 @@ //// [parserFunctionDeclaration6.js] { - function bar() { - } + function bar() { } } diff --git a/tests/baselines/reference/parserFunctionPropertyAssignment1.js b/tests/baselines/reference/parserFunctionPropertyAssignment1.js index c66c134ac4..ea7b20f05d 100644 --- a/tests/baselines/reference/parserFunctionPropertyAssignment1.js +++ b/tests/baselines/reference/parserFunctionPropertyAssignment1.js @@ -2,7 +2,4 @@ var v = { foo() { } }; //// [parserFunctionPropertyAssignment1.js] -var v = { - foo: function () { - } -}; +var v = { foo: function () { } }; diff --git a/tests/baselines/reference/parserFunctionPropertyAssignment2.js b/tests/baselines/reference/parserFunctionPropertyAssignment2.js index 7f6b3001c9..668e8df2cf 100644 --- a/tests/baselines/reference/parserFunctionPropertyAssignment2.js +++ b/tests/baselines/reference/parserFunctionPropertyAssignment2.js @@ -2,7 +2,4 @@ var v = { 0() { } }; //// [parserFunctionPropertyAssignment2.js] -var v = { - 0: function () { - } -}; +var v = { 0: function () { } }; diff --git a/tests/baselines/reference/parserFunctionPropertyAssignment3.js b/tests/baselines/reference/parserFunctionPropertyAssignment3.js index 2ed2152ae1..87a98ac402 100644 --- a/tests/baselines/reference/parserFunctionPropertyAssignment3.js +++ b/tests/baselines/reference/parserFunctionPropertyAssignment3.js @@ -2,7 +2,4 @@ var v = { "foo"() { } }; //// [parserFunctionPropertyAssignment3.js] -var v = { - "foo": function () { - } -}; +var v = { "foo": function () { } }; diff --git a/tests/baselines/reference/parserFunctionPropertyAssignment4.js b/tests/baselines/reference/parserFunctionPropertyAssignment4.js index eb95d79ac4..e9b41e754e 100644 --- a/tests/baselines/reference/parserFunctionPropertyAssignment4.js +++ b/tests/baselines/reference/parserFunctionPropertyAssignment4.js @@ -2,7 +2,4 @@ var v = { 0() { } }; //// [parserFunctionPropertyAssignment4.js] -var v = { - 0: function () { - } -}; +var v = { 0: function () { } }; diff --git a/tests/baselines/reference/parserFuzz1.js b/tests/baselines/reference/parserFuzz1.js index 969c07c165..b9ffb54004 100644 --- a/tests/baselines/reference/parserFuzz1.js +++ b/tests/baselines/reference/parserFuzz1.js @@ -6,8 +6,6 @@ cla >> 2; +1 + >>> + 2; diff --git a/tests/baselines/reference/parserGreaterThanTokenAmbiguity14.js b/tests/baselines/reference/parserGreaterThanTokenAmbiguity14.js index 5cc8bb3b88..b2eba6d587 100644 --- a/tests/baselines/reference/parserGreaterThanTokenAmbiguity14.js +++ b/tests/baselines/reference/parserGreaterThanTokenAmbiguity14.js @@ -3,5 +3,6 @@ = 2; //// [parserGreaterThanTokenAmbiguity14.js] -1 >> ; +1 >> +; 2; diff --git a/tests/baselines/reference/parserGreaterThanTokenAmbiguity15.js b/tests/baselines/reference/parserGreaterThanTokenAmbiguity15.js index df9e55b7e3..b6f905e12e 100644 --- a/tests/baselines/reference/parserGreaterThanTokenAmbiguity15.js +++ b/tests/baselines/reference/parserGreaterThanTokenAmbiguity15.js @@ -5,4 +5,6 @@ 2; //// [parserGreaterThanTokenAmbiguity15.js] -1 >>= 2; +1 + >>= + 2; diff --git a/tests/baselines/reference/parserGreaterThanTokenAmbiguity19.js b/tests/baselines/reference/parserGreaterThanTokenAmbiguity19.js index 52035691c8..d0671d8649 100644 --- a/tests/baselines/reference/parserGreaterThanTokenAmbiguity19.js +++ b/tests/baselines/reference/parserGreaterThanTokenAmbiguity19.js @@ -3,5 +3,6 @@ = 2; //// [parserGreaterThanTokenAmbiguity19.js] -1 >>> ; +1 >>> +; 2; diff --git a/tests/baselines/reference/parserGreaterThanTokenAmbiguity20.js b/tests/baselines/reference/parserGreaterThanTokenAmbiguity20.js index e6043febcd..01d1d6401f 100644 --- a/tests/baselines/reference/parserGreaterThanTokenAmbiguity20.js +++ b/tests/baselines/reference/parserGreaterThanTokenAmbiguity20.js @@ -5,4 +5,6 @@ 2; //// [parserGreaterThanTokenAmbiguity20.js] -1 >>>= 2; +1 + >>>= + 2; diff --git a/tests/baselines/reference/parserGreaterThanTokenAmbiguity4.js b/tests/baselines/reference/parserGreaterThanTokenAmbiguity4.js index 5ef065681d..dcfb51575e 100644 --- a/tests/baselines/reference/parserGreaterThanTokenAmbiguity4.js +++ b/tests/baselines/reference/parserGreaterThanTokenAmbiguity4.js @@ -3,4 +3,5 @@ > 2; //// [parserGreaterThanTokenAmbiguity4.js] -1 > > 2; +1 > + > 2; diff --git a/tests/baselines/reference/parserGreaterThanTokenAmbiguity5.js b/tests/baselines/reference/parserGreaterThanTokenAmbiguity5.js index a707e808b4..c65b76f504 100644 --- a/tests/baselines/reference/parserGreaterThanTokenAmbiguity5.js +++ b/tests/baselines/reference/parserGreaterThanTokenAmbiguity5.js @@ -5,4 +5,6 @@ 2; //// [parserGreaterThanTokenAmbiguity5.js] -1 >> 2; +1 + >> + 2; diff --git a/tests/baselines/reference/parserGreaterThanTokenAmbiguity9.js b/tests/baselines/reference/parserGreaterThanTokenAmbiguity9.js index 25c5ed53a7..96be8d0749 100644 --- a/tests/baselines/reference/parserGreaterThanTokenAmbiguity9.js +++ b/tests/baselines/reference/parserGreaterThanTokenAmbiguity9.js @@ -3,4 +3,5 @@ > 2; //// [parserGreaterThanTokenAmbiguity9.js] -1 >> > 2; +1 >> + > 2; diff --git a/tests/baselines/reference/parserInExpression1.js b/tests/baselines/reference/parserInExpression1.js index 2153828804..d6100b9b57 100644 --- a/tests/baselines/reference/parserInExpression1.js +++ b/tests/baselines/reference/parserInExpression1.js @@ -2,6 +2,4 @@ console.log("a" in { "a": true }); //// [parserInExpression1.js] -console.log("a" in { - "a": true -}); +console.log("a" in { "a": true }); diff --git a/tests/baselines/reference/parserMemberAccessor1.js b/tests/baselines/reference/parserMemberAccessor1.js index 3d4690d58e..866a171bc4 100644 --- a/tests/baselines/reference/parserMemberAccessor1.js +++ b/tests/baselines/reference/parserMemberAccessor1.js @@ -9,10 +9,8 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "foo", { - get: function () { - }, - set: function (a) { - }, + get: function () { }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration1.js b/tests/baselines/reference/parserMemberAccessorDeclaration1.js index 1f0b5eb3bd..30534735cf 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration1.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration1.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "a", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration10.js b/tests/baselines/reference/parserMemberAccessorDeclaration10.js index dba0654496..d778b19227 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration10.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration10.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - get: function () { - } + get: function () { } exports.Foo = Foo;, enumerable: true, configurable: true diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration11.js b/tests/baselines/reference/parserMemberAccessorDeclaration11.js index 2a286b8ca6..da8d7fc642 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration11.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration11.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration12.js b/tests/baselines/reference/parserMemberAccessorDeclaration12.js index aea6eccfbc..72923e060c 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration12.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration12.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - get: function (a) { - }, + get: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration13.js b/tests/baselines/reference/parserMemberAccessorDeclaration13.js index f6ca4ee6a0..14b0f1b0a0 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration13.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration13.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - set: function () { - }, + set: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration14.js b/tests/baselines/reference/parserMemberAccessorDeclaration14.js index 62877d402d..21b11219ca 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration14.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration14.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - set: function (a, b) { - }, + set: function (a, b) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration15.js b/tests/baselines/reference/parserMemberAccessorDeclaration15.js index 59ff360d43..0d01c75840 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration15.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration15.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration17.js b/tests/baselines/reference/parserMemberAccessorDeclaration17.js index 6c99c7ddae..d61fa2e840 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration17.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration17.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - set: function (a) { - }, + set: function (a) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration2.js b/tests/baselines/reference/parserMemberAccessorDeclaration2.js index 00cc281201..f29efc846e 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration2.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration2.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "b", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration3.js b/tests/baselines/reference/parserMemberAccessorDeclaration3.js index 86fc2c3e53..9c64bf0252 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration3.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration3.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "0", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration4.js b/tests/baselines/reference/parserMemberAccessorDeclaration4.js index 552c2c1d27..e65f6431a7 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration4.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration4.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "a", { - set: function (i) { - }, + set: function (i) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration5.js b/tests/baselines/reference/parserMemberAccessorDeclaration5.js index 309df8b68e..d304a44d64 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration5.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration5.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "a", { - set: function (i) { - }, + set: function (i) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration6.js b/tests/baselines/reference/parserMemberAccessorDeclaration6.js index 0b44673f14..9c6f3ce8a5 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration6.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration6.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "0", { - set: function (i) { - }, + set: function (i) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration7.js b/tests/baselines/reference/parserMemberAccessorDeclaration7.js index 0d2d24092e..ce103accf6 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration7.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration7.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "Foo", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration8.js b/tests/baselines/reference/parserMemberAccessorDeclaration8.js index dd93fa4852..07f12acae4 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration8.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration8.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C, "Foo", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberAccessorDeclaration9.js b/tests/baselines/reference/parserMemberAccessorDeclaration9.js index 5fca86f689..02183d46ef 100644 --- a/tests/baselines/reference/parserMemberAccessorDeclaration9.js +++ b/tests/baselines/reference/parserMemberAccessorDeclaration9.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C, "Foo", { - get: function () { - }, + get: function () { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserMemberFunctionDeclaration1.js b/tests/baselines/reference/parserMemberFunctionDeclaration1.js index 564245157b..1d40fa9470 100644 --- a/tests/baselines/reference/parserMemberFunctionDeclaration1.js +++ b/tests/baselines/reference/parserMemberFunctionDeclaration1.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.Foo = function () { - }; + C.prototype.Foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserMemberFunctionDeclaration2.js b/tests/baselines/reference/parserMemberFunctionDeclaration2.js index 0f103c90b7..fed1a6a074 100644 --- a/tests/baselines/reference/parserMemberFunctionDeclaration2.js +++ b/tests/baselines/reference/parserMemberFunctionDeclaration2.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.Foo = function () { - }; + C.Foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserMemberFunctionDeclaration3.js b/tests/baselines/reference/parserMemberFunctionDeclaration3.js index 46243f08da..18bbec7ba5 100644 --- a/tests/baselines/reference/parserMemberFunctionDeclaration3.js +++ b/tests/baselines/reference/parserMemberFunctionDeclaration3.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.Foo = function () { - }; + C.Foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserMemberFunctionDeclaration4.js b/tests/baselines/reference/parserMemberFunctionDeclaration4.js index bcf00aeb1b..cd12f23442 100644 --- a/tests/baselines/reference/parserMemberFunctionDeclaration4.js +++ b/tests/baselines/reference/parserMemberFunctionDeclaration4.js @@ -7,8 +7,7 @@ class C { var C = (function () { function C() { } - C.prototype.Foo = function () { - } + C.prototype.Foo = function () { } exports.Foo = Foo;; return C; })(); diff --git a/tests/baselines/reference/parserMemberFunctionDeclaration5.js b/tests/baselines/reference/parserMemberFunctionDeclaration5.js index da2d228199..75630d3455 100644 --- a/tests/baselines/reference/parserMemberFunctionDeclaration5.js +++ b/tests/baselines/reference/parserMemberFunctionDeclaration5.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.Foo = function () { - }; + C.prototype.Foo = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserMemberFunctionDeclarationAmbiguities1.js b/tests/baselines/reference/parserMemberFunctionDeclarationAmbiguities1.js index 59017d97fe..e0a0f7860c 100644 --- a/tests/baselines/reference/parserMemberFunctionDeclarationAmbiguities1.js +++ b/tests/baselines/reference/parserMemberFunctionDeclarationAmbiguities1.js @@ -17,21 +17,13 @@ class C { var C = (function () { function C() { } - C.prototype.public = function () { - }; - C.prototype.static = function () { - }; - C.prototype.public = function () { - }; - C.prototype.static = function () { - }; - C.public = function () { - }; - C.static = function () { - }; - C.public = function () { - }; - C.static = function () { - }; + C.prototype.public = function () { }; + C.prototype.static = function () { }; + C.prototype.public = function () { }; + C.prototype.static = function () { }; + C.public = function () { }; + C.static = function () { }; + C.public = function () { }; + C.static = function () { }; return C; })(); diff --git a/tests/baselines/reference/parserMissingLambdaOpenBrace1.js b/tests/baselines/reference/parserMissingLambdaOpenBrace1.js index 1c532f3d4b..8280d8dc9b 100644 --- a/tests/baselines/reference/parserMissingLambdaOpenBrace1.js +++ b/tests/baselines/reference/parserMissingLambdaOpenBrace1.js @@ -16,9 +16,7 @@ var C = (function () { var _this = this; return fromDoWhile(function (test) { var index = 0; - return _this.doWhile(function (item, i) { - return filter(item, i) ? test(item, index++) : true; - }); + return _this.doWhile(function (item, i) { return filter(item, i) ? test(item, index++) : true; }); }); }; return C; diff --git a/tests/baselines/reference/parserMissingToken1.js b/tests/baselines/reference/parserMissingToken1.js index 506e628fa3..7017d9d0b1 100644 --- a/tests/baselines/reference/parserMissingToken1.js +++ b/tests/baselines/reference/parserMissingToken1.js @@ -3,7 +3,5 @@ a / finally //// [parserMissingToken1.js] a / ; -try { -} -finally { -} +try { } +finally { } diff --git a/tests/baselines/reference/parserNoASIOnCallAfterFunctionExpression1.js b/tests/baselines/reference/parserNoASIOnCallAfterFunctionExpression1.js index 83df05206c..51581b1c74 100644 --- a/tests/baselines/reference/parserNoASIOnCallAfterFunctionExpression1.js +++ b/tests/baselines/reference/parserNoASIOnCallAfterFunctionExpression1.js @@ -4,5 +4,4 @@ var x = function () { } //// [parserNoASIOnCallAfterFunctionExpression1.js] -var x = function () { -}(window).foo; +var x = function () { }(window).foo; diff --git a/tests/baselines/reference/parserNotHexLiteral1.js b/tests/baselines/reference/parserNotHexLiteral1.js index eadbf8da27..89b978fcaa 100644 --- a/tests/baselines/reference/parserNotHexLiteral1.js +++ b/tests/baselines/reference/parserNotHexLiteral1.js @@ -7,10 +7,7 @@ console.info (x.e0); //// [parserNotHexLiteral1.js] -var x = { - e0: 'cat', - x0: 'dog' -}; +var x = { e0: 'cat', x0: 'dog' }; console.info(x.x0); // tsc dies on this next line with "bug.ts (5,16): Expected ')'" // tsc seems to be parsing the e0 as a hex constant. diff --git a/tests/baselines/reference/parserObjectLiterals1.js b/tests/baselines/reference/parserObjectLiterals1.js index 2224809474..426b8107d3 100644 --- a/tests/baselines/reference/parserObjectLiterals1.js +++ b/tests/baselines/reference/parserObjectLiterals1.js @@ -2,7 +2,4 @@ var v = { a: 1, b: 2 }; //// [parserObjectLiterals1.js] -var v = { - a: 1, - b: 2 -}; +var v = { a: 1, b: 2 }; diff --git a/tests/baselines/reference/parserParameterList1.js b/tests/baselines/reference/parserParameterList1.js index 49af7780b1..86b0690728 100644 --- a/tests/baselines/reference/parserParameterList1.js +++ b/tests/baselines/reference/parserParameterList1.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.F = function (A, B) { - }; + C.prototype.F = function (A, B) { }; return C; })(); diff --git a/tests/baselines/reference/parserParameterList15.js b/tests/baselines/reference/parserParameterList15.js index 289c65c88c..83216f1256 100644 --- a/tests/baselines/reference/parserParameterList15.js +++ b/tests/baselines/reference/parserParameterList15.js @@ -3,5 +3,4 @@ function foo(a = 4); function foo(a, b) {} //// [parserParameterList15.js] -function foo(a, b) { -} +function foo(a, b) { } diff --git a/tests/baselines/reference/parserParameterList16.js b/tests/baselines/reference/parserParameterList16.js index 368939bbcd..50c5821547 100644 --- a/tests/baselines/reference/parserParameterList16.js +++ b/tests/baselines/reference/parserParameterList16.js @@ -8,7 +8,6 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function (a, b) { - }; + C.prototype.foo = function (a, b) { }; return C; })(); diff --git a/tests/baselines/reference/parserParameterList3.js b/tests/baselines/reference/parserParameterList3.js index 01135f0cef..3992dc548e 100644 --- a/tests/baselines/reference/parserParameterList3.js +++ b/tests/baselines/reference/parserParameterList3.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.prototype.F = function (A, B) { - }; + C.prototype.F = function (A, B) { }; return C; })(); diff --git a/tests/baselines/reference/parserRealSource1.js b/tests/baselines/reference/parserRealSource1.js index c62897c9af..d19c2242f0 100644 --- a/tests/baselines/reference/parserRealSource1.js +++ b/tests/baselines/reference/parserRealSource1.js @@ -189,21 +189,11 @@ var TypeScript; var NullLogger = (function () { function NullLogger() { } - NullLogger.prototype.information = function () { - return false; - }; - NullLogger.prototype.debug = function () { - return false; - }; - NullLogger.prototype.warning = function () { - return false; - }; - NullLogger.prototype.error = function () { - return false; - }; - NullLogger.prototype.fatal = function () { - return false; - }; + NullLogger.prototype.information = function () { return false; }; + NullLogger.prototype.debug = function () { return false; }; + NullLogger.prototype.warning = function () { return false; }; + NullLogger.prototype.error = function () { return false; }; + NullLogger.prototype.fatal = function () { return false; }; NullLogger.prototype.log = function (s) { }; return NullLogger; @@ -218,21 +208,11 @@ var TypeScript; this._error = this.logger.error(); this._fatal = this.logger.fatal(); } - LoggerAdapter.prototype.information = function () { - return this._information; - }; - LoggerAdapter.prototype.debug = function () { - return this._debug; - }; - LoggerAdapter.prototype.warning = function () { - return this._warning; - }; - LoggerAdapter.prototype.error = function () { - return this._error; - }; - LoggerAdapter.prototype.fatal = function () { - return this._fatal; - }; + LoggerAdapter.prototype.information = function () { return this._information; }; + LoggerAdapter.prototype.debug = function () { return this._debug; }; + LoggerAdapter.prototype.warning = function () { return this._warning; }; + LoggerAdapter.prototype.error = function () { return this._error; }; + LoggerAdapter.prototype.fatal = function () { return this._fatal; }; LoggerAdapter.prototype.log = function (s) { this.logger.log(s); }; @@ -243,21 +223,11 @@ var TypeScript; function BufferedLogger() { this.logContents = []; } - BufferedLogger.prototype.information = function () { - return false; - }; - BufferedLogger.prototype.debug = function () { - return false; - }; - BufferedLogger.prototype.warning = function () { - return false; - }; - BufferedLogger.prototype.error = function () { - return false; - }; - BufferedLogger.prototype.fatal = function () { - return false; - }; + BufferedLogger.prototype.information = function () { return false; }; + BufferedLogger.prototype.debug = function () { return false; }; + BufferedLogger.prototype.warning = function () { return false; }; + BufferedLogger.prototype.error = function () { return false; }; + BufferedLogger.prototype.fatal = function () { return false; }; BufferedLogger.prototype.log = function (s) { this.logContents.push(s); }; diff --git a/tests/baselines/reference/parserRealSource10.js b/tests/baselines/reference/parserRealSource10.js index 871b9019ed..2ddc7a8dce 100644 --- a/tests/baselines/reference/parserRealSource10.js +++ b/tests/baselines/reference/parserRealSource10.js @@ -813,7 +813,8 @@ var TypeScript; else { var tokenInfo = lookupToken(this.tokenId); if (tokenInfo != undefined) { - if ((tokenInfo.unopNodeType != NodeType.None) || (tokenInfo.binopNodeType != NodeType.None)) { + if ((tokenInfo.unopNodeType != NodeType.None) || + (tokenInfo.binopNodeType != NodeType.None)) { return TokenClass.Operator; } } diff --git a/tests/baselines/reference/parserRealSource11.js b/tests/baselines/reference/parserRealSource11.js index 89c38a96fd..72fec69218 100644 --- a/tests/baselines/reference/parserRealSource11.js +++ b/tests/baselines/reference/parserRealSource11.js @@ -2397,18 +2397,10 @@ var TypeScript; this.postComments = null; this.isParenthesized = false; } - AST.prototype.isExpression = function () { - return false; - }; - AST.prototype.isStatementOrExpression = function () { - return false; - }; - AST.prototype.isCompoundStatement = function () { - return false; - }; - AST.prototype.isLeaf = function () { - return this.isStatementOrExpression() && (!this.isCompoundStatement()); - }; + AST.prototype.isExpression = function () { return false; }; + AST.prototype.isStatementOrExpression = function () { return false; }; + AST.prototype.isCompoundStatement = function () { return false; }; + AST.prototype.isLeaf = function () { return this.isStatementOrExpression() && (!this.isCompoundStatement()); }; AST.prototype.typeCheck = function (typeFlow) { switch (this.nodeType) { case NodeType.Error: @@ -2491,18 +2483,13 @@ var TypeScript; }; AST.prototype.print = function (context) { context.startLine(); - var lineCol = { - line: -1, - col: -1 - }; - var limLineCol = { - line: -1, - col: -1 - }; + var lineCol = { line: -1, col: -1 }; + var limLineCol = { line: -1, col: -1 }; if (context.parser !== null) { context.parser.getSourceLineCol(lineCol, this.minChar); context.parser.getSourceLineCol(limLineCol, this.limChar); - context.write("(" + lineCol.line + "," + lineCol.col + ")--" + "(" + limLineCol.line + "," + limLineCol.col + "): "); + context.write("(" + lineCol.line + "," + lineCol.col + ")--" + + "(" + limLineCol.line + "," + limLineCol.col + "): "); } var lab = this.printLabel(); if (hasFlag(this.flags, ASTFlags.Error)) { @@ -2649,12 +2636,8 @@ var TypeScript; this.text = actualText; } }; - Identifier.prototype.isMissing = function () { - return false; - }; - Identifier.prototype.isLeaf = function () { - return true; - }; + Identifier.prototype.isMissing = function () { return false; }; + Identifier.prototype.isLeaf = function () { return true; }; Identifier.prototype.treeViewLabel = function () { return "id: " + this.actualText; }; @@ -2698,9 +2681,7 @@ var TypeScript; _super.call(this, NodeType.Label); this.id = id; } - Label.prototype.printLabel = function () { - return this.id.actualText + ":"; - }; + Label.prototype.printLabel = function () { return this.id.actualText + ":"; }; Label.prototype.typeCheck = function (typeFlow) { this.type = typeFlow.voidType; return this; @@ -2723,12 +2704,8 @@ var TypeScript; function Expression(nodeType) { _super.call(this, nodeType); } - Expression.prototype.isExpression = function () { - return true; - }; - Expression.prototype.isStatementOrExpression = function () { - return true; - }; + Expression.prototype.isExpression = function () { return true; }; + Expression.prototype.isStatementOrExpression = function () { return true; }; return Expression; })(AST); TypeScript.Expression = Expression; @@ -3189,9 +3166,7 @@ var TypeScript; this.varFlags = VarFlags.None; this.isDynamicImport = false; } - ImportDeclaration.prototype.isStatementOrExpression = function () { - return true; - }; + ImportDeclaration.prototype.isStatementOrExpression = function () { return true; }; ImportDeclaration.prototype.emit = function (emitter, tokenId, startLine) { var mod = this.alias.type; // REVIEW: Only modules may be aliased for now, though there's no real @@ -3252,18 +3227,10 @@ var TypeScript; this.varFlags = VarFlags.None; this.sym = null; } - BoundDecl.prototype.isStatementOrExpression = function () { - return true; - }; - BoundDecl.prototype.isPrivate = function () { - return hasFlag(this.varFlags, VarFlags.Private); - }; - BoundDecl.prototype.isPublic = function () { - return hasFlag(this.varFlags, VarFlags.Public); - }; - BoundDecl.prototype.isProperty = function () { - return hasFlag(this.varFlags, VarFlags.Property); - }; + BoundDecl.prototype.isStatementOrExpression = function () { return true; }; + BoundDecl.prototype.isPrivate = function () { return hasFlag(this.varFlags, VarFlags.Private); }; + BoundDecl.prototype.isPublic = function () { return hasFlag(this.varFlags, VarFlags.Public); }; + BoundDecl.prototype.isProperty = function () { return hasFlag(this.varFlags, VarFlags.Property); }; BoundDecl.prototype.typeCheck = function (typeFlow) { return typeFlow.typeCheckBoundDecl(this); }; @@ -3278,15 +3245,9 @@ var TypeScript; function VarDecl(id, nest) { _super.call(this, id, NodeType.VarDecl, nest); } - VarDecl.prototype.isAmbient = function () { - return hasFlag(this.varFlags, VarFlags.Ambient); - }; - VarDecl.prototype.isExported = function () { - return hasFlag(this.varFlags, VarFlags.Exported); - }; - VarDecl.prototype.isStatic = function () { - return hasFlag(this.varFlags, VarFlags.Static); - }; + VarDecl.prototype.isAmbient = function () { return hasFlag(this.varFlags, VarFlags.Ambient); }; + VarDecl.prototype.isExported = function () { return hasFlag(this.varFlags, VarFlags.Exported); }; + VarDecl.prototype.isStatic = function () { return hasFlag(this.varFlags, VarFlags.Static); }; VarDecl.prototype.emit = function (emitter, tokenId, startLine) { emitter.emitJavascriptVarDecl(this, tokenId); }; @@ -3303,9 +3264,7 @@ var TypeScript; this.isOptional = false; this.parameterPropertySym = null; } - ArgDecl.prototype.isOptionalArg = function () { - return this.isOptional || this.init; - }; + ArgDecl.prototype.isOptionalArg = function () { return this.isOptional || this.init; }; ArgDecl.prototype.treeViewLabel = function () { return "arg: " + this.id.actualText; }; @@ -3366,12 +3325,8 @@ var TypeScript; } return this.internalNameCache; }; - FuncDecl.prototype.hasSelfReference = function () { - return hasFlag(this.fncFlags, FncFlags.HasSelfReference); - }; - FuncDecl.prototype.setHasSelfReference = function () { - this.fncFlags |= FncFlags.HasSelfReference; - }; + FuncDecl.prototype.hasSelfReference = function () { return hasFlag(this.fncFlags, FncFlags.HasSelfReference); }; + FuncDecl.prototype.setHasSelfReference = function () { this.fncFlags |= FncFlags.HasSelfReference; }; FuncDecl.prototype.addCloRef = function (id, sym) { if (this.envids == null) { this.envids = new Identifier[]; @@ -3425,45 +3380,19 @@ var TypeScript; FuncDecl.prototype.isMethod = function () { return (this.fncFlags & FncFlags.Method) != FncFlags.None; }; - FuncDecl.prototype.isCallMember = function () { - return hasFlag(this.fncFlags, FncFlags.CallMember); - }; - FuncDecl.prototype.isConstructMember = function () { - return hasFlag(this.fncFlags, FncFlags.ConstructMember); - }; - FuncDecl.prototype.isIndexerMember = function () { - return hasFlag(this.fncFlags, FncFlags.IndexerMember); - }; - FuncDecl.prototype.isSpecialFn = function () { - return this.isCallMember() || this.isIndexerMember() || this.isConstructMember(); - }; - FuncDecl.prototype.isAnonymousFn = function () { - return this.name === null; - }; - FuncDecl.prototype.isAccessor = function () { - return hasFlag(this.fncFlags, FncFlags.GetAccessor) || hasFlag(this.fncFlags, FncFlags.SetAccessor); - }; - FuncDecl.prototype.isGetAccessor = function () { - return hasFlag(this.fncFlags, FncFlags.GetAccessor); - }; - FuncDecl.prototype.isSetAccessor = function () { - return hasFlag(this.fncFlags, FncFlags.SetAccessor); - }; - FuncDecl.prototype.isAmbient = function () { - return hasFlag(this.fncFlags, FncFlags.Ambient); - }; - FuncDecl.prototype.isExported = function () { - return hasFlag(this.fncFlags, FncFlags.Exported); - }; - FuncDecl.prototype.isPrivate = function () { - return hasFlag(this.fncFlags, FncFlags.Private); - }; - FuncDecl.prototype.isPublic = function () { - return hasFlag(this.fncFlags, FncFlags.Public); - }; - FuncDecl.prototype.isStatic = function () { - return hasFlag(this.fncFlags, FncFlags.Static); - }; + FuncDecl.prototype.isCallMember = function () { return hasFlag(this.fncFlags, FncFlags.CallMember); }; + FuncDecl.prototype.isConstructMember = function () { return hasFlag(this.fncFlags, FncFlags.ConstructMember); }; + FuncDecl.prototype.isIndexerMember = function () { return hasFlag(this.fncFlags, FncFlags.IndexerMember); }; + FuncDecl.prototype.isSpecialFn = function () { return this.isCallMember() || this.isIndexerMember() || this.isConstructMember(); }; + FuncDecl.prototype.isAnonymousFn = function () { return this.name === null; }; + FuncDecl.prototype.isAccessor = function () { return hasFlag(this.fncFlags, FncFlags.GetAccessor) || hasFlag(this.fncFlags, FncFlags.SetAccessor); }; + FuncDecl.prototype.isGetAccessor = function () { return hasFlag(this.fncFlags, FncFlags.GetAccessor); }; + FuncDecl.prototype.isSetAccessor = function () { return hasFlag(this.fncFlags, FncFlags.SetAccessor); }; + FuncDecl.prototype.isAmbient = function () { return hasFlag(this.fncFlags, FncFlags.Ambient); }; + FuncDecl.prototype.isExported = function () { return hasFlag(this.fncFlags, FncFlags.Exported); }; + FuncDecl.prototype.isPrivate = function () { return hasFlag(this.fncFlags, FncFlags.Private); }; + FuncDecl.prototype.isPublic = function () { return hasFlag(this.fncFlags, FncFlags.Public); }; + FuncDecl.prototype.isStatic = function () { return hasFlag(this.fncFlags, FncFlags.Static); }; FuncDecl.prototype.treeViewLabel = function () { if (this.name == null) { return "funcExpr"; @@ -3475,12 +3404,8 @@ var TypeScript; FuncDecl.prototype.ClearFlags = function () { this.fncFlags = FncFlags.None; }; - FuncDecl.prototype.isSignature = function () { - return (this.fncFlags & FncFlags.Signature) != FncFlags.None; - }; - FuncDecl.prototype.hasStaticDeclarations = function () { - return (!this.isConstructor && (this.statics.members.length > 0 || this.innerStaticFuncs.length > 0)); - }; + FuncDecl.prototype.isSignature = function () { return (this.fncFlags & FncFlags.Signature) != FncFlags.None; }; + FuncDecl.prototype.hasStaticDeclarations = function () { return (!this.isConstructor && (this.statics.members.length > 0 || this.innerStaticFuncs.length > 0)); }; return FuncDecl; })(AST); TypeScript.FuncDecl = FuncDecl; @@ -3589,15 +3514,9 @@ var TypeScript; this.scopes = scopes; this.prettyName = this.name.actualText; } - ModuleDeclaration.prototype.isExported = function () { - return hasFlag(this.modFlags, ModuleFlags.Exported); - }; - ModuleDeclaration.prototype.isAmbient = function () { - return hasFlag(this.modFlags, ModuleFlags.Ambient); - }; - ModuleDeclaration.prototype.isEnum = function () { - return hasFlag(this.modFlags, ModuleFlags.IsEnum); - }; + ModuleDeclaration.prototype.isExported = function () { return hasFlag(this.modFlags, ModuleFlags.Exported); }; + ModuleDeclaration.prototype.isAmbient = function () { return hasFlag(this.modFlags, ModuleFlags.Ambient); }; + ModuleDeclaration.prototype.isEnum = function () { return hasFlag(this.modFlags, ModuleFlags.IsEnum); }; ModuleDeclaration.prototype.recordNonInterface = function () { this.modFlags &= ~ModuleFlags.ShouldEmitModuleDecl; }; @@ -3670,15 +3589,9 @@ var TypeScript; _super.call(this, nodeType); this.flags |= ASTFlags.IsStatement; } - Statement.prototype.isLoop = function () { - return false; - }; - Statement.prototype.isStatementOrExpression = function () { - return true; - }; - Statement.prototype.isCompoundStatement = function () { - return this.isLoop(); - }; + Statement.prototype.isLoop = function () { return false; }; + Statement.prototype.isStatementOrExpression = function () { return true; }; + Statement.prototype.isCompoundStatement = function () { return this.isLoop(); }; Statement.prototype.typeCheck = function (typeFlow) { this.type = typeFlow.voidType; return this; @@ -3782,9 +3695,7 @@ var TypeScript; this.target = null; this.resolvedTarget = null; } - Jump.prototype.hasExplicitTarget = function () { - return (this.target); - }; + Jump.prototype.hasExplicitTarget = function () { return (this.target); }; Jump.prototype.setResolvedTarget = function (parser, stmt) { if (stmt.isLoop()) { this.resolvedTarget = stmt; @@ -3835,9 +3746,7 @@ var TypeScript; this.cond = cond; this.body = null; } - WhileStatement.prototype.isLoop = function () { - return true; - }; + WhileStatement.prototype.isLoop = function () { return true; }; WhileStatement.prototype.emit = function (emitter, tokenId, startLine) { emitter.emitParensAndCommentsInPlace(this, true); emitter.recordSourceMappingStart(this); @@ -3890,9 +3799,7 @@ var TypeScript; this.whileAST = null; this.cond = null; } - DoWhileStatement.prototype.isLoop = function () { - return true; - }; + DoWhileStatement.prototype.isLoop = function () { return true; }; DoWhileStatement.prototype.emit = function (emitter, tokenId, startLine) { emitter.emitParensAndCommentsInPlace(this, true); emitter.recordSourceMappingStart(this); @@ -3948,9 +3855,7 @@ var TypeScript; this.elseBod = null; this.statement = new ASTSpan(); } - IfStatement.prototype.isCompoundStatement = function () { - return true; - }; + IfStatement.prototype.isCompoundStatement = function () { return true; }; IfStatement.prototype.emit = function (emitter, tokenId, startLine) { emitter.emitParensAndCommentsInPlace(this, true); emitter.recordSourceMappingStart(this); @@ -4070,9 +3975,7 @@ var TypeScript; this.lval.varFlags |= VarFlags.AutoInit; } } - ForInStatement.prototype.isLoop = function () { - return true; - }; + ForInStatement.prototype.isLoop = function () { return true; }; ForInStatement.prototype.isFiltered = function () { if (this.body) { var singleItem = null; @@ -4099,13 +4002,16 @@ var TypeScript; var target = cond.target; if (target.nodeType == NodeType.Dot) { var binex = target; - if ((binex.operand1.nodeType == NodeType.Name) && (this.obj.nodeType == NodeType.Name) && (binex.operand1.actualText == this.obj.actualText)) { + if ((binex.operand1.nodeType == NodeType.Name) && + (this.obj.nodeType == NodeType.Name) && + (binex.operand1.actualText == this.obj.actualText)) { var prop = binex.operand2; if (prop.actualText == "hasOwnProperty") { var args = cond.arguments; if ((args !== null) && (args.members.length == 1)) { var arg = args.members[0]; - if ((arg.nodeType == NodeType.Name) && (this.lval.nodeType == NodeType.Name)) { + if ((arg.nodeType == NodeType.Name) && + (this.lval.nodeType == NodeType.Name)) { if ((this.lval.actualText) == arg.actualText) { return true; } @@ -4179,9 +4085,7 @@ var TypeScript; _super.call(this, NodeType.For); this.init = init; } - ForStatement.prototype.isLoop = function () { - return true; - }; + ForStatement.prototype.isLoop = function () { return true; }; ForStatement.prototype.emit = function (emitter, tokenId, startLine) { emitter.emitParensAndCommentsInPlace(this, true); emitter.recordSourceMappingStart(this); @@ -4273,9 +4177,7 @@ var TypeScript; this.expr = expr; this.withSym = null; } - WithStatement.prototype.isCompoundStatement = function () { - return true; - }; + WithStatement.prototype.isCompoundStatement = function () { return true; }; WithStatement.prototype.emit = function (emitter, tokenId, startLine) { emitter.emitParensAndCommentsInPlace(this, true); emitter.recordSourceMappingStart(this); @@ -4302,9 +4204,7 @@ var TypeScript; this.defaultCase = null; this.statement = new ASTSpan(); } - SwitchStatement.prototype.isCompoundStatement = function () { - return true; - }; + SwitchStatement.prototype.isCompoundStatement = function () { return true; }; SwitchStatement.prototype.emit = function (emitter, tokenId, startLine) { emitter.emitParensAndCommentsInPlace(this, true); emitter.recordSourceMappingStart(this); @@ -4458,9 +4358,7 @@ var TypeScript; this.tryNode = tryNode; this.finallyNode = finallyNode; } - TryFinally.prototype.isCompoundStatement = function () { - return true; - }; + TryFinally.prototype.isCompoundStatement = function () { return true; }; TryFinally.prototype.emit = function (emitter, tokenId, startLine) { emitter.recordSourceMappingStart(this); emitter.emitJavascript(this.tryNode, TokenID.Try, false); @@ -4505,9 +4403,7 @@ var TypeScript; this.tryNode = tryNode; this.catchNode = catchNode; } - TryCatch.prototype.isCompoundStatement = function () { - return true; - }; + TryCatch.prototype.isCompoundStatement = function () { return true; }; TryCatch.prototype.emit = function (emitter, tokenId, startLine) { emitter.emitParensAndCommentsInPlace(this, true); emitter.recordSourceMappingStart(this); @@ -4697,9 +4593,7 @@ var TypeScript; } } else { - this.text = [ - (this.content.replace(/^\s+|\s+$/g, '')) - ]; + this.text = [(this.content.replace(/^\s+|\s+$/g, ''))]; } } return this.text; diff --git a/tests/baselines/reference/parserRealSource14.js b/tests/baselines/reference/parserRealSource14.js index f36f00235f..4312cb3851 100644 --- a/tests/baselines/reference/parserRealSource14.js +++ b/tests/baselines/reference/parserRealSource14.js @@ -607,9 +607,7 @@ var TypeScript; }; AstPath.prototype.clone = function () { var clone = new AstPath(); - clone.asts = this.asts.map(function (value) { - return value; - }); + clone.asts = this.asts.map(function (value) { return value; }); clone.top = this.top; return clone; }; @@ -658,167 +656,288 @@ var TypeScript; AstPath.prototype.isNameOfClass = function () { if (this.ast() === null || this.parent() === null) return false; - return (this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ClassDeclaration) && (this.parent().name === this.ast()); + return (this.ast().nodeType === TypeScript.NodeType.Name) && + (this.parent().nodeType === TypeScript.NodeType.ClassDeclaration) && + (this.parent().name === this.ast()); }; AstPath.prototype.isNameOfInterface = function () { if (this.ast() === null || this.parent() === null) return false; - return (this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.InterfaceDeclaration) && (this.parent().name === this.ast()); + return (this.ast().nodeType === TypeScript.NodeType.Name) && + (this.parent().nodeType === TypeScript.NodeType.InterfaceDeclaration) && + (this.parent().name === this.ast()); }; AstPath.prototype.isNameOfArgument = function () { if (this.ast() === null || this.parent() === null) return false; - return (this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ArgDecl) && (this.parent().id === this.ast()); + return (this.ast().nodeType === TypeScript.NodeType.Name) && + (this.parent().nodeType === TypeScript.NodeType.ArgDecl) && + (this.parent().id === this.ast()); }; AstPath.prototype.isNameOfVariable = function () { if (this.ast() === null || this.parent() === null) return false; - return (this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.VarDecl) && (this.parent().id === this.ast()); + return (this.ast().nodeType === TypeScript.NodeType.Name) && + (this.parent().nodeType === TypeScript.NodeType.VarDecl) && + (this.parent().id === this.ast()); }; AstPath.prototype.isNameOfModule = function () { if (this.ast() === null || this.parent() === null) return false; - return (this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.ModuleDeclaration) && (this.parent().name === this.ast()); + return (this.ast().nodeType === TypeScript.NodeType.Name) && + (this.parent().nodeType === TypeScript.NodeType.ModuleDeclaration) && + (this.parent().name === this.ast()); }; AstPath.prototype.isNameOfFunction = function () { if (this.ast() === null || this.parent() === null) return false; - return (this.ast().nodeType === TypeScript.NodeType.Name) && (this.parent().nodeType === TypeScript.NodeType.FuncDecl) && (this.parent().name === this.ast()); + return (this.ast().nodeType === TypeScript.NodeType.Name) && + (this.parent().nodeType === TypeScript.NodeType.FuncDecl) && + (this.parent().name === this.ast()); }; AstPath.prototype.isChildOfScript = function () { var ast = lastOf(this.asts); - return this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Script; + return this.count() >= 3 && + this.asts[this.top] === ast && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.Script; }; AstPath.prototype.isChildOfModule = function () { var ast = lastOf(this.asts); - return this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ModuleDeclaration; + return this.count() >= 3 && + this.asts[this.top] === ast && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.ModuleDeclaration; }; AstPath.prototype.isChildOfClass = function () { var ast = lastOf(this.asts); - return this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ClassDeclaration; + return this.count() >= 3 && + this.asts[this.top] === ast && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.ClassDeclaration; }; AstPath.prototype.isArgumentOfClassConstructor = function () { var ast = lastOf(this.asts); - return this.count() >= 5 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 3].nodeType === TypeScript.NodeType.List && this.asts[this.top - 4].nodeType === TypeScript.NodeType.ClassDeclaration && (this.asts[this.top - 2].isConstructor) && (this.asts[this.top - 2].arguments === this.asts[this.top - 1]) && (this.asts[this.top - 4].constructorDecl === this.asts[this.top - 2]); + return this.count() >= 5 && + this.asts[this.top] === ast && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && + this.asts[this.top - 3].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 4].nodeType === TypeScript.NodeType.ClassDeclaration && + (this.asts[this.top - 2].isConstructor) && + (this.asts[this.top - 2].arguments === this.asts[this.top - 1]) && + (this.asts[this.top - 4].constructorDecl === this.asts[this.top - 2]); }; AstPath.prototype.isChildOfInterface = function () { var ast = lastOf(this.asts); - return this.count() >= 3 && this.asts[this.top] === ast && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.InterfaceDeclaration; + return this.count() >= 3 && + this.asts[this.top] === ast && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.InterfaceDeclaration; }; AstPath.prototype.isTopLevelImplicitModule = function () { - return this.count() >= 1 && this.asts[this.top].nodeType === TypeScript.NodeType.ModuleDeclaration && TypeScript.hasFlag(this.asts[this.top].modFlags, TypeScript.ModuleFlags.IsWholeFile); + return this.count() >= 1 && + this.asts[this.top].nodeType === TypeScript.NodeType.ModuleDeclaration && + TypeScript.hasFlag(this.asts[this.top].modFlags, TypeScript.ModuleFlags.IsWholeFile); }; AstPath.prototype.isBodyOfTopLevelImplicitModule = function () { - return this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && this.asts[this.top - 1].members == this.asts[this.top - 0] && TypeScript.hasFlag(this.asts[this.top - 1].modFlags, TypeScript.ModuleFlags.IsWholeFile); + return this.count() >= 2 && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && + this.asts[this.top - 1].members == this.asts[this.top - 0] && + TypeScript.hasFlag(this.asts[this.top - 1].modFlags, TypeScript.ModuleFlags.IsWholeFile); }; AstPath.prototype.isBodyOfScript = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Script && this.asts[this.top - 1].bod == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Script && + this.asts[this.top - 1].bod == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfSwitch = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Switch && this.asts[this.top - 1].caseList == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Switch && + this.asts[this.top - 1].caseList == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfModule = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && this.asts[this.top - 1].members == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.ModuleDeclaration && + this.asts[this.top - 1].members == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfClass = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ClassDeclaration && this.asts[this.top - 1].members == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.ClassDeclaration && + this.asts[this.top - 1].members == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfFunction = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 1].bod == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl && + this.asts[this.top - 1].bod == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfInterface = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.InterfaceDeclaration && this.asts[this.top - 1].members == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.InterfaceDeclaration && + this.asts[this.top - 1].members == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfBlock = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Block && this.asts[this.top - 1].statements == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Block && + this.asts[this.top - 1].statements == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfFor = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.For && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.For && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfCase = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Case && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Case && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfTry = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Try && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Try && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfCatch = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Catch && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Catch && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfDoWhile = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.DoWhile && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.DoWhile && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfWhile = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.While && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.While && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfForIn = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ForIn && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.ForIn && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfWith = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.With && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.With && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfFinally = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Finally && this.asts[this.top - 1].body == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Finally && + this.asts[this.top - 1].body == this.asts[this.top - 0]; }; AstPath.prototype.isCaseOfSwitch = function () { - return this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].caseList == this.asts[this.top - 1]; + return this.count() >= 3 && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 2].caseList == this.asts[this.top - 1]; }; AstPath.prototype.isDefaultCaseOfSwitch = function () { - return this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].caseList == this.asts[this.top - 1] && this.asts[this.top - 2].defaultCase == this.asts[this.top - 0]; + return this.count() >= 3 && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.Switch && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 2].caseList == this.asts[this.top - 1] && + this.asts[this.top - 2].defaultCase == this.asts[this.top - 0]; }; AstPath.prototype.isListOfObjectLit = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].operand == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 1].operand == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfObjectLit = function () { return this.isListOfObjectLit(); }; AstPath.prototype.isEmptyListOfObjectLit = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].operand == this.asts[this.top - 0] && this.asts[this.top - 0].members.length == 0; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.ObjectLit && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 1].operand == this.asts[this.top - 0] && + this.asts[this.top - 0].members.length == 0; }; AstPath.prototype.isMemberOfObjectLit = function () { - return this.count() >= 3 && this.asts[this.top - 2].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Member && this.asts[this.top - 2].operand == this.asts[this.top - 1]; + return this.count() >= 3 && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.ObjectLit && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.Member && + this.asts[this.top - 2].operand == this.asts[this.top - 1]; }; AstPath.prototype.isNameOfMemberOfObjectLit = function () { - return this.count() >= 4 && this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit && this.asts[this.top - 2].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Name && this.asts[this.top - 3].operand == this.asts[this.top - 2]; + return this.count() >= 4 && + this.asts[this.top - 3].nodeType === TypeScript.NodeType.ObjectLit && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.Name && + this.asts[this.top - 3].operand == this.asts[this.top - 2]; }; AstPath.prototype.isListOfArrayLit = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.ArrayLit && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].operand == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.ArrayLit && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 1].operand == this.asts[this.top - 0]; }; AstPath.prototype.isTargetOfMember = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && this.asts[this.top - 1].operand1 === this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && + this.asts[this.top - 1].operand1 === this.asts[this.top - 0]; }; AstPath.prototype.isMemberOfMember = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && this.asts[this.top - 1].operand2 === this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Member && + this.asts[this.top - 1].operand2 === this.asts[this.top - 0]; }; AstPath.prototype.isItemOfList = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List; //(this.asts[this.top - 1]).operand2 === this.asts[this.top - 0]; }; AstPath.prototype.isThenOfIf = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.If && this.asts[this.top - 1].thenBod == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.If && + this.asts[this.top - 1].thenBod == this.asts[this.top - 0]; }; AstPath.prototype.isElseOfIf = function () { - return this.count() >= 2 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.If && this.asts[this.top - 1].elseBod == this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.If && + this.asts[this.top - 1].elseBod == this.asts[this.top - 0]; }; AstPath.prototype.isBodyOfDefaultCase = function () { return this.isBodyOfCase(); }; AstPath.prototype.isSingleStatementList = function () { - return this.count() >= 1 && this.asts[this.top].nodeType === TypeScript.NodeType.List && this.asts[this.top].members.length === 1; + return this.count() >= 1 && + this.asts[this.top].nodeType === TypeScript.NodeType.List && + this.asts[this.top].members.length === 1; }; AstPath.prototype.isArgumentListOfFunction = function () { - return this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 1].arguments === this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.FuncDecl && + this.asts[this.top - 1].arguments === this.asts[this.top - 0]; }; AstPath.prototype.isArgumentOfFunction = function () { - return this.count() >= 3 && this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && this.asts[this.top - 2].arguments === this.asts[this.top - 1]; + return this.count() >= 3 && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 2].nodeType === TypeScript.NodeType.FuncDecl && + this.asts[this.top - 2].arguments === this.asts[this.top - 1]; }; AstPath.prototype.isArgumentListOfCall = function () { - return this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.Call && this.asts[this.top - 1].arguments === this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.Call && + this.asts[this.top - 1].arguments === this.asts[this.top - 0]; }; AstPath.prototype.isArgumentListOfNew = function () { - return this.count() >= 2 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && this.asts[this.top - 1].nodeType === TypeScript.NodeType.New && this.asts[this.top - 1].arguments === this.asts[this.top - 0]; + return this.count() >= 2 && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.List && + this.asts[this.top - 1].nodeType === TypeScript.NodeType.New && + this.asts[this.top - 1].arguments === this.asts[this.top - 0]; }; AstPath.prototype.isSynthesizedBlock = function () { - return this.count() >= 1 && this.asts[this.top - 0].nodeType === TypeScript.NodeType.Block && this.asts[this.top - 0].isStatementBlock === false; + return this.count() >= 1 && + this.asts[this.top - 0].nodeType === TypeScript.NodeType.Block && + this.asts[this.top - 0].isStatementBlock === false; }; return AstPath; })(); @@ -879,7 +998,9 @@ var TypeScript; // bar // 0123 // If "position == 3", the caret is at the "right" of the "r" character, which should be considered valid - var inclusive = hasFlag(options, GetAstPathOptions.EdgeInclusive) || cur.nodeType === TypeScript.NodeType.Name || pos === script.limChar; // Special "EOF" case + var inclusive = hasFlag(options, GetAstPathOptions.EdgeInclusive) || + cur.nodeType === TypeScript.NodeType.Name || + pos === script.limChar; // Special "EOF" case var minChar = cur.minChar; var limChar = cur.limChar + (inclusive ? 1 : 0); if (pos >= minChar && pos < limChar) { diff --git a/tests/baselines/reference/parserRealSource4.js b/tests/baselines/reference/parserRealSource4.js index 1d6ed0aaf1..563e9e92a0 100644 --- a/tests/baselines/reference/parserRealSource4.js +++ b/tests/baselines/reference/parserRealSource4.js @@ -377,9 +377,7 @@ var TypeScript; } return false; }; - StringHashTable.prototype.count = function () { - return this.itemCount; - }; + StringHashTable.prototype.count = function () { return this.itemCount; }; StringHashTable.prototype.lookup = function (key) { var data = this.table[key]; if (data != undefined) { @@ -515,9 +513,7 @@ var TypeScript; } return result; }; - HashTable.prototype.count = function () { - return this.itemCount; - }; + HashTable.prototype.count = function () { return this.itemCount; }; HashTable.prototype.lookup = function (key) { var current; var val = this.hashFn(key); diff --git a/tests/baselines/reference/parserRealSource6.js b/tests/baselines/reference/parserRealSource6.js index e747b95e61..d65207b8c7 100644 --- a/tests/baselines/reference/parserRealSource6.js +++ b/tests/baselines/reference/parserRealSource6.js @@ -329,7 +329,8 @@ var TypeScript; // is has not been fully re-parsed yet. if (ast.nodeType == NodeType.Script && context.pos > limChar) limChar = context.pos; - if ((minChar <= context.pos) && (limChar >= context.pos)) { + if ((minChar <= context.pos) && + (limChar >= context.pos)) { switch (ast.nodeType) { case NodeType.Script: var script = ast; diff --git a/tests/baselines/reference/parserRealSource7.js b/tests/baselines/reference/parserRealSource7.js index 73b9aab501..5073c33feb 100644 --- a/tests/baselines/reference/parserRealSource7.js +++ b/tests/baselines/reference/parserRealSource7.js @@ -962,11 +962,7 @@ var TypeScript; var importDecl = ast; var isExported = hasFlag(importDecl.varFlags, VarFlags.Exported); // REVIEW: technically, this call isn't strictly necessary, since we'll find the type during the call to resolveTypeMembers - var aliasedModSymbol = findSymbolFromAlias(importDecl.alias, { - topLevelScope: scopeChain, - members: null, - tcContext: context - }); + var aliasedModSymbol = findSymbolFromAlias(importDecl.alias, { topLevelScope: scopeChain, members: null, tcContext: context }); var isGlobal = context.scopeChain.container == context.checker.gloMod; if (aliasedModSymbol) { var aliasedModType = aliasedModSymbol.getType(); @@ -1057,7 +1053,8 @@ var TypeScript; if (isExported) { typeSymbol.flags |= SymbolFlags.Exported; } - if ((context.scopeChain.moduleDecl) || (context.scopeChain.container == context.checker.gloMod)) { + if ((context.scopeChain.moduleDecl) || + (context.scopeChain.container == context.checker.gloMod)) { typeSymbol.flags |= SymbolFlags.ModuleMember; } moduleDecl.mod = modType; @@ -1083,7 +1080,11 @@ var TypeScript; // REVIEW-CLASSES if (!typeSymbol) { var valTypeSymbol = scopeChain.scope.findLocal(className, false, false); - if (valTypeSymbol && valTypeSymbol.isType() && valTypeSymbol.declAST && valTypeSymbol.declAST.nodeType == NodeType.FuncDecl && valTypeSymbol.declAST.isSignature()) { + if (valTypeSymbol && + valTypeSymbol.isType() && + valTypeSymbol.declAST && + valTypeSymbol.declAST.nodeType == NodeType.FuncDecl && + valTypeSymbol.declAST.isSignature()) { typeSymbol = valTypeSymbol; foundValSymbol = true; if (isExported) { @@ -1237,7 +1238,10 @@ var TypeScript; if (context.scopeChain.moduleDecl) { context.scopeChain.moduleDecl.recordNonInterface(); } - if (isProperty || isExported || (context.scopeChain.container == context.checker.gloMod) || context.scopeChain.moduleDecl) { + if (isProperty || + isExported || + (context.scopeChain.container == context.checker.gloMod) || + context.scopeChain.moduleDecl) { if (isAmbient) { var existingSym = scopeChain.scope.findLocal(varDecl.id.text, false, false); if (existingSym) { @@ -1258,7 +1262,8 @@ var TypeScript; } field.symbol = fieldSymbol; fieldSymbol.declAST = ast; - if ((context.scopeChain.moduleDecl) || (context.scopeChain.container == context.checker.gloMod)) { + if ((context.scopeChain.moduleDecl) || + (context.scopeChain.container == context.checker.gloMod)) { fieldSymbol.flags |= SymbolFlags.ModuleMember; fieldSymbol.declModule = context.scopeChain.moduleDecl; } @@ -1309,7 +1314,12 @@ var TypeScript; // If the parent is the constructor, and this isn't an instance method, skip it. // That way, we'll set the type during scope assignment, and can be sure that the // function will be placed in the constructor-local scope - if (!funcDecl.isConstructor && containerSym && containerSym.declAST && containerSym.declAST.nodeType == NodeType.FuncDecl && containerSym.declAST.isConstructor && !funcDecl.isMethod()) { + if (!funcDecl.isConstructor && + containerSym && + containerSym.declAST && + containerSym.declAST.nodeType == NodeType.FuncDecl && + containerSym.declAST.isConstructor && + !funcDecl.isMethod()) { return go; } // Interfaces and overloads @@ -1398,7 +1408,14 @@ var TypeScript; } } // REVIEW: Move this check into the typecheck phase? It's only being run over properties... - if (fgSym && !fgSym.isAccessor() && fgSym.type && fgSym.type.construct && fgSym.type.construct.signatures != [] && (fgSym.type.construct.signatures[0].declAST == null || !hasFlag(fgSym.type.construct.signatures[0].declAST.fncFlags, FncFlags.Ambient)) && !funcDecl.isConstructor) { + if (fgSym && + !fgSym.isAccessor() && + fgSym.type && + fgSym.type.construct && + fgSym.type.construct.signatures != [] && + (fgSym.type.construct.signatures[0].declAST == null || + !hasFlag(fgSym.type.construct.signatures[0].declAST.fncFlags, FncFlags.Ambient)) && + !funcDecl.isConstructor) { context.checker.errorReporter.simpleError(funcDecl, "Functions may not have class overloads"); } if (fgSym && !(fgSym.kind() == SymbolKind.Type) && funcDecl.isMethod() && !funcDecl.isAccessor() && !funcDecl.isConstructor) { diff --git a/tests/baselines/reference/parserRealSource8.js b/tests/baselines/reference/parserRealSource8.js index fcdb170ae1..8a667ad6db 100644 --- a/tests/baselines/reference/parserRealSource8.js +++ b/tests/baselines/reference/parserRealSource8.js @@ -632,7 +632,8 @@ var TypeScript; // the enclosing scope // REVIEW: Some twisted logic here - this needs to be cleaned up once old classes are removed // - if it's a new class, always use the contained scope, since we initialize the constructor scope below - if (context.scopeChain.thisType && (!funcDecl.isConstructor || hasFlag(funcDecl.fncFlags, FncFlags.ClassMethod))) { + if (context.scopeChain.thisType && + (!funcDecl.isConstructor || hasFlag(funcDecl.fncFlags, FncFlags.ClassMethod))) { var instType = context.scopeChain.thisType; if (!(instType.typeFlags & TypeFlags.IsClass) && !hasFlag(funcDecl.fncFlags, FncFlags.ClassMethod)) { if (!funcDecl.isMethod() || isStatic) { @@ -644,7 +645,10 @@ var TypeScript; } } else { - if (context.scopeChain.previous.scope.container && context.scopeChain.previous.scope.container.declAST && context.scopeChain.previous.scope.container.declAST.nodeType == NodeType.FuncDecl && context.scopeChain.previous.scope.container.declAST.isConstructor) { + if (context.scopeChain.previous.scope.container && + context.scopeChain.previous.scope.container.declAST && + context.scopeChain.previous.scope.container.declAST.nodeType == NodeType.FuncDecl && + context.scopeChain.previous.scope.container.declAST.isConstructor) { // if the parent is the class constructor, use the constructor scope parentScope = instType.constructorScope; } @@ -681,7 +685,12 @@ var TypeScript; outerFnc.innerStaticFuncs[outerFnc.innerStaticFuncs.length] = funcDecl; } else { - if (!funcDecl.isConstructor && container && container.declAST && container.declAST.nodeType == NodeType.FuncDecl && container.declAST.isConstructor && !funcDecl.isMethod()) { + if (!funcDecl.isConstructor && + container && + container.declAST && + container.declAST.nodeType == NodeType.FuncDecl && + container.declAST.isConstructor && + !funcDecl.isMethod()) { funcScope = context.scopeChain.thisType.constructorScope; //locals; } else { @@ -702,7 +711,11 @@ var TypeScript; } context.typeFlow.checker.createFunctionSignature(funcDecl, container, funcScope, fgSym, fgSym == null); // it's a getter or setter for a class property - if (!funcDecl.accessorSymbol && (funcDecl.fncFlags & FncFlags.ClassMethod) && container && ((!fgSym || fgSym.declAST.nodeType != NodeType.FuncDecl) && funcDecl.isAccessor()) || (fgSym && fgSym.isAccessor())) { + if (!funcDecl.accessorSymbol && + (funcDecl.fncFlags & FncFlags.ClassMethod) && + container && + ((!fgSym || fgSym.declAST.nodeType != NodeType.FuncDecl) && funcDecl.isAccessor()) || + (fgSym && fgSym.isAccessor())) { funcDecl.accessorSymbol = context.typeFlow.checker.createAccessorSymbol(funcDecl, fgSym, container.getType(), (funcDecl.isMethod() && isStatic), true, funcScope, container); } funcDecl.type.symbol.flags |= SymbolFlags.TypeSetDuringScopeAssignment; diff --git a/tests/baselines/reference/parserRealSource9.js b/tests/baselines/reference/parserRealSource9.js index 5b1423bff3..dba28c4f29 100644 --- a/tests/baselines/reference/parserRealSource9.js +++ b/tests/baselines/reference/parserRealSource9.js @@ -364,9 +364,7 @@ var TypeScript; // context of a given module (E.g., an outer import statement) if (typeSymbol.aliasLink && !typeSymbol.type && typeSymbol.aliasLink.alias.nodeType == NodeType.Name) { var modPath = typeSymbol.aliasLink.alias.text; - var modSym = this.checker.findSymbolForDynamicModule(modPath, this.checker.locationInfo.filename, function (id) { - return scope.find(id, false, true); - }); + var modSym = this.checker.findSymbolForDynamicModule(modPath, this.checker.locationInfo.filename, function (id) { return scope.find(id, false, true); }); if (modSym) { typeSymbol.type = modSym.getType(); } diff --git a/tests/baselines/reference/parserRegularExpressionDivideAmbiguity1.js b/tests/baselines/reference/parserRegularExpressionDivideAmbiguity1.js index 79e0c04d40..c3e61545c2 100644 --- a/tests/baselines/reference/parserRegularExpressionDivideAmbiguity1.js +++ b/tests/baselines/reference/parserRegularExpressionDivideAmbiguity1.js @@ -3,4 +3,5 @@ /notregexp/a.foo(); //// [parserRegularExpressionDivideAmbiguity1.js] -1 / notregexp / a.foo(); +1 + / notregexp / a.foo(); diff --git a/tests/baselines/reference/parserReturnStatement4.js b/tests/baselines/reference/parserReturnStatement4.js index aab5215ba0..f6800cbb8f 100644 --- a/tests/baselines/reference/parserReturnStatement4.js +++ b/tests/baselines/reference/parserReturnStatement4.js @@ -2,8 +2,4 @@ var v = { get foo() { return } }; //// [parserReturnStatement4.js] -var v = { - get foo() { - return; - } -}; +var v = { get foo() { return; } }; diff --git a/tests/baselines/reference/parserSetAccessorWithTypeParameters1.js b/tests/baselines/reference/parserSetAccessorWithTypeParameters1.js index a19675167c..651640c646 100644 --- a/tests/baselines/reference/parserSetAccessorWithTypeParameters1.js +++ b/tests/baselines/reference/parserSetAccessorWithTypeParameters1.js @@ -8,8 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "foo", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/parserShorthandPropertyAssignment1.js b/tests/baselines/reference/parserShorthandPropertyAssignment1.js index 2aabfc906a..0ef3c50d78 100644 --- a/tests/baselines/reference/parserShorthandPropertyAssignment1.js +++ b/tests/baselines/reference/parserShorthandPropertyAssignment1.js @@ -4,10 +4,6 @@ var name:any, id: any; foo({ name?, id? }); //// [parserShorthandPropertyAssignment1.js] -function foo(obj) { -} +function foo(obj) { } var name, id; -foo({ - name: name, - id: id -}); +foo({ name: name, id: id }); diff --git a/tests/baselines/reference/parserShorthandPropertyAssignment2.js b/tests/baselines/reference/parserShorthandPropertyAssignment2.js index f05c9b08b3..0de0fa3829 100644 --- a/tests/baselines/reference/parserShorthandPropertyAssignment2.js +++ b/tests/baselines/reference/parserShorthandPropertyAssignment2.js @@ -2,6 +2,4 @@ var v = { class }; //// [parserShorthandPropertyAssignment2.js] -var v = { - class: -}; +var v = { class: }; diff --git a/tests/baselines/reference/parserShorthandPropertyAssignment3.js b/tests/baselines/reference/parserShorthandPropertyAssignment3.js index a1d5ad3e64..814a725dcb 100644 --- a/tests/baselines/reference/parserShorthandPropertyAssignment3.js +++ b/tests/baselines/reference/parserShorthandPropertyAssignment3.js @@ -2,6 +2,4 @@ var v = { "" }; //// [parserShorthandPropertyAssignment3.js] -var v = { - "": -}; +var v = { "": }; diff --git a/tests/baselines/reference/parserShorthandPropertyAssignment4.js b/tests/baselines/reference/parserShorthandPropertyAssignment4.js index b0f05e2d9e..e10928ae2a 100644 --- a/tests/baselines/reference/parserShorthandPropertyAssignment4.js +++ b/tests/baselines/reference/parserShorthandPropertyAssignment4.js @@ -2,6 +2,4 @@ var v = { 0 }; //// [parserShorthandPropertyAssignment4.js] -var v = { - 0: -}; +var v = { 0: }; diff --git a/tests/baselines/reference/parserShorthandPropertyAssignment5.js b/tests/baselines/reference/parserShorthandPropertyAssignment5.js index 9dc4c78112..90d74722a9 100644 --- a/tests/baselines/reference/parserShorthandPropertyAssignment5.js +++ b/tests/baselines/reference/parserShorthandPropertyAssignment5.js @@ -4,6 +4,4 @@ var obj = { greet? }; //// [parserShorthandPropertyAssignment5.js] var greet = "hello"; -var obj = { - greet: greet -}; +var obj = { greet: greet }; diff --git a/tests/baselines/reference/parserSkippedTokens16.js b/tests/baselines/reference/parserSkippedTokens16.js index a31d0e7e24..dfbd8a4277 100644 --- a/tests/baselines/reference/parserSkippedTokens16.js +++ b/tests/baselines/reference/parserSkippedTokens16.js @@ -11,15 +11,12 @@ var x = //// [parserSkippedTokens16.js] foo(); Bar; -{ -} -{ -} +{ } +{ } 4 + ; 5; var M; (function (M) { - function a(T) { - } + function a(T) { } })(M || (M = {})); var x = ; diff --git a/tests/baselines/reference/parserStrictMode12.js b/tests/baselines/reference/parserStrictMode12.js index 199ed43cc9..ce97b2a91c 100644 --- a/tests/baselines/reference/parserStrictMode12.js +++ b/tests/baselines/reference/parserStrictMode12.js @@ -4,7 +4,4 @@ var v = { set foo(eval) { } } //// [parserStrictMode12.js] "use strict"; -var v = { - set foo(eval) { - } -}; +var v = { set foo(eval) { } }; diff --git a/tests/baselines/reference/parserSymbolIndexer5.js b/tests/baselines/reference/parserSymbolIndexer5.js index 43c456b64a..3aa046e211 100644 --- a/tests/baselines/reference/parserSymbolIndexer5.js +++ b/tests/baselines/reference/parserSymbolIndexer5.js @@ -5,6 +5,5 @@ var x = { //// [parserSymbolIndexer5.js] var x = { - [s]: symbol, - "": + [s]: symbol, "": }; diff --git a/tests/baselines/reference/parserSymbolProperty7.js b/tests/baselines/reference/parserSymbolProperty7.js index a3061ee1b5..1b3abdd62f 100644 --- a/tests/baselines/reference/parserSymbolProperty7.js +++ b/tests/baselines/reference/parserSymbolProperty7.js @@ -5,6 +5,5 @@ class C { //// [parserSymbolProperty7.js] class C { - [Symbol.toStringTag]() { - } + [Symbol.toStringTag]() { } } diff --git a/tests/baselines/reference/parserUnaryExpression2.js b/tests/baselines/reference/parserUnaryExpression2.js index 97b17b2b80..2d1fa8eef5 100644 --- a/tests/baselines/reference/parserUnaryExpression2.js +++ b/tests/baselines/reference/parserUnaryExpression2.js @@ -2,5 +2,4 @@ ++function(e) { } //// [parserUnaryExpression2.js] -++function (e) { -}; +++function (e) { }; diff --git a/tests/baselines/reference/parserUnaryExpression3.js b/tests/baselines/reference/parserUnaryExpression3.js index f075032a7c..37a9f72e7b 100644 --- a/tests/baselines/reference/parserUnaryExpression3.js +++ b/tests/baselines/reference/parserUnaryExpression3.js @@ -2,6 +2,4 @@ ++[0]; //// [parserUnaryExpression3.js] -++[ - 0 -]; +++[0]; diff --git a/tests/baselines/reference/parserUnicodeWhitespaceCharacter1.js b/tests/baselines/reference/parserUnicodeWhitespaceCharacter1.js index e6f7a2374e..dfd9b80705 100644 --- a/tests/baselines/reference/parserUnicodeWhitespaceCharacter1.js +++ b/tests/baselines/reference/parserUnicodeWhitespaceCharacter1.js @@ -3,5 +3,4 @@ function foo(){ } //// [parserUnicodeWhitespaceCharacter1.js] -function foo() { -} +function foo() { } diff --git a/tests/baselines/reference/parserUsingConstructorAsIdentifier.js b/tests/baselines/reference/parserUsingConstructorAsIdentifier.js index c239bbe3c3..ebf5663573 100644 --- a/tests/baselines/reference/parserUsingConstructorAsIdentifier.js +++ b/tests/baselines/reference/parserUsingConstructorAsIdentifier.js @@ -41,8 +41,7 @@ //// [parserUsingConstructorAsIdentifier.js] function define(constructor, instanceMembers, staticMembers) { - constructor = constructor || function () { - }; + constructor = constructor || function () { }; PluginUtilities.Utilities.markSupportedForProcessing(constructor); if (instanceMembers) { initializeProperties(constructor.prototype, instanceMembers); @@ -54,17 +53,11 @@ function define(constructor, instanceMembers, staticMembers) { } function derive(baseClass, constructor, instanceMembers, staticMembers) { if (baseClass) { - constructor = constructor || function () { - }; + constructor = constructor || function () { }; var basePrototype = baseClass.prototype; constructor.prototype = Object.create(basePrototype); PluginUtilities.Utilities.markSupportedForProcessing(constructor); - Object.defineProperty(constructor.prototype, "constructor", { - value: constructor, - writable: true, - configurable: true, - enumerable: true - }); + Object.defineProperty(constructor.prototype, "constructor", { value: constructor, writable: true, configurable: true, enumerable: true }); if (instanceMembers) { initializeProperties(constructor.prototype, instanceMembers); } @@ -78,8 +71,7 @@ function derive(baseClass, constructor, instanceMembers, staticMembers) { } } function mix(constructor) { - constructor = constructor || function () { - }; + constructor = constructor || function () { }; var i, len; for (i = 1, len = arguments.length; i < len; i++) { initializeProperties(constructor.prototype, arguments[i]); diff --git a/tests/baselines/reference/parserharness.js b/tests/baselines/reference/parserharness.js index 3645f21e5c..0230438001 100644 --- a/tests/baselines/reference/parserharness.js +++ b/tests/baselines/reference/parserharness.js @@ -2151,9 +2151,7 @@ var Harness; function bugs(content) { var bugs = content.match(/\bbug (\d+)/i); if (bugs) { - bugs.forEach(function (bug) { - return assert.bug(bug); - }); + bugs.forEach(function (bug) { return assert.bug(bug); }); } } Assert.bugs = bugs; @@ -2166,9 +2164,7 @@ var Harness; function arrayLengthIs(arr, length) { if (arr.length != length) { var actual = ''; - arr.forEach(function (n) { - return actual = actual + '\n ' + n.toString(); - }); + arr.forEach(function (n) { return actual = actual + '\n ' + n.toString(); }); Assert.throwAssertError(new Error('Expected array to have ' + length + ' elements. Actual elements were:' + actual)); } } @@ -2275,28 +2271,17 @@ var Harness; var Logger = (function () { function Logger() { } - Logger.prototype.start = function (fileName, priority) { - }; - Logger.prototype.end = function (fileName) { - }; - Logger.prototype.scenarioStart = function (scenario) { - }; - Logger.prototype.scenarioEnd = function (scenario, error) { - }; - Logger.prototype.testStart = function (test) { - }; - Logger.prototype.pass = function (test) { - }; - Logger.prototype.bug = function (test) { - }; - Logger.prototype.fail = function (test) { - }; - Logger.prototype.error = function (test, error) { - }; - Logger.prototype.comment = function (comment) { - }; - Logger.prototype.verify = function (test, passed, actual, expected, message) { - }; + Logger.prototype.start = function (fileName, priority) { }; + Logger.prototype.end = function (fileName) { }; + Logger.prototype.scenarioStart = function (scenario) { }; + Logger.prototype.scenarioEnd = function (scenario, error) { }; + Logger.prototype.testStart = function (test) { }; + Logger.prototype.pass = function (test) { }; + Logger.prototype.bug = function (test) { }; + Logger.prototype.fail = function (test) { }; + Logger.prototype.error = function (test, error) { }; + Logger.prototype.comment = function (comment) { }; + Logger.prototype.verify = function (test, passed, actual, expected, message) { }; return Logger; })(); Harness.Logger = Logger; @@ -2363,16 +2348,13 @@ var Harness; return false; } }; - Runnable.prototype.run = function (done) { - }; + Runnable.prototype.run = function (done) { }; Runnable.prototype.runBlock = function (done) { return this.call(this.block, done); }; Runnable.prototype.runChild = function (index, done) { var _this = this; - return this.call((function (done) { - return _this.children[index].run(done); - }), done); + return this.call((function (done) { return _this.children[index].run(done); }), done); }; Runnable.pushGlobalErrorHandler = function (done) { errorHandlerStack.push(function (e) { @@ -2410,25 +2392,17 @@ var Harness; TestCase.prototype.run = function (done) { var that = this; Runnable.currentStack.push(this); - emitLog('testStart', { - desc: this.description - }); + emitLog('testStart', { desc: this.description }); if (this.block) { var async = this.runBlock(function (e) { if (e) { that.passed = false; that.error = e; - emitLog('error', { - desc: this.description, - pass: false - }, e); + emitLog('error', { desc: this.description, pass: false }, e); } else { that.passed = true; - emitLog('pass', { - desc: this.description, - pass: true - }); + emitLog('pass', { desc: this.description, pass: true }); } Runnable.currentStack.pop(); done(); @@ -2449,24 +2423,15 @@ var Harness; Scenario.prototype.run = function (done) { var that = this; Runnable.currentStack.push(this); - emitLog('scenarioStart', { - desc: this.description - }); + emitLog('scenarioStart', { desc: this.description }); var async = this.runBlock(function (e) { Runnable.currentStack.pop(); if (e) { that.passed = false; that.error = e; - var metadata = { - id: undefined, - desc: this.description, - pass: false, - bugs: assert.bugIds - }; + var metadata = { id: undefined, desc: this.description, pass: false, bugs: assert.bugIds }; // Report all bugs affecting this scenario - assert.bugIds.forEach(function (desc) { - return emitLog('bug', metadata, desc); - }); + assert.bugIds.forEach(function (desc) { return emitLog('bug', metadata, desc); }); emitLog('scenarioEnd', metadata, e); done(); } @@ -2493,16 +2458,9 @@ var Harness; if (async) return; } - var metadata = { - id: undefined, - desc: this.description, - pass: this.passed, - bugs: assert.bugIds - }; + var metadata = { id: undefined, desc: this.description, pass: this.passed, bugs: assert.bugIds }; // Report all bugs affecting this scenario - assert.bugIds.forEach(function (desc) { - return emitLog('bug', metadata, desc); - }); + assert.bugIds.forEach(function (desc) { return emitLog('bug', metadata, desc); }); emitLog('scenarioEnd', metadata); done(); }; @@ -2627,16 +2585,11 @@ var Harness; this.description = ""; this.results = {}; } - Benchmark.prototype.bench = function (subBench) { - }; - Benchmark.prototype.before = function () { - }; - Benchmark.prototype.beforeEach = function () { - }; - Benchmark.prototype.after = function () { - }; - Benchmark.prototype.afterEach = function () { - }; + Benchmark.prototype.bench = function (subBench) { }; + Benchmark.prototype.before = function () { }; + Benchmark.prototype.beforeEach = function () { }; + Benchmark.prototype.after = function () { }; + Benchmark.prototype.afterEach = function () { }; Benchmark.prototype.addTimingFor = function (name, timing) { this.results[name] = this.results[name] || new Dataset(); this.results[name].add(timing); @@ -2672,13 +2625,9 @@ var Harness; b.after(); for (var prop in b.results) { var description = b.description + (prop ? ": " + prop : ''); - emitLog('testStart', { - desc: description - }); + emitLog('testStart', { desc: description }); emitLog('pass', { - desc: description, - pass: true, - perfResults: { + desc: description, pass: true, perfResults: { mean: b.results[prop].mean(), min: b.results[prop].min(), max: b.results[prop].max(), @@ -2743,18 +2692,10 @@ var Harness; this.fileCollection[s] = writer; return writer; }; - EmitterIOHost.prototype.directoryExists = function (s) { - return false; - }; - EmitterIOHost.prototype.fileExists = function (s) { - return typeof this.fileCollection[s] !== 'undefined'; - }; - EmitterIOHost.prototype.resolvePath = function (s) { - return s; - }; - EmitterIOHost.prototype.reset = function () { - this.fileCollection = {}; - }; + EmitterIOHost.prototype.directoryExists = function (s) { return false; }; + EmitterIOHost.prototype.fileExists = function (s) { return typeof this.fileCollection[s] !== 'undefined'; }; + EmitterIOHost.prototype.resolvePath = function (s) { return s; }; + EmitterIOHost.prototype.reset = function () { this.fileCollection = {}; }; EmitterIOHost.prototype.toArray = function () { var result = []; for (var p in this.fileCollection) { @@ -2764,10 +2705,7 @@ var Harness; if (p !== '0.js') { current.lines.unshift('////[' + p + ']'); } - result.push({ - filename: p, - file: this.fileCollection[p] - }); + result.push({ filename: p, file: this.fileCollection[p] }); } } } @@ -2831,9 +2769,7 @@ var Harness; Type.prototype.normalizeToArray = function (arg) { if ((Array.isArray && Array.isArray(arg)) || arg instanceof Array) return arg; - return [ - arg - ]; + return [arg]; }; Type.prototype.compilesOk = function (testCode) { var errors = null; @@ -2991,9 +2927,7 @@ var Harness; var tyInfo = compiler.pullGetTypeInfoAtPosition(targetPosition, script2); var name = this.getTypeInfoName(tyInfo.ast); var foundValue = new Type(tyInfo.typeInfo, code, name); - if (!matchingIdentifiers.some(function (value) { - return (value.identifier === foundValue.identifier) && (value.code === foundValue.code) && (value.type === foundValue.type); - })) { + if (!matchingIdentifiers.some(function (value) { return (value.identifier === foundValue.identifier) && (value.code === foundValue.code) && (value.type === foundValue.type); })) { matchingIdentifiers.push(foundValue); } } @@ -3003,9 +2937,7 @@ var Harness; var name = this.getTypeInfoName(tyInfo.ast); if (name === targetIdentifier) { var foundValue = new Type(tyInfo.typeInfo, code, targetIdentifier); - if (!matchingIdentifiers.some(function (value) { - return (value.identifier === foundValue.identifier) && (value.code === foundValue.code) && (value.type === foundValue.type); - })) { + if (!matchingIdentifiers.some(function (value) { return (value.identifier === foundValue.identifier) && (value.code === foundValue.code) && (value.type === foundValue.type); })) { matchingIdentifiers.push(foundValue); } } @@ -3111,15 +3043,9 @@ var Harness; outputs[fn] = new Harness.Compiler.WriterAggregator(); return outputs[fn]; }, - directoryExists: function (path) { - return true; - }, - fileExists: function (path) { - return true; - }, - resolvePath: function (path) { - return path; - } + directoryExists: function (path) { return true; }, + fileExists: function (path) { return true; }, + resolvePath: function (path) { return path; } }); compiler.emitDeclarations(); var results = null; @@ -3160,9 +3086,7 @@ var Harness; this.fileResults = fileResults; this.scripts = scripts; var lines = []; - fileResults.forEach(function (v) { - return lines = lines.concat(v.file.lines); - }); + fileResults.forEach(function (v) { return lines = lines.concat(v.file.lines); }); this.code = lines.join("\n"); this.errors = []; for (var i = 0; i < errorLines.length; i++) { @@ -3219,9 +3143,7 @@ var Harness; function reset() { stdout.reset(); stderr.reset(); - var files = compiler.units.map(function (value) { - return value.filename; - }); + var files = compiler.units.map(function (value) { return value.filename; }); for (var i = 0; i < files.length; i++) { var fname = files[i]; if (fname !== 'lib.d.ts') { @@ -3382,24 +3304,12 @@ var Harness; (function (TestCaseParser) { optionRegex = /^[\/]{2}\s*@(\w+):\s*(\S*)/gm; // multiple matches on multiple lines // List of allowed metadata names - var fileMetadataNames = [ - "filename", - "comments", - "declaration", - "module", - "nolib", - "sourcemap", - "target", - "out" - ]; + var fileMetadataNames = ["filename", "comments", "declaration", "module", "nolib", "sourcemap", "target", "out"]; function extractCompilerSettings(content) { var opts = []; var match; while ((match = optionRegex.exec(content)) != null) { - opts.push({ - flag: match[1], - value: match[2] - }); + opts.push({ flag: match[1], value: match[2] }); } return opts; } @@ -3492,10 +3402,7 @@ var Harness; references: refs }; files.push(newTestFile); - return { - settings: settings, - testUnitData: files - }; + return { settings: settings, testUnitData: files }; } TestCaseParser.makeUnitsFromTest = makeUnitsFromTest; })(TestCaseParser = Harness.TestCaseParser || (Harness.TestCaseParser = {})); @@ -3542,21 +3449,9 @@ var Harness; return TypeScript.ScriptEditRange.unknown(); } var entries = this.editRanges.slice(initialEditRangeIndex); - var minDistFromStart = entries.map(function (x) { - return x.editRange.minChar; - }).reduce(function (prev, current) { - return Math.min(prev, current); - }); - var minDistFromEnd = entries.map(function (x) { - return x.length - x.editRange.limChar; - }).reduce(function (prev, current) { - return Math.min(prev, current); - }); - var aggDelta = entries.map(function (x) { - return x.editRange.delta; - }).reduce(function (prev, current) { - return prev + current; - }); + var minDistFromStart = entries.map(function (x) { return x.editRange.minChar; }).reduce(function (prev, current) { return Math.min(prev, current); }); + var minDistFromEnd = entries.map(function (x) { return x.length - x.editRange.limChar; }).reduce(function (prev, current) { return Math.min(prev, current); }); + var aggDelta = entries.map(function (x) { return x.editRange.delta; }).reduce(function (prev, current) { return prev + current; }); return new TypeScript.ScriptEditRange(minDistFromStart, entries[0].length - minDistFromEnd, aggDelta); }; return ScriptInfo; @@ -3606,21 +3501,11 @@ var Harness; ////////////////////////////////////////////////////////////////////// // ILogger implementation // - TypeScriptLS.prototype.information = function () { - return false; - }; - TypeScriptLS.prototype.debug = function () { - return true; - }; - TypeScriptLS.prototype.warning = function () { - return true; - }; - TypeScriptLS.prototype.error = function () { - return true; - }; - TypeScriptLS.prototype.fatal = function () { - return true; - }; + TypeScriptLS.prototype.information = function () { return false; }; + TypeScriptLS.prototype.debug = function () { return true; }; + TypeScriptLS.prototype.warning = function () { return true; }; + TypeScriptLS.prototype.error = function () { return true; }; + TypeScriptLS.prototype.fatal = function () { return true; }; TypeScriptLS.prototype.log = function (s) { // For debugging... //IO.printLine("TypeScriptLS:" + s); @@ -3667,8 +3552,7 @@ var Harness; TypeScriptLS.prototype.parseSourceText = function (fileName, sourceText) { var parser = new TypeScript.Parser(); parser.setErrorRecovery(null); - parser.errorCallback = function (a, b, c, d) { - }; + parser.errorCallback = function (a, b, c, d) { }; var script = parser.parse(sourceText, fileName, 0); return script; }; @@ -3728,10 +3612,7 @@ var Harness; function mapEdits(edits) { var result = []; for (var i = 0; i < edits.length; i++) { - result.push({ - edit: edits[i], - index: i - }); + result.push({ edit: edits[i], index: i }); } return result; } @@ -3773,9 +3654,7 @@ var Harness; return result; }; TypeScriptLS.prototype.getHostSettings = function () { - return JSON.stringify({ - usePullLanguageService: Harness.usePull - }); + return JSON.stringify({ usePullLanguageService: Harness.usePull }); }; return TypeScriptLS; })(); @@ -3812,9 +3691,7 @@ var Harness; Runner.runCollateral = runCollateral; function runJSString(code, callback) { // List of names that get overriden by various test code we eval - var dangerNames = [ - 'Array' - ]; + var dangerNames = ['Array']; var globalBackup = {}; var n = null; for (n in dangerNames) { @@ -3932,10 +3809,7 @@ var Harness; expected = expected.replace(/\r\n?/g, '\n'); actual = actual.replace(/\r\n?/g, '\n'); } - return { - expected: expected, - actual: actual - }; + return { expected: expected, actual: actual }; } function writeComparison(expected, actual, relativeFilename, actualFilename, descriptionForDescribe) { if (expected != actual) { diff --git a/tests/baselines/reference/parserindenter.js b/tests/baselines/reference/parserindenter.js index 514a24afcf..511e75ea13 100644 --- a/tests/baselines/reference/parserindenter.js +++ b/tests/baselines/reference/parserindenter.js @@ -778,7 +778,10 @@ var Formatting; } Indenter.prototype.GetIndentationEdits = function (token, nextToken, node, sameLineIndent) { if (this.logger.information()) { - this.logger.log("GetIndentationEdits(" + "t1=[" + token.Span.startPosition() + "," + token.Span.endPosition() + "], " + "t2=[" + (nextToken == null ? "null" : (nextToken.Span.startPosition() + "," + nextToken.Span.endPosition())) + "]" + ")"); + this.logger.log("GetIndentationEdits(" + + "t1=[" + token.Span.startPosition() + "," + token.Span.endPosition() + "], " + + "t2=[" + (nextToken == null ? "null" : (nextToken.Span.startPosition() + "," + nextToken.Span.endPosition())) + "]" + + ")"); } var result = this.GetIndentationEditsWorker(token, nextToken, node, sameLineIndent); if (this.logger.information()) { @@ -938,7 +941,8 @@ var Formatting; }; Indenter.prototype.GetSpecialCaseIndentationForLCurly = function (node) { var indentationInfo = null; - if (node.AuthorNode.Details.Kind == AuthorParseNodeKind.apnkFncDecl || node.AuthorNode.EdgeLabel == AuthorParseNodeEdge.apneThen || node.AuthorNode.EdgeLabel == AuthorParseNodeEdge.apneElse) { + if (node.AuthorNode.Details.Kind == AuthorParseNodeKind.apnkFncDecl || + node.AuthorNode.EdgeLabel == AuthorParseNodeEdge.apneThen || node.AuthorNode.EdgeLabel == AuthorParseNodeEdge.apneElse) { // flushed with the node (function & if) indentationInfo = node.GetNodeStartLineIndentation(this); return indentationInfo; @@ -1233,7 +1237,8 @@ var Formatting; // Get the parent that is really on a different line from the self node var startNodeLineNumber = this.snapshot.GetLineNumberFromPosition(tree.StartNodeSelf.AuthorNode.Details.StartOffset); parent = tree.StartNodeSelf.Parent; - while (parent != null && startNodeLineNumber == this.snapshot.GetLineNumberFromPosition(parent.AuthorNode.Details.StartOffset)) { + while (parent != null && + startNodeLineNumber == this.snapshot.GetLineNumberFromPosition(parent.AuthorNode.Details.StartOffset)) { parent = parent.Parent; } } @@ -1331,7 +1336,8 @@ var Formatting; } }; Indenter.prototype.IsMultiLineString = function (token) { - return token.tokenID === TypeScript.TokenID.StringLiteral && this.snapshot.GetLineNumberFromPosition(token.Span.endPosition()) > this.snapshot.GetLineNumberFromPosition(token.Span.startPosition()); + return token.tokenID === TypeScript.TokenID.StringLiteral && + this.snapshot.GetLineNumberFromPosition(token.Span.endPosition()) > this.snapshot.GetLineNumberFromPosition(token.Span.startPosition()); }; return Indenter; })(); diff --git a/tests/baselines/reference/parsingClassRecoversWhenHittingUnexpectedSemicolon.js b/tests/baselines/reference/parsingClassRecoversWhenHittingUnexpectedSemicolon.js index add4e3a69f..8b197fd35a 100644 --- a/tests/baselines/reference/parsingClassRecoversWhenHittingUnexpectedSemicolon.js +++ b/tests/baselines/reference/parsingClassRecoversWhenHittingUnexpectedSemicolon.js @@ -9,7 +9,6 @@ class C { var C = (function () { function C() { } - C.prototype.f = function () { - }; + C.prototype.f = function () { }; return C; })(); diff --git a/tests/baselines/reference/partiallyAmbientFundule.js b/tests/baselines/reference/partiallyAmbientFundule.js index 21cb5179ae..9b52ca2147 100644 --- a/tests/baselines/reference/partiallyAmbientFundule.js +++ b/tests/baselines/reference/partiallyAmbientFundule.js @@ -5,5 +5,4 @@ declare module foo { function foo () { } // Legal, because module is ambient //// [partiallyAmbientFundule.js] -function foo() { -} // Legal, because module is ambient +function foo() { } // Legal, because module is ambient diff --git a/tests/baselines/reference/plusOperatorWithAnyOtherType.js b/tests/baselines/reference/plusOperatorWithAnyOtherType.js index 5a30af7e9f..33ac4ebb14 100644 --- a/tests/baselines/reference/plusOperatorWithAnyOtherType.js +++ b/tests/baselines/reference/plusOperatorWithAnyOtherType.js @@ -60,17 +60,9 @@ var ResultIsNumber19 = +(undefined + undefined); // + operator on any type var ANY; var ANY1; -var ANY2 = [ - "", - "" -]; +var ANY2 = ["", ""]; var obj; -var obj1 = { - x: function (s) { - }, - y: function (s1) { - } -}; +var obj1 = { x: function (s) { }, y: function (s1) { } }; function foo() { var a; return a; diff --git a/tests/baselines/reference/plusOperatorWithBooleanType.js b/tests/baselines/reference/plusOperatorWithBooleanType.js index 81c6222280..5af1a8fb90 100644 --- a/tests/baselines/reference/plusOperatorWithBooleanType.js +++ b/tests/baselines/reference/plusOperatorWithBooleanType.js @@ -38,15 +38,11 @@ var ResultIsNumber7 = +A.foo(); //// [plusOperatorWithBooleanType.js] // + operator on boolean type var BOOLEAN; -function foo() { - return true; -} +function foo() { return true; } var A = (function () { function A() { } - A.foo = function () { - return false; - }; + A.foo = function () { return false; }; return A; })(); var M; @@ -58,10 +54,7 @@ var objA = new A(); var ResultIsNumber1 = +BOOLEAN; // boolean type literal var ResultIsNumber2 = +true; -var ResultIsNumber3 = +{ - x: true, - y: false -}; +var ResultIsNumber3 = +{ x: true, y: false }; // boolean type expressions var ResultIsNumber4 = +objA.a; var ResultIsNumber5 = +M.n; diff --git a/tests/baselines/reference/plusOperatorWithNumberType.js b/tests/baselines/reference/plusOperatorWithNumberType.js index a42147e0a3..a0adaa5dec 100644 --- a/tests/baselines/reference/plusOperatorWithNumberType.js +++ b/tests/baselines/reference/plusOperatorWithNumberType.js @@ -44,19 +44,12 @@ var ResultIsNumber11 = +(NUMBER + NUMBER); //// [plusOperatorWithNumberType.js] // + operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; -function foo() { - return 1; -} +var NUMBER1 = [1, 2]; +function foo() { return 1; } var A = (function () { function A() { } - A.foo = function () { - return 1; - }; + A.foo = function () { return 1; }; return A; })(); var M; @@ -69,16 +62,8 @@ var ResultIsNumber1 = +NUMBER; var ResultIsNumber2 = +NUMBER1; // number type literal var ResultIsNumber3 = +1; -var ResultIsNumber4 = +{ - x: 1, - y: 2 -}; -var ResultIsNumber5 = +{ - x: 1, - y: function (n) { - return n; - } -}; +var ResultIsNumber4 = +{ x: 1, y: 2 }; +var ResultIsNumber5 = +{ x: 1, y: function (n) { return n; } }; // number type expressions var ResultIsNumber6 = +objA.a; var ResultIsNumber7 = +M.n; diff --git a/tests/baselines/reference/plusOperatorWithStringType.js b/tests/baselines/reference/plusOperatorWithStringType.js index b725f62adb..ed2c60111b 100644 --- a/tests/baselines/reference/plusOperatorWithStringType.js +++ b/tests/baselines/reference/plusOperatorWithStringType.js @@ -43,19 +43,12 @@ var ResultIsNumber12 = +STRING.charAt(0); //// [plusOperatorWithStringType.js] // + operator on string type var STRING; -var STRING1 = [ - "", - "abc" -]; -function foo() { - return "abc"; -} +var STRING1 = ["", "abc"]; +function foo() { return "abc"; } var A = (function () { function A() { } - A.foo = function () { - return ""; - }; + A.foo = function () { return ""; }; return A; })(); var M; @@ -68,16 +61,8 @@ var ResultIsNumber1 = +STRING; var ResultIsNumber2 = +STRING1; // string type literal var ResultIsNumber3 = +""; -var ResultIsNumber4 = +{ - x: "", - y: "" -}; -var ResultIsNumber5 = +{ - x: "", - y: function (s) { - return s; - } -}; +var ResultIsNumber4 = +{ x: "", y: "" }; +var ResultIsNumber5 = +{ x: "", y: function (s) { return s; } }; // string type expressions var ResultIsNumber6 = +objA.a; var ResultIsNumber7 = +M.n; diff --git a/tests/baselines/reference/primitiveConstraints1.js b/tests/baselines/reference/primitiveConstraints1.js index 7d697e57df..9ee39d74e8 100644 --- a/tests/baselines/reference/primitiveConstraints1.js +++ b/tests/baselines/reference/primitiveConstraints1.js @@ -7,9 +7,7 @@ foo2(1, 'hm'); // error //// [primitiveConstraints1.js] -function foo1(t, u) { -} +function foo1(t, u) { } foo1('hm', 1); // no error -function foo2(t, u) { -} +function foo2(t, u) { } foo2(1, 'hm'); // error diff --git a/tests/baselines/reference/primitiveMembers.js b/tests/baselines/reference/primitiveMembers.js index 18ade7ca77..bf3f1a1710 100644 --- a/tests/baselines/reference/primitiveMembers.js +++ b/tests/baselines/reference/primitiveMembers.js @@ -48,9 +48,7 @@ var N; n = N; // should not work, as 'number' has a different brand N = n; // should work var o = {}; -var f = function (x) { - return x.length; -}; +var f = function (x) { return x.length; }; var r2 = /./g; var n2 = 34; var s = "yo"; @@ -59,8 +57,7 @@ var n3 = 5 || {}; var baz = (function () { function baz() { } - baz.prototype.bar = function () { - }; + baz.prototype.bar = function () { }; return baz; })(); var foo = (function (_super) { @@ -68,8 +65,6 @@ var foo = (function (_super) { function foo() { _super.apply(this, arguments); } - foo.prototype.bar = function () { - return undefined; - }; + foo.prototype.bar = function () { return undefined; }; return foo; })(baz); diff --git a/tests/baselines/reference/primtiveTypesAreIdentical.js b/tests/baselines/reference/primtiveTypesAreIdentical.js index 00a77fac91..19bdadb4ce 100644 --- a/tests/baselines/reference/primtiveTypesAreIdentical.js +++ b/tests/baselines/reference/primtiveTypesAreIdentical.js @@ -33,21 +33,14 @@ function foo7(x: any) { } //// [primtiveTypesAreIdentical.js] // primitive types are identical to themselves so these overloads will all cause errors -function foo1(x) { -} -function foo2(x) { -} -function foo3(x) { -} -function foo4(x) { -} -function foo5(x) { -} +function foo1(x) { } +function foo2(x) { } +function foo3(x) { } +function foo4(x) { } +function foo5(x) { } var E; (function (E) { E[E["A"] = 0] = "A"; })(E || (E = {})); -function foo6(x) { -} -function foo7(x) { -} +function foo6(x) { } +function foo7(x) { } diff --git a/tests/baselines/reference/privateClassPropertyAccessibleWithinClass.js b/tests/baselines/reference/privateClassPropertyAccessibleWithinClass.js index e754d49280..116b255a92 100644 --- a/tests/baselines/reference/privateClassPropertyAccessibleWithinClass.js +++ b/tests/baselines/reference/privateClassPropertyAccessibleWithinClass.js @@ -37,34 +37,20 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "y", { - get: function () { - return this.x; - }, - set: function (x) { - this.y = this.x; - }, + get: function () { return this.x; }, + set: function (x) { this.y = this.x; }, enumerable: true, configurable: true }); - C.prototype.foo = function () { - return this.foo; - }; + C.prototype.foo = function () { return this.foo; }; Object.defineProperty(C, "y", { - get: function () { - return this.x; - }, - set: function (x) { - this.y = this.x; - }, + get: function () { return this.x; }, + set: function (x) { this.y = this.x; }, enumerable: true, configurable: true }); - C.foo = function () { - return this.foo; - }; - C.bar = function () { - this.foo(); - }; + C.foo = function () { return this.foo; }; + C.bar = function () { this.foo(); }; return C; })(); // added level of function nesting @@ -74,54 +60,40 @@ var C2 = (function () { Object.defineProperty(C2.prototype, "y", { get: function () { var _this = this; - (function () { - return _this.x; - }); + (function () { return _this.x; }); return null; }, set: function (x) { var _this = this; - (function () { - _this.y = _this.x; - }); + (function () { _this.y = _this.x; }); }, enumerable: true, configurable: true }); C2.prototype.foo = function () { var _this = this; - (function () { - return _this.foo; - }); + (function () { return _this.foo; }); }; Object.defineProperty(C2, "y", { get: function () { var _this = this; - (function () { - return _this.x; - }); + (function () { return _this.x; }); return null; }, set: function (x) { var _this = this; - (function () { - _this.y = _this.x; - }); + (function () { _this.y = _this.x; }); }, enumerable: true, configurable: true }); C2.foo = function () { var _this = this; - (function () { - return _this.foo; - }); + (function () { return _this.foo; }); }; C2.bar = function () { var _this = this; - (function () { - return _this.foo(); - }); + (function () { return _this.foo(); }); }; return C2; })(); diff --git a/tests/baselines/reference/privateInstanceVisibility.js b/tests/baselines/reference/privateInstanceVisibility.js index e1ccb28751..b730a763e1 100644 --- a/tests/baselines/reference/privateInstanceVisibility.js +++ b/tests/baselines/reference/privateInstanceVisibility.js @@ -57,9 +57,7 @@ var Test; var C = (function () { function C() { } - C.prototype.getX = function () { - return this.x; - }; + C.prototype.getX = function () { return this.x; }; C.prototype.clone = function (other) { this.x = other.x; }; diff --git a/tests/baselines/reference/privateStaticMemberAccessibility.js b/tests/baselines/reference/privateStaticMemberAccessibility.js index dd022d8646..fdcb266329 100644 --- a/tests/baselines/reference/privateStaticMemberAccessibility.js +++ b/tests/baselines/reference/privateStaticMemberAccessibility.js @@ -24,9 +24,7 @@ var Derived = (function (_super) { __extends(Derived, _super); function Derived() { _super.apply(this, arguments); - this.bing = function () { - return Base.foo; - }; // error + this.bing = function () { return Base.foo; }; // error } Derived.bar = Base.foo; // error return Derived; diff --git a/tests/baselines/reference/privateVisibility.js b/tests/baselines/reference/privateVisibility.js index 80e0bf51a1..d70d7b4756 100644 --- a/tests/baselines/reference/privateVisibility.js +++ b/tests/baselines/reference/privateVisibility.js @@ -32,11 +32,8 @@ var Foo = (function () { this.pubProp = 0; this.privProp = 0; } - Foo.prototype.pubMeth = function () { - this.privMeth(); - }; - Foo.prototype.privMeth = function () { - }; + Foo.prototype.pubMeth = function () { this.privMeth(); }; + Foo.prototype.privMeth = function () { }; return Foo; })(); var f = new Foo(); diff --git a/tests/baselines/reference/privateVisibles.js b/tests/baselines/reference/privateVisibles.js index c9206964f8..b2cb673c68 100644 --- a/tests/baselines/reference/privateVisibles.js +++ b/tests/baselines/reference/privateVisibles.js @@ -15,8 +15,6 @@ var Foo = (function () { this.pvar = 0; var n = this.pvar; } - Foo.prototype.meth = function () { - var q = this.pvar; - }; + Foo.prototype.meth = function () { var q = this.pvar; }; return Foo; })(); diff --git a/tests/baselines/reference/project/baseline/amd/decl.js b/tests/baselines/reference/project/baseline/amd/decl.js index 96eaed7142..ed53ca816d 100644 --- a/tests/baselines/reference/project/baseline/amd/decl.js +++ b/tests/baselines/reference/project/baseline/amd/decl.js @@ -1,10 +1,7 @@ define(["require", "exports"], function (require, exports) { ; function point(x, y) { - return { - x: x, - y: y - }; + return { x: x, y: y }; } exports.point = point; }); diff --git a/tests/baselines/reference/project/baseline/node/decl.js b/tests/baselines/reference/project/baseline/node/decl.js index 50cca2c0f4..eb0c46dd93 100644 --- a/tests/baselines/reference/project/baseline/node/decl.js +++ b/tests/baselines/reference/project/baseline/node/decl.js @@ -1,8 +1,5 @@ ; function point(x, y) { - return { - x: x, - y: y - }; + return { x: x, y: y }; } exports.point = point; diff --git a/tests/baselines/reference/project/baseline2/amd/decl.js b/tests/baselines/reference/project/baseline2/amd/decl.js index 96eaed7142..ed53ca816d 100644 --- a/tests/baselines/reference/project/baseline2/amd/decl.js +++ b/tests/baselines/reference/project/baseline2/amd/decl.js @@ -1,10 +1,7 @@ define(["require", "exports"], function (require, exports) { ; function point(x, y) { - return { - x: x, - y: y - }; + return { x: x, y: y }; } exports.point = point; }); diff --git a/tests/baselines/reference/project/baseline2/amd/dont_emit.js b/tests/baselines/reference/project/baseline2/amd/dont_emit.js index 6b45d747c1..d3e9e871c2 100644 --- a/tests/baselines/reference/project/baseline2/amd/dont_emit.js +++ b/tests/baselines/reference/project/baseline2/amd/dont_emit.js @@ -1,6 +1,3 @@ define(["require", "exports"], function (require, exports) { - var p = { - x: 10, - y: 20 - }; + var p = { x: 10, y: 20 }; }); diff --git a/tests/baselines/reference/project/baseline2/node/decl.js b/tests/baselines/reference/project/baseline2/node/decl.js index 50cca2c0f4..eb0c46dd93 100644 --- a/tests/baselines/reference/project/baseline2/node/decl.js +++ b/tests/baselines/reference/project/baseline2/node/decl.js @@ -1,8 +1,5 @@ ; function point(x, y) { - return { - x: x, - y: y - }; + return { x: x, y: y }; } exports.point = point; diff --git a/tests/baselines/reference/project/baseline2/node/dont_emit.js b/tests/baselines/reference/project/baseline2/node/dont_emit.js index 4322b9c60b..b6239b1295 100644 --- a/tests/baselines/reference/project/baseline2/node/dont_emit.js +++ b/tests/baselines/reference/project/baseline2/node/dont_emit.js @@ -1,4 +1 @@ -var p = { - x: 10, - y: 20 -}; +var p = { x: 10, y: 20 }; diff --git a/tests/baselines/reference/project/nonRelative/amd/lib/bar/a.js b/tests/baselines/reference/project/nonRelative/amd/lib/bar/a.js index 5351258111..6ffe8c5344 100644 --- a/tests/baselines/reference/project/nonRelative/amd/lib/bar/a.js +++ b/tests/baselines/reference/project/nonRelative/amd/lib/bar/a.js @@ -1,5 +1,4 @@ define(["require", "exports"], function (require, exports) { - function hello() { - } + function hello() { } exports.hello = hello; }); diff --git a/tests/baselines/reference/project/nonRelative/amd/lib/foo/a.js b/tests/baselines/reference/project/nonRelative/amd/lib/foo/a.js index 5351258111..6ffe8c5344 100644 --- a/tests/baselines/reference/project/nonRelative/amd/lib/foo/a.js +++ b/tests/baselines/reference/project/nonRelative/amd/lib/foo/a.js @@ -1,5 +1,4 @@ define(["require", "exports"], function (require, exports) { - function hello() { - } + function hello() { } exports.hello = hello; }); diff --git a/tests/baselines/reference/project/nonRelative/amd/lib/foo/b.js b/tests/baselines/reference/project/nonRelative/amd/lib/foo/b.js index 5351258111..6ffe8c5344 100644 --- a/tests/baselines/reference/project/nonRelative/amd/lib/foo/b.js +++ b/tests/baselines/reference/project/nonRelative/amd/lib/foo/b.js @@ -1,5 +1,4 @@ define(["require", "exports"], function (require, exports) { - function hello() { - } + function hello() { } exports.hello = hello; }); diff --git a/tests/baselines/reference/project/nonRelative/node/lib/bar/a.js b/tests/baselines/reference/project/nonRelative/node/lib/bar/a.js index 3bc8930ed5..58114de3a4 100644 --- a/tests/baselines/reference/project/nonRelative/node/lib/bar/a.js +++ b/tests/baselines/reference/project/nonRelative/node/lib/bar/a.js @@ -1,3 +1,2 @@ -function hello() { -} +function hello() { } exports.hello = hello; diff --git a/tests/baselines/reference/project/nonRelative/node/lib/foo/a.js b/tests/baselines/reference/project/nonRelative/node/lib/foo/a.js index 3bc8930ed5..58114de3a4 100644 --- a/tests/baselines/reference/project/nonRelative/node/lib/foo/a.js +++ b/tests/baselines/reference/project/nonRelative/node/lib/foo/a.js @@ -1,3 +1,2 @@ -function hello() { -} +function hello() { } exports.hello = hello; diff --git a/tests/baselines/reference/project/nonRelative/node/lib/foo/b.js b/tests/baselines/reference/project/nonRelative/node/lib/foo/b.js index 3bc8930ed5..58114de3a4 100644 --- a/tests/baselines/reference/project/nonRelative/node/lib/foo/b.js +++ b/tests/baselines/reference/project/nonRelative/node/lib/foo/b.js @@ -1,3 +1,2 @@ -function hello() { -} +function hello() { } exports.hello = hello; diff --git a/tests/baselines/reference/project/prologueEmit/amd/out.js b/tests/baselines/reference/project/prologueEmit/amd/out.js index f311ea7ba2..b19a07f649 100644 --- a/tests/baselines/reference/project/prologueEmit/amd/out.js +++ b/tests/baselines/reference/project/prologueEmit/amd/out.js @@ -1,8 +1,6 @@ var _this = this; // Add a lambda to ensure global 'this' capture is triggered -(function () { - return _this.window; -}); +(function () { return _this.window; }); var __extends = this.__extends || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; function __() { this.constructor = d; } diff --git a/tests/baselines/reference/project/prologueEmit/node/out.js b/tests/baselines/reference/project/prologueEmit/node/out.js index f311ea7ba2..b19a07f649 100644 --- a/tests/baselines/reference/project/prologueEmit/node/out.js +++ b/tests/baselines/reference/project/prologueEmit/node/out.js @@ -1,8 +1,6 @@ var _this = this; // Add a lambda to ensure global 'this' capture is triggered -(function () { - return _this.window; -}); +(function () { return _this.window; }); var __extends = this.__extends || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; function __() { this.constructor = d; } diff --git a/tests/baselines/reference/project/quotesInFileAndDirectoryNames/amd/li'b/class'A.js b/tests/baselines/reference/project/quotesInFileAndDirectoryNames/amd/li'b/class'A.js index 649db9a606..115b5fff25 100644 --- a/tests/baselines/reference/project/quotesInFileAndDirectoryNames/amd/li'b/class'A.js +++ b/tests/baselines/reference/project/quotesInFileAndDirectoryNames/amd/li'b/class'A.js @@ -3,8 +3,7 @@ var test; var ClassA = (function () { function ClassA() { } - ClassA.prototype.method = function () { - }; + ClassA.prototype.method = function () { }; return ClassA; })(); test.ClassA = ClassA; diff --git a/tests/baselines/reference/project/quotesInFileAndDirectoryNames/node/li'b/class'A.js b/tests/baselines/reference/project/quotesInFileAndDirectoryNames/node/li'b/class'A.js index 649db9a606..115b5fff25 100644 --- a/tests/baselines/reference/project/quotesInFileAndDirectoryNames/node/li'b/class'A.js +++ b/tests/baselines/reference/project/quotesInFileAndDirectoryNames/node/li'b/class'A.js @@ -3,8 +3,7 @@ var test; var ClassA = (function () { function ClassA() { } - ClassA.prototype.method = function () { - }; + ClassA.prototype.method = function () { }; return ClassA; })(); test.ClassA = ClassA; diff --git a/tests/baselines/reference/promiseChaining.js b/tests/baselines/reference/promiseChaining.js index acf6b71517..ce15e2d44c 100644 --- a/tests/baselines/reference/promiseChaining.js +++ b/tests/baselines/reference/promiseChaining.js @@ -19,13 +19,7 @@ var Chain = (function () { Chain.prototype.then = function (cb) { var result = cb(this.value); // should get a fresh type parameter which each then call - var z = this.then(function (x) { - return result; - }) /*S*/.then(function (x) { - return "abc"; - }) /*string*/.then(function (x) { - return x.length; - }); // No error + var z = this.then(function (x) { return result; }) /*S*/.then(function (x) { return "abc"; }) /*string*/.then(function (x) { return x.length; }); // No error return new Chain(result); }; return Chain; diff --git a/tests/baselines/reference/promiseChaining1.js b/tests/baselines/reference/promiseChaining1.js index 54e5064809..001f1ffc1a 100644 --- a/tests/baselines/reference/promiseChaining1.js +++ b/tests/baselines/reference/promiseChaining1.js @@ -19,13 +19,7 @@ var Chain2 = (function () { Chain2.prototype.then = function (cb) { var result = cb(this.value); // should get a fresh type parameter which each then call - var z = this.then(function (x) { - return result; - }) /*S*/.then(function (x) { - return "abc"; - }) /*Function*/.then(function (x) { - return x.length; - }); // Should error on "abc" because it is not a Function + var z = this.then(function (x) { return result; }) /*S*/.then(function (x) { return "abc"; }) /*Function*/.then(function (x) { return x.length; }); // Should error on "abc" because it is not a Function return new Chain2(result); }; return Chain2; diff --git a/tests/baselines/reference/promiseChaining2.js b/tests/baselines/reference/promiseChaining2.js index 88b601aad8..ed03ab2c97 100644 --- a/tests/baselines/reference/promiseChaining2.js +++ b/tests/baselines/reference/promiseChaining2.js @@ -19,13 +19,7 @@ var Chain2 = (function () { Chain2.prototype.then = function (cb) { var result = cb(this.value); // should get a fresh type parameter which each then call - var z = this.then(function (x) { - return result; - }).then(function (x) { - return "abc"; - }).then(function (x) { - return x.length; - }); + var z = this.then(function (x) { return result; }).then(function (x) { return "abc"; }).then(function (x) { return x.length; }); return new Chain2(result); }; return Chain2; diff --git a/tests/baselines/reference/promisePermutations.js b/tests/baselines/reference/promisePermutations.js index 83b1f251e6..e59e49d6f8 100644 --- a/tests/baselines/reference/promisePermutations.js +++ b/tests/baselines/reference/promisePermutations.js @@ -251,17 +251,13 @@ var s9d = s9.then(sPromise, sPromise, sPromise); // ok var s9e = s9.then(nPromise, nPromise, nPromise); // ok var s9f = s9.then(testFunction, sIPromise, nIPromise); // error var s9g = s9.then(testFunction, nIPromise, sIPromise).then(sIPromise, sIPromise, sIPromise); // ok -var r10 = testFunction10(function (x) { - return x; -}); +var r10 = testFunction10(function (x) { return x; }); var r10a = r10.then(testFunction10, testFunction10, testFunction10); // ok var r10b = r10.then(sIPromise, sIPromise, sIPromise); // ok var r10c = r10.then(nIPromise, nIPromise, nIPromise); // ok var r10d = r10.then(testFunction, sIPromise, nIPromise); // ok var r10e = r10.then(testFunction, nIPromise, sIPromise).then(sIPromise, sIPromise, sIPromise); // ok -var s10 = testFunction10P(function (x) { - return x; -}); +var s10 = testFunction10P(function (x) { return x; }); var s10a = s10.then(testFunction10, testFunction10, testFunction10); // ok var s10b = s10.then(testFunction10P, testFunction10P, testFunction10P); // ok var s10c = s10.then(testFunction10P, testFunction10, testFunction10); // ok @@ -275,13 +271,9 @@ var s11; var s11a = s11.then(testFunction11, testFunction11, testFunction11); // ok var s11b = s11.then(testFunction11P, testFunction11P, testFunction11P); // error var s11c = s11.then(testFunction11P, testFunction11, testFunction11); // error -var r12 = testFunction12(function (x) { - return x; -}); +var r12 = testFunction12(function (x) { return x; }); var r12a = r12.then(testFunction12, testFunction12, testFunction12); // ok -var s12 = testFunction12(function (x) { - return x; -}); +var s12 = testFunction12(function (x) { return x; }); var s12a = s12.then(testFunction12, testFunction12, testFunction12); // ok var s12b = s12.then(testFunction12P, testFunction12P, testFunction12P); // ok var s12c = s12.then(testFunction12P, testFunction12, testFunction12); // ok diff --git a/tests/baselines/reference/promisePermutations2.js b/tests/baselines/reference/promisePermutations2.js index 9a321e0366..a7b5d8cf83 100644 --- a/tests/baselines/reference/promisePermutations2.js +++ b/tests/baselines/reference/promisePermutations2.js @@ -251,17 +251,13 @@ var s9d = s9.then(sPromise, sPromise, sPromise); // ok var s9e = s9.then(nPromise, nPromise, nPromise); // ok var s9f = s9.then(testFunction, sIPromise, nIPromise); // error var s9g = s9.then(testFunction, nIPromise, sIPromise).then(sIPromise, sIPromise, sIPromise); // ok -var r10 = testFunction10(function (x) { - return x; -}); +var r10 = testFunction10(function (x) { return x; }); var r10a = r10.then(testFunction10, testFunction10, testFunction10); // ok var r10b = r10.then(sIPromise, sIPromise, sIPromise); // ok var r10c = r10.then(nIPromise, nIPromise, nIPromise); // ok var r10d = r10.then(testFunction, sIPromise, nIPromise); // error var r10e = r10.then(testFunction, nIPromise, sIPromise).then(sIPromise, sIPromise, sIPromise); // ok -var s10 = testFunction10P(function (x) { - return x; -}); +var s10 = testFunction10P(function (x) { return x; }); var s10a = s10.then(testFunction10, testFunction10, testFunction10); // ok var s10b = s10.then(testFunction10P, testFunction10P, testFunction10P); // ok var s10c = s10.then(testFunction10P, testFunction10, testFunction10); // ok @@ -275,13 +271,9 @@ var s11; var s11a = s11.then(testFunction11, testFunction11, testFunction11); // ok var s11b = s11.then(testFunction11P, testFunction11P, testFunction11P); // ok var s11c = s11.then(testFunction11P, testFunction11, testFunction11); // ok -var r12 = testFunction12(function (x) { - return x; -}); +var r12 = testFunction12(function (x) { return x; }); var r12a = r12.then(testFunction12, testFunction12, testFunction12); // ok -var s12 = testFunction12(function (x) { - return x; -}); +var s12 = testFunction12(function (x) { return x; }); var s12a = s12.then(testFunction12, testFunction12, testFunction12); // ok var s12b = s12.then(testFunction12P, testFunction12P, testFunction12P); // ok var s12c = s12.then(testFunction12P, testFunction12, testFunction12); // ok diff --git a/tests/baselines/reference/promisePermutations3.js b/tests/baselines/reference/promisePermutations3.js index cbee4093a6..eb9c882b97 100644 --- a/tests/baselines/reference/promisePermutations3.js +++ b/tests/baselines/reference/promisePermutations3.js @@ -251,17 +251,13 @@ var s9d = s9.then(sPromise, sPromise, sPromise); // ok var s9e = s9.then(nPromise, nPromise, nPromise); // ok var s9f = s9.then(testFunction, sIPromise, nIPromise); // error var s9g = s9.then(testFunction, nIPromise, sIPromise).then(sIPromise, sIPromise, sIPromise); // ok -var r10 = testFunction10(function (x) { - return x; -}); +var r10 = testFunction10(function (x) { return x; }); var r10a = r10.then(testFunction10, testFunction10, testFunction10); // ok var r10b = r10.then(sIPromise, sIPromise, sIPromise); // ok var r10c = r10.then(nIPromise, nIPromise, nIPromise); // ok var r10d = r10.then(testFunction, sIPromise, nIPromise); // error var r10e = r10.then(testFunction, nIPromise, sIPromise).then(sIPromise, sIPromise, sIPromise); // ok -var s10 = testFunction10P(function (x) { - return x; -}); +var s10 = testFunction10P(function (x) { return x; }); var s10a = s10.then(testFunction10, testFunction10, testFunction10); // ok var s10b = s10.then(testFunction10P, testFunction10P, testFunction10P); // ok var s10c = s10.then(testFunction10P, testFunction10, testFunction10); // ok @@ -275,13 +271,9 @@ var s11; var s11a = s11.then(testFunction11, testFunction11, testFunction11); // ok var s11b = s11.then(testFunction11P, testFunction11P, testFunction11P); // error var s11c = s11.then(testFunction11P, testFunction11, testFunction11); // error -var r12 = testFunction12(function (x) { - return x; -}); +var r12 = testFunction12(function (x) { return x; }); var r12a = r12.then(testFunction12, testFunction12, testFunction12); // ok -var s12 = testFunction12(function (x) { - return x; -}); +var s12 = testFunction12(function (x) { return x; }); var s12a = s12.then(testFunction12, testFunction12, testFunction12); // ok var s12b = s12.then(testFunction12P, testFunction12P, testFunction12P); // ok var s12c = s12.then(testFunction12P, testFunction12, testFunction12); // ok diff --git a/tests/baselines/reference/promiseTypeInference.js b/tests/baselines/reference/promiseTypeInference.js index 8124c4b03a..6faf131438 100644 --- a/tests/baselines/reference/promiseTypeInference.js +++ b/tests/baselines/reference/promiseTypeInference.js @@ -12,6 +12,4 @@ var $$x = load("something").then(s => convert(s)); //// [promiseTypeInference.js] -var $$x = load("something").then(function (s) { - return convert(s); -}); +var $$x = load("something").then(function (s) { return convert(s); }); diff --git a/tests/baselines/reference/propertyAccess.js b/tests/baselines/reference/propertyAccess.js index d646ca4076..9295ce43b2 100644 --- a/tests/baselines/reference/propertyAccess.js +++ b/tests/baselines/reference/propertyAccess.js @@ -176,28 +176,15 @@ var Compass; Compass[Compass["East"] = 2] = "East"; Compass[Compass["West"] = 3] = "West"; })(Compass || (Compass = {})); -var numIndex = { - 3: 'three', - 'three': 'three' -}; -var strIndex = { - 'N': Compass.North, - 'E': Compass.East -}; +var numIndex = { 3: 'three', 'three': 'three' }; +var strIndex = { 'N': Compass.North, 'E': Compass.East }; var bothIndex; -function noIndex() { -} +function noIndex() { } var obj = { 10: 'ten', x: 'hello', y: 32, - z: { - n: 'world', - m: 15, - o: function () { - return false; - } - }, + z: { n: 'world', m: 15, o: function () { return false; } }, 'literal property': 100 }; var anyVar = {}; diff --git a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints2.js b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints2.js index 81cdcec543..88baee7752 100644 --- a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints2.js +++ b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints2.js @@ -92,9 +92,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - return ''; - }; + A.prototype.foo = function () { return ''; }; return A; })(); var B = (function (_super) { diff --git a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints3.js b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints3.js index eb3770bc0b..941adc7ab4 100644 --- a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints3.js +++ b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints3.js @@ -67,9 +67,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - return ''; - }; + A.prototype.foo = function () { return ''; }; return A; })(); var B = (function (_super) { diff --git a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints5.js b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints5.js index 3a88ec832f..fe3c943379 100644 --- a/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints5.js +++ b/tests/baselines/reference/propertyAccessOnTypeParameterWithConstraints5.js @@ -54,9 +54,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - return ''; - }; + A.prototype.foo = function () { return ''; }; return A; })(); var B = (function (_super) { diff --git a/tests/baselines/reference/propertyAndAccessorWithSameName.js b/tests/baselines/reference/propertyAndAccessorWithSameName.js index f466483ced..f8978ac4d1 100644 --- a/tests/baselines/reference/propertyAndAccessorWithSameName.js +++ b/tests/baselines/reference/propertyAndAccessorWithSameName.js @@ -36,8 +36,7 @@ var D = (function () { function D() { } Object.defineProperty(D.prototype, "x", { - set: function (v) { - } // error + set: function (v) { } // error , enumerable: true, configurable: true @@ -51,8 +50,7 @@ var E = (function () { get: function () { return 1; }, - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/propertyAndFunctionWithSameName.js b/tests/baselines/reference/propertyAndFunctionWithSameName.js index ec5f1903e8..eb0b437fd5 100644 --- a/tests/baselines/reference/propertyAndFunctionWithSameName.js +++ b/tests/baselines/reference/propertyAndFunctionWithSameName.js @@ -23,7 +23,6 @@ var C = (function () { var D = (function () { function D() { } - D.prototype.x = function (v) { - }; // error + D.prototype.x = function (v) { }; // error return D; })(); diff --git a/tests/baselines/reference/propertyOrdering.js b/tests/baselines/reference/propertyOrdering.js index 1dc930f93a..f0f4644a98 100644 --- a/tests/baselines/reference/propertyOrdering.js +++ b/tests/baselines/reference/propertyOrdering.js @@ -31,9 +31,7 @@ var Foo = (function () { Foo.prototype.foo = function () { return this._store.length; // shouldn't be an error }; - Foo.prototype.bar = function () { - return this.store; - }; // should be an error + Foo.prototype.bar = function () { return this.store; }; // should be an error return Foo; })(); var Bar = (function () { diff --git a/tests/baselines/reference/propertyWrappedInTry.js b/tests/baselines/reference/propertyWrappedInTry.js index 459e35f91a..e7f8a28d68 100644 --- a/tests/baselines/reference/propertyWrappedInTry.js +++ b/tests/baselines/reference/propertyWrappedInTry.js @@ -28,8 +28,7 @@ var Foo = (function () { try { bar = someInitThatMightFail(); } -catch (e) { -} +catch (e) { } baz(); { return this.bar; // doesn't get rewritten to Foo.bar. diff --git a/tests/baselines/reference/protectedClassPropertyAccessibleWithinClass.js b/tests/baselines/reference/protectedClassPropertyAccessibleWithinClass.js index 63c6929e8b..19ec9f50d2 100644 --- a/tests/baselines/reference/protectedClassPropertyAccessibleWithinClass.js +++ b/tests/baselines/reference/protectedClassPropertyAccessibleWithinClass.js @@ -37,34 +37,20 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "y", { - get: function () { - return this.x; - }, - set: function (x) { - this.y = this.x; - }, + get: function () { return this.x; }, + set: function (x) { this.y = this.x; }, enumerable: true, configurable: true }); - C.prototype.foo = function () { - return this.foo; - }; + C.prototype.foo = function () { return this.foo; }; Object.defineProperty(C, "y", { - get: function () { - return this.x; - }, - set: function (x) { - this.y = this.x; - }, + get: function () { return this.x; }, + set: function (x) { this.y = this.x; }, enumerable: true, configurable: true }); - C.foo = function () { - return this.foo; - }; - C.bar = function () { - this.foo(); - }; + C.foo = function () { return this.foo; }; + C.bar = function () { this.foo(); }; return C; })(); // added level of function nesting @@ -74,54 +60,40 @@ var C2 = (function () { Object.defineProperty(C2.prototype, "y", { get: function () { var _this = this; - (function () { - return _this.x; - }); + (function () { return _this.x; }); return null; }, set: function (x) { var _this = this; - (function () { - _this.y = _this.x; - }); + (function () { _this.y = _this.x; }); }, enumerable: true, configurable: true }); C2.prototype.foo = function () { var _this = this; - (function () { - return _this.foo; - }); + (function () { return _this.foo; }); }; Object.defineProperty(C2, "y", { get: function () { var _this = this; - (function () { - return _this.x; - }); + (function () { return _this.x; }); return null; }, set: function (x) { var _this = this; - (function () { - _this.y = _this.x; - }); + (function () { _this.y = _this.x; }); }, enumerable: true, configurable: true }); C2.foo = function () { var _this = this; - (function () { - return _this.foo; - }); + (function () { return _this.foo; }); }; C2.bar = function () { var _this = this; - (function () { - return _this.foo(); - }); + (function () { return _this.foo(); }); }; return C2; })(); diff --git a/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass.js b/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass.js index 381d10f43e..28a1da5ffe 100644 --- a/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass.js +++ b/tests/baselines/reference/protectedClassPropertyAccessibleWithinSubclass.js @@ -38,36 +38,20 @@ var C = (function (_super) { _super.apply(this, arguments); } Object.defineProperty(C.prototype, "y", { - get: function () { - return this.x; - }, - set: function (x) { - this.y = this.x; - }, + get: function () { return this.x; }, + set: function (x) { this.y = this.x; }, enumerable: true, configurable: true }); - C.prototype.foo = function () { - return this.x; - }; - C.prototype.bar = function () { - return this.foo(); - }; + C.prototype.foo = function () { return this.x; }; + C.prototype.bar = function () { return this.foo(); }; Object.defineProperty(C, "y", { - get: function () { - return this.x; - }, - set: function (x) { - this.y = this.x; - }, + get: function () { return this.x; }, + set: function (x) { this.y = this.x; }, enumerable: true, configurable: true }); - C.foo = function () { - return this.x; - }; - C.bar = function () { - this.foo(); - }; + C.foo = function () { return this.x; }; + C.bar = function () { this.foo(); }; return C; })(B); diff --git a/tests/baselines/reference/prototypes.js b/tests/baselines/reference/prototypes.js index 4ecdafb3dc..4d7ddc4a4d 100644 --- a/tests/baselines/reference/prototypes.js +++ b/tests/baselines/reference/prototypes.js @@ -7,6 +7,5 @@ f.prototype; //// [prototypes.js] Object.prototype; // ok new Object().prototype; // error -function f() { -} +function f() { } f.prototype; diff --git a/tests/baselines/reference/qualifiedModuleLocals.js b/tests/baselines/reference/qualifiedModuleLocals.js index 2909be7639..b7ba5b70e8 100644 --- a/tests/baselines/reference/qualifiedModuleLocals.js +++ b/tests/baselines/reference/qualifiedModuleLocals.js @@ -13,11 +13,8 @@ A.a(); //// [qualifiedModuleLocals.js] var A; (function (A) { - function b() { - } - function a() { - A.b(); - } + function b() { } + function a() { A.b(); } A.a = a; // A.b should be an unresolved symbol error })(A || (A = {})); A.a(); diff --git a/tests/baselines/reference/quotedAccessorName1.js b/tests/baselines/reference/quotedAccessorName1.js index 93fd5b8dd6..69e0fdb2c8 100644 --- a/tests/baselines/reference/quotedAccessorName1.js +++ b/tests/baselines/reference/quotedAccessorName1.js @@ -8,9 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "foo", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/quotedAccessorName2.js b/tests/baselines/reference/quotedAccessorName2.js index 43041a29bf..5d2d486155 100644 --- a/tests/baselines/reference/quotedAccessorName2.js +++ b/tests/baselines/reference/quotedAccessorName2.js @@ -8,9 +8,7 @@ var C = (function () { function C() { } Object.defineProperty(C, "foo", { - get: function () { - return 0; - }, + get: function () { return 0; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/quotedFunctionName1.js b/tests/baselines/reference/quotedFunctionName1.js index 28d7518647..69f4f2cfaa 100644 --- a/tests/baselines/reference/quotedFunctionName1.js +++ b/tests/baselines/reference/quotedFunctionName1.js @@ -7,7 +7,6 @@ class Test1 { var Test1 = (function () { function Test1() { } - Test1.prototype["prop1"] = function () { - }; + Test1.prototype["prop1"] = function () { }; return Test1; })(); diff --git a/tests/baselines/reference/quotedFunctionName2.js b/tests/baselines/reference/quotedFunctionName2.js index 46d8d9bae9..3173ec29f1 100644 --- a/tests/baselines/reference/quotedFunctionName2.js +++ b/tests/baselines/reference/quotedFunctionName2.js @@ -7,7 +7,6 @@ class Test1 { var Test1 = (function () { function Test1() { } - Test1["prop1"] = function () { - }; + Test1["prop1"] = function () { }; return Test1; })(); diff --git a/tests/baselines/reference/quotedPropertyName3.js b/tests/baselines/reference/quotedPropertyName3.js index 8e6342e1ba..4191418e42 100644 --- a/tests/baselines/reference/quotedPropertyName3.js +++ b/tests/baselines/reference/quotedPropertyName3.js @@ -13,9 +13,7 @@ var Test = (function () { } Test.prototype.foo = function () { var _this = this; - var x = function () { - return _this["prop1"]; - }; + var x = function () { return _this["prop1"]; }; var y = x(); }; return Test; diff --git a/tests/baselines/reference/rectype.js b/tests/baselines/reference/rectype.js index ed303b6b26..15c5d9861f 100644 --- a/tests/baselines/reference/rectype.js +++ b/tests/baselines/reference/rectype.js @@ -16,9 +16,7 @@ module M { //// [rectype.js] var M; (function (M) { - function f(p) { - return f; - } + function f(p) { return f; } M.f = f; ; var i; diff --git a/tests/baselines/reference/recur1.js b/tests/baselines/reference/recur1.js index 3dd0e14ad9..37a8b6eb3f 100644 --- a/tests/baselines/reference/recur1.js +++ b/tests/baselines/reference/recur1.js @@ -9,8 +9,6 @@ cobalt.pitch = function() {} //// [recur1.js] var salt = new salt.pepper(); -salt.pepper = function () { -}; +salt.pepper = function () { }; var cobalt = new cobalt.pitch(); -cobalt.pitch = function () { -}; +cobalt.pitch = function () { }; diff --git a/tests/baselines/reference/recursiveBaseConstructorCreation1.js b/tests/baselines/reference/recursiveBaseConstructorCreation1.js index 69a71a4f79..c475f604b1 100644 --- a/tests/baselines/reference/recursiveBaseConstructorCreation1.js +++ b/tests/baselines/reference/recursiveBaseConstructorCreation1.js @@ -16,8 +16,7 @@ var __extends = this.__extends || function (d, b) { var C1 = (function () { function C1() { } - C1.prototype.func = function (param) { - }; + C1.prototype.func = function (param) { }; return C1; })(); var C2 = (function (_super) { diff --git a/tests/baselines/reference/recursiveClassReferenceTest.js b/tests/baselines/reference/recursiveClassReferenceTest.js index 5f8be8bfdf..d47d9340a8 100644 --- a/tests/baselines/reference/recursiveClassReferenceTest.js +++ b/tests/baselines/reference/recursiveClassReferenceTest.js @@ -122,9 +122,7 @@ var Sample; var StartFindAction = (function () { function StartFindAction() { } - StartFindAction.prototype.getId = function () { - return "yo"; - }; + StartFindAction.prototype.getId = function () { return "yo"; }; StartFindAction.prototype.run = function (Thing) { return true; }; @@ -148,11 +146,9 @@ var Sample; // scenario 1 codeThing.addWidget("addWidget", this); } - FindWidget.prototype.gar = function (runner) { - if (true) { - return runner(this); - } - }; + FindWidget.prototype.gar = function (runner) { if (true) { + return runner(this); + } }; FindWidget.prototype.getDomNode = function () { return domNode; }; @@ -167,9 +163,7 @@ var Sample; var AbstractMode = (function () { function AbstractMode() { } - AbstractMode.prototype.getInitialState = function () { - return null; - }; + AbstractMode.prototype.getInitialState = function () { return null; }; return AbstractMode; })(); var Sample; @@ -190,9 +184,7 @@ var Sample; State.prototype.equals = function (other) { return this === other; }; - State.prototype.getMode = function () { - return mode; - }; + State.prototype.getMode = function () { return mode; }; return State; })(); PlainText.State = State; diff --git a/tests/baselines/reference/recursiveClassReferenceTest.js.map b/tests/baselines/reference/recursiveClassReferenceTest.js.map index acc518edac..5573bdd8de 100644 --- a/tests/baselines/reference/recursiveClassReferenceTest.js.map +++ b/tests/baselines/reference/recursiveClassReferenceTest.js.map @@ -1,2 +1,2 @@ //// [recursiveClassReferenceTest.js.map] -{"version":3,"file":"recursiveClassReferenceTest.js","sourceRoot":"","sources":["recursiveClassReferenceTest.ts"],"names":["Sample","Sample.Actions","Sample.Actions.Thing","Sample.Actions.Thing.Find","Sample.Actions.Thing.Find.StartFindAction","Sample.Actions.Thing.Find.StartFindAction.constructor","Sample.Actions.Thing.Find.StartFindAction.getId","Sample.Actions.Thing.Find.StartFindAction.run","Sample.Thing","Sample.Thing.Widgets","Sample.Thing.Widgets.FindWidget","Sample.Thing.Widgets.FindWidget.constructor","Sample.Thing.Widgets.FindWidget.gar","Sample.Thing.Widgets.FindWidget.getDomNode","Sample.Thing.Widgets.FindWidget.destroy","AbstractMode","AbstractMode.constructor","AbstractMode.getInitialState","Sample.Thing.Languages","Sample.Thing.Languages.PlainText","Sample.Thing.Languages.PlainText.State","Sample.Thing.Languages.PlainText.State.constructor","Sample.Thing.Languages.PlainText.State.clone","Sample.Thing.Languages.PlainText.State.equals","Sample.Thing.Languages.PlainText.State.getMode","Sample.Thing.Languages.PlainText.Mode","Sample.Thing.Languages.PlainText.Mode.constructor","Sample.Thing.Languages.PlainText.Mode.getInitialState"],"mappings":"AAAA,iEAAiE;AACjE,0EAA0E;;;;;;;AA8B1E,IAAO,MAAM,CAUZ;AAVD,WAAO,MAAM;IAACA,IAAAA,OAAOA,CAUpBA;IAVaA,WAAAA,OAAOA;QAACC,IAAAA,KAAKA,CAU1BA;QAVqBA,WAAAA,OAAKA;YAACC,IAAAA,IAAIA,CAU/BA;YAV2BA,WAAAA,IAAIA,EAACA,CAACA;gBACjCC;oBAAAC;oBAQAC,CAACA;oBANOD,+BAAKA,GAAZA;wBAAiBE,MAAMA,CAACA,IAAIA,CAACA;oBAACA,CAACA;oBAExBF,6BAAGA,GAAVA,UAAWA,KAA6BA;wBAEvCG,MAAMA,CAACA,IAAIA,CAACA;oBACbA,CAACA;oBACFH,sBAACA;gBAADA,CAACA,AARDD,IAQCA;gBARYA,oBAAeA,kBAQ3BA,CAAAA;YACFA,CAACA,EAV2BD,IAAIA,GAAJA,YAAIA,KAAJA,YAAIA,QAU/BA;QAADA,CAACA,EAVqBD,KAAKA,GAALA,aAAKA,KAALA,aAAKA,QAU1BA;IAADA,CAACA,EAVaD,OAAOA,GAAPA,cAAOA,KAAPA,cAAOA,QAUpBA;AAADA,CAACA,EAVM,MAAM,KAAN,MAAM,QAUZ;AAED,IAAO,MAAM,CAoBZ;AApBD,WAAO,MAAM;IAACA,IAAAA,KAAKA,CAoBlBA;IApBaA,WAAAA,KAAKA;QAACQ,IAAAA,OAAOA,CAoB1BA;QApBmBA,WAAAA,OAAOA,EAACA,CAACA;YAC5BC;gBAKCC,oBAAoBA,SAAkCA;oBAAlCC,cAASA,GAATA,SAASA,CAAyBA;oBAD9CA,YAAOA,GAAOA,IAAIA,CAACA;oBAGvBA,AADAA,aAAaA;oBACbA,SAASA,CAACA,SAASA,CAACA,WAAWA,EAAEA,IAAIA,CAACA,CAACA;gBAC3CA,CAACA;gBANMD,wBAAGA,GAAVA,UAAWA,MAAyCA;oBAAIE,EAAEA,CAACA,CAACA,IAAIA,CAACA,CAACA,CAACA;wBAAAA,MAAMA,CAACA,MAAMA,CAACA,IAAIA,CAACA,CAACA;oBAAAA,CAACA;gBAAAA,CAACA;gBAQlFF,+BAAUA,GAAjBA;oBACCG,MAAMA,CAACA,OAAOA,CAACA;gBAChBA,CAACA;gBAEMH,4BAAOA,GAAdA;gBAEAI,CAACA;gBAEFJ,iBAACA;YAADA,CAACA,AAlBDD,IAkBCA;YAlBYA,kBAAUA,aAkBtBA,CAAAA;QACFA,CAACA,EApBmBD,OAAOA,GAAPA,aAAOA,KAAPA,aAAOA,QAoB1BA;IAADA,CAACA,EApBaR,KAAKA,GAALA,YAAKA,KAALA,YAAKA,QAoBlBA;AAADA,CAACA,EApBM,MAAM,KAAN,MAAM,QAoBZ;AAGD;IAAAe;IAAuFC,CAACA;IAA3CD,sCAAeA,GAAtBA;QAAmCE,MAAMA,CAACA,IAAIA,CAACA;IAAAA,CAACA;IAACF,mBAACA;AAADA,CAACA,AAAxF,IAAwF;AASxF,IAAO,MAAM,CAwBZ;AAxBD,WAAO,MAAM;IAACf,IAAAA,KAAKA,CAwBlBA;IAxBaA,WAAAA,KAAKA;QAACQ,IAAAA,SAASA,CAwB5BA;QAxBmBA,WAAAA,SAASA;YAACU,IAAAA,SAASA,CAwBtCA;YAxB6BA,WAAAA,SAASA,EAACA,CAACA;gBAExCC;oBACOC,eAAoBA,IAAWA;wBAAXC,SAAIA,GAAJA,IAAIA,CAAOA;oBAAIA,CAACA;oBACnCD,qBAAKA,GAAZA;wBACCE,MAAMA,CAACA,IAAIA,CAACA;oBACbA,CAACA;oBAEMF,sBAAMA,GAAbA,UAAcA,KAAYA;wBACzBG,MAAMA,CAACA,IAAIA,KAAKA,KAAKA,CAACA;oBACvBA,CAACA;oBAEMH,uBAAOA,GAAdA;wBAA0BI,MAAMA,CAACA,IAAIA,CAACA;oBAACA,CAACA;oBACzCJ,YAACA;gBAADA,CAACA,AAXDD,IAWCA;gBAXYA,eAAKA,QAWjBA,CAAAA;gBAEDA;oBAA0BM,wBAAYA;oBAAtCA;wBAA0BC,8BAAYA;oBAQtCA,CAACA;oBANAD,aAAaA;oBACNA,8BAAeA,GAAtBA;wBACCE,MAAMA,CAACA,IAAIA,KAAKA,CAACA,IAAIA,CAACA,CAACA;oBACxBA,CAACA;oBAGFF,WAACA;gBAADA,CAACA,AARDN,EAA0BA,YAAYA,EAQrCA;gBARYA,cAAIA,OAQhBA,CAAAA;YACFA,CAACA,EAxB6BD,SAASA,GAATA,mBAASA,KAATA,mBAASA,QAwBtCA;QAADA,CAACA,EAxBmBV,SAASA,GAATA,eAASA,KAATA,eAASA,QAwB5BA;IAADA,CAACA,EAxBaR,KAAKA,GAALA,YAAKA,KAALA,YAAKA,QAwBlBA;AAADA,CAACA,EAxBM,MAAM,KAAN,MAAM,QAwBZ"} \ No newline at end of file +{"version":3,"file":"recursiveClassReferenceTest.js","sourceRoot":"","sources":["recursiveClassReferenceTest.ts"],"names":["Sample","Sample.Actions","Sample.Actions.Thing","Sample.Actions.Thing.Find","Sample.Actions.Thing.Find.StartFindAction","Sample.Actions.Thing.Find.StartFindAction.constructor","Sample.Actions.Thing.Find.StartFindAction.getId","Sample.Actions.Thing.Find.StartFindAction.run","Sample.Thing","Sample.Thing.Widgets","Sample.Thing.Widgets.FindWidget","Sample.Thing.Widgets.FindWidget.constructor","Sample.Thing.Widgets.FindWidget.gar","Sample.Thing.Widgets.FindWidget.getDomNode","Sample.Thing.Widgets.FindWidget.destroy","AbstractMode","AbstractMode.constructor","AbstractMode.getInitialState","Sample.Thing.Languages","Sample.Thing.Languages.PlainText","Sample.Thing.Languages.PlainText.State","Sample.Thing.Languages.PlainText.State.constructor","Sample.Thing.Languages.PlainText.State.clone","Sample.Thing.Languages.PlainText.State.equals","Sample.Thing.Languages.PlainText.State.getMode","Sample.Thing.Languages.PlainText.Mode","Sample.Thing.Languages.PlainText.Mode.constructor","Sample.Thing.Languages.PlainText.Mode.getInitialState"],"mappings":"AAAA,iEAAiE;AACjE,0EAA0E;;;;;;;AA8B1E,IAAO,MAAM,CAUZ;AAVD,WAAO,MAAM;IAACA,IAAAA,OAAOA,CAUpBA;IAVaA,WAAAA,OAAOA;QAACC,IAAAA,KAAKA,CAU1BA;QAVqBA,WAAAA,OAAKA;YAACC,IAAAA,IAAIA,CAU/BA;YAV2BA,WAAAA,IAAIA,EAACA,CAACA;gBACjCC;oBAAAC;oBAQAC,CAACA;oBANOD,+BAAKA,GAAZA,cAAiBE,MAAMA,CAACA,IAAIA,CAACA,CAACA,CAACA;oBAExBF,6BAAGA,GAAVA,UAAWA,KAA6BA;wBAEvCG,MAAMA,CAACA,IAAIA,CAACA;oBACbA,CAACA;oBACFH,sBAACA;gBAADA,CAACA,AARDD,IAQCA;gBARYA,oBAAeA,kBAQ3BA,CAAAA;YACFA,CAACA,EAV2BD,IAAIA,GAAJA,YAAIA,KAAJA,YAAIA,QAU/BA;QAADA,CAACA,EAVqBD,KAAKA,GAALA,aAAKA,KAALA,aAAKA,QAU1BA;IAADA,CAACA,EAVaD,OAAOA,GAAPA,cAAOA,KAAPA,cAAOA,QAUpBA;AAADA,CAACA,EAVM,MAAM,KAAN,MAAM,QAUZ;AAED,IAAO,MAAM,CAoBZ;AApBD,WAAO,MAAM;IAACA,IAAAA,KAAKA,CAoBlBA;IApBaA,WAAAA,KAAKA;QAACQ,IAAAA,OAAOA,CAoB1BA;QApBmBA,WAAAA,OAAOA,EAACA,CAACA;YAC5BC;gBAKCC,oBAAoBA,SAAkCA;oBAAlCC,cAASA,GAATA,SAASA,CAAyBA;oBAD9CA,YAAOA,GAAOA,IAAIA,CAACA;oBAGvBA,AADAA,aAAaA;oBACbA,SAASA,CAACA,SAASA,CAACA,WAAWA,EAAEA,IAAIA,CAACA,CAACA;gBAC3CA,CAACA;gBANMD,wBAAGA,GAAVA,UAAWA,MAAyCA,IAAIE,EAAEA,CAACA,CAACA,IAAIA,CAACA,CAACA,CAACA;oBAAAA,MAAMA,CAACA,MAAMA,CAACA,IAAIA,CAACA,CAACA;gBAAAA,CAACA,CAAAA,CAACA;gBAQlFF,+BAAUA,GAAjBA;oBACCG,MAAMA,CAACA,OAAOA,CAACA;gBAChBA,CAACA;gBAEMH,4BAAOA,GAAdA;gBAEAI,CAACA;gBAEFJ,iBAACA;YAADA,CAACA,AAlBDD,IAkBCA;YAlBYA,kBAAUA,aAkBtBA,CAAAA;QACFA,CAACA,EApBmBD,OAAOA,GAAPA,aAAOA,KAAPA,aAAOA,QAoB1BA;IAADA,CAACA,EApBaR,KAAKA,GAALA,YAAKA,KAALA,YAAKA,QAoBlBA;AAADA,CAACA,EApBM,MAAM,KAAN,MAAM,QAoBZ;AAGD;IAAAe;IAAuFC,CAACA;IAA3CD,sCAAeA,GAAtBA,cAAmCE,MAAMA,CAACA,IAAIA,CAACA,CAAAA,CAACA;IAACF,mBAACA;AAADA,CAACA,AAAxF,IAAwF;AASxF,IAAO,MAAM,CAwBZ;AAxBD,WAAO,MAAM;IAACf,IAAAA,KAAKA,CAwBlBA;IAxBaA,WAAAA,KAAKA;QAACQ,IAAAA,SAASA,CAwB5BA;QAxBmBA,WAAAA,SAASA;YAACU,IAAAA,SAASA,CAwBtCA;YAxB6BA,WAAAA,SAASA,EAACA,CAACA;gBAExCC;oBACOC,eAAoBA,IAAWA;wBAAXC,SAAIA,GAAJA,IAAIA,CAAOA;oBAAIA,CAACA;oBACnCD,qBAAKA,GAAZA;wBACCE,MAAMA,CAACA,IAAIA,CAACA;oBACbA,CAACA;oBAEMF,sBAAMA,GAAbA,UAAcA,KAAYA;wBACzBG,MAAMA,CAACA,IAAIA,KAAKA,KAAKA,CAACA;oBACvBA,CAACA;oBAEMH,uBAAOA,GAAdA,cAA0BI,MAAMA,CAACA,IAAIA,CAACA,CAACA,CAACA;oBACzCJ,YAACA;gBAADA,CAACA,AAXDD,IAWCA;gBAXYA,eAAKA,QAWjBA,CAAAA;gBAEDA;oBAA0BM,wBAAYA;oBAAtCA;wBAA0BC,8BAAYA;oBAQtCA,CAACA;oBANAD,aAAaA;oBACNA,8BAAeA,GAAtBA;wBACCE,MAAMA,CAACA,IAAIA,KAAKA,CAACA,IAAIA,CAACA,CAACA;oBACxBA,CAACA;oBAGFF,WAACA;gBAADA,CAACA,AARDN,EAA0BA,YAAYA,EAQrCA;gBARYA,cAAIA,OAQhBA,CAAAA;YACFA,CAACA,EAxB6BD,SAASA,GAATA,mBAASA,KAATA,mBAASA,QAwBtCA;QAADA,CAACA,EAxBmBV,SAASA,GAATA,eAASA,KAATA,eAASA,QAwB5BA;IAADA,CAACA,EAxBaR,KAAKA,GAALA,YAAKA,KAALA,YAAKA,QAwBlBA;AAADA,CAACA,EAxBM,MAAM,KAAN,MAAM,QAwBZ"} \ No newline at end of file diff --git a/tests/baselines/reference/recursiveClassReferenceTest.sourcemap.txt b/tests/baselines/reference/recursiveClassReferenceTest.sourcemap.txt index 7e1295d630..23950aba4b 100644 --- a/tests/baselines/reference/recursiveClassReferenceTest.sourcemap.txt +++ b/tests/baselines/reference/recursiveClassReferenceTest.sourcemap.txt @@ -229,7 +229,7 @@ sourceFile:recursiveClassReferenceTest.ts >>> } 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1->export class StartFindAction implements Sample.Thing.IAction { > > public getId() { return "yo"; } @@ -243,61 +243,56 @@ sourceFile:recursiveClassReferenceTest.ts 1->Emitted(19, 21) Source(41, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.constructor) 2 >Emitted(19, 22) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.constructor) --- ->>> StartFindAction.prototype.getId = function () { +>>> StartFindAction.prototype.getId = function () { return "yo"; }; 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ +4 > ^^^^^^^^^^^^^^ +5 > ^^^^^^ +6 > ^ +7 > ^^^^ +8 > ^ +9 > ^ +10> ^ 1-> 2 > getId 3 > +4 > public getId() { +5 > return +6 > +7 > "yo" +8 > ; +9 > +10> } 1->Emitted(20, 21) Source(35, 10) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) 2 >Emitted(20, 52) Source(35, 15) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) 3 >Emitted(20, 55) Source(35, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) ---- ->>> return "yo"; -1 >^^^^^^^^^^^^^^^^^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^^^^ -5 > ^ -1 >public getId() { -2 > return -3 > -4 > "yo" -5 > ; -1 >Emitted(21, 25) Source(35, 20) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) -2 >Emitted(21, 31) Source(35, 26) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) -3 >Emitted(21, 32) Source(35, 27) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) -4 >Emitted(21, 36) Source(35, 31) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) -5 >Emitted(21, 37) Source(35, 32) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) ---- ->>> }; -1 >^^^^^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 > } -1 >Emitted(22, 21) Source(35, 33) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) -2 >Emitted(22, 22) Source(35, 34) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) +4 >Emitted(20, 69) Source(35, 20) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) +5 >Emitted(20, 75) Source(35, 26) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) +6 >Emitted(20, 76) Source(35, 27) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) +7 >Emitted(20, 80) Source(35, 31) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) +8 >Emitted(20, 81) Source(35, 32) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) +9 >Emitted(20, 82) Source(35, 33) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) +10>Emitted(20, 83) Source(35, 34) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.getId) --- >>> StartFindAction.prototype.run = function (Thing) { -1->^^^^^^^^^^^^^^^^^^^^ +1 >^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ 4 > ^^^^^^^^^^ 5 > ^^^^^ -1-> +1 > > > public 2 > run 3 > 4 > public run( 5 > Thing:Sample.Thing.ICodeThing -1->Emitted(23, 21) Source(37, 10) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) -2 >Emitted(23, 50) Source(37, 13) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) -3 >Emitted(23, 53) Source(37, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) -4 >Emitted(23, 63) Source(37, 14) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) -5 >Emitted(23, 68) Source(37, 43) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +1 >Emitted(21, 21) Source(37, 10) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +2 >Emitted(21, 50) Source(37, 13) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +3 >Emitted(21, 53) Source(37, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +4 >Emitted(21, 63) Source(37, 14) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +5 >Emitted(21, 68) Source(37, 43) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) --- >>> return true; 1 >^^^^^^^^^^^^^^^^^^^^^^^^ @@ -312,11 +307,11 @@ sourceFile:recursiveClassReferenceTest.ts 3 > 4 > true 5 > ; -1 >Emitted(24, 25) Source(39, 4) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) -2 >Emitted(24, 31) Source(39, 10) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) -3 >Emitted(24, 32) Source(39, 11) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) -4 >Emitted(24, 36) Source(39, 15) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) -5 >Emitted(24, 37) Source(39, 16) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) +1 >Emitted(22, 25) Source(39, 4) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) +2 >Emitted(22, 31) Source(39, 10) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) +3 >Emitted(22, 32) Source(39, 11) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) +4 >Emitted(22, 36) Source(39, 15) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) +5 >Emitted(22, 37) Source(39, 16) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) --- >>> }; 1 >^^^^^^^^^^^^^^^^^^^^ @@ -325,8 +320,8 @@ sourceFile:recursiveClassReferenceTest.ts 1 > > 2 > } -1 >Emitted(25, 21) Source(40, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) -2 >Emitted(25, 22) Source(40, 4) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) +1 >Emitted(23, 21) Source(40, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) +2 >Emitted(23, 22) Source(40, 4) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction.run) --- >>> return StartFindAction; 1->^^^^^^^^^^^^^^^^^^^^ @@ -334,8 +329,8 @@ sourceFile:recursiveClassReferenceTest.ts 1-> > 2 > } -1->Emitted(26, 21) Source(41, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) -2 >Emitted(26, 43) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +1->Emitted(24, 21) Source(41, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +2 >Emitted(24, 43) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) --- >>> })(); 1 >^^^^^^^^^^^^^^^^ @@ -355,10 +350,10 @@ sourceFile:recursiveClassReferenceTest.ts > return true; > } > } -1 >Emitted(27, 17) Source(41, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) -2 >Emitted(27, 18) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) -3 >Emitted(27, 18) Source(33, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find) -4 >Emitted(27, 22) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find) +1 >Emitted(25, 17) Source(41, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +2 >Emitted(25, 18) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find.StartFindAction) +3 >Emitted(25, 18) Source(33, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find) +4 >Emitted(25, 22) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find) --- >>> Find.StartFindAction = StartFindAction; 1->^^^^^^^^^^^^^^^^ @@ -378,10 +373,10 @@ sourceFile:recursiveClassReferenceTest.ts > } > } 4 > -1->Emitted(28, 17) Source(33, 15) + SourceIndex(0) name (Sample.Actions.Thing.Find) -2 >Emitted(28, 37) Source(33, 30) + SourceIndex(0) name (Sample.Actions.Thing.Find) -3 >Emitted(28, 55) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find) -4 >Emitted(28, 56) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find) +1->Emitted(26, 17) Source(33, 15) + SourceIndex(0) name (Sample.Actions.Thing.Find) +2 >Emitted(26, 37) Source(33, 30) + SourceIndex(0) name (Sample.Actions.Thing.Find) +3 >Emitted(26, 55) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find) +4 >Emitted(26, 56) Source(41, 3) + SourceIndex(0) name (Sample.Actions.Thing.Find) --- >>> })(Find = Thing_1.Find || (Thing_1.Find = {})); 1->^^^^^^^^^^^^ @@ -413,15 +408,15 @@ sourceFile:recursiveClassReferenceTest.ts > } > } > } -1->Emitted(29, 13) Source(42, 1) + SourceIndex(0) name (Sample.Actions.Thing.Find) -2 >Emitted(29, 14) Source(42, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find) -3 >Emitted(29, 16) Source(32, 29) + SourceIndex(0) name (Sample.Actions.Thing) -4 >Emitted(29, 20) Source(32, 33) + SourceIndex(0) name (Sample.Actions.Thing) -5 >Emitted(29, 23) Source(32, 29) + SourceIndex(0) name (Sample.Actions.Thing) -6 >Emitted(29, 35) Source(32, 33) + SourceIndex(0) name (Sample.Actions.Thing) -7 >Emitted(29, 40) Source(32, 29) + SourceIndex(0) name (Sample.Actions.Thing) -8 >Emitted(29, 52) Source(32, 33) + SourceIndex(0) name (Sample.Actions.Thing) -9 >Emitted(29, 60) Source(42, 2) + SourceIndex(0) name (Sample.Actions.Thing) +1->Emitted(27, 13) Source(42, 1) + SourceIndex(0) name (Sample.Actions.Thing.Find) +2 >Emitted(27, 14) Source(42, 2) + SourceIndex(0) name (Sample.Actions.Thing.Find) +3 >Emitted(27, 16) Source(32, 29) + SourceIndex(0) name (Sample.Actions.Thing) +4 >Emitted(27, 20) Source(32, 33) + SourceIndex(0) name (Sample.Actions.Thing) +5 >Emitted(27, 23) Source(32, 29) + SourceIndex(0) name (Sample.Actions.Thing) +6 >Emitted(27, 35) Source(32, 33) + SourceIndex(0) name (Sample.Actions.Thing) +7 >Emitted(27, 40) Source(32, 29) + SourceIndex(0) name (Sample.Actions.Thing) +8 >Emitted(27, 52) Source(32, 33) + SourceIndex(0) name (Sample.Actions.Thing) +9 >Emitted(27, 60) Source(42, 2) + SourceIndex(0) name (Sample.Actions.Thing) --- >>> })(Thing = Actions.Thing || (Actions.Thing = {})); 1 >^^^^^^^^ @@ -453,15 +448,15 @@ sourceFile:recursiveClassReferenceTest.ts > } > } > } -1 >Emitted(30, 9) Source(42, 1) + SourceIndex(0) name (Sample.Actions.Thing) -2 >Emitted(30, 10) Source(42, 2) + SourceIndex(0) name (Sample.Actions.Thing) -3 >Emitted(30, 12) Source(32, 23) + SourceIndex(0) name (Sample.Actions) -4 >Emitted(30, 17) Source(32, 28) + SourceIndex(0) name (Sample.Actions) -5 >Emitted(30, 20) Source(32, 23) + SourceIndex(0) name (Sample.Actions) -6 >Emitted(30, 33) Source(32, 28) + SourceIndex(0) name (Sample.Actions) -7 >Emitted(30, 38) Source(32, 23) + SourceIndex(0) name (Sample.Actions) -8 >Emitted(30, 51) Source(32, 28) + SourceIndex(0) name (Sample.Actions) -9 >Emitted(30, 59) Source(42, 2) + SourceIndex(0) name (Sample.Actions) +1 >Emitted(28, 9) Source(42, 1) + SourceIndex(0) name (Sample.Actions.Thing) +2 >Emitted(28, 10) Source(42, 2) + SourceIndex(0) name (Sample.Actions.Thing) +3 >Emitted(28, 12) Source(32, 23) + SourceIndex(0) name (Sample.Actions) +4 >Emitted(28, 17) Source(32, 28) + SourceIndex(0) name (Sample.Actions) +5 >Emitted(28, 20) Source(32, 23) + SourceIndex(0) name (Sample.Actions) +6 >Emitted(28, 33) Source(32, 28) + SourceIndex(0) name (Sample.Actions) +7 >Emitted(28, 38) Source(32, 23) + SourceIndex(0) name (Sample.Actions) +8 >Emitted(28, 51) Source(32, 28) + SourceIndex(0) name (Sample.Actions) +9 >Emitted(28, 59) Source(42, 2) + SourceIndex(0) name (Sample.Actions) --- >>> })(Actions = Sample.Actions || (Sample.Actions = {})); 1->^^^^ @@ -492,15 +487,15 @@ sourceFile:recursiveClassReferenceTest.ts > } > } > } -1->Emitted(31, 5) Source(42, 1) + SourceIndex(0) name (Sample.Actions) -2 >Emitted(31, 6) Source(42, 2) + SourceIndex(0) name (Sample.Actions) -3 >Emitted(31, 8) Source(32, 15) + SourceIndex(0) name (Sample) -4 >Emitted(31, 15) Source(32, 22) + SourceIndex(0) name (Sample) -5 >Emitted(31, 18) Source(32, 15) + SourceIndex(0) name (Sample) -6 >Emitted(31, 32) Source(32, 22) + SourceIndex(0) name (Sample) -7 >Emitted(31, 37) Source(32, 15) + SourceIndex(0) name (Sample) -8 >Emitted(31, 51) Source(32, 22) + SourceIndex(0) name (Sample) -9 >Emitted(31, 59) Source(42, 2) + SourceIndex(0) name (Sample) +1->Emitted(29, 5) Source(42, 1) + SourceIndex(0) name (Sample.Actions) +2 >Emitted(29, 6) Source(42, 2) + SourceIndex(0) name (Sample.Actions) +3 >Emitted(29, 8) Source(32, 15) + SourceIndex(0) name (Sample) +4 >Emitted(29, 15) Source(32, 22) + SourceIndex(0) name (Sample) +5 >Emitted(29, 18) Source(32, 15) + SourceIndex(0) name (Sample) +6 >Emitted(29, 32) Source(32, 22) + SourceIndex(0) name (Sample) +7 >Emitted(29, 37) Source(32, 15) + SourceIndex(0) name (Sample) +8 >Emitted(29, 51) Source(32, 22) + SourceIndex(0) name (Sample) +9 >Emitted(29, 59) Source(42, 2) + SourceIndex(0) name (Sample) --- >>>})(Sample || (Sample = {})); 1 > @@ -527,13 +522,13 @@ sourceFile:recursiveClassReferenceTest.ts > } > } > } -1 >Emitted(32, 1) Source(42, 1) + SourceIndex(0) name (Sample) -2 >Emitted(32, 2) Source(42, 2) + SourceIndex(0) name (Sample) -3 >Emitted(32, 4) Source(32, 8) + SourceIndex(0) -4 >Emitted(32, 10) Source(32, 14) + SourceIndex(0) -5 >Emitted(32, 15) Source(32, 8) + SourceIndex(0) -6 >Emitted(32, 21) Source(32, 14) + SourceIndex(0) -7 >Emitted(32, 29) Source(42, 2) + SourceIndex(0) +1 >Emitted(30, 1) Source(42, 1) + SourceIndex(0) name (Sample) +2 >Emitted(30, 2) Source(42, 2) + SourceIndex(0) name (Sample) +3 >Emitted(30, 4) Source(32, 8) + SourceIndex(0) +4 >Emitted(30, 10) Source(32, 14) + SourceIndex(0) +5 >Emitted(30, 15) Source(32, 8) + SourceIndex(0) +6 >Emitted(30, 21) Source(32, 14) + SourceIndex(0) +7 >Emitted(30, 29) Source(42, 2) + SourceIndex(0) --- >>>var Sample; 1 > @@ -567,10 +562,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(33, 1) Source(44, 1) + SourceIndex(0) -2 >Emitted(33, 5) Source(44, 8) + SourceIndex(0) -3 >Emitted(33, 11) Source(44, 14) + SourceIndex(0) -4 >Emitted(33, 12) Source(64, 2) + SourceIndex(0) +1 >Emitted(31, 1) Source(44, 1) + SourceIndex(0) +2 >Emitted(31, 5) Source(44, 8) + SourceIndex(0) +3 >Emitted(31, 11) Source(44, 14) + SourceIndex(0) +4 >Emitted(31, 12) Source(64, 2) + SourceIndex(0) --- >>>(function (Sample) { 1-> @@ -579,9 +574,9 @@ sourceFile:recursiveClassReferenceTest.ts 1-> 2 >module 3 > Sample -1->Emitted(34, 1) Source(44, 1) + SourceIndex(0) -2 >Emitted(34, 12) Source(44, 8) + SourceIndex(0) -3 >Emitted(34, 18) Source(44, 14) + SourceIndex(0) +1->Emitted(32, 1) Source(44, 1) + SourceIndex(0) +2 >Emitted(32, 12) Source(44, 8) + SourceIndex(0) +3 >Emitted(32, 18) Source(44, 14) + SourceIndex(0) --- >>> var Thing; 1 >^^^^ @@ -613,10 +608,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(35, 5) Source(44, 15) + SourceIndex(0) name (Sample) -2 >Emitted(35, 9) Source(44, 15) + SourceIndex(0) name (Sample) -3 >Emitted(35, 14) Source(44, 20) + SourceIndex(0) name (Sample) -4 >Emitted(35, 15) Source(64, 2) + SourceIndex(0) name (Sample) +1 >Emitted(33, 5) Source(44, 15) + SourceIndex(0) name (Sample) +2 >Emitted(33, 9) Source(44, 15) + SourceIndex(0) name (Sample) +3 >Emitted(33, 14) Source(44, 20) + SourceIndex(0) name (Sample) +4 >Emitted(33, 15) Source(64, 2) + SourceIndex(0) name (Sample) --- >>> (function (Thing) { 1->^^^^ @@ -626,9 +621,9 @@ sourceFile:recursiveClassReferenceTest.ts 1-> 2 > 3 > Thing -1->Emitted(36, 5) Source(44, 15) + SourceIndex(0) name (Sample) -2 >Emitted(36, 16) Source(44, 15) + SourceIndex(0) name (Sample) -3 >Emitted(36, 21) Source(44, 20) + SourceIndex(0) name (Sample) +1->Emitted(34, 5) Source(44, 15) + SourceIndex(0) name (Sample) +2 >Emitted(34, 16) Source(44, 15) + SourceIndex(0) name (Sample) +3 >Emitted(34, 21) Source(44, 20) + SourceIndex(0) name (Sample) --- >>> var Widgets; 1->^^^^^^^^ @@ -660,10 +655,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1->Emitted(37, 9) Source(44, 21) + SourceIndex(0) name (Sample.Thing) -2 >Emitted(37, 13) Source(44, 21) + SourceIndex(0) name (Sample.Thing) -3 >Emitted(37, 20) Source(44, 28) + SourceIndex(0) name (Sample.Thing) -4 >Emitted(37, 21) Source(64, 2) + SourceIndex(0) name (Sample.Thing) +1->Emitted(35, 9) Source(44, 21) + SourceIndex(0) name (Sample.Thing) +2 >Emitted(35, 13) Source(44, 21) + SourceIndex(0) name (Sample.Thing) +3 >Emitted(35, 20) Source(44, 28) + SourceIndex(0) name (Sample.Thing) +4 >Emitted(35, 21) Source(64, 2) + SourceIndex(0) name (Sample.Thing) --- >>> (function (Widgets) { 1->^^^^^^^^ @@ -677,18 +672,18 @@ sourceFile:recursiveClassReferenceTest.ts 3 > Widgets 4 > 5 > { -1->Emitted(38, 9) Source(44, 21) + SourceIndex(0) name (Sample.Thing) -2 >Emitted(38, 20) Source(44, 21) + SourceIndex(0) name (Sample.Thing) -3 >Emitted(38, 27) Source(44, 28) + SourceIndex(0) name (Sample.Thing) -4 >Emitted(38, 29) Source(44, 29) + SourceIndex(0) name (Sample.Thing) -5 >Emitted(38, 30) Source(44, 30) + SourceIndex(0) name (Sample.Thing) +1->Emitted(36, 9) Source(44, 21) + SourceIndex(0) name (Sample.Thing) +2 >Emitted(36, 20) Source(44, 21) + SourceIndex(0) name (Sample.Thing) +3 >Emitted(36, 27) Source(44, 28) + SourceIndex(0) name (Sample.Thing) +4 >Emitted(36, 29) Source(44, 29) + SourceIndex(0) name (Sample.Thing) +5 >Emitted(36, 30) Source(44, 30) + SourceIndex(0) name (Sample.Thing) --- >>> var FindWidget = (function () { 1->^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > -1->Emitted(39, 13) Source(45, 2) + SourceIndex(0) name (Sample.Thing.Widgets) +1->Emitted(37, 13) Source(45, 2) + SourceIndex(0) name (Sample.Thing.Widgets) --- >>> function FindWidget(codeThing) { 1->^^^^^^^^^^^^^^^^ @@ -703,9 +698,9 @@ sourceFile:recursiveClassReferenceTest.ts > 2 > constructor(private 3 > codeThing: Sample.Thing.ICodeThing -1->Emitted(40, 17) Source(50, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -2 >Emitted(40, 37) Source(50, 23) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -3 >Emitted(40, 46) Source(50, 57) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +1->Emitted(38, 17) Source(50, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +2 >Emitted(38, 37) Source(50, 23) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +3 >Emitted(38, 46) Source(50, 57) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) --- >>> this.codeThing = codeThing; 1->^^^^^^^^^^^^^^^^^^^^ @@ -718,11 +713,11 @@ sourceFile:recursiveClassReferenceTest.ts 3 > 4 > codeThing 5 > : Sample.Thing.ICodeThing -1->Emitted(41, 21) Source(50, 23) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -2 >Emitted(41, 35) Source(50, 32) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -3 >Emitted(41, 38) Source(50, 23) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -4 >Emitted(41, 47) Source(50, 32) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -5 >Emitted(41, 48) Source(50, 57) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +1->Emitted(39, 21) Source(50, 23) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +2 >Emitted(39, 35) Source(50, 32) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +3 >Emitted(39, 38) Source(50, 23) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +4 >Emitted(39, 47) Source(50, 32) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +5 >Emitted(39, 48) Source(50, 57) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) --- >>> this.domNode = null; 1 >^^^^^^^^^^^^^^^^^^^^ @@ -735,11 +730,11 @@ sourceFile:recursiveClassReferenceTest.ts 3 > :any = 4 > null 5 > ; -1 >Emitted(42, 21) Source(49, 11) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -2 >Emitted(42, 33) Source(49, 18) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -3 >Emitted(42, 36) Source(49, 25) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -4 >Emitted(42, 40) Source(49, 29) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -5 >Emitted(42, 41) Source(49, 30) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +1 >Emitted(40, 21) Source(49, 11) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +2 >Emitted(40, 33) Source(49, 18) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +3 >Emitted(40, 36) Source(49, 25) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +4 >Emitted(40, 40) Source(49, 29) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +5 >Emitted(40, 41) Source(49, 30) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) --- >>> // scenario 1 1 >^^^^^^^^^^^^^^^^^^^^ @@ -752,9 +747,9 @@ sourceFile:recursiveClassReferenceTest.ts > 2 > 3 > // scenario 1 -1 >Emitted(43, 21) Source(52, 7) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -2 >Emitted(43, 21) Source(51, 7) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -3 >Emitted(43, 34) Source(51, 20) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +1 >Emitted(41, 21) Source(52, 7) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +2 >Emitted(41, 21) Source(51, 7) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +3 >Emitted(41, 34) Source(51, 20) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) --- >>> codeThing.addWidget("addWidget", this); 1->^^^^^^^^^^^^^^^^^^^^ @@ -778,113 +773,108 @@ sourceFile:recursiveClassReferenceTest.ts 8 > this 9 > ) 10> ; -1->Emitted(44, 21) Source(52, 7) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -2 >Emitted(44, 30) Source(52, 16) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -3 >Emitted(44, 31) Source(52, 17) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -4 >Emitted(44, 40) Source(52, 26) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -5 >Emitted(44, 41) Source(52, 27) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -6 >Emitted(44, 52) Source(52, 38) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -7 >Emitted(44, 54) Source(52, 40) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -8 >Emitted(44, 58) Source(52, 44) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -9 >Emitted(44, 59) Source(52, 45) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -10>Emitted(44, 60) Source(52, 46) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +1->Emitted(42, 21) Source(52, 7) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +2 >Emitted(42, 30) Source(52, 16) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +3 >Emitted(42, 31) Source(52, 17) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +4 >Emitted(42, 40) Source(52, 26) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +5 >Emitted(42, 41) Source(52, 27) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +6 >Emitted(42, 52) Source(52, 38) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +7 >Emitted(42, 54) Source(52, 40) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +8 >Emitted(42, 58) Source(52, 44) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +9 >Emitted(42, 59) Source(52, 45) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +10>Emitted(42, 60) Source(52, 46) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) --- >>> } 1 >^^^^^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > > 2 > } -1 >Emitted(45, 17) Source(53, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) -2 >Emitted(45, 18) Source(53, 4) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +1 >Emitted(43, 17) Source(53, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) +2 >Emitted(43, 18) Source(53, 4) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.constructor) --- ->>> FindWidget.prototype.gar = function (runner) { +>>> FindWidget.prototype.gar = function (runner) { if (true) { 1->^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ 4 > ^^^^^^^^^^ 5 > ^^^^^^ +6 > ^^^^ +7 > ^^ +8 > ^ +9 > ^ +10> ^^^^ +11> ^ +12> ^ +13> ^ 1-> 2 > gar 3 > 4 > public gar( 5 > runner:(widget:Sample.Thing.IWidget)=>any -1->Emitted(46, 17) Source(47, 10) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -2 >Emitted(46, 41) Source(47, 13) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -3 >Emitted(46, 44) Source(47, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -4 >Emitted(46, 54) Source(47, 14) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -5 >Emitted(46, 60) Source(47, 55) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +6 > ) { +7 > if +8 > +9 > ( +10> true +11> ) +12> +13> { +1->Emitted(44, 17) Source(47, 10) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +2 >Emitted(44, 41) Source(47, 13) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +3 >Emitted(44, 44) Source(47, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +4 >Emitted(44, 54) Source(47, 14) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +5 >Emitted(44, 60) Source(47, 55) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +6 >Emitted(44, 64) Source(47, 59) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +7 >Emitted(44, 66) Source(47, 61) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +8 >Emitted(44, 67) Source(47, 62) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +9 >Emitted(44, 68) Source(47, 63) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +10>Emitted(44, 72) Source(47, 67) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +11>Emitted(44, 73) Source(47, 68) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +12>Emitted(44, 74) Source(47, 69) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +13>Emitted(44, 75) Source(47, 70) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) --- ->>> if (true) { +>>> return runner(this); 1 >^^^^^^^^^^^^^^^^^^^^ -2 > ^^ -3 > ^ -4 > ^ -5 > ^^^^ -6 > ^ -7 > ^ -8 > ^ -9 > ^^^^^^^^^^^^^^-> -1 >) { -2 > if -3 > -4 > ( -5 > true -6 > ) -7 > -8 > { -1 >Emitted(47, 21) Source(47, 59) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -2 >Emitted(47, 23) Source(47, 61) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -3 >Emitted(47, 24) Source(47, 62) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -4 >Emitted(47, 25) Source(47, 63) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -5 >Emitted(47, 29) Source(47, 67) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -6 >Emitted(47, 30) Source(47, 68) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -7 >Emitted(47, 31) Source(47, 69) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -8 >Emitted(47, 32) Source(47, 70) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) ---- ->>> return runner(this); -1->^^^^^^^^^^^^^^^^^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^^^^^^ -5 > ^ -6 > ^^^^ -7 > ^ -8 > ^ -1-> -2 > return -3 > -4 > runner -5 > ( -6 > this -7 > ) -8 > ; -1->Emitted(48, 25) Source(47, 70) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -2 >Emitted(48, 31) Source(47, 76) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -3 >Emitted(48, 32) Source(47, 77) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -4 >Emitted(48, 38) Source(47, 83) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -5 >Emitted(48, 39) Source(47, 84) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -6 >Emitted(48, 43) Source(47, 88) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -7 >Emitted(48, 44) Source(47, 89) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -8 >Emitted(48, 45) Source(47, 90) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) ---- ->>> } -1 >^^^^^^^^^^^^^^^^^^^^ -2 > ^ +2 > ^^^^^^ +3 > ^ +4 > ^^^^^^ +5 > ^ +6 > ^^^^ +7 > ^ +8 > ^ 1 > -2 > } -1 >Emitted(49, 21) Source(47, 90) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -2 >Emitted(49, 22) Source(47, 91) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +2 > return +3 > +4 > runner +5 > ( +6 > this +7 > ) +8 > ; +1 >Emitted(45, 21) Source(47, 70) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +2 >Emitted(45, 27) Source(47, 76) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +3 >Emitted(45, 28) Source(47, 77) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +4 >Emitted(45, 34) Source(47, 83) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +5 >Emitted(45, 35) Source(47, 84) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +6 >Emitted(45, 39) Source(47, 88) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +7 >Emitted(45, 40) Source(47, 89) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +8 >Emitted(45, 41) Source(47, 90) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) --- ->>> }; +>>> } }; 1 >^^^^^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^ +4 > ^ +5 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > 2 > } -1 >Emitted(50, 17) Source(47, 91) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) -2 >Emitted(50, 18) Source(47, 92) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +3 > +4 > } +1 >Emitted(46, 17) Source(47, 90) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +2 >Emitted(46, 18) Source(47, 91) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +3 >Emitted(46, 19) Source(47, 91) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) +4 >Emitted(46, 20) Source(47, 92) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.gar) --- >>> FindWidget.prototype.getDomNode = function () { 1->^^^^^^^^^^^^^^^^ @@ -901,9 +891,9 @@ sourceFile:recursiveClassReferenceTest.ts > public 2 > getDomNode 3 > -1->Emitted(51, 17) Source(55, 10) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -2 >Emitted(51, 48) Source(55, 20) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -3 >Emitted(51, 51) Source(55, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +1->Emitted(47, 17) Source(55, 10) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +2 >Emitted(47, 48) Source(55, 20) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +3 >Emitted(47, 51) Source(55, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) --- >>> return domNode; 1 >^^^^^^^^^^^^^^^^^^^^ @@ -917,11 +907,11 @@ sourceFile:recursiveClassReferenceTest.ts 3 > 4 > domNode 5 > ; -1 >Emitted(52, 21) Source(56, 4) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) -2 >Emitted(52, 27) Source(56, 10) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) -3 >Emitted(52, 28) Source(56, 11) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) -4 >Emitted(52, 35) Source(56, 18) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) -5 >Emitted(52, 36) Source(56, 19) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) +1 >Emitted(48, 21) Source(56, 4) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) +2 >Emitted(48, 27) Source(56, 10) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) +3 >Emitted(48, 28) Source(56, 11) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) +4 >Emitted(48, 35) Source(56, 18) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) +5 >Emitted(48, 36) Source(56, 19) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) --- >>> }; 1 >^^^^^^^^^^^^^^^^ @@ -930,8 +920,8 @@ sourceFile:recursiveClassReferenceTest.ts 1 > > 2 > } -1 >Emitted(53, 17) Source(57, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) -2 >Emitted(53, 18) Source(57, 4) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) +1 >Emitted(49, 17) Source(57, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) +2 >Emitted(49, 18) Source(57, 4) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.getDomNode) --- >>> FindWidget.prototype.destroy = function () { 1->^^^^^^^^^^^^^^^^ @@ -942,9 +932,9 @@ sourceFile:recursiveClassReferenceTest.ts > public 2 > destroy 3 > -1->Emitted(54, 17) Source(59, 10) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -2 >Emitted(54, 45) Source(59, 17) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -3 >Emitted(54, 48) Source(59, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +1->Emitted(50, 17) Source(59, 10) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +2 >Emitted(50, 45) Source(59, 17) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +3 >Emitted(50, 48) Source(59, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) --- >>> }; 1 >^^^^^^^^^^^^^^^^ @@ -954,8 +944,8 @@ sourceFile:recursiveClassReferenceTest.ts > > 2 > } -1 >Emitted(55, 17) Source(61, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.destroy) -2 >Emitted(55, 18) Source(61, 4) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.destroy) +1 >Emitted(51, 17) Source(61, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.destroy) +2 >Emitted(51, 18) Source(61, 4) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget.destroy) --- >>> return FindWidget; 1->^^^^^^^^^^^^^^^^ @@ -964,8 +954,8 @@ sourceFile:recursiveClassReferenceTest.ts > > 2 > } -1->Emitted(56, 17) Source(63, 2) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -2 >Emitted(56, 34) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +1->Emitted(52, 17) Source(63, 2) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +2 >Emitted(52, 34) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) --- >>> })(); 1 >^^^^^^^^^^^^ @@ -995,10 +985,10 @@ sourceFile:recursiveClassReferenceTest.ts > } > > } -1 >Emitted(57, 13) Source(63, 2) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -2 >Emitted(57, 14) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) -3 >Emitted(57, 14) Source(45, 2) + SourceIndex(0) name (Sample.Thing.Widgets) -4 >Emitted(57, 18) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets) +1 >Emitted(53, 13) Source(63, 2) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +2 >Emitted(53, 14) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets.FindWidget) +3 >Emitted(53, 14) Source(45, 2) + SourceIndex(0) name (Sample.Thing.Widgets) +4 >Emitted(53, 18) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets) --- >>> Widgets.FindWidget = FindWidget; 1->^^^^^^^^^^^^ @@ -1028,10 +1018,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } 4 > -1->Emitted(58, 13) Source(45, 15) + SourceIndex(0) name (Sample.Thing.Widgets) -2 >Emitted(58, 31) Source(45, 25) + SourceIndex(0) name (Sample.Thing.Widgets) -3 >Emitted(58, 44) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets) -4 >Emitted(58, 45) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets) +1->Emitted(54, 13) Source(45, 15) + SourceIndex(0) name (Sample.Thing.Widgets) +2 >Emitted(54, 31) Source(45, 25) + SourceIndex(0) name (Sample.Thing.Widgets) +3 >Emitted(54, 44) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets) +4 >Emitted(54, 45) Source(63, 3) + SourceIndex(0) name (Sample.Thing.Widgets) --- >>> })(Widgets = Thing.Widgets || (Thing.Widgets = {})); 1->^^^^^^^^ @@ -1073,15 +1063,15 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1->Emitted(59, 9) Source(64, 1) + SourceIndex(0) name (Sample.Thing.Widgets) -2 >Emitted(59, 10) Source(64, 2) + SourceIndex(0) name (Sample.Thing.Widgets) -3 >Emitted(59, 12) Source(44, 21) + SourceIndex(0) name (Sample.Thing) -4 >Emitted(59, 19) Source(44, 28) + SourceIndex(0) name (Sample.Thing) -5 >Emitted(59, 22) Source(44, 21) + SourceIndex(0) name (Sample.Thing) -6 >Emitted(59, 35) Source(44, 28) + SourceIndex(0) name (Sample.Thing) -7 >Emitted(59, 40) Source(44, 21) + SourceIndex(0) name (Sample.Thing) -8 >Emitted(59, 53) Source(44, 28) + SourceIndex(0) name (Sample.Thing) -9 >Emitted(59, 61) Source(64, 2) + SourceIndex(0) name (Sample.Thing) +1->Emitted(55, 9) Source(64, 1) + SourceIndex(0) name (Sample.Thing.Widgets) +2 >Emitted(55, 10) Source(64, 2) + SourceIndex(0) name (Sample.Thing.Widgets) +3 >Emitted(55, 12) Source(44, 21) + SourceIndex(0) name (Sample.Thing) +4 >Emitted(55, 19) Source(44, 28) + SourceIndex(0) name (Sample.Thing) +5 >Emitted(55, 22) Source(44, 21) + SourceIndex(0) name (Sample.Thing) +6 >Emitted(55, 35) Source(44, 28) + SourceIndex(0) name (Sample.Thing) +7 >Emitted(55, 40) Source(44, 21) + SourceIndex(0) name (Sample.Thing) +8 >Emitted(55, 53) Source(44, 28) + SourceIndex(0) name (Sample.Thing) +9 >Emitted(55, 61) Source(64, 2) + SourceIndex(0) name (Sample.Thing) --- >>> })(Thing = Sample.Thing || (Sample.Thing = {})); 1 >^^^^ @@ -1122,15 +1112,15 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(60, 5) Source(64, 1) + SourceIndex(0) name (Sample.Thing) -2 >Emitted(60, 6) Source(64, 2) + SourceIndex(0) name (Sample.Thing) -3 >Emitted(60, 8) Source(44, 15) + SourceIndex(0) name (Sample) -4 >Emitted(60, 13) Source(44, 20) + SourceIndex(0) name (Sample) -5 >Emitted(60, 16) Source(44, 15) + SourceIndex(0) name (Sample) -6 >Emitted(60, 28) Source(44, 20) + SourceIndex(0) name (Sample) -7 >Emitted(60, 33) Source(44, 15) + SourceIndex(0) name (Sample) -8 >Emitted(60, 45) Source(44, 20) + SourceIndex(0) name (Sample) -9 >Emitted(60, 53) Source(64, 2) + SourceIndex(0) name (Sample) +1 >Emitted(56, 5) Source(64, 1) + SourceIndex(0) name (Sample.Thing) +2 >Emitted(56, 6) Source(64, 2) + SourceIndex(0) name (Sample.Thing) +3 >Emitted(56, 8) Source(44, 15) + SourceIndex(0) name (Sample) +4 >Emitted(56, 13) Source(44, 20) + SourceIndex(0) name (Sample) +5 >Emitted(56, 16) Source(44, 15) + SourceIndex(0) name (Sample) +6 >Emitted(56, 28) Source(44, 20) + SourceIndex(0) name (Sample) +7 >Emitted(56, 33) Source(44, 15) + SourceIndex(0) name (Sample) +8 >Emitted(56, 45) Source(44, 20) + SourceIndex(0) name (Sample) +9 >Emitted(56, 53) Source(64, 2) + SourceIndex(0) name (Sample) --- >>>})(Sample || (Sample = {})); 1 > @@ -1168,13 +1158,13 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(61, 1) Source(64, 1) + SourceIndex(0) name (Sample) -2 >Emitted(61, 2) Source(64, 2) + SourceIndex(0) name (Sample) -3 >Emitted(61, 4) Source(44, 8) + SourceIndex(0) -4 >Emitted(61, 10) Source(44, 14) + SourceIndex(0) -5 >Emitted(61, 15) Source(44, 8) + SourceIndex(0) -6 >Emitted(61, 21) Source(44, 14) + SourceIndex(0) -7 >Emitted(61, 29) Source(64, 2) + SourceIndex(0) +1 >Emitted(57, 1) Source(64, 1) + SourceIndex(0) name (Sample) +2 >Emitted(57, 2) Source(64, 2) + SourceIndex(0) name (Sample) +3 >Emitted(57, 4) Source(44, 8) + SourceIndex(0) +4 >Emitted(57, 10) Source(44, 14) + SourceIndex(0) +5 >Emitted(57, 15) Source(44, 8) + SourceIndex(0) +6 >Emitted(57, 21) Source(44, 14) + SourceIndex(0) +7 >Emitted(57, 29) Source(64, 2) + SourceIndex(0) --- >>>var AbstractMode = (function () { 1-> @@ -1183,67 +1173,62 @@ sourceFile:recursiveClassReferenceTest.ts > >interface IMode { getInitialState(): IState;} > -1->Emitted(62, 1) Source(67, 1) + SourceIndex(0) +1->Emitted(58, 1) Source(67, 1) + SourceIndex(0) --- >>> function AbstractMode() { 1->^^^^ 2 > ^^-> 1-> -1->Emitted(63, 5) Source(67, 1) + SourceIndex(0) name (AbstractMode) +1->Emitted(59, 5) Source(67, 1) + SourceIndex(0) name (AbstractMode) --- >>> } 1->^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1->class AbstractMode implements IMode { public getInitialState(): IState { return null;} 2 > } -1->Emitted(64, 5) Source(67, 88) + SourceIndex(0) name (AbstractMode.constructor) -2 >Emitted(64, 6) Source(67, 89) + SourceIndex(0) name (AbstractMode.constructor) +1->Emitted(60, 5) Source(67, 88) + SourceIndex(0) name (AbstractMode.constructor) +2 >Emitted(60, 6) Source(67, 89) + SourceIndex(0) name (AbstractMode.constructor) --- ->>> AbstractMode.prototype.getInitialState = function () { +>>> AbstractMode.prototype.getInitialState = function () { return null; }; 1->^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ +4 > ^^^^^^^^^^^^^^ +5 > ^^^^^^ +6 > ^ +7 > ^^^^ +8 > ^ +9 > ^ +10> ^ 1-> 2 > getInitialState 3 > -1->Emitted(65, 5) Source(67, 46) + SourceIndex(0) name (AbstractMode) -2 >Emitted(65, 43) Source(67, 61) + SourceIndex(0) name (AbstractMode) -3 >Emitted(65, 46) Source(67, 39) + SourceIndex(0) name (AbstractMode) ---- ->>> return null; -1 >^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^^^^ -5 > ^ -1 >public getInitialState(): IState { -2 > return -3 > -4 > null -5 > ; -1 >Emitted(66, 9) Source(67, 74) + SourceIndex(0) name (AbstractMode.getInitialState) -2 >Emitted(66, 15) Source(67, 80) + SourceIndex(0) name (AbstractMode.getInitialState) -3 >Emitted(66, 16) Source(67, 81) + SourceIndex(0) name (AbstractMode.getInitialState) -4 >Emitted(66, 20) Source(67, 85) + SourceIndex(0) name (AbstractMode.getInitialState) -5 >Emitted(66, 21) Source(67, 86) + SourceIndex(0) name (AbstractMode.getInitialState) ---- ->>> }; -1 >^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^-> -1 > -2 > } -1 >Emitted(67, 5) Source(67, 86) + SourceIndex(0) name (AbstractMode.getInitialState) -2 >Emitted(67, 6) Source(67, 87) + SourceIndex(0) name (AbstractMode.getInitialState) +4 > public getInitialState(): IState { +5 > return +6 > +7 > null +8 > ; +9 > +10> } +1->Emitted(61, 5) Source(67, 46) + SourceIndex(0) name (AbstractMode) +2 >Emitted(61, 43) Source(67, 61) + SourceIndex(0) name (AbstractMode) +3 >Emitted(61, 46) Source(67, 39) + SourceIndex(0) name (AbstractMode) +4 >Emitted(61, 60) Source(67, 74) + SourceIndex(0) name (AbstractMode.getInitialState) +5 >Emitted(61, 66) Source(67, 80) + SourceIndex(0) name (AbstractMode.getInitialState) +6 >Emitted(61, 67) Source(67, 81) + SourceIndex(0) name (AbstractMode.getInitialState) +7 >Emitted(61, 71) Source(67, 85) + SourceIndex(0) name (AbstractMode.getInitialState) +8 >Emitted(61, 72) Source(67, 86) + SourceIndex(0) name (AbstractMode.getInitialState) +9 >Emitted(61, 73) Source(67, 86) + SourceIndex(0) name (AbstractMode.getInitialState) +10>Emitted(61, 74) Source(67, 87) + SourceIndex(0) name (AbstractMode.getInitialState) --- >>> return AbstractMode; -1->^^^^ +1 >^^^^ 2 > ^^^^^^^^^^^^^^^^^^^ -1-> +1 > 2 > } -1->Emitted(68, 5) Source(67, 88) + SourceIndex(0) name (AbstractMode) -2 >Emitted(68, 24) Source(67, 89) + SourceIndex(0) name (AbstractMode) +1 >Emitted(62, 5) Source(67, 88) + SourceIndex(0) name (AbstractMode) +2 >Emitted(62, 24) Source(67, 89) + SourceIndex(0) name (AbstractMode) --- >>>})(); 1 > @@ -1255,10 +1240,10 @@ sourceFile:recursiveClassReferenceTest.ts 2 >} 3 > 4 > class AbstractMode implements IMode { public getInitialState(): IState { return null;} } -1 >Emitted(69, 1) Source(67, 88) + SourceIndex(0) name (AbstractMode) -2 >Emitted(69, 2) Source(67, 89) + SourceIndex(0) name (AbstractMode) -3 >Emitted(69, 2) Source(67, 1) + SourceIndex(0) -4 >Emitted(69, 6) Source(67, 89) + SourceIndex(0) +1 >Emitted(63, 1) Source(67, 88) + SourceIndex(0) name (AbstractMode) +2 >Emitted(63, 2) Source(67, 89) + SourceIndex(0) name (AbstractMode) +3 >Emitted(63, 2) Source(67, 1) + SourceIndex(0) +4 >Emitted(63, 6) Source(67, 89) + SourceIndex(0) --- >>>var Sample; 1-> @@ -1303,10 +1288,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1->Emitted(70, 1) Source(76, 1) + SourceIndex(0) -2 >Emitted(70, 5) Source(76, 8) + SourceIndex(0) -3 >Emitted(70, 11) Source(76, 14) + SourceIndex(0) -4 >Emitted(70, 12) Source(100, 2) + SourceIndex(0) +1->Emitted(64, 1) Source(76, 1) + SourceIndex(0) +2 >Emitted(64, 5) Source(76, 8) + SourceIndex(0) +3 >Emitted(64, 11) Source(76, 14) + SourceIndex(0) +4 >Emitted(64, 12) Source(100, 2) + SourceIndex(0) --- >>>(function (Sample) { 1-> @@ -1315,9 +1300,9 @@ sourceFile:recursiveClassReferenceTest.ts 1-> 2 >module 3 > Sample -1->Emitted(71, 1) Source(76, 1) + SourceIndex(0) -2 >Emitted(71, 12) Source(76, 8) + SourceIndex(0) -3 >Emitted(71, 18) Source(76, 14) + SourceIndex(0) +1->Emitted(65, 1) Source(76, 1) + SourceIndex(0) +2 >Emitted(65, 12) Source(76, 8) + SourceIndex(0) +3 >Emitted(65, 18) Source(76, 14) + SourceIndex(0) --- >>> var Thing; 1 >^^^^ @@ -1353,10 +1338,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(72, 5) Source(76, 15) + SourceIndex(0) name (Sample) -2 >Emitted(72, 9) Source(76, 15) + SourceIndex(0) name (Sample) -3 >Emitted(72, 14) Source(76, 20) + SourceIndex(0) name (Sample) -4 >Emitted(72, 15) Source(100, 2) + SourceIndex(0) name (Sample) +1 >Emitted(66, 5) Source(76, 15) + SourceIndex(0) name (Sample) +2 >Emitted(66, 9) Source(76, 15) + SourceIndex(0) name (Sample) +3 >Emitted(66, 14) Source(76, 20) + SourceIndex(0) name (Sample) +4 >Emitted(66, 15) Source(100, 2) + SourceIndex(0) name (Sample) --- >>> (function (Thing) { 1->^^^^ @@ -1366,9 +1351,9 @@ sourceFile:recursiveClassReferenceTest.ts 1-> 2 > 3 > Thing -1->Emitted(73, 5) Source(76, 15) + SourceIndex(0) name (Sample) -2 >Emitted(73, 16) Source(76, 15) + SourceIndex(0) name (Sample) -3 >Emitted(73, 21) Source(76, 20) + SourceIndex(0) name (Sample) +1->Emitted(67, 5) Source(76, 15) + SourceIndex(0) name (Sample) +2 >Emitted(67, 16) Source(76, 15) + SourceIndex(0) name (Sample) +3 >Emitted(67, 21) Source(76, 20) + SourceIndex(0) name (Sample) --- >>> var Languages; 1->^^^^^^^^ @@ -1404,10 +1389,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1->Emitted(74, 9) Source(76, 21) + SourceIndex(0) name (Sample.Thing) -2 >Emitted(74, 13) Source(76, 21) + SourceIndex(0) name (Sample.Thing) -3 >Emitted(74, 22) Source(76, 30) + SourceIndex(0) name (Sample.Thing) -4 >Emitted(74, 23) Source(100, 2) + SourceIndex(0) name (Sample.Thing) +1->Emitted(68, 9) Source(76, 21) + SourceIndex(0) name (Sample.Thing) +2 >Emitted(68, 13) Source(76, 21) + SourceIndex(0) name (Sample.Thing) +3 >Emitted(68, 22) Source(76, 30) + SourceIndex(0) name (Sample.Thing) +4 >Emitted(68, 23) Source(100, 2) + SourceIndex(0) name (Sample.Thing) --- >>> (function (Languages) { 1->^^^^^^^^ @@ -1416,9 +1401,9 @@ sourceFile:recursiveClassReferenceTest.ts 1-> 2 > 3 > Languages -1->Emitted(75, 9) Source(76, 21) + SourceIndex(0) name (Sample.Thing) -2 >Emitted(75, 20) Source(76, 21) + SourceIndex(0) name (Sample.Thing) -3 >Emitted(75, 29) Source(76, 30) + SourceIndex(0) name (Sample.Thing) +1->Emitted(69, 9) Source(76, 21) + SourceIndex(0) name (Sample.Thing) +2 >Emitted(69, 20) Source(76, 21) + SourceIndex(0) name (Sample.Thing) +3 >Emitted(69, 29) Source(76, 30) + SourceIndex(0) name (Sample.Thing) --- >>> var PlainText; 1 >^^^^^^^^^^^^ @@ -1454,10 +1439,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(76, 13) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) -2 >Emitted(76, 17) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) -3 >Emitted(76, 26) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) -4 >Emitted(76, 27) Source(100, 2) + SourceIndex(0) name (Sample.Thing.Languages) +1 >Emitted(70, 13) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) +2 >Emitted(70, 17) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) +3 >Emitted(70, 26) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) +4 >Emitted(70, 27) Source(100, 2) + SourceIndex(0) name (Sample.Thing.Languages) --- >>> (function (PlainText) { 1->^^^^^^^^^^^^ @@ -1471,11 +1456,11 @@ sourceFile:recursiveClassReferenceTest.ts 3 > PlainText 4 > 5 > { -1->Emitted(77, 13) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) -2 >Emitted(77, 24) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) -3 >Emitted(77, 33) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) -4 >Emitted(77, 35) Source(76, 41) + SourceIndex(0) name (Sample.Thing.Languages) -5 >Emitted(77, 36) Source(76, 42) + SourceIndex(0) name (Sample.Thing.Languages) +1->Emitted(71, 13) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) +2 >Emitted(71, 24) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) +3 >Emitted(71, 33) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) +4 >Emitted(71, 35) Source(76, 41) + SourceIndex(0) name (Sample.Thing.Languages) +5 >Emitted(71, 36) Source(76, 42) + SourceIndex(0) name (Sample.Thing.Languages) --- >>> var State = (function () { 1->^^^^^^^^^^^^^^^^ @@ -1483,7 +1468,7 @@ sourceFile:recursiveClassReferenceTest.ts 1-> > > -1->Emitted(78, 17) Source(78, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +1->Emitted(72, 17) Source(78, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) --- >>> function State(mode) { 1->^^^^^^^^^^^^^^^^^^^^ @@ -1494,9 +1479,9 @@ sourceFile:recursiveClassReferenceTest.ts > 2 > constructor(private 3 > mode: IMode -1->Emitted(79, 21) Source(79, 9) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -2 >Emitted(79, 36) Source(79, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -3 >Emitted(79, 40) Source(79, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +1->Emitted(73, 21) Source(79, 9) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +2 >Emitted(73, 36) Source(79, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +3 >Emitted(73, 40) Source(79, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) --- >>> this.mode = mode; 1->^^^^^^^^^^^^^^^^^^^^^^^^ @@ -1509,11 +1494,11 @@ sourceFile:recursiveClassReferenceTest.ts 3 > 4 > mode 5 > : IMode -1->Emitted(80, 25) Source(79, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) -2 >Emitted(80, 34) Source(79, 33) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) -3 >Emitted(80, 37) Source(79, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) -4 >Emitted(80, 41) Source(79, 33) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) -5 >Emitted(80, 42) Source(79, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) +1->Emitted(74, 25) Source(79, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) +2 >Emitted(74, 34) Source(79, 33) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) +3 >Emitted(74, 37) Source(79, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) +4 >Emitted(74, 41) Source(79, 33) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) +5 >Emitted(74, 42) Source(79, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) --- >>> } 1 >^^^^^^^^^^^^^^^^^^^^ @@ -1521,8 +1506,8 @@ sourceFile:recursiveClassReferenceTest.ts 3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 >) { 2 > } -1 >Emitted(81, 21) Source(79, 44) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) -2 >Emitted(81, 22) Source(79, 45) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) +1 >Emitted(75, 21) Source(79, 44) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) +2 >Emitted(75, 22) Source(79, 45) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.constructor) --- >>> State.prototype.clone = function () { 1->^^^^^^^^^^^^^^^^^^^^ @@ -1532,9 +1517,9 @@ sourceFile:recursiveClassReferenceTest.ts > public 2 > clone 3 > -1->Emitted(82, 21) Source(80, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -2 >Emitted(82, 42) Source(80, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -3 >Emitted(82, 45) Source(80, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +1->Emitted(76, 21) Source(80, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +2 >Emitted(76, 42) Source(80, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +3 >Emitted(76, 45) Source(80, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) --- >>> return this; 1 >^^^^^^^^^^^^^^^^^^^^^^^^ @@ -1548,11 +1533,11 @@ sourceFile:recursiveClassReferenceTest.ts 3 > 4 > this 5 > ; -1 >Emitted(83, 25) Source(81, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) -2 >Emitted(83, 31) Source(81, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) -3 >Emitted(83, 32) Source(81, 11) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) -4 >Emitted(83, 36) Source(81, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) -5 >Emitted(83, 37) Source(81, 16) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) +1 >Emitted(77, 25) Source(81, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) +2 >Emitted(77, 31) Source(81, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) +3 >Emitted(77, 32) Source(81, 11) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) +4 >Emitted(77, 36) Source(81, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) +5 >Emitted(77, 37) Source(81, 16) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) --- >>> }; 1 >^^^^^^^^^^^^^^^^^^^^ @@ -1561,8 +1546,8 @@ sourceFile:recursiveClassReferenceTest.ts 1 > > 2 > } -1 >Emitted(84, 21) Source(82, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) -2 >Emitted(84, 22) Source(82, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) +1 >Emitted(78, 21) Source(82, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) +2 >Emitted(78, 22) Source(82, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.clone) --- >>> State.prototype.equals = function (other) { 1->^^^^^^^^^^^^^^^^^^^^ @@ -1577,11 +1562,11 @@ sourceFile:recursiveClassReferenceTest.ts 3 > 4 > public equals( 5 > other:IState -1->Emitted(85, 21) Source(84, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -2 >Emitted(85, 43) Source(84, 16) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -3 >Emitted(85, 46) Source(84, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -4 >Emitted(85, 56) Source(84, 17) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -5 >Emitted(85, 61) Source(84, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +1->Emitted(79, 21) Source(84, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +2 >Emitted(79, 43) Source(84, 16) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +3 >Emitted(79, 46) Source(84, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +4 >Emitted(79, 56) Source(84, 17) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +5 >Emitted(79, 61) Source(84, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) --- >>> return this === other; 1 >^^^^^^^^^^^^^^^^^^^^^^^^ @@ -1599,71 +1584,66 @@ sourceFile:recursiveClassReferenceTest.ts 5 > === 6 > other 7 > ; -1 >Emitted(86, 25) Source(85, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) -2 >Emitted(86, 31) Source(85, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) -3 >Emitted(86, 32) Source(85, 11) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) -4 >Emitted(86, 36) Source(85, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) -5 >Emitted(86, 41) Source(85, 20) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) -6 >Emitted(86, 46) Source(85, 25) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) -7 >Emitted(86, 47) Source(85, 26) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +1 >Emitted(80, 25) Source(85, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +2 >Emitted(80, 31) Source(85, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +3 >Emitted(80, 32) Source(85, 11) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +4 >Emitted(80, 36) Source(85, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +5 >Emitted(80, 41) Source(85, 20) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +6 >Emitted(80, 46) Source(85, 25) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +7 >Emitted(80, 47) Source(85, 26) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) --- >>> }; 1 >^^^^^^^^^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > > 2 > } -1 >Emitted(87, 21) Source(86, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) -2 >Emitted(87, 22) Source(86, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +1 >Emitted(81, 21) Source(86, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) +2 >Emitted(81, 22) Source(86, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.equals) --- ->>> State.prototype.getMode = function () { +>>> State.prototype.getMode = function () { return mode; }; 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ +4 > ^^^^^^^^^^^^^^ +5 > ^^^^^^ +6 > ^ +7 > ^^^^ +8 > ^ +9 > ^ +10> ^ 1-> > > public 2 > getMode 3 > -1->Emitted(88, 21) Source(88, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -2 >Emitted(88, 44) Source(88, 17) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -3 >Emitted(88, 47) Source(88, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) ---- ->>> return mode; -1 >^^^^^^^^^^^^^^^^^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^^^^ -5 > ^ -1 >public getMode(): IMode { -2 > return -3 > -4 > mode -5 > ; -1 >Emitted(89, 25) Source(88, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) -2 >Emitted(89, 31) Source(88, 35) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) -3 >Emitted(89, 32) Source(88, 36) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) -4 >Emitted(89, 36) Source(88, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) -5 >Emitted(89, 37) Source(88, 41) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) ---- ->>> }; -1 >^^^^^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^-> -1 > -2 > } -1 >Emitted(90, 21) Source(88, 42) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) -2 >Emitted(90, 22) Source(88, 43) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) +4 > public getMode(): IMode { +5 > return +6 > +7 > mode +8 > ; +9 > +10> } +1->Emitted(82, 21) Source(88, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +2 >Emitted(82, 44) Source(88, 17) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +3 >Emitted(82, 47) Source(88, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +4 >Emitted(82, 61) Source(88, 29) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) +5 >Emitted(82, 67) Source(88, 35) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) +6 >Emitted(82, 68) Source(88, 36) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) +7 >Emitted(82, 72) Source(88, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) +8 >Emitted(82, 73) Source(88, 41) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) +9 >Emitted(82, 74) Source(88, 42) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) +10>Emitted(82, 75) Source(88, 43) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State.getMode) --- >>> return State; -1->^^^^^^^^^^^^^^^^^^^^ +1 >^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^ -1-> +1 > > 2 > } -1->Emitted(91, 21) Source(89, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -2 >Emitted(91, 33) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +1 >Emitted(83, 21) Source(89, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +2 >Emitted(83, 33) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) --- >>> })(); 1 >^^^^^^^^^^^^^^^^ @@ -1686,10 +1666,10 @@ sourceFile:recursiveClassReferenceTest.ts > > public getMode(): IMode { return mode; } > } -1 >Emitted(92, 17) Source(89, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -2 >Emitted(92, 18) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) -3 >Emitted(92, 18) Source(78, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -4 >Emitted(92, 22) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +1 >Emitted(84, 17) Source(89, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +2 >Emitted(84, 18) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.State) +3 >Emitted(84, 18) Source(78, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +4 >Emitted(84, 22) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) --- >>> PlainText.State = State; 1->^^^^^^^^^^^^^^^^ @@ -1712,10 +1692,10 @@ sourceFile:recursiveClassReferenceTest.ts > public getMode(): IMode { return mode; } > } 4 > -1->Emitted(93, 17) Source(78, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -2 >Emitted(93, 32) Source(78, 20) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -3 >Emitted(93, 40) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -4 >Emitted(93, 41) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +1->Emitted(85, 17) Source(78, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +2 >Emitted(85, 32) Source(78, 20) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +3 >Emitted(85, 40) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +4 >Emitted(85, 41) Source(89, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) --- >>> var Mode = (function (_super) { 1->^^^^^^^^^^^^^^^^ @@ -1723,29 +1703,29 @@ sourceFile:recursiveClassReferenceTest.ts 1-> > > -1->Emitted(94, 17) Source(91, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +1->Emitted(86, 17) Source(91, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) --- >>> __extends(Mode, _super); 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^ 1->export class Mode extends 2 > AbstractMode -1->Emitted(95, 21) Source(91, 28) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) -2 >Emitted(95, 45) Source(91, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +1->Emitted(87, 21) Source(91, 28) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +2 >Emitted(87, 45) Source(91, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) --- >>> function Mode() { 1 >^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > -1 >Emitted(96, 21) Source(91, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +1 >Emitted(88, 21) Source(91, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) --- >>> _super.apply(this, arguments); 1->^^^^^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 1->export class Mode extends 2 > AbstractMode -1->Emitted(97, 25) Source(91, 28) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.constructor) -2 >Emitted(97, 55) Source(91, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.constructor) +1->Emitted(89, 25) Source(91, 28) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.constructor) +2 >Emitted(89, 55) Source(91, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.constructor) --- >>> } 1 >^^^^^^^^^^^^^^^^^^^^ @@ -1761,8 +1741,8 @@ sourceFile:recursiveClassReferenceTest.ts > > 2 > } -1 >Emitted(98, 21) Source(99, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.constructor) -2 >Emitted(98, 22) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.constructor) +1 >Emitted(90, 21) Source(99, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.constructor) +2 >Emitted(90, 22) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.constructor) --- >>> // scenario 2 1->^^^^^^^^^^^^^^^^^^^^ @@ -1770,8 +1750,8 @@ sourceFile:recursiveClassReferenceTest.ts 3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> 2 > // scenario 2 -1->Emitted(99, 21) Source(93, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) -2 >Emitted(99, 34) Source(93, 16) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +1->Emitted(91, 21) Source(93, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +2 >Emitted(91, 34) Source(93, 16) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) --- >>> Mode.prototype.getInitialState = function () { 1->^^^^^^^^^^^^^^^^^^^^ @@ -1781,9 +1761,9 @@ sourceFile:recursiveClassReferenceTest.ts > public 2 > getInitialState 3 > -1->Emitted(100, 21) Source(94, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) -2 >Emitted(100, 51) Source(94, 25) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) -3 >Emitted(100, 54) Source(94, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +1->Emitted(92, 21) Source(94, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +2 >Emitted(92, 51) Source(94, 25) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +3 >Emitted(92, 54) Source(94, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) --- >>> return new State(self); 1 >^^^^^^^^^^^^^^^^^^^^^^^^ @@ -1805,15 +1785,15 @@ sourceFile:recursiveClassReferenceTest.ts 7 > self 8 > ) 9 > ; -1 >Emitted(101, 25) Source(95, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -2 >Emitted(101, 31) Source(95, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -3 >Emitted(101, 32) Source(95, 11) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -4 >Emitted(101, 36) Source(95, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -5 >Emitted(101, 41) Source(95, 20) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -6 >Emitted(101, 42) Source(95, 21) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -7 >Emitted(101, 46) Source(95, 25) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -8 >Emitted(101, 47) Source(95, 26) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -9 >Emitted(101, 48) Source(95, 27) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +1 >Emitted(93, 25) Source(95, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +2 >Emitted(93, 31) Source(95, 10) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +3 >Emitted(93, 32) Source(95, 11) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +4 >Emitted(93, 36) Source(95, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +5 >Emitted(93, 41) Source(95, 20) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +6 >Emitted(93, 42) Source(95, 21) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +7 >Emitted(93, 46) Source(95, 25) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +8 >Emitted(93, 47) Source(95, 26) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +9 >Emitted(93, 48) Source(95, 27) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) --- >>> }; 1 >^^^^^^^^^^^^^^^^^^^^ @@ -1822,8 +1802,8 @@ sourceFile:recursiveClassReferenceTest.ts 1 > > 2 > } -1 >Emitted(102, 21) Source(96, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) -2 >Emitted(102, 22) Source(96, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +1 >Emitted(94, 21) Source(96, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) +2 >Emitted(94, 22) Source(96, 4) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode.getInitialState) --- >>> return Mode; 1->^^^^^^^^^^^^^^^^^^^^ @@ -1834,8 +1814,8 @@ sourceFile:recursiveClassReferenceTest.ts > > 2 > } -1->Emitted(103, 21) Source(99, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) -2 >Emitted(103, 32) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +1->Emitted(95, 21) Source(99, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +2 >Emitted(95, 32) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) --- >>> })(AbstractMode); 1->^^^^^^^^^^^^^^^^ @@ -1859,12 +1839,12 @@ sourceFile:recursiveClassReferenceTest.ts > > > } -1->Emitted(104, 17) Source(99, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) -2 >Emitted(104, 18) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) -3 >Emitted(104, 18) Source(91, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -4 >Emitted(104, 20) Source(91, 28) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -5 >Emitted(104, 32) Source(91, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -6 >Emitted(104, 34) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +1->Emitted(96, 17) Source(99, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +2 >Emitted(96, 18) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText.Mode) +3 >Emitted(96, 18) Source(91, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +4 >Emitted(96, 20) Source(91, 28) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +5 >Emitted(96, 32) Source(91, 40) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +6 >Emitted(96, 34) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) --- >>> PlainText.Mode = Mode; 1->^^^^^^^^^^^^^^^^ @@ -1884,10 +1864,10 @@ sourceFile:recursiveClassReferenceTest.ts > > } 4 > -1->Emitted(105, 17) Source(91, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -2 >Emitted(105, 31) Source(91, 19) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -3 >Emitted(105, 38) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -4 >Emitted(105, 39) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +1->Emitted(97, 17) Source(91, 15) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +2 >Emitted(97, 31) Source(91, 19) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +3 >Emitted(97, 38) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +4 >Emitted(97, 39) Source(99, 3) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) --- >>> })(PlainText = Languages.PlainText || (Languages.PlainText = {})); 1->^^^^^^^^^^^^ @@ -1933,15 +1913,15 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1->Emitted(106, 13) Source(100, 1) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -2 >Emitted(106, 14) Source(100, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) -3 >Emitted(106, 16) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) -4 >Emitted(106, 25) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) -5 >Emitted(106, 28) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) -6 >Emitted(106, 47) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) -7 >Emitted(106, 52) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) -8 >Emitted(106, 71) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) -9 >Emitted(106, 79) Source(100, 2) + SourceIndex(0) name (Sample.Thing.Languages) +1->Emitted(98, 13) Source(100, 1) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +2 >Emitted(98, 14) Source(100, 2) + SourceIndex(0) name (Sample.Thing.Languages.PlainText) +3 >Emitted(98, 16) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) +4 >Emitted(98, 25) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) +5 >Emitted(98, 28) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) +6 >Emitted(98, 47) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) +7 >Emitted(98, 52) Source(76, 31) + SourceIndex(0) name (Sample.Thing.Languages) +8 >Emitted(98, 71) Source(76, 40) + SourceIndex(0) name (Sample.Thing.Languages) +9 >Emitted(98, 79) Source(100, 2) + SourceIndex(0) name (Sample.Thing.Languages) --- >>> })(Languages = Thing.Languages || (Thing.Languages = {})); 1 >^^^^^^^^ @@ -1986,15 +1966,15 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(107, 9) Source(100, 1) + SourceIndex(0) name (Sample.Thing.Languages) -2 >Emitted(107, 10) Source(100, 2) + SourceIndex(0) name (Sample.Thing.Languages) -3 >Emitted(107, 12) Source(76, 21) + SourceIndex(0) name (Sample.Thing) -4 >Emitted(107, 21) Source(76, 30) + SourceIndex(0) name (Sample.Thing) -5 >Emitted(107, 24) Source(76, 21) + SourceIndex(0) name (Sample.Thing) -6 >Emitted(107, 39) Source(76, 30) + SourceIndex(0) name (Sample.Thing) -7 >Emitted(107, 44) Source(76, 21) + SourceIndex(0) name (Sample.Thing) -8 >Emitted(107, 59) Source(76, 30) + SourceIndex(0) name (Sample.Thing) -9 >Emitted(107, 67) Source(100, 2) + SourceIndex(0) name (Sample.Thing) +1 >Emitted(99, 9) Source(100, 1) + SourceIndex(0) name (Sample.Thing.Languages) +2 >Emitted(99, 10) Source(100, 2) + SourceIndex(0) name (Sample.Thing.Languages) +3 >Emitted(99, 12) Source(76, 21) + SourceIndex(0) name (Sample.Thing) +4 >Emitted(99, 21) Source(76, 30) + SourceIndex(0) name (Sample.Thing) +5 >Emitted(99, 24) Source(76, 21) + SourceIndex(0) name (Sample.Thing) +6 >Emitted(99, 39) Source(76, 30) + SourceIndex(0) name (Sample.Thing) +7 >Emitted(99, 44) Source(76, 21) + SourceIndex(0) name (Sample.Thing) +8 >Emitted(99, 59) Source(76, 30) + SourceIndex(0) name (Sample.Thing) +9 >Emitted(99, 67) Source(100, 2) + SourceIndex(0) name (Sample.Thing) --- >>> })(Thing = Sample.Thing || (Sample.Thing = {})); 1 >^^^^ @@ -2039,15 +2019,15 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(108, 5) Source(100, 1) + SourceIndex(0) name (Sample.Thing) -2 >Emitted(108, 6) Source(100, 2) + SourceIndex(0) name (Sample.Thing) -3 >Emitted(108, 8) Source(76, 15) + SourceIndex(0) name (Sample) -4 >Emitted(108, 13) Source(76, 20) + SourceIndex(0) name (Sample) -5 >Emitted(108, 16) Source(76, 15) + SourceIndex(0) name (Sample) -6 >Emitted(108, 28) Source(76, 20) + SourceIndex(0) name (Sample) -7 >Emitted(108, 33) Source(76, 15) + SourceIndex(0) name (Sample) -8 >Emitted(108, 45) Source(76, 20) + SourceIndex(0) name (Sample) -9 >Emitted(108, 53) Source(100, 2) + SourceIndex(0) name (Sample) +1 >Emitted(100, 5) Source(100, 1) + SourceIndex(0) name (Sample.Thing) +2 >Emitted(100, 6) Source(100, 2) + SourceIndex(0) name (Sample.Thing) +3 >Emitted(100, 8) Source(76, 15) + SourceIndex(0) name (Sample) +4 >Emitted(100, 13) Source(76, 20) + SourceIndex(0) name (Sample) +5 >Emitted(100, 16) Source(76, 15) + SourceIndex(0) name (Sample) +6 >Emitted(100, 28) Source(76, 20) + SourceIndex(0) name (Sample) +7 >Emitted(100, 33) Source(76, 15) + SourceIndex(0) name (Sample) +8 >Emitted(100, 45) Source(76, 20) + SourceIndex(0) name (Sample) +9 >Emitted(100, 53) Source(100, 2) + SourceIndex(0) name (Sample) --- >>>})(Sample || (Sample = {})); 1 > @@ -2089,12 +2069,12 @@ sourceFile:recursiveClassReferenceTest.ts > > } > } -1 >Emitted(109, 1) Source(100, 1) + SourceIndex(0) name (Sample) -2 >Emitted(109, 2) Source(100, 2) + SourceIndex(0) name (Sample) -3 >Emitted(109, 4) Source(76, 8) + SourceIndex(0) -4 >Emitted(109, 10) Source(76, 14) + SourceIndex(0) -5 >Emitted(109, 15) Source(76, 8) + SourceIndex(0) -6 >Emitted(109, 21) Source(76, 14) + SourceIndex(0) -7 >Emitted(109, 29) Source(100, 2) + SourceIndex(0) +1 >Emitted(101, 1) Source(100, 1) + SourceIndex(0) name (Sample) +2 >Emitted(101, 2) Source(100, 2) + SourceIndex(0) name (Sample) +3 >Emitted(101, 4) Source(76, 8) + SourceIndex(0) +4 >Emitted(101, 10) Source(76, 14) + SourceIndex(0) +5 >Emitted(101, 15) Source(76, 8) + SourceIndex(0) +6 >Emitted(101, 21) Source(76, 14) + SourceIndex(0) +7 >Emitted(101, 29) Source(100, 2) + SourceIndex(0) --- >>>//# sourceMappingURL=recursiveClassReferenceTest.js.map \ No newline at end of file diff --git a/tests/baselines/reference/recursiveFunctionTypes.js b/tests/baselines/reference/recursiveFunctionTypes.js index 6f10ef9908..040c323066 100644 --- a/tests/baselines/reference/recursiveFunctionTypes.js +++ b/tests/baselines/reference/recursiveFunctionTypes.js @@ -45,39 +45,27 @@ f7(""); // ok (function takes an any param) f7(); // ok //// [recursiveFunctionTypes.js] -function fn() { - return 1; -} +function fn() { return 1; } var x = fn; // error var y = fn; // ok var f; var g; -function f1(d) { -} -function f2() { -} -function g2() { -} -function f3() { - return f3; -} +function f1(d) { } +function f2() { } +function g2() { } +function f3() { return f3; } var a = f3; // error var C = (function () { function C() { } - C.g = function (t) { - }; + C.g = function (t) { }; return C; })(); C.g(3); // error var f4; f4 = 3; // error -function f5() { - return f5; -} -function f6(a) { - return f6; -} +function f5() { return f5; } +function f6(a) { return f6; } f6("", 3); // error (arity mismatch) f6(""); // ok (function takes an any param) f6(); // ok diff --git a/tests/baselines/reference/recursiveFunctionTypes1.js b/tests/baselines/reference/recursiveFunctionTypes1.js index 2f2d072cb6..c4c255d5e4 100644 --- a/tests/baselines/reference/recursiveFunctionTypes1.js +++ b/tests/baselines/reference/recursiveFunctionTypes1.js @@ -7,7 +7,6 @@ class C { var C = (function () { function C() { } - C.g = function (t) { - }; + C.g = function (t) { }; return C; })(); diff --git a/tests/baselines/reference/recursiveGetterAccess.js b/tests/baselines/reference/recursiveGetterAccess.js index cf042c2c1a..1dea2e02d3 100644 --- a/tests/baselines/reference/recursiveGetterAccess.js +++ b/tests/baselines/reference/recursiveGetterAccess.js @@ -10,9 +10,7 @@ var MyClass = (function () { function MyClass() { } Object.defineProperty(MyClass.prototype, "testProp", { - get: function () { - return this.testProp; - }, + get: function () { return this.testProp; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/recursiveIdenticalOverloadResolution.js b/tests/baselines/reference/recursiveIdenticalOverloadResolution.js index e1ea203ac5..3c53c2b2a0 100644 --- a/tests/baselines/reference/recursiveIdenticalOverloadResolution.js +++ b/tests/baselines/reference/recursiveIdenticalOverloadResolution.js @@ -20,9 +20,7 @@ module M { //// [recursiveIdenticalOverloadResolution.js] var M; (function (M) { - function f(p) { - return f; - } + function f(p) { return f; } ; var i; f(i); diff --git a/tests/baselines/reference/recursiveInference1.js b/tests/baselines/reference/recursiveInference1.js index 839e13130f..3a26ead542 100644 --- a/tests/baselines/reference/recursiveInference1.js +++ b/tests/baselines/reference/recursiveInference1.js @@ -3,7 +3,5 @@ function fib(x:number) { return x <= 1 ? x : fib(x - 1) + fib(x - 2); } var result = fib(5); //// [recursiveInference1.js] -function fib(x) { - return x <= 1 ? x : fib(x - 1) + fib(x - 2); -} +function fib(x) { return x <= 1 ? x : fib(x - 1) + fib(x - 2); } var result = fib(5); diff --git a/tests/baselines/reference/recursiveInferenceBug.js b/tests/baselines/reference/recursiveInferenceBug.js index cffa96415d..5b4d4f0c0a 100644 --- a/tests/baselines/reference/recursiveInferenceBug.js +++ b/tests/baselines/reference/recursiveInferenceBug.js @@ -17,9 +17,6 @@ function f(x) { return x; } var zz = { - g: function () { - }, - get f() { - return "abc"; - } + g: function () { }, + get f() { return "abc"; } }; diff --git a/tests/baselines/reference/recursiveInheritance3.js b/tests/baselines/reference/recursiveInheritance3.js index 710b691fa9..bc9fb6cb4f 100644 --- a/tests/baselines/reference/recursiveInheritance3.js +++ b/tests/baselines/reference/recursiveInheritance3.js @@ -13,8 +13,6 @@ var C = (function () { function C() { this.x = 1; } - C.prototype.foo = function (x) { - return x; - }; + C.prototype.foo = function (x) { return x; }; return C; })(); diff --git a/tests/baselines/reference/recursiveInitializer.js b/tests/baselines/reference/recursiveInitializer.js index 2b33e873cb..82abf2b50a 100644 --- a/tests/baselines/reference/recursiveInitializer.js +++ b/tests/baselines/reference/recursiveInitializer.js @@ -35,6 +35,4 @@ var b2 = !!b2; var b3 = !b3 || b3; // expected boolean here. actually 'any' var b4 = (!b4) && b4; // expected boolean here. actually 'any' // (x:string) => any -var f = function (x) { - return f(x); -}; +var f = function (x) { return f(x); }; diff --git a/tests/baselines/reference/recursiveLetConst.js b/tests/baselines/reference/recursiveLetConst.js index 7d9aea3a75..9c6151cde3 100644 --- a/tests/baselines/reference/recursiveLetConst.js +++ b/tests/baselines/reference/recursiveLetConst.js @@ -20,23 +20,12 @@ let x = x + 1; let [x1] = x1 + 1; const y = y + 2; const [y1] = y1 + 1; -for (let v = v;;) { -} -for (let [v] = v;;) { -} -for (let v in v) { -} -for (let v of v) { -} -for (let [v] of v) { -} +for (let v = v;;) { } +for (let [v] = v;;) { } +for (let v in v) { } +for (let v of v) { } +for (let [v] of v) { } let [x2 = x2] = []; let z0 = () => z0; -let z1 = function () { - return z1; -}; -let z2 = { - f() { - return z2; - } -}; +let z1 = function () { return z1; }; +let z2 = { f() { return z2; } }; diff --git a/tests/baselines/reference/recursiveObjectLiteral.js b/tests/baselines/reference/recursiveObjectLiteral.js index 80c512a828..70de48d249 100644 --- a/tests/baselines/reference/recursiveObjectLiteral.js +++ b/tests/baselines/reference/recursiveObjectLiteral.js @@ -2,6 +2,4 @@ var a = { f: a }; //// [recursiveObjectLiteral.js] -var a = { - f: a -}; +var a = { f: a }; diff --git a/tests/baselines/reference/recursiveProperties.js b/tests/baselines/reference/recursiveProperties.js index 6364448495..84d9ebcd27 100644 --- a/tests/baselines/reference/recursiveProperties.js +++ b/tests/baselines/reference/recursiveProperties.js @@ -12,9 +12,7 @@ var A = (function () { function A() { } Object.defineProperty(A.prototype, "testProp", { - get: function () { - return this.testProp; - }, + get: function () { return this.testProp; }, enumerable: true, configurable: true }); @@ -24,9 +22,7 @@ var B = (function () { function B() { } Object.defineProperty(B.prototype, "testProp", { - set: function (value) { - this.testProp = value; - }, + set: function (value) { this.testProp = value; }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/recursiveReturns.js b/tests/baselines/reference/recursiveReturns.js index d01825f8cb..18c9ed4dd7 100644 --- a/tests/baselines/reference/recursiveReturns.js +++ b/tests/baselines/reference/recursiveReturns.js @@ -20,9 +20,7 @@ function R1() { R1(); return; } -function R2() { - R2(); -} +function R2() { R2(); } function R3(n) { if (n == 0) { } diff --git a/tests/baselines/reference/recursiveTypesUsedAsFunctionParameters.js b/tests/baselines/reference/recursiveTypesUsedAsFunctionParameters.js index b056e90e90..0cef9be47a 100644 --- a/tests/baselines/reference/recursiveTypesUsedAsFunctionParameters.js +++ b/tests/baselines/reference/recursiveTypesUsedAsFunctionParameters.js @@ -59,13 +59,9 @@ function foo(x) { function foo2(x) { } function other() { - function foo3(x) { - } - function foo4(x) { - } - function foo5(x) { - return null; - } + function foo3(x) { } + function foo4(x) { } + function foo5(x) { return null; } var list; var myList; var r = foo5(list); diff --git a/tests/baselines/reference/redefineArray.js b/tests/baselines/reference/redefineArray.js index 9349423243..080d2b1a2d 100644 --- a/tests/baselines/reference/redefineArray.js +++ b/tests/baselines/reference/redefineArray.js @@ -2,6 +2,4 @@ Array = function (n:number, s:string) {return n;}; //// [redefineArray.js] -Array = function (n, s) { - return n; -}; +Array = function (n, s) { return n; }; diff --git a/tests/baselines/reference/resolvingClassDeclarationWhenInBaseTypeResolution.js b/tests/baselines/reference/resolvingClassDeclarationWhenInBaseTypeResolution.js index 608090e872..24f0e7f1bc 100644 --- a/tests/baselines/reference/resolvingClassDeclarationWhenInBaseTypeResolution.js +++ b/tests/baselines/reference/resolvingClassDeclarationWhenInBaseTypeResolution.js @@ -1036,41 +1036,31 @@ var rionegrensis; caniventer.prototype.salomonseni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; caniventer.prototype.uchidai = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; caniventer.prototype.raffrayana = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; caniventer.prototype.Uranium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; caniventer.prototype.nayaur = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return caniventer; @@ -1084,41 +1074,31 @@ var rionegrensis; veraecrucis.prototype.naso = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; veraecrucis.prototype.vancouverensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; veraecrucis.prototype.africana = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; veraecrucis.prototype.palliolata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; veraecrucis.prototype.nivicola = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return veraecrucis; @@ -1139,41 +1119,31 @@ var julianae; nudicaudus.prototype.brandtii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nudicaudus.prototype.maxwellii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nudicaudus.prototype.endoi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nudicaudus.prototype.venezuelae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nudicaudus.prototype.zamicrus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return nudicaudus; @@ -1185,57 +1155,43 @@ var julianae; galapagoensis.prototype.isabellae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; galapagoensis.prototype.rueppellii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; galapagoensis.prototype.peregusna = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; galapagoensis.prototype.gliroides = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; galapagoensis.prototype.banakrisi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; galapagoensis.prototype.rozendaali = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; galapagoensis.prototype.stuhlmanni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return galapagoensis; @@ -1247,57 +1203,43 @@ var julianae; albidens.prototype.mattheyi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; albidens.prototype.Astatine = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; albidens.prototype.vincenti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; albidens.prototype.hirta = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; albidens.prototype.virginianus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; albidens.prototype.macrophyllum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; albidens.prototype.porcellus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return albidens; @@ -1311,105 +1253,79 @@ var julianae; oralis.prototype.cepapi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.porteri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.bindi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.puda = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.mindorensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.ignitus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.rufus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.monax = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.unalascensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.wuchihensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.leucippe = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.ordii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oralis.prototype.eisentrauti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return oralis; @@ -1423,57 +1339,43 @@ var julianae; sumatrana.prototype.wolffsohni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sumatrana.prototype.geata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sumatrana.prototype.awashensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sumatrana.prototype.sturdeei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sumatrana.prototype.pachyurus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sumatrana.prototype.lyelli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sumatrana.prototype.neohibernicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return sumatrana; @@ -1485,89 +1387,67 @@ var julianae; gerbillus.prototype.pundti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.tristrami = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.swarthi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.horsfieldii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.diazi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.rennelli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.maulinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.muscina = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.pelengensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.abramus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gerbillus.prototype.reevesi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return gerbillus; @@ -1579,97 +1459,73 @@ var julianae; acariensis.prototype.levicula = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.minous = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.cinereiventer = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.longicaudatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.baeodon = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.soricoides = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.datae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.spixii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.anakuma = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.kihaulei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.gymnura = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; acariensis.prototype.olchonensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return acariensis; @@ -1683,25 +1539,19 @@ var julianae; durangae.prototype.Californium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; durangae.prototype.Flerovium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; durangae.prototype.phrudus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return durangae; @@ -1716,17 +1566,13 @@ var ruatanica; hector.prototype.humulis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; hector.prototype.eurycerus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return hector; @@ -1741,25 +1587,19 @@ var Lanthanum; suillus.prototype.spilosoma = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; suillus.prototype.tumbalensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; suillus.prototype.anatolicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return suillus; @@ -1773,81 +1613,61 @@ var Lanthanum; nitidus.prototype.granatensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.negligens = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.lewisi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.arge = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.dominicensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.taurus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.tonganus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.silvatica = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.midas = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; nitidus.prototype.bicornis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return nitidus; @@ -1861,65 +1681,49 @@ var Lanthanum; megalonyx.prototype.phillipsii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megalonyx.prototype.melanogaster = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megalonyx.prototype.elaphus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megalonyx.prototype.elater = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megalonyx.prototype.ourebi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megalonyx.prototype.caraccioli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megalonyx.prototype.parva = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megalonyx.prototype.albipes = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return megalonyx; @@ -1931,113 +1735,85 @@ var Lanthanum; jugularis.prototype.torrei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.revoili = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.macrobullatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.compactus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.talpinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.stramineus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.dartmouthi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.ogilbyi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.incomtus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.surdaster = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.melanorhinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.picticaudata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.pomona = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; jugularis.prototype.ileile = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return jugularis; @@ -2054,113 +1830,85 @@ var rendalli; zuluensis.prototype.telfairi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.keyensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.occasius = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.damarensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.Neptunium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.griseoflavus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.thar = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.alborufus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.fusicaudus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.gordonorum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.ruber = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.desmarestianus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.lutillus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; zuluensis.prototype.salocco = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return zuluensis; @@ -2172,81 +1920,61 @@ var rendalli; moojeni.prototype.floweri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.montosa = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.miletus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.heaneyi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.marchei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.budini = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.maggietaylorae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.poliocephalus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.zibethicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; moojeni.prototype.biacensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return moojeni; @@ -2260,25 +1988,19 @@ var rendalli; crenulata.prototype.salvanius = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; crenulata.prototype.maritimus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; crenulata.prototype.edax = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return crenulata; @@ -2293,65 +2015,49 @@ var trivirgatus; tumidifrons.prototype.nivalis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; tumidifrons.prototype.vestitus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; tumidifrons.prototype.aequatorius = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; tumidifrons.prototype.scherman = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; tumidifrons.prototype.improvisum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; tumidifrons.prototype.cervinipes = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; tumidifrons.prototype.audax = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; tumidifrons.prototype.vallinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return tumidifrons; @@ -2365,57 +2071,43 @@ var trivirgatus; mixtus.prototype.ochrogaster = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mixtus.prototype.bryophilus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mixtus.prototype.liechtensteini = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mixtus.prototype.crawfordi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mixtus.prototype.hypsibia = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mixtus.prototype.matacus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mixtus.prototype.demidoff = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return mixtus; @@ -2427,17 +2119,13 @@ var trivirgatus; lotor.prototype.balensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; lotor.prototype.pullata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return lotor; @@ -2449,57 +2137,43 @@ var trivirgatus; falconeri.prototype.cabrali = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; falconeri.prototype.gouldi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; falconeri.prototype.fuscicollis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; falconeri.prototype.martiensseni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; falconeri.prototype.gaoligongensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; falconeri.prototype.shawi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; falconeri.prototype.gmelini = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return falconeri; @@ -2511,113 +2185,85 @@ var trivirgatus; oconnelli.prototype.youngsoni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.terrestris = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.chrysopus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.fuscomurina = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.hellwaldii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.aenea = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.perrini = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.entellus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.krebsii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.cephalotes = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.molossinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.luisi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.ceylonicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oconnelli.prototype.ralli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return oconnelli; @@ -2632,33 +2278,25 @@ var quasiater; bobrinskoi.prototype.crassicaudatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; bobrinskoi.prototype.mulatta = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; bobrinskoi.prototype.ansorgei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; bobrinskoi.prototype.Copper = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return bobrinskoi; @@ -2675,33 +2313,25 @@ var ruatanica; americanus.prototype.nasoloi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; americanus.prototype.mystacalis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; americanus.prototype.fardoulisi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; americanus.prototype.tumidus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return americanus; @@ -2718,105 +2348,79 @@ var lavali; wilsoni.prototype.setiger = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.lorentzii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.antisensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.blossevillii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.bontanus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.caligata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.franqueti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.roberti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.degelidus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.amoenus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.kob = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.csorbai = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wilsoni.prototype.dorsata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return wilsoni; @@ -2836,105 +2440,79 @@ var lavali; otion.prototype.bonaerensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.dussumieri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.osvaldoreigi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.grevyi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.hirtula = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.cristatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.darlingtoni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.fontanierii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.umbrosus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.chiriquinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.orarius = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.ilaeus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; otion.prototype.musschenbroekii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return otion; @@ -2946,97 +2524,73 @@ var lavali; xanthognathus.prototype.nanulus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.albigena = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.onca = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.gunnii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.apeco = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.variegates = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.goudotii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.pohlei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.ineptus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.euryotis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.maurisca = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; xanthognathus.prototype.coyhaiquensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return xanthognathus; @@ -3050,65 +2604,49 @@ var lavali; thaeleri.prototype.coromandra = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thaeleri.prototype.parvipes = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thaeleri.prototype.sponsorius = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thaeleri.prototype.vates = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thaeleri.prototype.roosmalenorum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thaeleri.prototype.rubicola = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thaeleri.prototype.ikonnikovi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thaeleri.prototype.paramicrus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return thaeleri; @@ -3122,17 +2660,13 @@ var lavali; lepturus.prototype.ferrumequinum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; lepturus.prototype.aequalis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return lepturus; @@ -3149,73 +2683,55 @@ var dogramacii; robustulus.prototype.fossor = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; robustulus.prototype.humboldti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; robustulus.prototype.mexicana = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; robustulus.prototype.martini = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; robustulus.prototype.beatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; robustulus.prototype.leporina = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; robustulus.prototype.pearsonii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; robustulus.prototype.keaysi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; robustulus.prototype.hindei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return robustulus; @@ -3227,9 +2743,7 @@ var dogramacii; koepckeae.prototype.culturatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return koepckeae; @@ -3241,105 +2755,79 @@ var dogramacii; kaiseri.prototype.bedfordiae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.paramorum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.rubidus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.juninensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.marginata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.Meitnerium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.pinetorum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.hoolock = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.poeyi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.Thulium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.patrius = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.quadraticauda = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; kaiseri.prototype.ater = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return kaiseri; @@ -3351,65 +2839,49 @@ var dogramacii; aurata.prototype.grunniens = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; aurata.prototype.howensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; aurata.prototype.karlkoopmani = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; aurata.prototype.mirapitanga = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; aurata.prototype.ophiodon = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; aurata.prototype.landeri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; aurata.prototype.sonomae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; aurata.prototype.erythromos = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return aurata; @@ -3426,113 +2898,85 @@ var lutreolus; schlegeli.prototype.mittendorfi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.blicki = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.culionensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.scrofa = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.fernandoni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.Tin = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.marmorata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.tavaratra = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.peregrina = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.frontalis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.cuniculus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.magdalenae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.andamanensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; schlegeli.prototype.dispar = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return schlegeli; @@ -3547,89 +2991,67 @@ var argurus; dauricus.prototype.chinensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.duodecimcostatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.foxi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.macleayii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.darienensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.hardwickii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.albifrons = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.jacobitus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.guentheri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.mahomet = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dauricus.prototype.misionensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return dauricus; @@ -3644,65 +3066,49 @@ var nigra; dolichurus.prototype.solomonis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dolichurus.prototype.alfredi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dolichurus.prototype.morrisi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dolichurus.prototype.lekaguli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dolichurus.prototype.dimissus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dolichurus.prototype.phaeotis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dolichurus.prototype.ustus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; dolichurus.prototype.sagei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return dolichurus; @@ -3719,49 +3125,37 @@ var panglima; amphibius.prototype.bottegi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amphibius.prototype.jerdoni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amphibius.prototype.camtschatica = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amphibius.prototype.spadix = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amphibius.prototype.luismanueli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amphibius.prototype.aceramarcae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return amphibius; @@ -3775,25 +3169,19 @@ var panglima; fundatus.prototype.crassulus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fundatus.prototype.flamarioni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fundatus.prototype.mirabilis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return fundatus; @@ -3807,41 +3195,31 @@ var panglima; abidi.prototype.greyii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; abidi.prototype.macedonicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; abidi.prototype.galili = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; abidi.prototype.thierryi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; abidi.prototype.ega = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return abidi; @@ -3856,57 +3234,43 @@ var quasiater; carolinensis.prototype.concinna = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; carolinensis.prototype.aeneus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; carolinensis.prototype.aloysiisabaudiae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; carolinensis.prototype.tenellus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; carolinensis.prototype.andium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; carolinensis.prototype.persephone = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; carolinensis.prototype.patrizii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return carolinensis; @@ -3923,97 +3287,73 @@ var minutus; himalayana.prototype.simoni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.lobata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.rusticus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.latona = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.famulus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.flaviceps = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.paradoxolophus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.Osmium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.vulgaris = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.betsileoensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.vespuccii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; himalayana.prototype.olympus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return himalayana; @@ -4030,65 +3370,49 @@ var caurinus; mahaganus.prototype.martiniquensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mahaganus.prototype.devius = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mahaganus.prototype.masalai = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mahaganus.prototype.kathleenae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mahaganus.prototype.simulus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mahaganus.prototype.nigrovittatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mahaganus.prototype.senegalensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; mahaganus.prototype.acticola = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return mahaganus; @@ -4103,9 +3427,7 @@ var macrorhinos; marmosurus.prototype.tansaniana = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return marmosurus; @@ -4122,9 +3444,7 @@ var howi; angulatus.prototype.pennatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return angulatus; @@ -4148,65 +3468,49 @@ var nigra; thalia.prototype.dichotomus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thalia.prototype.arnuxii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thalia.prototype.verheyeni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thalia.prototype.dauuricus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thalia.prototype.tristriatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thalia.prototype.lasiura = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thalia.prototype.gangetica = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; thalia.prototype.brucei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return thalia; @@ -4223,9 +3527,7 @@ var sagitta; walkeri.prototype.maracajuensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return walkeri; @@ -4242,9 +3544,7 @@ var minutus; inez.prototype.vexillaris = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return inez; @@ -4272,73 +3572,55 @@ var panamensis; linulus.prototype.goslingi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; linulus.prototype.taki = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; linulus.prototype.fumosus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; linulus.prototype.rufinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; linulus.prototype.lami = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; linulus.prototype.regina = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; linulus.prototype.nanilla = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; linulus.prototype.enganus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; linulus.prototype.gomantongensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return linulus; @@ -4353,105 +3635,79 @@ var nigra; gracilis.prototype.weddellii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.echinothrix = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.garridoi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.rouxii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.aurita = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.geoffrensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.theresa = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.melanocarpus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.dubiaquercus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.pectoralis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.apoensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.grisescens = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gracilis.prototype.ramirohitra = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return gracilis; @@ -4468,105 +3724,79 @@ var samarensis; pelurus.prototype.Palladium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.castanea = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.chamek = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.nigriceps = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.lunatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.madurae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.chinchilla = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.eliasi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.proditor = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.gambianus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.petteri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.nusatenggara = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pelurus.prototype.olitor = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return pelurus; @@ -4580,113 +3810,85 @@ var samarensis; fuscus.prototype.planifrons = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.badia = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.prymnolopha = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.natalensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.hunteri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.sapiens = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.macrocercus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.nimbae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.suricatta = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.jagorii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.beecrofti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.imaizumii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.colocolo = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; fuscus.prototype.wolfi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return fuscus; @@ -4698,33 +3900,25 @@ var samarensis; pallidus.prototype.oblativa = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pallidus.prototype.watersi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pallidus.prototype.glacialis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pallidus.prototype.viaria = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return pallidus; @@ -4736,41 +3930,31 @@ var samarensis; cahirinus.prototype.alashanicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cahirinus.prototype.flaviventer = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cahirinus.prototype.bottai = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cahirinus.prototype.pinetis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cahirinus.prototype.saussurei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return cahirinus; @@ -4787,41 +3971,31 @@ var sagitta; leptoceros.prototype.victus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; leptoceros.prototype.hoplomyoides = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; leptoceros.prototype.gratiosus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; leptoceros.prototype.rex = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; leptoceros.prototype.bolami = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return leptoceros; @@ -4838,9 +4012,7 @@ var daubentonii; nigricans.prototype.woosnami = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return nigricans; @@ -4866,25 +4038,19 @@ var argurus; pygmaea.prototype.pajeros = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pygmaea.prototype.capucinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; pygmaea.prototype.cuvieri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return pygmaea; @@ -4901,57 +4067,43 @@ var chrysaeolus; sarasinorum.prototype.belzebul = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sarasinorum.prototype.hinpoon = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sarasinorum.prototype.kandti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sarasinorum.prototype.cynosuros = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sarasinorum.prototype.Germanium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sarasinorum.prototype.Ununoctium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sarasinorum.prototype.princeps = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return sarasinorum; @@ -4966,57 +4118,43 @@ var argurus; wetmorei.prototype.leucoptera = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wetmorei.prototype.ochraventer = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wetmorei.prototype.tephromelas = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wetmorei.prototype.cracens = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wetmorei.prototype.jamaicensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wetmorei.prototype.gymnocaudus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wetmorei.prototype.mayori = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return wetmorei; @@ -5033,65 +4171,49 @@ var argurus; oreas.prototype.salamonis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oreas.prototype.paniscus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oreas.prototype.fagani = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oreas.prototype.papuanus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oreas.prototype.timidus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oreas.prototype.nghetinhensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oreas.prototype.barbei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; oreas.prototype.univittatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return oreas; @@ -5106,97 +4228,73 @@ var daubentonii; arboreus.prototype.capreolus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.moreni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.hypoleucos = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.paedulcus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.pucheranii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.stella = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.brasiliensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.brevicaudata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.vitticollis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.huangensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.cameroni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; arboreus.prototype.tianshanica = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return arboreus; @@ -5211,105 +4309,79 @@ var patas; uralensis.prototype.cartilagonodus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.pyrrhinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.insulans = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.nigricauda = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.muricauda = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.albicaudus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.fallax = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.attenuata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.megalura = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.neblina = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.citellus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.tanezumi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; uralensis.prototype.albiventer = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return uralensis; @@ -5326,17 +4398,13 @@ var provocax; melanoleuca.prototype.Neodymium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanoleuca.prototype.baeri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return melanoleuca; @@ -5351,17 +4419,13 @@ var sagitta; sicarius.prototype.Chlorine = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sicarius.prototype.simulator = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return sicarius; @@ -5378,113 +4442,85 @@ var howi; marcanoi.prototype.formosae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.dudui = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.leander = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.martinsi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.beatrix = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.griseoventer = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.zerda = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.yucatanicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.nigrita = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.jouvenetae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.indefessus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.vuquangensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.Zirconium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; marcanoi.prototype.hyaena = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return marcanoi; @@ -5499,97 +4535,73 @@ var argurus; gilbertii.prototype.nasutus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.poecilops = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.sondaicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.auriventer = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.cherriei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.lindberghi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.pipistrellus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.paranus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.dubosti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.opossum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.oreopolus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; gilbertii.prototype.amurensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return gilbertii; @@ -5613,105 +4625,79 @@ var lutreolus; punicus.prototype.strandi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.lar = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.erica = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.trichura = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.lemniscatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.aspalax = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.marshalli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.Zinc = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.monochromos = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.purinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.ischyrus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.tenuis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; punicus.prototype.Helium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return punicus; @@ -5726,49 +4712,37 @@ var macrorhinos; daphaenodon.prototype.bredanensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; daphaenodon.prototype.othus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; daphaenodon.prototype.hammondi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; daphaenodon.prototype.aureocollaris = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; daphaenodon.prototype.flavipes = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; daphaenodon.prototype.callosus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return daphaenodon; @@ -5783,97 +4757,73 @@ var sagitta; cinereus.prototype.zunigae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.microps = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.guaporensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.tonkeana = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.montensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.sphinx = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.glis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.dorsalis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.fimbriatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.sara = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.epimelas = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cinereus.prototype.pittieri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return cinereus; @@ -5905,81 +4855,61 @@ var gabriellae; amicus.prototype.pirrensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.phaeura = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.voratus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.satarae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.hooperi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.perrensi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.ridei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.audeberti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.Lutetium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; amicus.prototype.atrox = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return amicus; @@ -5991,9 +4921,7 @@ var gabriellae; echinatus.prototype.tenuipes = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return echinatus; @@ -6008,49 +4936,37 @@ var imperfecta; lasiurus.prototype.marisae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; lasiurus.prototype.fulvus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; lasiurus.prototype.paranaensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; lasiurus.prototype.didactylus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; lasiurus.prototype.schreibersii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; lasiurus.prototype.orii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return lasiurus; @@ -6062,89 +4978,67 @@ var imperfecta; subspinosus.prototype.monticularis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.Gadolinium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.oasicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.paterculus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.punctata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.invictus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.stangeri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.siskiyou = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.welwitschii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.Polonium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; subspinosus.prototype.harpia = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return subspinosus; @@ -6158,25 +5052,19 @@ var imperfecta; ciliolabrum.prototype.leschenaultii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; ciliolabrum.prototype.ludia = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; ciliolabrum.prototype.sinicus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return ciliolabrum; @@ -6191,33 +5079,25 @@ var quasiater; wattsi.prototype.lagotis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wattsi.prototype.hussoni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wattsi.prototype.bilarni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; wattsi.prototype.cabrerae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return wattsi; @@ -6234,73 +5114,55 @@ var petrophilus; sodyi.prototype.saundersiae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sodyi.prototype.imberbis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sodyi.prototype.cansdalei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sodyi.prototype.Lawrencium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sodyi.prototype.catta = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sodyi.prototype.breviceps = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sodyi.prototype.transitionalis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sodyi.prototype.heptneri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; sodyi.prototype.bairdii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return sodyi; @@ -6317,65 +5179,49 @@ var caurinus; megaphyllus.prototype.montana = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megaphyllus.prototype.amatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megaphyllus.prototype.bucculentus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megaphyllus.prototype.lepida = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megaphyllus.prototype.graecus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megaphyllus.prototype.forsteri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megaphyllus.prototype.perotensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; megaphyllus.prototype.cirrhosus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return megaphyllus; @@ -6390,25 +5236,19 @@ var minutus; portoricensis.prototype.relictus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; portoricensis.prototype.aequatorianus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; portoricensis.prototype.rhinogradoides = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return portoricensis; @@ -6423,105 +5263,79 @@ var lutreolus; foina.prototype.tarfayensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.Promethium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.salinae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.kerri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.scotti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.camerunensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.affinis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.siebersi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.maquassiensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.layardi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.bishopi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.apodemoides = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; foina.prototype.argentiventer = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return foina; @@ -6538,81 +5352,61 @@ var lutreolus; cor.prototype.antinorii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.voi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.mussoi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.truncatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.achates = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.praedatrix = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.mzabi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.xanthinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.tapoatafa = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; cor.prototype.castroviejoi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return cor; @@ -6627,17 +5421,13 @@ var howi; coludo.prototype.bernhardi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; coludo.prototype.isseli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return coludo; @@ -6654,17 +5444,13 @@ var argurus; germaini.prototype.sharpei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; germaini.prototype.palmarum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return germaini; @@ -6679,89 +5465,67 @@ var sagitta; stolzmanni.prototype.riparius = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.dhofarensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.tricolor = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.gardneri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.walleri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.talpoides = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.pallipes = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.lagurus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.hipposideros = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.griselda = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; stolzmanni.prototype.florium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return stolzmanni; @@ -6778,105 +5542,79 @@ var dammermani; melanops.prototype.blarina = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.harwoodi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.ashaninka = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.wiedii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.godmani = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.condorensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.xerophila = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.laminatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.archeri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.hidalgo = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.unicolor = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.philippii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; melanops.prototype.bocagei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return melanops; @@ -6893,65 +5631,49 @@ var argurus; peninsulae.prototype.aitkeni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; peninsulae.prototype.novaeangliae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; peninsulae.prototype.olallae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; peninsulae.prototype.anselli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; peninsulae.prototype.timminsi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; peninsulae.prototype.sordidus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; peninsulae.prototype.telfordi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; peninsulae.prototype.cavernarum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return peninsulae; @@ -6966,105 +5688,79 @@ var argurus; netscheri.prototype.gravis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.ruschii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.tricuspidatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.fernandezi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.colletti = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.microbullatus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.eburneae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.tatei = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.millardi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.pruinosus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.delator = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.nyikae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; netscheri.prototype.ruemmleri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return netscheri; @@ -7081,105 +5777,79 @@ var ruatanica; Praseodymium.prototype.clara = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.spectabilis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.kamensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.ruddi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.bartelsii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.yerbabuenae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.davidi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.pilirostris = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.catherinae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.frontata = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.Terbium = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.thomensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; Praseodymium.prototype.soricinus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return Praseodymium; @@ -7196,9 +5866,7 @@ var caurinus; johorensis.prototype.maini = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return johorensis; @@ -7213,9 +5881,7 @@ var argurus; luctuosa.prototype.loriae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return luctuosa; @@ -7230,65 +5896,49 @@ var panamensis; setulosus.prototype.duthieae = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; setulosus.prototype.guereza = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; setulosus.prototype.buselaphus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; setulosus.prototype.nuttalli = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; setulosus.prototype.pelii = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; setulosus.prototype.tunneyi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; setulosus.prototype.lamula = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; setulosus.prototype.vampyrus = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return setulosus; @@ -7303,41 +5953,31 @@ var petrophilus; rosalia.prototype.palmeri = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; rosalia.prototype.baeops = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; rosalia.prototype.ozensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; rosalia.prototype.creaghi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; rosalia.prototype.montivaga = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return rosalia; @@ -7354,49 +5994,37 @@ var caurinus; psilurus.prototype.socialis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; psilurus.prototype.lundi = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; psilurus.prototype.araeum = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; psilurus.prototype.calamianensis = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; psilurus.prototype.petersoni = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; psilurus.prototype.nitela = function () { var _this = this; var x; - (function () { - var y = _this; - }); + (function () { var y = _this; }); return x; }; return psilurus; diff --git a/tests/baselines/reference/restArgAssignmentCompat.js b/tests/baselines/reference/restArgAssignmentCompat.js index a640560c05..3f8749f332 100644 --- a/tests/baselines/reference/restArgAssignmentCompat.js +++ b/tests/baselines/reference/restArgAssignmentCompat.js @@ -15,14 +15,9 @@ function f() { for (var _i = 0; _i < arguments.length; _i++) { x[_i - 0] = arguments[_i]; } - x.forEach(function (n, i) { - return void ('item ' + i + ' = ' + n); - }); -} -function g(x, y) { + x.forEach(function (n, i) { return void ('item ' + i + ' = ' + n); }); } +function g(x, y) { } var n = g; n = f; -n([ - 4 -], 'foo'); +n([4], 'foo'); diff --git a/tests/baselines/reference/restElementMustBeLast.js b/tests/baselines/reference/restElementMustBeLast.js index 2e11ce91de..337cb6de6f 100644 --- a/tests/baselines/reference/restElementMustBeLast.js +++ b/tests/baselines/reference/restElementMustBeLast.js @@ -4,14 +4,6 @@ var [...a, x] = [1, 2, 3]; // Error, rest must be last element //// [restElementMustBeLast.js] -var _a = [ - 1, - 2, - 3 -], x = _a[1]; // Error, rest must be last element -_b = [ - 1, - 2, - 3 -], x = _b[1]; // Error, rest must be last element +var _a = [1, 2, 3], x = _a[1]; // Error, rest must be last element +_b = [1, 2, 3], x = _b[1]; // Error, rest must be last element var _b; diff --git a/tests/baselines/reference/restParameterNotLast.js b/tests/baselines/reference/restParameterNotLast.js index 791d83849a..4ca416a47e 100644 --- a/tests/baselines/reference/restParameterNotLast.js +++ b/tests/baselines/reference/restParameterNotLast.js @@ -2,5 +2,4 @@ function f(...x, y) { } //// [restParameterNotLast.js] -function f(x, y) { -} +function f(x, y) { } diff --git a/tests/baselines/reference/returnInConstructor1.js b/tests/baselines/reference/returnInConstructor1.js index 30ce79bc36..0096c4d65b 100644 --- a/tests/baselines/reference/returnInConstructor1.js +++ b/tests/baselines/reference/returnInConstructor1.js @@ -77,47 +77,39 @@ var A = (function () { function A() { return; } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); var B = (function () { function B() { return 1; // error } - B.prototype.foo = function () { - }; + B.prototype.foo = function () { }; return B; })(); var C = (function () { function C() { return this; } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); var D = (function () { function D() { return "test"; // error } - D.prototype.foo = function () { - }; + D.prototype.foo = function () { }; return D; })(); var E = (function () { function E() { - return { - foo: 1 - }; + return { foo: 1 }; } return E; })(); var F = (function () { function F() { - return { - foo: 1 - }; //error + return { foo: 1 }; //error } return F; })(); @@ -125,10 +117,8 @@ var G = (function () { function G() { this.test = 2; } - G.prototype.test1 = function () { - }; - G.prototype.foo = function () { - }; + G.prototype.test1 = function () { }; + G.prototype.foo = function () { }; return G; })(); var H = (function (_super) { diff --git a/tests/baselines/reference/returnStatements.js b/tests/baselines/reference/returnStatements.js index b968998e4d..77b6ae1f77 100644 --- a/tests/baselines/reference/returnStatements.js +++ b/tests/baselines/reference/returnStatements.js @@ -32,35 +32,18 @@ var __extends = this.__extends || function (d, b) { d.prototype = new __(); }; // all the following should be valid -function fn1() { - return 1; -} -function fn2() { - return ''; -} -function fn3() { - return undefined; -} -function fn4() { - return; -} -function fn5() { - return true; -} -function fn6() { - return new Date(12); -} -function fn7() { - return null; -} -function fn8() { - return; -} // OK, eq. to 'return undefined' +function fn1() { return 1; } +function fn2() { return ''; } +function fn3() { return undefined; } +function fn4() { return; } +function fn5() { return true; } +function fn6() { return new Date(12); } +function fn7() { return null; } +function fn8() { return; } // OK, eq. to 'return undefined' var C = (function () { function C() { } - C.prototype.dispose = function () { - }; + C.prototype.dispose = function () { }; return C; })(); var D = (function (_super) { @@ -70,17 +53,7 @@ var D = (function (_super) { } return D; })(C); -function fn10() { - return { - id: 12 - }; -} -function fn11() { - return new C(); -} -function fn12() { - return new D(); -} -function fn13() { - return null; -} +function fn10() { return { id: 12 }; } +function fn11() { return new C(); } +function fn12() { return new D(); } +function fn13() { return null; } diff --git a/tests/baselines/reference/returnTypeParameter.js b/tests/baselines/reference/returnTypeParameter.js index 5866720705..d5f46cba77 100644 --- a/tests/baselines/reference/returnTypeParameter.js +++ b/tests/baselines/reference/returnTypeParameter.js @@ -3,8 +3,5 @@ function f(a: T): T { } // error, no return statement function f2(a: T): T { return T; } // bug was that this satisfied the return statement requirement //// [returnTypeParameter.js] -function f(a) { -} // error, no return statement -function f2(a) { - return T; -} // bug was that this satisfied the return statement requirement +function f(a) { } // error, no return statement +function f2(a) { return T; } // bug was that this satisfied the return statement requirement diff --git a/tests/baselines/reference/returnTypeParameterWithModules.js b/tests/baselines/reference/returnTypeParameterWithModules.js index 2dc8da604f..4790fe1341 100644 --- a/tests/baselines/reference/returnTypeParameterWithModules.js +++ b/tests/baselines/reference/returnTypeParameterWithModules.js @@ -18,12 +18,7 @@ module M2 { var M1; (function (M1) { function reduce(ar, f, e) { - return Array.prototype.reduce.apply(ar, e ? [ - f, - e - ] : [ - f - ]); + return Array.prototype.reduce.apply(ar, e ? [f, e] : [f]); } M1.reduce = reduce; ; @@ -38,9 +33,7 @@ var M2; M2.compose = compose; ; function compose2(g, f) { - return function (x) { - return g(f(x)); - }; + return function (x) { return g(f(x)); }; } M2.compose2 = compose2; ; diff --git a/tests/baselines/reference/returnTypeTypeArguments.js b/tests/baselines/reference/returnTypeTypeArguments.js index 5be549d2f3..b374cb1c58 100644 --- a/tests/baselines/reference/returnTypeTypeArguments.js +++ b/tests/baselines/reference/returnTypeTypeArguments.js @@ -92,65 +92,31 @@ var Three = (function () { } return Three; })(); -function A1() { - return null; -} -function A2() { - return null; -} -function A3() { - return null; -} -function B1() { - return null; -} -function B2() { - return null; -} -function B3() { - return null; -} +function A1() { return null; } +function A2() { return null; } +function A3() { return null; } +function B1() { return null; } +function B2() { return null; } +function B3() { return null; } var C = (function () { function C() { } - C.prototype.A1 = function () { - return null; - }; - C.prototype.A2 = function () { - return null; - }; - C.prototype.A3 = function () { - return null; - }; - C.prototype.B1 = function () { - return null; - }; - C.prototype.B2 = function () { - return null; - }; - C.prototype.B3 = function () { - return null; - }; + C.prototype.A1 = function () { return null; }; + C.prototype.A2 = function () { return null; }; + C.prototype.A3 = function () { return null; }; + C.prototype.B1 = function () { return null; }; + C.prototype.B2 = function () { return null; }; + C.prototype.B3 = function () { return null; }; return C; })(); var D = (function () { function D() { } - D.prototype.A2 = function () { - return null; - }; - D.prototype.A3 = function () { - return null; - }; - D.prototype.B1 = function () { - return null; - }; - D.prototype.B2 = function () { - return null; - }; - D.prototype.B3 = function () { - return null; - }; + D.prototype.A2 = function () { return null; }; + D.prototype.A3 = function () { return null; }; + D.prototype.B1 = function () { return null; }; + D.prototype.B2 = function () { return null; }; + D.prototype.B3 = function () { return null; }; return D; })(); var Y = (function () { diff --git a/tests/baselines/reference/reverseInferenceInContextualInstantiation.js b/tests/baselines/reference/reverseInferenceInContextualInstantiation.js index 7108029ac5..f9c3242e1e 100644 --- a/tests/baselines/reference/reverseInferenceInContextualInstantiation.js +++ b/tests/baselines/reference/reverseInferenceInContextualInstantiation.js @@ -5,8 +5,6 @@ x.sort(compare); // Error, but shouldn't be //// [reverseInferenceInContextualInstantiation.js] -function compare(a, b) { - return 0; -} +function compare(a, b) { return 0; } var x; x.sort(compare); // Error, but shouldn't be diff --git a/tests/baselines/reference/scannertest1.js b/tests/baselines/reference/scannertest1.js index dc003e95a8..b96c965a79 100644 --- a/tests/baselines/reference/scannertest1.js +++ b/tests/baselines/reference/scannertest1.js @@ -33,11 +33,17 @@ var CharacterInfo = (function () { return c >= CharacterCodes._0 && c <= CharacterCodes._9; }; CharacterInfo.isHexDigit = function (c) { - return isDecimalDigit(c) || (c >= CharacterCodes.A && c <= CharacterCodes.F) || (c >= CharacterCodes.a && c <= CharacterCodes.f); + return isDecimalDigit(c) || + (c >= CharacterCodes.A && c <= CharacterCodes.F) || + (c >= CharacterCodes.a && c <= CharacterCodes.f); }; CharacterInfo.hexValue = function (c) { Debug.assert(isHexDigit(c)); - return isDecimalDigit(c) ? (c - CharacterCodes._0) : (c >= CharacterCodes.A && c <= CharacterCodes.F) ? c - CharacterCodes.A + 10 : c - CharacterCodes.a + 10; + return isDecimalDigit(c) + ? (c - CharacterCodes._0) + : (c >= CharacterCodes.A && c <= CharacterCodes.F) + ? c - CharacterCodes.A + 10 + : c - CharacterCodes.a + 10; }; return CharacterInfo; })(); diff --git a/tests/baselines/reference/scopingInCatchBlocks.js b/tests/baselines/reference/scopingInCatchBlocks.js index 2d3ca7098b..3121f4e9c7 100644 --- a/tests/baselines/reference/scopingInCatchBlocks.js +++ b/tests/baselines/reference/scopingInCatchBlocks.js @@ -11,17 +11,12 @@ var x = ex1; // should error //// [scopingInCatchBlocks.js] -try { -} +try { } catch (ex1) { throw ex1; } -try { -} -catch (ex1) { -} // should not error -try { -} -catch (ex1) { -} // should not error +try { } +catch (ex1) { } // should not error +try { } +catch (ex1) { } // should not error var x = ex1; // should error diff --git a/tests/baselines/reference/selfInCallback.js b/tests/baselines/reference/selfInCallback.js index 85f16390f9..25228b0318 100644 --- a/tests/baselines/reference/selfInCallback.js +++ b/tests/baselines/reference/selfInCallback.js @@ -12,14 +12,10 @@ var C = (function () { function C() { this.p1 = 0; } - C.prototype.callback = function (cb) { - cb(); - }; + C.prototype.callback = function (cb) { cb(); }; C.prototype.doit = function () { var _this = this; - this.callback(function () { - _this.p1 + 1; - }); + this.callback(function () { _this.p1 + 1; }); }; return C; })(); diff --git a/tests/baselines/reference/selfInLambdas.js b/tests/baselines/reference/selfInLambdas.js index 67006603c8..6b09cf2e22 100644 --- a/tests/baselines/reference/selfInLambdas.js +++ b/tests/baselines/reference/selfInLambdas.js @@ -53,9 +53,7 @@ var o = { var _this = this; window.onmousemove = function () { _this.counter++; - var f = function () { - return _this.counter; - }; + var f = function () { return _this.counter; }; }; } }; diff --git a/tests/baselines/reference/separate1-2.js b/tests/baselines/reference/separate1-2.js index bda277467e..6ef155ca0f 100644 --- a/tests/baselines/reference/separate1-2.js +++ b/tests/baselines/reference/separate1-2.js @@ -6,7 +6,6 @@ module X { //// [separate1-2.js] var X; (function (X) { - function f() { - } + function f() { } X.f = f; })(X || (X = {})); diff --git a/tests/baselines/reference/shadowPrivateMembers.js b/tests/baselines/reference/shadowPrivateMembers.js index 3d7e3db7ef..098a7914a7 100644 --- a/tests/baselines/reference/shadowPrivateMembers.js +++ b/tests/baselines/reference/shadowPrivateMembers.js @@ -13,8 +13,7 @@ var __extends = this.__extends || function (d, b) { var base = (function () { function base() { } - base.prototype.n = function () { - }; + base.prototype.n = function () { }; return base; })(); var derived = (function (_super) { @@ -22,7 +21,6 @@ var derived = (function (_super) { function derived() { _super.apply(this, arguments); } - derived.prototype.n = function () { - }; + derived.prototype.n = function () { }; return derived; })(base); diff --git a/tests/baselines/reference/shadowedInternalModule.js b/tests/baselines/reference/shadowedInternalModule.js index 90bbd02358..3a7c6d4d61 100644 --- a/tests/baselines/reference/shadowedInternalModule.js +++ b/tests/baselines/reference/shadowedInternalModule.js @@ -37,17 +37,11 @@ module Z { // all errors imported modules conflict with local variables var A; (function (A) { - A.Point = { - x: 0, - y: 0 - }; + A.Point = { x: 0, y: 0 }; })(A || (A = {})); var B; (function (B) { - var A = { - x: 0, - y: 0 - }; + var A = { x: 0, y: 0 }; })(B || (B = {})); var X; (function (X) { diff --git a/tests/baselines/reference/shadowingViaLocalValueOrBindingElement.js b/tests/baselines/reference/shadowingViaLocalValueOrBindingElement.js index a930f7405f..b3c44600d1 100644 --- a/tests/baselines/reference/shadowingViaLocalValueOrBindingElement.js +++ b/tests/baselines/reference/shadowingViaLocalValueOrBindingElement.js @@ -15,17 +15,9 @@ if (true) { var x_1; if (true) { var x = 0; // Error - var _a = ({ - x: 0 - }).x, x = _a === void 0 ? 0 : _a; // Error - var _b = ({ - x: 0 - }).x, x = _b === void 0 ? 0 : _b; // Error - var x = ({ - x: 0 - }).x; // Error - var x = ({ - x: 0 - }).x; // Error + var _a = ({ x: 0 }).x, x = _a === void 0 ? 0 : _a; // Error + var _b = ({ x: 0 }).x, x = _b === void 0 ? 0 : _b; // Error + var x = ({ x: 0 }).x; // Error + var x = ({ x: 0 }).x; // Error } } diff --git a/tests/baselines/reference/simpleArrowFunctionParameterReferencedInObjectLiteral1.js b/tests/baselines/reference/simpleArrowFunctionParameterReferencedInObjectLiteral1.js index 2cbc58ac19..fbf01bc167 100644 --- a/tests/baselines/reference/simpleArrowFunctionParameterReferencedInObjectLiteral1.js +++ b/tests/baselines/reference/simpleArrowFunctionParameterReferencedInObjectLiteral1.js @@ -3,10 +3,4 @@ //// [simpleArrowFunctionParameterReferencedInObjectLiteral1.js] -[].map(function () { - return [].map(function (p) { - return ({ - X: p - }); - }); -}); +[].map(function () { return [].map(function (p) { return ({ X: p }); }); }); diff --git a/tests/baselines/reference/sourceMap-FileWithComments.js b/tests/baselines/reference/sourceMap-FileWithComments.js index 6143ff95fb..e9755f6c04 100644 --- a/tests/baselines/reference/sourceMap-FileWithComments.js +++ b/tests/baselines/reference/sourceMap-FileWithComments.js @@ -48,9 +48,7 @@ var Shapes; this.y = y; } // Instance member - Point.prototype.getDist = function () { - return Math.sqrt(this.x * this.x + this.y * this.y); - }; + Point.prototype.getDist = function () { return Math.sqrt(this.x * this.x + this.y * this.y); }; // Static member Point.origin = new Point(0, 0); return Point; diff --git a/tests/baselines/reference/sourceMap-FileWithComments.js.map b/tests/baselines/reference/sourceMap-FileWithComments.js.map index 3da9be212f..fc27b8542d 100644 --- a/tests/baselines/reference/sourceMap-FileWithComments.js.map +++ b/tests/baselines/reference/sourceMap-FileWithComments.js.map @@ -1,2 +1,2 @@ //// [sourceMap-FileWithComments.js.map] -{"version":3,"file":"sourceMap-FileWithComments.js","sourceRoot":"","sources":["sourceMap-FileWithComments.ts"],"names":["Shapes","Shapes.Point","Shapes.Point.constructor","Shapes.Point.getDist","Shapes.foo"],"mappings":"AAOA,AADA,SAAS;AACT,IAAO,MAAM,CAwBZ;AAxBD,WAAO,MAAM,EAAC,CAAC;IAGXA,AADAA,QAAQA;;QAEJC,cAAcA;QACdA,eAAmBA,CAASA,EAASA,CAASA;YAA3BC,MAACA,GAADA,CAACA,CAAQA;YAASA,MAACA,GAADA,CAACA,CAAQA;QAAIA,CAACA;QAEnDD,kBAAkBA;QAClBA,uBAAOA,GAAPA;YAAYE,MAAMA,CAACA,IAAIA,CAACA,IAAIA,CAACA,IAAIA,CAACA,CAACA,GAAGA,IAAIA,CAACA,CAACA,GAAGA,IAAIA,CAACA,CAACA,GAAGA,IAAIA,CAACA,CAACA,CAACA,CAACA;QAACA,CAACA;QAElEF,gBAAgBA;QACTA,YAAMA,GAAGA,IAAIA,KAAKA,CAACA,CAACA,EAAEA,CAACA,CAACA,CAACA;QACpCA,YAACA;IAADA,CAACA,AATDD,IASCA;IATYA,YAAKA,QASjBA,CAAAA;IAGDA,AADAA,+BAA+BA;QAC3BA,CAACA,GAAGA,EAAEA,CAACA;IAEXA;IACAI,CAACA;IADeJ,UAAGA,MAClBA,CAAAA;IAKDA,AAHAA;;MAEEA;QACEA,CAACA,GAAGA,EAAEA,CAACA;AACfA,CAACA,EAxBM,MAAM,KAAN,MAAM,QAwBZ;AAGD,AADA,qBAAqB;IACjB,CAAC,GAAW,IAAI,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AACvC,IAAI,IAAI,GAAG,CAAC,CAAC,OAAO,EAAE,CAAC"} \ No newline at end of file +{"version":3,"file":"sourceMap-FileWithComments.js","sourceRoot":"","sources":["sourceMap-FileWithComments.ts"],"names":["Shapes","Shapes.Point","Shapes.Point.constructor","Shapes.Point.getDist","Shapes.foo"],"mappings":"AAOA,AADA,SAAS;AACT,IAAO,MAAM,CAwBZ;AAxBD,WAAO,MAAM,EAAC,CAAC;IAGXA,AADAA,QAAQA;;QAEJC,cAAcA;QACdA,eAAmBA,CAASA,EAASA,CAASA;YAA3BC,MAACA,GAADA,CAACA,CAAQA;YAASA,MAACA,GAADA,CAACA,CAAQA;QAAIA,CAACA;QAEnDD,kBAAkBA;QAClBA,uBAAOA,GAAPA,cAAYE,MAAMA,CAACA,IAAIA,CAACA,IAAIA,CAACA,IAAIA,CAACA,CAACA,GAAGA,IAAIA,CAACA,CAACA,GAAGA,IAAIA,CAACA,CAACA,GAAGA,IAAIA,CAACA,CAACA,CAACA,CAACA,CAACA,CAACA;QAElEF,gBAAgBA;QACTA,YAAMA,GAAGA,IAAIA,KAAKA,CAACA,CAACA,EAAEA,CAACA,CAACA,CAACA;QACpCA,YAACA;IAADA,CAACA,AATDD,IASCA;IATYA,YAAKA,QASjBA,CAAAA;IAGDA,AADAA,+BAA+BA;QAC3BA,CAACA,GAAGA,EAAEA,CAACA;IAEXA;IACAI,CAACA;IADeJ,UAAGA,MAClBA,CAAAA;IAKDA,AAHAA;;MAEEA;QACEA,CAACA,GAAGA,EAAEA,CAACA;AACfA,CAACA,EAxBM,MAAM,KAAN,MAAM,QAwBZ;AAGD,AADA,qBAAqB;IACjB,CAAC,GAAW,IAAI,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AACvC,IAAI,IAAI,GAAG,CAAC,CAAC,OAAO,EAAE,CAAC"} \ No newline at end of file diff --git a/tests/baselines/reference/sourceMap-FileWithComments.sourcemap.txt b/tests/baselines/reference/sourceMap-FileWithComments.sourcemap.txt index be00cb7f26..8283006042 100644 --- a/tests/baselines/reference/sourceMap-FileWithComments.sourcemap.txt +++ b/tests/baselines/reference/sourceMap-FileWithComments.sourcemap.txt @@ -176,7 +176,7 @@ sourceFile:sourceMap-FileWithComments.ts >>> // Instance member 1->^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^ -3 > ^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > > @@ -184,112 +184,106 @@ sourceFile:sourceMap-FileWithComments.ts 1->Emitted(11, 9) Source(15, 9) + SourceIndex(0) name (Shapes.Point) 2 >Emitted(11, 27) Source(15, 27) + SourceIndex(0) name (Shapes.Point) --- ->>> Point.prototype.getDist = function () { +>>> Point.prototype.getDist = function () { return Math.sqrt(this.x * this.x + this.y * this.y); }; 1->^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +4 > ^^^^^^^^^^^^^^ +5 > ^^^^^^ +6 > ^ +7 > ^^^^ +8 > ^ +9 > ^^^^ +10> ^ +11> ^^^^ +12> ^ +13> ^ +14> ^^^ +15> ^^^^ +16> ^ +17> ^ +18> ^^^ +19> ^^^^ +20> ^ +21> ^ +22> ^^^ +23> ^^^^ +24> ^ +25> ^ +26> ^ +27> ^ +28> ^ +29> ^ 1-> > 2 > getDist 3 > +4 > getDist() { +5 > return +6 > +7 > Math +8 > . +9 > sqrt +10> ( +11> this +12> . +13> x +14> * +15> this +16> . +17> x +18> + +19> this +20> . +21> y +22> * +23> this +24> . +25> y +26> ) +27> ; +28> +29> } 1->Emitted(12, 9) Source(16, 9) + SourceIndex(0) name (Shapes.Point) 2 >Emitted(12, 32) Source(16, 16) + SourceIndex(0) name (Shapes.Point) 3 >Emitted(12, 35) Source(16, 9) + SourceIndex(0) name (Shapes.Point) ---- ->>> return Math.sqrt(this.x * this.x + this.y * this.y); -1->^^^^^^^^^^^^ -2 > ^^^^^^ -3 > ^ -4 > ^^^^ -5 > ^ -6 > ^^^^ -7 > ^ -8 > ^^^^ -9 > ^ -10> ^ -11> ^^^ -12> ^^^^ -13> ^ -14> ^ -15> ^^^ -16> ^^^^ -17> ^ -18> ^ -19> ^^^ -20> ^^^^ -21> ^ -22> ^ -23> ^ -24> ^ -1->getDist() { -2 > return -3 > -4 > Math -5 > . -6 > sqrt -7 > ( -8 > this -9 > . -10> x -11> * -12> this -13> . -14> x -15> + -16> this -17> . -18> y -19> * -20> this -21> . -22> y -23> ) -24> ; -1->Emitted(13, 13) Source(16, 21) + SourceIndex(0) name (Shapes.Point.getDist) -2 >Emitted(13, 19) Source(16, 27) + SourceIndex(0) name (Shapes.Point.getDist) -3 >Emitted(13, 20) Source(16, 28) + SourceIndex(0) name (Shapes.Point.getDist) -4 >Emitted(13, 24) Source(16, 32) + SourceIndex(0) name (Shapes.Point.getDist) -5 >Emitted(13, 25) Source(16, 33) + SourceIndex(0) name (Shapes.Point.getDist) -6 >Emitted(13, 29) Source(16, 37) + SourceIndex(0) name (Shapes.Point.getDist) -7 >Emitted(13, 30) Source(16, 38) + SourceIndex(0) name (Shapes.Point.getDist) -8 >Emitted(13, 34) Source(16, 42) + SourceIndex(0) name (Shapes.Point.getDist) -9 >Emitted(13, 35) Source(16, 43) + SourceIndex(0) name (Shapes.Point.getDist) -10>Emitted(13, 36) Source(16, 44) + SourceIndex(0) name (Shapes.Point.getDist) -11>Emitted(13, 39) Source(16, 47) + SourceIndex(0) name (Shapes.Point.getDist) -12>Emitted(13, 43) Source(16, 51) + SourceIndex(0) name (Shapes.Point.getDist) -13>Emitted(13, 44) Source(16, 52) + SourceIndex(0) name (Shapes.Point.getDist) -14>Emitted(13, 45) Source(16, 53) + SourceIndex(0) name (Shapes.Point.getDist) -15>Emitted(13, 48) Source(16, 56) + SourceIndex(0) name (Shapes.Point.getDist) -16>Emitted(13, 52) Source(16, 60) + SourceIndex(0) name (Shapes.Point.getDist) -17>Emitted(13, 53) Source(16, 61) + SourceIndex(0) name (Shapes.Point.getDist) -18>Emitted(13, 54) Source(16, 62) + SourceIndex(0) name (Shapes.Point.getDist) -19>Emitted(13, 57) Source(16, 65) + SourceIndex(0) name (Shapes.Point.getDist) -20>Emitted(13, 61) Source(16, 69) + SourceIndex(0) name (Shapes.Point.getDist) -21>Emitted(13, 62) Source(16, 70) + SourceIndex(0) name (Shapes.Point.getDist) -22>Emitted(13, 63) Source(16, 71) + SourceIndex(0) name (Shapes.Point.getDist) -23>Emitted(13, 64) Source(16, 72) + SourceIndex(0) name (Shapes.Point.getDist) -24>Emitted(13, 65) Source(16, 73) + SourceIndex(0) name (Shapes.Point.getDist) ---- ->>> }; -1 >^^^^^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^^^-> -1 > -2 > } -1 >Emitted(14, 9) Source(16, 74) + SourceIndex(0) name (Shapes.Point.getDist) -2 >Emitted(14, 10) Source(16, 75) + SourceIndex(0) name (Shapes.Point.getDist) +4 >Emitted(12, 49) Source(16, 21) + SourceIndex(0) name (Shapes.Point.getDist) +5 >Emitted(12, 55) Source(16, 27) + SourceIndex(0) name (Shapes.Point.getDist) +6 >Emitted(12, 56) Source(16, 28) + SourceIndex(0) name (Shapes.Point.getDist) +7 >Emitted(12, 60) Source(16, 32) + SourceIndex(0) name (Shapes.Point.getDist) +8 >Emitted(12, 61) Source(16, 33) + SourceIndex(0) name (Shapes.Point.getDist) +9 >Emitted(12, 65) Source(16, 37) + SourceIndex(0) name (Shapes.Point.getDist) +10>Emitted(12, 66) Source(16, 38) + SourceIndex(0) name (Shapes.Point.getDist) +11>Emitted(12, 70) Source(16, 42) + SourceIndex(0) name (Shapes.Point.getDist) +12>Emitted(12, 71) Source(16, 43) + SourceIndex(0) name (Shapes.Point.getDist) +13>Emitted(12, 72) Source(16, 44) + SourceIndex(0) name (Shapes.Point.getDist) +14>Emitted(12, 75) Source(16, 47) + SourceIndex(0) name (Shapes.Point.getDist) +15>Emitted(12, 79) Source(16, 51) + SourceIndex(0) name (Shapes.Point.getDist) +16>Emitted(12, 80) Source(16, 52) + SourceIndex(0) name (Shapes.Point.getDist) +17>Emitted(12, 81) Source(16, 53) + SourceIndex(0) name (Shapes.Point.getDist) +18>Emitted(12, 84) Source(16, 56) + SourceIndex(0) name (Shapes.Point.getDist) +19>Emitted(12, 88) Source(16, 60) + SourceIndex(0) name (Shapes.Point.getDist) +20>Emitted(12, 89) Source(16, 61) + SourceIndex(0) name (Shapes.Point.getDist) +21>Emitted(12, 90) Source(16, 62) + SourceIndex(0) name (Shapes.Point.getDist) +22>Emitted(12, 93) Source(16, 65) + SourceIndex(0) name (Shapes.Point.getDist) +23>Emitted(12, 97) Source(16, 69) + SourceIndex(0) name (Shapes.Point.getDist) +24>Emitted(12, 98) Source(16, 70) + SourceIndex(0) name (Shapes.Point.getDist) +25>Emitted(12, 99) Source(16, 71) + SourceIndex(0) name (Shapes.Point.getDist) +26>Emitted(12, 100) Source(16, 72) + SourceIndex(0) name (Shapes.Point.getDist) +27>Emitted(12, 101) Source(16, 73) + SourceIndex(0) name (Shapes.Point.getDist) +28>Emitted(12, 102) Source(16, 74) + SourceIndex(0) name (Shapes.Point.getDist) +29>Emitted(12, 103) Source(16, 75) + SourceIndex(0) name (Shapes.Point.getDist) --- >>> // Static member -1->^^^^^^^^ +1 >^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^ 3 > ^^^^^^^^^^^^^^^^-> -1-> +1 > > > 2 > // Static member -1->Emitted(15, 9) Source(18, 9) + SourceIndex(0) name (Shapes.Point) -2 >Emitted(15, 25) Source(18, 25) + SourceIndex(0) name (Shapes.Point) +1 >Emitted(13, 9) Source(18, 9) + SourceIndex(0) name (Shapes.Point) +2 >Emitted(13, 25) Source(18, 25) + SourceIndex(0) name (Shapes.Point) --- >>> Point.origin = new Point(0, 0); 1->^^^^^^^^ @@ -315,17 +309,17 @@ sourceFile:sourceMap-FileWithComments.ts 9 > 0 10> ) 11> ; -1->Emitted(16, 9) Source(19, 16) + SourceIndex(0) name (Shapes.Point) -2 >Emitted(16, 21) Source(19, 22) + SourceIndex(0) name (Shapes.Point) -3 >Emitted(16, 24) Source(19, 25) + SourceIndex(0) name (Shapes.Point) -4 >Emitted(16, 28) Source(19, 29) + SourceIndex(0) name (Shapes.Point) -5 >Emitted(16, 33) Source(19, 34) + SourceIndex(0) name (Shapes.Point) -6 >Emitted(16, 34) Source(19, 35) + SourceIndex(0) name (Shapes.Point) -7 >Emitted(16, 35) Source(19, 36) + SourceIndex(0) name (Shapes.Point) -8 >Emitted(16, 37) Source(19, 38) + SourceIndex(0) name (Shapes.Point) -9 >Emitted(16, 38) Source(19, 39) + SourceIndex(0) name (Shapes.Point) -10>Emitted(16, 39) Source(19, 40) + SourceIndex(0) name (Shapes.Point) -11>Emitted(16, 40) Source(19, 41) + SourceIndex(0) name (Shapes.Point) +1->Emitted(14, 9) Source(19, 16) + SourceIndex(0) name (Shapes.Point) +2 >Emitted(14, 21) Source(19, 22) + SourceIndex(0) name (Shapes.Point) +3 >Emitted(14, 24) Source(19, 25) + SourceIndex(0) name (Shapes.Point) +4 >Emitted(14, 28) Source(19, 29) + SourceIndex(0) name (Shapes.Point) +5 >Emitted(14, 33) Source(19, 34) + SourceIndex(0) name (Shapes.Point) +6 >Emitted(14, 34) Source(19, 35) + SourceIndex(0) name (Shapes.Point) +7 >Emitted(14, 35) Source(19, 36) + SourceIndex(0) name (Shapes.Point) +8 >Emitted(14, 37) Source(19, 38) + SourceIndex(0) name (Shapes.Point) +9 >Emitted(14, 38) Source(19, 39) + SourceIndex(0) name (Shapes.Point) +10>Emitted(14, 39) Source(19, 40) + SourceIndex(0) name (Shapes.Point) +11>Emitted(14, 40) Source(19, 41) + SourceIndex(0) name (Shapes.Point) --- >>> return Point; 1 >^^^^^^^^ @@ -333,8 +327,8 @@ sourceFile:sourceMap-FileWithComments.ts 1 > > 2 > } -1 >Emitted(17, 9) Source(20, 5) + SourceIndex(0) name (Shapes.Point) -2 >Emitted(17, 21) Source(20, 6) + SourceIndex(0) name (Shapes.Point) +1 >Emitted(15, 9) Source(20, 5) + SourceIndex(0) name (Shapes.Point) +2 >Emitted(15, 21) Source(20, 6) + SourceIndex(0) name (Shapes.Point) --- >>> })(); 1 >^^^^ @@ -355,10 +349,10 @@ sourceFile:sourceMap-FileWithComments.ts > // Static member > static origin = new Point(0, 0); > } -1 >Emitted(18, 5) Source(20, 5) + SourceIndex(0) name (Shapes.Point) -2 >Emitted(18, 6) Source(20, 6) + SourceIndex(0) name (Shapes.Point) -3 >Emitted(18, 6) Source(11, 5) + SourceIndex(0) name (Shapes) -4 >Emitted(18, 10) Source(20, 6) + SourceIndex(0) name (Shapes) +1 >Emitted(16, 5) Source(20, 5) + SourceIndex(0) name (Shapes.Point) +2 >Emitted(16, 6) Source(20, 6) + SourceIndex(0) name (Shapes.Point) +3 >Emitted(16, 6) Source(11, 5) + SourceIndex(0) name (Shapes) +4 >Emitted(16, 10) Source(20, 6) + SourceIndex(0) name (Shapes) --- >>> Shapes.Point = Point; 1->^^^^ @@ -379,10 +373,10 @@ sourceFile:sourceMap-FileWithComments.ts > static origin = new Point(0, 0); > } 4 > -1->Emitted(19, 5) Source(11, 18) + SourceIndex(0) name (Shapes) -2 >Emitted(19, 17) Source(11, 23) + SourceIndex(0) name (Shapes) -3 >Emitted(19, 25) Source(20, 6) + SourceIndex(0) name (Shapes) -4 >Emitted(19, 26) Source(20, 6) + SourceIndex(0) name (Shapes) +1->Emitted(17, 5) Source(11, 18) + SourceIndex(0) name (Shapes) +2 >Emitted(17, 17) Source(11, 23) + SourceIndex(0) name (Shapes) +3 >Emitted(17, 25) Source(20, 6) + SourceIndex(0) name (Shapes) +4 >Emitted(17, 26) Source(20, 6) + SourceIndex(0) name (Shapes) --- >>> // Variable comment after class 1->^^^^ @@ -394,9 +388,9 @@ sourceFile:sourceMap-FileWithComments.ts > 2 > 3 > // Variable comment after class -1->Emitted(20, 5) Source(23, 5) + SourceIndex(0) name (Shapes) -2 >Emitted(20, 5) Source(22, 5) + SourceIndex(0) name (Shapes) -3 >Emitted(20, 36) Source(22, 36) + SourceIndex(0) name (Shapes) +1->Emitted(18, 5) Source(23, 5) + SourceIndex(0) name (Shapes) +2 >Emitted(18, 5) Source(22, 5) + SourceIndex(0) name (Shapes) +3 >Emitted(18, 36) Source(22, 36) + SourceIndex(0) name (Shapes) --- >>> var a = 10; 1 >^^^^^^^^ @@ -411,11 +405,11 @@ sourceFile:sourceMap-FileWithComments.ts 3 > = 4 > 10 5 > ; -1 >Emitted(21, 9) Source(23, 9) + SourceIndex(0) name (Shapes) -2 >Emitted(21, 10) Source(23, 10) + SourceIndex(0) name (Shapes) -3 >Emitted(21, 13) Source(23, 13) + SourceIndex(0) name (Shapes) -4 >Emitted(21, 15) Source(23, 15) + SourceIndex(0) name (Shapes) -5 >Emitted(21, 16) Source(23, 16) + SourceIndex(0) name (Shapes) +1 >Emitted(19, 9) Source(23, 9) + SourceIndex(0) name (Shapes) +2 >Emitted(19, 10) Source(23, 10) + SourceIndex(0) name (Shapes) +3 >Emitted(19, 13) Source(23, 13) + SourceIndex(0) name (Shapes) +4 >Emitted(19, 15) Source(23, 15) + SourceIndex(0) name (Shapes) +5 >Emitted(19, 16) Source(23, 16) + SourceIndex(0) name (Shapes) --- >>> function foo() { 1->^^^^ @@ -423,7 +417,7 @@ sourceFile:sourceMap-FileWithComments.ts 1-> > > -1->Emitted(22, 5) Source(25, 5) + SourceIndex(0) name (Shapes) +1->Emitted(20, 5) Source(25, 5) + SourceIndex(0) name (Shapes) --- >>> } 1->^^^^ @@ -432,8 +426,8 @@ sourceFile:sourceMap-FileWithComments.ts 1->export function foo() { > 2 > } -1->Emitted(23, 5) Source(26, 5) + SourceIndex(0) name (Shapes.foo) -2 >Emitted(23, 6) Source(26, 6) + SourceIndex(0) name (Shapes.foo) +1->Emitted(21, 5) Source(26, 5) + SourceIndex(0) name (Shapes.foo) +2 >Emitted(21, 6) Source(26, 6) + SourceIndex(0) name (Shapes.foo) --- >>> Shapes.foo = foo; 1->^^^^ @@ -446,10 +440,10 @@ sourceFile:sourceMap-FileWithComments.ts 3 > () { > } 4 > -1->Emitted(24, 5) Source(25, 21) + SourceIndex(0) name (Shapes) -2 >Emitted(24, 15) Source(25, 24) + SourceIndex(0) name (Shapes) -3 >Emitted(24, 21) Source(26, 6) + SourceIndex(0) name (Shapes) -4 >Emitted(24, 22) Source(26, 6) + SourceIndex(0) name (Shapes) +1->Emitted(22, 5) Source(25, 21) + SourceIndex(0) name (Shapes) +2 >Emitted(22, 15) Source(25, 24) + SourceIndex(0) name (Shapes) +3 >Emitted(22, 21) Source(26, 6) + SourceIndex(0) name (Shapes) +4 >Emitted(22, 22) Source(26, 6) + SourceIndex(0) name (Shapes) --- >>> /** comment after function 1->^^^^ @@ -462,8 +456,8 @@ sourceFile:sourceMap-FileWithComments.ts > */ > 2 > -1->Emitted(25, 5) Source(31, 5) + SourceIndex(0) name (Shapes) -2 >Emitted(25, 5) Source(28, 5) + SourceIndex(0) name (Shapes) +1->Emitted(23, 5) Source(31, 5) + SourceIndex(0) name (Shapes) +2 >Emitted(23, 5) Source(28, 5) + SourceIndex(0) name (Shapes) --- >>> * this is another comment >>> */ @@ -472,7 +466,7 @@ sourceFile:sourceMap-FileWithComments.ts 1->/** comment after function > * this is another comment > */ -1->Emitted(27, 7) Source(30, 7) + SourceIndex(0) name (Shapes) +1->Emitted(25, 7) Source(30, 7) + SourceIndex(0) name (Shapes) --- >>> var b = 10; 1->^^^^^^^^ @@ -487,11 +481,11 @@ sourceFile:sourceMap-FileWithComments.ts 3 > = 4 > 10 5 > ; -1->Emitted(28, 9) Source(31, 9) + SourceIndex(0) name (Shapes) -2 >Emitted(28, 10) Source(31, 10) + SourceIndex(0) name (Shapes) -3 >Emitted(28, 13) Source(31, 13) + SourceIndex(0) name (Shapes) -4 >Emitted(28, 15) Source(31, 15) + SourceIndex(0) name (Shapes) -5 >Emitted(28, 16) Source(31, 16) + SourceIndex(0) name (Shapes) +1->Emitted(26, 9) Source(31, 9) + SourceIndex(0) name (Shapes) +2 >Emitted(26, 10) Source(31, 10) + SourceIndex(0) name (Shapes) +3 >Emitted(26, 13) Source(31, 13) + SourceIndex(0) name (Shapes) +4 >Emitted(26, 15) Source(31, 15) + SourceIndex(0) name (Shapes) +5 >Emitted(26, 16) Source(31, 16) + SourceIndex(0) name (Shapes) --- >>>})(Shapes || (Shapes = {})); 1-> @@ -533,13 +527,13 @@ sourceFile:sourceMap-FileWithComments.ts > */ > var b = 10; > } -1->Emitted(29, 1) Source(32, 1) + SourceIndex(0) name (Shapes) -2 >Emitted(29, 2) Source(32, 2) + SourceIndex(0) name (Shapes) -3 >Emitted(29, 4) Source(8, 8) + SourceIndex(0) -4 >Emitted(29, 10) Source(8, 14) + SourceIndex(0) -5 >Emitted(29, 15) Source(8, 8) + SourceIndex(0) -6 >Emitted(29, 21) Source(8, 14) + SourceIndex(0) -7 >Emitted(29, 29) Source(32, 2) + SourceIndex(0) +1->Emitted(27, 1) Source(32, 1) + SourceIndex(0) name (Shapes) +2 >Emitted(27, 2) Source(32, 2) + SourceIndex(0) name (Shapes) +3 >Emitted(27, 4) Source(8, 8) + SourceIndex(0) +4 >Emitted(27, 10) Source(8, 14) + SourceIndex(0) +5 >Emitted(27, 15) Source(8, 8) + SourceIndex(0) +6 >Emitted(27, 21) Source(8, 14) + SourceIndex(0) +7 >Emitted(27, 29) Source(32, 2) + SourceIndex(0) --- >>>/** Local Variable */ 1 > @@ -552,9 +546,9 @@ sourceFile:sourceMap-FileWithComments.ts > 2 > 3 >/** Local Variable */ -1 >Emitted(30, 1) Source(35, 1) + SourceIndex(0) -2 >Emitted(30, 1) Source(34, 1) + SourceIndex(0) -3 >Emitted(30, 22) Source(34, 22) + SourceIndex(0) +1 >Emitted(28, 1) Source(35, 1) + SourceIndex(0) +2 >Emitted(28, 1) Source(34, 1) + SourceIndex(0) +3 >Emitted(28, 22) Source(34, 22) + SourceIndex(0) --- >>>var p = new Shapes.Point(3, 4); 1->^^^^ @@ -584,19 +578,19 @@ sourceFile:sourceMap-FileWithComments.ts 11> 4 12> ) 13> ; -1->Emitted(31, 5) Source(35, 5) + SourceIndex(0) -2 >Emitted(31, 6) Source(35, 6) + SourceIndex(0) -3 >Emitted(31, 9) Source(35, 17) + SourceIndex(0) -4 >Emitted(31, 13) Source(35, 21) + SourceIndex(0) -5 >Emitted(31, 19) Source(35, 27) + SourceIndex(0) -6 >Emitted(31, 20) Source(35, 28) + SourceIndex(0) -7 >Emitted(31, 25) Source(35, 33) + SourceIndex(0) -8 >Emitted(31, 26) Source(35, 34) + SourceIndex(0) -9 >Emitted(31, 27) Source(35, 35) + SourceIndex(0) -10>Emitted(31, 29) Source(35, 37) + SourceIndex(0) -11>Emitted(31, 30) Source(35, 38) + SourceIndex(0) -12>Emitted(31, 31) Source(35, 39) + SourceIndex(0) -13>Emitted(31, 32) Source(35, 40) + SourceIndex(0) +1->Emitted(29, 5) Source(35, 5) + SourceIndex(0) +2 >Emitted(29, 6) Source(35, 6) + SourceIndex(0) +3 >Emitted(29, 9) Source(35, 17) + SourceIndex(0) +4 >Emitted(29, 13) Source(35, 21) + SourceIndex(0) +5 >Emitted(29, 19) Source(35, 27) + SourceIndex(0) +6 >Emitted(29, 20) Source(35, 28) + SourceIndex(0) +7 >Emitted(29, 25) Source(35, 33) + SourceIndex(0) +8 >Emitted(29, 26) Source(35, 34) + SourceIndex(0) +9 >Emitted(29, 27) Source(35, 35) + SourceIndex(0) +10>Emitted(29, 29) Source(35, 37) + SourceIndex(0) +11>Emitted(29, 30) Source(35, 38) + SourceIndex(0) +12>Emitted(29, 31) Source(35, 39) + SourceIndex(0) +13>Emitted(29, 32) Source(35, 40) + SourceIndex(0) --- >>>var dist = p.getDist(); 1 > @@ -619,14 +613,14 @@ sourceFile:sourceMap-FileWithComments.ts 7 > getDist 8 > () 9 > ; -1 >Emitted(32, 1) Source(36, 1) + SourceIndex(0) -2 >Emitted(32, 5) Source(36, 5) + SourceIndex(0) -3 >Emitted(32, 9) Source(36, 9) + SourceIndex(0) -4 >Emitted(32, 12) Source(36, 12) + SourceIndex(0) -5 >Emitted(32, 13) Source(36, 13) + SourceIndex(0) -6 >Emitted(32, 14) Source(36, 14) + SourceIndex(0) -7 >Emitted(32, 21) Source(36, 21) + SourceIndex(0) -8 >Emitted(32, 23) Source(36, 23) + SourceIndex(0) -9 >Emitted(32, 24) Source(36, 24) + SourceIndex(0) +1 >Emitted(30, 1) Source(36, 1) + SourceIndex(0) +2 >Emitted(30, 5) Source(36, 5) + SourceIndex(0) +3 >Emitted(30, 9) Source(36, 9) + SourceIndex(0) +4 >Emitted(30, 12) Source(36, 12) + SourceIndex(0) +5 >Emitted(30, 13) Source(36, 13) + SourceIndex(0) +6 >Emitted(30, 14) Source(36, 14) + SourceIndex(0) +7 >Emitted(30, 21) Source(36, 21) + SourceIndex(0) +8 >Emitted(30, 23) Source(36, 23) + SourceIndex(0) +9 >Emitted(30, 24) Source(36, 24) + SourceIndex(0) --- >>>//# sourceMappingURL=sourceMap-FileWithComments.js.map \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js index 33efe0fabe..486cdd3963 100644 --- a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js +++ b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js @@ -9,9 +9,7 @@ var Greeter = (function () { function Greeter() { var _this = this; this.a = 10; - this.returnA = function () { - return _this.a; - }; + this.returnA = function () { return _this.a; }; } return Greeter; })(); diff --git a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js.map b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js.map index d085c2f9cc..b0325217c7 100644 --- a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js.map +++ b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js.map @@ -1,2 +1,2 @@ //// [sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js.map] -{"version":3,"file":"sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js","sourceRoot":"","sources":["sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.ts"],"names":["Greeter","Greeter.constructor"],"mappings":"AAAA;IAAAA;QAAAC,iBAGCA;QAFUA,MAACA,GAAGA,EAAEA,CAACA;QACPA,YAAOA,GAAGA;mBAAMA,KAAIA,CAACA,CAACA;QAANA,CAAMA,CAACA;IAClCA,CAACA;IAADD,cAACA;AAADA,CAACA,AAHD,IAGC"} \ No newline at end of file +{"version":3,"file":"sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js","sourceRoot":"","sources":["sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.ts"],"names":["Greeter","Greeter.constructor"],"mappings":"AAAA;IAAAA;QAAAC,iBAGCA;QAFUA,MAACA,GAAGA,EAAEA,CAACA;QACPA,YAAOA,GAAGA,cAAMA,OAAAA,KAAIA,CAACA,CAACA,EAANA,CAAMA,CAACA;IAClCA,CAACA;IAADD,cAACA;AAADA,CAACA,AAHD,IAGC"} \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.sourcemap.txt b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.sourcemap.txt index ff4d526ffc..555f1c096c 100644 --- a/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.sourcemap.txt +++ b/tests/baselines/reference/sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.sourcemap.txt @@ -37,7 +37,7 @@ sourceFile:sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatemen 3 > ^^^ 4 > ^^ 5 > ^ -6 > ^^^^^^^^^^^^^^^^^-> +6 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > 2 > a 3 > = @@ -49,43 +49,41 @@ sourceFile:sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatemen 4 >Emitted(4, 20) Source(2, 18) + SourceIndex(0) name (Greeter.constructor) 5 >Emitted(4, 21) Source(2, 19) + SourceIndex(0) name (Greeter.constructor) --- ->>> this.returnA = function () { +>>> this.returnA = function () { return _this.a; }; 1->^^^^^^^^ 2 > ^^^^^^^^^^^^ 3 > ^^^ -4 > ^^^^^-> +4 > ^^^^^^^^^^^^^^ +5 > ^^^^^^^ +6 > ^^^^^ +7 > ^ +8 > ^ +9 > ^^ +10> ^ +11> ^ 1-> > public 2 > returnA 3 > = +4 > () => +5 > +6 > this +7 > . +8 > a +9 > +10> this.a +11> ; 1->Emitted(5, 9) Source(3, 12) + SourceIndex(0) name (Greeter.constructor) 2 >Emitted(5, 21) Source(3, 19) + SourceIndex(0) name (Greeter.constructor) 3 >Emitted(5, 24) Source(3, 22) + SourceIndex(0) name (Greeter.constructor) ---- ->>> return _this.a; -1->^^^^^^^^^^^^^^^^^^^ -2 > ^^^^^ -3 > ^ -4 > ^ -1->() => -2 > this -3 > . -4 > a -1->Emitted(6, 20) Source(3, 28) + SourceIndex(0) name (Greeter.constructor) -2 >Emitted(6, 25) Source(3, 32) + SourceIndex(0) name (Greeter.constructor) -3 >Emitted(6, 26) Source(3, 33) + SourceIndex(0) name (Greeter.constructor) -4 >Emitted(6, 27) Source(3, 34) + SourceIndex(0) name (Greeter.constructor) ---- ->>> }; -1 >^^^^^^^^ -2 > ^ -3 > ^ -1 > -2 > this.a -3 > ; -1 >Emitted(7, 9) Source(3, 28) + SourceIndex(0) name (Greeter.constructor) -2 >Emitted(7, 10) Source(3, 34) + SourceIndex(0) name (Greeter.constructor) -3 >Emitted(7, 11) Source(3, 35) + SourceIndex(0) name (Greeter.constructor) +4 >Emitted(5, 38) Source(3, 28) + SourceIndex(0) name (Greeter.constructor) +5 >Emitted(5, 45) Source(3, 28) + SourceIndex(0) name (Greeter.constructor) +6 >Emitted(5, 50) Source(3, 32) + SourceIndex(0) name (Greeter.constructor) +7 >Emitted(5, 51) Source(3, 33) + SourceIndex(0) name (Greeter.constructor) +8 >Emitted(5, 52) Source(3, 34) + SourceIndex(0) name (Greeter.constructor) +9 >Emitted(5, 54) Source(3, 28) + SourceIndex(0) name (Greeter.constructor) +10>Emitted(5, 55) Source(3, 34) + SourceIndex(0) name (Greeter.constructor) +11>Emitted(5, 56) Source(3, 35) + SourceIndex(0) name (Greeter.constructor) --- >>> } 1 >^^^^ @@ -94,16 +92,16 @@ sourceFile:sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatemen 1 > > 2 > } -1 >Emitted(8, 5) Source(4, 1) + SourceIndex(0) name (Greeter.constructor) -2 >Emitted(8, 6) Source(4, 2) + SourceIndex(0) name (Greeter.constructor) +1 >Emitted(6, 5) Source(4, 1) + SourceIndex(0) name (Greeter.constructor) +2 >Emitted(6, 6) Source(4, 2) + SourceIndex(0) name (Greeter.constructor) --- >>> return Greeter; 1->^^^^ 2 > ^^^^^^^^^^^^^^ 1-> 2 > } -1->Emitted(9, 5) Source(4, 1) + SourceIndex(0) name (Greeter) -2 >Emitted(9, 19) Source(4, 2) + SourceIndex(0) name (Greeter) +1->Emitted(7, 5) Source(4, 1) + SourceIndex(0) name (Greeter) +2 >Emitted(7, 19) Source(4, 2) + SourceIndex(0) name (Greeter) --- >>>})(); 1 > @@ -118,9 +116,9 @@ sourceFile:sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatemen > public a = 10; > public returnA = () => this.a; > } -1 >Emitted(10, 1) Source(4, 1) + SourceIndex(0) name (Greeter) -2 >Emitted(10, 2) Source(4, 2) + SourceIndex(0) name (Greeter) -3 >Emitted(10, 2) Source(1, 1) + SourceIndex(0) -4 >Emitted(10, 6) Source(4, 2) + SourceIndex(0) +1 >Emitted(8, 1) Source(4, 1) + SourceIndex(0) name (Greeter) +2 >Emitted(8, 2) Source(4, 2) + SourceIndex(0) name (Greeter) +3 >Emitted(8, 2) Source(1, 1) + SourceIndex(0) +4 >Emitted(8, 6) Source(4, 2) + SourceIndex(0) --- >>>//# sourceMappingURL=sourceMapValidationClassWithDefaultConstructorAndCapturedThisStatement.js.map \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationFunctionExpressions.js b/tests/baselines/reference/sourceMapValidationFunctionExpressions.js index 5aa2c9902e..f215c5071e 100644 --- a/tests/baselines/reference/sourceMapValidationFunctionExpressions.js +++ b/tests/baselines/reference/sourceMapValidationFunctionExpressions.js @@ -14,7 +14,5 @@ var greet = function (greeting) { return greetings; }; greet("Hello"); -var incrGreetings = function () { - return greetings++; -}; +var incrGreetings = function () { return greetings++; }; //# sourceMappingURL=sourceMapValidationFunctionExpressions.js.map \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationFunctionExpressions.js.map b/tests/baselines/reference/sourceMapValidationFunctionExpressions.js.map index a55cd03c9e..0ab0bdac14 100644 --- a/tests/baselines/reference/sourceMapValidationFunctionExpressions.js.map +++ b/tests/baselines/reference/sourceMapValidationFunctionExpressions.js.map @@ -1,2 +1,2 @@ //// [sourceMapValidationFunctionExpressions.js.map] -{"version":3,"file":"sourceMapValidationFunctionExpressions.js","sourceRoot":"","sources":["sourceMapValidationFunctionExpressions.ts"],"names":[],"mappings":"AAAA,IAAI,SAAS,GAAG,CAAC,CAAC;AAClB,IAAI,KAAK,GAAG,UAAC,QAAgB;IACzB,SAAS,EAAE,CAAC;IACZ,MAAM,CAAC,SAAS,CAAC;AACrB,CAAC,CAAA;AACD,KAAK,CAAC,OAAO,CAAC,CAAC;AACf,IAAI,aAAa,GAAG;WAAM,SAAS,EAAE;AAAX,CAAW,CAAC"} \ No newline at end of file +{"version":3,"file":"sourceMapValidationFunctionExpressions.js","sourceRoot":"","sources":["sourceMapValidationFunctionExpressions.ts"],"names":[],"mappings":"AAAA,IAAI,SAAS,GAAG,CAAC,CAAC;AAClB,IAAI,KAAK,GAAG,UAAC,QAAgB;IACzB,SAAS,EAAE,CAAC;IACZ,MAAM,CAAC,SAAS,CAAC;AACrB,CAAC,CAAA;AACD,KAAK,CAAC,OAAO,CAAC,CAAC;AACf,IAAI,aAAa,GAAG,cAAM,OAAA,SAAS,EAAE,EAAX,CAAW,CAAC"} \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationFunctionExpressions.sourcemap.txt b/tests/baselines/reference/sourceMapValidationFunctionExpressions.sourcemap.txt index d745903daf..722afe1f9d 100644 --- a/tests/baselines/reference/sourceMapValidationFunctionExpressions.sourcemap.txt +++ b/tests/baselines/reference/sourceMapValidationFunctionExpressions.sourcemap.txt @@ -104,7 +104,7 @@ sourceFile:sourceMapValidationFunctionExpressions.ts 4 > ^^^^^^^ 5 > ^ 6 > ^ -7 > ^^^^^^^^^^^^^^^^^^^-> +7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > 2 >greet @@ -119,43 +119,41 @@ sourceFile:sourceMapValidationFunctionExpressions.ts 5 >Emitted(6, 15) Source(6, 15) + SourceIndex(0) 6 >Emitted(6, 16) Source(6, 16) + SourceIndex(0) --- ->>>var incrGreetings = function () { +>>>var incrGreetings = function () { return greetings++; }; 1-> 2 >^^^^ 3 > ^^^^^^^^^^^^^ 4 > ^^^ -5 > ^^^^-> +5 > ^^^^^^^^^^^^^^ +6 > ^^^^^^^ +7 > ^^^^^^^^^ +8 > ^^ +9 > ^^ +10> ^ +11> ^ +12> ^^^^^^^^^-> 1-> > 2 >var 3 > incrGreetings 4 > = +5 > () => +6 > +7 > greetings +8 > ++ +9 > +10> greetings++ +11> ; 1->Emitted(7, 1) Source(7, 1) + SourceIndex(0) 2 >Emitted(7, 5) Source(7, 5) + SourceIndex(0) 3 >Emitted(7, 18) Source(7, 18) + SourceIndex(0) 4 >Emitted(7, 21) Source(7, 21) + SourceIndex(0) ---- ->>> return greetings++; -1->^^^^^^^^^^^ -2 > ^^^^^^^^^ -3 > ^^ -1->() => -2 > greetings -3 > ++ -1->Emitted(8, 12) Source(7, 27) + SourceIndex(0) -2 >Emitted(8, 21) Source(7, 36) + SourceIndex(0) -3 >Emitted(8, 23) Source(7, 38) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >greetings++ -3 > ; -1 >Emitted(9, 1) Source(7, 27) + SourceIndex(0) -2 >Emitted(9, 2) Source(7, 38) + SourceIndex(0) -3 >Emitted(9, 3) Source(7, 39) + SourceIndex(0) +5 >Emitted(7, 35) Source(7, 27) + SourceIndex(0) +6 >Emitted(7, 42) Source(7, 27) + SourceIndex(0) +7 >Emitted(7, 51) Source(7, 36) + SourceIndex(0) +8 >Emitted(7, 53) Source(7, 38) + SourceIndex(0) +9 >Emitted(7, 55) Source(7, 27) + SourceIndex(0) +10>Emitted(7, 56) Source(7, 38) + SourceIndex(0) +11>Emitted(7, 57) Source(7, 39) + SourceIndex(0) --- >>>//# sourceMappingURL=sourceMapValidationFunctionExpressions.js.map \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.js b/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.js index be4c5bbf08..289d29d02b 100644 --- a/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.js +++ b/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.js @@ -2,8 +2,5 @@ var x = { n() { } }; //// [sourceMapValidationFunctionPropertyAssignment.js] -var x = { - n: function () { - } -}; +var x = { n: function () { } }; //# sourceMappingURL=sourceMapValidationFunctionPropertyAssignment.js.map \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.js.map b/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.js.map index 9ff69d2192..81066a66ba 100644 --- a/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.js.map +++ b/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.js.map @@ -1,2 +1,2 @@ //// [sourceMapValidationFunctionPropertyAssignment.js.map] -{"version":3,"file":"sourceMapValidationFunctionPropertyAssignment.js","sourceRoot":"","sources":["sourceMapValidationFunctionPropertyAssignment.ts"],"names":["n"],"mappings":"AAAA,IAAI,CAAC,GAAG;IAAE,CAAC;IAAKA,CAACA;CAAE,CAAC"} \ No newline at end of file +{"version":3,"file":"sourceMapValidationFunctionPropertyAssignment.js","sourceRoot":"","sources":["sourceMapValidationFunctionPropertyAssignment.ts"],"names":["n"],"mappings":"AAAA,IAAI,CAAC,GAAG,EAAE,CAAC,gBAAKA,CAACA,EAAE,CAAC"} \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.sourcemap.txt b/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.sourcemap.txt index 3595fcebf3..52a8bfe688 100644 --- a/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.sourcemap.txt +++ b/tests/baselines/reference/sourceMapValidationFunctionPropertyAssignment.sourcemap.txt @@ -8,45 +8,37 @@ sources: sourceMapValidationFunctionPropertyAssignment.ts emittedFile:tests/cases/compiler/sourceMapValidationFunctionPropertyAssignment.js sourceFile:sourceMapValidationFunctionPropertyAssignment.ts ------------------------------------------------------------------- ->>>var x = { +>>>var x = { n: function () { } }; 1 > 2 >^^^^ 3 > ^ 4 > ^^^ -5 > ^^^^^^^^^^^^^-> +5 > ^^ +6 > ^ +7 > ^^^^^^^^^^^^^^^^ +8 > ^ +9 > ^^ +10> ^ +11> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > 2 >var 3 > x 4 > = +5 > { +6 > n +7 > () { +8 > } +9 > } +10> ; 1 >Emitted(1, 1) Source(1, 1) + SourceIndex(0) 2 >Emitted(1, 5) Source(1, 5) + SourceIndex(0) 3 >Emitted(1, 6) Source(1, 6) + SourceIndex(0) 4 >Emitted(1, 9) Source(1, 9) + SourceIndex(0) ---- ->>> n: function () { -1->^^^^ -2 > ^ -3 > ^-> -1->{ -2 > n -1->Emitted(2, 5) Source(1, 11) + SourceIndex(0) -2 >Emitted(2, 6) Source(1, 12) + SourceIndex(0) ---- ->>> } -1->^^^^ -2 > ^ -1->() { -2 > } -1->Emitted(3, 5) Source(1, 17) + SourceIndex(0) name (n) -2 >Emitted(3, 6) Source(1, 18) + SourceIndex(0) name (n) ---- ->>>}; -1 >^ -2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > } -2 > ; -1 >Emitted(4, 2) Source(1, 20) + SourceIndex(0) -2 >Emitted(4, 3) Source(1, 21) + SourceIndex(0) +5 >Emitted(1, 11) Source(1, 11) + SourceIndex(0) +6 >Emitted(1, 12) Source(1, 12) + SourceIndex(0) +7 >Emitted(1, 28) Source(1, 17) + SourceIndex(0) name (n) +8 >Emitted(1, 29) Source(1, 18) + SourceIndex(0) name (n) +9 >Emitted(1, 31) Source(1, 20) + SourceIndex(0) +10>Emitted(1, 32) Source(1, 21) + SourceIndex(0) --- >>>//# sourceMappingURL=sourceMapValidationFunctionPropertyAssignment.js.map \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationStatements.js b/tests/baselines/reference/sourceMapValidationStatements.js index 85a4dc3388..8a4b565e9b 100644 --- a/tests/baselines/reference/sourceMapValidationStatements.js +++ b/tests/baselines/reference/sourceMapValidationStatements.js @@ -136,22 +136,19 @@ function f() { z = 10; } switch (obj.z) { - case 0: - { - x++; - break; - } - case 1: - { - x--; - break; - } - default: - { - x *= 2; - x = 50; - break; - } + case 0: { + x++; + break; + } + case 1: { + x--; + break; + } + default: { + x *= 2; + x = 50; + break; + } } while (x < 10) { x++; diff --git a/tests/baselines/reference/sourceMapValidationStatements.js.map b/tests/baselines/reference/sourceMapValidationStatements.js.map index 6373175106..a1ea3b1db7 100644 --- a/tests/baselines/reference/sourceMapValidationStatements.js.map +++ b/tests/baselines/reference/sourceMapValidationStatements.js.map @@ -1,2 +1,2 @@ //// [sourceMapValidationStatements.js.map] -{"version":3,"file":"sourceMapValidationStatements.js","sourceRoot":"","sources":["sourceMapValidationStatements.ts"],"names":["f"],"mappings":"AAAA;IACIA,IAAIA,CAACA,CAACA;IACNA,IAAIA,CAACA,GAAGA,CAACA,CAACA;IACVA,GAAGA,CAACA,CAACA,GAAGA,CAACA,CAACA,GAAGA,CAACA,EAAEA,CAACA,GAAGA,EAAEA,EAAEA,CAACA,EAAEA,EAAEA,CAACA;QAC1BA,CAACA,IAAIA,CAACA,CAACA;QACPA,CAACA,IAAIA,CAACA,CAACA;IACXA,CAACA;IACDA,EAAEA,CAACA,CAACA,CAACA,GAAGA,EAAEA,CAACA,CAACA,CAACA;QACTA,CAACA,IAAIA,CAACA,CAACA;IACXA,CAACA;IAACA,IAAIA,CAACA,CAACA;QACJA,CAACA,IAAIA,EAAEA,CAACA;QACRA,CAACA,EAAEA,CAACA;IACRA,CAACA;IACDA,IAAIA,CAACA,GAAGA;QACJA,CAACA;QACDA,CAACA;QACDA,CAACA;KACJA,CAACA;IACFA,IAAIA,GAAGA,GAAGA;QACNA,CAACA,EAAEA,CAACA;QACJA,CAACA,EAAEA,OAAOA;KACbA,CAACA;IACFA,GAAGA,CAACA,CAACA,GAAGA,CAACA,CAACA,IAAIA,CAACA,CAACA,CAACA,CAACA;QACdA,GAAGA,CAACA,CAACA,GAAGA,CAACA,CAACA,CAACA,CAACA,CAACA;QACbA,IAAIA,CAACA,GAAGA,EAAEA,CAACA;IACfA,CAACA;IACDA,IAAIA,CAACA;QACDA,GAAGA,CAACA,CAACA,GAAGA,MAAMA,CAACA;IACnBA,CAAEA;IAAAA,KAAKA,CAACA,CAACA,CAACA,CAACA,CAACA,CAACA;QACTA,EAAEA,CAACA,CAACA,GAAGA,CAACA,CAACA,GAAGA,EAAEA,CAACA,CAACA,CAACA;YACbA,GAAGA,CAACA,CAACA,GAAGA,EAAEA,CAACA;QACfA,CAACA;QAACA,IAAIA,CAACA,CAACA;YACJA,GAAGA,CAACA,CAACA,GAAGA,KAAKA,CAACA;QAClBA,CAACA;IACLA,CAACA;IACDA,IAAIA,CAACA;QACDA,MAAMA,IAAIA,KAAKA,EAAEA,CAACA;IACtBA,CAAEA;IAAAA,KAAKA,CAACA,CAACA,EAAEA,CAACA,CAACA,CAACA;QACVA,IAAIA,CAACA,GAAGA,EAAEA,CAACA;IACfA,CAACA;YAASA,CAACA;QACPA,CAACA,GAAGA,EAAEA,CAACA;IACXA,CAACA;IACDA,MAAMA,GAAGA,EAAEA,CAACA;QACRA,CAACA,GAAGA,CAACA,CAACA;QACNA,CAACA,GAAGA,EAAEA,CAACA;IACXA,CAACA;IACDA,MAAMA,CAACA,CAACA,GAAGA,CAACA,CAACA,CAACA,CAACA,CAACA;QACZA,KAAKA,CAACA;YAAEA,CAACA;gBACLA,CAACA,EAAEA,CAACA;gBACJA,KAAKA,CAACA;YAEVA,CAACA;QACDA,KAAKA,CAACA;YAAEA,CAACA;gBACLA,CAACA,EAAEA,CAACA;gBACJA,KAAKA,CAACA;YAEVA,CAACA;QACDA;YAASA,CAACA;gBACNA,CAACA,IAAIA,CAACA,CAACA;gBACPA,CAACA,GAAGA,EAAEA,CAACA;gBACPA,KAAKA,CAACA;YAEVA,CAACA;IACLA,CAACA;IACDA,OAAOA,CAACA,GAAGA,EAAEA,EAAEA,CAACA;QACZA,CAACA,EAAEA,CAACA;IACRA,CAACA;IACDA,GAAGA,CAACA;QACAA,CAACA,EAAEA,CAACA;IACRA,CAACA,QAAQA,CAACA,GAAGA,CAACA,EAACA;IACfA,CAACA,GAAGA,CAACA,CAACA;IACNA,IAAIA,CAACA,GAAGA,CAACA,CAACA,IAAIA,CAACA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,CAACA;IACjCA,CAACA,CAACA,IAAIA,CAACA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,CAACA;IACzBA,CAACA,KAAKA,CAACA,CAACA;IACRA,CAACA,GAAGA,CAACA,GAAGA,EAAEA,CAACA;IACXA,IAAIA,CAACA,GAAGA,CAACA,CAACA;IACVA,MAAMA,CAACA;AACXA,CAACA;AACD,IAAI,CAAC,GAAG;IACJ,IAAI,CAAC,GAAG,EAAE,CAAC;IACX,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AACd,CAAC,CAAC;AACF,CAAC,EAAE,CAAC"} \ No newline at end of file +{"version":3,"file":"sourceMapValidationStatements.js","sourceRoot":"","sources":["sourceMapValidationStatements.ts"],"names":["f"],"mappings":"AAAA;IACIA,IAAIA,CAACA,CAACA;IACNA,IAAIA,CAACA,GAAGA,CAACA,CAACA;IACVA,GAAGA,CAACA,CAACA,GAAGA,CAACA,CAACA,GAAGA,CAACA,EAAEA,CAACA,GAAGA,EAAEA,EAAEA,CAACA,EAAEA,EAAEA,CAACA;QAC1BA,CAACA,IAAIA,CAACA,CAACA;QACPA,CAACA,IAAIA,CAACA,CAACA;IACXA,CAACA;IACDA,EAAEA,CAACA,CAACA,CAACA,GAAGA,EAAEA,CAACA,CAACA,CAACA;QACTA,CAACA,IAAIA,CAACA,CAACA;IACXA,CAACA;IAACA,IAAIA,CAACA,CAACA;QACJA,CAACA,IAAIA,EAAEA,CAACA;QACRA,CAACA,EAAEA,CAACA;IACRA,CAACA;IACDA,IAAIA,CAACA,GAAGA;QACJA,CAACA;QACDA,CAACA;QACDA,CAACA;KACJA,CAACA;IACFA,IAAIA,GAAGA,GAAGA;QACNA,CAACA,EAAEA,CAACA;QACJA,CAACA,EAAEA,OAAOA;KACbA,CAACA;IACFA,GAAGA,CAACA,CAACA,GAAGA,CAACA,CAACA,IAAIA,CAACA,CAACA,CAACA,CAACA;QACdA,GAAGA,CAACA,CAACA,GAAGA,CAACA,CAACA,CAACA,CAACA,CAACA;QACbA,IAAIA,CAACA,GAAGA,EAAEA,CAACA;IACfA,CAACA;IACDA,IAAIA,CAACA;QACDA,GAAGA,CAACA,CAACA,GAAGA,MAAMA,CAACA;IACnBA,CAAEA;IAAAA,KAAKA,CAACA,CAACA,CAACA,CAACA,CAACA,CAACA;QACTA,EAAEA,CAACA,CAACA,GAAGA,CAACA,CAACA,GAAGA,EAAEA,CAACA,CAACA,CAACA;YACbA,GAAGA,CAACA,CAACA,GAAGA,EAAEA,CAACA;QACfA,CAACA;QAACA,IAAIA,CAACA,CAACA;YACJA,GAAGA,CAACA,CAACA,GAAGA,KAAKA,CAACA;QAClBA,CAACA;IACLA,CAACA;IACDA,IAAIA,CAACA;QACDA,MAAMA,IAAIA,KAAKA,EAAEA,CAACA;IACtBA,CAAEA;IAAAA,KAAKA,CAACA,CAACA,EAAEA,CAACA,CAACA,CAACA;QACVA,IAAIA,CAACA,GAAGA,EAAEA,CAACA;IACfA,CAACA;YAASA,CAACA;QACPA,CAACA,GAAGA,EAAEA,CAACA;IACXA,CAACA;IACDA,MAAMA,GAAGA,EAAEA,CAACA;QACRA,CAACA,GAAGA,CAACA,CAACA;QACNA,CAACA,GAAGA,EAAEA,CAACA;IACXA,CAACA;IACDA,MAAMA,CAACA,CAACA,GAAGA,CAACA,CAACA,CAACA,CAACA,CAACA;QACZA,KAAKA,CAACA,EAAEA,CAACA;YACLA,CAACA,EAAEA,CAACA;YACJA,KAAKA,CAACA;QAEVA,CAACA;QACDA,KAAKA,CAACA,EAAEA,CAACA;YACLA,CAACA,EAAEA,CAACA;YACJA,KAAKA,CAACA;QAEVA,CAACA;QACDA,SAASA,CAACA;YACNA,CAACA,IAAIA,CAACA,CAACA;YACPA,CAACA,GAAGA,EAAEA,CAACA;YACPA,KAAKA,CAACA;QAEVA,CAACA;IACLA,CAACA;IACDA,OAAOA,CAACA,GAAGA,EAAEA,EAAEA,CAACA;QACZA,CAACA,EAAEA,CAACA;IACRA,CAACA;IACDA,GAAGA,CAACA;QACAA,CAACA,EAAEA,CAACA;IACRA,CAACA,QAAQA,CAACA,GAAGA,CAACA,EAACA;IACfA,CAACA,GAAGA,CAACA,CAACA;IACNA,IAAIA,CAACA,GAAGA,CAACA,CAACA,IAAIA,CAACA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,CAACA;IACjCA,CAACA,CAACA,IAAIA,CAACA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,GAAGA,CAACA,CAACA;IACzBA,CAACA,KAAKA,CAACA,CAACA;IACRA,CAACA,GAAGA,CAACA,GAAGA,EAAEA,CAACA;IACXA,IAAIA,CAACA,GAAGA,CAACA,CAACA;IACVA,MAAMA,CAACA;AACXA,CAACA;AACD,IAAI,CAAC,GAAG;IACJ,IAAI,CAAC,GAAG,EAAE,CAAC;IACX,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AACd,CAAC,CAAC;AACF,CAAC,EAAE,CAAC"} \ No newline at end of file diff --git a/tests/baselines/reference/sourceMapValidationStatements.sourcemap.txt b/tests/baselines/reference/sourceMapValidationStatements.sourcemap.txt index 789d98afe5..2a2daed01d 100644 --- a/tests/baselines/reference/sourceMapValidationStatements.sourcemap.txt +++ b/tests/baselines/reference/sourceMapValidationStatements.sourcemap.txt @@ -930,200 +930,191 @@ sourceFile:sourceMapValidationStatements.ts 9 >Emitted(52, 20) Source(47, 20) + SourceIndex(0) name (f) 10>Emitted(52, 21) Source(47, 21) + SourceIndex(0) name (f) --- ->>> case 0: +>>> case 0: { 1 >^^^^^^^^ 2 > ^^^^^ 3 > ^ +4 > ^^ +5 > ^ 1 > > 2 > case 3 > 0 +4 > : +5 > { 1 >Emitted(53, 9) Source(48, 9) + SourceIndex(0) name (f) 2 >Emitted(53, 14) Source(48, 14) + SourceIndex(0) name (f) 3 >Emitted(53, 15) Source(48, 15) + SourceIndex(0) name (f) +4 >Emitted(53, 17) Source(48, 17) + SourceIndex(0) name (f) +5 >Emitted(53, 18) Source(48, 18) + SourceIndex(0) name (f) --- ->>> { +>>> x++; 1 >^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^-> -1 >: -2 > { -1 >Emitted(54, 13) Source(48, 17) + SourceIndex(0) name (f) -2 >Emitted(54, 14) Source(48, 18) + SourceIndex(0) name (f) +3 > ^^ +4 > ^ +5 > ^^^-> +1 > + > +2 > x +3 > ++ +4 > ; +1 >Emitted(54, 13) Source(49, 13) + SourceIndex(0) name (f) +2 >Emitted(54, 14) Source(49, 14) + SourceIndex(0) name (f) +3 >Emitted(54, 16) Source(49, 16) + SourceIndex(0) name (f) +4 >Emitted(54, 17) Source(49, 17) + SourceIndex(0) name (f) --- ->>> x++; -1->^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^ -4 > ^ -5 > ^^^-> +>>> break; +1->^^^^^^^^^^^^ +2 > ^^^^^ +3 > ^ 1-> > -2 > x -3 > ++ -4 > ; -1->Emitted(55, 17) Source(49, 13) + SourceIndex(0) name (f) -2 >Emitted(55, 18) Source(49, 14) + SourceIndex(0) name (f) -3 >Emitted(55, 20) Source(49, 16) + SourceIndex(0) name (f) -4 >Emitted(55, 21) Source(49, 17) + SourceIndex(0) name (f) +2 > break +3 > ; +1->Emitted(55, 13) Source(50, 13) + SourceIndex(0) name (f) +2 >Emitted(55, 18) Source(50, 18) + SourceIndex(0) name (f) +3 >Emitted(55, 19) Source(50, 19) + SourceIndex(0) name (f) --- ->>> break; -1->^^^^^^^^^^^^^^^^ -2 > ^^^^^ -3 > ^ -1-> - > -2 > break -3 > ; -1->Emitted(56, 17) Source(50, 13) + SourceIndex(0) name (f) -2 >Emitted(56, 22) Source(50, 18) + SourceIndex(0) name (f) -3 >Emitted(56, 23) Source(50, 19) + SourceIndex(0) name (f) ---- ->>> } -1 >^^^^^^^^^^^^ -2 > ^ -3 > ^^^-> +>>> } +1 >^^^^^^^^ +2 > ^ +3 > ^^^^^^^^^-> 1 > > > -2 > } -1 >Emitted(57, 13) Source(52, 9) + SourceIndex(0) name (f) -2 >Emitted(57, 14) Source(52, 10) + SourceIndex(0) name (f) +2 > } +1 >Emitted(56, 9) Source(52, 9) + SourceIndex(0) name (f) +2 >Emitted(56, 10) Source(52, 10) + SourceIndex(0) name (f) --- ->>> case 1: +>>> case 1: { 1->^^^^^^^^ 2 > ^^^^^ 3 > ^ +4 > ^^ +5 > ^ 1-> > 2 > case 3 > 1 -1->Emitted(58, 9) Source(53, 9) + SourceIndex(0) name (f) -2 >Emitted(58, 14) Source(53, 14) + SourceIndex(0) name (f) -3 >Emitted(58, 15) Source(53, 15) + SourceIndex(0) name (f) +4 > : +5 > { +1->Emitted(57, 9) Source(53, 9) + SourceIndex(0) name (f) +2 >Emitted(57, 14) Source(53, 14) + SourceIndex(0) name (f) +3 >Emitted(57, 15) Source(53, 15) + SourceIndex(0) name (f) +4 >Emitted(57, 17) Source(53, 17) + SourceIndex(0) name (f) +5 >Emitted(57, 18) Source(53, 18) + SourceIndex(0) name (f) --- ->>> { +>>> x--; 1 >^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^-> -1 >: -2 > { -1 >Emitted(59, 13) Source(53, 17) + SourceIndex(0) name (f) -2 >Emitted(59, 14) Source(53, 18) + SourceIndex(0) name (f) +3 > ^^ +4 > ^ +5 > ^^^-> +1 > + > +2 > x +3 > -- +4 > ; +1 >Emitted(58, 13) Source(54, 13) + SourceIndex(0) name (f) +2 >Emitted(58, 14) Source(54, 14) + SourceIndex(0) name (f) +3 >Emitted(58, 16) Source(54, 16) + SourceIndex(0) name (f) +4 >Emitted(58, 17) Source(54, 17) + SourceIndex(0) name (f) --- ->>> x--; -1->^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^ -4 > ^ -5 > ^^^-> +>>> break; +1->^^^^^^^^^^^^ +2 > ^^^^^ +3 > ^ 1-> > -2 > x -3 > -- -4 > ; -1->Emitted(60, 17) Source(54, 13) + SourceIndex(0) name (f) -2 >Emitted(60, 18) Source(54, 14) + SourceIndex(0) name (f) -3 >Emitted(60, 20) Source(54, 16) + SourceIndex(0) name (f) -4 >Emitted(60, 21) Source(54, 17) + SourceIndex(0) name (f) +2 > break +3 > ; +1->Emitted(59, 13) Source(55, 13) + SourceIndex(0) name (f) +2 >Emitted(59, 18) Source(55, 18) + SourceIndex(0) name (f) +3 >Emitted(59, 19) Source(55, 19) + SourceIndex(0) name (f) --- ->>> break; -1->^^^^^^^^^^^^^^^^ -2 > ^^^^^ -3 > ^ -1-> - > -2 > break -3 > ; -1->Emitted(61, 17) Source(55, 13) + SourceIndex(0) name (f) -2 >Emitted(61, 22) Source(55, 18) + SourceIndex(0) name (f) -3 >Emitted(61, 23) Source(55, 19) + SourceIndex(0) name (f) ---- ->>> } -1 >^^^^^^^^^^^^ -2 > ^ -3 > ^^^^-> +>>> } +1 >^^^^^^^^ +2 > ^ +3 > ^^^^^^^^^^-> 1 > > > -2 > } -1 >Emitted(62, 13) Source(57, 9) + SourceIndex(0) name (f) -2 >Emitted(62, 14) Source(57, 10) + SourceIndex(0) name (f) +2 > } +1 >Emitted(60, 9) Source(57, 9) + SourceIndex(0) name (f) +2 >Emitted(60, 10) Source(57, 10) + SourceIndex(0) name (f) --- ->>> default: +>>> default: { 1->^^^^^^^^ -2 > ^^^^^^-> +2 > ^^^^^^^^^ +3 > ^ +4 > ^^-> 1-> > -1->Emitted(63, 9) Source(58, 9) + SourceIndex(0) name (f) +2 > default: +3 > { +1->Emitted(61, 9) Source(58, 9) + SourceIndex(0) name (f) +2 >Emitted(61, 18) Source(58, 18) + SourceIndex(0) name (f) +3 >Emitted(61, 19) Source(58, 19) + SourceIndex(0) name (f) --- ->>> { +>>> x *= 2; 1->^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^-> -1->default: -2 > { -1->Emitted(64, 13) Source(58, 18) + SourceIndex(0) name (f) -2 >Emitted(64, 14) Source(58, 19) + SourceIndex(0) name (f) ---- ->>> x *= 2; -1->^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^^^ -4 > ^ -5 > ^ -6 > ^-> +3 > ^^^^ +4 > ^ +5 > ^ +6 > ^-> 1-> > -2 > x -3 > *= -4 > 2 -5 > ; -1->Emitted(65, 17) Source(59, 13) + SourceIndex(0) name (f) -2 >Emitted(65, 18) Source(59, 14) + SourceIndex(0) name (f) -3 >Emitted(65, 22) Source(59, 18) + SourceIndex(0) name (f) -4 >Emitted(65, 23) Source(59, 19) + SourceIndex(0) name (f) -5 >Emitted(65, 24) Source(59, 20) + SourceIndex(0) name (f) +2 > x +3 > *= +4 > 2 +5 > ; +1->Emitted(62, 13) Source(59, 13) + SourceIndex(0) name (f) +2 >Emitted(62, 14) Source(59, 14) + SourceIndex(0) name (f) +3 >Emitted(62, 18) Source(59, 18) + SourceIndex(0) name (f) +4 >Emitted(62, 19) Source(59, 19) + SourceIndex(0) name (f) +5 >Emitted(62, 20) Source(59, 20) + SourceIndex(0) name (f) --- ->>> x = 50; -1->^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^^ -4 > ^^ -5 > ^ +>>> x = 50; +1->^^^^^^^^^^^^ +2 > ^ +3 > ^^^ +4 > ^^ +5 > ^ 1-> > -2 > x -3 > = -4 > 50 -5 > ; -1->Emitted(66, 17) Source(60, 13) + SourceIndex(0) name (f) -2 >Emitted(66, 18) Source(60, 14) + SourceIndex(0) name (f) -3 >Emitted(66, 21) Source(60, 17) + SourceIndex(0) name (f) -4 >Emitted(66, 23) Source(60, 19) + SourceIndex(0) name (f) -5 >Emitted(66, 24) Source(60, 20) + SourceIndex(0) name (f) +2 > x +3 > = +4 > 50 +5 > ; +1->Emitted(63, 13) Source(60, 13) + SourceIndex(0) name (f) +2 >Emitted(63, 14) Source(60, 14) + SourceIndex(0) name (f) +3 >Emitted(63, 17) Source(60, 17) + SourceIndex(0) name (f) +4 >Emitted(63, 19) Source(60, 19) + SourceIndex(0) name (f) +5 >Emitted(63, 20) Source(60, 20) + SourceIndex(0) name (f) --- ->>> break; -1 >^^^^^^^^^^^^^^^^ -2 > ^^^^^ -3 > ^ +>>> break; +1 >^^^^^^^^^^^^ +2 > ^^^^^ +3 > ^ 1 > > -2 > break -3 > ; -1 >Emitted(67, 17) Source(61, 13) + SourceIndex(0) name (f) -2 >Emitted(67, 22) Source(61, 18) + SourceIndex(0) name (f) -3 >Emitted(67, 23) Source(61, 19) + SourceIndex(0) name (f) +2 > break +3 > ; +1 >Emitted(64, 13) Source(61, 13) + SourceIndex(0) name (f) +2 >Emitted(64, 18) Source(61, 18) + SourceIndex(0) name (f) +3 >Emitted(64, 19) Source(61, 19) + SourceIndex(0) name (f) --- ->>> } -1 >^^^^^^^^^^^^ -2 > ^ +>>> } +1 >^^^^^^^^ +2 > ^ 1 > > > -2 > } -1 >Emitted(68, 13) Source(63, 9) + SourceIndex(0) name (f) -2 >Emitted(68, 14) Source(63, 10) + SourceIndex(0) name (f) +2 > } +1 >Emitted(65, 9) Source(63, 9) + SourceIndex(0) name (f) +2 >Emitted(65, 10) Source(63, 10) + SourceIndex(0) name (f) --- >>> } 1 >^^^^ @@ -1132,8 +1123,8 @@ sourceFile:sourceMapValidationStatements.ts 1 > > 2 > } -1 >Emitted(69, 5) Source(64, 5) + SourceIndex(0) name (f) -2 >Emitted(69, 6) Source(64, 6) + SourceIndex(0) name (f) +1 >Emitted(66, 5) Source(64, 5) + SourceIndex(0) name (f) +2 >Emitted(66, 6) Source(64, 6) + SourceIndex(0) name (f) --- >>> while (x < 10) { 1->^^^^ @@ -1151,13 +1142,13 @@ sourceFile:sourceMapValidationStatements.ts 5 > 10 6 > ) 7 > { -1->Emitted(70, 5) Source(65, 5) + SourceIndex(0) name (f) -2 >Emitted(70, 12) Source(65, 12) + SourceIndex(0) name (f) -3 >Emitted(70, 13) Source(65, 13) + SourceIndex(0) name (f) -4 >Emitted(70, 16) Source(65, 16) + SourceIndex(0) name (f) -5 >Emitted(70, 18) Source(65, 18) + SourceIndex(0) name (f) -6 >Emitted(70, 20) Source(65, 20) + SourceIndex(0) name (f) -7 >Emitted(70, 21) Source(65, 21) + SourceIndex(0) name (f) +1->Emitted(67, 5) Source(65, 5) + SourceIndex(0) name (f) +2 >Emitted(67, 12) Source(65, 12) + SourceIndex(0) name (f) +3 >Emitted(67, 13) Source(65, 13) + SourceIndex(0) name (f) +4 >Emitted(67, 16) Source(65, 16) + SourceIndex(0) name (f) +5 >Emitted(67, 18) Source(65, 18) + SourceIndex(0) name (f) +6 >Emitted(67, 20) Source(65, 20) + SourceIndex(0) name (f) +7 >Emitted(67, 21) Source(65, 21) + SourceIndex(0) name (f) --- >>> x++; 1 >^^^^^^^^ @@ -1169,10 +1160,10 @@ sourceFile:sourceMapValidationStatements.ts 2 > x 3 > ++ 4 > ; -1 >Emitted(71, 9) Source(66, 9) + SourceIndex(0) name (f) -2 >Emitted(71, 10) Source(66, 10) + SourceIndex(0) name (f) -3 >Emitted(71, 12) Source(66, 12) + SourceIndex(0) name (f) -4 >Emitted(71, 13) Source(66, 13) + SourceIndex(0) name (f) +1 >Emitted(68, 9) Source(66, 9) + SourceIndex(0) name (f) +2 >Emitted(68, 10) Source(66, 10) + SourceIndex(0) name (f) +3 >Emitted(68, 12) Source(66, 12) + SourceIndex(0) name (f) +4 >Emitted(68, 13) Source(66, 13) + SourceIndex(0) name (f) --- >>> } 1 >^^^^ @@ -1181,8 +1172,8 @@ sourceFile:sourceMapValidationStatements.ts 1 > > 2 > } -1 >Emitted(72, 5) Source(67, 5) + SourceIndex(0) name (f) -2 >Emitted(72, 6) Source(67, 6) + SourceIndex(0) name (f) +1 >Emitted(69, 5) Source(67, 5) + SourceIndex(0) name (f) +2 >Emitted(69, 6) Source(67, 6) + SourceIndex(0) name (f) --- >>> do { 1->^^^^ @@ -1193,9 +1184,9 @@ sourceFile:sourceMapValidationStatements.ts > 2 > do 3 > { -1->Emitted(73, 5) Source(68, 5) + SourceIndex(0) name (f) -2 >Emitted(73, 8) Source(68, 8) + SourceIndex(0) name (f) -3 >Emitted(73, 9) Source(68, 9) + SourceIndex(0) name (f) +1->Emitted(70, 5) Source(68, 5) + SourceIndex(0) name (f) +2 >Emitted(70, 8) Source(68, 8) + SourceIndex(0) name (f) +3 >Emitted(70, 9) Source(68, 9) + SourceIndex(0) name (f) --- >>> x--; 1->^^^^^^^^ @@ -1208,10 +1199,10 @@ sourceFile:sourceMapValidationStatements.ts 2 > x 3 > -- 4 > ; -1->Emitted(74, 9) Source(69, 9) + SourceIndex(0) name (f) -2 >Emitted(74, 10) Source(69, 10) + SourceIndex(0) name (f) -3 >Emitted(74, 12) Source(69, 12) + SourceIndex(0) name (f) -4 >Emitted(74, 13) Source(69, 13) + SourceIndex(0) name (f) +1->Emitted(71, 9) Source(69, 9) + SourceIndex(0) name (f) +2 >Emitted(71, 10) Source(69, 10) + SourceIndex(0) name (f) +3 >Emitted(71, 12) Source(69, 12) + SourceIndex(0) name (f) +4 >Emitted(71, 13) Source(69, 13) + SourceIndex(0) name (f) --- >>> } while (x > 4); 1->^^^^ @@ -1229,13 +1220,13 @@ sourceFile:sourceMapValidationStatements.ts 5 > > 6 > 4 7 > ) -1->Emitted(75, 5) Source(70, 5) + SourceIndex(0) name (f) -2 >Emitted(75, 6) Source(70, 6) + SourceIndex(0) name (f) -3 >Emitted(75, 14) Source(70, 14) + SourceIndex(0) name (f) -4 >Emitted(75, 15) Source(70, 15) + SourceIndex(0) name (f) -5 >Emitted(75, 18) Source(70, 18) + SourceIndex(0) name (f) -6 >Emitted(75, 19) Source(70, 19) + SourceIndex(0) name (f) -7 >Emitted(75, 21) Source(70, 20) + SourceIndex(0) name (f) +1->Emitted(72, 5) Source(70, 5) + SourceIndex(0) name (f) +2 >Emitted(72, 6) Source(70, 6) + SourceIndex(0) name (f) +3 >Emitted(72, 14) Source(70, 14) + SourceIndex(0) name (f) +4 >Emitted(72, 15) Source(70, 15) + SourceIndex(0) name (f) +5 >Emitted(72, 18) Source(70, 18) + SourceIndex(0) name (f) +6 >Emitted(72, 19) Source(70, 19) + SourceIndex(0) name (f) +7 >Emitted(72, 21) Source(70, 20) + SourceIndex(0) name (f) --- >>> x = y; 1 >^^^^ @@ -1250,11 +1241,11 @@ sourceFile:sourceMapValidationStatements.ts 3 > = 4 > y 5 > ; -1 >Emitted(76, 5) Source(71, 5) + SourceIndex(0) name (f) -2 >Emitted(76, 6) Source(71, 6) + SourceIndex(0) name (f) -3 >Emitted(76, 9) Source(71, 9) + SourceIndex(0) name (f) -4 >Emitted(76, 10) Source(71, 10) + SourceIndex(0) name (f) -5 >Emitted(76, 11) Source(71, 11) + SourceIndex(0) name (f) +1 >Emitted(73, 5) Source(71, 5) + SourceIndex(0) name (f) +2 >Emitted(73, 6) Source(71, 6) + SourceIndex(0) name (f) +3 >Emitted(73, 9) Source(71, 9) + SourceIndex(0) name (f) +4 >Emitted(73, 10) Source(71, 10) + SourceIndex(0) name (f) +5 >Emitted(73, 11) Source(71, 11) + SourceIndex(0) name (f) --- >>> var z = (x == 1) ? x + 1 : x - 1; 1->^^^^ @@ -1294,24 +1285,24 @@ sourceFile:sourceMapValidationStatements.ts 16> - 17> 1 18> ; -1->Emitted(77, 5) Source(72, 5) + SourceIndex(0) name (f) -2 >Emitted(77, 9) Source(72, 9) + SourceIndex(0) name (f) -3 >Emitted(77, 10) Source(72, 10) + SourceIndex(0) name (f) -4 >Emitted(77, 13) Source(72, 13) + SourceIndex(0) name (f) -5 >Emitted(77, 14) Source(72, 14) + SourceIndex(0) name (f) -6 >Emitted(77, 15) Source(72, 15) + SourceIndex(0) name (f) -7 >Emitted(77, 19) Source(72, 19) + SourceIndex(0) name (f) -8 >Emitted(77, 20) Source(72, 20) + SourceIndex(0) name (f) -9 >Emitted(77, 21) Source(72, 21) + SourceIndex(0) name (f) -10>Emitted(77, 24) Source(72, 24) + SourceIndex(0) name (f) -11>Emitted(77, 25) Source(72, 25) + SourceIndex(0) name (f) -12>Emitted(77, 28) Source(72, 28) + SourceIndex(0) name (f) -13>Emitted(77, 29) Source(72, 29) + SourceIndex(0) name (f) -14>Emitted(77, 32) Source(72, 32) + SourceIndex(0) name (f) -15>Emitted(77, 33) Source(72, 33) + SourceIndex(0) name (f) -16>Emitted(77, 36) Source(72, 36) + SourceIndex(0) name (f) -17>Emitted(77, 37) Source(72, 37) + SourceIndex(0) name (f) -18>Emitted(77, 38) Source(72, 38) + SourceIndex(0) name (f) +1->Emitted(74, 5) Source(72, 5) + SourceIndex(0) name (f) +2 >Emitted(74, 9) Source(72, 9) + SourceIndex(0) name (f) +3 >Emitted(74, 10) Source(72, 10) + SourceIndex(0) name (f) +4 >Emitted(74, 13) Source(72, 13) + SourceIndex(0) name (f) +5 >Emitted(74, 14) Source(72, 14) + SourceIndex(0) name (f) +6 >Emitted(74, 15) Source(72, 15) + SourceIndex(0) name (f) +7 >Emitted(74, 19) Source(72, 19) + SourceIndex(0) name (f) +8 >Emitted(74, 20) Source(72, 20) + SourceIndex(0) name (f) +9 >Emitted(74, 21) Source(72, 21) + SourceIndex(0) name (f) +10>Emitted(74, 24) Source(72, 24) + SourceIndex(0) name (f) +11>Emitted(74, 25) Source(72, 25) + SourceIndex(0) name (f) +12>Emitted(74, 28) Source(72, 28) + SourceIndex(0) name (f) +13>Emitted(74, 29) Source(72, 29) + SourceIndex(0) name (f) +14>Emitted(74, 32) Source(72, 32) + SourceIndex(0) name (f) +15>Emitted(74, 33) Source(72, 33) + SourceIndex(0) name (f) +16>Emitted(74, 36) Source(72, 36) + SourceIndex(0) name (f) +17>Emitted(74, 37) Source(72, 37) + SourceIndex(0) name (f) +18>Emitted(74, 38) Source(72, 38) + SourceIndex(0) name (f) --- >>> (x == 1) ? x + 1 : x - 1; 1 >^^^^ @@ -1345,21 +1336,21 @@ sourceFile:sourceMapValidationStatements.ts 13> - 14> 1 15> ; -1 >Emitted(78, 5) Source(73, 5) + SourceIndex(0) name (f) -2 >Emitted(78, 6) Source(73, 6) + SourceIndex(0) name (f) -3 >Emitted(78, 7) Source(73, 7) + SourceIndex(0) name (f) -4 >Emitted(78, 11) Source(73, 11) + SourceIndex(0) name (f) -5 >Emitted(78, 12) Source(73, 12) + SourceIndex(0) name (f) -6 >Emitted(78, 13) Source(73, 13) + SourceIndex(0) name (f) -7 >Emitted(78, 16) Source(73, 16) + SourceIndex(0) name (f) -8 >Emitted(78, 17) Source(73, 17) + SourceIndex(0) name (f) -9 >Emitted(78, 20) Source(73, 20) + SourceIndex(0) name (f) -10>Emitted(78, 21) Source(73, 21) + SourceIndex(0) name (f) -11>Emitted(78, 24) Source(73, 24) + SourceIndex(0) name (f) -12>Emitted(78, 25) Source(73, 25) + SourceIndex(0) name (f) -13>Emitted(78, 28) Source(73, 28) + SourceIndex(0) name (f) -14>Emitted(78, 29) Source(73, 29) + SourceIndex(0) name (f) -15>Emitted(78, 30) Source(73, 30) + SourceIndex(0) name (f) +1 >Emitted(75, 5) Source(73, 5) + SourceIndex(0) name (f) +2 >Emitted(75, 6) Source(73, 6) + SourceIndex(0) name (f) +3 >Emitted(75, 7) Source(73, 7) + SourceIndex(0) name (f) +4 >Emitted(75, 11) Source(73, 11) + SourceIndex(0) name (f) +5 >Emitted(75, 12) Source(73, 12) + SourceIndex(0) name (f) +6 >Emitted(75, 13) Source(73, 13) + SourceIndex(0) name (f) +7 >Emitted(75, 16) Source(73, 16) + SourceIndex(0) name (f) +8 >Emitted(75, 17) Source(73, 17) + SourceIndex(0) name (f) +9 >Emitted(75, 20) Source(73, 20) + SourceIndex(0) name (f) +10>Emitted(75, 21) Source(73, 21) + SourceIndex(0) name (f) +11>Emitted(75, 24) Source(73, 24) + SourceIndex(0) name (f) +12>Emitted(75, 25) Source(73, 25) + SourceIndex(0) name (f) +13>Emitted(75, 28) Source(73, 28) + SourceIndex(0) name (f) +14>Emitted(75, 29) Source(73, 29) + SourceIndex(0) name (f) +15>Emitted(75, 30) Source(73, 30) + SourceIndex(0) name (f) --- >>> x === 1; 1 >^^^^ @@ -1374,11 +1365,11 @@ sourceFile:sourceMapValidationStatements.ts 3 > === 4 > 1 5 > ; -1 >Emitted(79, 5) Source(74, 5) + SourceIndex(0) name (f) -2 >Emitted(79, 6) Source(74, 6) + SourceIndex(0) name (f) -3 >Emitted(79, 11) Source(74, 11) + SourceIndex(0) name (f) -4 >Emitted(79, 12) Source(74, 12) + SourceIndex(0) name (f) -5 >Emitted(79, 13) Source(74, 13) + SourceIndex(0) name (f) +1 >Emitted(76, 5) Source(74, 5) + SourceIndex(0) name (f) +2 >Emitted(76, 6) Source(74, 6) + SourceIndex(0) name (f) +3 >Emitted(76, 11) Source(74, 11) + SourceIndex(0) name (f) +4 >Emitted(76, 12) Source(74, 12) + SourceIndex(0) name (f) +5 >Emitted(76, 13) Source(74, 13) + SourceIndex(0) name (f) --- >>> x = z = 40; 1->^^^^ @@ -1396,13 +1387,13 @@ sourceFile:sourceMapValidationStatements.ts 5 > = 6 > 40 7 > ; -1->Emitted(80, 5) Source(75, 5) + SourceIndex(0) name (f) -2 >Emitted(80, 6) Source(75, 6) + SourceIndex(0) name (f) -3 >Emitted(80, 9) Source(75, 9) + SourceIndex(0) name (f) -4 >Emitted(80, 10) Source(75, 10) + SourceIndex(0) name (f) -5 >Emitted(80, 13) Source(75, 13) + SourceIndex(0) name (f) -6 >Emitted(80, 15) Source(75, 15) + SourceIndex(0) name (f) -7 >Emitted(80, 16) Source(75, 16) + SourceIndex(0) name (f) +1->Emitted(77, 5) Source(75, 5) + SourceIndex(0) name (f) +2 >Emitted(77, 6) Source(75, 6) + SourceIndex(0) name (f) +3 >Emitted(77, 9) Source(75, 9) + SourceIndex(0) name (f) +4 >Emitted(77, 10) Source(75, 10) + SourceIndex(0) name (f) +5 >Emitted(77, 13) Source(75, 13) + SourceIndex(0) name (f) +6 >Emitted(77, 15) Source(75, 15) + SourceIndex(0) name (f) +7 >Emitted(77, 16) Source(75, 16) + SourceIndex(0) name (f) --- >>> eval("y"); 1 >^^^^ @@ -1418,12 +1409,12 @@ sourceFile:sourceMapValidationStatements.ts 4 > "y" 5 > ) 6 > ; -1 >Emitted(81, 5) Source(76, 5) + SourceIndex(0) name (f) -2 >Emitted(81, 9) Source(76, 9) + SourceIndex(0) name (f) -3 >Emitted(81, 10) Source(76, 10) + SourceIndex(0) name (f) -4 >Emitted(81, 13) Source(76, 13) + SourceIndex(0) name (f) -5 >Emitted(81, 14) Source(76, 14) + SourceIndex(0) name (f) -6 >Emitted(81, 15) Source(76, 15) + SourceIndex(0) name (f) +1 >Emitted(78, 5) Source(76, 5) + SourceIndex(0) name (f) +2 >Emitted(78, 9) Source(76, 9) + SourceIndex(0) name (f) +3 >Emitted(78, 10) Source(76, 10) + SourceIndex(0) name (f) +4 >Emitted(78, 13) Source(76, 13) + SourceIndex(0) name (f) +5 >Emitted(78, 14) Source(76, 14) + SourceIndex(0) name (f) +6 >Emitted(78, 15) Source(76, 15) + SourceIndex(0) name (f) --- >>> return; 1 >^^^^ @@ -1433,9 +1424,9 @@ sourceFile:sourceMapValidationStatements.ts > 2 > return 3 > ; -1 >Emitted(82, 5) Source(77, 5) + SourceIndex(0) name (f) -2 >Emitted(82, 11) Source(77, 11) + SourceIndex(0) name (f) -3 >Emitted(82, 12) Source(77, 12) + SourceIndex(0) name (f) +1 >Emitted(79, 5) Source(77, 5) + SourceIndex(0) name (f) +2 >Emitted(79, 11) Source(77, 11) + SourceIndex(0) name (f) +3 >Emitted(79, 12) Source(77, 12) + SourceIndex(0) name (f) --- >>>} 1 > @@ -1444,8 +1435,8 @@ sourceFile:sourceMapValidationStatements.ts 1 > > 2 >} -1 >Emitted(83, 1) Source(78, 1) + SourceIndex(0) name (f) -2 >Emitted(83, 2) Source(78, 2) + SourceIndex(0) name (f) +1 >Emitted(80, 1) Source(78, 1) + SourceIndex(0) name (f) +2 >Emitted(80, 2) Source(78, 2) + SourceIndex(0) name (f) --- >>>var b = function () { 1-> @@ -1458,10 +1449,10 @@ sourceFile:sourceMapValidationStatements.ts 2 >var 3 > b 4 > = -1->Emitted(84, 1) Source(79, 1) + SourceIndex(0) -2 >Emitted(84, 5) Source(79, 5) + SourceIndex(0) -3 >Emitted(84, 6) Source(79, 6) + SourceIndex(0) -4 >Emitted(84, 9) Source(79, 9) + SourceIndex(0) +1->Emitted(81, 1) Source(79, 1) + SourceIndex(0) +2 >Emitted(81, 5) Source(79, 5) + SourceIndex(0) +3 >Emitted(81, 6) Source(79, 6) + SourceIndex(0) +4 >Emitted(81, 9) Source(79, 9) + SourceIndex(0) --- >>> var x = 10; 1->^^^^ @@ -1477,12 +1468,12 @@ sourceFile:sourceMapValidationStatements.ts 4 > = 5 > 10 6 > ; -1->Emitted(85, 5) Source(80, 5) + SourceIndex(0) -2 >Emitted(85, 9) Source(80, 9) + SourceIndex(0) -3 >Emitted(85, 10) Source(80, 10) + SourceIndex(0) -4 >Emitted(85, 13) Source(80, 13) + SourceIndex(0) -5 >Emitted(85, 15) Source(80, 15) + SourceIndex(0) -6 >Emitted(85, 16) Source(80, 16) + SourceIndex(0) +1->Emitted(82, 5) Source(80, 5) + SourceIndex(0) +2 >Emitted(82, 9) Source(80, 9) + SourceIndex(0) +3 >Emitted(82, 10) Source(80, 10) + SourceIndex(0) +4 >Emitted(82, 13) Source(80, 13) + SourceIndex(0) +5 >Emitted(82, 15) Source(80, 15) + SourceIndex(0) +6 >Emitted(82, 16) Source(80, 16) + SourceIndex(0) --- >>> x = x + 1; 1 >^^^^ @@ -1500,13 +1491,13 @@ sourceFile:sourceMapValidationStatements.ts 5 > + 6 > 1 7 > ; -1 >Emitted(86, 5) Source(81, 5) + SourceIndex(0) -2 >Emitted(86, 6) Source(81, 6) + SourceIndex(0) -3 >Emitted(86, 9) Source(81, 9) + SourceIndex(0) -4 >Emitted(86, 10) Source(81, 10) + SourceIndex(0) -5 >Emitted(86, 13) Source(81, 13) + SourceIndex(0) -6 >Emitted(86, 14) Source(81, 14) + SourceIndex(0) -7 >Emitted(86, 15) Source(81, 15) + SourceIndex(0) +1 >Emitted(83, 5) Source(81, 5) + SourceIndex(0) +2 >Emitted(83, 6) Source(81, 6) + SourceIndex(0) +3 >Emitted(83, 9) Source(81, 9) + SourceIndex(0) +4 >Emitted(83, 10) Source(81, 10) + SourceIndex(0) +5 >Emitted(83, 13) Source(81, 13) + SourceIndex(0) +6 >Emitted(83, 14) Source(81, 14) + SourceIndex(0) +7 >Emitted(83, 15) Source(81, 15) + SourceIndex(0) --- >>>}; 1 > @@ -1517,9 +1508,9 @@ sourceFile:sourceMapValidationStatements.ts > 2 >} 3 > ; -1 >Emitted(87, 1) Source(82, 1) + SourceIndex(0) -2 >Emitted(87, 2) Source(82, 2) + SourceIndex(0) -3 >Emitted(87, 3) Source(82, 3) + SourceIndex(0) +1 >Emitted(84, 1) Source(82, 1) + SourceIndex(0) +2 >Emitted(84, 2) Source(82, 2) + SourceIndex(0) +3 >Emitted(84, 3) Source(82, 3) + SourceIndex(0) --- >>>f(); 1-> @@ -1532,9 +1523,9 @@ sourceFile:sourceMapValidationStatements.ts 2 >f 3 > () 4 > ; -1->Emitted(88, 1) Source(83, 1) + SourceIndex(0) -2 >Emitted(88, 2) Source(83, 2) + SourceIndex(0) -3 >Emitted(88, 4) Source(83, 4) + SourceIndex(0) -4 >Emitted(88, 5) Source(83, 5) + SourceIndex(0) +1->Emitted(85, 1) Source(83, 1) + SourceIndex(0) +2 >Emitted(85, 2) Source(83, 2) + SourceIndex(0) +3 >Emitted(85, 4) Source(83, 4) + SourceIndex(0) +4 >Emitted(85, 5) Source(83, 5) + SourceIndex(0) --- >>>//# sourceMappingURL=sourceMapValidationStatements.js.map \ No newline at end of file diff --git a/tests/baselines/reference/spaceBeforeQuestionMarkInPropertyAssignment.js b/tests/baselines/reference/spaceBeforeQuestionMarkInPropertyAssignment.js index 87aff29c21..d439cc3b02 100644 --- a/tests/baselines/reference/spaceBeforeQuestionMarkInPropertyAssignment.js +++ b/tests/baselines/reference/spaceBeforeQuestionMarkInPropertyAssignment.js @@ -2,6 +2,4 @@ var x = {x ?: 1} // should not crash //// [spaceBeforeQuestionMarkInPropertyAssignment.js] -var x = { - x: 1 -}; // should not crash +var x = { x: 1 }; // should not crash diff --git a/tests/baselines/reference/specializationsShouldNotAffectEachOther.js b/tests/baselines/reference/specializationsShouldNotAffectEachOther.js index d0b84d9900..3116571166 100644 --- a/tests/baselines/reference/specializationsShouldNotAffectEachOther.js +++ b/tests/baselines/reference/specializationsShouldNotAffectEachOther.js @@ -23,13 +23,9 @@ var keyExtent2: any[] = series.data.map(function (d: string) { return d; }); //// [specializationsShouldNotAffectEachOther.js] var series; function foo() { - var seriesExtent = function (series) { - return null; - }; + var seriesExtent = function (series) { return null; }; var series2; series2.map(seriesExtent); return null; } -var keyExtent2 = series.data.map(function (d) { - return d; -}); +var keyExtent2 = series.data.map(function (d) { return d; }); diff --git a/tests/baselines/reference/specializeVarArgs1.js b/tests/baselines/reference/specializeVarArgs1.js index 3eac6daa61..cc09df1daa 100644 --- a/tests/baselines/reference/specializeVarArgs1.js +++ b/tests/baselines/reference/specializeVarArgs1.js @@ -23,8 +23,6 @@ a.push('Some Value'); //// [specializeVarArgs1.js] -function observableArray() { - return null; -} +function observableArray() { return null; } var a = observableArray(); a.push('Some Value'); diff --git a/tests/baselines/reference/specializedInheritedConstructors1.js b/tests/baselines/reference/specializedInheritedConstructors1.js index 4c30628af4..36280f9a44 100644 --- a/tests/baselines/reference/specializedInheritedConstructors1.js +++ b/tests/baselines/reference/specializedInheritedConstructors1.js @@ -41,11 +41,7 @@ var MyView = (function (_super) { } return MyView; })(View); -var m = { - model: new Model() -}; -var aView = new View({ - model: new Model() -}); +var m = { model: new Model() }; +var aView = new View({ model: new Model() }); var aView2 = new View(m); var myView = new MyView(m); // was error diff --git a/tests/baselines/reference/specializedOverloadWithRestParameters.js b/tests/baselines/reference/specializedOverloadWithRestParameters.js index 56bf07f6fd..f091a39677 100644 --- a/tests/baselines/reference/specializedOverloadWithRestParameters.js +++ b/tests/baselines/reference/specializedOverloadWithRestParameters.js @@ -22,8 +22,7 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base() { } - Base.prototype.foo = function () { - }; + Base.prototype.foo = function () { }; return Base; })(); var Derived1 = (function (_super) { @@ -31,8 +30,7 @@ var Derived1 = (function (_super) { function Derived1() { _super.apply(this, arguments); } - Derived1.prototype.bar = function () { - }; + Derived1.prototype.bar = function () { }; return Derived1; })(Base); function f(tagName) { diff --git a/tests/baselines/reference/specializedSignatureAsCallbackParameter1.js b/tests/baselines/reference/specializedSignatureAsCallbackParameter1.js index bf6c73bdf4..1607f730e4 100644 --- a/tests/baselines/reference/specializedSignatureAsCallbackParameter1.js +++ b/tests/baselines/reference/specializedSignatureAsCallbackParameter1.js @@ -13,9 +13,5 @@ function x3(a, cb) { cb(a); } // both are errors -x3(1, function (x) { - return 1; -}); -x3(1, function (x) { - return 1; -}); +x3(1, function (x) { return 1; }); +x3(1, function (x) { return 1; }); diff --git a/tests/baselines/reference/specializedSignatureIsNotSubtypeOfNonSpecializedSignature.js b/tests/baselines/reference/specializedSignatureIsNotSubtypeOfNonSpecializedSignature.js index eaf0605ef1..e5e06d48a8 100644 --- a/tests/baselines/reference/specializedSignatureIsNotSubtypeOfNonSpecializedSignature.js +++ b/tests/baselines/reference/specializedSignatureIsNotSubtypeOfNonSpecializedSignature.js @@ -69,27 +69,23 @@ var a3: { //// [specializedSignatureIsNotSubtypeOfNonSpecializedSignature.js] // Specialized signatures must be a subtype of a non-specialized signature // All the below should be errors -function foo(x) { -} +function foo(x) { } var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; + C.prototype.foo = function (x) { }; return C; })(); var C2 = (function () { function C2() { } - C2.prototype.foo = function (x) { - }; + C2.prototype.foo = function (x) { }; return C2; })(); var C3 = (function () { function C3() { } - C3.prototype.foo = function (x) { - }; + C3.prototype.foo = function (x) { }; return C3; })(); var a; diff --git a/tests/baselines/reference/specializedSignatureIsSubtypeOfNonSpecializedSignature.js b/tests/baselines/reference/specializedSignatureIsSubtypeOfNonSpecializedSignature.js index 882d0da912..17a886a078 100644 --- a/tests/baselines/reference/specializedSignatureIsSubtypeOfNonSpecializedSignature.js +++ b/tests/baselines/reference/specializedSignatureIsSubtypeOfNonSpecializedSignature.js @@ -84,27 +84,23 @@ var a3: { //// [specializedSignatureIsSubtypeOfNonSpecializedSignature.js] // Specialized signatures must be a subtype of a non-specialized signature // All the below should not be errors -function foo(x) { -} +function foo(x) { } var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; + C.prototype.foo = function (x) { }; return C; })(); var C2 = (function () { function C2() { } - C2.prototype.foo = function (x) { - }; + C2.prototype.foo = function (x) { }; return C2; })(); var C3 = (function () { function C3() { } - C3.prototype.foo = function (x) { - }; + C3.prototype.foo = function (x) { }; return C3; })(); var a; diff --git a/tests/baselines/reference/staticAndMemberFunctions.js b/tests/baselines/reference/staticAndMemberFunctions.js index 0d1d9e8190..71f146b72f 100644 --- a/tests/baselines/reference/staticAndMemberFunctions.js +++ b/tests/baselines/reference/staticAndMemberFunctions.js @@ -8,9 +8,7 @@ class T { var T = (function () { function T() { } - T.x = function () { - }; - T.prototype.y = function () { - }; + T.x = function () { }; + T.prototype.y = function () { }; return T; })(); diff --git a/tests/baselines/reference/staticAndNonStaticPropertiesSameName.js b/tests/baselines/reference/staticAndNonStaticPropertiesSameName.js index ccfbcc8560..be667ae1f3 100644 --- a/tests/baselines/reference/staticAndNonStaticPropertiesSameName.js +++ b/tests/baselines/reference/staticAndNonStaticPropertiesSameName.js @@ -11,9 +11,7 @@ class C { var C = (function () { function C() { } - C.prototype.f = function () { - }; - C.f = function () { - }; + C.prototype.f = function () { }; + C.f = function () { }; return C; })(); diff --git a/tests/baselines/reference/staticClassProps.js b/tests/baselines/reference/staticClassProps.js index 3dc7dbb67d..aad40e29b7 100644 --- a/tests/baselines/reference/staticClassProps.js +++ b/tests/baselines/reference/staticClassProps.js @@ -12,8 +12,7 @@ class C var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; C.z = 1; return C; })(); diff --git a/tests/baselines/reference/staticFactory1.js b/tests/baselines/reference/staticFactory1.js index af5780d96c..529cc230d7 100644 --- a/tests/baselines/reference/staticFactory1.js +++ b/tests/baselines/reference/staticFactory1.js @@ -23,9 +23,7 @@ var __extends = this.__extends || function (d, b) { var Base = (function () { function Base() { } - Base.prototype.foo = function () { - return 1; - }; + Base.prototype.foo = function () { return 1; }; Base.create = function () { return new this(); }; @@ -36,9 +34,7 @@ var Derived = (function (_super) { function Derived() { _super.apply(this, arguments); } - Derived.prototype.foo = function () { - return 2; - }; + Derived.prototype.foo = function () { return 2; }; return Derived; })(Base); var d = Derived.create(); diff --git a/tests/baselines/reference/staticGetterAndSetter.js b/tests/baselines/reference/staticGetterAndSetter.js index 7c6ef26e73..5c61af0b7c 100644 --- a/tests/baselines/reference/staticGetterAndSetter.js +++ b/tests/baselines/reference/staticGetterAndSetter.js @@ -10,11 +10,8 @@ var Foo = (function () { function Foo() { } Object.defineProperty(Foo, "Foo", { - get: function () { - return 0; - }, - set: function (n) { - }, + get: function () { return 0; }, + set: function (n) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/staticInheritance.js b/tests/baselines/reference/staticInheritance.js index dfe39119d3..a577bad3a8 100644 --- a/tests/baselines/reference/staticInheritance.js +++ b/tests/baselines/reference/staticInheritance.js @@ -18,8 +18,7 @@ var __extends = this.__extends || function (d, b) { __.prototype = b.prototype; d.prototype = new __(); }; -function doThing(x) { -} +function doThing(x) { } var A = (function () { function A() { this.p = doThing(A); // OK diff --git a/tests/baselines/reference/staticInstanceResolution4.js b/tests/baselines/reference/staticInstanceResolution4.js index 6e81d67dc0..c74030d047 100644 --- a/tests/baselines/reference/staticInstanceResolution4.js +++ b/tests/baselines/reference/staticInstanceResolution4.js @@ -9,8 +9,7 @@ A.foo(); var A = (function () { function A() { } - A.prototype.foo = function () { - }; + A.prototype.foo = function () { }; return A; })(); A.foo(); diff --git a/tests/baselines/reference/staticInstanceResolution5.js b/tests/baselines/reference/staticInstanceResolution5.js index 6ca976ae46..843b79ec6f 100644 --- a/tests/baselines/reference/staticInstanceResolution5.js +++ b/tests/baselines/reference/staticInstanceResolution5.js @@ -19,10 +19,7 @@ function z(w3: WinJS) { } //// [staticInstanceResolution5_1.js] define(["require", "exports"], function (require, exports) { // these 3 should be errors - var x = function (w1) { - }; - var y = function (w2) { - }; - function z(w3) { - } + var x = function (w1) { }; + var y = function (w2) { }; + function z(w3) { } }); diff --git a/tests/baselines/reference/staticMemberAssignsToConstructorFunctionMembers.js b/tests/baselines/reference/staticMemberAssignsToConstructorFunctionMembers.js index df0858edc0..edd657d7da 100644 --- a/tests/baselines/reference/staticMemberAssignsToConstructorFunctionMembers.js +++ b/tests/baselines/reference/staticMemberAssignsToConstructorFunctionMembers.js @@ -17,18 +17,12 @@ var C = (function () { function C() { } C.foo = function () { - C.foo = function () { - }; + C.foo = function () { }; }; C.bar = function (x) { - C.bar = function () { - }; // error - C.bar = function (x) { - return x; - }; // ok - C.bar = function (x) { - return 1; - }; // ok + C.bar = function () { }; // error + C.bar = function (x) { return x; }; // ok + C.bar = function (x) { return 1; }; // ok return 1; }; return C; diff --git a/tests/baselines/reference/staticMemberExportAccess.js b/tests/baselines/reference/staticMemberExportAccess.js index 5de5a76ca7..3779935670 100644 --- a/tests/baselines/reference/staticMemberExportAccess.js +++ b/tests/baselines/reference/staticMemberExportAccess.js @@ -24,9 +24,7 @@ Sammy.bar(); var Sammy = (function () { function Sammy() { } - Sammy.prototype.foo = function () { - return "hi"; - }; + Sammy.prototype.foo = function () { return "hi"; }; Sammy.bar = function () { return -1; }; diff --git a/tests/baselines/reference/staticMemberOfClassAndPublicMemberOfAnotherClassAssignment.js b/tests/baselines/reference/staticMemberOfClassAndPublicMemberOfAnotherClassAssignment.js index 23e6fa9dd0..7b24a29b32 100644 --- a/tests/baselines/reference/staticMemberOfClassAndPublicMemberOfAnotherClassAssignment.js +++ b/tests/baselines/reference/staticMemberOfClassAndPublicMemberOfAnotherClassAssignment.js @@ -29,15 +29,13 @@ c = a; var B = (function () { function B() { } - B.prototype.name = function () { - }; + B.prototype.name = function () { }; return B; })(); var C = (function () { function C() { } - C.name = function () { - }; + C.name = function () { }; return C; })(); var a = new B(); diff --git a/tests/baselines/reference/staticMembersUsingClassTypeParameter.js b/tests/baselines/reference/staticMembersUsingClassTypeParameter.js index 1c31ef82d9..0c728cdbab 100644 --- a/tests/baselines/reference/staticMembersUsingClassTypeParameter.js +++ b/tests/baselines/reference/staticMembersUsingClassTypeParameter.js @@ -20,21 +20,18 @@ class C3 { var C = (function () { function C() { } - C.f = function (x) { - }; + C.f = function (x) { }; return C; })(); var C2 = (function () { function C2() { } - C2.f = function (x) { - }; + C2.f = function (x) { }; return C2; })(); var C3 = (function () { function C3() { } - C3.f = function (x) { - }; + C3.f = function (x) { }; return C3; })(); diff --git a/tests/baselines/reference/staticMethodsReferencingClassTypeParameters.js b/tests/baselines/reference/staticMethodsReferencingClassTypeParameters.js index 499e16ec58..76fa7d6249 100644 --- a/tests/baselines/reference/staticMethodsReferencingClassTypeParameters.js +++ b/tests/baselines/reference/staticMethodsReferencingClassTypeParameters.js @@ -7,8 +7,6 @@ class C { var C = (function () { function C() { } - C.s = function (p) { - return p; - }; + C.s = function (p) { return p; }; return C; })(); diff --git a/tests/baselines/reference/staticModifierAlreadySeen.js b/tests/baselines/reference/staticModifierAlreadySeen.js index b097f3924e..d767a9b51d 100644 --- a/tests/baselines/reference/staticModifierAlreadySeen.js +++ b/tests/baselines/reference/staticModifierAlreadySeen.js @@ -8,8 +8,7 @@ class C { var C = (function () { function C() { } - C.bar = function () { - }; + C.bar = function () { }; C.foo = 1; return C; })(); diff --git a/tests/baselines/reference/staticOffOfInstance1.js b/tests/baselines/reference/staticOffOfInstance1.js index 41b7cd895b..58cf24d052 100644 --- a/tests/baselines/reference/staticOffOfInstance1.js +++ b/tests/baselines/reference/staticOffOfInstance1.js @@ -13,7 +13,6 @@ var List = (function () { List.prototype.Blah = function () { this.Foo(); }; - List.Foo = function () { - }; + List.Foo = function () { }; return List; })(); diff --git a/tests/baselines/reference/staticOffOfInstance2.js b/tests/baselines/reference/staticOffOfInstance2.js index ff139859bf..ceac77419a 100644 --- a/tests/baselines/reference/staticOffOfInstance2.js +++ b/tests/baselines/reference/staticOffOfInstance2.js @@ -16,7 +16,6 @@ var List = (function () { this.Foo(); // no error List.Foo(); }; - List.Foo = function () { - }; + List.Foo = function () { }; return List; })(); diff --git a/tests/baselines/reference/staticPropertyAndFunctionWithSameName.js b/tests/baselines/reference/staticPropertyAndFunctionWithSameName.js index 0308805cd7..50252c606f 100644 --- a/tests/baselines/reference/staticPropertyAndFunctionWithSameName.js +++ b/tests/baselines/reference/staticPropertyAndFunctionWithSameName.js @@ -18,7 +18,6 @@ var C = (function () { var D = (function () { function D() { } - D.prototype.f = function () { - }; + D.prototype.f = function () { }; return D; })(); diff --git a/tests/baselines/reference/staticPropertyNotInClassType.js b/tests/baselines/reference/staticPropertyNotInClassType.js index 22ff4276de..e9df2b2158 100644 --- a/tests/baselines/reference/staticPropertyNotInClassType.js +++ b/tests/baselines/reference/staticPropertyNotInClassType.js @@ -47,15 +47,10 @@ var NonGeneric; this.a = a; this.b = b; } - C.prototype.fn = function () { - return this; - }; + C.prototype.fn = function () { return this; }; Object.defineProperty(C, "x", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -78,15 +73,10 @@ var Generic; this.a = a; this.b = b; } - C.prototype.fn = function () { - return this; - }; + C.prototype.fn = function () { return this; }; Object.defineProperty(C, "x", { - get: function () { - return 1; - }, - set: function (v) { - }, + get: function () { return 1; }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/staticPrototypeProperty.js b/tests/baselines/reference/staticPrototypeProperty.js index cfd81bedee..471ec743b5 100644 --- a/tests/baselines/reference/staticPrototypeProperty.js +++ b/tests/baselines/reference/staticPrototypeProperty.js @@ -11,8 +11,7 @@ class C2 { var C = (function () { function C() { } - C.prototype = function () { - }; + C.prototype = function () { }; return C; })(); var C2 = (function () { diff --git a/tests/baselines/reference/staticVisibility.js b/tests/baselines/reference/staticVisibility.js index 0da2e3dbe2..7dbf49a2ba 100644 --- a/tests/baselines/reference/staticVisibility.js +++ b/tests/baselines/reference/staticVisibility.js @@ -58,13 +58,9 @@ var C2 = (function () { this.barback = ""; } Object.defineProperty(C2, "Bar", { - get: function () { - return "bar"; - } // ok + get: function () { return "bar"; } // ok , - set: function (bar) { - barback = bar; - } // not ok + set: function (bar) { barback = bar; } // not ok , enumerable: true, configurable: true diff --git a/tests/baselines/reference/statics.js b/tests/baselines/reference/statics.js index 4da39198b2..c69fa0aabd 100644 --- a/tests/baselines/reference/statics.js +++ b/tests/baselines/reference/statics.js @@ -40,9 +40,7 @@ var M; this.c1 = c1; this.c2 = c2; this.x = C.y + this.c1 + this.c2 + c3; - this.g = function (v) { - return C.f(_this.x + C.y + v + _this.c1 + _this.c2 + C.pub); - }; + this.g = function (v) { return C.f(_this.x + C.y + v + _this.c1 + _this.c2 + C.pub); }; } C.f = function (n) { return "wow: " + (n + C.y + C.pub + C.priv); diff --git a/tests/baselines/reference/staticsInAFunction.js b/tests/baselines/reference/staticsInAFunction.js index e6959b7757..e918f4b290 100644 --- a/tests/baselines/reference/staticsInAFunction.js +++ b/tests/baselines/reference/staticsInAFunction.js @@ -11,6 +11,5 @@ function boo() { test(); test(name, string); test(name ? : any); - { - } + { } } diff --git a/tests/baselines/reference/staticsInConstructorBodies.js b/tests/baselines/reference/staticsInConstructorBodies.js index 044f183b37..bb91b52a18 100644 --- a/tests/baselines/reference/staticsInConstructorBodies.js +++ b/tests/baselines/reference/staticsInConstructorBodies.js @@ -10,8 +10,7 @@ class C { var C = (function () { function C() { } - C.m1 = function () { - }; // ERROR + C.m1 = function () { }; // ERROR C.p1 = 0; // ERROR return C; })(); diff --git a/tests/baselines/reference/strictMode5.js b/tests/baselines/reference/strictMode5.js index c46de926db..8e4021820f 100644 --- a/tests/baselines/reference/strictMode5.js +++ b/tests/baselines/reference/strictMode5.js @@ -36,8 +36,7 @@ var A = (function () { return _this.n(); }; }; - A.prototype.n = function () { - }; + A.prototype.n = function () { }; return A; })(); function bar(x) { diff --git a/tests/baselines/reference/stringIndexerAndConstructor.js b/tests/baselines/reference/stringIndexerAndConstructor.js index 6d4cc3747c..db3b9b8770 100644 --- a/tests/baselines/reference/stringIndexerAndConstructor.js +++ b/tests/baselines/reference/stringIndexerAndConstructor.js @@ -17,7 +17,6 @@ interface I { var C = (function () { function C() { } - C.v = function () { - }; + C.v = function () { }; return C; })(); diff --git a/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations.js b/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations.js index ed96311f52..9d70b66887 100644 --- a/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations.js +++ b/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations.js @@ -106,8 +106,7 @@ var C = (function () { get: function () { return ''; }, - set: function (v) { - } // ok + set: function (v) { } // ok , enumerable: true, configurable: true @@ -115,8 +114,7 @@ var C = (function () { C.prototype.foo = function () { return ''; }; - C.foo = function () { - }; // ok + C.foo = function () { }; // ok Object.defineProperty(C, "X", { get: function () { return 1; @@ -131,8 +129,7 @@ var a; var b = { a: '', b: 1, - c: function () { - }, + c: function () { }, "d": '', "e": 1, 1.0: '', @@ -143,8 +140,7 @@ var b = { get X() { return ''; }, - set X(v) { - }, + set X(v) { }, foo: function () { return ''; } diff --git a/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations2.js b/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations2.js index b9195403b2..c9278c4044 100644 --- a/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations2.js +++ b/tests/baselines/reference/stringIndexerConstrainsPropertyDeclarations2.js @@ -50,9 +50,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.foo = function () { - return ''; - }; + A.prototype.foo = function () { return ''; }; return A; })(); var B = (function (_super) { @@ -60,9 +58,7 @@ var B = (function (_super) { function B() { _super.apply(this, arguments); } - B.prototype.bar = function () { - return ''; - }; + B.prototype.bar = function () { return ''; }; return B; })(A); var Foo = (function () { diff --git a/tests/baselines/reference/stringIndexingResults.js b/tests/baselines/reference/stringIndexingResults.js index 4e80c25d9b..a6e00d92ec 100644 --- a/tests/baselines/reference/stringIndexingResults.js +++ b/tests/baselines/reference/stringIndexingResults.js @@ -54,9 +54,7 @@ var a; var r7 = a['y']; var r8 = a['a']; var r9 = a[1]; -var b = { - y: '' -}; +var b = { y: '' }; var r10 = b['y']; var r11 = b['a']; var r12 = b[1]; diff --git a/tests/baselines/reference/stringLiteralObjectLiteralDeclaration1.js b/tests/baselines/reference/stringLiteralObjectLiteralDeclaration1.js index a367c3400f..2c9e54e610 100644 --- a/tests/baselines/reference/stringLiteralObjectLiteralDeclaration1.js +++ b/tests/baselines/reference/stringLiteralObjectLiteralDeclaration1.js @@ -7,9 +7,7 @@ module m1 { //// [stringLiteralObjectLiteralDeclaration1.js] var m1; (function (m1) { - m1.n = { - 'foo bar': 4 - }; + m1.n = { 'foo bar': 4 }; })(m1 || (m1 = {})); diff --git a/tests/baselines/reference/stringLiteralPropertyNameWithLineContinuation1.js b/tests/baselines/reference/stringLiteralPropertyNameWithLineContinuation1.js index 0c46d72e23..99ed3fb320 100644 --- a/tests/baselines/reference/stringLiteralPropertyNameWithLineContinuation1.js +++ b/tests/baselines/reference/stringLiteralPropertyNameWithLineContinuation1.js @@ -5,8 +5,6 @@ x.text = "bar" //// [stringLiteralPropertyNameWithLineContinuation1.js] -var x = { - 'text\ -': 'hello' -}; +var x = { 'text\ +': 'hello' }; x.text = "bar"; diff --git a/tests/baselines/reference/stringLiteralTypeIsSubtypeOfString.js b/tests/baselines/reference/stringLiteralTypeIsSubtypeOfString.js index 64609d96ec..01b5dc814a 100644 --- a/tests/baselines/reference/stringLiteralTypeIsSubtypeOfString.js +++ b/tests/baselines/reference/stringLiteralTypeIsSubtypeOfString.js @@ -102,36 +102,21 @@ function f16(x: any) { } //// [stringLiteralTypeIsSubtypeOfString.js] // string literal types are subtypes of string, any -function f1(x) { -} -function f2(x) { -} -function f3(x) { -} -function f4(x) { -} -function f5(x) { -} -function f6(x) { -} -function f7(x) { -} -function f8(x) { -} -function f9(x) { -} +function f1(x) { } +function f2(x) { } +function f3(x) { } +function f4(x) { } +function f5(x) { } +function f6(x) { } +function f7(x) { } +function f8(x) { } +function f9(x) { } var C = (function () { function C() { } - C.prototype.toString = function () { - return null; - }; - C.prototype.charAt = function (pos) { - return null; - }; - C.prototype.charCodeAt = function (index) { - return null; - }; + C.prototype.toString = function () { return null; }; + C.prototype.charAt = function (pos) { return null; }; + C.prototype.charCodeAt = function (index) { return null; }; C.prototype.concat = function () { var strings = []; for (var _i = 0; _i < arguments.length; _i++) { @@ -139,71 +124,32 @@ var C = (function () { } return null; }; - C.prototype.indexOf = function (searchString, position) { - return null; - }; - C.prototype.lastIndexOf = function (searchString, position) { - return null; - }; - C.prototype.localeCompare = function (that) { - return null; - }; - C.prototype.match = function (regexp) { - return null; - }; - C.prototype.replace = function (searchValue, replaceValue) { - return null; - }; - C.prototype.search = function (regexp) { - return null; - }; - C.prototype.slice = function (start, end) { - return null; - }; - C.prototype.split = function (separator, limit) { - return null; - }; - C.prototype.substring = function (start, end) { - return null; - }; - C.prototype.toLowerCase = function () { - return null; - }; - C.prototype.toLocaleLowerCase = function () { - return null; - }; - C.prototype.toUpperCase = function () { - return null; - }; - C.prototype.toLocaleUpperCase = function () { - return null; - }; - C.prototype.trim = function () { - return null; - }; - C.prototype.substr = function (from, length) { - return null; - }; - C.prototype.valueOf = function () { - return null; - }; + C.prototype.indexOf = function (searchString, position) { return null; }; + C.prototype.lastIndexOf = function (searchString, position) { return null; }; + C.prototype.localeCompare = function (that) { return null; }; + C.prototype.match = function (regexp) { return null; }; + C.prototype.replace = function (searchValue, replaceValue) { return null; }; + C.prototype.search = function (regexp) { return null; }; + C.prototype.slice = function (start, end) { return null; }; + C.prototype.split = function (separator, limit) { return null; }; + C.prototype.substring = function (start, end) { return null; }; + C.prototype.toLowerCase = function () { return null; }; + C.prototype.toLocaleLowerCase = function () { return null; }; + C.prototype.toUpperCase = function () { return null; }; + C.prototype.toLocaleUpperCase = function () { return null; }; + C.prototype.trim = function () { return null; }; + C.prototype.substr = function (from, length) { return null; }; + C.prototype.valueOf = function () { return null; }; return C; })(); -function f10(x) { -} -function f11(x) { -} -function f12(x) { -} -function f13(x) { -} +function f10(x) { } +function f11(x) { } +function f12(x) { } +function f13(x) { } var E; (function (E) { E[E["A"] = 0] = "A"; })(E || (E = {})); -function f14(x) { -} -function f15(x) { -} -function f16(x) { -} +function f14(x) { } +function f15(x) { } +function f16(x) { } diff --git a/tests/baselines/reference/stringLiteralTypesInImplementationSignatures.js b/tests/baselines/reference/stringLiteralTypesInImplementationSignatures.js index dc2b2a7341..724c20c630 100644 --- a/tests/baselines/reference/stringLiteralTypesInImplementationSignatures.js +++ b/tests/baselines/reference/stringLiteralTypesInImplementationSignatures.js @@ -28,25 +28,18 @@ var b = { //// [stringLiteralTypesInImplementationSignatures.js] // String literal types are only valid in overload signatures -function foo(x) { -} -var f = function foo(x) { -}; -var f2 = function (x, y) { -}; +function foo(x) { } +var f = function foo(x) { }; +var f2 = function (x, y) { }; var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; + C.prototype.foo = function (x) { }; return C; })(); var a; var b = { - foo: function (x) { - }, - a: function foo(x, y) { - }, - b: function (x) { - } + foo: function (x) { }, + a: function foo(x, y) { }, + b: function (x) { } }; diff --git a/tests/baselines/reference/stringLiteralTypesInImplementationSignatures2.js b/tests/baselines/reference/stringLiteralTypesInImplementationSignatures2.js index 2ecd3330e2..5050709c21 100644 --- a/tests/baselines/reference/stringLiteralTypesInImplementationSignatures2.js +++ b/tests/baselines/reference/stringLiteralTypesInImplementationSignatures2.js @@ -31,19 +31,15 @@ var b = { //// [stringLiteralTypesInImplementationSignatures2.js] // String literal types are only valid in overload signatures -function foo(x) { -} +function foo(x) { } var C = (function () { function C() { } - C.prototype.foo = function (x) { - }; + C.prototype.foo = function (x) { }; return C; })(); var a; var b = { - foo: function (x) { - }, - foo: function (x) { - } + foo: function (x) { }, + foo: function (x) { } }; diff --git a/tests/baselines/reference/stringPropCodeGen.js b/tests/baselines/reference/stringPropCodeGen.js index 46e1a6eb92..ae8cfa3d5a 100644 --- a/tests/baselines/reference/stringPropCodeGen.js +++ b/tests/baselines/reference/stringPropCodeGen.js @@ -15,8 +15,7 @@ a.bar.toString(); //// [stringPropCodeGen.js] var a = { - "foo": function () { - }, + "foo": function () { }, "bar": 5 }; a.foo(); diff --git a/tests/baselines/reference/stripInternal1.js b/tests/baselines/reference/stripInternal1.js index 9deadf1fc3..c5d350bcd8 100644 --- a/tests/baselines/reference/stripInternal1.js +++ b/tests/baselines/reference/stripInternal1.js @@ -10,11 +10,9 @@ class C { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; // @internal - C.prototype.bar = function () { - }; + C.prototype.bar = function () { }; return C; })(); diff --git a/tests/baselines/reference/structural1.js b/tests/baselines/reference/structural1.js index ebafbc8f0a..73b033a525 100644 --- a/tests/baselines/reference/structural1.js +++ b/tests/baselines/reference/structural1.js @@ -18,8 +18,5 @@ var M; function f(i) { } M.f = f; - f({ - salt: 2, - pepper: 0 - }); + f({ salt: 2, pepper: 0 }); })(M || (M = {})); diff --git a/tests/baselines/reference/subtypesOfAny.js b/tests/baselines/reference/subtypesOfAny.js index 973db6a9a7..e73a120ed6 100644 --- a/tests/baselines/reference/subtypesOfAny.js +++ b/tests/baselines/reference/subtypesOfAny.js @@ -149,8 +149,7 @@ var E; (function (E) { E[E["A"] = 0] = "A"; })(E || (E = {})); -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; diff --git a/tests/baselines/reference/subtypesOfTypeParameter.js b/tests/baselines/reference/subtypesOfTypeParameter.js index d9901e6cea..7fe3d28278 100644 --- a/tests/baselines/reference/subtypesOfTypeParameter.js +++ b/tests/baselines/reference/subtypesOfTypeParameter.js @@ -143,8 +143,7 @@ var E; (function (E) { E[E["A"] = 0] = "A"; })(E || (E = {})); -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; @@ -175,22 +174,12 @@ function f2(x, y) { var r4 = true ? x : new Date(); var r5 = true ? /1/ : x; var r5 = true ? x : /1/; - var r6 = true ? { - foo: 1 - } : x; - var r6 = true ? x : { - foo: 1 - }; - var r7 = true ? function () { - } : x; - var r7 = true ? x : function () { - }; - var r8 = true ? function (x) { - return x; - } : x; - var r8b = true ? x : function (x) { - return x; - }; // type parameters not identical across declarations + var r6 = true ? { foo: 1 } : x; + var r6 = true ? x : { foo: 1 }; + var r7 = true ? function () { } : x; + var r7 = true ? x : function () { }; + var r8 = true ? function (x) { return x; } : x; + var r8b = true ? x : function (x) { return x; }; // type parameters not identical across declarations var i1; var r9 = true ? i1 : x; var r9 = true ? x : i1; diff --git a/tests/baselines/reference/subtypesOfTypeParameterWithConstraints2.js b/tests/baselines/reference/subtypesOfTypeParameterWithConstraints2.js index 07f2170aca..e1c137f77e 100644 --- a/tests/baselines/reference/subtypesOfTypeParameterWithConstraints2.js +++ b/tests/baselines/reference/subtypesOfTypeParameterWithConstraints2.js @@ -199,8 +199,7 @@ var E; (function (E) { E[E["A"] = 0] = "A"; })(E || (E = {})); -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; @@ -242,26 +241,16 @@ function f9(x) { var r5 = true ? x : /1/; // ok } function f10(x) { - var r6 = true ? { - foo: 1 - } : x; // ok - var r6 = true ? x : { - foo: 1 - }; // ok + var r6 = true ? { foo: 1 } : x; // ok + var r6 = true ? x : { foo: 1 }; // ok } function f11(x) { - var r7 = true ? function () { - } : x; // ok - var r7 = true ? x : function () { - }; // ok + var r7 = true ? function () { } : x; // ok + var r7 = true ? x : function () { }; // ok } function f12(x) { - var r8 = true ? function (x) { - return x; - } : x; // ok - var r8b = true ? x : function (x) { - return x; - }; // ok, type parameters not identical across declarations + var r8 = true ? function (x) { return x; } : x; // ok + var r8b = true ? x : function (x) { return x; }; // ok, type parameters not identical across declarations } function f13(x) { var i1; diff --git a/tests/baselines/reference/subtypesOfUnion.js b/tests/baselines/reference/subtypesOfUnion.js index a18ebb944b..926efc3e92 100644 --- a/tests/baselines/reference/subtypesOfUnion.js +++ b/tests/baselines/reference/subtypesOfUnion.js @@ -68,8 +68,7 @@ var A2 = (function () { } return A2; })(); -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; diff --git a/tests/baselines/reference/subtypingWithCallSignatures.js b/tests/baselines/reference/subtypingWithCallSignatures.js index 560871cce4..73ca2c6543 100644 --- a/tests/baselines/reference/subtypingWithCallSignatures.js +++ b/tests/baselines/reference/subtypingWithCallSignatures.js @@ -14,16 +14,8 @@ module CallSignature { //// [subtypingWithCallSignatures.js] var CallSignature; (function (CallSignature) { - var r = foo1(function (x) { - return 1; - }); // ok because base returns void - var r2 = foo1(function (x) { - return ''; - }); // ok because base returns void - var r3 = foo2(function (x, y) { - return 1; - }); // ok because base returns void - var r4 = foo2(function (x) { - return ''; - }); // ok because base returns void + var r = foo1(function (x) { return 1; }); // ok because base returns void + var r2 = foo1(function (x) { return ''; }); // ok because base returns void + var r3 = foo2(function (x, y) { return 1; }); // ok because base returns void + var r4 = foo2(function (x) { return ''; }); // ok because base returns void })(CallSignature || (CallSignature = {})); diff --git a/tests/baselines/reference/subtypingWithCallSignatures2.js b/tests/baselines/reference/subtypingWithCallSignatures2.js index cd430902af..e134191473 100644 --- a/tests/baselines/reference/subtypingWithCallSignatures2.js +++ b/tests/baselines/reference/subtypingWithCallSignatures2.js @@ -206,160 +206,51 @@ var OtherDerived = (function (_super) { } return OtherDerived; })(Base); -var r1arg1 = function (x) { - return [ - x - ]; -}; -var r1arg2 = function (x) { - return [ - 1 - ]; -}; +var r1arg1 = function (x) { return [x]; }; +var r1arg2 = function (x) { return [1]; }; var r1 = foo1(r1arg1); // any, return types are not subtype of first overload -var r1a = [ - r1arg2, - r1arg1 -]; // generic signature, subtype in both directions -var r1b = [ - r1arg1, - r1arg2 -]; // generic signature, subtype in both directions -var r2arg1 = function (x) { - return [ - '' - ]; -}; -var r2arg2 = function (x) { - return [ - '' - ]; -}; +var r1a = [r1arg2, r1arg1]; // generic signature, subtype in both directions +var r1b = [r1arg1, r1arg2]; // generic signature, subtype in both directions +var r2arg1 = function (x) { return ['']; }; +var r2arg2 = function (x) { return ['']; }; var r2 = foo2(r2arg1); -var r2a = [ - r2arg1, - r2arg2 -]; -var r2b = [ - r2arg2, - r2arg1 -]; -var r3arg1 = function (x) { - return x; -}; -var r3arg2 = function (x) { -}; +var r2a = [r2arg1, r2arg2]; +var r2b = [r2arg2, r2arg1]; +var r3arg1 = function (x) { return x; }; +var r3arg2 = function (x) { }; var r3 = foo3(r3arg1); -var r3a = [ - r3arg1, - r3arg2 -]; -var r3b = [ - r3arg2, - r3arg1 -]; -var r4arg1 = function (x, y) { - return x; -}; -var r4arg2 = function (x, y) { - return ''; -}; +var r3a = [r3arg1, r3arg2]; +var r3b = [r3arg2, r3arg1]; +var r4arg1 = function (x, y) { return x; }; +var r4arg2 = function (x, y) { return ''; }; var r4 = foo4(r4arg1); // any -var r4a = [ - r4arg1, - r4arg2 -]; -var r4b = [ - r4arg2, - r4arg1 -]; -var r5arg1 = function (x) { - return null; -}; -var r5arg2 = function (x) { - return ''; -}; +var r4a = [r4arg1, r4arg2]; +var r4b = [r4arg2, r4arg1]; +var r5arg1 = function (x) { return null; }; +var r5arg2 = function (x) { return ''; }; var r5 = foo5(r5arg1); // any -var r5a = [ - r5arg1, - r5arg2 -]; -var r5b = [ - r5arg2, - r5arg1 -]; -var r6arg1 = function (x) { - return null; -}; -var r6arg2 = function (x) { - return null; -}; +var r5a = [r5arg1, r5arg2]; +var r5b = [r5arg2, r5arg1]; +var r6arg1 = function (x) { return null; }; +var r6arg2 = function (x) { return null; }; var r6 = foo6(r6arg1); // any -var r6a = [ - r6arg1, - r6arg2 -]; -var r6b = [ - r6arg2, - r6arg1 -]; -var r7arg1 = function (x) { - return function (r) { - return null; - }; -}; -var r7arg2 = function (x) { - return function (r) { - return null; - }; -}; +var r6a = [r6arg1, r6arg2]; +var r6b = [r6arg2, r6arg1]; +var r7arg1 = function (x) { return function (r) { return null; }; }; +var r7arg2 = function (x) { return function (r) { return null; }; }; var r7 = foo7(r7arg1); // any -var r7a = [ - r7arg1, - r7arg2 -]; -var r7b = [ - r7arg2, - r7arg1 -]; -var r8arg1 = function (x, y) { - return function (r) { - return null; - }; -}; -var r8arg2 = function (x, y) { - return function (r) { - return null; - }; -}; +var r7a = [r7arg1, r7arg2]; +var r7b = [r7arg2, r7arg1]; +var r8arg1 = function (x, y) { return function (r) { return null; }; }; +var r8arg2 = function (x, y) { return function (r) { return null; }; }; var r8 = foo8(r8arg1); // any -var r8a = [ - r8arg1, - r8arg2 -]; -var r8b = [ - r8arg2, - r8arg1 -]; -var r9arg1 = function (x, y) { - return function (r) { - return null; - }; -}; -var r9arg2 = function (x, y) { - return function (r) { - return null; - }; -}; +var r8a = [r8arg1, r8arg2]; +var r8b = [r8arg2, r8arg1]; +var r9arg1 = function (x, y) { return function (r) { return null; }; }; +var r9arg2 = function (x, y) { return function (r) { return null; }; }; var r9 = foo9(r9arg1); // any -var r9a = [ - r9arg1, - r9arg2 -]; -var r9b = [ - r9arg2, - r9arg1 -]; +var r9a = [r9arg1, r9arg2]; +var r9b = [r9arg2, r9arg1]; var r10arg1 = function () { var x = []; for (var _i = 0; _i < arguments.length; _i++) { @@ -375,89 +266,33 @@ var r10arg2 = function () { return null; }; var r10 = foo10(r10arg1); // any -var r10a = [ - r10arg1, - r10arg2 -]; -var r10b = [ - r10arg2, - r10arg1 -]; -var r11arg1 = function (x, y) { - return x; -}; -var r11arg2 = function (x, y) { - return null; -}; +var r10a = [r10arg1, r10arg2]; +var r10b = [r10arg2, r10arg1]; +var r11arg1 = function (x, y) { return x; }; +var r11arg2 = function (x, y) { return null; }; var r11 = foo11(r11arg1); // any -var r11a = [ - r11arg1, - r11arg2 -]; -var r11b = [ - r11arg2, - r11arg1 -]; -var r12arg1 = function (x, y) { - return null; -}; -var r12arg2 = function (x, y) { - return null; -}; +var r11a = [r11arg1, r11arg2]; +var r11b = [r11arg2, r11arg1]; +var r12arg1 = function (x, y) { return null; }; +var r12arg2 = function (x, y) { return null; }; var r12 = foo12(r12arg1); // any -var r12a = [ - r12arg1, - r12arg2 -]; -var r12b = [ - r12arg2, - r12arg1 -]; -var r13arg1 = function (x, y) { - return y; -}; -var r13arg2 = function (x, y) { - return null; -}; +var r12a = [r12arg1, r12arg2]; +var r12b = [r12arg2, r12arg1]; +var r13arg1 = function (x, y) { return y; }; +var r13arg2 = function (x, y) { return null; }; var r13 = foo13(r13arg1); // any -var r13a = [ - r13arg1, - r13arg2 -]; -var r13b = [ - r13arg2, - r13arg1 -]; -var r14arg1 = function (x) { - return x.a; -}; -var r14arg2 = function (x) { - return null; -}; +var r13a = [r13arg1, r13arg2]; +var r13b = [r13arg2, r13arg1]; +var r14arg1 = function (x) { return x.a; }; +var r14arg2 = function (x) { return null; }; var r14 = foo14(r14arg1); // any -var r14a = [ - r14arg1, - r14arg2 -]; -var r14b = [ - r14arg2, - r14arg1 -]; -var r15arg1 = function (x) { - return null; -}; +var r14a = [r14arg1, r14arg2]; +var r14b = [r14arg2, r14arg1]; +var r15arg1 = function (x) { return null; }; var r15 = foo15(r15arg1); // any -var r16arg1 = function (x) { - return [ - 1 - ]; -}; +var r16arg1 = function (x) { return [1]; }; var r16 = foo16(r16arg1); -var r17arg1 = function (x) { - return null; -}; +var r17arg1 = function (x) { return null; }; var r17 = foo17(r17arg1); // any -var r18arg1 = function (x) { - return null; -}; +var r18arg1 = function (x) { return null; }; var r18 = foo18(r18arg1); diff --git a/tests/baselines/reference/subtypingWithCallSignatures3.js b/tests/baselines/reference/subtypingWithCallSignatures3.js index 9dd2cb7a87..fb7b0fef55 100644 --- a/tests/baselines/reference/subtypingWithCallSignatures3.js +++ b/tests/baselines/reference/subtypingWithCallSignatures3.js @@ -155,67 +155,19 @@ var Errors; } return OtherDerived; })(Base); - var r1 = foo2(function (x) { - return null; - }); // any - var r1a = [ - function (x) { - return [ - '' - ]; - }, - function (x) { - return null; - } - ]; - var r1b = [ - function (x) { - return null; - }, - function (x) { - return [ - '' - ]; - } - ]; - var r2arg = function (x) { - return function (r) { - return null; - }; - }; - var r2arg2 = function (x) { - return function (r) { - return null; - }; - }; + var r1 = foo2(function (x) { return null; }); // any + var r1a = [function (x) { return ['']; }, function (x) { return null; }]; + var r1b = [function (x) { return null; }, function (x) { return ['']; }]; + var r2arg = function (x) { return function (r) { return null; }; }; + var r2arg2 = function (x) { return function (r) { return null; }; }; var r2 = foo7(r2arg); // any - var r2a = [ - r2arg2, - r2arg - ]; - var r2b = [ - r2arg, - r2arg2 - ]; - var r3arg = function (x, y) { - return function (r) { - return null; - }; - }; - var r3arg2 = function (x, y) { - return function (r) { - return null; - }; - }; + var r2a = [r2arg2, r2arg]; + var r2b = [r2arg, r2arg2]; + var r3arg = function (x, y) { return function (r) { return null; }; }; + var r3arg2 = function (x, y) { return function (r) { return null; }; }; var r3 = foo8(r3arg); // any - var r3a = [ - r3arg2, - r3arg - ]; - var r3b = [ - r3arg, - r3arg2 - ]; + var r3a = [r3arg2, r3arg]; + var r3b = [r3arg, r3arg2]; var r4arg = function () { var x = []; for (var _i = 0; _i < arguments.length; _i++) { @@ -231,90 +183,36 @@ var Errors; return null; }; var r4 = foo10(r4arg); // any - var r4a = [ - r4arg2, - r4arg - ]; - var r4b = [ - r4arg, - r4arg2 - ]; - var r5arg = function (x, y) { - return null; - }; - var r5arg2 = function (x, y) { - return null; - }; + var r4a = [r4arg2, r4arg]; + var r4b = [r4arg, r4arg2]; + var r5arg = function (x, y) { return null; }; + var r5arg2 = function (x, y) { return null; }; var r5 = foo11(r5arg); // any - var r5a = [ - r5arg2, - r5arg - ]; - var r5b = [ - r5arg, - r5arg2 - ]; - var r6arg = function (x, y) { - return null; - }; - var r6arg2 = function (x, y) { - return null; - }; + var r5a = [r5arg2, r5arg]; + var r5b = [r5arg, r5arg2]; + var r6arg = function (x, y) { return null; }; + var r6arg2 = function (x, y) { return null; }; var r6 = foo12(r6arg); // (x: Array, y: Array) => Array - var r6a = [ - r6arg2, - r6arg - ]; - var r6b = [ - r6arg, - r6arg2 - ]; - var r7arg = function (x) { - return null; - }; - var r7arg2 = function (x) { - return 1; - }; + var r6a = [r6arg2, r6arg]; + var r6b = [r6arg, r6arg2]; + var r7arg = function (x) { return null; }; + var r7arg2 = function (x) { return 1; }; var r7 = foo15(r7arg); // any - var r7a = [ - r7arg2, - r7arg - ]; - var r7b = [ - r7arg, - r7arg2 - ]; - var r7arg3 = function (x) { - return 1; - }; + var r7a = [r7arg2, r7arg]; + var r7b = [r7arg, r7arg2]; + var r7arg3 = function (x) { return 1; }; var r7c = foo15(r7arg3); // (x: { a: string; b: number }) => number): number; - var r7d = [ - r7arg2, - r7arg3 - ]; - var r7e = [ - r7arg3, - r7arg2 - ]; - var r8arg = function (x) { - return null; - }; + var r7d = [r7arg2, r7arg3]; + var r7e = [r7arg3, r7arg2]; + var r8arg = function (x) { return null; }; var r8 = foo16(r8arg); // any - var r9arg = function (x) { - return null; - }; + var r9arg = function (x) { return null; }; var r9 = foo17(r9arg); // (x: { (a: T): T; (a: T): T; }): any[]; (x: { (a: T): T; (a: T): T; }): any[]; })(Errors || (Errors = {})); var WithGenericSignaturesInBaseType; (function (WithGenericSignaturesInBaseType) { - var r2arg2 = function (x) { - return [ - '' - ]; - }; + var r2arg2 = function (x) { return ['']; }; var r2 = foo2(r2arg2); // (x:T) => T[] since we can infer from generic signatures now - var r3arg2 = function (x) { - return null; - }; + var r3arg2 = function (x) { return null; }; var r3 = foo3(r3arg2); // any })(WithGenericSignaturesInBaseType || (WithGenericSignaturesInBaseType = {})); diff --git a/tests/baselines/reference/subtypingWithCallSignatures4.js b/tests/baselines/reference/subtypingWithCallSignatures4.js index abdef75ef9..cbdf92e2e6 100644 --- a/tests/baselines/reference/subtypingWithCallSignatures4.js +++ b/tests/baselines/reference/subtypingWithCallSignatures4.js @@ -145,149 +145,52 @@ var OtherDerived = (function (_super) { } return OtherDerived; })(Base); -var r1arg = function (x) { - return null; -}; -var r1arg2 = function (x) { - return null; -}; +var r1arg = function (x) { return null; }; +var r1arg2 = function (x) { return null; }; var r1 = foo1(r1arg); -var r1a = [ - r1arg, - r1arg2 -]; -var r1b = [ - r1arg2, - r1arg -]; -var r2arg = function (x) { - return [ - '' - ]; -}; -var r2arg2 = function (x) { - return [ - '' - ]; -}; +var r1a = [r1arg, r1arg2]; +var r1b = [r1arg2, r1arg]; +var r2arg = function (x) { return ['']; }; +var r2arg2 = function (x) { return ['']; }; var r2 = foo2(r2arg); -var r2a = [ - r2arg, - r2arg2 -]; -var r2b = [ - r2arg2, - r2arg -]; -var r3arg = function (x) { - return null; -}; -var r3arg2 = function (x) { -}; +var r2a = [r2arg, r2arg2]; +var r2b = [r2arg2, r2arg]; +var r3arg = function (x) { return null; }; +var r3arg2 = function (x) { }; var r3 = foo3(r3arg); -var r3a = [ - r3arg, - r3arg2 -]; -var r3b = [ - r3arg2, - r3arg -]; -var r4arg = function (x, y) { - return ''; -}; -var r4arg2 = function (x, y) { - return ''; -}; +var r3a = [r3arg, r3arg2]; +var r3b = [r3arg2, r3arg]; +var r4arg = function (x, y) { return ''; }; +var r4arg2 = function (x, y) { return ''; }; var r4 = foo4(r4arg); -var r4a = [ - r4arg, - r4arg2 -]; -var r4b = [ - r4arg2, - r4arg -]; -var r5arg = function (x) { - return null; -}; -var r5arg2 = function (x) { - return null; -}; +var r4a = [r4arg, r4arg2]; +var r4b = [r4arg2, r4arg]; +var r5arg = function (x) { return null; }; +var r5arg2 = function (x) { return null; }; var r5 = foo5(r5arg); -var r5a = [ - r5arg, - r5arg2 -]; -var r5b = [ - r5arg2, - r5arg -]; -var r6arg = function (x) { - return null; -}; -var r6arg2 = function (x) { - return null; -}; +var r5a = [r5arg, r5arg2]; +var r5b = [r5arg2, r5arg]; +var r6arg = function (x) { return null; }; +var r6arg2 = function (x) { return null; }; var r6 = foo6(r6arg); -var r6a = [ - r6arg, - r6arg2 -]; -var r6b = [ - r6arg2, - r6arg -]; -var r11arg = function (x, y) { - return null; -}; -var r11arg2 = function (x, y) { - return null; -}; +var r6a = [r6arg, r6arg2]; +var r6b = [r6arg2, r6arg]; +var r11arg = function (x, y) { return null; }; +var r11arg2 = function (x, y) { return null; }; var r11 = foo11(r11arg); -var r11a = [ - r11arg, - r11arg2 -]; -var r11b = [ - r11arg2, - r11arg -]; -var r15arg = function (x) { - return null; -}; -var r15arg2 = function (x) { - return null; -}; +var r11a = [r11arg, r11arg2]; +var r11b = [r11arg2, r11arg]; +var r15arg = function (x) { return null; }; +var r15arg2 = function (x) { return null; }; var r15 = foo15(r15arg); -var r15a = [ - r15arg, - r15arg2 -]; -var r15b = [ - r15arg2, - r15arg -]; -var r16arg = function (x) { - return null; -}; -var r16arg2 = function (x) { - return null; -}; +var r15a = [r15arg, r15arg2]; +var r15b = [r15arg2, r15arg]; +var r16arg = function (x) { return null; }; +var r16arg2 = function (x) { return null; }; var r16 = foo16(r16arg); -var r16a = [ - r16arg, - r16arg2 -]; -var r16b = [ - r16arg2, - r16arg -]; -var r17arg = function (x) { - return null; -}; +var r16a = [r16arg, r16arg2]; +var r16b = [r16arg2, r16arg]; +var r17arg = function (x) { return null; }; var r17 = foo17(r17arg); -var r18arg = function (x) { - return null; -}; +var r18arg = function (x) { return null; }; var r18 = foo18(r18arg); diff --git a/tests/baselines/reference/subtypingWithCallSignaturesA.js b/tests/baselines/reference/subtypingWithCallSignaturesA.js index 5a67984457..a6c8da99b8 100644 --- a/tests/baselines/reference/subtypingWithCallSignaturesA.js +++ b/tests/baselines/reference/subtypingWithCallSignaturesA.js @@ -3,6 +3,4 @@ declare function foo3(cb: (x: number) => number): typeof cb; var r5 = foo3((x: number) => ''); // error //// [subtypingWithCallSignaturesA.js] -var r5 = foo3(function (x) { - return ''; -}); // error +var r5 = foo3(function (x) { return ''; }); // error diff --git a/tests/baselines/reference/subtypingWithConstructSignatures2.js b/tests/baselines/reference/subtypingWithConstructSignatures2.js index ebedd89849..9a7ecd791c 100644 --- a/tests/baselines/reference/subtypingWithConstructSignatures2.js +++ b/tests/baselines/reference/subtypingWithConstructSignatures2.js @@ -209,157 +209,73 @@ var OtherDerived = (function (_super) { var r1arg1; var r1arg2; var r1 = foo1(r1arg1); // any, return types are not subtype of first overload -var r1a = [ - r1arg2, - r1arg1 -]; // generic signature, subtype in both directions -var r1b = [ - r1arg1, - r1arg2 -]; // generic signature, subtype in both directions +var r1a = [r1arg2, r1arg1]; // generic signature, subtype in both directions +var r1b = [r1arg1, r1arg2]; // generic signature, subtype in both directions var r2arg1; var r2arg2; var r2 = foo2(r2arg1); -var r2a = [ - r2arg1, - r2arg2 -]; -var r2b = [ - r2arg2, - r2arg1 -]; +var r2a = [r2arg1, r2arg2]; +var r2b = [r2arg2, r2arg1]; var r3arg1; var r3arg2; var r3 = foo3(r3arg1); -var r3a = [ - r3arg1, - r3arg2 -]; -var r3b = [ - r3arg2, - r3arg1 -]; +var r3a = [r3arg1, r3arg2]; +var r3b = [r3arg2, r3arg1]; var r4arg1; var r4arg2; var r4 = foo4(r4arg1); // any -var r4a = [ - r4arg1, - r4arg2 -]; -var r4b = [ - r4arg2, - r4arg1 -]; +var r4a = [r4arg1, r4arg2]; +var r4b = [r4arg2, r4arg1]; var r5arg1; var r5arg2; var r5 = foo5(r5arg1); // any -var r5a = [ - r5arg1, - r5arg2 -]; -var r5b = [ - r5arg2, - r5arg1 -]; +var r5a = [r5arg1, r5arg2]; +var r5b = [r5arg2, r5arg1]; var r6arg1; var r6arg2; var r6 = foo6(r6arg1); // any -var r6a = [ - r6arg1, - r6arg2 -]; -var r6b = [ - r6arg2, - r6arg1 -]; +var r6a = [r6arg1, r6arg2]; +var r6b = [r6arg2, r6arg1]; var r7arg1; var r7arg2; var r7 = foo7(r7arg1); // any -var r7a = [ - r7arg1, - r7arg2 -]; -var r7b = [ - r7arg2, - r7arg1 -]; +var r7a = [r7arg1, r7arg2]; +var r7b = [r7arg2, r7arg1]; var r8arg1; var r8arg2; var r8 = foo8(r8arg1); // any -var r8a = [ - r8arg1, - r8arg2 -]; -var r8b = [ - r8arg2, - r8arg1 -]; +var r8a = [r8arg1, r8arg2]; +var r8b = [r8arg2, r8arg1]; var r9arg1; var r9arg2; var r9 = foo9(r9arg1); // any -var r9a = [ - r9arg1, - r9arg2 -]; -var r9b = [ - r9arg2, - r9arg1 -]; +var r9a = [r9arg1, r9arg2]; +var r9b = [r9arg2, r9arg1]; var r10arg1; var r10arg2; var r10 = foo10(r10arg1); // any -var r10a = [ - r10arg1, - r10arg2 -]; -var r10b = [ - r10arg2, - r10arg1 -]; +var r10a = [r10arg1, r10arg2]; +var r10b = [r10arg2, r10arg1]; var r11arg1; var r11arg2; var r11 = foo11(r11arg1); // any -var r11a = [ - r11arg1, - r11arg2 -]; -var r11b = [ - r11arg2, - r11arg1 -]; +var r11a = [r11arg1, r11arg2]; +var r11b = [r11arg2, r11arg1]; var r12arg1; var r12arg2; var r12 = foo12(r12arg1); // any -var r12a = [ - r12arg1, - r12arg2 -]; -var r12b = [ - r12arg2, - r12arg1 -]; +var r12a = [r12arg1, r12arg2]; +var r12b = [r12arg2, r12arg1]; var r13arg1; var r13arg2; var r13 = foo13(r13arg1); // any -var r13a = [ - r13arg1, - r13arg2 -]; -var r13b = [ - r13arg2, - r13arg1 -]; +var r13a = [r13arg1, r13arg2]; +var r13b = [r13arg2, r13arg1]; var r14arg1; var r14arg2; var r14 = foo14(r14arg1); // any -var r14a = [ - r14arg1, - r14arg2 -]; -var r14b = [ - r14arg2, - r14arg1 -]; +var r14a = [r14arg1, r14arg2]; +var r14b = [r14arg2, r14arg1]; var r15arg1; var r15 = foo15(r15arg1); // any var r16arg1; diff --git a/tests/baselines/reference/subtypingWithConstructSignatures3.js b/tests/baselines/reference/subtypingWithConstructSignatures3.js index f32f26fc69..a74c14e8d4 100644 --- a/tests/baselines/reference/subtypingWithConstructSignatures3.js +++ b/tests/baselines/reference/subtypingWithConstructSignatures3.js @@ -160,90 +160,42 @@ var Errors; var r1arg1; var r1arg2; var r1 = foo2(r1arg1); // any - var r1a = [ - r1arg2, - r1arg1 - ]; - var r1b = [ - r1arg1, - r1arg2 - ]; + var r1a = [r1arg2, r1arg1]; + var r1b = [r1arg1, r1arg2]; var r2arg1; var r2arg2; var r2 = foo7(r2arg1); // any - var r2a = [ - r2arg2, - r2arg1 - ]; - var r2b = [ - r2arg1, - r2arg2 - ]; + var r2a = [r2arg2, r2arg1]; + var r2b = [r2arg1, r2arg2]; var r3arg1; var r3arg2; var r3 = foo8(r3arg1); // any - var r3a = [ - r3arg2, - r3arg1 - ]; - var r3b = [ - r3arg1, - r3arg2 - ]; + var r3a = [r3arg2, r3arg1]; + var r3b = [r3arg1, r3arg2]; var r4arg1; var r4arg2; var r4 = foo10(r4arg1); // any - var r4a = [ - r4arg2, - r4arg1 - ]; - var r4b = [ - r4arg1, - r4arg2 - ]; + var r4a = [r4arg2, r4arg1]; + var r4b = [r4arg1, r4arg2]; var r5arg1; var r5arg2; var r5 = foo11(r5arg1); // any - var r5a = [ - r5arg2, - r5arg1 - ]; - var r5b = [ - r5arg1, - r5arg2 - ]; + var r5a = [r5arg2, r5arg1]; + var r5b = [r5arg1, r5arg2]; var r6arg1; var r6arg2; var r6 = foo12(r6arg1); // new (x: Array, y: Array) => Array - var r6a = [ - r6arg2, - r6arg1 - ]; - var r6b = [ - r6arg1, - r6arg2 - ]; + var r6a = [r6arg2, r6arg1]; + var r6b = [r6arg1, r6arg2]; var r7arg1; var r7arg2; var r7 = foo15(r7arg1); // (x: { a: string; b: number }) => number): number; - var r7a = [ - r7arg2, - r7arg1 - ]; - var r7b = [ - r7arg1, - r7arg2 - ]; + var r7a = [r7arg2, r7arg1]; + var r7b = [r7arg1, r7arg2]; var r7arg3; var r7c = foo15(r7arg3); // any - var r7d = [ - r7arg2, - r7arg3 - ]; - var r7e = [ - r7arg3, - r7arg2 - ]; + var r7d = [r7arg2, r7arg3]; + var r7e = [r7arg3, r7arg2]; var r8arg; var r8 = foo16(r8arg); // any var r9arg; diff --git a/tests/baselines/reference/subtypingWithConstructSignatures4.js b/tests/baselines/reference/subtypingWithConstructSignatures4.js index 4e0783afa4..b3d43b0308 100644 --- a/tests/baselines/reference/subtypingWithConstructSignatures4.js +++ b/tests/baselines/reference/subtypingWithConstructSignatures4.js @@ -148,102 +148,48 @@ var OtherDerived = (function (_super) { var r1arg; var r1arg2; var r1 = foo1(r1arg); -var r1a = [ - r1arg, - r1arg2 -]; -var r1b = [ - r1arg2, - r1arg -]; +var r1a = [r1arg, r1arg2]; +var r1b = [r1arg2, r1arg]; var r2arg; var r2arg2; var r2 = foo2(r2arg); -var r2a = [ - r2arg, - r2arg2 -]; -var r2b = [ - r2arg2, - r2arg -]; +var r2a = [r2arg, r2arg2]; +var r2b = [r2arg2, r2arg]; var r3arg; var r3arg2; var r3 = foo3(r3arg); -var r3a = [ - r3arg, - r3arg2 -]; -var r3b = [ - r3arg2, - r3arg -]; +var r3a = [r3arg, r3arg2]; +var r3b = [r3arg2, r3arg]; var r4arg; var r4arg2; var r4 = foo4(r4arg); -var r4a = [ - r4arg, - r4arg2 -]; -var r4b = [ - r4arg2, - r4arg -]; +var r4a = [r4arg, r4arg2]; +var r4b = [r4arg2, r4arg]; var r5arg; var r5arg2; var r5 = foo5(r5arg); -var r5a = [ - r5arg, - r5arg2 -]; -var r5b = [ - r5arg2, - r5arg -]; +var r5a = [r5arg, r5arg2]; +var r5b = [r5arg2, r5arg]; var r6arg; var r6arg2; var r6 = foo6(r6arg); -var r6a = [ - r6arg, - r6arg2 -]; -var r6b = [ - r6arg2, - r6arg -]; +var r6a = [r6arg, r6arg2]; +var r6b = [r6arg2, r6arg]; var r11arg; var r11arg2; var r11 = foo11(r11arg); -var r11a = [ - r11arg, - r11arg2 -]; -var r11b = [ - r11arg2, - r11arg -]; +var r11a = [r11arg, r11arg2]; +var r11b = [r11arg2, r11arg]; var r15arg; var r15arg2; var r15 = foo15(r15arg); -var r15a = [ - r15arg, - r15arg2 -]; -var r15b = [ - r15arg2, - r15arg -]; +var r15a = [r15arg, r15arg2]; +var r15b = [r15arg2, r15arg]; var r16arg; var r16arg2; var r16 = foo16(r16arg); -var r16a = [ - r16arg, - r16arg2 -]; -var r16b = [ - r16arg2, - r16arg -]; +var r16a = [r16arg, r16arg2]; +var r16b = [r16arg2, r16arg]; var r17arg; var r17 = foo17(r17arg); var r18arg; diff --git a/tests/baselines/reference/subtypingWithObjectMembersOptionality.js b/tests/baselines/reference/subtypingWithObjectMembersOptionality.js index f0005c9fe1..87a7012e91 100644 --- a/tests/baselines/reference/subtypingWithObjectMembersOptionality.js +++ b/tests/baselines/reference/subtypingWithObjectMembersOptionality.js @@ -77,16 +77,12 @@ module TwoLevels { // Derived member is not optional but base member is, should be ok // object literal case var a; -var b = { - Foo: null -}; +var b = { Foo: null }; var r = true ? a : b; var TwoLevels; (function (TwoLevels) { // object literal case var a; - var b = { - Foo: null - }; + var b = { Foo: null }; var r = true ? a : b; })(TwoLevels || (TwoLevels = {})); diff --git a/tests/baselines/reference/subtypingWithOptionalProperties.js b/tests/baselines/reference/subtypingWithOptionalProperties.js index 48f73e72b0..4908a92f2e 100644 --- a/tests/baselines/reference/subtypingWithOptionalProperties.js +++ b/tests/baselines/reference/subtypingWithOptionalProperties.js @@ -17,7 +17,5 @@ function f(a) { var b = a; return b; } -var r = f({ - s: new Object() -}); // ok +var r = f({ s: new Object() }); // ok r.s && r.s.toFixed(); // would blow up at runtime diff --git a/tests/baselines/reference/superAccess.js b/tests/baselines/reference/superAccess.js index c9ab251443..3d9080b76e 100644 --- a/tests/baselines/reference/superAccess.js +++ b/tests/baselines/reference/superAccess.js @@ -23,9 +23,7 @@ var __extends = this.__extends || function (d, b) { var MyBase = (function () { function MyBase() { this.S2 = "test"; - this.f = function () { - return 5; - }; + this.f = function () { return 5; }; } MyBase.S1 = 5; return MyBase; diff --git a/tests/baselines/reference/superAccess2.js b/tests/baselines/reference/superAccess2.js index 259afb1af0..8672b5b993 100644 --- a/tests/baselines/reference/superAccess2.js +++ b/tests/baselines/reference/superAccess2.js @@ -34,10 +34,8 @@ var __extends = this.__extends || function (d, b) { var P = (function () { function P() { } - P.prototype.x = function () { - }; - P.y = function () { - }; + P.prototype.x = function () { }; + P.y = function () { }; return P; })(); var Q = (function (_super) { @@ -47,9 +45,7 @@ var Q = (function (_super) { var _this = this; if (z === void 0) { z = _super.prototype.; } if (zz === void 0) { zz = _super.prototype.; } - if (zzz === void 0) { zzz = function () { - return _super.prototype.; - }; } + if (zzz === void 0) { zzz = function () { return _super.prototype.; }; } _super.call(this); this.z = z; this.xx = _super.prototype.; diff --git a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithIncorrectNumberOfTypeArguments1.js b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithIncorrectNumberOfTypeArguments1.js index bbfd81879b..92abed0d66 100644 --- a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithIncorrectNumberOfTypeArguments1.js +++ b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithIncorrectNumberOfTypeArguments1.js @@ -26,9 +26,7 @@ var A = (function () { var B = (function (_super) { __extends(B, _super); function B() { - _super.call(this, function (value) { - return String(value); - }); + _super.call(this, function (value) { return String(value); }); } return B; })(A); diff --git a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithNoTypeArguments1.js b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithNoTypeArguments1.js index 11eb82025a..7e3c61e669 100644 --- a/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithNoTypeArguments1.js +++ b/tests/baselines/reference/superCallFromClassThatDerivesFromGenericTypeButWithNoTypeArguments1.js @@ -26,9 +26,7 @@ var A = (function () { var B = (function (_super) { __extends(B, _super); function B() { - _super.call(this, function (value) { - return String(value); - }); + _super.call(this, function (value) { return String(value); }); } return B; })(A); diff --git a/tests/baselines/reference/superCallFromClassThatDerivesNonGenericTypeButWithTypeArguments1.js b/tests/baselines/reference/superCallFromClassThatDerivesNonGenericTypeButWithTypeArguments1.js index b6caa0880c..b48d5bb7f5 100644 --- a/tests/baselines/reference/superCallFromClassThatDerivesNonGenericTypeButWithTypeArguments1.js +++ b/tests/baselines/reference/superCallFromClassThatDerivesNonGenericTypeButWithTypeArguments1.js @@ -26,9 +26,7 @@ var A = (function () { var B = (function (_super) { __extends(B, _super); function B() { - _super.call(this, function (value) { - return String(value); - }); + _super.call(this, function (value) { return String(value); }); } return B; })(A); diff --git a/tests/baselines/reference/superCallFromClassThatHasNoBaseType1.js b/tests/baselines/reference/superCallFromClassThatHasNoBaseType1.js index 3f4c24297e..7818aed7ff 100644 --- a/tests/baselines/reference/superCallFromClassThatHasNoBaseType1.js +++ b/tests/baselines/reference/superCallFromClassThatHasNoBaseType1.js @@ -19,9 +19,7 @@ var A = (function () { })(); var B = (function () { function B() { - _super.call(this, function (value) { - return String(value); - }); + _super.call(this, function (value) { return String(value); }); } return B; })(); diff --git a/tests/baselines/reference/superCallFromFunction1.js b/tests/baselines/reference/superCallFromFunction1.js index ecc78aa539..a7fcbaaeff 100644 --- a/tests/baselines/reference/superCallFromFunction1.js +++ b/tests/baselines/reference/superCallFromFunction1.js @@ -6,7 +6,5 @@ function foo() { //// [superCallFromFunction1.js] function foo() { - _super.call(this, function (value) { - return String(value); - }); + _super.call(this, function (value) { return String(value); }); } diff --git a/tests/baselines/reference/superCallInNonStaticMethod.js b/tests/baselines/reference/superCallInNonStaticMethod.js index cf29ac3b1a..7ef1ce1c62 100644 --- a/tests/baselines/reference/superCallInNonStaticMethod.js +++ b/tests/baselines/reference/superCallInNonStaticMethod.js @@ -70,9 +70,7 @@ var Other = (function (_super) { var _this = this; _super.call(this); this.propertyInitializer = _super.prototype.instanceMethod.call(this); - this.functionProperty = function () { - _super.prototype.instanceMethod.call(_this); - }; + this.functionProperty = function () { _super.prototype.instanceMethod.call(_this); }; _super.prototype.instanceMethod.call(this); } // in instance method diff --git a/tests/baselines/reference/superCallOutsideConstructor.js b/tests/baselines/reference/superCallOutsideConstructor.js index 32d45b044f..94f41cccb5 100644 --- a/tests/baselines/reference/superCallOutsideConstructor.js +++ b/tests/baselines/reference/superCallOutsideConstructor.js @@ -32,8 +32,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; return C; })(); var D = (function (_super) { diff --git a/tests/baselines/reference/superCallParameterContextualTyping1.js b/tests/baselines/reference/superCallParameterContextualTyping1.js index 0df2159c40..b11d62d62c 100644 --- a/tests/baselines/reference/superCallParameterContextualTyping1.js +++ b/tests/baselines/reference/superCallParameterContextualTyping1.js @@ -29,9 +29,7 @@ var B = (function (_super) { __extends(B, _super); // Ensure 'value' is of type 'number (and not '{}') by using its 'toExponential()' method. function B() { - _super.call(this, function (value) { - return String(value.toExponential()); - }); + _super.call(this, function (value) { return String(value.toExponential()); }); } return B; })(A); diff --git a/tests/baselines/reference/superCallParameterContextualTyping2.js b/tests/baselines/reference/superCallParameterContextualTyping2.js index cfd2c452ad..61e8b94f00 100644 --- a/tests/baselines/reference/superCallParameterContextualTyping2.js +++ b/tests/baselines/reference/superCallParameterContextualTyping2.js @@ -28,9 +28,7 @@ var C = (function (_super) { __extends(C, _super); // Ensure 'value' is not of type 'any' by invoking it with type arguments. function C() { - _super.call(this, function (value) { - return String(value()); - }); + _super.call(this, function (value) { return String(value()); }); } return C; })(A); diff --git a/tests/baselines/reference/superCalls.js b/tests/baselines/reference/superCalls.js index e714a4db19..2928793feb 100644 --- a/tests/baselines/reference/superCalls.js +++ b/tests/baselines/reference/superCalls.js @@ -43,8 +43,7 @@ var Base = (function () { } return Base; })(); -function v() { -} +function v() { } var Derived = (function (_super) { __extends(Derived, _super); //super call in class constructor of derived type diff --git a/tests/baselines/reference/superCallsInConstructor.js b/tests/baselines/reference/superCallsInConstructor.js index 912bfab349..0c19e365d9 100644 --- a/tests/baselines/reference/superCallsInConstructor.js +++ b/tests/baselines/reference/superCallsInConstructor.js @@ -30,10 +30,8 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.foo = function () { - }; - C.prototype.bar = function () { - }; + C.prototype.foo = function () { }; + C.prototype.bar = function () { }; return C; })(); var Base = (function () { @@ -49,8 +47,7 @@ var Derived = (function (_super) { _super.call(this); bar(); } - try { - } + try { } catch (e) { _super.call(this); } diff --git a/tests/baselines/reference/superErrors.js b/tests/baselines/reference/superErrors.js index 2b1a508261..bb17019aa4 100644 --- a/tests/baselines/reference/superErrors.js +++ b/tests/baselines/reference/superErrors.js @@ -61,16 +61,8 @@ var __extends = this.__extends || function (d, b) { function foo() { // super in a non class context var x = _super.; - var y = function () { - return _super.; - }; - var z = function () { - return function () { - return function () { - return _super.; - }; - }; - }; + var y = function () { return _super.; }; + var z = function () { return function () { return function () { return _super.; }; }; }; } var User = (function () { function User() { @@ -92,47 +84,27 @@ var RegisteredUser = (function (_super) { } // super call in a lambda in an inner function in a constructor function inner2() { - var x = function () { - return _super.sayHello.call(this); - }; + var x = function () { return _super.sayHello.call(this); }; } // super call in a lambda in a function expression in a constructor - (function () { - return function () { - return _super.; - }; - })(); + (function () { return function () { return _super.; }; })(); } RegisteredUser.prototype.sayHello = function () { // super call in a method _super.prototype.sayHello.call(this); // super call in a lambda in an inner function in a method function inner() { - var x = function () { - return _super.sayHello.call(this); - }; + var x = function () { return _super.sayHello.call(this); }; } // super call in a lambda in a function expression in a constructor - (function () { - return function () { - return _super.; - }; - })(); + (function () { return function () { return _super.; }; })(); }; RegisteredUser.staticFunction = function () { var _this = this; // super in static functions var s = _super.; - var x = function () { - return _super.; - }; - var y = function () { - return function () { - return function () { - return _super.; - }; - }; - }; + var x = function () { return _super.; }; + var y = function () { return function () { return function () { return _super.; }; }; }; }; return RegisteredUser; })(User); diff --git a/tests/baselines/reference/superInCatchBlock1.js b/tests/baselines/reference/superInCatchBlock1.js index f94c051127..1b9085ec26 100644 --- a/tests/baselines/reference/superInCatchBlock1.js +++ b/tests/baselines/reference/superInCatchBlock1.js @@ -23,8 +23,7 @@ var __extends = this.__extends || function (d, b) { var A = (function () { function A() { } - A.prototype.m = function () { - }; + A.prototype.m = function () { }; return A; })(); var B = (function (_super) { diff --git a/tests/baselines/reference/superInLambdas.js b/tests/baselines/reference/superInLambdas.js index f7e3c4706c..10c489f1b4 100644 --- a/tests/baselines/reference/superInLambdas.js +++ b/tests/baselines/reference/superInLambdas.js @@ -92,18 +92,14 @@ var RegisteredUser = (function (_super) { // super call in a constructor _super.prototype.sayHello.call(this); // super call in a lambda in a constructor - var x = function () { - return _super.prototype.sayHello.call(_this); - }; + var x = function () { return _super.prototype.sayHello.call(_this); }; } RegisteredUser.prototype.sayHello = function () { var _this = this; // super call in a method _super.prototype.sayHello.call(this); // super call in a lambda in a method - var x = function () { - return _super.prototype.sayHello.call(_this); - }; + var x = function () { return _super.prototype.sayHello.call(_this); }; }; return RegisteredUser; })(User); @@ -114,24 +110,12 @@ var RegisteredUser2 = (function (_super) { _super.call(this); this.name = "Joe"; // super call in a nested lambda in a constructor - var x = function () { - return function () { - return function () { - return _super.prototype.sayHello.call(_this); - }; - }; - }; + var x = function () { return function () { return function () { return _super.prototype.sayHello.call(_this); }; }; }; } RegisteredUser2.prototype.sayHello = function () { var _this = this; // super call in a nested lambda in a method - var x = function () { - return function () { - return function () { - return _super.prototype.sayHello.call(_this); - }; - }; - }; + var x = function () { return function () { return function () { return _super.prototype.sayHello.call(_this); }; }; }; }; return RegisteredUser2; })(User); @@ -142,24 +126,12 @@ var RegisteredUser3 = (function (_super) { _super.call(this); this.name = "Sam"; // super property in a nested lambda in a constructor - var superName = function () { - return function () { - return function () { - return _super.prototype.name; - }; - }; - }; + var superName = function () { return function () { return function () { return _super.prototype.name; }; }; }; } RegisteredUser3.prototype.sayHello = function () { var _this = this; // super property in a nested lambda in a method - var superName = function () { - return function () { - return function () { - return _super.prototype.name; - }; - }; - }; + var superName = function () { return function () { return function () { return _super.prototype.name; }; }; }; }; return RegisteredUser3; })(User); @@ -170,20 +142,12 @@ var RegisteredUser4 = (function (_super) { _super.call(this); this.name = "Mark"; // super in a nested lambda in a constructor - var x = function () { - return function () { - return _super.prototype.; - }; - }; + var x = function () { return function () { return _super.prototype.; }; }; } RegisteredUser4.prototype.sayHello = function () { var _this = this; // super in a nested lambda in a method - var x = function () { - return function () { - return _super.prototype.; - }; - }; + var x = function () { return function () { return _super.prototype.; }; }; }; return RegisteredUser4; })(User); diff --git a/tests/baselines/reference/superNewCall1.js b/tests/baselines/reference/superNewCall1.js index b0ec9899a5..d9b74ac508 100644 --- a/tests/baselines/reference/superNewCall1.js +++ b/tests/baselines/reference/superNewCall1.js @@ -28,9 +28,7 @@ var A = (function () { var B = (function (_super) { __extends(B, _super); function B() { - new _super.prototype(function (value) { - return String(value); - }); + new _super.prototype(function (value) { return String(value); }); } return B; })(A); diff --git a/tests/baselines/reference/superPropertyAccess.js b/tests/baselines/reference/superPropertyAccess.js index a9ee2352c7..a5419aaf36 100644 --- a/tests/baselines/reference/superPropertyAccess.js +++ b/tests/baselines/reference/superPropertyAccess.js @@ -45,22 +45,15 @@ var __extends = this.__extends || function (d, b) { }; var MyBase = (function () { function MyBase() { - this.m2 = function () { - }; + this.m2 = function () { }; this.d1 = 42; this.d2 = 42; } - MyBase.prototype.m1 = function (a) { - return a; - }; - MyBase.prototype.p1 = function () { - }; + MyBase.prototype.m1 = function (a) { return a; }; + MyBase.prototype.p1 = function () { }; Object.defineProperty(MyBase.prototype, "value", { - get: function () { - return 0; - }, - set: function (v) { - }, + get: function () { return 0; }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -79,9 +72,7 @@ var MyDerived = (function (_super) { _super.prototype.p1.call(this); // Should error, private not public instance member function var l1 = _super.prototype.d1; // Should error, instance data property not a public instance member function var l1 = _super.prototype.d2; // Should error, instance data property not a public instance member function - _super.prototype.m1 = function (a) { - return ""; - }; // Should be allowed, we will not restrict assignment + _super.prototype.m1 = function (a) { return ""; }; // Should be allowed, we will not restrict assignment _super.prototype.value = 0; // Should error, instance data property not a public instance member function var z = _super.prototype.value; // Should error, instance data property not a public instance member function }; diff --git a/tests/baselines/reference/superPropertyAccess1.js b/tests/baselines/reference/superPropertyAccess1.js index 8b1e855e0a..a0a52526f9 100644 --- a/tests/baselines/reference/superPropertyAccess1.js +++ b/tests/baselines/reference/superPropertyAccess1.js @@ -37,8 +37,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.foo = function () { - }; + C.prototype.foo = function () { }; Object.defineProperty(C.prototype, "x", { get: function () { return 1; @@ -46,8 +45,7 @@ var C = (function () { enumerable: true, configurable: true }); - C.prototype.bar = function () { - }; + C.prototype.bar = function () { }; return C; })(); var D = (function (_super) { diff --git a/tests/baselines/reference/superPropertyAccess2.js b/tests/baselines/reference/superPropertyAccess2.js index 98beb078e2..b906f1b0a8 100644 --- a/tests/baselines/reference/superPropertyAccess2.js +++ b/tests/baselines/reference/superPropertyAccess2.js @@ -37,8 +37,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.foo = function () { - }; + C.foo = function () { }; Object.defineProperty(C.prototype, "x", { get: function () { return 1; @@ -46,8 +45,7 @@ var C = (function () { enumerable: true, configurable: true }); - C.bar = function () { - }; + C.bar = function () { }; return C; })(); var D = (function (_super) { diff --git a/tests/baselines/reference/superPropertyAccessNoError.js b/tests/baselines/reference/superPropertyAccessNoError.js index 086ead2e16..e49a2c6b71 100644 --- a/tests/baselines/reference/superPropertyAccessNoError.js +++ b/tests/baselines/reference/superPropertyAccessNoError.js @@ -95,9 +95,7 @@ var SomeDerivedClass = (function (_super) { var _this = this; var x = _super.prototype.func.call(this); var x; - var y = function () { - return _super.prototype.func.call(_this); - }; + var y = function () { return _super.prototype.func.call(_this); }; }; Object.defineProperty(SomeDerivedClass.prototype, "a", { get: function () { diff --git a/tests/baselines/reference/superWithTypeArgument3.js b/tests/baselines/reference/superWithTypeArgument3.js index 8277fe0506..ef228a3ba2 100644 --- a/tests/baselines/reference/superWithTypeArgument3.js +++ b/tests/baselines/reference/superWithTypeArgument3.js @@ -23,8 +23,7 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C() { } - C.prototype.bar = function (x) { - }; + C.prototype.bar = function (x) { }; return C; })(); var D = (function (_super) { diff --git a/tests/baselines/reference/super_inside-object-literal-getters-and-setters.js b/tests/baselines/reference/super_inside-object-literal-getters-and-setters.js index c4ced2a9dc..2a97b6d04d 100644 --- a/tests/baselines/reference/super_inside-object-literal-getters-and-setters.js +++ b/tests/baselines/reference/super_inside-object-literal-getters-and-setters.js @@ -52,9 +52,7 @@ var ObjectLiteral; var F = (function () { function F() { } - F.prototype.test = function () { - return ""; - }; + F.prototype.test = function () { return ""; }; return F; })(); var SuperObjectTest = (function (_super) { diff --git a/tests/baselines/reference/switchAssignmentCompat.js b/tests/baselines/reference/switchAssignmentCompat.js index 4743e5d7eb..1e6792ee37 100644 --- a/tests/baselines/reference/switchAssignmentCompat.js +++ b/tests/baselines/reference/switchAssignmentCompat.js @@ -13,6 +13,5 @@ var Foo = (function () { return Foo; })(); switch (0) { - case Foo: - break; // Error expected + case Foo: break; // Error expected } diff --git a/tests/baselines/reference/switchBreakStatements.js b/tests/baselines/reference/switchBreakStatements.js index 810c990923..534f025e2f 100644 --- a/tests/baselines/reference/switchBreakStatements.js +++ b/tests/baselines/reference/switchBreakStatements.js @@ -91,8 +91,7 @@ SEVEN: switch ('') { break SEVEN; EIGHT: switch ('') { case 'a': - var fn = function () { - }; + var fn = function () { }; break EIGHT; } } diff --git a/tests/baselines/reference/switchCasesExpressionTypeMismatch.js b/tests/baselines/reference/switchCasesExpressionTypeMismatch.js index 546d03dec9..ca354779be 100644 --- a/tests/baselines/reference/switchCasesExpressionTypeMismatch.js +++ b/tests/baselines/reference/switchCasesExpressionTypeMismatch.js @@ -25,24 +25,16 @@ var Foo = (function () { return Foo; })(); switch (0) { - case Foo: - break; // Error - case "sss": - break; // Error - case 123: - break; // No Error - case true: - break; // Error + case Foo: break; // Error + case "sss": break; // Error + case 123: break; // No Error + case true: break; // Error } var s = 0; // No error for all switch (s) { - case Foo: - break; - case "sss": - break; - case 123: - break; - case true: - break; + case Foo: break; + case "sss": break; + case 123: break; + case true: break; } diff --git a/tests/baselines/reference/switchFallThroughs.js b/tests/baselines/reference/switchFallThroughs.js index b38c6b6f0a..53f221bd46 100644 --- a/tests/baselines/reference/switchFallThroughs.js +++ b/tests/baselines/reference/switchFallThroughs.js @@ -26,10 +26,9 @@ function R1(index) { var a = 'a'; return a; case 3: - case 4: - { - return 'b'; - } + case 4: { + return 'b'; + } case 5: default: return 'c'; diff --git a/tests/baselines/reference/switchStatements.js b/tests/baselines/reference/switchStatements.js index 699871d9dd..6348ca62e7 100644 --- a/tests/baselines/reference/switchStatements.js +++ b/tests/baselines/reference/switchStatements.js @@ -81,21 +81,13 @@ switch (x) { case /[a-z]/: case []: case {}: - case { - id: 12 - }: - case [ - 'a' - ]: + case { id: 12 }: + case ['a']: case typeof x: case typeof M: case M.fn(1): - case function (x) { - return ''; - }: - case (function (x) { - return ''; - })(2): + case function (x) { return ''; }: + case (function (x) { return ''; })(2): default: } // basic assignable check, rest covered in tests for 'assignement compatibility' @@ -113,10 +105,7 @@ var D = (function (_super) { })(C); switch (new C()) { case new D(): - case { - id: 12, - name: '' - }: + case { id: 12, name: '' }: case new C(): } switch ('') { @@ -139,19 +128,11 @@ switch ([]) { } switch ({}) { } -switch ({ - id: 12 -}) { +switch ({ id: 12 }) { } -switch ([ - 'a' -]) { +switch (['a']) { } -switch (function (x) { - return ''; -}) { +switch (function (x) { return ''; }) { } -switch ((function (x) { - return ''; -})(1)) { +switch ((function (x) { return ''; })(1)) { } diff --git a/tests/baselines/reference/switchStatementsWithMultipleDefaults.js b/tests/baselines/reference/switchStatementsWithMultipleDefaults.js index 09a1a70a5d..a17abe5711 100644 --- a/tests/baselines/reference/switchStatementsWithMultipleDefaults.js +++ b/tests/baselines/reference/switchStatementsWithMultipleDefaults.js @@ -56,8 +56,7 @@ switch (x) { default: // Error, third 'default' clause default: // Error, fourth 'default' clause. // Errors on fifth-seventh - default: - return; + default: return; default: default: } diff --git a/tests/baselines/reference/symbolDeclarationEmit10.js b/tests/baselines/reference/symbolDeclarationEmit10.js index 7ace6617db..0c46d8750e 100644 --- a/tests/baselines/reference/symbolDeclarationEmit10.js +++ b/tests/baselines/reference/symbolDeclarationEmit10.js @@ -6,11 +6,8 @@ var obj = { //// [symbolDeclarationEmit10.js] var obj = { - get [Symbol.isConcatSpreadable]() { - return ''; - }, - set [Symbol.isConcatSpreadable](x) { - } + get [Symbol.isConcatSpreadable]() { return ''; }, + set [Symbol.isConcatSpreadable](x) { } }; diff --git a/tests/baselines/reference/symbolDeclarationEmit11.js b/tests/baselines/reference/symbolDeclarationEmit11.js index 599f7393f4..b598317758 100644 --- a/tests/baselines/reference/symbolDeclarationEmit11.js +++ b/tests/baselines/reference/symbolDeclarationEmit11.js @@ -8,13 +8,9 @@ class C { //// [symbolDeclarationEmit11.js] class C { - static [Symbol.toPrimitive]() { - } - static get [Symbol.isRegExp]() { - return ""; - } - static set [Symbol.isRegExp](x) { - } + static [Symbol.toPrimitive]() { } + static get [Symbol.isRegExp]() { return ""; } + static set [Symbol.isRegExp](x) { } } C[Symbol.iterator] = 0; diff --git a/tests/baselines/reference/symbolDeclarationEmit12.js b/tests/baselines/reference/symbolDeclarationEmit12.js index ab930b4158..ce7b3861b0 100644 --- a/tests/baselines/reference/symbolDeclarationEmit12.js +++ b/tests/baselines/reference/symbolDeclarationEmit12.js @@ -16,16 +16,12 @@ module M { var M; (function (M) { class C { - [Symbol.toPrimitive](x) { - } + [Symbol.toPrimitive](x) { } [Symbol.isConcatSpreadable]() { return undefined; } - get [Symbol.isRegExp]() { - return undefined; - } - set [Symbol.isRegExp](x) { - } + get [Symbol.isRegExp]() { return undefined; } + set [Symbol.isRegExp](x) { } } M.C = C; })(M || (M = {})); diff --git a/tests/baselines/reference/symbolDeclarationEmit13.js b/tests/baselines/reference/symbolDeclarationEmit13.js index f48a918a6f..b309cfb2f6 100644 --- a/tests/baselines/reference/symbolDeclarationEmit13.js +++ b/tests/baselines/reference/symbolDeclarationEmit13.js @@ -6,11 +6,8 @@ class C { //// [symbolDeclarationEmit13.js] class C { - get [Symbol.isRegExp]() { - return ""; - } - set [Symbol.toStringTag](x) { - } + get [Symbol.isRegExp]() { return ""; } + set [Symbol.toStringTag](x) { } } diff --git a/tests/baselines/reference/symbolDeclarationEmit14.js b/tests/baselines/reference/symbolDeclarationEmit14.js index 6197ffa2b4..f24ce11ee7 100644 --- a/tests/baselines/reference/symbolDeclarationEmit14.js +++ b/tests/baselines/reference/symbolDeclarationEmit14.js @@ -6,12 +6,8 @@ class C { //// [symbolDeclarationEmit14.js] class C { - get [Symbol.isRegExp]() { - return ""; - } - get [Symbol.toStringTag]() { - return ""; - } + get [Symbol.isRegExp]() { return ""; } + get [Symbol.toStringTag]() { return ""; } } diff --git a/tests/baselines/reference/symbolDeclarationEmit3.js b/tests/baselines/reference/symbolDeclarationEmit3.js index 6f513b053c..8808798201 100644 --- a/tests/baselines/reference/symbolDeclarationEmit3.js +++ b/tests/baselines/reference/symbolDeclarationEmit3.js @@ -7,8 +7,7 @@ class C { //// [symbolDeclarationEmit3.js] class C { - [Symbol.isRegExp](x) { - } + [Symbol.isRegExp](x) { } } diff --git a/tests/baselines/reference/symbolDeclarationEmit4.js b/tests/baselines/reference/symbolDeclarationEmit4.js index 14f50a03ee..67ec3477f7 100644 --- a/tests/baselines/reference/symbolDeclarationEmit4.js +++ b/tests/baselines/reference/symbolDeclarationEmit4.js @@ -6,11 +6,8 @@ class C { //// [symbolDeclarationEmit4.js] class C { - get [Symbol.isRegExp]() { - return ""; - } - set [Symbol.isRegExp](x) { - } + get [Symbol.isRegExp]() { return ""; } + set [Symbol.isRegExp](x) { } } diff --git a/tests/baselines/reference/symbolDeclarationEmit9.js b/tests/baselines/reference/symbolDeclarationEmit9.js index 8cdb717314..d38171767a 100644 --- a/tests/baselines/reference/symbolDeclarationEmit9.js +++ b/tests/baselines/reference/symbolDeclarationEmit9.js @@ -5,8 +5,7 @@ var obj = { //// [symbolDeclarationEmit9.js] var obj = { - [Symbol.isConcatSpreadable]() { - } + [Symbol.isConcatSpreadable]() { } }; diff --git a/tests/baselines/reference/symbolProperty1.js b/tests/baselines/reference/symbolProperty1.js index 1537883f4e..0117dd3b1c 100644 --- a/tests/baselines/reference/symbolProperty1.js +++ b/tests/baselines/reference/symbolProperty1.js @@ -12,8 +12,7 @@ var x = { var s; var x = { [s]: 0, - [s]() { - }, + [s]() { }, get [s]() { return 0; } diff --git a/tests/baselines/reference/symbolProperty18.js b/tests/baselines/reference/symbolProperty18.js index ff69588be3..1d0a57e7b5 100644 --- a/tests/baselines/reference/symbolProperty18.js +++ b/tests/baselines/reference/symbolProperty18.js @@ -12,11 +12,8 @@ i[Symbol.toPrimitive] = false; //// [symbolProperty18.js] var i = { [Symbol.iterator]: 0, - [Symbol.toStringTag]() { - return ""; - }, - set [Symbol.toPrimitive](p) { - } + [Symbol.toStringTag]() { return ""; }, + set [Symbol.toPrimitive](p) { } }; var it = i[Symbol.iterator]; var str = i[Symbol.toStringTag](); diff --git a/tests/baselines/reference/symbolProperty19.js b/tests/baselines/reference/symbolProperty19.js index d4bfd0dc7c..5ec7968218 100644 --- a/tests/baselines/reference/symbolProperty19.js +++ b/tests/baselines/reference/symbolProperty19.js @@ -9,14 +9,8 @@ var str = i[Symbol.toStringTag](); //// [symbolProperty19.js] var i = { - [Symbol.iterator]: { - p: null - }, - [Symbol.toStringTag]() { - return { - p: undefined - }; - } + [Symbol.iterator]: { p: null }, + [Symbol.toStringTag]() { return { p: undefined }; } }; var it = i[Symbol.iterator]; var str = i[Symbol.toStringTag](); diff --git a/tests/baselines/reference/symbolProperty2.js b/tests/baselines/reference/symbolProperty2.js index 5c0f89b025..0158366f9d 100644 --- a/tests/baselines/reference/symbolProperty2.js +++ b/tests/baselines/reference/symbolProperty2.js @@ -12,8 +12,7 @@ var x = { var s = Symbol(); var x = { [s]: 0, - [s]() { - }, + [s]() { }, get [s]() { return 0; } diff --git a/tests/baselines/reference/symbolProperty20.js b/tests/baselines/reference/symbolProperty20.js index cfb763dc20..dd60a87cbe 100644 --- a/tests/baselines/reference/symbolProperty20.js +++ b/tests/baselines/reference/symbolProperty20.js @@ -12,7 +12,5 @@ var i: I = { //// [symbolProperty20.js] var i = { [Symbol.iterator]: s => s, - [Symbol.toStringTag](n) { - return n; - } + [Symbol.toStringTag](n) { return n; } }; diff --git a/tests/baselines/reference/symbolProperty22.js b/tests/baselines/reference/symbolProperty22.js index 19989106e5..d4609c74d3 100644 --- a/tests/baselines/reference/symbolProperty22.js +++ b/tests/baselines/reference/symbolProperty22.js @@ -8,6 +8,4 @@ declare function foo(p1: T, p2: I): U; foo("", { [Symbol.unscopables]: s => s.length }); //// [symbolProperty22.js] -foo("", { - [Symbol.unscopables]: s => s.length -}); +foo("", { [Symbol.unscopables]: s => s.length }); diff --git a/tests/baselines/reference/symbolProperty28.js b/tests/baselines/reference/symbolProperty28.js index ed53a88f95..38d032b52f 100644 --- a/tests/baselines/reference/symbolProperty28.js +++ b/tests/baselines/reference/symbolProperty28.js @@ -13,9 +13,7 @@ var obj = c[Symbol.toStringTag]().x; //// [symbolProperty28.js] class C1 { [Symbol.toStringTag]() { - return { - x: "" - }; + return { x: "" }; } } class C2 extends C1 { diff --git a/tests/baselines/reference/symbolProperty29.js b/tests/baselines/reference/symbolProperty29.js index 759a775482..4e269d4a76 100644 --- a/tests/baselines/reference/symbolProperty29.js +++ b/tests/baselines/reference/symbolProperty29.js @@ -9,8 +9,6 @@ class C1 { //// [symbolProperty29.js] class C1 { [Symbol.toStringTag]() { - return { - x: "" - }; + return { x: "" }; } } diff --git a/tests/baselines/reference/symbolProperty3.js b/tests/baselines/reference/symbolProperty3.js index 6159b10f9f..dda9ca23d3 100644 --- a/tests/baselines/reference/symbolProperty3.js +++ b/tests/baselines/reference/symbolProperty3.js @@ -12,8 +12,7 @@ var x = { var s = Symbol; var x = { [s]: 0, - [s]() { - }, + [s]() { }, get [s]() { return 0; } diff --git a/tests/baselines/reference/symbolProperty30.js b/tests/baselines/reference/symbolProperty30.js index 263fdc1041..de1c92b57c 100644 --- a/tests/baselines/reference/symbolProperty30.js +++ b/tests/baselines/reference/symbolProperty30.js @@ -9,8 +9,6 @@ class C1 { //// [symbolProperty30.js] class C1 { [Symbol.toStringTag]() { - return { - x: "" - }; + return { x: "" }; } } diff --git a/tests/baselines/reference/symbolProperty31.js b/tests/baselines/reference/symbolProperty31.js index a9db50061b..b2ba8fd604 100644 --- a/tests/baselines/reference/symbolProperty31.js +++ b/tests/baselines/reference/symbolProperty31.js @@ -11,9 +11,7 @@ class C2 extends C1 { //// [symbolProperty31.js] class C1 { [Symbol.toStringTag]() { - return { - x: "" - }; + return { x: "" }; } } class C2 extends C1 { diff --git a/tests/baselines/reference/symbolProperty32.js b/tests/baselines/reference/symbolProperty32.js index 52db43bb9d..9fcfc54e92 100644 --- a/tests/baselines/reference/symbolProperty32.js +++ b/tests/baselines/reference/symbolProperty32.js @@ -11,9 +11,7 @@ class C2 extends C1 { //// [symbolProperty32.js] class C1 { [Symbol.toStringTag]() { - return { - x: "" - }; + return { x: "" }; } } class C2 extends C1 { diff --git a/tests/baselines/reference/symbolProperty33.js b/tests/baselines/reference/symbolProperty33.js index 8a0e3f691b..8ae5d305af 100644 --- a/tests/baselines/reference/symbolProperty33.js +++ b/tests/baselines/reference/symbolProperty33.js @@ -11,9 +11,7 @@ class C2 { //// [symbolProperty33.js] class C1 extends C2 { [Symbol.toStringTag]() { - return { - x: "" - }; + return { x: "" }; } } class C2 { diff --git a/tests/baselines/reference/symbolProperty34.js b/tests/baselines/reference/symbolProperty34.js index b8bcd54487..c35d6bcf46 100644 --- a/tests/baselines/reference/symbolProperty34.js +++ b/tests/baselines/reference/symbolProperty34.js @@ -11,9 +11,7 @@ class C2 { //// [symbolProperty34.js] class C1 extends C2 { [Symbol.toStringTag]() { - return { - x: "" - }; + return { x: "" }; } } class C2 { diff --git a/tests/baselines/reference/symbolProperty4.js b/tests/baselines/reference/symbolProperty4.js index be7cdab5f8..6072d6bbf7 100644 --- a/tests/baselines/reference/symbolProperty4.js +++ b/tests/baselines/reference/symbolProperty4.js @@ -10,8 +10,7 @@ var x = { //// [symbolProperty4.js] var x = { [Symbol()]: 0, - [Symbol()]() { - }, + [Symbol()]() { }, get [Symbol()]() { return 0; } diff --git a/tests/baselines/reference/symbolProperty48.js b/tests/baselines/reference/symbolProperty48.js index 283c3d0d2c..508dd8944e 100644 --- a/tests/baselines/reference/symbolProperty48.js +++ b/tests/baselines/reference/symbolProperty48.js @@ -12,7 +12,6 @@ var M; (function (M) { var Symbol; class C { - [Symbol.iterator]() { - } + [Symbol.iterator]() { } } })(M || (M = {})); diff --git a/tests/baselines/reference/symbolProperty49.js b/tests/baselines/reference/symbolProperty49.js index 027b76f76d..5ed756b086 100644 --- a/tests/baselines/reference/symbolProperty49.js +++ b/tests/baselines/reference/symbolProperty49.js @@ -12,7 +12,6 @@ var M; (function (M) { M.Symbol; class C { - [M.Symbol.iterator]() { - } + [M.Symbol.iterator]() { } } })(M || (M = {})); diff --git a/tests/baselines/reference/symbolProperty5.js b/tests/baselines/reference/symbolProperty5.js index 9f0ff3d688..c7c88681f8 100644 --- a/tests/baselines/reference/symbolProperty5.js +++ b/tests/baselines/reference/symbolProperty5.js @@ -10,8 +10,7 @@ var x = { //// [symbolProperty5.js] var x = { [Symbol.iterator]: 0, - [Symbol.isRegExp]() { - }, + [Symbol.isRegExp]() { }, get [Symbol.toStringTag]() { return 0; } diff --git a/tests/baselines/reference/symbolProperty50.js b/tests/baselines/reference/symbolProperty50.js index 30c911e8fa..76a4274b77 100644 --- a/tests/baselines/reference/symbolProperty50.js +++ b/tests/baselines/reference/symbolProperty50.js @@ -11,7 +11,6 @@ module M { var M; (function (M) { class C { - [Symbol.iterator]() { - } + [Symbol.iterator]() { } } })(M || (M = {})); diff --git a/tests/baselines/reference/symbolProperty51.js b/tests/baselines/reference/symbolProperty51.js index a9a7909842..7dd45eba09 100644 --- a/tests/baselines/reference/symbolProperty51.js +++ b/tests/baselines/reference/symbolProperty51.js @@ -11,7 +11,6 @@ module M { var M; (function (M) { class C { - [Symbol.iterator]() { - } + [Symbol.iterator]() { } } })(M || (M = {})); diff --git a/tests/baselines/reference/symbolProperty6.js b/tests/baselines/reference/symbolProperty6.js index 311baf2c18..81be3e2a92 100644 --- a/tests/baselines/reference/symbolProperty6.js +++ b/tests/baselines/reference/symbolProperty6.js @@ -13,8 +13,7 @@ class C { constructor() { this[Symbol.iterator] = 0; } - [Symbol.isRegExp]() { - } + [Symbol.isRegExp]() { } get [Symbol.toStringTag]() { return 0; } diff --git a/tests/baselines/reference/symbolProperty7.js b/tests/baselines/reference/symbolProperty7.js index b833eecff3..51f3511f33 100644 --- a/tests/baselines/reference/symbolProperty7.js +++ b/tests/baselines/reference/symbolProperty7.js @@ -13,8 +13,7 @@ class C { constructor() { this[Symbol()] = 0; } - [Symbol()]() { - } + [Symbol()]() { } get [Symbol()]() { return 0; } diff --git a/tests/baselines/reference/symbolType13.js b/tests/baselines/reference/symbolType13.js index 56aef2cc8e..afd62079bb 100644 --- a/tests/baselines/reference/symbolType13.js +++ b/tests/baselines/reference/symbolType13.js @@ -9,9 +9,6 @@ for (var y in s) { } //// [symbolType13.js] var s = Symbol(); var x; -for (s in {}) { -} -for (x in s) { -} -for (var y in s) { -} +for (s in {}) { } +for (x in s) { } +for (var y in s) { } diff --git a/tests/baselines/reference/taggedTemplateContextualTyping1.js b/tests/baselines/reference/taggedTemplateContextualTyping1.js index 173d0f56bb..17618b50e8 100644 --- a/tests/baselines/reference/taggedTemplateContextualTyping1.js +++ b/tests/baselines/reference/taggedTemplateContextualTyping1.js @@ -26,28 +26,7 @@ function tempTag1(...rest) { // Otherwise, the arrow functions' parameters will be typed as 'any', // and it is an error to invoke an any-typed value with type arguments, // so this test will error. -tempTag1 `${x => { - x(undefined); - return x; -}}${10}`; -tempTag1 `${x => { - x(undefined); - return x; -}}${y => { - y(undefined); - return y; -}}${10}`; -tempTag1 `${x => { - x(undefined); - return x; -}}${(y) => { - y(undefined); - return y; -}}${undefined}`; -tempTag1 `${(x) => { - x(undefined); - return x; -}}${y => { - y(undefined); - return y; -}}${undefined}`; +tempTag1 `${x => { x(undefined); return x; }}${10}`; +tempTag1 `${x => { x(undefined); return x; }}${y => { y(undefined); return y; }}${10}`; +tempTag1 `${x => { x(undefined); return x; }}${(y) => { y(undefined); return y; }}${undefined}`; +tempTag1 `${(x) => { x(undefined); return x; }}${y => { y(undefined); return y; }}${undefined}`; diff --git a/tests/baselines/reference/taggedTemplateContextualTyping2.js b/tests/baselines/reference/taggedTemplateContextualTyping2.js index 1eed600da4..8adea53f47 100644 --- a/tests/baselines/reference/taggedTemplateContextualTyping2.js +++ b/tests/baselines/reference/taggedTemplateContextualTyping2.js @@ -25,18 +25,6 @@ function tempTag2(...rest) { // Otherwise, the arrow functions' parameters will be typed as 'any', // and it is an error to invoke an any-typed value with type arguments, // so this test will error. -tempTag2 `${x => { - x(undefined); - return x; -}}${0}`; -tempTag2 `${x => { - x(undefined); - return x; -}}${y => { - y(null); - return y; -}}${"hello"}`; -tempTag2 `${x => { - x(undefined); - return x; -}}${undefined}${"hello"}`; +tempTag2 `${x => { x(undefined); return x; }}${0}`; +tempTag2 `${x => { x(undefined); return x; }}${y => { y(null); return y; }}${"hello"}`; +tempTag2 `${x => { x(undefined); return x; }}${undefined}${"hello"}`; diff --git a/tests/baselines/reference/taggedTemplateStringsTypeArgumentInference.js b/tests/baselines/reference/taggedTemplateStringsTypeArgumentInference.js index 5b128221aa..1b6e3ab92c 100644 --- a/tests/baselines/reference/taggedTemplateStringsTypeArgumentInference.js +++ b/tests/baselines/reference/taggedTemplateStringsTypeArgumentInference.js @@ -95,115 +95,48 @@ var arr: any[]; //// [taggedTemplateStringsTypeArgumentInference.js] // Generic tag with one parameter -function noParams(n) { -} +function noParams(n) { } (_a = [""], _a.raw = [""], noParams(_a)); // Generic tag with parameter which does not use type parameter -function noGenericParams(n) { -} +function noGenericParams(n) { } (_b = [""], _b.raw = [""], noGenericParams(_b)); // Generic tag with multiple type parameters and only one used in parameter type annotation -function someGenerics1a(n, m) { -} +function someGenerics1a(n, m) { } (_c = ["", ""], _c.raw = ["", ""], someGenerics1a(_c, 3)); -function someGenerics1b(n, m) { -} +function someGenerics1b(n, m) { } (_d = ["", ""], _d.raw = ["", ""], someGenerics1b(_d, 3)); // Generic tag with argument of function type whose parameter is of type parameter type -function someGenerics2a(strs, n) { -} -(_e = ["", ""], _e.raw = ["", ""], someGenerics2a(_e, function (n) { - return n; -})); -function someGenerics2b(strs, n) { -} -(_f = ["", ""], _f.raw = ["", ""], someGenerics2b(_f, function (n, x) { - return n; -})); +function someGenerics2a(strs, n) { } +(_e = ["", ""], _e.raw = ["", ""], someGenerics2a(_e, function (n) { return n; })); +function someGenerics2b(strs, n) { } +(_f = ["", ""], _f.raw = ["", ""], someGenerics2b(_f, function (n, x) { return n; })); // Generic tag with argument of function type whose parameter is not of type parameter type but body/return type uses type parameter -function someGenerics3(strs, producer) { -} -(_g = ["", ""], _g.raw = ["", ""], someGenerics3(_g, function () { - return ''; -})); -(_h = ["", ""], _h.raw = ["", ""], someGenerics3(_h, function () { - return undefined; -})); -(_j = ["", ""], _j.raw = ["", ""], someGenerics3(_j, function () { - return 3; -})); +function someGenerics3(strs, producer) { } +(_g = ["", ""], _g.raw = ["", ""], someGenerics3(_g, function () { return ''; })); +(_h = ["", ""], _h.raw = ["", ""], someGenerics3(_h, function () { return undefined; })); +(_j = ["", ""], _j.raw = ["", ""], someGenerics3(_j, function () { return 3; })); // 2 parameter generic tag with argument 1 of type parameter type and argument 2 of function type whose parameter is of type parameter type -function someGenerics4(strs, n, f) { -} -(_k = ["", "", ""], _k.raw = ["", "", ""], someGenerics4(_k, 4, function () { - return null; -})); -(_l = ["", "", ""], _l.raw = ["", "", ""], someGenerics4(_l, '', function () { - return 3; -})); +function someGenerics4(strs, n, f) { } +(_k = ["", "", ""], _k.raw = ["", "", ""], someGenerics4(_k, 4, function () { return null; })); +(_l = ["", "", ""], _l.raw = ["", "", ""], someGenerics4(_l, '', function () { return 3; })); (_m = ["", "", ""], _m.raw = ["", "", ""], someGenerics4(_m, null, null)); // 2 parameter generic tag with argument 2 of type parameter type and argument 1 of function type whose parameter is of type parameter type -function someGenerics5(strs, n, f) { -} -(_o = ["", " ", ""], _o.raw = ["", " ", ""], someGenerics5(_o, 4, function () { - return null; -})); -(_p = ["", "", ""], _p.raw = ["", "", ""], someGenerics5(_p, '', function () { - return 3; -})); +function someGenerics5(strs, n, f) { } +(_o = ["", " ", ""], _o.raw = ["", " ", ""], someGenerics5(_o, 4, function () { return null; })); +(_p = ["", "", ""], _p.raw = ["", "", ""], someGenerics5(_p, '', function () { return 3; })); (_q = ["", "", ""], _q.raw = ["", "", ""], someGenerics5(_q, null, null)); // Generic tag with multiple arguments of function types that each have parameters of the same generic type -function someGenerics6(strs, a, b, c) { -} -(_r = ["", "", "", ""], _r.raw = ["", "", "", ""], someGenerics6(_r, function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -})); -(_s = ["", "", "", ""], _s.raw = ["", "", "", ""], someGenerics6(_s, function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -})); -(_t = ["", "", "", ""], _t.raw = ["", "", "", ""], someGenerics6(_t, function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -})); +function someGenerics6(strs, a, b, c) { } +(_r = ["", "", "", ""], _r.raw = ["", "", "", ""], someGenerics6(_r, function (n) { return n; }, function (n) { return n; }, function (n) { return n; })); +(_s = ["", "", "", ""], _s.raw = ["", "", "", ""], someGenerics6(_s, function (n) { return n; }, function (n) { return n; }, function (n) { return n; })); +(_t = ["", "", "", ""], _t.raw = ["", "", "", ""], someGenerics6(_t, function (n) { return n; }, function (n) { return n; }, function (n) { return n; })); // Generic tag with multiple arguments of function types that each have parameters of different generic type -function someGenerics7(strs, a, b, c) { -} -(_u = ["", "", "", ""], _u.raw = ["", "", "", ""], someGenerics7(_u, function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -})); -(_v = ["", "", "", ""], _v.raw = ["", "", "", ""], someGenerics7(_v, function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -})); -(_w = ["", "", "", ""], _w.raw = ["", "", "", ""], someGenerics7(_w, function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -})); +function someGenerics7(strs, a, b, c) { } +(_u = ["", "", "", ""], _u.raw = ["", "", "", ""], someGenerics7(_u, function (n) { return n; }, function (n) { return n; }, function (n) { return n; })); +(_v = ["", "", "", ""], _v.raw = ["", "", "", ""], someGenerics7(_v, function (n) { return n; }, function (n) { return n; }, function (n) { return n; })); +(_w = ["", "", "", ""], _w.raw = ["", "", "", ""], someGenerics7(_w, function (n) { return n; }, function (n) { return n; }, function (n) { return n; })); // Generic tag with argument of generic function type -function someGenerics8(strs, n) { - return n; -} +function someGenerics8(strs, n) { return n; } var x = (_x = ["", ""], _x.raw = ["", ""], someGenerics8(_x, someGenerics7)); (_y = ["", "", "", ""], _y.raw = ["", "", "", ""], x(_y, null, null, null)); // Generic tag with multiple parameters of generic type passed arguments with no best common type @@ -212,22 +145,10 @@ function someGenerics9(strs, a, b, c) { } var a9a = (_z = ["", "", "", ""], _z.raw = ["", "", "", ""], someGenerics9(_z, '', 0, [])); var a9a; -var a9e = (_0 = ["", "", "", ""], _0.raw = ["", "", "", ""], someGenerics9(_0, undefined, { - x: 6, - z: new Date() -}, { - x: 6, - y: '' -})); +var a9e = (_0 = ["", "", "", ""], _0.raw = ["", "", "", ""], someGenerics9(_0, undefined, { x: 6, z: new Date() }, { x: 6, y: '' })); var a9e; // Generic tag with multiple parameters of generic type passed arguments with a single best common type -var a9d = (_1 = ["", "", "", ""], _1.raw = ["", "", "", ""], someGenerics9(_1, { - x: 3 -}, { - x: 6 -}, { - x: 6 -})); +var a9d = (_1 = ["", "", "", ""], _1.raw = ["", "", "", ""], someGenerics9(_1, { x: 3 }, { x: 6 }, { x: 6 })); var a9d; // Generic tag with multiple parameters of generic type where one argument is of type 'any' var anyVar; diff --git a/tests/baselines/reference/taggedTemplateStringsTypeArgumentInferenceES6.js b/tests/baselines/reference/taggedTemplateStringsTypeArgumentInferenceES6.js index 1fdeb3e4b3..2f57882b4b 100644 --- a/tests/baselines/reference/taggedTemplateStringsTypeArgumentInferenceES6.js +++ b/tests/baselines/reference/taggedTemplateStringsTypeArgumentInferenceES6.js @@ -94,61 +94,48 @@ var arr: any[]; //// [taggedTemplateStringsTypeArgumentInferenceES6.js] // Generic tag with one parameter -function noParams(n) { -} +function noParams(n) { } noParams ``; // Generic tag with parameter which does not use type parameter -function noGenericParams(n) { -} +function noGenericParams(n) { } noGenericParams ``; // Generic tag with multiple type parameters and only one used in parameter type annotation -function someGenerics1a(n, m) { -} +function someGenerics1a(n, m) { } someGenerics1a `${3}`; -function someGenerics1b(n, m) { -} +function someGenerics1b(n, m) { } someGenerics1b `${3}`; // Generic tag with argument of function type whose parameter is of type parameter type -function someGenerics2a(strs, n) { -} +function someGenerics2a(strs, n) { } someGenerics2a `${(n) => n}`; -function someGenerics2b(strs, n) { -} +function someGenerics2b(strs, n) { } someGenerics2b `${(n, x) => n}`; // Generic tag with argument of function type whose parameter is not of type parameter type but body/return type uses type parameter -function someGenerics3(strs, producer) { -} +function someGenerics3(strs, producer) { } someGenerics3 `${() => ''}`; someGenerics3 `${() => undefined}`; someGenerics3 `${() => 3}`; // 2 parameter generic tag with argument 1 of type parameter type and argument 2 of function type whose parameter is of type parameter type -function someGenerics4(strs, n, f) { -} +function someGenerics4(strs, n, f) { } someGenerics4 `${4}${() => null}`; someGenerics4 `${''}${() => 3}`; someGenerics4 `${null}${null}`; // 2 parameter generic tag with argument 2 of type parameter type and argument 1 of function type whose parameter is of type parameter type -function someGenerics5(strs, n, f) { -} +function someGenerics5(strs, n, f) { } someGenerics5 `${4} ${() => null}`; someGenerics5 `${''}${() => 3}`; someGenerics5 `${null}${null}`; // Generic tag with multiple arguments of function types that each have parameters of the same generic type -function someGenerics6(strs, a, b, c) { -} +function someGenerics6(strs, a, b, c) { } someGenerics6 `${n => n}${n => n}${n => n}`; someGenerics6 `${n => n}${n => n}${n => n}`; someGenerics6 `${(n) => n}${(n) => n}${(n) => n}`; // Generic tag with multiple arguments of function types that each have parameters of different generic type -function someGenerics7(strs, a, b, c) { -} +function someGenerics7(strs, a, b, c) { } someGenerics7 `${n => n}${n => n}${n => n}`; someGenerics7 `${n => n}${n => n}${n => n}`; someGenerics7 `${(n) => n}${(n) => n}${(n) => n}`; // Generic tag with argument of generic function type -function someGenerics8(strs, n) { - return n; -} +function someGenerics8(strs, n) { return n; } var x = someGenerics8 `${someGenerics7}`; x `${null}${null}${null}`; // Generic tag with multiple parameters of generic type passed arguments with no best common type @@ -157,22 +144,10 @@ function someGenerics9(strs, a, b, c) { } var a9a = someGenerics9 `${''}${0}${[]}`; var a9a; -var a9e = someGenerics9 `${undefined}${{ - x: 6, - z: new Date() -}}${{ - x: 6, - y: '' -}}`; +var a9e = someGenerics9 `${undefined}${{ x: 6, z: new Date() }}${{ x: 6, y: '' }}`; var a9e; // 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 -}}`; +var a9d = someGenerics9 `${{ x: 3 }}${{ x: 6 }}${{ x: 6 }}`; var a9d; // Generic tag with multiple parameters of generic type where one argument is of type 'any' var anyVar; diff --git a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3.js b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3.js index 24b0b16ea3..48c03b6d41 100644 --- a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3.js +++ b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3.js @@ -74,15 +74,11 @@ fn5 `${ (n) => n.substr(0) }`; //// [taggedTemplateStringsWithOverloadResolution3.js] -function fn1() { - return null; -} +function fn1() { return null; } var s = (_a = ["", ""], _a.raw = ["", ""], fn1(_a, undefined)); // No candidate overloads found (_b = ["", ""], _b.raw = ["", ""], fn1(_b, {})); // Error -function fn2() { - return undefined; -} +function fn2() { return undefined; } var d1 = (_c = ["", "", ""], _c.raw = ["", "", ""], fn2(_c, 0, undefined)); // contextually typed var d2 = (_d = ["", "", ""], _d.raw = ["", "", ""], fn2(_d, 0, undefined)); // any d1.foo(); // error @@ -91,9 +87,7 @@ d2(); // no error (typed as any) (_e = ["", "", ""], _e.raw = ["", "", ""], fn2(_e, 0, '')); // OK // Generic and non-generic overload where non-generic overload is the only candidate (_f = ["", "", ""], _f.raw = ["", "", ""], fn2(_f, '', 0)); // OK -function fn3() { - return null; -} +function fn3() { return null; } var s = (_g = ["", ""], _g.raw = ["", ""], fn3(_g, 3)); var s = (_h = ["", "", "", ""], _h.raw = ["", "", "", ""], fn3(_h, '', 3, '')); var n = (_j = ["", "", "", ""], _j.raw = ["", "", "", ""], fn3(_j, 5, 5, 5)); @@ -104,8 +98,7 @@ var s = (_l = ["", "", "", ""], _l.raw = ["", "", "", ""], fn3(_l, '', '', '')); var n = (_m = ["", "", "", ""], _m.raw = ["", "", "", ""], fn3(_m, '', '', 3)); // Generic overloads with differing arity tagging with argument count that doesn't match any overload (_o = [""], _o.raw = [""], fn3(_o)); // Error -function fn4() { -} +function fn4() { } // Generic overloads with constraints tagged with types that satisfy the constraints (_p = ["", "", ""], _p.raw = ["", "", ""], fn4(_p, '', 3)); (_q = ["", "", ""], _q.raw = ["", "", ""], fn4(_q, 3, '')); @@ -116,13 +109,7 @@ function fn4() { // Generic overloads with constraints called without type arguments but with types that do not satisfy the constraints (_u = ["", "", ""], _u.raw = ["", "", ""], fn4(_u, true, null)); (_v = ["", "", ""], _v.raw = ["", "", ""], fn4(_v, null, true)); -function fn5() { - return undefined; -} -(_w = ["", ""], _w.raw = ["", ""], fn5(_w, function (n) { - return n.toFixed(); -})); // will error; 'n' should have type 'string'. -(_x = ["", ""], _x.raw = ["", ""], fn5(_x, function (n) { - return n.substr(0); -})); +function fn5() { return undefined; } +(_w = ["", ""], _w.raw = ["", ""], fn5(_w, function (n) { return n.toFixed(); })); // will error; 'n' should have type 'string'. +(_x = ["", ""], _x.raw = ["", ""], fn5(_x, function (n) { return n.substr(0); })); var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x; diff --git a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3_ES6.js b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3_ES6.js index 666974de44..583770b9cd 100644 --- a/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3_ES6.js +++ b/tests/baselines/reference/taggedTemplateStringsWithOverloadResolution3_ES6.js @@ -73,15 +73,11 @@ fn5 `${ (n) => n.substr(0) }`; //// [taggedTemplateStringsWithOverloadResolution3_ES6.js] -function fn1() { - return null; -} +function fn1() { return null; } var s = fn1 `${undefined}`; // No candidate overloads found fn1 `${{}}`; // Error -function fn2() { - return undefined; -} +function fn2() { return undefined; } var d1 = fn2 `${0}${undefined}`; // contextually typed var d2 = fn2 `${0}${undefined}`; // any d1.foo(); // error @@ -90,9 +86,7 @@ d2(); // no error (typed as any) fn2 `${0}${''}`; // OK // Generic and non-generic overload where non-generic overload is the only candidate fn2 `${''}${0}`; // OK -function fn3() { - return null; -} +function fn3() { return null; } var s = fn3 `${3}`; var s = fn3 `${''}${3}${''}`; var n = fn3 `${5}${5}${5}`; @@ -103,8 +97,7 @@ var s = fn3 `${''}${''}${''}`; var n = fn3 `${''}${''}${3}`; // Generic overloads with differing arity tagging with argument count that doesn't match any overload fn3 ``; // Error -function fn4() { -} +function fn4() { } // Generic overloads with constraints tagged with types that satisfy the constraints fn4 `${''}${3}`; fn4 `${3}${''}`; @@ -115,8 +108,6 @@ fn4 `${null}${null}`; // Error // Generic overloads with constraints called without type arguments but with types that do not satisfy the constraints fn4 `${true}${null}`; fn4 `${null}${true}`; -function fn5() { - return undefined; -} +function fn5() { return undefined; } fn5 `${(n) => n.toFixed()}`; // will error; 'n' should have type 'string'. fn5 `${(n) => n.substr(0)}`; diff --git a/tests/baselines/reference/taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js b/tests/baselines/reference/taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js index 10a8f1f2a1..f7523eb987 100644 --- a/tests/baselines/reference/taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js +++ b/tests/baselines/reference/taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js @@ -13,7 +13,5 @@ function foo() { rest[_i - 0] = arguments[_i]; } } -(_a = ["", ""], _a.raw = ["", ""], foo(_a, function (x) { - x = "bad"; -})); +(_a = ["", ""], _a.raw = ["", ""], foo(_a, function (x) { x = "bad"; })); var _a; diff --git a/tests/baselines/reference/taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js b/tests/baselines/reference/taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js index bc18a60045..7691b83b3b 100644 --- a/tests/baselines/reference/taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js +++ b/tests/baselines/reference/taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js @@ -8,6 +8,4 @@ foo `${function (x: number) { x = "bad"; } }`; //// [taggedTemplateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js] function foo(...rest) { } -foo `${function (x) { - x = "bad"; -}}`; +foo `${function (x) { x = "bad"; }}`; diff --git a/tests/baselines/reference/targetTypeArgs.js b/tests/baselines/reference/targetTypeArgs.js index cb227f81b4..18dff375ab 100644 --- a/tests/baselines/reference/targetTypeArgs.js +++ b/tests/baselines/reference/targetTypeArgs.js @@ -18,36 +18,10 @@ foo(function(x) { x }); function foo(callback) { callback("hello"); } -foo(function (x) { - x; -}); -[ - 1 -].forEach(function (v, i, a) { - v; -}); -[ - "hello" -].every(function (v, i, a) { - return true; -}); -[ - 1 -].every(function (v, i, a) { - return true; -}); -[ - 1 -].every(function (v, i, a) { - return true; -}); -[ - "s" -].every(function (v, i, a) { - return true; -}); -[ - "s" -].forEach(function (v, i, a) { - v; -}); +foo(function (x) { x; }); +[1].forEach(function (v, i, a) { v; }); +["hello"].every(function (v, i, a) { return true; }); +[1].every(function (v, i, a) { return true; }); +[1].every(function (v, i, a) { return true; }); +["s"].every(function (v, i, a) { return true; }); +["s"].forEach(function (v, i, a) { v; }); diff --git a/tests/baselines/reference/targetTypeBaseCalls.js b/tests/baselines/reference/targetTypeBaseCalls.js index d844354b15..c886183bac 100644 --- a/tests/baselines/reference/targetTypeBaseCalls.js +++ b/tests/baselines/reference/targetTypeBaseCalls.js @@ -25,25 +25,18 @@ var __extends = this.__extends || function (d, b) { __.prototype = b.prototype; d.prototype = new __(); }; -function foo(x) { -} +function foo(x) { } var Foo = (function () { function Foo(x) { } return Foo; })(); -foo(function (s) { - s = 5; -}); // Error, can’t assign number to string -new Foo(function (s) { - s = 5; -}); // error, if types are applied correctly +foo(function (s) { s = 5; }); // Error, can’t assign number to string +new Foo(function (s) { s = 5; }); // error, if types are applied correctly var Bar = (function (_super) { __extends(Bar, _super); function Bar() { - _super.call(this, function (s) { - s = 5; - }); + _super.call(this, function (s) { s = 5; }); } return Bar; })(Foo); // error, if types are applied correctly diff --git a/tests/baselines/reference/targetTypeCalls.js b/tests/baselines/reference/targetTypeCalls.js index 302419a269..168195216c 100644 --- a/tests/baselines/reference/targetTypeCalls.js +++ b/tests/baselines/reference/targetTypeCalls.js @@ -6,27 +6,7 @@ var fra3: (v:any)=>string = function() { return function() { return function(v) var fra4: (v:any)=>void = function() { return function() { return function(v) {return v;};}(); }() // should work //// [targetTypeCalls.js] -var fra1 = function () { - return function (v) { - return v; - }; -}(); // should work -var fra2 = function () { - return function () { - return 0; - }; -}(); // should work -var fra3 = function () { - return function () { - return function (v) { - return v; - }; - }(); -}(); // should work -var fra4 = function () { - return function () { - return function (v) { - return v; - }; - }(); -}(); // should work +var fra1 = function () { return function (v) { return v; }; }(); // should work +var fra2 = function () { return function () { return 0; }; }(); // should work +var fra3 = function () { return function () { return function (v) { return v; }; }(); }(); // should work +var fra4 = function () { return function () { return function (v) { return v; }; }(); }(); // should work diff --git a/tests/baselines/reference/targetTypeCastTest.js b/tests/baselines/reference/targetTypeCastTest.js index c9a30c6d68..053aced730 100644 --- a/tests/baselines/reference/targetTypeCastTest.js +++ b/tests/baselines/reference/targetTypeCastTest.js @@ -28,12 +28,8 @@ function Point(x, y) { this.x = x; this.y = y; } -var add = function (x, y) { - return x + y; -}; +var add = function (x, y) { return x + y; }; var add2 = function (x, y) { return 0; }; -function add3(x, y) { - x; -} +function add3(x, y) { x; } diff --git a/tests/baselines/reference/targetTypeObjectLiteralToAny.js b/tests/baselines/reference/targetTypeObjectLiteralToAny.js index f6228f210f..fced520e09 100644 --- a/tests/baselines/reference/targetTypeObjectLiteralToAny.js +++ b/tests/baselines/reference/targetTypeObjectLiteralToAny.js @@ -15,9 +15,6 @@ function suggest() { var TypeScriptKeywords; var result; TypeScriptKeywords.forEach(function (keyword) { - result.push({ - text: keyword, - type: "keyword" - }); // this should not cause a crash - push should be typed to any + result.push({ text: keyword, type: "keyword" }); // this should not cause a crash - push should be typed to any }); } diff --git a/tests/baselines/reference/targetTypeTest1.js b/tests/baselines/reference/targetTypeTest1.js index 8c9156d1e0..8f9657ee9d 100644 --- a/tests/baselines/reference/targetTypeTest1.js +++ b/tests/baselines/reference/targetTypeTest1.js @@ -80,9 +80,7 @@ function Point(x, y) { this.x = x; this.y = y; } -function EF1(a, b) { - return a + b; -} +function EF1(a, b) { return a + b; } var x = EF1(1, 2); // Point.origin declared as type Point Point.origin = new Point(0, 0); @@ -110,10 +108,10 @@ function C(a, b) { this.a = a; this.b = b; } -C.prototype = { - a: 0, - b: 0, - C1M1: function (c, d) { - return (this.a + c) + (this.b + d); - } -}; +C.prototype = + { a: 0, + b: 0, + C1M1: function (c, d) { + return (this.a + c) + (this.b + d); + } + }; diff --git a/tests/baselines/reference/targetTypeTest2.js b/tests/baselines/reference/targetTypeTest2.js index 2d0a7dee46..0ba82bc9cc 100644 --- a/tests/baselines/reference/targetTypeTest2.js +++ b/tests/baselines/reference/targetTypeTest2.js @@ -13,18 +13,8 @@ function func2(stuff1:string, stuff2:number, stuff3:number) { //// [targetTypeTest2.js] // Test target typing for array literals and call expressions -var a = [ - 1, - 2, - "3" -]; -function func1(stuff) { - return stuff; -} +var a = [1, 2, "3"]; +function func1(stuff) { return stuff; } function func2(stuff1, stuff2, stuff3) { - return func1([ - stuff1, - stuff2, - stuff3 - ]); + return func1([stuff1, stuff2, stuff3]); } diff --git a/tests/baselines/reference/targetTypeTest3.js b/tests/baselines/reference/targetTypeTest3.js index 199d998a11..1397247858 100644 --- a/tests/baselines/reference/targetTypeTest3.js +++ b/tests/baselines/reference/targetTypeTest3.js @@ -13,18 +13,8 @@ function func2(stuff1:string, stuff2:number, stuff3:number) { //// [targetTypeTest3.js] // Test target typing for array literals and call expressions -var a = [ - 1, - 2, - "3" -]; // should produce an error -function func1(stuff) { - return stuff; -} +var a = [1, 2, "3"]; // should produce an error +function func1(stuff) { return stuff; } function func2(stuff1, stuff2, stuff3) { - return func1([ - stuff1, - stuff2, - stuff3 - ]); + return func1([stuff1, stuff2, stuff3]); } diff --git a/tests/baselines/reference/targetTypeVoidFunc.js b/tests/baselines/reference/targetTypeVoidFunc.js index 9913b4bd49..dba2086b0e 100644 --- a/tests/baselines/reference/targetTypeVoidFunc.js +++ b/tests/baselines/reference/targetTypeVoidFunc.js @@ -9,9 +9,7 @@ var z = new (f1())(); //// [targetTypeVoidFunc.js] function f1() { - return function () { - return; - }; + return function () { return; }; } ; var x = f1(); diff --git a/tests/baselines/reference/targetTypingOnFunctions.js b/tests/baselines/reference/targetTypingOnFunctions.js index 5b11a34ff4..fad75a4bf6 100644 --- a/tests/baselines/reference/targetTypingOnFunctions.js +++ b/tests/baselines/reference/targetTypingOnFunctions.js @@ -4,9 +4,5 @@ var fu: (s: string) => string = function (s) { return s.toLowerCase() }; var zu = fu = function (s) { return s.toLowerCase() }; //// [targetTypingOnFunctions.js] -var fu = function (s) { - return s.toLowerCase(); -}; -var zu = fu = function (s) { - return s.toLowerCase(); -}; +var fu = function (s) { return s.toLowerCase(); }; +var zu = fu = function (s) { return s.toLowerCase(); }; diff --git a/tests/baselines/reference/templateStringInArray.js b/tests/baselines/reference/templateStringInArray.js index 175dc39f62..97d0b1a636 100644 --- a/tests/baselines/reference/templateStringInArray.js +++ b/tests/baselines/reference/templateStringInArray.js @@ -2,8 +2,4 @@ var x = [1, 2, `abc${ 123 }def`]; //// [templateStringInArray.js] -var x = [ - 1, - 2, - ("abc" + 123 + "def") -]; +var x = [1, 2, ("abc" + 123 + "def")]; diff --git a/tests/baselines/reference/templateStringInArrowFunction.js b/tests/baselines/reference/templateStringInArrowFunction.js index 984c8673cb..4c4890633e 100644 --- a/tests/baselines/reference/templateStringInArrowFunction.js +++ b/tests/baselines/reference/templateStringInArrowFunction.js @@ -2,6 +2,4 @@ var x = x => `abc${ x }def`; //// [templateStringInArrowFunction.js] -var x = function (x) { - return ("abc" + x + "def"); -}; +var x = function (x) { return ("abc" + x + "def"); }; diff --git a/tests/baselines/reference/templateStringInEqualityChecks.js b/tests/baselines/reference/templateStringInEqualityChecks.js index 54f5fa610c..f7573f8efd 100644 --- a/tests/baselines/reference/templateStringInEqualityChecks.js +++ b/tests/baselines/reference/templateStringInEqualityChecks.js @@ -5,4 +5,7 @@ var x = `abc${0}abc` === `abc` || "abc0abc" !== `abc${0}abc`; //// [templateStringInEqualityChecks.js] -var x = "abc" + 0 + "abc" === "abc" || "abc" !== "abc" + 0 + "abc" && "abc" + 0 + "abc" == "abc0abc" && "abc0abc" !== "abc" + 0 + "abc"; +var x = "abc" + 0 + "abc" === "abc" || + "abc" !== "abc" + 0 + "abc" && + "abc" + 0 + "abc" == "abc0abc" && + "abc0abc" !== "abc" + 0 + "abc"; diff --git a/tests/baselines/reference/templateStringInEqualityChecksES6.js b/tests/baselines/reference/templateStringInEqualityChecksES6.js index 317db1ab36..9bb001d9dc 100644 --- a/tests/baselines/reference/templateStringInEqualityChecksES6.js +++ b/tests/baselines/reference/templateStringInEqualityChecksES6.js @@ -5,4 +5,7 @@ var x = `abc${0}abc` === `abc` || "abc0abc" !== `abc${0}abc`; //// [templateStringInEqualityChecksES6.js] -var x = `abc${0}abc` === `abc` || `abc` !== `abc${0}abc` && `abc${0}abc` == "abc0abc" && "abc0abc" !== `abc${0}abc`; +var x = `abc${0}abc` === `abc` || + `abc` !== `abc${0}abc` && + `abc${0}abc` == "abc0abc" && + "abc0abc" !== `abc${0}abc`; diff --git a/tests/baselines/reference/templateStringInInOperator.js b/tests/baselines/reference/templateStringInInOperator.js index 6384c1096c..c496e335dd 100644 --- a/tests/baselines/reference/templateStringInInOperator.js +++ b/tests/baselines/reference/templateStringInInOperator.js @@ -2,7 +2,4 @@ var x = `${ "hi" }` in { hi: 10, hello: 20}; //// [templateStringInInOperator.js] -var x = "" + "hi" in { - hi: 10, - hello: 20 -}; +var x = "" + "hi" in { hi: 10, hello: 20 }; diff --git a/tests/baselines/reference/templateStringInInOperatorES6.js b/tests/baselines/reference/templateStringInInOperatorES6.js index 75d79fad06..bd4daef3b6 100644 --- a/tests/baselines/reference/templateStringInInOperatorES6.js +++ b/tests/baselines/reference/templateStringInInOperatorES6.js @@ -2,7 +2,4 @@ var x = `${ "hi" }` in { hi: 10, hello: 20}; //// [templateStringInInOperatorES6.js] -var x = `${"hi"}` in { - hi: 10, - hello: 20 -}; +var x = `${"hi"}` in { hi: 10, hello: 20 }; diff --git a/tests/baselines/reference/templateStringInObjectLiteral.js b/tests/baselines/reference/templateStringInObjectLiteral.js index 5a096b0adf..2e4de70f57 100644 --- a/tests/baselines/reference/templateStringInObjectLiteral.js +++ b/tests/baselines/reference/templateStringInObjectLiteral.js @@ -6,7 +6,6 @@ var x = { //// [templateStringInObjectLiteral.js] var x = (_a = ["b"], _a.raw = ["b"], ({ - a: "abc" + 123 + "def" -})(_a)); + a: "abc" + 123 + "def" })(_a)); 321; var _a; diff --git a/tests/baselines/reference/templateStringInObjectLiteralES6.js b/tests/baselines/reference/templateStringInObjectLiteralES6.js index 22144e7524..7de012185a 100644 --- a/tests/baselines/reference/templateStringInObjectLiteralES6.js +++ b/tests/baselines/reference/templateStringInObjectLiteralES6.js @@ -6,6 +6,5 @@ var x = { //// [templateStringInObjectLiteralES6.js] var x = { - a: `abc${123}def`, -} `b`; + a: `abc${123}def`, } `b`; 321; diff --git a/tests/baselines/reference/templateStringWithEmbeddedArray.js b/tests/baselines/reference/templateStringWithEmbeddedArray.js index 946bae01df..1fb6512db4 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedArray.js +++ b/tests/baselines/reference/templateStringWithEmbeddedArray.js @@ -2,8 +2,4 @@ var x = `abc${ [1,2,3] }def`; //// [templateStringWithEmbeddedArray.js] -var x = "abc" + [ - 1, - 2, - 3 -] + "def"; +var x = "abc" + [1, 2, 3] + "def"; diff --git a/tests/baselines/reference/templateStringWithEmbeddedArrayES6.js b/tests/baselines/reference/templateStringWithEmbeddedArrayES6.js index 96b311cf02..804ef7a4e7 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedArrayES6.js +++ b/tests/baselines/reference/templateStringWithEmbeddedArrayES6.js @@ -2,8 +2,4 @@ var x = `abc${ [1,2,3] }def`; //// [templateStringWithEmbeddedArrayES6.js] -var x = `abc${[ - 1, - 2, - 3 -]}def`; +var x = `abc${[1, 2, 3]}def`; diff --git a/tests/baselines/reference/templateStringWithEmbeddedArrowFunction.js b/tests/baselines/reference/templateStringWithEmbeddedArrowFunction.js index 22b9387047..eb2579b0cc 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedArrowFunction.js +++ b/tests/baselines/reference/templateStringWithEmbeddedArrowFunction.js @@ -2,6 +2,4 @@ var x = `abc${ x => x }def`; //// [templateStringWithEmbeddedArrowFunction.js] -var x = "abc" + function (x) { - return x; -} + "def"; +var x = "abc" + function (x) { return x; } + "def"; diff --git a/tests/baselines/reference/templateStringWithEmbeddedFunctionExpression.js b/tests/baselines/reference/templateStringWithEmbeddedFunctionExpression.js index 3447ff87ac..88a8349d1a 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedFunctionExpression.js +++ b/tests/baselines/reference/templateStringWithEmbeddedFunctionExpression.js @@ -2,6 +2,4 @@ var x = `abc${ function y() { return y; } }def`; //// [templateStringWithEmbeddedFunctionExpression.js] -var x = "abc" + function y() { - return y; -} + "def"; +var x = "abc" + function y() { return y; } + "def"; diff --git a/tests/baselines/reference/templateStringWithEmbeddedFunctionExpressionES6.js b/tests/baselines/reference/templateStringWithEmbeddedFunctionExpressionES6.js index 46e37c0ac1..f0e2f749cf 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedFunctionExpressionES6.js +++ b/tests/baselines/reference/templateStringWithEmbeddedFunctionExpressionES6.js @@ -2,6 +2,4 @@ var x = `abc${ function y() { return y; } }def`; //// [templateStringWithEmbeddedFunctionExpressionES6.js] -var x = `abc${function y() { - return y; -}}def`; +var x = `abc${function y() { return y; }}def`; diff --git a/tests/baselines/reference/templateStringWithEmbeddedInOperator.js b/tests/baselines/reference/templateStringWithEmbeddedInOperator.js index 27c83d6ca8..091843ea52 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedInOperator.js +++ b/tests/baselines/reference/templateStringWithEmbeddedInOperator.js @@ -2,7 +2,4 @@ var x = `abc${ "hi" in { hi: 10, hello: 20} }def`; //// [templateStringWithEmbeddedInOperator.js] -var x = "abc" + ("hi" in { - hi: 10, - hello: 20 -}) + "def"; +var x = "abc" + ("hi" in { hi: 10, hello: 20 }) + "def"; diff --git a/tests/baselines/reference/templateStringWithEmbeddedInOperatorES6.js b/tests/baselines/reference/templateStringWithEmbeddedInOperatorES6.js index 76a6643631..f6510c2fab 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedInOperatorES6.js +++ b/tests/baselines/reference/templateStringWithEmbeddedInOperatorES6.js @@ -2,7 +2,4 @@ var x = `abc${ "hi" in { hi: 10, hello: 20} }def`; //// [templateStringWithEmbeddedInOperatorES6.js] -var x = `abc${"hi" in { - hi: 10, - hello: 20 -}}def`; +var x = `abc${"hi" in { hi: 10, hello: 20 }}def`; diff --git a/tests/baselines/reference/templateStringWithEmbeddedObjectLiteral.js b/tests/baselines/reference/templateStringWithEmbeddedObjectLiteral.js index 99d801f1c8..40ecf48624 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedObjectLiteral.js +++ b/tests/baselines/reference/templateStringWithEmbeddedObjectLiteral.js @@ -2,7 +2,4 @@ var x = `abc${ { x: 10, y: 20 } }def`; //// [templateStringWithEmbeddedObjectLiteral.js] -var x = "abc" + { - x: 10, - y: 20 -} + "def"; +var x = "abc" + { x: 10, y: 20 } + "def"; diff --git a/tests/baselines/reference/templateStringWithEmbeddedObjectLiteralES6.js b/tests/baselines/reference/templateStringWithEmbeddedObjectLiteralES6.js index bf197d8631..dbc3837e13 100644 --- a/tests/baselines/reference/templateStringWithEmbeddedObjectLiteralES6.js +++ b/tests/baselines/reference/templateStringWithEmbeddedObjectLiteralES6.js @@ -2,7 +2,4 @@ var x = `abc${ { x: 10, y: 20 } }def`; //// [templateStringWithEmbeddedObjectLiteralES6.js] -var x = `abc${{ - x: 10, - y: 20 -}}def`; +var x = `abc${{ x: 10, y: 20 }}def`; diff --git a/tests/baselines/reference/templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js b/tests/baselines/reference/templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js index ef11331206..72d0fd8c8d 100644 --- a/tests/baselines/reference/templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js +++ b/tests/baselines/reference/templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js @@ -4,6 +4,4 @@ `${function (x: number) { x = "bad"; } }`; //// [templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpression.js] -"" + function (x) { - x = "bad"; -}; +"" + function (x) { x = "bad"; }; diff --git a/tests/baselines/reference/templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js b/tests/baselines/reference/templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js index 9ce47348dc..18fae66c78 100644 --- a/tests/baselines/reference/templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js +++ b/tests/baselines/reference/templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js @@ -3,6 +3,4 @@ `${function (x: number) { x = "bad"; } }`; //// [templateStringsWithTypeErrorInFunctionExpressionsInSubstitutionExpressionES6.js] -`${function (x) { - x = "bad"; -}}`; +`${function (x) { x = "bad"; }}`; diff --git a/tests/baselines/reference/ternaryExpressionSourceMap.js b/tests/baselines/reference/ternaryExpressionSourceMap.js index 24813de973..4b43726b28 100644 --- a/tests/baselines/reference/ternaryExpressionSourceMap.js +++ b/tests/baselines/reference/ternaryExpressionSourceMap.js @@ -5,9 +5,5 @@ var foo = x ? () => 0 : () => 0; //// [ternaryExpressionSourceMap.js] var x = 1; -var foo = x ? function () { - return 0; -} : function () { - return 0; -}; +var foo = x ? function () { return 0; } : function () { return 0; }; //# sourceMappingURL=ternaryExpressionSourceMap.js.map \ No newline at end of file diff --git a/tests/baselines/reference/ternaryExpressionSourceMap.js.map b/tests/baselines/reference/ternaryExpressionSourceMap.js.map index af4eaa03ab..f7ddfe9024 100644 --- a/tests/baselines/reference/ternaryExpressionSourceMap.js.map +++ b/tests/baselines/reference/ternaryExpressionSourceMap.js.map @@ -1,2 +1,2 @@ //// [ternaryExpressionSourceMap.js.map] -{"version":3,"file":"ternaryExpressionSourceMap.js","sourceRoot":"","sources":["ternaryExpressionSourceMap.ts"],"names":[],"mappings":"AACA,IAAI,CAAC,GAAG,CAAC,CAAC;AACV,IAAI,GAAG,GAAG,CAAC,GAAG;WAAM,CAAC;AAAD,CAAC,GAAG;WAAM,CAAC;AAAD,CAAC,CAAC"} \ No newline at end of file +{"version":3,"file":"ternaryExpressionSourceMap.js","sourceRoot":"","sources":["ternaryExpressionSourceMap.ts"],"names":[],"mappings":"AACA,IAAI,CAAC,GAAG,CAAC,CAAC;AACV,IAAI,GAAG,GAAG,CAAC,GAAG,cAAM,OAAA,CAAC,EAAD,CAAC,GAAG,cAAM,OAAA,CAAC,EAAD,CAAC,CAAC"} \ No newline at end of file diff --git a/tests/baselines/reference/ternaryExpressionSourceMap.sourcemap.txt b/tests/baselines/reference/ternaryExpressionSourceMap.sourcemap.txt index b1046e0b42..51807286b6 100644 --- a/tests/baselines/reference/ternaryExpressionSourceMap.sourcemap.txt +++ b/tests/baselines/reference/ternaryExpressionSourceMap.sourcemap.txt @@ -15,7 +15,7 @@ sourceFile:ternaryExpressionSourceMap.ts 4 > ^^^ 5 > ^ 6 > ^ -7 > ^^^^^^^^^^^^^^^^^^-> +7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > > 2 >var @@ -30,13 +30,25 @@ sourceFile:ternaryExpressionSourceMap.ts 5 >Emitted(1, 10) Source(2, 10) + SourceIndex(0) 6 >Emitted(1, 11) Source(2, 11) + SourceIndex(0) --- ->>>var foo = x ? function () { +>>>var foo = x ? function () { return 0; } : function () { return 0; }; 1-> 2 >^^^^ 3 > ^^^ 4 > ^^^ 5 > ^ 6 > ^^^ +7 > ^^^^^^^^^^^^^^ +8 > ^^^^^^^ +9 > ^ +10> ^^ +11> ^ +12> ^^^ +13> ^^^^^^^^^^^^^^ +14> ^^^^^^^ +15> ^ +16> ^^ +17> ^ +18> ^ 1-> > 2 >var @@ -44,52 +56,35 @@ sourceFile:ternaryExpressionSourceMap.ts 4 > = 5 > x 6 > ? +7 > () => +8 > +9 > 0 +10> +11> 0 +12> : +13> () => +14> +15> 0 +16> +17> 0 +18> ; 1->Emitted(2, 1) Source(3, 1) + SourceIndex(0) 2 >Emitted(2, 5) Source(3, 5) + SourceIndex(0) 3 >Emitted(2, 8) Source(3, 8) + SourceIndex(0) 4 >Emitted(2, 11) Source(3, 11) + SourceIndex(0) 5 >Emitted(2, 12) Source(3, 12) + SourceIndex(0) 6 >Emitted(2, 15) Source(3, 15) + SourceIndex(0) ---- ->>> return 0; -1 >^^^^^^^^^^^ -2 > ^ -3 > ^^^^^^-> -1 >() => -2 > 0 -1 >Emitted(3, 12) Source(3, 21) + SourceIndex(0) -2 >Emitted(3, 13) Source(3, 22) + SourceIndex(0) ---- ->>>} : function () { -1-> -2 >^ -3 > ^^^ -4 > ^^^^^^^^^^-> -1-> -2 >0 -3 > : -1->Emitted(4, 1) Source(3, 21) + SourceIndex(0) -2 >Emitted(4, 2) Source(3, 22) + SourceIndex(0) -3 >Emitted(4, 5) Source(3, 25) + SourceIndex(0) ---- ->>> return 0; -1->^^^^^^^^^^^ -2 > ^ -1->() => -2 > 0 -1->Emitted(5, 12) Source(3, 31) + SourceIndex(0) -2 >Emitted(5, 13) Source(3, 32) + SourceIndex(0) ---- ->>>}; -1 > -2 >^ -3 > ^ -4 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> -1 > -2 >0 -3 > ; -1 >Emitted(6, 1) Source(3, 31) + SourceIndex(0) -2 >Emitted(6, 2) Source(3, 32) + SourceIndex(0) -3 >Emitted(6, 3) Source(3, 33) + SourceIndex(0) +7 >Emitted(2, 29) Source(3, 21) + SourceIndex(0) +8 >Emitted(2, 36) Source(3, 21) + SourceIndex(0) +9 >Emitted(2, 37) Source(3, 22) + SourceIndex(0) +10>Emitted(2, 39) Source(3, 21) + SourceIndex(0) +11>Emitted(2, 40) Source(3, 22) + SourceIndex(0) +12>Emitted(2, 43) Source(3, 25) + SourceIndex(0) +13>Emitted(2, 57) Source(3, 31) + SourceIndex(0) +14>Emitted(2, 64) Source(3, 31) + SourceIndex(0) +15>Emitted(2, 65) Source(3, 32) + SourceIndex(0) +16>Emitted(2, 67) Source(3, 31) + SourceIndex(0) +17>Emitted(2, 68) Source(3, 32) + SourceIndex(0) +18>Emitted(2, 69) Source(3, 33) + SourceIndex(0) --- >>>//# sourceMappingURL=ternaryExpressionSourceMap.js.map \ No newline at end of file diff --git a/tests/baselines/reference/thisBinding.js b/tests/baselines/reference/thisBinding.js index 0c0547a4b9..79a27b19fd 100644 --- a/tests/baselines/reference/thisBinding.js +++ b/tests/baselines/reference/thisBinding.js @@ -27,10 +27,7 @@ var M; var C = (function () { function C() { this.x = 0; - ({ - z: 10, - f: this.f - }).f(({})); + ({ z: 10, f: this.f }).f(({})); } C.prototype.f = function (x) { x.e; // e not found diff --git a/tests/baselines/reference/thisBinding2.js b/tests/baselines/reference/thisBinding2.js index ced47c0bc7..76b99797e1 100644 --- a/tests/baselines/reference/thisBinding2.js +++ b/tests/baselines/reference/thisBinding2.js @@ -40,8 +40,6 @@ var messenger = { message: "Hello World", start: function () { var _this = this; - return setTimeout(function () { - var x = _this.message; - }, 3000); + return setTimeout(function () { var x = _this.message; }, 3000); } }; diff --git a/tests/baselines/reference/thisExpressionInCallExpressionWithTypeArguments.js b/tests/baselines/reference/thisExpressionInCallExpressionWithTypeArguments.js index 348684fe60..78b06d30dd 100644 --- a/tests/baselines/reference/thisExpressionInCallExpressionWithTypeArguments.js +++ b/tests/baselines/reference/thisExpressionInCallExpressionWithTypeArguments.js @@ -10,13 +10,7 @@ var C = (function () { } C.prototype.foo = function () { var _this = this; - [ - 1, - 2, - 3 - ].map(function (x) { - return _this; - }); + [1, 2, 3].map(function (x) { return _this; }); }; return C; })(); diff --git a/tests/baselines/reference/thisExpressionInIndexExpression.js b/tests/baselines/reference/thisExpressionInIndexExpression.js index 45094ece93..1e6661386c 100644 --- a/tests/baselines/reference/thisExpressionInIndexExpression.js +++ b/tests/baselines/reference/thisExpressionInIndexExpression.js @@ -6,7 +6,5 @@ function f() { //// [thisExpressionInIndexExpression.js] function f() { var _this = this; - return function (r) { - return r[_this]; - }; + return function (r) { return r[_this]; }; } diff --git a/tests/baselines/reference/thisExpressionOfGenericObject.js b/tests/baselines/reference/thisExpressionOfGenericObject.js index 5daa4959c6..e790050069 100644 --- a/tests/baselines/reference/thisExpressionOfGenericObject.js +++ b/tests/baselines/reference/thisExpressionOfGenericObject.js @@ -11,9 +11,7 @@ class MyClass1 { var MyClass1 = (function () { function MyClass1() { var _this = this; - (function () { - return _this; - }); + (function () { return _this; }); } return MyClass1; })(); diff --git a/tests/baselines/reference/thisInAccessors.js b/tests/baselines/reference/thisInAccessors.js index 3d3206e11f..ab52164929 100644 --- a/tests/baselines/reference/thisInAccessors.js +++ b/tests/baselines/reference/thisInAccessors.js @@ -38,9 +38,7 @@ var GetterOnly = (function () { Object.defineProperty(GetterOnly.prototype, "Value", { get: function () { var _this = this; - var fn = function () { - return _this; - }; + var fn = function () { return _this; }; return ''; }, set: function (val) { @@ -60,9 +58,7 @@ var SetterOnly = (function () { }, set: function (val) { var _this = this; - var fn = function () { - return _this; - }; + var fn = function () { return _this; }; }, enumerable: true, configurable: true @@ -76,16 +72,12 @@ var GetterAndSetter = (function () { Object.defineProperty(GetterAndSetter.prototype, "Value", { get: function () { var _this = this; - var fn = function () { - return _this; - }; + var fn = function () { return _this; }; return ''; }, set: function (val) { var _this = this; - var fn = function () { - return _this; - }; + var fn = function () { return _this; }; }, enumerable: true, configurable: true diff --git a/tests/baselines/reference/thisInArrowFunctionInStaticInitializer1.js b/tests/baselines/reference/thisInArrowFunctionInStaticInitializer1.js index fdfcc5d952..03e6ddb64d 100644 --- a/tests/baselines/reference/thisInArrowFunctionInStaticInitializer1.js +++ b/tests/baselines/reference/thisInArrowFunctionInStaticInitializer1.js @@ -9,8 +9,7 @@ class Vector { } //// [thisInArrowFunctionInStaticInitializer1.js] -function log(a) { -} +function log(a) { } var Vector = (function () { function Vector() { var _this = this; diff --git a/tests/baselines/reference/thisInInnerFunctions.js b/tests/baselines/reference/thisInInnerFunctions.js index 09ee60fdb9..d9ba3adfdf 100644 --- a/tests/baselines/reference/thisInInnerFunctions.js +++ b/tests/baselines/reference/thisInInnerFunctions.js @@ -26,9 +26,7 @@ var Foo = (function () { function inner() { var _this = this; this.y = "hi"; // 'this' should be not type to 'Foo' either - var f = function () { - return _this.y; - }; // 'this' should be not type to 'Foo' either + var f = function () { return _this.y; }; // 'this' should be not type to 'Foo' either } }; return Foo; @@ -36,9 +34,7 @@ var Foo = (function () { function test() { var _this = this; var x = function () { - (function () { - return _this; - })(); + (function () { return _this; })(); _this; }; } diff --git a/tests/baselines/reference/thisInInvalidContexts.js b/tests/baselines/reference/thisInInvalidContexts.js index 16c40a96e9..f21ebedc1e 100644 --- a/tests/baselines/reference/thisInInvalidContexts.js +++ b/tests/baselines/reference/thisInInvalidContexts.js @@ -92,8 +92,7 @@ var M; //'this' as type parameter constraint // function fn() { } // Error //'this' as a type argument -function genericFunc(x) { -} +function genericFunc(x) { } genericFunc < this > (undefined); // Should be an error var ErrClass3 = (function () { function ErrClass3() { diff --git a/tests/baselines/reference/thisInInvalidContextsExternalModule.js b/tests/baselines/reference/thisInInvalidContextsExternalModule.js index 2e8e6d10c6..e9fddd380b 100644 --- a/tests/baselines/reference/thisInInvalidContextsExternalModule.js +++ b/tests/baselines/reference/thisInInvalidContextsExternalModule.js @@ -92,8 +92,7 @@ var M; //'this' as type parameter constraint // function fn() { } // Error //'this' as a type argument -function genericFunc(x) { -} +function genericFunc(x) { } genericFunc < this > (undefined); // Should be an error var ErrClass3 = (function () { function ErrClass3() { diff --git a/tests/baselines/reference/thisInLambda.js b/tests/baselines/reference/thisInLambda.js index 40a12d9335..94c86bd5a8 100644 --- a/tests/baselines/reference/thisInLambda.js +++ b/tests/baselines/reference/thisInLambda.js @@ -26,14 +26,11 @@ var Foo = (function () { Foo.prototype.bar = function () { var _this = this; this.x; // 'this' is type 'Foo' - var f = function () { - return _this.x; - }; // 'this' should be type 'Foo' as well + var f = function () { return _this.x; }; // 'this' should be type 'Foo' as well }; return Foo; })(); -function myFn(a) { -} +function myFn(a) { } var myCls = (function () { function myCls() { var _this = this; diff --git a/tests/baselines/reference/thisInObjectLiterals.js b/tests/baselines/reference/thisInObjectLiterals.js index a2a6453e1a..79e834be15 100644 --- a/tests/baselines/reference/thisInObjectLiterals.js +++ b/tests/baselines/reference/thisInObjectLiterals.js @@ -24,10 +24,7 @@ var MyClass = (function () { } MyClass.prototype.fn = function () { //type of 'this' in an object literal is the containing scope's this - var t = { - x: this, - y: this.t - }; + var t = { x: this, y: this.t }; var t; }; return MyClass; diff --git a/tests/baselines/reference/thisInOuterClassBody.js b/tests/baselines/reference/thisInOuterClassBody.js index ecbe6fc541..0dff441bb1 100644 --- a/tests/baselines/reference/thisInOuterClassBody.js +++ b/tests/baselines/reference/thisInOuterClassBody.js @@ -28,9 +28,7 @@ var Foo = (function () { Foo.prototype.bar = function () { var _this = this; this.x; // 'this' is type 'Foo' - var f = function () { - return _this.x; - }; // 'this' should be type 'Foo' as well + var f = function () { return _this.x; }; // 'this' should be type 'Foo' as well var p = this.y; return this; }; diff --git a/tests/baselines/reference/thisInPropertyBoundDeclarations.js b/tests/baselines/reference/thisInPropertyBoundDeclarations.js index cba8fd2a8c..e5004eed43 100644 --- a/tests/baselines/reference/thisInPropertyBoundDeclarations.js +++ b/tests/baselines/reference/thisInPropertyBoundDeclarations.js @@ -92,9 +92,7 @@ var A = (function () { function inner() { this; } - (function () { - return _this; - }); + (function () { return _this; }); }; this.prop3 = function () { function inner() { @@ -102,15 +100,11 @@ var A = (function () { } }; this.prop4 = { - a: function () { - return this; - } + a: function () { return this; } }; this.prop5 = function () { return { - a: function () { - return this; - } + a: function () { return this; } }; }; } @@ -120,36 +114,19 @@ var B = (function () { function B() { var _this = this; this.prop1 = this; - this.prop2 = function () { - return _this; - }; - this.prop3 = function () { - return function () { - return function () { - return function () { - return _this; - }; - }; - }; - }; - this.prop4 = ' ' + function () { - } + ' ' + (function () { - return function () { - return function () { - return _this; - }; - }; - }); + this.prop2 = function () { return _this; }; + this.prop3 = function () { return function () { return function () { return function () { return _this; }; }; }; }; + this.prop4 = ' ' + + function () { + } + + ' ' + + (function () { return function () { return function () { return _this; }; }; }); this.prop5 = { - a: function () { - return _this; - } + a: function () { return _this; } }; this.prop6 = function () { return { - a: function () { - return _this; - } + a: function () { return _this; } }; }; } diff --git a/tests/baselines/reference/thisReferencedInFunctionInsideArrowFunction1.js b/tests/baselines/reference/thisReferencedInFunctionInsideArrowFunction1.js index 78467e8a22..99341af9f8 100644 --- a/tests/baselines/reference/thisReferencedInFunctionInsideArrowFunction1.js +++ b/tests/baselines/reference/thisReferencedInFunctionInsideArrowFunction1.js @@ -8,12 +8,9 @@ function test() } //// [thisReferencedInFunctionInsideArrowFunction1.js] -var foo = function (dummy) { -}; +var foo = function (dummy) { }; function test() { foo(function () { - return function () { - return this; - }; + return function () { return this; }; }); } diff --git a/tests/baselines/reference/throwInEnclosingStatements.js b/tests/baselines/reference/throwInEnclosingStatements.js index b52926e651..0b072434f3 100644 --- a/tests/baselines/reference/throwInEnclosingStatements.js +++ b/tests/baselines/reference/throwInEnclosingStatements.js @@ -50,9 +50,7 @@ var aa = { function fn(x) { throw x; } -(function (x) { - throw x; -}); +(function (x) { throw x; }); var y; switch (y) { case 'a': diff --git a/tests/baselines/reference/throwStatements.js b/tests/baselines/reference/throwStatements.js index 4ab370db0b..83663d08cc 100644 --- a/tests/baselines/reference/throwStatements.js +++ b/tests/baselines/reference/throwStatements.js @@ -97,9 +97,7 @@ var D = (function () { } return D; })(); -function F(x) { - return 42; -} +function F(x) { return 42; } var M; (function (M) { var A = (function () { @@ -108,9 +106,7 @@ var M; return A; })(); M.A = A; - function F2(x) { - return x.toString(); - } + function F2(x) { return x.toString(); } M.F2 = F2; })(M || (M = {})); var aNumber = 9.9; @@ -131,16 +127,12 @@ var aClass = new C(); throw aClass; var aGenericClass = new D(); throw aGenericClass; -var anObjectLiteral = { - id: 12 -}; +var anObjectLiteral = { id: 12 }; throw anObjectLiteral; var aFunction = F; throw aFunction; throw aFunction(''); -var aLambda = function (x) { - return 2; -}; +var aLambda = function (x) { return 2; }; throw aLambda; throw aLambda(1); var aModule = M; @@ -159,23 +151,11 @@ throw false; throw null; throw undefined; throw 'a string'; -throw function () { - return 'a string'; -}; -throw function (x) { - return 42; -}; -throw { - x: 12, - y: 13 -}; +throw function () { return 'a string'; }; +throw function (x) { return 42; }; +throw { x: 12, y: 13 }; throw []; -throw [ - 'a', - [ - 'b' - ] -]; +throw ['a', ['b']]; throw /[a-z]/; throw new Date(); throw new C(); diff --git a/tests/baselines/reference/tooFewArgumentsInGenericFunctionTypedArgument.js b/tests/baselines/reference/tooFewArgumentsInGenericFunctionTypedArgument.js index 8aa23c8246..4b00c5fd0f 100644 --- a/tests/baselines/reference/tooFewArgumentsInGenericFunctionTypedArgument.js +++ b/tests/baselines/reference/tooFewArgumentsInGenericFunctionTypedArgument.js @@ -19,10 +19,6 @@ var r1b = _.map(c2, rf1); //// [tooFewArgumentsInGenericFunctionTypedArgument.js] var c2; var _; -var r1a = _.map(c2, function (x) { - return x.toFixed(); -}); -var rf1 = function (x) { - return x.toFixed(); -}; +var r1a = _.map(c2, function (x) { return x.toFixed(); }); +var rf1 = function (x) { return x.toFixed(); }; var r1b = _.map(c2, rf1); diff --git a/tests/baselines/reference/tooManyTypeParameters1.js b/tests/baselines/reference/tooManyTypeParameters1.js index 3ac7dfacda..892731cbd4 100644 --- a/tests/baselines/reference/tooManyTypeParameters1.js +++ b/tests/baselines/reference/tooManyTypeParameters1.js @@ -12,11 +12,9 @@ interface I {} var i: I; //// [tooManyTypeParameters1.js] -function f() { -} +function f() { } f(); -var x = function () { -}; +var x = function () { }; x(); var C = (function () { function C() { diff --git a/tests/baselines/reference/topLevelExports.js b/tests/baselines/reference/topLevelExports.js index 0f539310b1..91e28b6a97 100644 --- a/tests/baselines/reference/topLevelExports.js +++ b/tests/baselines/reference/topLevelExports.js @@ -8,8 +8,6 @@ void log(foo).toString(); //// [topLevelExports.js] define(["require", "exports"], function (require, exports) { exports.foo = 3; - function log(n) { - return n; - } + function log(n) { return n; } void log(exports.foo).toString(); }); diff --git a/tests/baselines/reference/topLevelLambda.js b/tests/baselines/reference/topLevelLambda.js index 756a42b434..3c4f1a3bc8 100644 --- a/tests/baselines/reference/topLevelLambda.js +++ b/tests/baselines/reference/topLevelLambda.js @@ -8,7 +8,5 @@ module M { var M; (function (M) { var _this = this; - var f = function () { - _this.window; - }; + var f = function () { _this.window; }; })(M || (M = {})); diff --git a/tests/baselines/reference/topLevelLambda2.js b/tests/baselines/reference/topLevelLambda2.js index e5cb1fcac5..10059e42ef 100644 --- a/tests/baselines/reference/topLevelLambda2.js +++ b/tests/baselines/reference/topLevelLambda2.js @@ -5,8 +5,5 @@ foo(()=>this.window); //// [topLevelLambda2.js] var _this = this; -function foo(x) { -} -foo(function () { - return _this.window; -}); +function foo(x) { } +foo(function () { return _this.window; }); diff --git a/tests/baselines/reference/topLevelLambda3.js b/tests/baselines/reference/topLevelLambda3.js index 1505e38956..0314b356b0 100644 --- a/tests/baselines/reference/topLevelLambda3.js +++ b/tests/baselines/reference/topLevelLambda3.js @@ -3,6 +3,4 @@ var f = () => {this.window;} //// [topLevelLambda3.js] var _this = this; -var f = function () { - _this.window; -}; +var f = function () { _this.window; }; diff --git a/tests/baselines/reference/topLevelLambda4.js b/tests/baselines/reference/topLevelLambda4.js index 47b238cd87..863a0e9a10 100644 --- a/tests/baselines/reference/topLevelLambda4.js +++ b/tests/baselines/reference/topLevelLambda4.js @@ -4,7 +4,5 @@ export var x = () => this.window; //// [topLevelLambda4.js] define(["require", "exports"], function (require, exports) { var _this = this; - exports.x = function () { - return _this.window; - }; + exports.x = function () { return _this.window; }; }); diff --git a/tests/baselines/reference/trailingCommaInHeterogenousArrayLiteral1.js b/tests/baselines/reference/trailingCommaInHeterogenousArrayLiteral1.js index 0fdc757708..7dd59ee840 100644 --- a/tests/baselines/reference/trailingCommaInHeterogenousArrayLiteral1.js +++ b/tests/baselines/reference/trailingCommaInHeterogenousArrayLiteral1.js @@ -13,22 +13,11 @@ class arrTest { var arrTest = (function () { function arrTest() { } - arrTest.prototype.test = function (arg1) { - }; + arrTest.prototype.test = function (arg1) { }; arrTest.prototype.callTest = function () { // these two should give the same error - this.test([ - 1, - 2, - "hi", - 5, - ]); - this.test([ - 1, - 2, - "hi", - 5 - ]); + this.test([1, 2, "hi", 5,]); + this.test([1, 2, "hi", 5]); }; return arrTest; })(); diff --git a/tests/baselines/reference/trailingCommasES3.js b/tests/baselines/reference/trailingCommasES3.js index b8b8c8ad1f..554390a83e 100644 --- a/tests/baselines/reference/trailingCommasES3.js +++ b/tests/baselines/reference/trailingCommasES3.js @@ -13,35 +13,13 @@ var a5 = [1, , ]; var a6 = [, , ]; //// [trailingCommasES3.js] -var o1 = { - a: 1, - b: 2 -}; -var o2 = { - a: 1, - b: 2 -}; -var o3 = { - a: 1 -}; +var o1 = { a: 1, b: 2 }; +var o2 = { a: 1, b: 2 }; +var o3 = { a: 1 }; var o4 = {}; -var a1 = [ - 1, - 2 -]; -var a2 = [ - 1, - 2, -]; -var a3 = [ - 1, -]; +var a1 = [1, 2]; +var a2 = [1, 2,]; +var a3 = [1,]; var a4 = []; -var a5 = [ - 1, - , -]; -var a6 = [ - , - , -]; +var a5 = [1, ,]; +var a6 = [, ,]; diff --git a/tests/baselines/reference/trailingCommasES5.js b/tests/baselines/reference/trailingCommasES5.js index 8cd17e7519..e54e911189 100644 --- a/tests/baselines/reference/trailingCommasES5.js +++ b/tests/baselines/reference/trailingCommasES5.js @@ -13,35 +13,13 @@ var a5 = [1, , ]; var a6 = [, , ]; //// [trailingCommasES5.js] -var o1 = { - a: 1, - b: 2 -}; -var o2 = { - a: 1, - b: 2, -}; -var o3 = { - a: 1, -}; +var o1 = { a: 1, b: 2 }; +var o2 = { a: 1, b: 2, }; +var o3 = { a: 1, }; var o4 = {}; -var a1 = [ - 1, - 2 -]; -var a2 = [ - 1, - 2, -]; -var a3 = [ - 1, -]; +var a1 = [1, 2]; +var a2 = [1, 2,]; +var a3 = [1,]; var a4 = []; -var a5 = [ - 1, - , -]; -var a6 = [ - , - , -]; +var a5 = [1, ,]; +var a6 = [, ,]; diff --git a/tests/baselines/reference/tryCatchFinally.js b/tests/baselines/reference/tryCatchFinally.js index aeda61faca..b93f248c03 100644 --- a/tests/baselines/reference/tryCatchFinally.js +++ b/tests/baselines/reference/tryCatchFinally.js @@ -6,17 +6,10 @@ try {} catch(e) {} try {} finally {} //// [tryCatchFinally.js] -try { -} -catch (e) { -} -finally { -} -try { -} -catch (e) { -} -try { -} -finally { -} +try { } +catch (e) { } +finally { } +try { } +catch (e) { } +try { } +finally { } diff --git a/tests/baselines/reference/tryStatements.js b/tests/baselines/reference/tryStatements.js index 01d55308d1..723014c1b5 100644 --- a/tests/baselines/reference/tryStatements.js +++ b/tests/baselines/reference/tryStatements.js @@ -18,14 +18,9 @@ function fn() { catch (x) { var x; } - try { - } - finally { - } - try { - } - catch (z) { - } - finally { - } + try { } + finally { } + try { } + catch (z) { } + finally { } } diff --git a/tests/baselines/reference/tupleTypes.js b/tests/baselines/reference/tupleTypes.js index ba0aaa9d8b..451aeb5eb0 100644 --- a/tests/baselines/reference/tupleTypes.js +++ b/tests/baselines/reference/tupleTypes.js @@ -67,40 +67,15 @@ var t1; var t2 = t[2]; // number|string var t2; t = []; // Error -t = [ - 1 -]; // Error -t = [ - 1, - "hello" -]; // Ok -t = [ - "hello", - 1 -]; // Error -t = [ - 1, - "hello", - 2 -]; // Ok -var tf = [ - "hello", - function (x) { - return x.length; - } -]; -var ff1 = ff("hello", [ - "foo", - function (x) { - return x.length; - } -]); +t = [1]; // Error +t = [1, "hello"]; // Ok +t = ["hello", 1]; // Error +t = [1, "hello", 2]; // Ok +var tf = ["hello", function (x) { return x.length; }]; +var ff1 = ff("hello", ["foo", function (x) { return x.length; }]); var ff1; function tuple2(item0, item1) { - return [ - item0, - item1 - ]; + return [item0, item1]; } var tt = tuple2(1, "string"); var tt0 = tt[0]; @@ -110,14 +85,8 @@ var tt1; var tt2 = tt[2]; var tt2; tt = tuple2(1, undefined); -tt = [ - 1, - undefined -]; -tt = [ - undefined, - undefined -]; +tt = [1, undefined]; +tt = [undefined, undefined]; tt = []; // Error var a; var a1; diff --git a/tests/baselines/reference/twoAccessorsWithSameName.js b/tests/baselines/reference/twoAccessorsWithSameName.js index 7ae4d3bd1f..1e447ea120 100644 --- a/tests/baselines/reference/twoAccessorsWithSameName.js +++ b/tests/baselines/reference/twoAccessorsWithSameName.js @@ -39,9 +39,7 @@ var C = (function () { function C() { } Object.defineProperty(C.prototype, "x", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); @@ -51,8 +49,7 @@ var D = (function () { function D() { } Object.defineProperty(D.prototype, "x", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -65,8 +62,7 @@ var E = (function () { get: function () { return 1; }, - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -85,6 +81,5 @@ var y = { get x() { return 1; }, - set x(v) { - } + set x(v) { } }; diff --git a/tests/baselines/reference/twoAccessorsWithSameName2.js b/tests/baselines/reference/twoAccessorsWithSameName2.js index 437fe16cea..847f83e6a7 100644 --- a/tests/baselines/reference/twoAccessorsWithSameName2.js +++ b/tests/baselines/reference/twoAccessorsWithSameName2.js @@ -21,9 +21,7 @@ var C = (function () { function C() { } Object.defineProperty(C, "x", { - get: function () { - return 1; - }, + get: function () { return 1; }, enumerable: true, configurable: true }); @@ -33,8 +31,7 @@ var D = (function () { function D() { } Object.defineProperty(D, "x", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); @@ -47,8 +44,7 @@ var E = (function () { get: function () { return 1; }, - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/typeAliases.js b/tests/baselines/reference/typeAliases.js index 062a741092..c31a52bff4 100644 --- a/tests/baselines/reference/typeAliases.js +++ b/tests/baselines/reference/typeAliases.js @@ -122,8 +122,5 @@ var E; f15(E.x).toLowerCase(); var x; f16(x); -var y = [ - "1", - false -]; +var y = ["1", false]; y[0].toLowerCase(); diff --git a/tests/baselines/reference/typeAnnotationBestCommonTypeInArrayLiteral.js b/tests/baselines/reference/typeAnnotationBestCommonTypeInArrayLiteral.js index be252fe345..cf5ddb23cc 100644 --- a/tests/baselines/reference/typeAnnotationBestCommonTypeInArrayLiteral.js +++ b/tests/baselines/reference/typeAnnotationBestCommonTypeInArrayLiteral.js @@ -29,8 +29,7 @@ var menuData = [ "type": "image", "link": "", "icon": "modules/menu/logo.svg" - }, - { + }, { "id": "productName", "type": "default", "link": "", diff --git a/tests/baselines/reference/typeArgInference.js b/tests/baselines/reference/typeArgInference.js index 624c357cbc..7ac36fa258 100644 --- a/tests/baselines/reference/typeArgInference.js +++ b/tests/baselines/reference/typeArgInference.js @@ -16,32 +16,13 @@ var t4: { c: number; d: string }; //// [typeArgInference.js] -var o = { - a: 3, - b: "test" -}; +var o = { a: 3, b: "test" }; var x; -var t1 = x.f([ - o -], [ - o -]); +var t1 = x.f([o], [o]); var t1; -var t2 = x.f([ - o -], [ - o -]); +var t2 = x.f([o], [o]); var t2; -var t3 = x.g([ - o -], [ - o -]); +var t3 = x.g([o], [o]); var t3; -var t4 = x.g([ - o -], [ - o -]); +var t4 = x.g([o], [o]); var t4; diff --git a/tests/baselines/reference/typeArgInference2.js b/tests/baselines/reference/typeArgInference2.js index 1af776c119..193345cdeb 100644 --- a/tests/baselines/reference/typeArgInference2.js +++ b/tests/baselines/reference/typeArgInference2.js @@ -15,20 +15,7 @@ var z6 = foo({ name: "abc", a: 5 }, { name: "def", b: 5 }); // error //// [typeArgInference2.js] var z1 = foo(null); // any var z2 = foo(); // Item -var z3 = foo({ - name: null -}); // { name: any } -var z4 = foo({ - name: "abc" -}); // { name: string } -var z5 = foo({ - name: "abc", - a: 5 -}); // { name: string; a: number } -var z6 = foo({ - name: "abc", - a: 5 -}, { - name: "def", - b: 5 -}); // error +var z3 = foo({ name: null }); // { name: any } +var z4 = foo({ name: "abc" }); // { name: string } +var z5 = foo({ name: "abc", a: 5 }); // { name: string; a: number } +var z6 = foo({ name: "abc", a: 5 }, { name: "def", b: 5 }); // error diff --git a/tests/baselines/reference/typeArgInferenceWithNull.js b/tests/baselines/reference/typeArgInferenceWithNull.js index 78b0dd238f..ed7a50780a 100644 --- a/tests/baselines/reference/typeArgInferenceWithNull.js +++ b/tests/baselines/reference/typeArgInferenceWithNull.js @@ -13,19 +13,9 @@ fn6({ x: null }, y => { }, { x: "" }); // y has type { x: any }, but ideally wou //// [typeArgInferenceWithNull.js] // All legal -function fn4(n) { -} +function fn4(n) { } fn4(null); -function fn5(n) { -} -fn5({ - x: null -}); -function fn6(n, fun, n2) { -} -fn6({ - x: null -}, function (y) { -}, { - x: "" -}); // y has type { x: any }, but ideally would have type { x: string } +function fn5(n) { } +fn5({ x: null }); +function fn6(n, fun, n2) { } +fn6({ x: null }, function (y) { }, { x: "" }); // y has type { x: any }, but ideally would have type { x: string } diff --git a/tests/baselines/reference/typeArgumentConstraintResolution1.js b/tests/baselines/reference/typeArgumentConstraintResolution1.js index b7476ad2ab..fd661dd812 100644 --- a/tests/baselines/reference/typeArgumentConstraintResolution1.js +++ b/tests/baselines/reference/typeArgumentConstraintResolution1.js @@ -13,10 +13,7 @@ foo2(""); // Type Date does not satisfy the constraint 'Number' for type p //// [typeArgumentConstraintResolution1.js] -function foo1(test) { -} +function foo1(test) { } foo1(""); // should error -function foo2(test) { - return null; -} +function foo2(test) { return null; } foo2(""); // Type Date does not satisfy the constraint 'Number' for type parameter 'T extends Number' diff --git a/tests/baselines/reference/typeArgumentInference.js b/tests/baselines/reference/typeArgumentInference.js index 6de9a5951b..1d10562ac7 100644 --- a/tests/baselines/reference/typeArgumentInference.js +++ b/tests/baselines/reference/typeArgumentInference.js @@ -102,129 +102,55 @@ var arr: any[]; //// [typeArgumentInference.js] // Generic call with no parameters -function noParams() { -} +function noParams() { } noParams(); noParams(); noParams(); // Generic call with parameters but none use type parameter type -function noGenericParams(n) { -} +function noGenericParams(n) { } noGenericParams(''); noGenericParams(''); noGenericParams(''); // Generic call with multiple type parameters and only one used in parameter type annotation -function someGenerics1(n, m) { -} +function someGenerics1(n, m) { } someGenerics1(3, 4); someGenerics1(3, 4); // Generic call with argument of function type whose parameter is of type parameter type -function someGenerics2a(n) { -} -someGenerics2a(function (n) { - return n; -}); -someGenerics2a(function (n) { - return n; -}); -someGenerics2a(function (n) { - return n.substr(0); -}); -function someGenerics2b(n) { -} -someGenerics2b(function (n, x) { - return n; -}); -someGenerics2b(function (n, t) { - return n; -}); -someGenerics2b(function (n, t) { - return n.substr(t * t); -}); +function someGenerics2a(n) { } +someGenerics2a(function (n) { return n; }); +someGenerics2a(function (n) { return n; }); +someGenerics2a(function (n) { return n.substr(0); }); +function someGenerics2b(n) { } +someGenerics2b(function (n, x) { return n; }); +someGenerics2b(function (n, t) { return n; }); +someGenerics2b(function (n, t) { return n.substr(t * t); }); // Generic call with argument of function type whose parameter is not of type parameter type but body/return type uses type parameter -function someGenerics3(producer) { -} -someGenerics3(function () { - return ''; -}); -someGenerics3(function () { - return undefined; -}); -someGenerics3(function () { - return 3; -}); +function someGenerics3(producer) { } +someGenerics3(function () { return ''; }); +someGenerics3(function () { return undefined; }); +someGenerics3(function () { return 3; }); // 2 parameter generic call with argument 1 of type parameter type and argument 2 of function type whose parameter is of type parameter type -function someGenerics4(n, f) { -} -someGenerics4(4, function () { - return null; -}); -someGenerics4('', function () { - return 3; -}); +function someGenerics4(n, f) { } +someGenerics4(4, function () { return null; }); +someGenerics4('', function () { return 3; }); someGenerics4(null, null); // 2 parameter generic call with argument 2 of type parameter type and argument 1 of function type whose parameter is of type parameter type -function someGenerics5(n, f) { -} -someGenerics5(4, function () { - return null; -}); -someGenerics5('', function () { - return 3; -}); +function someGenerics5(n, f) { } +someGenerics5(4, function () { return null; }); +someGenerics5('', function () { return 3; }); someGenerics5(null, null); // Generic call with multiple arguments of function types that each have parameters of the same generic type -function someGenerics6(a, b, c) { -} -someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); +function someGenerics6(a, b, c) { } +someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Generic call with multiple arguments of function types that each have parameters of different generic type -function someGenerics7(a, b, c) { -} -someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); +function someGenerics7(a, b, c) { } +someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Generic call with argument of generic function type -function someGenerics8(n) { - return n; -} +function someGenerics8(n) { return n; } var x = someGenerics8(someGenerics7); x(null, null, null); // Generic call with multiple parameters of generic type passed arguments with no best common type @@ -233,36 +159,14 @@ function someGenerics9(a, b, c) { } var a9a = someGenerics9('', 0, []); var a9a; -var a9b = someGenerics9({ - a: 0 -}, { - b: '' -}, null); +var a9b = someGenerics9({ a: 0 }, { b: '' }, null); var a9b; -var a9e = someGenerics9(undefined, { - x: 6, - z: new Date() -}, { - x: 6, - y: '' -}); +var a9e = someGenerics9(undefined, { x: 6, z: new Date() }, { x: 6, y: '' }); var a9e; -var a9f = someGenerics9(undefined, { - x: 6, - z: new Date() -}, { - x: 6, - y: '' -}); +var a9f = someGenerics9(undefined, { x: 6, z: new Date() }, { x: 6, y: '' }); var a9f; // Generic call with multiple parameters of generic type passed arguments with a single best common type -var a9d = someGenerics9({ - x: 3 -}, { - x: 6 -}, { - x: 6 -}); +var a9d = someGenerics9({ x: 3 }, { x: 6 }, { x: 6 }); var a9d; // Generic call with multiple parameters of generic type where one argument is of type 'any' var anyVar; diff --git a/tests/baselines/reference/typeArgumentInferenceConstructSignatures.js b/tests/baselines/reference/typeArgumentInferenceConstructSignatures.js index a2346cc28a..148ec81c44 100644 --- a/tests/baselines/reference/typeArgumentInferenceConstructSignatures.js +++ b/tests/baselines/reference/typeArgumentInferenceConstructSignatures.js @@ -152,144 +152,50 @@ new someGenerics1(3, 4); new someGenerics1(3, 4); // Error new someGenerics1(3, 4); var someGenerics2a; -new someGenerics2a(function (n) { - return n; -}); -new someGenerics2a(function (n) { - return n; -}); -new someGenerics2a(function (n) { - return n.substr(0); -}); +new someGenerics2a(function (n) { return n; }); +new someGenerics2a(function (n) { return n; }); +new someGenerics2a(function (n) { return n.substr(0); }); var someGenerics2b; -new someGenerics2b(function (n, x) { - return n; -}); -new someGenerics2b(function (n, t) { - return n; -}); -new someGenerics2b(function (n, t) { - return n.substr(t * t); -}); +new someGenerics2b(function (n, x) { return n; }); +new someGenerics2b(function (n, t) { return n; }); +new someGenerics2b(function (n, t) { return n.substr(t * t); }); var someGenerics3; -new someGenerics3(function () { - return ''; -}); -new someGenerics3(function () { - return undefined; -}); -new someGenerics3(function () { - return 3; -}); +new someGenerics3(function () { return ''; }); +new someGenerics3(function () { return undefined; }); +new someGenerics3(function () { return 3; }); var someGenerics4; -new someGenerics4(4, function () { - return null; -}); -new someGenerics4('', function () { - return 3; -}); -new someGenerics4('', function (x) { - return ''; -}); // Error +new someGenerics4(4, function () { return null; }); +new someGenerics4('', function () { return 3; }); +new someGenerics4('', function (x) { return ''; }); // Error new someGenerics4(null, null); var someGenerics5; -new someGenerics5(4, function () { - return null; -}); -new someGenerics5('', function () { - return 3; -}); -new someGenerics5('', function (x) { - return ''; -}); // Error +new someGenerics5(4, function () { return null; }); +new someGenerics5('', function () { return 3; }); +new someGenerics5('', function (x) { return ''; }); // Error new someGenerics5(null, null); var someGenerics6; -new someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -new someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -new someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); // Error -new someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); +new someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +new someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +new someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Error +new someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); var someGenerics7; -new someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -new someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -new someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); +new someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +new someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +new someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); var someGenerics8; var x = new someGenerics8(someGenerics7); new x(null, null, null); var someGenerics9; var a9a = new someGenerics9('', 0, []); var a9a; -var a9b = new someGenerics9({ - a: 0 -}, { - b: '' -}, null); +var a9b = new someGenerics9({ a: 0 }, { b: '' }, null); var a9b; -var a9e = new someGenerics9(undefined, { - x: 6, - z: window -}, { - x: 6, - y: '' -}); +var a9e = new someGenerics9(undefined, { x: 6, z: window }, { x: 6, y: '' }); var a9e; -var a9f = new someGenerics9(undefined, { - x: 6, - z: window -}, { - x: 6, - y: '' -}); +var a9f = new someGenerics9(undefined, { x: 6, z: window }, { x: 6, y: '' }); var a9f; // Generic call with multiple parameters of generic type passed arguments with a single best common type -var a9d = new someGenerics9({ - x: 3 -}, { - x: 6 -}, { - x: 6 -}); +var a9d = new someGenerics9({ x: 3 }, { x: 6 }, { x: 6 }); var a9d; // Generic call with multiple parameters of generic type where one argument is of type 'any' var anyVar; diff --git a/tests/baselines/reference/typeArgumentInferenceErrors.js b/tests/baselines/reference/typeArgumentInferenceErrors.js index 97dfce01a1..7ec612d2c7 100644 --- a/tests/baselines/reference/typeArgumentInferenceErrors.js +++ b/tests/baselines/reference/typeArgumentInferenceErrors.js @@ -18,28 +18,14 @@ someGenerics6((n: number) => n, (n: string) => n, (n: number) => n); // //// [typeArgumentInferenceErrors.js] // Generic call with multiple type parameters and only one used in parameter type annotation -function someGenerics1(n, m) { -} +function someGenerics1(n, m) { } someGenerics1(3, 4); // Error // 2 parameter generic call with argument 1 of type parameter type and argument 2 of function type whose parameter is of type parameter type -function someGenerics4(n, f) { -} -someGenerics4('', function (x) { - return ''; -}); // Error +function someGenerics4(n, f) { } +someGenerics4('', function (x) { return ''; }); // Error // 2 parameter generic call with argument 2 of type parameter type and argument 1 of function type whose parameter is of type parameter type -function someGenerics5(n, f) { -} -someGenerics5('', function (x) { - return ''; -}); // Error +function someGenerics5(n, f) { } +someGenerics5('', function (x) { return ''; }); // Error // Generic call with multiple arguments of function types that each have parameters of the same generic type -function someGenerics6(a, b, c) { -} -someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); // Error +function someGenerics6(a, b, c) { } +someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Error diff --git a/tests/baselines/reference/typeArgumentInferenceOrdering.js b/tests/baselines/reference/typeArgumentInferenceOrdering.js index 53917844f6..96978bfd48 100644 --- a/tests/baselines/reference/typeArgumentInferenceOrdering.js +++ b/tests/baselines/reference/typeArgumentInferenceOrdering.js @@ -16,9 +16,7 @@ interface Goo { //// [typeArgumentInferenceOrdering.js] -function foo(f) { - return null; -} +function foo(f) { return null; } var x = foo(new C()).x; // was Error that property x does not exist on type {} var C = (function () { function C() { diff --git a/tests/baselines/reference/typeArgumentInferenceTransitiveConstraints.js b/tests/baselines/reference/typeArgumentInferenceTransitiveConstraints.js index 5a470de46d..003ae4af53 100644 --- a/tests/baselines/reference/typeArgumentInferenceTransitiveConstraints.js +++ b/tests/baselines/reference/typeArgumentInferenceTransitiveConstraints.js @@ -10,11 +10,7 @@ var d: Date[]; // Should be OK (d should be Date[]) //// [typeArgumentInferenceTransitiveConstraints.js] function fn(a, b, c) { - return [ - a, - b, - c - ]; + return [a, b, c]; } var d = fn(new Date(), new Date(), new Date()); var d; // Should be OK (d should be Date[]) diff --git a/tests/baselines/reference/typeArgumentInferenceWithConstraintAsCommonRoot.js b/tests/baselines/reference/typeArgumentInferenceWithConstraintAsCommonRoot.js index 50d7767b5d..941c9330a5 100644 --- a/tests/baselines/reference/typeArgumentInferenceWithConstraintAsCommonRoot.js +++ b/tests/baselines/reference/typeArgumentInferenceWithConstraintAsCommonRoot.js @@ -8,9 +8,7 @@ var e: Elephant; f(g, e); // valid because both Giraffe and Elephant satisfy the constraint. T is Animal //// [typeArgumentInferenceWithConstraintAsCommonRoot.js] -function f(x, y) { - return undefined; -} +function f(x, y) { return undefined; } var g; var e; f(g, e); // valid because both Giraffe and Elephant satisfy the constraint. T is Animal diff --git a/tests/baselines/reference/typeArgumentInferenceWithConstraints.js b/tests/baselines/reference/typeArgumentInferenceWithConstraints.js index ce0d3cb82e..b8c051f0c3 100644 --- a/tests/baselines/reference/typeArgumentInferenceWithConstraints.js +++ b/tests/baselines/reference/typeArgumentInferenceWithConstraints.js @@ -107,144 +107,60 @@ var arr: any[]; //// [typeArgumentInferenceWithConstraints.js] // Generic call with no parameters -function noParams() { -} +function noParams() { } noParams(); noParams(); noParams(); // Generic call with parameters but none use type parameter type -function noGenericParams(n) { -} +function noGenericParams(n) { } noGenericParams(''); // Valid noGenericParams(''); noGenericParams(''); // Error // Generic call with multiple type parameters and only one used in parameter type annotation -function someGenerics1(n, m) { -} +function someGenerics1(n, m) { } someGenerics1(3, 4); // Valid someGenerics1(3, 4); // Error someGenerics1(3, 4); // Error someGenerics1(3, 4); // Generic call with argument of function type whose parameter is of type parameter type -function someGenerics2a(n) { -} -someGenerics2a(function (n) { - return n; -}); -someGenerics2a(function (n) { - return n; -}); -someGenerics2a(function (n) { - return n.substr(0); -}); -function someGenerics2b(n) { -} -someGenerics2b(function (n, x) { - return n; -}); -someGenerics2b(function (n, t) { - return n; -}); -someGenerics2b(function (n, t) { - return n.substr(t * t); -}); +function someGenerics2a(n) { } +someGenerics2a(function (n) { return n; }); +someGenerics2a(function (n) { return n; }); +someGenerics2a(function (n) { return n.substr(0); }); +function someGenerics2b(n) { } +someGenerics2b(function (n, x) { return n; }); +someGenerics2b(function (n, t) { return n; }); +someGenerics2b(function (n, t) { return n.substr(t * t); }); // Generic call with argument of function type whose parameter is not of type parameter type but body/return type uses type parameter -function someGenerics3(producer) { -} -someGenerics3(function () { - return ''; -}); // Error -someGenerics3(function () { - return undefined; -}); -someGenerics3(function () { - return 3; -}); // Error +function someGenerics3(producer) { } +someGenerics3(function () { return ''; }); // Error +someGenerics3(function () { return undefined; }); +someGenerics3(function () { return 3; }); // Error // 2 parameter generic call with argument 1 of type parameter type and argument 2 of function type whose parameter is of type parameter type -function someGenerics4(n, f) { -} -someGenerics4(4, function () { - return null; -}); // Valid -someGenerics4('', function () { - return 3; -}); -someGenerics4('', function (x) { - return ''; -}); // Error +function someGenerics4(n, f) { } +someGenerics4(4, function () { return null; }); // Valid +someGenerics4('', function () { return 3; }); +someGenerics4('', function (x) { return ''; }); // Error someGenerics4(null, null); // 2 parameter generic call with argument 2 of type parameter type and argument 1 of function type whose parameter is of type parameter type -function someGenerics5(n, f) { -} -someGenerics5(4, function () { - return null; -}); // Valid -someGenerics5('', function () { - return 3; -}); -someGenerics5('', function (x) { - return ''; -}); // Error +function someGenerics5(n, f) { } +someGenerics5(4, function () { return null; }); // Valid +someGenerics5('', function () { return 3; }); +someGenerics5('', function (x) { return ''; }); // Error someGenerics5(null, null); // Error // Generic call with multiple arguments of function types that each have parameters of the same generic type -function someGenerics6(a, b, c) { -} -someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); // Valid -someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); // Error -someGenerics6(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); +function someGenerics6(a, b, c) { } +someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Valid +someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Error +someGenerics6(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Generic call with multiple arguments of function types that each have parameters of different generic type -function someGenerics7(a, b, c) { -} -someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); // Valid, types of n are respectively -someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); -someGenerics7(function (n) { - return n; -}, function (n) { - return n; -}, function (n) { - return n; -}); +function someGenerics7(a, b, c) { } +someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Valid, types of n are respectively +someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); +someGenerics7(function (n) { return n; }, function (n) { return n; }, function (n) { return n; }); // Generic call with argument of generic function type -function someGenerics8(n) { - return n; -} +function someGenerics8(n) { return n; } var x = someGenerics8(someGenerics7); // Error x(null, null, null); // Error // Generic call with multiple parameters of generic type passed arguments with no best common type @@ -253,36 +169,14 @@ function someGenerics9(a, b, c) { } var a9a = someGenerics9('', 0, []); var a9a; -var a9b = someGenerics9({ - a: 0 -}, { - b: '' -}, null); +var a9b = someGenerics9({ a: 0 }, { b: '' }, null); var a9b; -var a9e = someGenerics9(undefined, { - x: 6, - z: window -}, { - x: 6, - y: '' -}); +var a9e = someGenerics9(undefined, { x: 6, z: window }, { x: 6, y: '' }); var a9e; -var a9f = someGenerics9(undefined, { - x: 6, - z: window -}, { - x: 6, - y: '' -}); +var a9f = someGenerics9(undefined, { x: 6, z: window }, { x: 6, y: '' }); var a9f; // Generic call with multiple parameters of generic type passed arguments with a single best common type -var a9d = someGenerics9({ - x: 3 -}, { - x: 6 -}, { - x: 6 -}); +var a9d = someGenerics9({ x: 3 }, { x: 6 }, { x: 6 }); var a9d; // Generic call with multiple parameters of generic type where one argument is of type 'any' var anyVar; diff --git a/tests/baselines/reference/typeArgumentInferenceWithObjectLiteral.js b/tests/baselines/reference/typeArgumentInferenceWithObjectLiteral.js index 95220d4fdc..4d040cfe13 100644 --- a/tests/baselines/reference/typeArgumentInferenceWithObjectLiteral.js +++ b/tests/baselines/reference/typeArgumentInferenceWithObjectLiteral.js @@ -37,25 +37,16 @@ var v3 = f1({ w: x => x, r: () => E1.X }, E2.X); // Error //// [typeArgumentInferenceWithObjectLiteral.js] -function foo(x) { -} +function foo(x) { } var s; // Calls below should infer string for T and then assign that type to the value parameter foo({ - read: function () { - return s; - }, - write: function (value) { - return s = value; - } + read: function () { return s; }, + write: function (value) { return s = value; } }); foo({ - write: function (value) { - return s = value; - }, - read: function () { - return s; - } + write: function (value) { return s = value; }, + read: function () { return s; } }); var E1; (function (E1) { @@ -66,44 +57,9 @@ var E2; E2[E2["X"] = 0] = "X"; })(E2 || (E2 = {})); var v1; -var v1 = f1({ - w: function (x) { - return x; - }, - r: function () { - return 0; - } -}, 0); -var v1 = f1({ - w: function (x) { - return x; - }, - r: function () { - return 0; - } -}, E1.X); -var v1 = f1({ - w: function (x) { - return x; - }, - r: function () { - return E1.X; - } -}, 0); +var v1 = f1({ w: function (x) { return x; }, r: function () { return 0; } }, 0); +var v1 = f1({ w: function (x) { return x; }, r: function () { return 0; } }, E1.X); +var v1 = f1({ w: function (x) { return x; }, r: function () { return E1.X; } }, 0); var v2; -var v2 = f1({ - w: function (x) { - return x; - }, - r: function () { - return E1.X; - } -}, E1.X); -var v3 = f1({ - w: function (x) { - return x; - }, - r: function () { - return E1.X; - } -}, E2.X); // Error +var v2 = f1({ w: function (x) { return x; }, r: function () { return E1.X; } }, E1.X); +var v3 = f1({ w: function (x) { return x; }, r: function () { return E1.X; } }, E2.X); // Error diff --git a/tests/baselines/reference/typeAssertionToGenericFunctionType.js b/tests/baselines/reference/typeAssertionToGenericFunctionType.js index 4f7d30dfbd..15e5cf82f2 100644 --- a/tests/baselines/reference/typeAssertionToGenericFunctionType.js +++ b/tests/baselines/reference/typeAssertionToGenericFunctionType.js @@ -8,12 +8,8 @@ x.b(); // error //// [typeAssertionToGenericFunctionType.js] var x = { - a: (function (x) { - return 1; - }), - b: function (x) { - x; - } + a: (function (x) { return 1; }), + b: function (x) { x; } }; x.a(1); // bug was that this caused 'Could not find symbol T' on return type T in the type assertion on x.a's definition x.b(); // error diff --git a/tests/baselines/reference/typeAssertions.js b/tests/baselines/reference/typeAssertions.js index c964ae9495..01acf58227 100644 --- a/tests/baselines/reference/typeAssertions.js +++ b/tests/baselines/reference/typeAssertions.js @@ -50,10 +50,8 @@ var __extends = this.__extends || function (d, b) { d.prototype = new __(); }; // Function call whose argument is a 1 arg generic function call with explicit type arguments -function fn1(t) { -} -function fn2(t) { -} +function fn1(t) { } +function fn2(t) { } fn1(fn2(4)); // Error var a; var s; diff --git a/tests/baselines/reference/typeCheckTypeArgument.js b/tests/baselines/reference/typeCheckTypeArgument.js index 720ee92a96..bec33393f9 100644 --- a/tests/baselines/reference/typeCheckTypeArgument.js +++ b/tests/baselines/reference/typeCheckTypeArgument.js @@ -23,14 +23,11 @@ var Foo = (function () { } return Foo; })(); -function bar() { -} +function bar() { } var Foo2 = (function () { function Foo2() { } - Foo2.prototype.method = function () { - }; + Foo2.prototype.method = function () { }; return Foo2; })(); -(function (a) { -}); +(function (a) { }); diff --git a/tests/baselines/reference/typeCheckingInsideFunctionExpressionInArray.js b/tests/baselines/reference/typeCheckingInsideFunctionExpressionInArray.js index 3ea78c7a3d..9dad9fb671 100644 --- a/tests/baselines/reference/typeCheckingInsideFunctionExpressionInArray.js +++ b/tests/baselines/reference/typeCheckingInsideFunctionExpressionInArray.js @@ -8,15 +8,9 @@ var functions = [function () { //// [typeCheckingInsideFunctionExpressionInArray.js] -var functions = [ - function () { +var functions = [function () { var k = 10; k = new Object(); - [ - 1, - 2, - 3 - ].NonexistantMethod(); + [1, 2, 3].NonexistantMethod(); derp(); - } -]; + }]; diff --git a/tests/baselines/reference/typeGuardsDefeat.js b/tests/baselines/reference/typeGuardsDefeat.js index bb70c2db82..9670c260b5 100644 --- a/tests/baselines/reference/typeGuardsDefeat.js +++ b/tests/baselines/reference/typeGuardsDefeat.js @@ -69,9 +69,7 @@ function foo3(x) { return x.length; // string } else { - var f = function () { - return x * x; - }; + var f = function () { return x * x; }; } x = "hello"; f(); diff --git a/tests/baselines/reference/typeGuardsInConditionalExpression.js b/tests/baselines/reference/typeGuardsInConditionalExpression.js index ebe84879d2..118ebbc02c 100644 --- a/tests/baselines/reference/typeGuardsInConditionalExpression.js +++ b/tests/baselines/reference/typeGuardsInConditionalExpression.js @@ -105,73 +105,92 @@ function foo12(x: number | string | boolean) { // the type of a variable or parameter is narrowed by any type guard in the condition when false, // provided the false expression contains no assignments to the variable or parameter. function foo(x) { - return typeof x === "string" ? x.length // string - : x++; // number + return typeof x === "string" + ? x.length // string + : x++; // number } function foo2(x) { // x is assigned in the if true branch, the type is not narrowed - return typeof x === "string" ? (x = 10 && x) // string | number - : x; // string | number + return typeof x === "string" + ? (x = 10 && x) // string | number + : x; // string | number } function foo3(x) { // x is assigned in the if false branch, the type is not narrowed // even though assigned using same type as narrowed expression - return typeof x === "string" ? (x = "Hello" && x) // string | number - : x; // string | number + return typeof x === "string" + ? (x = "Hello" && x) // string | number + : x; // string | number } function foo4(x) { // false branch updates the variable - so here it is not number // even though assigned using same type as narrowed expression - return typeof x === "string" ? x // string | number - : (x = 10 && x); // string | number + return typeof x === "string" + ? x // string | number + : (x = 10 && x); // string | number } function foo5(x) { // false branch updates the variable - so here it is not number - return typeof x === "string" ? x // string | number - : (x = "hello" && x); // string | number + return typeof x === "string" + ? x // string | number + : (x = "hello" && x); // string | number } function foo6(x) { // Modify in both branches - return typeof x === "string" ? (x = 10 && x) // string | number - : (x = "hello" && x); // string | number + return typeof x === "string" + ? (x = 10 && x) // string | number + : (x = "hello" && x); // string | number } function foo7(x) { - return typeof x === "string" ? x === "hello" // string - : typeof x === "boolean" ? x // boolean - : x == 10; // number + return typeof x === "string" + ? x === "hello" // string + : typeof x === "boolean" + ? x // boolean + : x == 10; // number } function foo8(x) { var b; - return typeof x === "string" ? x === "hello" : ((b = x) && (typeof x === "boolean" ? x // boolean - : x == 10)); // number + return typeof x === "string" + ? x === "hello" + : ((b = x) && + (typeof x === "boolean" + ? x // boolean + : x == 10)); // number } function foo9(x) { var y = 10; // usage of x or assignment to separate variable shouldn't cause narrowing of type to stop - return typeof x === "string" ? ((y = x.length) && x === "hello") // string - : x === 10; // number + return typeof x === "string" + ? ((y = x.length) && x === "hello") // string + : x === 10; // number } function foo10(x) { // Mixing typeguards var b; - return typeof x === "string" ? x // string - : ((b = x) // x is number | boolean - && typeof x === "number" && x.toString()); // x is number + return typeof x === "string" + ? x // string + : ((b = x) // x is number | boolean + && typeof x === "number" + && x.toString()); // x is number } function foo11(x) { // Mixing typeguards // Assigning value to x deep inside another guard stops narrowing of type too var b; - return typeof x === "string" ? x // number | boolean | string - changed in the false branch - : ((b = x) // x is number | boolean | string - because the assignment changed it - && typeof x === "number" && (x = 10) // assignment to x - && x); // x is number | boolean | string + return typeof x === "string" + ? x // number | boolean | string - changed in the false branch + : ((b = x) // x is number | boolean | string - because the assignment changed it + && typeof x === "number" + && (x = 10) // assignment to x + && x); // x is number | boolean | string } function foo12(x) { // Mixing typeguards // Assigning value to x in outer guard shouldn't stop narrowing in the inner expression var b; - return typeof x === "string" ? (x = 10 && x.toString().length) // number | boolean | string - changed here - : ((b = x) // x is number | boolean | string - changed in true branch - && typeof x === "number" && x); // x is number + return typeof x === "string" + ? (x = 10 && x.toString().length) // number | boolean | string - changed here + : ((b = x) // x is number | boolean | string - changed in true branch + && typeof x === "number" + && x); // x is number } diff --git a/tests/baselines/reference/typeGuardsInFunctionAndModuleBlock.js b/tests/baselines/reference/typeGuardsInFunctionAndModuleBlock.js index 239eeb4bfe..7cf19dac0a 100644 --- a/tests/baselines/reference/typeGuardsInFunctionAndModuleBlock.js +++ b/tests/baselines/reference/typeGuardsInFunctionAndModuleBlock.js @@ -82,32 +82,44 @@ module m1 { //// [typeGuardsInFunctionAndModuleBlock.js] // typeguards are scoped in function/module block function foo(x) { - return typeof x === "string" ? x : function f() { - var b = x; // number | boolean - return typeof x === "boolean" ? x.toString() // boolean - : x.toString(); // number - }(); + return typeof x === "string" + ? x + : function f() { + var b = x; // number | boolean + return typeof x === "boolean" + ? x.toString() // boolean + : x.toString(); // number + }(); } function foo2(x) { - return typeof x === "string" ? x : function f(a) { - var b = x; // new scope - number | boolean - return typeof x === "boolean" ? x.toString() // boolean - : x.toString(); // number - }(x); // x here is narrowed to number | boolean + return typeof x === "string" + ? x + : function f(a) { + var b = x; // new scope - number | boolean + return typeof x === "boolean" + ? x.toString() // boolean + : x.toString(); // number + }(x); // x here is narrowed to number | boolean } function foo3(x) { - return typeof x === "string" ? x : (function () { - var b = x; // new scope - number | boolean - return typeof x === "boolean" ? x.toString() // boolean - : x.toString(); // number - })(); + return typeof x === "string" + ? x + : (function () { + var b = x; // new scope - number | boolean + return typeof x === "boolean" + ? x.toString() // boolean + : x.toString(); // number + })(); } function foo4(x) { - return typeof x === "string" ? x : (function (a) { - var b = x; // new scope - number | boolean - return typeof x === "boolean" ? x.toString() // boolean - : x.toString(); // number - })(x); // x here is narrowed to number | boolean + return typeof x === "string" + ? x + : (function (a) { + var b = x; // new scope - number | boolean + return typeof x === "boolean" + ? x.toString() // boolean + : x.toString(); // number + })(x); // x here is narrowed to number | boolean } // Type guards affect nested function expressions, but not nested function declarations function foo5(x) { @@ -129,8 +141,9 @@ var m; y = x; // string; } else { - y = typeof x === "boolean" ? x.toString() // boolean - : x.toString(); // number + y = typeof x === "boolean" + ? x.toString() // boolean + : x.toString(); // number } })(m2 || (m2 = {})); })(m || (m = {})); @@ -147,8 +160,9 @@ var m1; y = x; // string; } else { - y = typeof x === "boolean" ? x.toString() // boolean - : x.toString(); // number + y = typeof x === "boolean" + ? x.toString() // boolean + : x.toString(); // number } })(m3 = m2.m3 || (m2.m3 = {})); })(m2 || (m2 = {})); diff --git a/tests/baselines/reference/typeGuardsInIfStatement.js b/tests/baselines/reference/typeGuardsInIfStatement.js index c228c03857..820d205bc6 100644 --- a/tests/baselines/reference/typeGuardsInIfStatement.js +++ b/tests/baselines/reference/typeGuardsInIfStatement.js @@ -258,8 +258,9 @@ function foo10(x) { else { var y; var b = x; // number | boolean - return typeof x === "number" ? x === 10 // number - : x; // x should be boolean + return typeof x === "number" + ? x === 10 // number + : x; // x should be boolean } } function foo11(x) { @@ -271,13 +272,15 @@ function foo11(x) { else { var y; var b = x; // number | boolean | string - because below we are changing value of x in if statement - return typeof x === "number" ? ( - // change value of x - x = 10 && x.toString() // number | boolean | string - ) : ( - // do not change value - y = x && x.toString() // number | boolean | string - ); + return typeof x === "number" + ? ( + // change value of x + x = 10 && x.toString() // number | boolean | string + ) + : ( + // do not change value + y = x && x.toString() // number | boolean | string + ); } } function foo12(x) { @@ -289,7 +292,8 @@ function foo12(x) { else { x = 10; var b = x; // number | boolean | string - return typeof x === "number" ? x.toString() // number - : x.toString(); // boolean | string + return typeof x === "number" + ? x.toString() // number + : x.toString(); // boolean | string } } diff --git a/tests/baselines/reference/typeGuardsInRightOperandOfAndAndOperator.js b/tests/baselines/reference/typeGuardsInRightOperandOfAndAndOperator.js index ffba829c37..e3f1a8c72c 100644 --- a/tests/baselines/reference/typeGuardsInRightOperandOfAndAndOperator.js +++ b/tests/baselines/reference/typeGuardsInRightOperandOfAndAndOperator.js @@ -72,36 +72,40 @@ function foo3(x) { } function foo4(x) { return typeof x !== "string" // string | number | boolean - && typeof x !== "number" // number | boolean - && x; // boolean + && typeof x !== "number" // number | boolean + && x; // boolean } function foo5(x) { // usage of x or assignment to separate variable shouldn't cause narrowing of type to stop var b; return typeof x !== "string" // string | number | boolean - && ((b = x) && (typeof x !== "number" // number | boolean - && x)); // boolean + && ((b = x) && (typeof x !== "number" // number | boolean + && x)); // boolean } function foo6(x) { // Mixing typeguard narrowing in if statement with conditional expression typeguard return typeof x !== "string" // string | number | boolean - && (typeof x !== "number" // number | boolean - ? x // boolean - : x === 10); // number + && (typeof x !== "number" // number | boolean + ? x // boolean + : x === 10); // number } function foo7(x) { var y; var z; // Mixing typeguard narrowing // Assigning value to x deep inside another guard stops narrowing of type too - return typeof x !== "string" && ((z = x) // string | number | boolean - x changed deeper in conditional expression - && (typeof x === "number" ? (x = 10 && x.toString()) // number | boolean | string - : (y = x && x.toString()))); // number | boolean | string + return typeof x !== "string" + && ((z = x) // string | number | boolean - x changed deeper in conditional expression + && (typeof x === "number" + ? (x = 10 && x.toString()) // number | boolean | string + : (y = x && x.toString()))); // number | boolean | string } function foo8(x) { // Mixing typeguard // Assigning value to x in outer guard shouldn't stop narrowing in the inner expression - return typeof x !== "string" && (x = 10) // change x - number| string - && (typeof x === "number" ? x // number - : x.length); // string + return typeof x !== "string" + && (x = 10) // change x - number| string + && (typeof x === "number" + ? x // number + : x.length); // string } diff --git a/tests/baselines/reference/typeGuardsInRightOperandOfOrOrOperator.js b/tests/baselines/reference/typeGuardsInRightOperandOfOrOrOperator.js index 5f5880a494..188d226da1 100644 --- a/tests/baselines/reference/typeGuardsInRightOperandOfOrOrOperator.js +++ b/tests/baselines/reference/typeGuardsInRightOperandOfOrOrOperator.js @@ -72,36 +72,40 @@ function foo3(x) { } function foo4(x) { return typeof x === "string" // string | number | boolean - || typeof x === "number" // number | boolean - || x; // boolean + || typeof x === "number" // number | boolean + || x; // boolean } function foo5(x) { // usage of x or assignment to separate variable shouldn't cause narrowing of type to stop var b; return typeof x === "string" // string | number | boolean - || ((b = x) || (typeof x === "number" // number | boolean - || x)); // boolean + || ((b = x) || (typeof x === "number" // number | boolean + || x)); // boolean } function foo6(x) { // Mixing typeguard return typeof x === "string" // string | number | boolean - || (typeof x !== "number" // number | boolean - ? x // boolean - : x === 10); // number + || (typeof x !== "number" // number | boolean + ? x // boolean + : x === 10); // number } function foo7(x) { var y; var z; // Mixing typeguard narrowing // Assigning value to x deep inside another guard stops narrowing of type too - return typeof x === "string" || ((z = x) // string | number | boolean - x changed deeper in conditional expression - || (typeof x === "number" ? (x = 10 && x.toString()) // number | boolean | string - : (y = x && x.toString()))); // number | boolean | string + return typeof x === "string" + || ((z = x) // string | number | boolean - x changed deeper in conditional expression + || (typeof x === "number" + ? (x = 10 && x.toString()) // number | boolean | string + : (y = x && x.toString()))); // number | boolean | string } function foo8(x) { // Mixing typeguard // Assigning value to x in outer guard shouldn't stop narrowing in the inner expression - return typeof x === "string" || (x = 10) // change x - number| string - || (typeof x === "number" ? x // number - : x.length); // string + return typeof x === "string" + || (x = 10) // change x - number| string + || (typeof x === "number" + ? x // number + : x.length); // string } diff --git a/tests/baselines/reference/typeGuardsWithAny.js b/tests/baselines/reference/typeGuardsWithAny.js index 08aed91edd..be3d64b806 100644 --- a/tests/baselines/reference/typeGuardsWithAny.js +++ b/tests/baselines/reference/typeGuardsWithAny.js @@ -38,9 +38,7 @@ else { //// [typeGuardsWithAny.js] -var x = { - p: 0 -}; +var x = { p: 0 }; if (x instanceof Object) { x.p; // No error, type any unaffected by instanceof type guard } diff --git a/tests/baselines/reference/typeIdentityConsidersBrands.js b/tests/baselines/reference/typeIdentityConsidersBrands.js index 002364a2e0..2398033c2c 100644 --- a/tests/baselines/reference/typeIdentityConsidersBrands.js +++ b/tests/baselines/reference/typeIdentityConsidersBrands.js @@ -53,15 +53,13 @@ var Y_1 = (function () { } return Y_1; })(); -function foo(arg) { -} +function foo(arg) { } var a = new Y(); var b = new X(); a = b; // ok foo(a); // ok var a2 = new Y_1(); var b2 = new X_1(); -function foo2(arg) { -} +function foo2(arg) { } a2 = b2; // should error foo2(a2); // should error diff --git a/tests/baselines/reference/typeInfer1.js b/tests/baselines/reference/typeInfer1.js index bab1ebf930..f961329883 100644 --- a/tests/baselines/reference/typeInfer1.js +++ b/tests/baselines/reference/typeInfer1.js @@ -15,13 +15,9 @@ var yyyyyyyy: ITextWriter2 = { //// [typeInfer1.js] var x = { - Write: function (s) { - }, - WriteLine: function (s) { - } + Write: function (s) { }, + WriteLine: function (s) { } }; var yyyyyyyy = { - Moo: function () { - return "cow"; - } + Moo: function () { return "cow"; } }; diff --git a/tests/baselines/reference/typeInferenceConflictingCandidates.js b/tests/baselines/reference/typeInferenceConflictingCandidates.js index ea7834a076..2033c3b6b2 100644 --- a/tests/baselines/reference/typeInferenceConflictingCandidates.js +++ b/tests/baselines/reference/typeInferenceConflictingCandidates.js @@ -4,6 +4,4 @@ declare function g(a: T, b: T, c: (t: T) => T): T; g("", 3, a => a); //// [typeInferenceConflictingCandidates.js] -g("", 3, function (a) { - return a; -}); +g("", 3, function (a) { return a; }); diff --git a/tests/baselines/reference/typeInferenceFixEarly.js b/tests/baselines/reference/typeInferenceFixEarly.js index 820f381e7a..58b8824c8b 100644 --- a/tests/baselines/reference/typeInferenceFixEarly.js +++ b/tests/baselines/reference/typeInferenceFixEarly.js @@ -4,6 +4,4 @@ declare function f(p: (t: T) => T): T; f(n => 3); //// [typeInferenceFixEarly.js] -f(function (n) { - return 3; -}); +f(function (n) { return 3; }); diff --git a/tests/baselines/reference/typeInferenceWithTupleType.js b/tests/baselines/reference/typeInferenceWithTupleType.js index bc504b30b3..10a18274c7 100644 --- a/tests/baselines/reference/typeInferenceWithTupleType.js +++ b/tests/baselines/reference/typeInferenceWithTupleType.js @@ -27,39 +27,22 @@ var zipResultEleEle = zipResult[0][0]; // string //// [typeInferenceWithTupleType.js] function combine(x, y) { - return [ - x, - y - ]; + return [x, y]; } var combineResult = combine("string", 10); var combineEle1 = combineResult[0]; // string var combineEle2 = combineResult[1]; // number function zip(array1, array2) { if (array1.length != array2.length) { - return [ - [ - undefined, - undefined - ] - ]; + return [[undefined, undefined]]; } var length = array1.length; var zipResult; for (var i = 0; i < length; ++i) { - zipResult.push([ - array1[i], - array2[i] - ]); + zipResult.push([array1[i], array2[i]]); } return zipResult; } -var zipResult = zip([ - "foo", - "bar" -], [ - 5, - 6 -]); +var zipResult = zip(["foo", "bar"], [5, 6]); var zipResultEle = zipResult[0]; // [string, number] var zipResultEleEle = zipResult[0][0]; // string diff --git a/tests/baselines/reference/typeInferenceWithTypeAnnotation.js b/tests/baselines/reference/typeInferenceWithTypeAnnotation.js index 164be34cd2..119773f6e3 100644 --- a/tests/baselines/reference/typeInferenceWithTypeAnnotation.js +++ b/tests/baselines/reference/typeInferenceWithTypeAnnotation.js @@ -4,6 +4,4 @@ declare function f(p: (t: T) => T): T; f((n: number) => n); //// [typeInferenceWithTypeAnnotation.js] -f(function (n) { - return n; -}); +f(function (n) { return n; }); diff --git a/tests/baselines/reference/typeLiteralCallback.js b/tests/baselines/reference/typeLiteralCallback.js index 8f94058191..82c8b37e45 100644 --- a/tests/baselines/reference/typeLiteralCallback.js +++ b/tests/baselines/reference/typeLiteralCallback.js @@ -17,9 +17,5 @@ test.fail2(arg => foo.reject(arg)); // Should be OK. Was: Error: Supplied para //// [typeLiteralCallback.js] var foo; var test; -test.fail(function (arg) { - return foo.reject(arg); -}); -test.fail2(function (arg) { - return foo.reject(arg); -}); // Should be OK. Was: Error: Supplied parameters do not match any signature of call target +test.fail(function (arg) { return foo.reject(arg); }); +test.fail2(function (arg) { return foo.reject(arg); }); // Should be OK. Was: Error: Supplied parameters do not match any signature of call target diff --git a/tests/baselines/reference/typeMatch2.js b/tests/baselines/reference/typeMatch2.js index c59bfad8b1..1fd624e4e5 100644 --- a/tests/baselines/reference/typeMatch2.js +++ b/tests/baselines/reference/typeMatch2.js @@ -52,23 +52,11 @@ var __extends = this.__extends || function (d, b) { d.prototype = new __(); }; function f1() { - var a = { - x: 1, - y: 2 - }; + var a = { x: 1, y: 2 }; a = {}; // error - a = { - x: 1 - }; // error - a = { - x: 1, - y: 2, - z: 3 - }; - a = { - x: 1, - z: 3 - }; // error + a = { x: 1 }; // error + a = { x: 1, y: 2, z: 3 }; + a = { x: 1, z: 3 }; // error } var Animal = (function () { function Animal() { @@ -85,26 +73,12 @@ var Giraffe = (function (_super) { function f2() { var a = new Animal(); var g = new Giraffe(); - var aa = [ - a, - a, - a - ]; - var gg = [ - g, - g, - g - ]; + var aa = [a, a, a]; + var gg = [g, g, g]; aa = gg; gg = aa; // error - var xa = { - f1: 5, - f2: aa - }; - var xb = { - f1: 5, - f2: gg - }; + var xa = { f1: 5, f2: aa }; + var xb = { f1: 5, f2: gg }; xa = xb; // Should be ok xb = xa; // Not ok } @@ -113,36 +87,14 @@ function f4() { var i = 5; i = null; i = undefined; - var a = { - x: 1, - y: 1 - }; - a = { - x: 1, - y: null - }; - a = { - x: 1, - y: undefined - }; - a = { - x: 1, - y: _any - }; - a = { - x: 1, - y: _any, - z: 1 - }; - a = { - x: 1 - }; // error - var mf = function m(n) { - return false; - }; - var zf = function z(n) { - return true; - }; + var a = { x: 1, y: 1 }; + a = { x: 1, y: null }; + a = { x: 1, y: undefined }; + a = { x: 1, y: _any }; + a = { x: 1, y: _any, z: 1 }; + a = { x: 1 }; // error + var mf = function m(n) { return false; }; + var zf = function z(n) { return true; }; mf = zf; mf(_any); zf(_any); diff --git a/tests/baselines/reference/typeOfOnTypeArg.js b/tests/baselines/reference/typeOfOnTypeArg.js index ff304c0569..199233065b 100644 --- a/tests/baselines/reference/typeOfOnTypeArg.js +++ b/tests/baselines/reference/typeOfOnTypeArg.js @@ -9,9 +9,7 @@ fill(32); //// [typeOfOnTypeArg.js] -var A = { - '': 3 -}; +var A = { '': 3 }; function fill(f) { } fill(32); diff --git a/tests/baselines/reference/typeOfThisInInstanceMember.js b/tests/baselines/reference/typeOfThisInInstanceMember.js index 7d88d98cf7..5e4b4f2970 100644 --- a/tests/baselines/reference/typeOfThisInInstanceMember.js +++ b/tests/baselines/reference/typeOfThisInInstanceMember.js @@ -59,11 +59,7 @@ var r = c.x; var ra = c.x.x.x; var r2 = c.y; var r3 = c.foo(); -var rs = [ - r, - r2, - r3 -]; +var rs = [r, r2, r3]; rs.forEach(function (x) { x.foo; x.x; diff --git a/tests/baselines/reference/typeOfThisInInstanceMember2.js b/tests/baselines/reference/typeOfThisInInstanceMember2.js index e094e232ec..b2b81ce3a2 100644 --- a/tests/baselines/reference/typeOfThisInInstanceMember2.js +++ b/tests/baselines/reference/typeOfThisInInstanceMember2.js @@ -64,11 +64,7 @@ var ra = c.x.x.x; var r2 = c.y; var r3 = c.foo(); var r4 = c.z; -var rs = [ - r, - r2, - r3 -]; +var rs = [r, r2, r3]; rs.forEach(function (x) { x.foo; x.x; diff --git a/tests/baselines/reference/typeParameterAsElementType.js b/tests/baselines/reference/typeParameterAsElementType.js index ce4364e740..a934f3d033 100644 --- a/tests/baselines/reference/typeParameterAsElementType.js +++ b/tests/baselines/reference/typeParameterAsElementType.js @@ -7,8 +7,5 @@ function fee() { //// [typeParameterAsElementType.js] function fee() { var t; - var arr = [ - t, - "" - ]; + var arr = [t, ""]; } diff --git a/tests/baselines/reference/typeParameterAsTypeParameterConstraint.js b/tests/baselines/reference/typeParameterAsTypeParameterConstraint.js index f432358a1c..9266f52086 100644 --- a/tests/baselines/reference/typeParameterAsTypeParameterConstraint.js +++ b/tests/baselines/reference/typeParameterAsTypeParameterConstraint.js @@ -29,32 +29,16 @@ foo2(1, ['']); //// [typeParameterAsTypeParameterConstraint.js] // using a type parameter as a constraint for a type parameter is valid // no errors expected except illegal constraints -function foo(x, y) { - return y; -} +function foo(x, y) { return y; } var r = foo(1, 2); var r = foo({}, 1); var a; var b; var r2 = foo(a, b); -var r3 = foo({ - x: 1 -}, { - x: 2, - y: 3 -}); -function foo2(x, y) { - return y; -} +var r3 = foo({ x: 1 }, { x: 2, y: 3 }); +function foo2(x, y) { return y; } foo2(1, ''); -foo2({}, { - length: 2 -}); -foo2(1, { - width: 3, - length: 2 -}); +foo2({}, { length: 2 }); +foo2(1, { width: 3, length: 2 }); foo2(1, []); -foo2(1, [ - '' -]); +foo2(1, ['']); diff --git a/tests/baselines/reference/typeParameterAsTypeParameterConstraint2.js b/tests/baselines/reference/typeParameterAsTypeParameterConstraint2.js index a3f4d8d525..e8066b9ebf 100644 --- a/tests/baselines/reference/typeParameterAsTypeParameterConstraint2.js +++ b/tests/baselines/reference/typeParameterAsTypeParameterConstraint2.js @@ -21,22 +21,12 @@ foo2([], ['']); //// [typeParameterAsTypeParameterConstraint2.js] // using a type parameter as a constraint for a type parameter is invalid // these should be errors unless otherwise noted -function foo(x, y) { - return y; -} // this is now an error +function foo(x, y) { return y; } // this is now an error foo(1, ''); foo(1, {}); var n; var r3 = foo(1, n); -function foo2(x, y) { - return y; -} // this is now an error -foo2(1, { - length: '' -}); -foo2(1, { - length: {} -}); -foo2([], [ - '' -]); +function foo2(x, y) { return y; } // this is now an error +foo2(1, { length: '' }); +foo2(1, { length: {} }); +foo2([], ['']); diff --git a/tests/baselines/reference/typeParameterAsTypeParameterConstraintTransitively.js b/tests/baselines/reference/typeParameterAsTypeParameterConstraintTransitively.js index 669139058e..bc50363036 100644 --- a/tests/baselines/reference/typeParameterAsTypeParameterConstraintTransitively.js +++ b/tests/baselines/reference/typeParameterAsTypeParameterConstraintTransitively.js @@ -30,39 +30,15 @@ foo(b, b, { foo: 1, bar: '', hm: '' }); var a; var b; var c; -function foo(x, y, z) { - return z; -} +function foo(x, y, z) { return z; } //function foo(x: T, y: U, z: V): V { return z; } foo(1, 2, 3); -foo({ - x: 1 -}, { - x: 1, - y: '' -}, { - x: 2, - y: '', - z: true -}); +foo({ x: 1 }, { x: 1, y: '' }, { x: 2, y: '', z: true }); foo(a, b, c); -foo(a, b, { - foo: 1, - bar: '', - hm: true -}); -foo(function (x, y) { -}, function (x) { -}, function () { -}); -function foo2(x, y, z) { - return z; -} +foo(a, b, { foo: 1, bar: '', hm: true }); +foo(function (x, y) { }, function (x) { }, function () { }); +function foo2(x, y, z) { return z; } //function foo2(x: T, y: U, z: V): V { return z; } foo(a, a, a); foo(a, b, c); -foo(b, b, { - foo: 1, - bar: '', - hm: '' -}); +foo(b, b, { foo: 1, bar: '', hm: '' }); diff --git a/tests/baselines/reference/typeParameterAsTypeParameterConstraintTransitively2.js b/tests/baselines/reference/typeParameterAsTypeParameterConstraintTransitively2.js index 32bad4dc3c..6541cfaa23 100644 --- a/tests/baselines/reference/typeParameterAsTypeParameterConstraintTransitively2.js +++ b/tests/baselines/reference/typeParameterAsTypeParameterConstraintTransitively2.js @@ -29,34 +29,14 @@ foo(c, c, a); var a; var b; var c; -function foo(x, y, z) { - return z; -} +function foo(x, y, z) { return z; } //function foo(x: T, y: U, z: V): V { return z; } foo(1, 2, ''); -foo({ - x: 1 -}, { - x: 1, - y: '' -}, { - x: 2, - y: 2, - z: true -}); +foo({ x: 1 }, { x: 1, y: '' }, { x: 2, y: 2, z: true }); foo(a, b, a); -foo(a, { - foo: 1, - bar: '', - hm: true -}, b); -foo(function (x, y) { -}, function (x, y) { -}, function () { -}); -function foo2(x, y, z) { - return z; -} +foo(a, { foo: 1, bar: '', hm: true }, b); +foo(function (x, y) { }, function (x, y) { }, function () { }); +function foo2(x, y, z) { return z; } //function foo2(x: T, y: U, z: V): V { return z; } foo(b, a, c); foo(c, c, a); diff --git a/tests/baselines/reference/typeParameterCompatibilityAccrossDeclarations.js b/tests/baselines/reference/typeParameterCompatibilityAccrossDeclarations.js index 04fb7b1dc2..7e92394138 100644 --- a/tests/baselines/reference/typeParameterCompatibilityAccrossDeclarations.js +++ b/tests/baselines/reference/typeParameterCompatibilityAccrossDeclarations.js @@ -25,14 +25,10 @@ i2 = a2; // no error //// [typeParameterCompatibilityAccrossDeclarations.js] define(["require", "exports"], function (require, exports) { var a = { - x: function (y) { - return null; - } + x: function (y) { return null; } }; var a2 = { - x: function (y) { - return null; - } + x: function (y) { return null; } }; var i; var i2; diff --git a/tests/baselines/reference/typeParameterConstraints1.js b/tests/baselines/reference/typeParameterConstraints1.js index 49d347f576..6ffefbcf8f 100644 --- a/tests/baselines/reference/typeParameterConstraints1.js +++ b/tests/baselines/reference/typeParameterConstraints1.js @@ -14,29 +14,16 @@ function foo12(test: T) { } function foo13(test: T) { } //// [typeParameterConstraints1.js] -function foo1(test) { -} -function foo2(test) { -} -function foo3(test) { -} -function foo4(test) { -} // valid -function foo5(test) { -} // valid -function foo6(test) { -} -function foo7(test) { -} // valid -function foo8(test) { -} -function foo9(test) { -} -function foo10(test) { -} -function foo11(test) { -} -function foo12(test) { -} -function foo13(test) { -} +function foo1(test) { } +function foo2(test) { } +function foo3(test) { } +function foo4(test) { } // valid +function foo5(test) { } // valid +function foo6(test) { } +function foo7(test) { } // valid +function foo8(test) { } +function foo9(test) { } +function foo10(test) { } +function foo11(test) { } +function foo12(test) { } +function foo13(test) { } diff --git a/tests/baselines/reference/typeParameterDirectlyConstrainedToItself.js b/tests/baselines/reference/typeParameterDirectlyConstrainedToItself.js index 85f86f7de7..a14e010515 100644 --- a/tests/baselines/reference/typeParameterDirectlyConstrainedToItself.js +++ b/tests/baselines/reference/typeParameterDirectlyConstrainedToItself.js @@ -30,12 +30,8 @@ var C2 = (function () { } return C2; })(); -function f() { -} -function f2() { -} +function f() { } +function f2() { } var a; -var b = function () { -}; -var b2 = function () { -}; +var b = function () { }; +var b2 = function () { }; diff --git a/tests/baselines/reference/typeParameterFixingWithConstraints.js b/tests/baselines/reference/typeParameterFixingWithConstraints.js index 49b2c48fbe..7eeee2b387 100644 --- a/tests/baselines/reference/typeParameterFixingWithConstraints.js +++ b/tests/baselines/reference/typeParameterFixingWithConstraints.js @@ -12,10 +12,4 @@ foo.foo({ bar: null }, bar => null, bar => null); //// [typeParameterFixingWithConstraints.js] var foo; -foo.foo({ - bar: null -}, function (bar) { - return null; -}, function (bar) { - return null; -}); +foo.foo({ bar: null }, function (bar) { return null; }, function (bar) { return null; }); diff --git a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments.js b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments.js index 170bd711b6..0ac79625e1 100644 --- a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments.js +++ b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments.js @@ -10,19 +10,8 @@ var d2 = f(b, x => x.a, null); // type [B, A] var d3 = f(b, x => x.b, null); // type [B, any] //// [typeParameterFixingWithContextSensitiveArguments.js] -function f(y, f, x) { - return [ - y, - f(x) - ]; -} +function f(y, f, x) { return [y, f(x)]; } var a, b; -var d = f(b, function (x) { - return x.a; -}, a); // type [A, A] -var d2 = f(b, function (x) { - return x.a; -}, null); // type [B, A] -var d3 = f(b, function (x) { - return x.b; -}, null); // type [B, any] +var d = f(b, function (x) { return x.a; }, a); // type [A, A] +var d2 = f(b, function (x) { return x.a; }, null); // type [B, A] +var d3 = f(b, function (x) { return x.b; }, null); // type [B, any] diff --git a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments2.js b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments2.js index 1b97f04953..25b22fde8b 100644 --- a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments2.js +++ b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments2.js @@ -8,15 +8,6 @@ var a: A, b: B; var d = f(a, b, x => x, x => x); // A => A not assignable to A => B //// [typeParameterFixingWithContextSensitiveArguments2.js] -function f(y, y1, p, p1) { - return [ - y, - p1(y) - ]; -} +function f(y, y1, p, p1) { return [y, p1(y)]; } var a, b; -var d = f(a, b, function (x) { - return x; -}, function (x) { - return x; -}); // A => A not assignable to A => B +var d = f(a, b, function (x) { return x; }, function (x) { return x; }); // A => A not assignable to A => B diff --git a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments3.js b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments3.js index 4b5370cfc1..665ee9d131 100644 --- a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments3.js +++ b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments3.js @@ -8,15 +8,6 @@ var a: A, b: B; var d = f(a, b, u2 => u2.b, t2 => t2); //// [typeParameterFixingWithContextSensitiveArguments3.js] -function f(t1, u1, pf1, pf2) { - return [ - t1, - pf2(t1) - ]; -} +function f(t1, u1, pf1, pf2) { return [t1, pf2(t1)]; } var a, b; -var d = f(a, b, function (u2) { - return u2.b; -}, function (t2) { - return t2; -}); +var d = f(a, b, function (u2) { return u2.b; }, function (t2) { return t2; }); diff --git a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments4.js b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments4.js index 7efab1f62c..65adc2f288 100644 --- a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments4.js +++ b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments4.js @@ -8,15 +8,6 @@ var a: A, b: B; var d = f(a, b, x => x, x => x); // Type [A, B] //// [typeParameterFixingWithContextSensitiveArguments4.js] -function f(y, y1, p, p1) { - return [ - y, - p1(y) - ]; -} +function f(y, y1, p, p1) { return [y, p1(y)]; } var a, b; -var d = f(a, b, function (x) { - return x; -}, function (x) { - return x; -}); // Type [A, B] +var d = f(a, b, function (x) { return x; }, function (x) { return x; }); // Type [A, B] diff --git a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments5.js b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments5.js index 7ab2502e02..391a98d75a 100644 --- a/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments5.js +++ b/tests/baselines/reference/typeParameterFixingWithContextSensitiveArguments5.js @@ -8,15 +8,6 @@ var a: A, b: B; var d = f(a, b, u2 => u2.b, t2 => t2); //// [typeParameterFixingWithContextSensitiveArguments5.js] -function f(t1, u1, pf1, pf2) { - return [ - t1, - pf2(t1) - ]; -} +function f(t1, u1, pf1, pf2) { return [t1, pf2(t1)]; } var a, b; -var d = f(a, b, function (u2) { - return u2.b; -}, function (t2) { - return t2; -}); +var d = f(a, b, function (u2) { return u2.b; }, function (t2) { return t2; }); diff --git a/tests/baselines/reference/typeParameterIndirectlyConstrainedToItself.js b/tests/baselines/reference/typeParameterIndirectlyConstrainedToItself.js index fc0e10d41c..3cdb735adf 100644 --- a/tests/baselines/reference/typeParameterIndirectlyConstrainedToItself.js +++ b/tests/baselines/reference/typeParameterIndirectlyConstrainedToItself.js @@ -29,15 +29,11 @@ var C2 = (function () { } return C2; })(); -function f() { -} -function f2() { -} +function f() { } +function f2() { } var a; -var b = function () { -}; -var b2 = function () { -}; +var b = function () { }; +var b2 = function () { }; var D = (function () { function D() { } diff --git a/tests/baselines/reference/typeParameterOrderReversal.js b/tests/baselines/reference/typeParameterOrderReversal.js index 8c9185ba57..40df6db003 100644 --- a/tests/baselines/reference/typeParameterOrderReversal.js +++ b/tests/baselines/reference/typeParameterOrderReversal.js @@ -15,10 +15,8 @@ tFirst(z); //// [typeParameterOrderReversal.js] // Only difference here is order of type parameters -function uFirst(x) { -} -function tFirst(x) { -} +function uFirst(x) { } +function tFirst(x) { } var z = null; // Both of these should be allowed uFirst(z); diff --git a/tests/baselines/reference/typeParameterUsedAsConstraint.js b/tests/baselines/reference/typeParameterUsedAsConstraint.js index 4649a53f8f..b1c55343aa 100644 --- a/tests/baselines/reference/typeParameterUsedAsConstraint.js +++ b/tests/baselines/reference/typeParameterUsedAsConstraint.js @@ -66,30 +66,18 @@ var C6 = (function () { } return C6; })(); -function f() { -} -function f2() { -} -function f3() { -} -function f4() { -} -function f5() { -} -function f6() { -} -var e = function () { -}; -var e2 = function () { -}; -var e3 = function () { -}; -var e4 = function () { -}; -var e5 = function () { -}; -var e6 = function () { -}; +function f() { } +function f2() { } +function f3() { } +function f4() { } +function f5() { } +function f6() { } +var e = function () { }; +var e2 = function () { }; +var e3 = function () { }; +var e4 = function () { }; +var e5 = function () { }; +var e6 = function () { }; var a; var a2; var a3; diff --git a/tests/baselines/reference/typeParametersAreIdenticalToThemselves.js b/tests/baselines/reference/typeParametersAreIdenticalToThemselves.js index a2f8aa2f9b..c6c624f7e2 100644 --- a/tests/baselines/reference/typeParametersAreIdenticalToThemselves.js +++ b/tests/baselines/reference/typeParametersAreIdenticalToThemselves.js @@ -78,37 +78,26 @@ interface I2 { //// [typeParametersAreIdenticalToThemselves.js] // type parameters from the same declaration are identical to themself -function foo1(x) { -} -function foo2(x) { -} +function foo1(x) { } +function foo2(x) { } function foo3(x, y) { - function inner(x) { - } - function inner2(x) { - } + function inner(x) { } + function inner2(x) { } } var C = (function () { function C() { } - C.prototype.foo1 = function (x) { - }; - C.prototype.foo2 = function (a, x) { - }; - C.prototype.foo3 = function (x) { - }; - C.prototype.foo4 = function (x) { - }; + C.prototype.foo1 = function (x) { }; + C.prototype.foo2 = function (a, x) { }; + C.prototype.foo3 = function (x) { }; + C.prototype.foo4 = function (x) { }; return C; })(); var C2 = (function () { function C2() { } - C2.prototype.foo1 = function (x) { - }; - C2.prototype.foo2 = function (a, x) { - }; - C2.prototype.foo3 = function (x) { - }; + C2.prototype.foo1 = function (x) { }; + C2.prototype.foo2 = function (a, x) { }; + C2.prototype.foo3 = function (x) { }; return C2; })(); diff --git a/tests/baselines/reference/typeParametersInStaticAccessors.js b/tests/baselines/reference/typeParametersInStaticAccessors.js index 411a4eac69..c621de910b 100644 --- a/tests/baselines/reference/typeParametersInStaticAccessors.js +++ b/tests/baselines/reference/typeParametersInStaticAccessors.js @@ -9,15 +9,12 @@ var foo = (function () { function foo() { } Object.defineProperty(foo, "Foo", { - get: function () { - return null; - }, + get: function () { return null; }, enumerable: true, configurable: true }); Object.defineProperty(foo, "Bar", { - set: function (v) { - }, + set: function (v) { }, enumerable: true, configurable: true }); diff --git a/tests/baselines/reference/typeQueryOnClass.js b/tests/baselines/reference/typeQueryOnClass.js index a3ae0bd02c..1c8b2424a7 100644 --- a/tests/baselines/reference/typeQueryOnClass.js +++ b/tests/baselines/reference/typeQueryOnClass.js @@ -62,14 +62,10 @@ var C = (function () { var _this = this; this.x = x; this.ia = 1; - this.ib = function () { - return _this.ia; - }; + this.ib = function () { return _this.ia; }; } - C.foo = function (x) { - }; - C.bar = function (x) { - }; + C.foo = function (x) { }; + C.bar = function (x) { }; Object.defineProperty(C, "sc", { get: function () { return 1; @@ -86,9 +82,7 @@ var C = (function () { enumerable: true, configurable: true }); - C.prototype.baz = function (x) { - return ''; - }; + C.prototype.baz = function (x) { return ''; }; Object.defineProperty(C.prototype, "ic", { get: function () { return 1; @@ -106,9 +100,7 @@ var C = (function () { configurable: true }); C.sa = 1; - C.sb = function () { - return 1; - }; + C.sb = function () { return 1; }; return C; })(); var c; @@ -119,8 +111,7 @@ var D = (function () { function D(y) { this.y = y; } - D.prototype.foo = function () { - }; + D.prototype.foo = function () { }; return D; })(); var d; diff --git a/tests/baselines/reference/typeResolution.js b/tests/baselines/reference/typeResolution.js index 74102f5a0f..55a6beeceb 100644 --- a/tests/baselines/reference/typeResolution.js +++ b/tests/baselines/reference/typeResolution.js @@ -224,24 +224,21 @@ define(["require", "exports"], function (require, exports) { var ClassA = (function () { function ClassA() { } - ClassA.prototype.AisIn1_2_2 = function () { - }; + ClassA.prototype.AisIn1_2_2 = function () { }; return ClassA; })(); SubSubModule2.ClassA = ClassA; var ClassB = (function () { function ClassB() { } - ClassB.prototype.BisIn1_2_2 = function () { - }; + ClassB.prototype.BisIn1_2_2 = function () { }; return ClassB; })(); SubSubModule2.ClassB = ClassB; var ClassC = (function () { function ClassC() { } - ClassC.prototype.CisIn1_2_2 = function () { - }; + ClassC.prototype.CisIn1_2_2 = function () { }; return ClassC; })(); SubSubModule2.ClassC = ClassC; @@ -250,8 +247,7 @@ define(["require", "exports"], function (require, exports) { var ClassA = (function () { function ClassA() { } - ClassA.prototype.AisIn1 = function () { - }; + ClassA.prototype.AisIn1 = function () { }; return ClassA; })(); var NotExportedModule; @@ -271,8 +267,7 @@ define(["require", "exports"], function (require, exports) { var ClassA = (function () { function ClassA() { } - ClassA.prototype.AisIn2_3 = function () { - }; + ClassA.prototype.AisIn2_3 = function () { }; return ClassA; })(); SubModule3.ClassA = ClassA; diff --git a/tests/baselines/reference/typeResolution.js.map b/tests/baselines/reference/typeResolution.js.map index b4aa704053..8bbff8aa76 100644 --- a/tests/baselines/reference/typeResolution.js.map +++ b/tests/baselines/reference/typeResolution.js.map @@ -1,2 +1,2 @@ //// [typeResolution.js.map] -{"version":3,"file":"typeResolution.js","sourceRoot":"","sources":["typeResolution.ts"],"names":["TopLevelModule1","TopLevelModule1.SubModule1","TopLevelModule1.SubModule1.SubSubModule1","TopLevelModule1.SubModule1.SubSubModule1.ClassA","TopLevelModule1.SubModule1.SubSubModule1.ClassA.constructor","TopLevelModule1.SubModule1.SubSubModule1.ClassA.AisIn1_1_1","TopLevelModule1.SubModule1.SubSubModule1.ClassB","TopLevelModule1.SubModule1.SubSubModule1.ClassB.constructor","TopLevelModule1.SubModule1.SubSubModule1.ClassB.BisIn1_1_1","TopLevelModule1.SubModule1.SubSubModule1.NonExportedClassQ","TopLevelModule1.SubModule1.SubSubModule1.NonExportedClassQ.constructor","TopLevelModule1.SubModule1.SubSubModule1.NonExportedClassQ.constructor.QQ","TopLevelModule1.SubModule1.ClassA","TopLevelModule1.SubModule1.ClassA.constructor","TopLevelModule1.SubModule1.ClassA.constructor.AA","TopLevelModule1.SubModule2","TopLevelModule1.SubModule2.SubSubModule2","TopLevelModule1.SubModule2.SubSubModule2.ClassA","TopLevelModule1.SubModule2.SubSubModule2.ClassA.constructor","TopLevelModule1.SubModule2.SubSubModule2.ClassA.AisIn1_2_2","TopLevelModule1.SubModule2.SubSubModule2.ClassB","TopLevelModule1.SubModule2.SubSubModule2.ClassB.constructor","TopLevelModule1.SubModule2.SubSubModule2.ClassB.BisIn1_2_2","TopLevelModule1.SubModule2.SubSubModule2.ClassC","TopLevelModule1.SubModule2.SubSubModule2.ClassC.constructor","TopLevelModule1.SubModule2.SubSubModule2.ClassC.CisIn1_2_2","TopLevelModule1.ClassA","TopLevelModule1.ClassA.constructor","TopLevelModule1.ClassA.AisIn1","TopLevelModule1.NotExportedModule","TopLevelModule1.NotExportedModule.ClassA","TopLevelModule1.NotExportedModule.ClassA.constructor","TopLevelModule2","TopLevelModule2.SubModule3","TopLevelModule2.SubModule3.ClassA","TopLevelModule2.SubModule3.ClassA.constructor","TopLevelModule2.SubModule3.ClassA.AisIn2_3"],"mappings":";IAAA,IAAc,eAAe,CAmG5B;IAnGD,WAAc,eAAe,EAAC,CAAC;QAC3BA,IAAcA,UAAUA,CAwEvBA;QAxEDA,WAAcA,UAAUA,EAACA,CAACA;YACtBC,IAAcA,aAAaA,CAwD1BA;YAxDDA,WAAcA,aAAaA,EAACA,CAACA;gBACzBC;oBAAAC;oBAmBAC,CAACA;oBAlBUD,2BAAUA,GAAjBA;wBAEIE,AADAA,uCAAuCA;4BACnCA,EAAUA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAChCA,IAAIA,EAAwBA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAC9CA,IAAIA,EAAmCA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACzDA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,yCAAyCA;4BACrCA,EAAUA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAChCA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,qCAAqCA;4BACjCA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,sBAAsBA;4BAClBA,EAAcA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACpCA,IAAIA,EAA4BA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;oBACtDA,CAACA;oBACLF,aAACA;gBAADA,CAACA,AAnBDD,IAmBCA;gBAnBYA,oBAAMA,SAmBlBA,CAAAA;gBACDA;oBAAAI;oBAsBAC,CAACA;oBArBUD,2BAAUA,GAAjBA;wBACIE,+CAA+CA;wBAG/CA,AADAA,uCAAuCA;4BACnCA,EAAUA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAChCA,IAAIA,EAAwBA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAC9CA,IAAIA,EAAmCA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACzDA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,yCAAyCA;4BACrCA,EAAUA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAChCA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,qCAAqCA;4BACjCA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACzEA,IAAIA,EAAqCA,CAACA;wBAACA,EAAEA,CAACA,QAAQA,EAAEA,CAACA;wBAGzDA,AADAA,sBAAsBA;4BAClBA,EAAcA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACpCA,IAAIA,EAA4BA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;oBACtDA,CAACA;oBACLF,aAACA;gBAADA,CAACA,AAtBDJ,IAsBCA;gBAtBYA,oBAAMA,SAsBlBA,CAAAA;gBAEDA;oBACIO;wBACIC;4BAEIC,AADAA,uCAAuCA;gCACnCA,EAAmDA,CAACA;4BAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;4BACzEA,IAAIA,EAAmDA,CAACA;4BAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;4BACzEA,IAAIA,EAAcA,CAACA;4BAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;4BACpCA,IAAIA,EAAqCA,CAACA;4BAACA,EAAEA,CAACA,QAAQA,EAAEA,CAACA;wBAC7DA,CAACA;oBACLD,CAACA;oBACLD,wBAACA;gBAADA,CAACA,AAVDP,IAUCA;YACLA,CAACA,EAxDaD,aAAaA,GAAbA,wBAAaA,KAAbA,wBAAaA,QAwD1BA;YAGDA,AADAA,0EAA0EA;;gBAEtEW;oBACIC;wBACIC,IAAIA,EAAwBA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAC9CA,IAAIA,EAAmCA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACzDA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,sBAAsBA;4BAClBA,EAA4BA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;oBACtDA,CAACA;gBACLD,CAACA;gBACLD,aAACA;YAADA,CAACA,AAXDX,IAWCA;QACLA,CAACA,EAxEaD,UAAUA,GAAVA,0BAAUA,KAAVA,0BAAUA,QAwEvBA;QAEDA,IAAcA,UAAUA,CAWvBA;QAXDA,WAAcA,UAAUA,EAACA,CAACA;YACtBe,IAAcA,aAAaA,CAO1BA;YAPDA,WAAcA,aAAaA,EAACA,CAACA;gBAEzBC,AADAA,6DAA6DA;;oBAC7DC;oBAA8CC,CAACA;oBAAlBD,2BAAUA,GAAjBA;oBAAsBE,CAACA;oBAACF,aAACA;gBAADA,CAACA,AAA/CD,IAA+CA;gBAAlCA,oBAAMA,SAA4BA,CAAAA;gBAC/CA;oBAAAI;oBAA8CC,CAACA;oBAAlBD,2BAAUA,GAAjBA;oBAAsBE,CAACA;oBAACF,aAACA;gBAADA,CAACA,AAA/CJ,IAA+CA;gBAAlCA,oBAAMA,SAA4BA,CAAAA;gBAC/CA;oBAAAO;oBAA8CC,CAACA;oBAAlBD,2BAAUA,GAAjBA;oBAAsBE,CAACA;oBAACF,aAACA;gBAADA,CAACA,AAA/CP,IAA+CA;gBAAlCA,oBAAMA,SAA4BA,CAAAA;gBAEZA,JACvCA,CAACA,EAPaD,aAAaA,GAAbA,wBAAaA,KAAbA,wBAAaA,QAO1BA;YAE0CA,JAC/CA,CAACA,EAXaf,UAAUA,GAAVA,0BAAUA,KAAVA,0BAAUA,QAWvBA;QAEDA;YAAA0B;YAEAC,CAACA;YADUD,uBAAMA,GAAbA;YAAkBE,CAACA;YACvBF,aAACA;QAADA,CAACA,AAFD1B,IAECA;QAMDA,IAAOA,iBAAiBA,CAEvBA;QAFDA,WAAOA,iBAAiBA,EAACA,CAACA;YACtB6B;gBAAAC;gBAAsBC,CAACA;gBAADD,aAACA;YAADA,CAACA,AAAvBD,IAAuBA;YAAVA,wBAAMA,SAAIA,CAAAA;QAC3BA,CAACA,EAFM7B,iBAAiBA,KAAjBA,iBAAiBA,QAEvBA;IACLA,CAACA,EAnGa,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAmG5B;IAED,IAAO,eAAe,CAMrB;IAND,WAAO,eAAe,EAAC,CAAC;QACpBgC,IAAcA,UAAUA,CAIvBA;QAJDA,WAAcA,UAAUA,EAACA,CAACA;YACtBC;gBAAAC;gBAEAC,CAACA;gBADUD,yBAAQA,GAAfA;gBAAoBE,CAACA;gBACzBF,aAACA;YAADA,CAACA,AAFDD,IAECA;YAFYA,iBAAMA,SAElBA,CAAAA;QACLA,CAACA,EAJaD,UAAUA,GAAVA,0BAAUA,KAAVA,0BAAUA,QAIvBA;IACLA,CAACA,EANM,eAAe,KAAf,eAAe,QAMrB"} \ No newline at end of file +{"version":3,"file":"typeResolution.js","sourceRoot":"","sources":["typeResolution.ts"],"names":["TopLevelModule1","TopLevelModule1.SubModule1","TopLevelModule1.SubModule1.SubSubModule1","TopLevelModule1.SubModule1.SubSubModule1.ClassA","TopLevelModule1.SubModule1.SubSubModule1.ClassA.constructor","TopLevelModule1.SubModule1.SubSubModule1.ClassA.AisIn1_1_1","TopLevelModule1.SubModule1.SubSubModule1.ClassB","TopLevelModule1.SubModule1.SubSubModule1.ClassB.constructor","TopLevelModule1.SubModule1.SubSubModule1.ClassB.BisIn1_1_1","TopLevelModule1.SubModule1.SubSubModule1.NonExportedClassQ","TopLevelModule1.SubModule1.SubSubModule1.NonExportedClassQ.constructor","TopLevelModule1.SubModule1.SubSubModule1.NonExportedClassQ.constructor.QQ","TopLevelModule1.SubModule1.ClassA","TopLevelModule1.SubModule1.ClassA.constructor","TopLevelModule1.SubModule1.ClassA.constructor.AA","TopLevelModule1.SubModule2","TopLevelModule1.SubModule2.SubSubModule2","TopLevelModule1.SubModule2.SubSubModule2.ClassA","TopLevelModule1.SubModule2.SubSubModule2.ClassA.constructor","TopLevelModule1.SubModule2.SubSubModule2.ClassA.AisIn1_2_2","TopLevelModule1.SubModule2.SubSubModule2.ClassB","TopLevelModule1.SubModule2.SubSubModule2.ClassB.constructor","TopLevelModule1.SubModule2.SubSubModule2.ClassB.BisIn1_2_2","TopLevelModule1.SubModule2.SubSubModule2.ClassC","TopLevelModule1.SubModule2.SubSubModule2.ClassC.constructor","TopLevelModule1.SubModule2.SubSubModule2.ClassC.CisIn1_2_2","TopLevelModule1.ClassA","TopLevelModule1.ClassA.constructor","TopLevelModule1.ClassA.AisIn1","TopLevelModule1.NotExportedModule","TopLevelModule1.NotExportedModule.ClassA","TopLevelModule1.NotExportedModule.ClassA.constructor","TopLevelModule2","TopLevelModule2.SubModule3","TopLevelModule2.SubModule3.ClassA","TopLevelModule2.SubModule3.ClassA.constructor","TopLevelModule2.SubModule3.ClassA.AisIn2_3"],"mappings":";IAAA,IAAc,eAAe,CAmG5B;IAnGD,WAAc,eAAe,EAAC,CAAC;QAC3BA,IAAcA,UAAUA,CAwEvBA;QAxEDA,WAAcA,UAAUA,EAACA,CAACA;YACtBC,IAAcA,aAAaA,CAwD1BA;YAxDDA,WAAcA,aAAaA,EAACA,CAACA;gBACzBC;oBAAAC;oBAmBAC,CAACA;oBAlBUD,2BAAUA,GAAjBA;wBAEIE,AADAA,uCAAuCA;4BACnCA,EAAUA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAChCA,IAAIA,EAAwBA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAC9CA,IAAIA,EAAmCA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACzDA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,yCAAyCA;4BACrCA,EAAUA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAChCA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,qCAAqCA;4BACjCA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,sBAAsBA;4BAClBA,EAAcA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACpCA,IAAIA,EAA4BA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;oBACtDA,CAACA;oBACLF,aAACA;gBAADA,CAACA,AAnBDD,IAmBCA;gBAnBYA,oBAAMA,SAmBlBA,CAAAA;gBACDA;oBAAAI;oBAsBAC,CAACA;oBArBUD,2BAAUA,GAAjBA;wBACIE,+CAA+CA;wBAG/CA,AADAA,uCAAuCA;4BACnCA,EAAUA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAChCA,IAAIA,EAAwBA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAC9CA,IAAIA,EAAmCA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACzDA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,yCAAyCA;4BACrCA,EAAUA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAChCA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,qCAAqCA;4BACjCA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACzEA,IAAIA,EAAqCA,CAACA;wBAACA,EAAEA,CAACA,QAAQA,EAAEA,CAACA;wBAGzDA,AADAA,sBAAsBA;4BAClBA,EAAcA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACpCA,IAAIA,EAA4BA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;oBACtDA,CAACA;oBACLF,aAACA;gBAADA,CAACA,AAtBDJ,IAsBCA;gBAtBYA,oBAAMA,SAsBlBA,CAAAA;gBAEDA;oBACIO;wBACIC;4BAEIC,AADAA,uCAAuCA;gCACnCA,EAAmDA,CAACA;4BAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;4BACzEA,IAAIA,EAAmDA,CAACA;4BAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;4BACzEA,IAAIA,EAAcA,CAACA;4BAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;4BACpCA,IAAIA,EAAqCA,CAACA;4BAACA,EAAEA,CAACA,QAAQA,EAAEA,CAACA;wBAC7DA,CAACA;oBACLD,CAACA;oBACLD,wBAACA;gBAADA,CAACA,AAVDP,IAUCA;YACLA,CAACA,EAxDaD,aAAaA,GAAbA,wBAAaA,KAAbA,wBAAaA,QAwD1BA;YAGDA,AADAA,0EAA0EA;;gBAEtEW;oBACIC;wBACIC,IAAIA,EAAwBA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAC9CA,IAAIA,EAAmCA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBACzDA,IAAIA,EAAmDA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;wBAGzEA,AADAA,sBAAsBA;4BAClBA,EAA4BA,CAACA;wBAACA,EAAEA,CAACA,UAAUA,EAAEA,CAACA;oBACtDA,CAACA;gBACLD,CAACA;gBACLD,aAACA;YAADA,CAACA,AAXDX,IAWCA;QACLA,CAACA,EAxEaD,UAAUA,GAAVA,0BAAUA,KAAVA,0BAAUA,QAwEvBA;QAEDA,IAAcA,UAAUA,CAWvBA;QAXDA,WAAcA,UAAUA,EAACA,CAACA;YACtBe,IAAcA,aAAaA,CAO1BA;YAPDA,WAAcA,aAAaA,EAACA,CAACA;gBAEzBC,AADAA,6DAA6DA;;oBAC7DC;oBAA8CC,CAACA;oBAAlBD,2BAAUA,GAAjBA,cAAsBE,CAACA;oBAACF,aAACA;gBAADA,CAACA,AAA/CD,IAA+CA;gBAAlCA,oBAAMA,SAA4BA,CAAAA;gBAC/CA;oBAAAI;oBAA8CC,CAACA;oBAAlBD,2BAAUA,GAAjBA,cAAsBE,CAACA;oBAACF,aAACA;gBAADA,CAACA,AAA/CJ,IAA+CA;gBAAlCA,oBAAMA,SAA4BA,CAAAA;gBAC/CA;oBAAAO;oBAA8CC,CAACA;oBAAlBD,2BAAUA,GAAjBA,cAAsBE,CAACA;oBAACF,aAACA;gBAADA,CAACA,AAA/CP,IAA+CA;gBAAlCA,oBAAMA,SAA4BA,CAAAA;gBAEZA,JACvCA,CAACA,EAPaD,aAAaA,GAAbA,wBAAaA,KAAbA,wBAAaA,QAO1BA;YAE0CA,JAC/CA,CAACA,EAXaf,UAAUA,GAAVA,0BAAUA,KAAVA,0BAAUA,QAWvBA;QAEDA;YAAA0B;YAEAC,CAACA;YADUD,uBAAMA,GAAbA,cAAkBE,CAACA;YACvBF,aAACA;QAADA,CAACA,AAFD1B,IAECA;QAMDA,IAAOA,iBAAiBA,CAEvBA;QAFDA,WAAOA,iBAAiBA,EAACA,CAACA;YACtB6B;gBAAAC;gBAAsBC,CAACA;gBAADD,aAACA;YAADA,CAACA,AAAvBD,IAAuBA;YAAVA,wBAAMA,SAAIA,CAAAA;QAC3BA,CAACA,EAFM7B,iBAAiBA,KAAjBA,iBAAiBA,QAEvBA;IACLA,CAACA,EAnGa,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAmG5B;IAED,IAAO,eAAe,CAMrB;IAND,WAAO,eAAe,EAAC,CAAC;QACpBgC,IAAcA,UAAUA,CAIvBA;QAJDA,WAAcA,UAAUA,EAACA,CAACA;YACtBC;gBAAAC;gBAEAC,CAACA;gBADUD,yBAAQA,GAAfA,cAAoBE,CAACA;gBACzBF,aAACA;YAADA,CAACA,AAFDD,IAECA;YAFYA,iBAAMA,SAElBA,CAAAA;QACLA,CAACA,EAJaD,UAAUA,GAAVA,0BAAUA,KAAVA,0BAAUA,QAIvBA;IACLA,CAACA,EANM,eAAe,KAAf,eAAe,QAMrB"} \ No newline at end of file diff --git a/tests/baselines/reference/typeResolution.sourcemap.txt b/tests/baselines/reference/typeResolution.sourcemap.txt index 54b2c44eae..a7d8bd170f 100644 --- a/tests/baselines/reference/typeResolution.sourcemap.txt +++ b/tests/baselines/reference/typeResolution.sourcemap.txt @@ -2176,39 +2176,36 @@ sourceFile:typeResolution.ts >>> } 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1->export class ClassA { public AisIn1_2_2() { } 2 > } 1->Emitted(113, 21) Source(79, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA.constructor) 2 >Emitted(113, 22) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA.constructor) --- ->>> ClassA.prototype.AisIn1_2_2 = function () { +>>> ClassA.prototype.AisIn1_2_2 = function () { }; 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ +4 > ^^^^^^^^^^^^^^ +5 > ^ 1-> 2 > AisIn1_2_2 3 > +4 > public AisIn1_2_2() { +5 > } 1->Emitted(114, 21) Source(79, 42) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) 2 >Emitted(114, 48) Source(79, 52) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) 3 >Emitted(114, 51) Source(79, 35) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) ---- ->>> }; -1 >^^^^^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^-> -1 >public AisIn1_2_2() { -2 > } -1 >Emitted(115, 21) Source(79, 57) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA.AisIn1_2_2) -2 >Emitted(115, 22) Source(79, 58) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA.AisIn1_2_2) +4 >Emitted(114, 65) Source(79, 57) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA.AisIn1_2_2) +5 >Emitted(114, 66) Source(79, 58) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA.AisIn1_2_2) --- >>> return ClassA; -1->^^^^^^^^^^^^^^^^^^^^ +1 >^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^ -1-> +1 > 2 > } -1->Emitted(116, 21) Source(79, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) -2 >Emitted(116, 34) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) +1 >Emitted(115, 21) Source(79, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) +2 >Emitted(115, 34) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) --- >>> })(); 1 >^^^^^^^^^^^^^^^^ @@ -2220,10 +2217,10 @@ sourceFile:typeResolution.ts 2 > } 3 > 4 > export class ClassA { public AisIn1_2_2() { } } -1 >Emitted(117, 17) Source(79, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) -2 >Emitted(117, 18) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) -3 >Emitted(117, 18) Source(79, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -4 >Emitted(117, 22) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +1 >Emitted(116, 17) Source(79, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) +2 >Emitted(116, 18) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassA) +3 >Emitted(116, 18) Source(79, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +4 >Emitted(116, 22) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) --- >>> SubSubModule2.ClassA = ClassA; 1->^^^^^^^^^^^^^^^^ @@ -2234,60 +2231,57 @@ sourceFile:typeResolution.ts 2 > ClassA 3 > { public AisIn1_2_2() { } } 4 > -1->Emitted(118, 17) Source(79, 26) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -2 >Emitted(118, 37) Source(79, 32) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -3 >Emitted(118, 46) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -4 >Emitted(118, 47) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +1->Emitted(117, 17) Source(79, 26) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +2 >Emitted(117, 37) Source(79, 32) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +3 >Emitted(117, 46) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +4 >Emitted(117, 47) Source(79, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) --- >>> var ClassB = (function () { 1 >^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > > -1 >Emitted(119, 17) Source(80, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +1 >Emitted(118, 17) Source(80, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) --- >>> function ClassB() { 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^^-> 1-> -1->Emitted(120, 21) Source(80, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) +1->Emitted(119, 21) Source(80, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) --- >>> } 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1->export class ClassB { public BisIn1_2_2() { } 2 > } -1->Emitted(121, 21) Source(80, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB.constructor) -2 >Emitted(121, 22) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB.constructor) +1->Emitted(120, 21) Source(80, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB.constructor) +2 >Emitted(120, 22) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB.constructor) --- ->>> ClassB.prototype.BisIn1_2_2 = function () { +>>> ClassB.prototype.BisIn1_2_2 = function () { }; 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ +4 > ^^^^^^^^^^^^^^ +5 > ^ 1-> 2 > BisIn1_2_2 3 > -1->Emitted(122, 21) Source(80, 42) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) -2 >Emitted(122, 48) Source(80, 52) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) -3 >Emitted(122, 51) Source(80, 35) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) ---- ->>> }; -1 >^^^^^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^-> -1 >public BisIn1_2_2() { -2 > } -1 >Emitted(123, 21) Source(80, 57) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB.BisIn1_2_2) -2 >Emitted(123, 22) Source(80, 58) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB.BisIn1_2_2) +4 > public BisIn1_2_2() { +5 > } +1->Emitted(121, 21) Source(80, 42) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) +2 >Emitted(121, 48) Source(80, 52) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) +3 >Emitted(121, 51) Source(80, 35) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) +4 >Emitted(121, 65) Source(80, 57) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB.BisIn1_2_2) +5 >Emitted(121, 66) Source(80, 58) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB.BisIn1_2_2) --- >>> return ClassB; -1->^^^^^^^^^^^^^^^^^^^^ +1 >^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^ -1-> +1 > 2 > } -1->Emitted(124, 21) Source(80, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) -2 >Emitted(124, 34) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) +1 >Emitted(122, 21) Source(80, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) +2 >Emitted(122, 34) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) --- >>> })(); 1 >^^^^^^^^^^^^^^^^ @@ -2299,10 +2293,10 @@ sourceFile:typeResolution.ts 2 > } 3 > 4 > export class ClassB { public BisIn1_2_2() { } } -1 >Emitted(125, 17) Source(80, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) -2 >Emitted(125, 18) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) -3 >Emitted(125, 18) Source(80, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -4 >Emitted(125, 22) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +1 >Emitted(123, 17) Source(80, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) +2 >Emitted(123, 18) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassB) +3 >Emitted(123, 18) Source(80, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +4 >Emitted(123, 22) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) --- >>> SubSubModule2.ClassB = ClassB; 1->^^^^^^^^^^^^^^^^ @@ -2313,60 +2307,57 @@ sourceFile:typeResolution.ts 2 > ClassB 3 > { public BisIn1_2_2() { } } 4 > -1->Emitted(126, 17) Source(80, 26) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -2 >Emitted(126, 37) Source(80, 32) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -3 >Emitted(126, 46) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -4 >Emitted(126, 47) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +1->Emitted(124, 17) Source(80, 26) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +2 >Emitted(124, 37) Source(80, 32) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +3 >Emitted(124, 46) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +4 >Emitted(124, 47) Source(80, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) --- >>> var ClassC = (function () { 1 >^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > > -1 >Emitted(127, 17) Source(81, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +1 >Emitted(125, 17) Source(81, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) --- >>> function ClassC() { 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^^-> 1-> -1->Emitted(128, 21) Source(81, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) +1->Emitted(126, 21) Source(81, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) --- >>> } 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1->export class ClassC { public CisIn1_2_2() { } 2 > } -1->Emitted(129, 21) Source(81, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC.constructor) -2 >Emitted(129, 22) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC.constructor) +1->Emitted(127, 21) Source(81, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC.constructor) +2 >Emitted(127, 22) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC.constructor) --- ->>> ClassC.prototype.CisIn1_2_2 = function () { +>>> ClassC.prototype.CisIn1_2_2 = function () { }; 1->^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ +4 > ^^^^^^^^^^^^^^ +5 > ^ 1-> 2 > CisIn1_2_2 3 > -1->Emitted(130, 21) Source(81, 42) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) -2 >Emitted(130, 48) Source(81, 52) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) -3 >Emitted(130, 51) Source(81, 35) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) ---- ->>> }; -1 >^^^^^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^-> -1 >public CisIn1_2_2() { -2 > } -1 >Emitted(131, 21) Source(81, 57) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC.CisIn1_2_2) -2 >Emitted(131, 22) Source(81, 58) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC.CisIn1_2_2) +4 > public CisIn1_2_2() { +5 > } +1->Emitted(128, 21) Source(81, 42) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) +2 >Emitted(128, 48) Source(81, 52) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) +3 >Emitted(128, 51) Source(81, 35) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) +4 >Emitted(128, 65) Source(81, 57) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC.CisIn1_2_2) +5 >Emitted(128, 66) Source(81, 58) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC.CisIn1_2_2) --- >>> return ClassC; -1->^^^^^^^^^^^^^^^^^^^^ +1 >^^^^^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^ -1-> +1 > 2 > } -1->Emitted(132, 21) Source(81, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) -2 >Emitted(132, 34) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) +1 >Emitted(129, 21) Source(81, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) +2 >Emitted(129, 34) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) --- >>> })(); 1 >^^^^^^^^^^^^^^^^ @@ -2378,10 +2369,10 @@ sourceFile:typeResolution.ts 2 > } 3 > 4 > export class ClassC { public CisIn1_2_2() { } } -1 >Emitted(133, 17) Source(81, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) -2 >Emitted(133, 18) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) -3 >Emitted(133, 18) Source(81, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -4 >Emitted(133, 22) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +1 >Emitted(130, 17) Source(81, 59) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) +2 >Emitted(130, 18) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2.ClassC) +3 >Emitted(130, 18) Source(81, 13) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +4 >Emitted(130, 22) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) --- >>> SubSubModule2.ClassC = ClassC; 1->^^^^^^^^^^^^^^^^ @@ -2393,10 +2384,10 @@ sourceFile:typeResolution.ts 2 > ClassC 3 > { public CisIn1_2_2() { } } 4 > -1->Emitted(134, 17) Source(81, 26) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -2 >Emitted(134, 37) Source(81, 32) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -3 >Emitted(134, 46) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -4 >Emitted(134, 47) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +1->Emitted(131, 17) Source(81, 26) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +2 >Emitted(131, 37) Source(81, 32) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +3 >Emitted(131, 46) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +4 >Emitted(131, 47) Source(81, 60) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) --- >>> })(SubSubModule2 = SubModule2.SubSubModule2 || (SubModule2.SubSubModule2 = {})); 1->^^^^^^^^^^^^^^^^ @@ -2429,16 +2420,16 @@ sourceFile:typeResolution.ts > export interface InterfaceY { YisIn1_2_2(); } > interface NonExportedInterfaceQ { } > } -1->Emitted(135, 17) Source(83, 48) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -2 >Emitted(135, 13) Source(84, 9) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -3 >Emitted(135, 14) Source(84, 10) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) -4 >Emitted(135, 16) Source(77, 23) + SourceIndex(0) name (TopLevelModule1.SubModule2) -5 >Emitted(135, 29) Source(77, 36) + SourceIndex(0) name (TopLevelModule1.SubModule2) -6 >Emitted(135, 32) Source(77, 23) + SourceIndex(0) name (TopLevelModule1.SubModule2) -7 >Emitted(135, 56) Source(77, 36) + SourceIndex(0) name (TopLevelModule1.SubModule2) -8 >Emitted(135, 61) Source(77, 23) + SourceIndex(0) name (TopLevelModule1.SubModule2) -9 >Emitted(135, 85) Source(77, 36) + SourceIndex(0) name (TopLevelModule1.SubModule2) -10>Emitted(135, 93) Source(84, 10) + SourceIndex(0) name (TopLevelModule1.SubModule2) +1->Emitted(132, 17) Source(83, 48) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +2 >Emitted(132, 13) Source(84, 9) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +3 >Emitted(132, 14) Source(84, 10) + SourceIndex(0) name (TopLevelModule1.SubModule2.SubSubModule2) +4 >Emitted(132, 16) Source(77, 23) + SourceIndex(0) name (TopLevelModule1.SubModule2) +5 >Emitted(132, 29) Source(77, 36) + SourceIndex(0) name (TopLevelModule1.SubModule2) +6 >Emitted(132, 32) Source(77, 23) + SourceIndex(0) name (TopLevelModule1.SubModule2) +7 >Emitted(132, 56) Source(77, 36) + SourceIndex(0) name (TopLevelModule1.SubModule2) +8 >Emitted(132, 61) Source(77, 23) + SourceIndex(0) name (TopLevelModule1.SubModule2) +9 >Emitted(132, 85) Source(77, 36) + SourceIndex(0) name (TopLevelModule1.SubModule2) +10>Emitted(132, 93) Source(84, 10) + SourceIndex(0) name (TopLevelModule1.SubModule2) --- >>> })(SubModule2 = TopLevelModule1.SubModule2 || (TopLevelModule1.SubModule2 = {})); 1 >^^^^^^^^^^^^ @@ -2475,16 +2466,16 @@ sourceFile:typeResolution.ts > > export interface InterfaceY { YisIn1_2(); } > } -1 >Emitted(136, 13) Source(86, 52) + SourceIndex(0) name (TopLevelModule1.SubModule2) -2 >Emitted(136, 9) Source(87, 5) + SourceIndex(0) name (TopLevelModule1.SubModule2) -3 >Emitted(136, 10) Source(87, 6) + SourceIndex(0) name (TopLevelModule1.SubModule2) -4 >Emitted(136, 12) Source(76, 19) + SourceIndex(0) name (TopLevelModule1) -5 >Emitted(136, 22) Source(76, 29) + SourceIndex(0) name (TopLevelModule1) -6 >Emitted(136, 25) Source(76, 19) + SourceIndex(0) name (TopLevelModule1) -7 >Emitted(136, 51) Source(76, 29) + SourceIndex(0) name (TopLevelModule1) -8 >Emitted(136, 56) Source(76, 19) + SourceIndex(0) name (TopLevelModule1) -9 >Emitted(136, 82) Source(76, 29) + SourceIndex(0) name (TopLevelModule1) -10>Emitted(136, 90) Source(87, 6) + SourceIndex(0) name (TopLevelModule1) +1 >Emitted(133, 13) Source(86, 52) + SourceIndex(0) name (TopLevelModule1.SubModule2) +2 >Emitted(133, 9) Source(87, 5) + SourceIndex(0) name (TopLevelModule1.SubModule2) +3 >Emitted(133, 10) Source(87, 6) + SourceIndex(0) name (TopLevelModule1.SubModule2) +4 >Emitted(133, 12) Source(76, 19) + SourceIndex(0) name (TopLevelModule1) +5 >Emitted(133, 22) Source(76, 29) + SourceIndex(0) name (TopLevelModule1) +6 >Emitted(133, 25) Source(76, 19) + SourceIndex(0) name (TopLevelModule1) +7 >Emitted(133, 51) Source(76, 29) + SourceIndex(0) name (TopLevelModule1) +8 >Emitted(133, 56) Source(76, 19) + SourceIndex(0) name (TopLevelModule1) +9 >Emitted(133, 82) Source(76, 29) + SourceIndex(0) name (TopLevelModule1) +10>Emitted(133, 90) Source(87, 6) + SourceIndex(0) name (TopLevelModule1) --- >>> var ClassA = (function () { 1 >^^^^^^^^ @@ -2492,53 +2483,50 @@ sourceFile:typeResolution.ts 1 > > > -1 >Emitted(137, 9) Source(89, 5) + SourceIndex(0) name (TopLevelModule1) +1 >Emitted(134, 9) Source(89, 5) + SourceIndex(0) name (TopLevelModule1) --- >>> function ClassA() { 1->^^^^^^^^^^^^ 2 > ^^-> 1-> -1->Emitted(138, 13) Source(89, 5) + SourceIndex(0) name (TopLevelModule1.ClassA) +1->Emitted(135, 13) Source(89, 5) + SourceIndex(0) name (TopLevelModule1.ClassA) --- >>> } 1->^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1->class ClassA { > public AisIn1() { } > 2 > } -1->Emitted(139, 13) Source(91, 5) + SourceIndex(0) name (TopLevelModule1.ClassA.constructor) -2 >Emitted(139, 14) Source(91, 6) + SourceIndex(0) name (TopLevelModule1.ClassA.constructor) +1->Emitted(136, 13) Source(91, 5) + SourceIndex(0) name (TopLevelModule1.ClassA.constructor) +2 >Emitted(136, 14) Source(91, 6) + SourceIndex(0) name (TopLevelModule1.ClassA.constructor) --- ->>> ClassA.prototype.AisIn1 = function () { +>>> ClassA.prototype.AisIn1 = function () { }; 1->^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ +4 > ^^^^^^^^^^^^^^ +5 > ^ 1-> 2 > AisIn1 3 > -1->Emitted(140, 13) Source(90, 16) + SourceIndex(0) name (TopLevelModule1.ClassA) -2 >Emitted(140, 36) Source(90, 22) + SourceIndex(0) name (TopLevelModule1.ClassA) -3 >Emitted(140, 39) Source(90, 9) + SourceIndex(0) name (TopLevelModule1.ClassA) ---- ->>> }; -1 >^^^^^^^^^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^-> -1 >public AisIn1() { -2 > } -1 >Emitted(141, 13) Source(90, 27) + SourceIndex(0) name (TopLevelModule1.ClassA.AisIn1) -2 >Emitted(141, 14) Source(90, 28) + SourceIndex(0) name (TopLevelModule1.ClassA.AisIn1) +4 > public AisIn1() { +5 > } +1->Emitted(137, 13) Source(90, 16) + SourceIndex(0) name (TopLevelModule1.ClassA) +2 >Emitted(137, 36) Source(90, 22) + SourceIndex(0) name (TopLevelModule1.ClassA) +3 >Emitted(137, 39) Source(90, 9) + SourceIndex(0) name (TopLevelModule1.ClassA) +4 >Emitted(137, 53) Source(90, 27) + SourceIndex(0) name (TopLevelModule1.ClassA.AisIn1) +5 >Emitted(137, 54) Source(90, 28) + SourceIndex(0) name (TopLevelModule1.ClassA.AisIn1) --- >>> return ClassA; -1->^^^^^^^^^^^^ +1 >^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^ -1-> +1 > > 2 > } -1->Emitted(142, 13) Source(91, 5) + SourceIndex(0) name (TopLevelModule1.ClassA) -2 >Emitted(142, 26) Source(91, 6) + SourceIndex(0) name (TopLevelModule1.ClassA) +1 >Emitted(138, 13) Source(91, 5) + SourceIndex(0) name (TopLevelModule1.ClassA) +2 >Emitted(138, 26) Source(91, 6) + SourceIndex(0) name (TopLevelModule1.ClassA) --- >>> })(); 1 >^^^^^^^^ @@ -2552,10 +2540,10 @@ sourceFile:typeResolution.ts 4 > class ClassA { > public AisIn1() { } > } -1 >Emitted(143, 9) Source(91, 5) + SourceIndex(0) name (TopLevelModule1.ClassA) -2 >Emitted(143, 10) Source(91, 6) + SourceIndex(0) name (TopLevelModule1.ClassA) -3 >Emitted(143, 10) Source(89, 5) + SourceIndex(0) name (TopLevelModule1) -4 >Emitted(143, 14) Source(91, 6) + SourceIndex(0) name (TopLevelModule1) +1 >Emitted(139, 9) Source(91, 5) + SourceIndex(0) name (TopLevelModule1.ClassA) +2 >Emitted(139, 10) Source(91, 6) + SourceIndex(0) name (TopLevelModule1.ClassA) +3 >Emitted(139, 10) Source(89, 5) + SourceIndex(0) name (TopLevelModule1) +4 >Emitted(139, 14) Source(91, 6) + SourceIndex(0) name (TopLevelModule1) --- >>> var NotExportedModule; 1->^^^^^^^^ @@ -2575,10 +2563,10 @@ sourceFile:typeResolution.ts 4 > { > export class ClassA { } > } -1->Emitted(144, 9) Source(97, 5) + SourceIndex(0) name (TopLevelModule1) -2 >Emitted(144, 13) Source(97, 12) + SourceIndex(0) name (TopLevelModule1) -3 >Emitted(144, 30) Source(97, 29) + SourceIndex(0) name (TopLevelModule1) -4 >Emitted(144, 31) Source(99, 6) + SourceIndex(0) name (TopLevelModule1) +1->Emitted(140, 9) Source(97, 5) + SourceIndex(0) name (TopLevelModule1) +2 >Emitted(140, 13) Source(97, 12) + SourceIndex(0) name (TopLevelModule1) +3 >Emitted(140, 30) Source(97, 29) + SourceIndex(0) name (TopLevelModule1) +4 >Emitted(140, 31) Source(99, 6) + SourceIndex(0) name (TopLevelModule1) --- >>> (function (NotExportedModule) { 1->^^^^^^^^ @@ -2592,24 +2580,24 @@ sourceFile:typeResolution.ts 3 > NotExportedModule 4 > 5 > { -1->Emitted(145, 9) Source(97, 5) + SourceIndex(0) name (TopLevelModule1) -2 >Emitted(145, 20) Source(97, 12) + SourceIndex(0) name (TopLevelModule1) -3 >Emitted(145, 37) Source(97, 29) + SourceIndex(0) name (TopLevelModule1) -4 >Emitted(145, 39) Source(97, 30) + SourceIndex(0) name (TopLevelModule1) -5 >Emitted(145, 40) Source(97, 31) + SourceIndex(0) name (TopLevelModule1) +1->Emitted(141, 9) Source(97, 5) + SourceIndex(0) name (TopLevelModule1) +2 >Emitted(141, 20) Source(97, 12) + SourceIndex(0) name (TopLevelModule1) +3 >Emitted(141, 37) Source(97, 29) + SourceIndex(0) name (TopLevelModule1) +4 >Emitted(141, 39) Source(97, 30) + SourceIndex(0) name (TopLevelModule1) +5 >Emitted(141, 40) Source(97, 31) + SourceIndex(0) name (TopLevelModule1) --- >>> var ClassA = (function () { 1->^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > -1->Emitted(146, 13) Source(98, 9) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +1->Emitted(142, 13) Source(98, 9) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) --- >>> function ClassA() { 1->^^^^^^^^^^^^^^^^ 2 > ^^-> 1-> -1->Emitted(147, 17) Source(98, 9) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) +1->Emitted(143, 17) Source(98, 9) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) --- >>> } 1->^^^^^^^^^^^^^^^^ @@ -2617,16 +2605,16 @@ sourceFile:typeResolution.ts 3 > ^^^^^^^^^^^^^^-> 1->export class ClassA { 2 > } -1->Emitted(148, 17) Source(98, 31) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA.constructor) -2 >Emitted(148, 18) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA.constructor) +1->Emitted(144, 17) Source(98, 31) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA.constructor) +2 >Emitted(144, 18) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA.constructor) --- >>> return ClassA; 1->^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^ 1-> 2 > } -1->Emitted(149, 17) Source(98, 31) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) -2 >Emitted(149, 30) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) +1->Emitted(145, 17) Source(98, 31) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) +2 >Emitted(145, 30) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) --- >>> })(); 1 >^^^^^^^^^^^^ @@ -2638,10 +2626,10 @@ sourceFile:typeResolution.ts 2 > } 3 > 4 > export class ClassA { } -1 >Emitted(150, 13) Source(98, 31) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) -2 >Emitted(150, 14) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) -3 >Emitted(150, 14) Source(98, 9) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) -4 >Emitted(150, 18) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +1 >Emitted(146, 13) Source(98, 31) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) +2 >Emitted(146, 14) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule.ClassA) +3 >Emitted(146, 14) Source(98, 9) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +4 >Emitted(146, 18) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) --- >>> NotExportedModule.ClassA = ClassA; 1->^^^^^^^^^^^^ @@ -2653,10 +2641,10 @@ sourceFile:typeResolution.ts 2 > ClassA 3 > { } 4 > -1->Emitted(151, 13) Source(98, 22) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) -2 >Emitted(151, 37) Source(98, 28) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) -3 >Emitted(151, 46) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) -4 >Emitted(151, 47) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +1->Emitted(147, 13) Source(98, 22) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +2 >Emitted(147, 37) Source(98, 28) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +3 >Emitted(147, 46) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +4 >Emitted(147, 47) Source(98, 32) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) --- >>> })(NotExportedModule || (NotExportedModule = {})); 1->^^^^^^^^ @@ -2677,13 +2665,13 @@ sourceFile:typeResolution.ts 7 > { > export class ClassA { } > } -1->Emitted(152, 9) Source(99, 5) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) -2 >Emitted(152, 10) Source(99, 6) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) -3 >Emitted(152, 12) Source(97, 12) + SourceIndex(0) name (TopLevelModule1) -4 >Emitted(152, 29) Source(97, 29) + SourceIndex(0) name (TopLevelModule1) -5 >Emitted(152, 34) Source(97, 12) + SourceIndex(0) name (TopLevelModule1) -6 >Emitted(152, 51) Source(97, 29) + SourceIndex(0) name (TopLevelModule1) -7 >Emitted(152, 59) Source(99, 6) + SourceIndex(0) name (TopLevelModule1) +1->Emitted(148, 9) Source(99, 5) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +2 >Emitted(148, 10) Source(99, 6) + SourceIndex(0) name (TopLevelModule1.NotExportedModule) +3 >Emitted(148, 12) Source(97, 12) + SourceIndex(0) name (TopLevelModule1) +4 >Emitted(148, 29) Source(97, 29) + SourceIndex(0) name (TopLevelModule1) +5 >Emitted(148, 34) Source(97, 12) + SourceIndex(0) name (TopLevelModule1) +6 >Emitted(148, 51) Source(97, 29) + SourceIndex(0) name (TopLevelModule1) +7 >Emitted(148, 59) Source(99, 6) + SourceIndex(0) name (TopLevelModule1) --- >>> })(TopLevelModule1 = exports.TopLevelModule1 || (exports.TopLevelModule1 = {})); 1->^^^^ @@ -2804,15 +2792,15 @@ sourceFile:typeResolution.ts > export class ClassA { } > } > } -1->Emitted(153, 5) Source(100, 1) + SourceIndex(0) name (TopLevelModule1) -2 >Emitted(153, 6) Source(100, 2) + SourceIndex(0) name (TopLevelModule1) -3 >Emitted(153, 8) Source(1, 15) + SourceIndex(0) -4 >Emitted(153, 23) Source(1, 30) + SourceIndex(0) -5 >Emitted(153, 26) Source(1, 15) + SourceIndex(0) -6 >Emitted(153, 49) Source(1, 30) + SourceIndex(0) -7 >Emitted(153, 54) Source(1, 15) + SourceIndex(0) -8 >Emitted(153, 77) Source(1, 30) + SourceIndex(0) -9 >Emitted(153, 85) Source(100, 2) + SourceIndex(0) +1->Emitted(149, 5) Source(100, 1) + SourceIndex(0) name (TopLevelModule1) +2 >Emitted(149, 6) Source(100, 2) + SourceIndex(0) name (TopLevelModule1) +3 >Emitted(149, 8) Source(1, 15) + SourceIndex(0) +4 >Emitted(149, 23) Source(1, 30) + SourceIndex(0) +5 >Emitted(149, 26) Source(1, 15) + SourceIndex(0) +6 >Emitted(149, 49) Source(1, 30) + SourceIndex(0) +7 >Emitted(149, 54) Source(1, 15) + SourceIndex(0) +8 >Emitted(149, 77) Source(1, 30) + SourceIndex(0) +9 >Emitted(149, 85) Source(100, 2) + SourceIndex(0) --- >>> var TopLevelModule2; 1 >^^^^ @@ -2832,10 +2820,10 @@ sourceFile:typeResolution.ts > } > } > } -1 >Emitted(154, 5) Source(102, 1) + SourceIndex(0) -2 >Emitted(154, 9) Source(102, 8) + SourceIndex(0) -3 >Emitted(154, 24) Source(102, 23) + SourceIndex(0) -4 >Emitted(154, 25) Source(108, 2) + SourceIndex(0) +1 >Emitted(150, 5) Source(102, 1) + SourceIndex(0) +2 >Emitted(150, 9) Source(102, 8) + SourceIndex(0) +3 >Emitted(150, 24) Source(102, 23) + SourceIndex(0) +4 >Emitted(150, 25) Source(108, 2) + SourceIndex(0) --- >>> (function (TopLevelModule2) { 1->^^^^ @@ -2848,11 +2836,11 @@ sourceFile:typeResolution.ts 3 > TopLevelModule2 4 > 5 > { -1->Emitted(155, 5) Source(102, 1) + SourceIndex(0) -2 >Emitted(155, 16) Source(102, 8) + SourceIndex(0) -3 >Emitted(155, 31) Source(102, 23) + SourceIndex(0) -4 >Emitted(155, 33) Source(102, 24) + SourceIndex(0) -5 >Emitted(155, 34) Source(102, 25) + SourceIndex(0) +1->Emitted(151, 5) Source(102, 1) + SourceIndex(0) +2 >Emitted(151, 16) Source(102, 8) + SourceIndex(0) +3 >Emitted(151, 31) Source(102, 23) + SourceIndex(0) +4 >Emitted(151, 33) Source(102, 24) + SourceIndex(0) +5 >Emitted(151, 34) Source(102, 25) + SourceIndex(0) --- >>> var SubModule3; 1 >^^^^^^^^ @@ -2869,10 +2857,10 @@ sourceFile:typeResolution.ts > public AisIn2_3() { } > } > } -1 >Emitted(156, 9) Source(103, 5) + SourceIndex(0) name (TopLevelModule2) -2 >Emitted(156, 13) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) -3 >Emitted(156, 23) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) -4 >Emitted(156, 24) Source(107, 6) + SourceIndex(0) name (TopLevelModule2) +1 >Emitted(152, 9) Source(103, 5) + SourceIndex(0) name (TopLevelModule2) +2 >Emitted(152, 13) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) +3 >Emitted(152, 23) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) +4 >Emitted(152, 24) Source(107, 6) + SourceIndex(0) name (TopLevelModule2) --- >>> (function (SubModule3) { 1->^^^^^^^^ @@ -2886,64 +2874,61 @@ sourceFile:typeResolution.ts 3 > SubModule3 4 > 5 > { -1->Emitted(157, 9) Source(103, 5) + SourceIndex(0) name (TopLevelModule2) -2 >Emitted(157, 20) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) -3 >Emitted(157, 30) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) -4 >Emitted(157, 32) Source(103, 30) + SourceIndex(0) name (TopLevelModule2) -5 >Emitted(157, 33) Source(103, 31) + SourceIndex(0) name (TopLevelModule2) +1->Emitted(153, 9) Source(103, 5) + SourceIndex(0) name (TopLevelModule2) +2 >Emitted(153, 20) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) +3 >Emitted(153, 30) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) +4 >Emitted(153, 32) Source(103, 30) + SourceIndex(0) name (TopLevelModule2) +5 >Emitted(153, 33) Source(103, 31) + SourceIndex(0) name (TopLevelModule2) --- >>> var ClassA = (function () { 1->^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^-> 1-> > -1->Emitted(158, 13) Source(104, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3) +1->Emitted(154, 13) Source(104, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3) --- >>> function ClassA() { 1->^^^^^^^^^^^^^^^^ 2 > ^^-> 1-> -1->Emitted(159, 17) Source(104, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) +1->Emitted(155, 17) Source(104, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) --- >>> } 1->^^^^^^^^^^^^^^^^ 2 > ^ -3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +3 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1->export class ClassA { > public AisIn2_3() { } > 2 > } -1->Emitted(160, 17) Source(106, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA.constructor) -2 >Emitted(160, 18) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA.constructor) +1->Emitted(156, 17) Source(106, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA.constructor) +2 >Emitted(156, 18) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA.constructor) --- ->>> ClassA.prototype.AisIn2_3 = function () { +>>> ClassA.prototype.AisIn2_3 = function () { }; 1->^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^^^^^^^^^^^^^ 3 > ^^^ +4 > ^^^^^^^^^^^^^^ +5 > ^ 1-> 2 > AisIn2_3 3 > -1->Emitted(161, 17) Source(105, 20) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) -2 >Emitted(161, 42) Source(105, 28) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) -3 >Emitted(161, 45) Source(105, 13) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) ---- ->>> }; -1 >^^^^^^^^^^^^^^^^ -2 > ^ -3 > ^^^^^^^^^^^^^^-> -1 >public AisIn2_3() { -2 > } -1 >Emitted(162, 17) Source(105, 33) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA.AisIn2_3) -2 >Emitted(162, 18) Source(105, 34) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA.AisIn2_3) +4 > public AisIn2_3() { +5 > } +1->Emitted(157, 17) Source(105, 20) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) +2 >Emitted(157, 42) Source(105, 28) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) +3 >Emitted(157, 45) Source(105, 13) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) +4 >Emitted(157, 59) Source(105, 33) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA.AisIn2_3) +5 >Emitted(157, 60) Source(105, 34) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA.AisIn2_3) --- >>> return ClassA; -1->^^^^^^^^^^^^^^^^ +1 >^^^^^^^^^^^^^^^^ 2 > ^^^^^^^^^^^^^ -1-> +1 > > 2 > } -1->Emitted(163, 17) Source(106, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) -2 >Emitted(163, 30) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) +1 >Emitted(158, 17) Source(106, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) +2 >Emitted(158, 30) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) --- >>> })(); 1 >^^^^^^^^^^^^ @@ -2957,10 +2942,10 @@ sourceFile:typeResolution.ts 4 > export class ClassA { > public AisIn2_3() { } > } -1 >Emitted(164, 13) Source(106, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) -2 >Emitted(164, 14) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) -3 >Emitted(164, 14) Source(104, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3) -4 >Emitted(164, 18) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3) +1 >Emitted(159, 13) Source(106, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) +2 >Emitted(159, 14) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3.ClassA) +3 >Emitted(159, 14) Source(104, 9) + SourceIndex(0) name (TopLevelModule2.SubModule3) +4 >Emitted(159, 18) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3) --- >>> SubModule3.ClassA = ClassA; 1->^^^^^^^^^^^^ @@ -2974,10 +2959,10 @@ sourceFile:typeResolution.ts > public AisIn2_3() { } > } 4 > -1->Emitted(165, 13) Source(104, 22) + SourceIndex(0) name (TopLevelModule2.SubModule3) -2 >Emitted(165, 30) Source(104, 28) + SourceIndex(0) name (TopLevelModule2.SubModule3) -3 >Emitted(165, 39) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3) -4 >Emitted(165, 40) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3) +1->Emitted(160, 13) Source(104, 22) + SourceIndex(0) name (TopLevelModule2.SubModule3) +2 >Emitted(160, 30) Source(104, 28) + SourceIndex(0) name (TopLevelModule2.SubModule3) +3 >Emitted(160, 39) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3) +4 >Emitted(160, 40) Source(106, 10) + SourceIndex(0) name (TopLevelModule2.SubModule3) --- >>> })(SubModule3 = TopLevelModule2.SubModule3 || (TopLevelModule2.SubModule3 = {})); 1->^^^^^^^^ @@ -3003,15 +2988,15 @@ sourceFile:typeResolution.ts > public AisIn2_3() { } > } > } -1->Emitted(166, 9) Source(107, 5) + SourceIndex(0) name (TopLevelModule2.SubModule3) -2 >Emitted(166, 10) Source(107, 6) + SourceIndex(0) name (TopLevelModule2.SubModule3) -3 >Emitted(166, 12) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) -4 >Emitted(166, 22) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) -5 >Emitted(166, 25) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) -6 >Emitted(166, 51) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) -7 >Emitted(166, 56) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) -8 >Emitted(166, 82) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) -9 >Emitted(166, 90) Source(107, 6) + SourceIndex(0) name (TopLevelModule2) +1->Emitted(161, 9) Source(107, 5) + SourceIndex(0) name (TopLevelModule2.SubModule3) +2 >Emitted(161, 10) Source(107, 6) + SourceIndex(0) name (TopLevelModule2.SubModule3) +3 >Emitted(161, 12) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) +4 >Emitted(161, 22) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) +5 >Emitted(161, 25) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) +6 >Emitted(161, 51) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) +7 >Emitted(161, 56) Source(103, 19) + SourceIndex(0) name (TopLevelModule2) +8 >Emitted(161, 82) Source(103, 29) + SourceIndex(0) name (TopLevelModule2) +9 >Emitted(161, 90) Source(107, 6) + SourceIndex(0) name (TopLevelModule2) --- >>> })(TopLevelModule2 || (TopLevelModule2 = {})); 1 >^^^^ @@ -3035,13 +3020,13 @@ sourceFile:typeResolution.ts > } > } > } -1 >Emitted(167, 5) Source(108, 1) + SourceIndex(0) name (TopLevelModule2) -2 >Emitted(167, 6) Source(108, 2) + SourceIndex(0) name (TopLevelModule2) -3 >Emitted(167, 8) Source(102, 8) + SourceIndex(0) -4 >Emitted(167, 23) Source(102, 23) + SourceIndex(0) -5 >Emitted(167, 28) Source(102, 8) + SourceIndex(0) -6 >Emitted(167, 43) Source(102, 23) + SourceIndex(0) -7 >Emitted(167, 51) Source(108, 2) + SourceIndex(0) +1 >Emitted(162, 5) Source(108, 1) + SourceIndex(0) name (TopLevelModule2) +2 >Emitted(162, 6) Source(108, 2) + SourceIndex(0) name (TopLevelModule2) +3 >Emitted(162, 8) Source(102, 8) + SourceIndex(0) +4 >Emitted(162, 23) Source(102, 23) + SourceIndex(0) +5 >Emitted(162, 28) Source(102, 8) + SourceIndex(0) +6 >Emitted(162, 43) Source(102, 23) + SourceIndex(0) +7 >Emitted(162, 51) Source(108, 2) + SourceIndex(0) --- >>>}); >>>//# sourceMappingURL=typeResolution.js.map \ No newline at end of file diff --git a/tests/baselines/reference/typeVal.js b/tests/baselines/reference/typeVal.js index 7c1d506fbd..264b40c5f1 100644 --- a/tests/baselines/reference/typeVal.js +++ b/tests/baselines/reference/typeVal.js @@ -9,7 +9,5 @@ I.I=4; //// [typeVal.js] -var I = { - I: 3 -}; +var I = { I: 3 }; I.I = 4; diff --git a/tests/baselines/reference/typedGenericPrototypeMember.js b/tests/baselines/reference/typedGenericPrototypeMember.js index 866bf500de..e5ba2e0e75 100644 --- a/tests/baselines/reference/typedGenericPrototypeMember.js +++ b/tests/baselines/reference/typedGenericPrototypeMember.js @@ -10,8 +10,7 @@ List.prototype.add("abc"); // Valid because T is instantiated to any var List = (function () { function List() { } - List.prototype.add = function (item) { - }; + List.prototype.add = function (item) { }; return List; })(); List.prototype.add("abc"); // Valid because T is instantiated to any diff --git a/tests/baselines/reference/typeofANonExportedType.js b/tests/baselines/reference/typeofANonExportedType.js index 7ce08d5f93..bb41ddfab7 100644 --- a/tests/baselines/reference/typeofANonExportedType.js +++ b/tests/baselines/reference/typeofANonExportedType.js @@ -54,9 +54,7 @@ export var r13: typeof foo; //// [typeofANonExportedType.js] var x = 1; exports.r1; -var y = { - foo: '' -}; +var y = { foo: '' }; exports.r2; var C = (function () { function C() { @@ -93,8 +91,7 @@ var E; exports.r10; exports.r11; exports.r12; -function foo() { -} +function foo() { } var foo; (function (foo) { foo.y = 1; diff --git a/tests/baselines/reference/typeofAnExportedType.js b/tests/baselines/reference/typeofAnExportedType.js index 20a0fe754e..af6c405a3c 100644 --- a/tests/baselines/reference/typeofAnExportedType.js +++ b/tests/baselines/reference/typeofAnExportedType.js @@ -54,9 +54,7 @@ export var r13: typeof foo; //// [typeofAnExportedType.js] exports.x = 1; exports.r1; -exports.y = { - foo: '' -}; +exports.y = { foo: '' }; exports.r2; var C = (function () { function C() { @@ -95,8 +93,7 @@ var E = exports.E; exports.r10; exports.r11; exports.r12; -function foo() { -} +function foo() { } exports.foo = foo; var foo; (function (foo) { diff --git a/tests/baselines/reference/typeofClass2.js b/tests/baselines/reference/typeofClass2.js index cbad006837..1cef22bf2e 100644 --- a/tests/baselines/reference/typeofClass2.js +++ b/tests/baselines/reference/typeofClass2.js @@ -31,10 +31,8 @@ var __extends = this.__extends || function (d, b) { var C = (function () { function C(x) { } - C.foo = function (x) { - }; - C.bar = function (x) { - }; + C.foo = function (x) { }; + C.bar = function (x) { }; return C; })(); var D = (function (_super) { @@ -42,10 +40,8 @@ var D = (function (_super) { function D() { _super.apply(this, arguments); } - D.baz = function (x) { - }; - D.prototype.foo = function () { - }; + D.baz = function (x) { }; + D.prototype.foo = function () { }; return D; })(C); var d; diff --git a/tests/baselines/reference/typeofInterface.js b/tests/baselines/reference/typeofInterface.js index 49e194db7f..1f0bf72eeb 100644 --- a/tests/baselines/reference/typeofInterface.js +++ b/tests/baselines/reference/typeofInterface.js @@ -12,6 +12,4 @@ var j: typeof k.foo = { a: "hello" }; //// [typeofInterface.js] var I; var k; -var j = { - a: "hello" -}; +var j = { a: "hello" }; diff --git a/tests/baselines/reference/typeofOperatorWithAnyOtherType.js b/tests/baselines/reference/typeofOperatorWithAnyOtherType.js index 422d49ae11..a497519f24 100644 --- a/tests/baselines/reference/typeofOperatorWithAnyOtherType.js +++ b/tests/baselines/reference/typeofOperatorWithAnyOtherType.js @@ -78,16 +78,9 @@ z: typeof obj1.x; // typeof operator on any type var ANY; var ANY1; -var ANY2 = [ - "", - "" -]; +var ANY2 = ["", ""]; var obj; -var obj1 = { - x: "a", - y: function () { - } -}; +var obj1 = { x: "a", y: function () { } }; function foo() { var a; return a; diff --git a/tests/baselines/reference/typeofOperatorWithBooleanType.js b/tests/baselines/reference/typeofOperatorWithBooleanType.js index 884371f944..82af3eac26 100644 --- a/tests/baselines/reference/typeofOperatorWithBooleanType.js +++ b/tests/baselines/reference/typeofOperatorWithBooleanType.js @@ -53,15 +53,11 @@ z: typeof M.n; //// [typeofOperatorWithBooleanType.js] // typeof operator on boolean type var BOOLEAN; -function foo() { - return true; -} +function foo() { return true; } var A = (function () { function A() { } - A.foo = function () { - return false; - }; + A.foo = function () { return false; }; return A; })(); var M; @@ -73,10 +69,7 @@ var objA = new A(); var ResultIsString1 = typeof BOOLEAN; // boolean type literal var ResultIsString2 = typeof true; -var ResultIsString3 = typeof { - x: true, - y: false -}; +var ResultIsString3 = typeof { x: true, y: false }; // boolean type expressions var ResultIsString4 = typeof objA.a; var ResultIsString5 = typeof M.n; @@ -97,10 +90,7 @@ var x; var r; z: typeof BOOLEAN; r: typeof foo; -var y = { - a: true, - b: false -}; +var y = { a: true, b: false }; z: typeof y.a; z: typeof objA.a; z: typeof A.foo; diff --git a/tests/baselines/reference/typeofOperatorWithNumberType.js b/tests/baselines/reference/typeofOperatorWithNumberType.js index 51e657e401..14b45ab518 100644 --- a/tests/baselines/reference/typeofOperatorWithNumberType.js +++ b/tests/baselines/reference/typeofOperatorWithNumberType.js @@ -60,19 +60,12 @@ z: typeof M.n; //// [typeofOperatorWithNumberType.js] // typeof operator on number type var NUMBER; -var NUMBER1 = [ - 1, - 2 -]; -function foo() { - return 1; -} +var NUMBER1 = [1, 2]; +function foo() { return 1; } var A = (function () { function A() { } - A.foo = function () { - return 1; - }; + A.foo = function () { return 1; }; return A; })(); var M; @@ -85,16 +78,8 @@ var ResultIsString1 = typeof NUMBER; var ResultIsString2 = typeof NUMBER1; // number type literal var ResultIsString3 = typeof 1; -var ResultIsString4 = typeof { - x: 1, - y: 2 -}; -var ResultIsString5 = typeof { - x: 1, - y: function (n) { - return n; - } -}; +var ResultIsString4 = typeof { x: 1, y: 2 }; +var ResultIsString5 = typeof { x: 1, y: function (n) { return n; } }; // number type expressions var ResultIsString6 = typeof objA.a; var ResultIsString7 = typeof M.n; @@ -119,10 +104,7 @@ var x; z: typeof NUMBER; x: typeof NUMBER1; r: typeof foo; -var y = { - a: 1, - b: 2 -}; +var y = { a: 1, b: 2 }; z: typeof y.a; z: typeof objA.a; z: typeof A.foo; diff --git a/tests/baselines/reference/typeofOperatorWithStringType.js b/tests/baselines/reference/typeofOperatorWithStringType.js index d527284452..381205ff8c 100644 --- a/tests/baselines/reference/typeofOperatorWithStringType.js +++ b/tests/baselines/reference/typeofOperatorWithStringType.js @@ -60,19 +60,12 @@ z: typeof M.n; //// [typeofOperatorWithStringType.js] // typeof operator on string type var STRING; -var STRING1 = [ - "", - "abc" -]; -function foo() { - return "abc"; -} +var STRING1 = ["", "abc"]; +function foo() { return "abc"; } var A = (function () { function A() { } - A.foo = function () { - return ""; - }; + A.foo = function () { return ""; }; return A; })(); var M; @@ -85,16 +78,8 @@ var ResultIsString1 = typeof STRING; var ResultIsString2 = typeof STRING1; // string type literal var ResultIsString3 = typeof ""; -var ResultIsString4 = typeof { - x: "", - y: "" -}; -var ResultIsString5 = typeof { - x: "", - y: function (s) { - return s; - } -}; +var ResultIsString4 = typeof { x: "", y: "" }; +var ResultIsString5 = typeof { x: "", y: function (s) { return s; } }; // string type expressions var ResultIsString6 = typeof objA.a; var ResultIsString7 = typeof M.n; @@ -119,10 +104,7 @@ var r; z: typeof STRING; x: typeof STRING1; r: typeof foo; -var y = { - a: "", - b: "" -}; +var y = { a: "", b: "" }; z: typeof y.a; z: typeof objA.a; z: typeof A.foo; diff --git a/tests/baselines/reference/typesWithDuplicateTypeParameters.js b/tests/baselines/reference/typesWithDuplicateTypeParameters.js index f81f59d530..cc80d4d57b 100644 --- a/tests/baselines/reference/typesWithDuplicateTypeParameters.js +++ b/tests/baselines/reference/typesWithDuplicateTypeParameters.js @@ -19,7 +19,5 @@ var C2 = (function () { } return C2; })(); -function f() { -} -function f2() { -} +function f() { } +function f2() { } diff --git a/tests/baselines/reference/typesWithOptionalProperty.js b/tests/baselines/reference/typesWithOptionalProperty.js index 2056fab37e..7c791cd599 100644 --- a/tests/baselines/reference/typesWithOptionalProperty.js +++ b/tests/baselines/reference/typesWithOptionalProperty.js @@ -33,20 +33,9 @@ a = i; //// [typesWithOptionalProperty.js] // basic uses of optional properties without errors var a; -var b = { - foo: '' -}; -var c = { - foo: '', - bar: 3 -}; -var d = { - foo: '', - bar: 3, - baz: function () { - return ''; - } -}; +var b = { foo: '' }; +var c = { foo: '', bar: 3 }; +var d = { foo: '', bar: 3, baz: function () { return ''; } }; var i; i = b; i = c; diff --git a/tests/baselines/reference/uncaughtCompilerError1.js b/tests/baselines/reference/uncaughtCompilerError1.js index 39369c8e89..a09f8c949d 100644 --- a/tests/baselines/reference/uncaughtCompilerError1.js +++ b/tests/baselines/reference/uncaughtCompilerError1.js @@ -18,16 +18,10 @@ function f() { function f() { if (lineTokens[index].trim() === '=' && index > 0 && token.type === '' && tokens[index - 1].type === 'attribute.name.html') { if (index === (tokens.length - 1)) { - return { - appendText: '\"\"', - advanceCount: 1 - }; + return { appendText: '\"\"', advanceCount: 1 }; } else if (tokens[index + 1].type !== 'attribute.value.html' && tokens[index + 1].type !== '') { - return { - appendText: '\"\"', - advanceCount: 1 - }; + return { appendText: '\"\"', advanceCount: 1 }; } return null; } diff --git a/tests/baselines/reference/undeclaredMethod.js b/tests/baselines/reference/undeclaredMethod.js index b279593863..2cef06cc59 100644 --- a/tests/baselines/reference/undeclaredMethod.js +++ b/tests/baselines/reference/undeclaredMethod.js @@ -19,8 +19,7 @@ var M; var C = (function () { function C() { } - C.prototype.salt = function () { - }; + C.prototype.salt = function () { }; return C; })(); M.C = C; diff --git a/tests/baselines/reference/undeclaredModuleError.js b/tests/baselines/reference/undeclaredModuleError.js index e7e9b70ee7..0764840cad 100644 --- a/tests/baselines/reference/undeclaredModuleError.js +++ b/tests/baselines/reference/undeclaredModuleError.js @@ -17,8 +17,7 @@ function instrumentFile(covFileDir: string, covFileName: string, originalFilePat //// [undeclaredModuleError.js] define(["require", "exports", 'fs'], function (require, exports, fs) { - function readdir(path, accept, callback) { - } + function readdir(path, accept, callback) { } function join() { var paths = []; for (var _i = 0; _i < arguments.length; _i++) { diff --git a/tests/baselines/reference/undefinedArgumentInference.js b/tests/baselines/reference/undefinedArgumentInference.js index ad74e9ebeb..2e7501f23f 100644 --- a/tests/baselines/reference/undefinedArgumentInference.js +++ b/tests/baselines/reference/undefinedArgumentInference.js @@ -12,7 +12,4 @@ var z1 = foo1({ x: undefined, y: undefined }); function foo1(f1) { return undefined; } -var z1 = foo1({ - x: undefined, - y: undefined -}); +var z1 = foo1({ x: undefined, y: undefined }); diff --git a/tests/baselines/reference/undefinedIsSubtypeOfEverything.js b/tests/baselines/reference/undefinedIsSubtypeOfEverything.js index df87e7b0ad..b1ef3e19ed 100644 --- a/tests/baselines/reference/undefinedIsSubtypeOfEverything.js +++ b/tests/baselines/reference/undefinedIsSubtypeOfEverything.js @@ -250,8 +250,7 @@ var D11 = (function (_super) { } return D11; })(Base); -function f() { -} +function f() { } var f; (function (f) { f.bar = 1; diff --git a/tests/baselines/reference/undefinedSymbolReferencedInArrayLiteral1.js b/tests/baselines/reference/undefinedSymbolReferencedInArrayLiteral1.js index 61f248e56e..f314f9ad11 100644 --- a/tests/baselines/reference/undefinedSymbolReferencedInArrayLiteral1.js +++ b/tests/baselines/reference/undefinedSymbolReferencedInArrayLiteral1.js @@ -9,18 +9,8 @@ var functions = [function() { //// [undefinedSymbolReferencedInArrayLiteral1.js] -var tokens = [ - { - startIndex: deltaOffset - } -]; -var functions = [ - function () { - [ - 1, - 2, - 3 - ].NonexistantMethod(); +var tokens = [{ startIndex: deltaOffset }]; +var functions = [function () { + [1, 2, 3].NonexistantMethod(); anotherNonExistingMethod(); - } -]; + }]; diff --git a/tests/baselines/reference/underscoreTest1.js b/tests/baselines/reference/underscoreTest1.js index bc6bf9b615..ddd5201b85 100644 --- a/tests/baselines/reference/underscoreTest1.js +++ b/tests/baselines/reference/underscoreTest1.js @@ -904,428 +904,73 @@ _.template("Using 'with': <%= data.answer %>", { answer: 'no' }, { variable: 'da //// [underscoreTest1_underscore.js] //// [underscoreTest1_underscoreTests.js] /// -_.each([ - 1, - 2, - 3 -], function (num) { - return alert(num.toString()); -}); -_.each({ - one: 1, - two: 2, - three: 3 -}, function (value, key) { - return alert(value.toString()); -}); -_.map([ - 1, - 2, - 3 -], function (num) { - return num * 3; -}); -_.map({ - one: 1, - two: 2, - three: 3 -}, function (value, key) { - return value * 3; -}); -var sum = _.reduce([ - 1, - 2, - 3 -], function (memo, num) { - return memo + num; -}, 0); -var list = [ - [ - 0, - 1 - ], - [ - 2, - 3 - ], - [ - 4, - 5 - ] -]; -var flat = _.reduceRight(list, function (a, b) { - return a.concat(b); -}, []); -var even = _.find([ - 1, - 2, - 3, - 4, - 5, - 6 -], function (num) { - return num % 2 == 0; -}); -var evens = _.filter([ - 1, - 2, - 3, - 4, - 5, - 6 -], function (num) { - return num % 2 == 0; -}); -var listOfPlays = [ - { - title: "Cymbeline", - author: "Shakespeare", - year: 1611 - }, - { - title: "The Tempest", - author: "Shakespeare", - year: 1611 - }, - { - title: "Other", - author: "Not Shakespeare", - year: 2012 - } -]; -_.where(listOfPlays, { - author: "Shakespeare", - year: 1611 -}); -var odds = _.reject([ - 1, - 2, - 3, - 4, - 5, - 6 -], function (num) { - return num % 2 == 0; -}); -_.all([ - true, - 1, - null, - 'yes' -], _.identity); -_.any([ - null, - 0, - 'yes', - false -]); -_.contains([ - 1, - 2, - 3 -], 3); -_.invoke([ - [ - 5, - 1, - 7 - ], - [ - 3, - 2, - 1 - ] -], 'sort'); -var stooges = [ - { - name: 'moe', - age: 40 - }, - { - name: 'larry', - age: 50 - }, - { - name: 'curly', - age: 60 - } -]; +_.each([1, 2, 3], function (num) { return alert(num.toString()); }); +_.each({ one: 1, two: 2, three: 3 }, function (value, key) { return alert(value.toString()); }); +_.map([1, 2, 3], function (num) { return num * 3; }); +_.map({ one: 1, two: 2, three: 3 }, function (value, key) { return value * 3; }); +var sum = _.reduce([1, 2, 3], function (memo, num) { return memo + num; }, 0); +var list = [[0, 1], [2, 3], [4, 5]]; +var flat = _.reduceRight(list, function (a, b) { return a.concat(b); }, []); +var even = _.find([1, 2, 3, 4, 5, 6], function (num) { return num % 2 == 0; }); +var evens = _.filter([1, 2, 3, 4, 5, 6], function (num) { return num % 2 == 0; }); +var listOfPlays = [{ title: "Cymbeline", author: "Shakespeare", year: 1611 }, { title: "The Tempest", author: "Shakespeare", year: 1611 }, { title: "Other", author: "Not Shakespeare", year: 2012 }]; +_.where(listOfPlays, { author: "Shakespeare", year: 1611 }); +var odds = _.reject([1, 2, 3, 4, 5, 6], function (num) { return num % 2 == 0; }); +_.all([true, 1, null, 'yes'], _.identity); +_.any([null, 0, 'yes', false]); +_.contains([1, 2, 3], 3); +_.invoke([[5, 1, 7], [3, 2, 1]], 'sort'); +var stooges = [{ name: 'moe', age: 40 }, { name: 'larry', age: 50 }, { name: 'curly', age: 60 }]; _.pluck(stooges, 'name'); -_.max(stooges, function (stooge) { - return stooge.age; -}); -var numbers = [ - 10, - 5, - 100, - 2, - 1000 -]; +_.max(stooges, function (stooge) { return stooge.age; }); +var numbers = [10, 5, 100, 2, 1000]; _.min(numbers); -_.sortBy([ - 1, - 2, - 3, - 4, - 5, - 6 -], function (num) { - return Math.sin(num); -}); +_.sortBy([1, 2, 3, 4, 5, 6], function (num) { return Math.sin(num); }); // not sure how this is typechecking at all.. Math.floor(e) is number not string..? -_([ - 1.3, - 2.1, - 2.4 -]).groupBy(function (e, i, list) { - return Math.floor(e); -}); -_.groupBy([ - 1.3, - 2.1, - 2.4 -], function (num) { - return Math.floor(num); -}); -_.groupBy([ - 'one', - 'two', - 'three' -], 'length'); -_.countBy([ - 1, - 2, - 3, - 4, - 5 -], function (num) { - return num % 2 == 0 ? 'even' : 'odd'; -}); -_.shuffle([ - 1, - 2, - 3, - 4, - 5, - 6 -]); +_([1.3, 2.1, 2.4]).groupBy(function (e, i, list) { return Math.floor(e); }); +_.groupBy([1.3, 2.1, 2.4], function (num) { return Math.floor(num); }); +_.groupBy(['one', 'two', 'three'], 'length'); +_.countBy([1, 2, 3, 4, 5], function (num) { return num % 2 == 0 ? 'even' : 'odd'; }); +_.shuffle([1, 2, 3, 4, 5, 6]); // (function(){ return _.toArray(arguments).slice(1); })(1, 2, 3, 4); -_.size({ - one: 1, - two: 2, - three: 3 -}); +_.size({ one: 1, two: 2, three: 3 }); /////////////////////////////////////////////////////////////////////////////////////// -_.first([ - 5, - 4, - 3, - 2, - 1 -]); -_.initial([ - 5, - 4, - 3, - 2, - 1 -]); -_.last([ - 5, - 4, - 3, - 2, - 1 -]); -_.rest([ - 5, - 4, - 3, - 2, - 1 -]); -_.compact([ - 0, - 1, - false, - 2, - '', - 3 -]); -_.flatten([ - 1, - 2, - 3, - 4 -]); -_.flatten([ - 1, - [ - 2 - ] -]); +_.first([5, 4, 3, 2, 1]); +_.initial([5, 4, 3, 2, 1]); +_.last([5, 4, 3, 2, 1]); +_.rest([5, 4, 3, 2, 1]); +_.compact([0, 1, false, 2, '', 3]); +_.flatten([1, 2, 3, 4]); +_.flatten([1, [2]]); // typescript doesn't like the elements being different -_.flatten([ - 1, - [ - 2 - ], - [ - 3, - [ - [ - 4 - ] - ] - ] -]); -_.flatten([ - 1, - [ - 2 - ], - [ - 3, - [ - [ - 4 - ] - ] - ] -], true); -_.without([ - 1, - 2, - 1, - 0, - 3, - 1, - 4 -], 0, 1); -_.union([ - 1, - 2, - 3 -], [ - 101, - 2, - 1, - 10 -], [ - 2, - 1 -]); -_.intersection([ - 1, - 2, - 3 -], [ - 101, - 2, - 1, - 10 -], [ - 2, - 1 -]); -_.difference([ - 1, - 2, - 3, - 4, - 5 -], [ - 5, - 2, - 10 -]); -_.uniq([ - 1, - 2, - 1, - 3, - 1, - 4 -]); -_.zip([ - 'moe', - 'larry', - 'curly' -], [ - 30, - 40, - 50 -], [ - true, - false, - false -]); -_.object([ - 'moe', - 'larry', - 'curly' -], [ - 30, - 40, - 50 -]); -_.object([ - [ - 'moe', - 30 - ], - [ - 'larry', - 40 - ], - [ - 'curly', - 50 - ] -]); -_.indexOf([ - 1, - 2, - 3 -], 2); -_.lastIndexOf([ - 1, - 2, - 3, - 1, - 2, - 3 -], 2); -_.sortedIndex([ - 10, - 20, - 30, - 40, - 50 -], 35); +_.flatten([1, [2], [3, [[4]]]]); +_.flatten([1, [2], [3, [[4]]]], true); +_.without([1, 2, 1, 0, 3, 1, 4], 0, 1); +_.union([1, 2, 3], [101, 2, 1, 10], [2, 1]); +_.intersection([1, 2, 3], [101, 2, 1, 10], [2, 1]); +_.difference([1, 2, 3, 4, 5], [5, 2, 10]); +_.uniq([1, 2, 1, 3, 1, 4]); +_.zip(['moe', 'larry', 'curly'], [30, 40, 50], [true, false, false]); +_.object(['moe', 'larry', 'curly'], [30, 40, 50]); +_.object([['moe', 30], ['larry', 40], ['curly', 50]]); +_.indexOf([1, 2, 3], 2); +_.lastIndexOf([1, 2, 3, 1, 2, 3], 2); +_.sortedIndex([10, 20, 30, 40, 50], 35); _.range(10); _.range(1, 11); _.range(0, 30, 5); _.range(0, 30, 5); _.range(0); /////////////////////////////////////////////////////////////////////////////////////// -var func = function (greeting) { - return greeting + ': ' + this.name; -}; +var func = function (greeting) { return greeting + ': ' + this.name; }; // need a second var otherwise typescript thinks func signature is the above func type, // instead of the newly returned _bind => func type. -var func2 = _.bind(func, { - name: 'moe' -}, 'hi'); +var func2 = _.bind(func, { name: 'moe' }, 'hi'); func2(); var buttonView = { label: 'underscore', - onClick: function () { - alert('clicked: ' + this.label); - }, - onHover: function () { - alert('hovering: ' + this.label); - } + onClick: function () { alert('clicked: ' + this.label); }, + onHover: function () { alert('hovering: ' + this.label); } }; _.bindAll(buttonView); $('#underscore_button').bind('click', buttonView.onClick); @@ -1339,153 +984,59 @@ var log = _.bind(function (message) { } }, Date); _.delay(log, 1000, 'logged later'); -_.defer(function () { - alert('deferred'); -}); -var updatePosition = function () { - return alert('updating position...'); -}; +_.defer(function () { alert('deferred'); }); +var updatePosition = function () { return alert('updating position...'); }; var throttled = _.throttle(updatePosition, 100); $(null).scroll(throttled); -var calculateLayout = function () { - return alert('calculating layout...'); -}; +var calculateLayout = function () { return alert('calculating layout...'); }; var lazyLayout = _.debounce(calculateLayout, 300); $(null).resize(lazyLayout); -var createApplication = function () { - return alert('creating application...'); -}; +var createApplication = function () { return alert('creating application...'); }; var initialize = _.once(createApplication); initialize(); initialize(); var notes; -var render = function () { - return alert("rendering..."); -}; +var render = function () { return alert("rendering..."); }; var renderNotes = _.after(notes.length, render); -_.each(notes, function (note) { - return note.asyncSave({ - success: renderNotes - }); -}); -var hello = function (name) { - return "hello: " + name; -}; -hello = _.wrap(hello, function (func, arg) { - return "before, " + func(arg) + ", after"; -}); +_.each(notes, function (note) { return note.asyncSave({ success: renderNotes }); }); +var hello = function (name) { return "hello: " + name; }; +hello = _.wrap(hello, function (func, arg) { return "before, " + func(arg) + ", after"; }); hello("moe"); -var greet = function (name) { - return "hi: " + name; -}; -var exclaim = function (statement) { - return statement + "!"; -}; +var greet = function (name) { return "hi: " + name; }; +var exclaim = function (statement) { return statement + "!"; }; var welcome = _.compose(exclaim, greet); welcome('moe'); /////////////////////////////////////////////////////////////////////////////////////// -_.keys({ - one: 1, - two: 2, - three: 3 -}); -_.values({ - one: 1, - two: 2, - three: 3 -}); -_.pairs({ - one: 1, - two: 2, - three: 3 -}); -_.invert({ - Moe: "Moses", - Larry: "Louis", - Curly: "Jerome" -}); +_.keys({ one: 1, two: 2, three: 3 }); +_.values({ one: 1, two: 2, three: 3 }); +_.pairs({ one: 1, two: 2, three: 3 }); +_.invert({ Moe: "Moses", Larry: "Louis", Curly: "Jerome" }); _.functions(_); -_.extend({ - name: 'moe' -}, { - age: 50 -}); -_.pick({ - name: 'moe', - age: 50, - userid: 'moe1' -}, 'name', 'age'); -_.omit({ - name: 'moe', - age: 50, - userid: 'moe1' -}, 'userid'); -var iceCream = { - flavor: "chocolate" -}; -_.defaults(iceCream, { - flavor: "vanilla", - sprinkles: "lots" -}); -_.clone({ - name: 'moe' -}); -_.chain([ - 1, - 2, - 3, - 200 -]).filter(function (num) { - return num % 2 == 0; -}).tap(alert).map(function (num) { - return num * num; -}).value(); -_.has({ - a: 1, - b: 2, - c: 3 -}, "b"); -var moe = { - name: 'moe', - luckyNumbers: [ - 13, - 27, - 34 - ] -}; -var clone = { - name: 'moe', - luckyNumbers: [ - 13, - 27, - 34 - ] -}; +_.extend({ name: 'moe' }, { age: 50 }); +_.pick({ name: 'moe', age: 50, userid: 'moe1' }, 'name', 'age'); +_.omit({ name: 'moe', age: 50, userid: 'moe1' }, 'userid'); +var iceCream = { flavor: "chocolate" }; +_.defaults(iceCream, { flavor: "vanilla", sprinkles: "lots" }); +_.clone({ name: 'moe' }); +_.chain([1, 2, 3, 200]) + .filter(function (num) { return num % 2 == 0; }) + .tap(alert) + .map(function (num) { return num * num; }) + .value(); +_.has({ a: 1, b: 2, c: 3 }, "b"); +var moe = { name: 'moe', luckyNumbers: [13, 27, 34] }; +var clone = { name: 'moe', luckyNumbers: [13, 27, 34] }; moe == clone; _.isEqual(moe, clone); -_.isEmpty([ - 1, - 2, - 3 -]); +_.isEmpty([1, 2, 3]); _.isEmpty({}); _.isElement($('body')[0]); -(function () { - return _.isArray(arguments); -})(); -_.isArray([ - 1, - 2, - 3 -]); +(function () { return _.isArray(arguments); })(); +_.isArray([1, 2, 3]); _.isObject({}); _.isObject(1); // (() => { return _.isArguments(arguments); })(1, 2, 3); -_.isArguments([ - 1, - 2, - 3 -]); +_.isArguments([1, 2, 3]); _.isFunction(alert); _.isString("moe"); _.isNumber(8.4 * 5); @@ -1502,14 +1053,10 @@ _.isNull(undefined); _.isUndefined(null.missingVariable); /////////////////////////////////////////////////////////////////////////////////////// var underscore = _.noConflict(); -var moe2 = { - name: 'moe' -}; +var moe2 = { name: 'moe' }; moe2 === _.identity(moe); var genie; -_.times(3, function (n) { - genie.grantWishNumber(n); -}); +_.times(3, function (n) { genie.grantWishNumber(n); }); _.random(0, 100); _.mixin({ capitalize: function (string) { @@ -1519,43 +1066,20 @@ _.mixin({ _("fabio").capitalize(); _.uniqueId('contact_'); _.escape('Curly, Larry & Moe'); -var object = { - cheese: 'crumpets', - stuff: function () { - return 'nonsense'; - } -}; +var object = { cheese: 'crumpets', stuff: function () { return 'nonsense'; } }; _.result(object, 'cheese'); _.result(object, 'stuff'); var compiled = _.template("hello: <%= name %>"); -compiled({ - name: 'moe' -}); +compiled({ name: 'moe' }); var list2 = "<% _.each(people, function(name) { %>
  • <%= name %>
  • <% }); %>"; -_.template(list2, { - people: [ - 'moe', - 'curly', - 'larry' - ] -}); +_.template(list2, { people: ['moe', 'curly', 'larry'] }); var template = _.template("<%- value %>"); -template({ - value: '