diff --git a/_infrastructure/tests/runner.js b/_infrastructure/tests/runner.js
index 2999c057f..502b15e93 100644
--- a/_infrastructure/tests/runner.js
+++ b/_infrastructure/tests/runner.js
@@ -1,1108 +1,1108 @@
-//
-// Copyright (c) Microsoft Corporation. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-var ExecResult = (function () {
- function ExecResult() {
- this.stdout = "";
- this.stderr = "";
- }
- return ExecResult;
-})();
-
-var WindowsScriptHostExec = (function () {
- function WindowsScriptHostExec() {
- }
- WindowsScriptHostExec.prototype.exec = function (filename, cmdLineArgs, handleResult) {
- var result = new ExecResult();
- var shell = new ActiveXObject('WScript.Shell');
- try {
- var process = shell.Exec(filename + ' ' + cmdLineArgs.join(' '));
- } catch (e) {
- result.stderr = e.message;
- result.exitCode = 1;
- handleResult(result);
- return;
- }
-
- while (process.Status != 0) {
- }
-
- result.exitCode = process.ExitCode;
- if (!process.StdOut.AtEndOfStream)
- result.stdout = process.StdOut.ReadAll();
- if (!process.StdErr.AtEndOfStream)
- result.stderr = process.StdErr.ReadAll();
-
- handleResult(result);
- };
- return WindowsScriptHostExec;
-})();
-
-var NodeExec = (function () {
- function NodeExec() {
- }
- NodeExec.prototype.exec = function (filename, cmdLineArgs, handleResult) {
- var nodeExec = require('child_process').exec;
-
- var result = new ExecResult();
- result.exitCode = null;
- var cmdLine = filename + ' ' + cmdLineArgs.join(' ');
-
- var process = nodeExec(cmdLine, function (error, stdout, stderr) {
- result.stdout = stdout;
- result.stderr = stderr;
- result.exitCode = error ? error.code : 0;
- handleResult(result);
- });
- };
- return NodeExec;
-})();
-
-var Exec = (function () {
- var global = Function("return this;").call(null);
- if (typeof global.ActiveXObject !== "undefined") {
- return new WindowsScriptHostExec();
- } else {
- return new NodeExec();
- }
-})();
-//
-// Copyright (c) Microsoft Corporation. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-var IOUtils;
-(function (IOUtils) {
- // Creates the directory including its parent if not already present
- function createDirectoryStructure(ioHost, dirName) {
- if (ioHost.directoryExists(dirName)) {
- return;
- }
-
- var parentDirectory = ioHost.dirName(dirName);
- if (parentDirectory != "") {
- createDirectoryStructure(ioHost, parentDirectory);
- }
- ioHost.createDirectory(dirName);
- }
-
- // Creates a file including its directory structure if not already present
- function createFileAndFolderStructure(ioHost, fileName, useUTF8) {
- var path = ioHost.resolvePath(fileName);
- var dirName = ioHost.dirName(path);
- createDirectoryStructure(ioHost, dirName);
- return ioHost.createFile(path, useUTF8);
- }
- IOUtils.createFileAndFolderStructure = createFileAndFolderStructure;
-
- function throwIOError(message, error) {
- var errorMessage = message;
- if (error && error.message) {
- errorMessage += (" " + error.message);
- }
- throw new Error(errorMessage);
- }
- IOUtils.throwIOError = throwIOError;
-})(IOUtils || (IOUtils = {}));
-
-var IO = (function () {
- // Create an IO object for use inside WindowsScriptHost hosts
- // Depends on WSCript and FileSystemObject
- function getWindowsScriptHostIO() {
- var fso = new ActiveXObject("Scripting.FileSystemObject");
- var streamObjectPool = [];
-
- function getStreamObject() {
- if (streamObjectPool.length > 0) {
- return streamObjectPool.pop();
- } else {
- return new ActiveXObject("ADODB.Stream");
- }
- }
-
- function releaseStreamObject(obj) {
- streamObjectPool.push(obj);
- }
-
- var args = [];
- for (var i = 0; i < WScript.Arguments.length; i++) {
- args[i] = WScript.Arguments.Item(i);
- }
-
- return {
- readFile: function (path) {
- try {
- var streamObj = getStreamObject();
- streamObj.Open();
- streamObj.Type = 2;
- streamObj.Charset = 'x-ansi';
- streamObj.LoadFromFile(path);
- var bomChar = streamObj.ReadText(2);
- streamObj.Position = 0;
- if ((bomChar.charCodeAt(0) == 0xFE && bomChar.charCodeAt(1) == 0xFF) || (bomChar.charCodeAt(0) == 0xFF && bomChar.charCodeAt(1) == 0xFE)) {
- streamObj.Charset = 'unicode';
- } else if (bomChar.charCodeAt(0) == 0xEF && bomChar.charCodeAt(1) == 0xBB) {
- streamObj.Charset = 'utf-8';
- }
-
- // Read the whole file
- var str = streamObj.ReadText(-1);
- streamObj.Close();
- releaseStreamObject(streamObj);
- return str;
- } catch (err) {
- IOUtils.throwIOError("Error reading file \"" + path + "\".", err);
- }
- },
- writeFile: function (path, contents) {
- var file = this.createFile(path);
- file.Write(contents);
- file.Close();
- },
- fileExists: function (path) {
- return fso.FileExists(path);
- },
- resolvePath: function (path) {
- return fso.GetAbsolutePathName(path);
- },
- dirName: function (path) {
- return fso.GetParentFolderName(path);
- },
- findFile: function (rootPath, partialFilePath) {
- var path = fso.GetAbsolutePathName(rootPath) + "/" + partialFilePath;
-
- while (true) {
- if (fso.FileExists(path)) {
- try {
- var content = this.readFile(path);
- return { content: content, path: path };
- } catch (err) {
- //Tools.CompilerDiagnostics.debugPrint("Could not find " + path + ", trying parent");
- }
- } else {
- rootPath = fso.GetParentFolderName(fso.GetAbsolutePathName(rootPath));
-
- if (rootPath == "") {
- return null;
- } else {
- path = fso.BuildPath(rootPath, partialFilePath);
- }
- }
- }
- },
- deleteFile: function (path) {
- try {
- if (fso.FileExists(path)) {
- fso.DeleteFile(path, true);
- }
- } catch (e) {
- IOUtils.throwIOError("Couldn't delete file '" + path + "'.", e);
- }
- },
- createFile: function (path, useUTF8) {
- try {
- var streamObj = getStreamObject();
- streamObj.Charset = useUTF8 ? 'utf-8' : 'x-ansi';
- streamObj.Open();
- return {
- Write: function (str) {
- streamObj.WriteText(str, 0);
- },
- WriteLine: function (str) {
- streamObj.WriteText(str, 1);
- },
- Close: function () {
- try {
- streamObj.SaveToFile(path, 2);
- } catch (saveError) {
- IOUtils.throwIOError("Couldn't write to file '" + path + "'.", saveError);
- } finally {
- if (streamObj.State != 0) {
- streamObj.Close();
- }
- releaseStreamObject(streamObj);
- }
- }
- };
- } catch (creationError) {
- IOUtils.throwIOError("Couldn't write to file '" + path + "'.", creationError);
- }
- },
- directoryExists: function (path) {
- return fso.FolderExists(path);
- },
- createDirectory: function (path) {
- try {
- if (!this.directoryExists(path)) {
- fso.CreateFolder(path);
- }
- } catch (e) {
- IOUtils.throwIOError("Couldn't create directory '" + path + "'.", e);
- }
- },
- dir: function (path, spec, options) {
- options = options || {};
- function filesInFolder(folder, root) {
- var paths = [];
- var fc;
-
- if (options.recursive) {
- fc = new Enumerator(folder.subfolders);
-
- for (; !fc.atEnd(); fc.moveNext()) {
- paths = paths.concat(filesInFolder(fc.item(), root + "/" + fc.item().Name));
- }
- }
-
- fc = new Enumerator(folder.files);
-
- for (; !fc.atEnd(); fc.moveNext()) {
- if (!spec || fc.item().Name.match(spec)) {
- paths.push(root + "/" + fc.item().Name);
- }
- }
-
- return paths;
- }
-
- var folder = fso.GetFolder(path);
- var paths = [];
-
- return filesInFolder(folder, path);
- },
- print: function (str) {
- WScript.StdOut.Write(str);
- },
- printLine: function (str) {
- WScript.Echo(str);
- },
- arguments: args,
- stderr: WScript.StdErr,
- stdout: WScript.StdOut,
- watchFile: null,
- run: function (source, filename) {
- try {
- eval(source);
- } catch (e) {
- IOUtils.throwIOError("Error while executing file '" + filename + "'.", e);
- }
- },
- getExecutingFilePath: function () {
- return WScript.ScriptFullName;
- },
- quit: function (exitCode) {
- if (typeof exitCode === "undefined") { exitCode = 0; }
- try {
- WScript.Quit(exitCode);
- } catch (e) {
- }
- }
- };
- }
- ;
-
- // Create an IO object for use inside Node.js hosts
- // Depends on 'fs' and 'path' modules
- function getNodeIO() {
- var _fs = require('fs');
- var _path = require('path');
- var _module = require('module');
-
- return {
- readFile: function (file) {
- try {
- var buffer = _fs.readFileSync(file);
- switch (buffer[0]) {
- case 0xFE:
- if (buffer[1] == 0xFF) {
- // utf16-be. Reading the buffer as big endian is not supported, so convert it to
- // Little Endian first
- var i = 0;
- while ((i + 1) < buffer.length) {
- var temp = buffer[i];
- buffer[i] = buffer[i + 1];
- buffer[i + 1] = temp;
- i += 2;
- }
- return buffer.toString("ucs2", 2);
- }
- break;
- case 0xFF:
- if (buffer[1] == 0xFE) {
- // utf16-le
- return buffer.toString("ucs2", 2);
- }
- break;
- case 0xEF:
- if (buffer[1] == 0xBB) {
- // utf-8
- return buffer.toString("utf8", 3);
- }
- }
-
- // Default behaviour
- return buffer.toString();
- } catch (e) {
- IOUtils.throwIOError("Error reading file \"" + file + "\".", e);
- }
- },
- writeFile: _fs.writeFileSync,
- deleteFile: function (path) {
- try {
- _fs.unlinkSync(path);
- } catch (e) {
- IOUtils.throwIOError("Couldn't delete file '" + path + "'.", e);
- }
- },
- fileExists: function (path) {
- return _fs.existsSync(path);
- },
- createFile: function (path, useUTF8) {
- function mkdirRecursiveSync(path) {
- var stats = _fs.statSync(path);
- if (stats.isFile()) {
- IOUtils.throwIOError("\"" + path + "\" exists but isn't a directory.", null);
- } else if (stats.isDirectory()) {
- return;
- } else {
- mkdirRecursiveSync(_path.dirname(path));
- _fs.mkdirSync(path, 0775);
- }
- }
-
- mkdirRecursiveSync(_path.dirname(path));
-
- try {
- var fd = _fs.openSync(path, 'w');
- } catch (e) {
- IOUtils.throwIOError("Couldn't write to file '" + path + "'.", e);
- }
- return {
- Write: function (str) {
- _fs.writeSync(fd, str);
- },
- WriteLine: function (str) {
- _fs.writeSync(fd, str + '\r\n');
- },
- Close: function () {
- _fs.closeSync(fd);
- fd = null;
- }
- };
- },
- dir: function dir(path, spec, options) {
- options = options || {};
-
- function filesInFolder(folder, deep) {
- var paths = [];
-
- var files = _fs.readdirSync(folder);
- for (var i = 0; i < files.length; i++) {
- var stat = _fs.statSync(folder + "/" + files[i]);
- if (options.recursive && stat.isDirectory()) {
- if (deep < (options.deep || 100)) {
- paths = paths.concat(filesInFolder(folder + "/" + files[i], 1));
- }
- } else if (stat.isFile() && (!spec || files[i].match(spec))) {
- paths.push(folder + "/" + files[i]);
- }
- }
-
- return paths;
- }
-
- return filesInFolder(path, 0);
- },
- createDirectory: function (path) {
- try {
- if (!this.directoryExists(path)) {
- _fs.mkdirSync(path);
- }
- } catch (e) {
- IOUtils.throwIOError("Couldn't create directory '" + path + "'.", e);
- }
- },
- directoryExists: function (path) {
- return _fs.existsSync(path) && _fs.lstatSync(path).isDirectory();
- },
- resolvePath: function (path) {
- return _path.resolve(path);
- },
- dirName: function (path) {
- return _path.dirname(path);
- },
- findFile: function (rootPath, partialFilePath) {
- var path = rootPath + "/" + partialFilePath;
-
- while (true) {
- if (_fs.existsSync(path)) {
- try {
- var content = this.readFile(path);
- return { content: content, path: path };
- } catch (err) {
- //Tools.CompilerDiagnostics.debugPrint(("Could not find " + path) + ", trying parent");
- }
- } else {
- var parentPath = _path.resolve(rootPath, "..");
-
- if (rootPath === parentPath) {
- return null;
- } else {
- rootPath = parentPath;
- path = _path.resolve(rootPath, partialFilePath);
- }
- }
- }
- },
- print: function (str) {
- process.stdout.write(str);
- },
- printLine: function (str) {
- process.stdout.write(str + '\n');
- },
- arguments: process.argv.slice(2),
- stderr: {
- Write: function (str) {
- process.stderr.write(str);
- },
- WriteLine: function (str) {
- process.stderr.write(str + '\n');
- },
- Close: function () {
- }
- },
- stdout: {
- Write: function (str) {
- process.stdout.write(str);
- },
- WriteLine: function (str) {
- process.stdout.write(str + '\n');
- },
- Close: function () {
- }
- },
- watchFile: function (filename, callback) {
- var firstRun = true;
- var processingChange = false;
-
- var fileChanged = function (curr, prev) {
- if (!firstRun) {
- if (curr.mtime < prev.mtime) {
- return;
- }
-
- _fs.unwatchFile(filename, fileChanged);
- if (!processingChange) {
- processingChange = true;
- callback(filename);
- setTimeout(function () {
- processingChange = false;
- }, 100);
- }
- }
- firstRun = false;
- _fs.watchFile(filename, { persistent: true, interval: 500 }, fileChanged);
- };
-
- fileChanged();
- return {
- filename: filename,
- close: function () {
- _fs.unwatchFile(filename, fileChanged);
- }
- };
- },
- run: function (source, filename) {
- require.main.filename = filename;
- require.main.paths = _module._nodeModulePaths(_path.dirname(_fs.realpathSync(filename)));
- require.main._compile(source, filename);
- },
- getExecutingFilePath: function () {
- return process.mainModule.filename;
- },
- quit: process.exit
- };
- }
- ;
-
- if (typeof ActiveXObject === "function")
- return getWindowsScriptHostIO();
-else if (typeof require === "function")
- return getNodeIO();
-else
- return null;
-})();
-///
-///
-var DefinitelyTyped;
-(function (DefinitelyTyped) {
- (function (TestManager) {
- var path = require('path');
-
- function endsWith(str, suffix) {
- return str.indexOf(suffix, str.length - suffix.length) !== -1;
- }
-
- var Iterator = (function () {
- function Iterator(list) {
- this.list = list;
- this.index = -1;
- }
- Iterator.prototype.next = function () {
- this.index++;
- return this.list[this.index];
- };
-
- Iterator.prototype.hasNext = function () {
- return this.list[1 + this.index] != null;
- };
- return Iterator;
- })();
-
- var Tsc = (function () {
- function Tsc() {
- }
- Tsc.run = function (tsfile, callback) {
- var command = 'node ./_infrastructure/tests/typescript/tsc.js --module commonjs ';
- if (IO.fileExists(tsfile + '.tscparams')) {
- command += '@' + tsfile + '.tscparams';
- }
- Exec.exec(command, [tsfile], function (ExecResult) {
- callback(ExecResult);
- });
- };
- return Tsc;
- })();
-
- var Test = (function () {
- function Test(tsfile) {
- this.tsfile = tsfile;
- }
- Test.prototype.run = function (callback) {
- Tsc.run(this.tsfile, callback);
- };
- return Test;
- })();
-
- var Typing = (function () {
- function Typing(name, baseDir) {
- this.name = name;
- this.fileHandler = new FileHandler(baseDir + '/' + name + '/', /.\.ts/g);
- }
- return Typing;
- })();
-
- var FileHandler = (function () {
- function FileHandler(path, pattern) {
- this.path = path;
- this.files = [];
- this.typings = [];
- this.files = IO.dir(path, pattern, { recursive: true }).sort();
- }
- FileHandler.prototype.allTS = function () {
- return this.files;
- };
-
- FileHandler.prototype.allTests = function () {
- var tests = [];
-
- for (var i = 0; i < this.files.length; i++) {
- if (endsWith(this.files[i].toUpperCase(), '-TESTS.TS')) {
- tests.push(this.files[i]);
- }
- }
-
- return tests;
- };
-
- FileHandler.prototype.allTypings = function () {
- var typings = {};
-
- for (var i = 0; i < this.files.length; i++) {
- var file = this.files[i];
- var firName = path.dirname(file.substr(this.path.length + 1)).replace('\\', '/');
- var dir = firName.split('/')[0];
-
- if (!typings[dir])
- typings[dir] = true;
- }
-
- var list = [];
- for (var attr in typings) {
- list.push(attr);
- }
-
- return list;
- };
- return FileHandler;
- })();
-
- var Timer = (function () {
- function Timer() {
- this.time = 0;
- }
- Timer.prettyDate = function (date1, date2) {
- var diff = ((date2 - date1) / 1000), day_diff = Math.floor(diff / 86400);
-
- if (isNaN(day_diff) || day_diff < 0 || day_diff >= 31)
- return;
-
- return (day_diff == 0 && (diff < 60 && (diff + " secconds") || diff < 120 && "1 minute" || diff < 3600 && Math.floor(diff / 60) + " minutes" || diff < 7200 && "1 hour" || diff < 86400 && Math.floor(diff / 3600) + " hours") || day_diff == 1 && "Yesterday" || day_diff < 7 && day_diff + " days" || day_diff < 31 && Math.ceil(day_diff / 7) + " weeks");
- };
-
- Timer.prototype.start = function () {
- this.time = 0;
- this.startTime = this.now();
- };
-
- Timer.prototype.now = function () {
- return Date.now();
- };
-
- Timer.prototype.end = function () {
- this.time = (this.now() - this.startTime) / 1000;
- this.asString = Timer.prettyDate(this.startTime, this.now());
- };
- return Timer;
- })();
-
- var Print = (function () {
- function Print(version, typings, tsFiles) {
- this.version = version;
- this.typings = typings;
- this.tsFiles = tsFiles;
- }
- Print.prototype.out = function (s) {
- process.stdout.write(s);
- };
-
- Print.prototype.printHeader = function () {
- this.out('=============================================================================\n');
- this.out(' \33[36m\33[1mDefinitelyTyped test runner 0.2.1\33[0m\n');
- this.out('=============================================================================\n');
- this.out(' \33[36m\33[1mTypescript version:\33[0m ' + this.version + '\n');
- this.out(' \33[36m\33[1mTypings :\33[0m ' + this.typings + '\n');
- this.out(' \33[36m\33[1mTypeScript files :\33[0m ' + this.tsFiles + '\n');
- };
-
- Print.prototype.printSyntaxChecking = function () {
- this.out('============================ \33[34m\33[1mSyntax checking\33[0m ================================\n');
- };
-
- Print.prototype.printTypingTests = function () {
- this.out('============================= \33[34m\33[1mTyping tests\33[0m ==================================\n');
- };
-
- Print.prototype.printSuccess = function () {
- this.out('\33[36m\33[1m.\33[0m');
- };
-
- Print.prototype.printFailure = function () {
- this.out('x');
- };
-
- Print.prototype.printDiv = function () {
- this.out('-----------------------------------------------------------------------------\n');
- };
-
- Print.prototype.printfilesWithSintaxErrorMessage = function () {
- this.out(' \33[36m\33[1mFiles with syntax error\33[0m\n');
- };
-
- Print.prototype.printFailedTestMessage = function () {
- this.out(' \33[36m\33[1mFailed tests\33[0m\n');
- };
-
- Print.prototype.printTypingsWithoutTestsMessage = function () {
- this.out(' \33[36m\33[1mTyping without tests\33[0m\n');
- };
-
- Print.prototype.printTotalMessage = function () {
- this.out(' \33[36m\33[1mTotal\33[0m\n');
- };
-
- Print.prototype.printErrorFile = function (file) {
- this.out(' - ' + file + '\n');
- };
-
- Print.prototype.printTypingsWithoutTest = function (file) {
- this.out(' - \33[33m\33[1m' + file + '\33[0m\n');
- };
-
- Print.prototype.breack = function () {
- this.out('\n');
- };
-
- Print.prototype.printSuccessCount = function (current, total) {
- this.out(' \33[36m\33[1mSuccessful :\33[0m \33[32m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
- };
-
- Print.prototype.printFailedCount = function (current, total) {
- this.out(' \33[36m\33[1mFailure :\33[0m \33[31m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
- };
-
- Print.prototype.printElapsedTime = function (time, s) {
- this.out(' \33[36m\33[1mElapsed time :\33[0m ~' + time + ' (' + s + 's)\n');
- };
-
- Print.prototype.printSyntaxErrorCount = function (current, total) {
- this.out(' \33[36m\33[1mSyntax error :\33[0m \33[31m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
- };
-
- Print.prototype.printTestErrorCount = function (current, total) {
- this.out(' \33[36m\33[1mFailed tests :\33[0m \33[31m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
- };
-
- Print.prototype.printWithoutTestCount = function (current, total) {
- this.out(' \33[36m\33[1mWithout tests :\33[0m \33[33m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
- };
- return Print;
- })();
-
- var File = (function () {
- function File(name, hasError) {
- this.name = name;
- this.hasError = hasError;
- }
- File.prototype.formatName = function (baseDir) {
- var dirName = path.dirname(this.name.substr(baseDir.length + 1)).replace('\\', '/');
- var dir = dirName.split('/')[0];
- var file = path.basename(this.name, '.ts');
- var ext = path.extname(this.name);
-
- return dir + ((dirName.split('/').length > 1) ? '/-/' : '/') + '\33[36m\33[1m' + file + '\33[0m' + ext;
- };
- return File;
- })();
-
- var SyntaxChecking = (function () {
- function SyntaxChecking(fileHandler, out) {
- this.fileHandler = fileHandler;
- this.out = out;
- this.files = [];
- this.timer = new Timer();
- }
- SyntaxChecking.prototype.getFailedFiles = function () {
- var list = [];
-
- for (var i = 0; i < this.files.length; i++) {
- if (this.files[i].hasError) {
- list.push(this.files[i]);
- }
- }
-
- return list;
- };
-
- SyntaxChecking.prototype.getSuccessFiles = function () {
- var list = [];
-
- for (var i = 0; i < this.files.length; i++) {
- if (!this.files[i].hasError) {
- list.push(this.files[i]);
- }
- }
-
- return list;
- };
-
- SyntaxChecking.prototype.printStats = function () {
- this.out.printDiv();
- this.out.printElapsedTime(this.timer.asString, this.timer.time);
- this.out.printSuccessCount(this.getSuccessFiles().length, this.files.length);
- this.out.printFailedCount(this.getFailedFiles().length, this.files.length);
- };
-
- SyntaxChecking.prototype.printFailedFiles = function () {
- if (this.getFailedFiles().length > 0) {
- this.out.printDiv();
-
- this.out.printfilesWithSintaxErrorMessage();
-
- this.out.printDiv();
-
- for (var i = 0; i < this.getFailedFiles().length; i++) {
- var errorFile = this.getFailedFiles()[i];
- this.out.printErrorFile(errorFile.formatName(this.fileHandler.path));
- }
- }
- };
-
- SyntaxChecking.prototype.run = function (it, file, len, maxLen, callback) {
- var _this = this;
- if (!endsWith(file.toUpperCase(), '-TESTS.TS') && endsWith(file.toUpperCase(), '.TS') && file.indexOf('../_infrastructure') < 0) {
- new Test(file).run(function (o) {
- var failed = false;
-
- if (o.exitCode === 1) {
- _this.out.printFailure();
- failed = true;
- len++;
- } else {
- _this.out.printSuccess();
- len++;
- }
-
- _this.files.push(new File(file, failed));
-
- if (len > maxLen) {
- len = 0;
- _this.out.breack();
- }
-
- if (it.hasNext()) {
- _this.run(it, it.next(), len, maxLen, callback);
- } else {
- _this.out.breack();
- _this.timer.end();
- _this.printFailedFiles();
- _this.printStats();
-
- callback(_this.getFailedFiles().length, _this.files.length);
- }
- });
- } else if (it.hasNext()) {
- this.run(it, it.next(), len, maxLen, callback);
- } else {
- this.out.breack();
- this.timer.end();
- this.printStats();
- this.printFailedFiles();
-
- callback(this.getFailedFiles().length, this.files.length);
- }
- };
-
- SyntaxChecking.prototype.start = function (callback) {
- this.timer.start();
-
- var tsFiles = this.fileHandler.allTS();
-
- var it = new Iterator(tsFiles);
-
- var len = 0;
- var maxLen = 76;
-
- if (it.hasNext()) {
- this.run(it, it.next(), len, maxLen, callback);
- }
- };
- return SyntaxChecking;
- })();
-
- var TestEval = (function () {
- function TestEval(fileHandler, out) {
- this.fileHandler = fileHandler;
- this.out = out;
- this.files = [];
- this.timer = new Timer();
- }
- TestEval.prototype.getFailedFiles = function () {
- var list = [];
-
- for (var i = 0; i < this.files.length; i++) {
- if (this.files[i].hasError) {
- list.push(this.files[i]);
- }
- }
-
- return list;
- };
-
- TestEval.prototype.getSuccessFiles = function () {
- var list = [];
-
- for (var i = 0; i < this.files.length; i++) {
- if (!this.files[i].hasError) {
- list.push(this.files[i]);
- }
- }
-
- return list;
- };
-
- TestEval.prototype.printStats = function () {
- this.out.printDiv();
- this.out.printElapsedTime(this.timer.asString, this.timer.time);
- this.out.printSuccessCount(this.getSuccessFiles().length, this.files.length);
- this.out.printFailedCount(this.getFailedFiles().length, this.files.length);
- };
-
- TestEval.prototype.printFailedFiles = function () {
- if (this.getFailedFiles().length > 0) {
- this.out.printDiv();
-
- this.out.printFailedTestMessage();
-
- this.out.printDiv();
-
- for (var i = 0; i < this.getFailedFiles().length; i++) {
- var errorFile = this.getFailedFiles()[i];
- this.out.printErrorFile(errorFile.formatName(this.fileHandler.path));
- }
- }
- };
-
- TestEval.prototype.run = function (it, file, len, maxLen, callback) {
- var _this = this;
- if (endsWith(file.toUpperCase(), '-TESTS.TS')) {
- new Test(file).run(function (o) {
- var failed = false;
-
- if (o.exitCode === 1) {
- _this.out.printFailure();
- failed = true;
- len++;
- } else {
- _this.out.printSuccess();
- len++;
- }
-
- _this.files.push(new File(file, failed));
-
- if (len > maxLen) {
- len = 0;
- _this.out.breack();
- }
-
- if (it.hasNext()) {
- _this.run(it, it.next(), len, maxLen, callback);
- } else {
- _this.out.breack();
- _this.timer.end();
- _this.printFailedFiles();
- _this.printStats();
-
- callback(_this.getFailedFiles().length, _this.files.length);
- }
- });
- } else if (it.hasNext()) {
- this.run(it, it.next(), len, maxLen, callback);
- } else {
- this.out.breack();
- this.timer.end();
- this.printFailedFiles();
- this.printStats();
-
- callback(this.getFailedFiles().length, this.files.length);
- }
- };
-
- TestEval.prototype.start = function (callback) {
- this.timer.start();
-
- var tsFiles = this.fileHandler.allTS();
-
- var it = new Iterator(tsFiles);
-
- var len = 0;
- var maxLen = 76;
-
- if (it.hasNext()) {
- this.run(it, it.next(), len, maxLen, callback);
- }
- };
- return TestEval;
- })();
-
- var TestRunner = (function () {
- function TestRunner(dtPath) {
- this.dtPath = dtPath;
- this.typings = [];
- this.fh = new FileHandler(dtPath, /.\.ts/g);
- this.out = new Print('0.9.1.0', this.fh.allTypings().length, this.fh.allTS().length);
- this.sc = new SyntaxChecking(this.fh, this.out);
- this.te = new TestEval(this.fh, this.out);
-
- var tpgs = this.fh.allTypings();
- for (var i = 0; i < tpgs.length; i++) {
- this.typings.push(new Typing(tpgs[i], this.dtPath));
- }
- }
- TestRunner.prototype.printTypingsWithoutTest = function () {
- var count = 0;
-
- if (this.typings.length > 0) {
- this.out.printDiv();
-
- this.out.printTypingsWithoutTestsMessage();
-
- this.out.printDiv();
-
- for (var i = 0; i < this.typings.length; i++) {
- var typing = this.typings[i];
- if (typing.fileHandler.allTests().length == 0) {
- if (typing.name != '_infrastructure' && typing.name != '_ReSharper.DefinitelyTyped' && typing.name != 'obj' && typing.name != 'bin' && typing.name != 'Properties') {
- this.out.printTypingsWithoutTest(typing.name);
- count++;
- }
- }
- }
- }
-
- return count;
- };
-
- TestRunner.prototype.run = function () {
- var _this = this;
- var timer = new Timer();
- timer.start();
-
- this.out.printHeader();
- this.out.printSyntaxChecking();
-
- this.sc.start(function (syntaxFailedCount, syntaxTotal) {
- _this.out.printTypingTests();
- _this.te.start(function (testFailedCount, testTotal) {
- var total = _this.printTypingsWithoutTest();
-
- timer.end();
-
- _this.out.printDiv();
- _this.out.printTotalMessage();
- _this.out.printDiv();
-
- _this.out.printElapsedTime(timer.asString, timer.time);
- _this.out.printSyntaxErrorCount(syntaxFailedCount, syntaxTotal);
- _this.out.printTestErrorCount(testFailedCount, testTotal);
- _this.out.printWithoutTestCount(total, _this.fh.allTypings().length);
-
- _this.out.printDiv();
-
- if (syntaxFailedCount > 0 || testFailedCount > 0) {
- process.exit(1);
- }
- });
- });
- };
- return TestRunner;
- })();
- TestManager.TestRunner = TestRunner;
- })(DefinitelyTyped.TestManager || (DefinitelyTyped.TestManager = {}));
- var TestManager = DefinitelyTyped.TestManager;
-})(DefinitelyTyped || (DefinitelyTyped = {}));
-
-var dtPath = __dirname + '/../..';
-
-var runner = new DefinitelyTyped.TestManager.TestRunner(dtPath);
-runner.run();
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+var ExecResult = (function () {
+ function ExecResult() {
+ this.stdout = "";
+ this.stderr = "";
+ }
+ return ExecResult;
+})();
+
+var WindowsScriptHostExec = (function () {
+ function WindowsScriptHostExec() {
+ }
+ WindowsScriptHostExec.prototype.exec = function (filename, cmdLineArgs, handleResult) {
+ var result = new ExecResult();
+ var shell = new ActiveXObject('WScript.Shell');
+ try {
+ var process = shell.Exec(filename + ' ' + cmdLineArgs.join(' '));
+ } catch (e) {
+ result.stderr = e.message;
+ result.exitCode = 1;
+ handleResult(result);
+ return;
+ }
+
+ while (process.Status != 0) {
+ }
+
+ result.exitCode = process.ExitCode;
+ if (!process.StdOut.AtEndOfStream)
+ result.stdout = process.StdOut.ReadAll();
+ if (!process.StdErr.AtEndOfStream)
+ result.stderr = process.StdErr.ReadAll();
+
+ handleResult(result);
+ };
+ return WindowsScriptHostExec;
+})();
+
+var NodeExec = (function () {
+ function NodeExec() {
+ }
+ NodeExec.prototype.exec = function (filename, cmdLineArgs, handleResult) {
+ var nodeExec = require('child_process').exec;
+
+ var result = new ExecResult();
+ result.exitCode = null;
+ var cmdLine = filename + ' ' + cmdLineArgs.join(' ');
+
+ var process = nodeExec(cmdLine, function (error, stdout, stderr) {
+ result.stdout = stdout;
+ result.stderr = stderr;
+ result.exitCode = error ? error.code : 0;
+ handleResult(result);
+ });
+ };
+ return NodeExec;
+})();
+
+var Exec = (function () {
+ var global = Function("return this;").call(null);
+ if (typeof global.ActiveXObject !== "undefined") {
+ return new WindowsScriptHostExec();
+ } else {
+ return new NodeExec();
+ }
+})();
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+var IOUtils;
+(function (IOUtils) {
+ // Creates the directory including its parent if not already present
+ function createDirectoryStructure(ioHost, dirName) {
+ if (ioHost.directoryExists(dirName)) {
+ return;
+ }
+
+ var parentDirectory = ioHost.dirName(dirName);
+ if (parentDirectory != "") {
+ createDirectoryStructure(ioHost, parentDirectory);
+ }
+ ioHost.createDirectory(dirName);
+ }
+
+ // Creates a file including its directory structure if not already present
+ function createFileAndFolderStructure(ioHost, fileName, useUTF8) {
+ var path = ioHost.resolvePath(fileName);
+ var dirName = ioHost.dirName(path);
+ createDirectoryStructure(ioHost, dirName);
+ return ioHost.createFile(path, useUTF8);
+ }
+ IOUtils.createFileAndFolderStructure = createFileAndFolderStructure;
+
+ function throwIOError(message, error) {
+ var errorMessage = message;
+ if (error && error.message) {
+ errorMessage += (" " + error.message);
+ }
+ throw new Error(errorMessage);
+ }
+ IOUtils.throwIOError = throwIOError;
+})(IOUtils || (IOUtils = {}));
+
+var IO = (function () {
+ // Create an IO object for use inside WindowsScriptHost hosts
+ // Depends on WSCript and FileSystemObject
+ function getWindowsScriptHostIO() {
+ var fso = new ActiveXObject("Scripting.FileSystemObject");
+ var streamObjectPool = [];
+
+ function getStreamObject() {
+ if (streamObjectPool.length > 0) {
+ return streamObjectPool.pop();
+ } else {
+ return new ActiveXObject("ADODB.Stream");
+ }
+ }
+
+ function releaseStreamObject(obj) {
+ streamObjectPool.push(obj);
+ }
+
+ var args = [];
+ for (var i = 0; i < WScript.Arguments.length; i++) {
+ args[i] = WScript.Arguments.Item(i);
+ }
+
+ return {
+ readFile: function (path) {
+ try {
+ var streamObj = getStreamObject();
+ streamObj.Open();
+ streamObj.Type = 2;
+ streamObj.Charset = 'x-ansi';
+ streamObj.LoadFromFile(path);
+ var bomChar = streamObj.ReadText(2);
+ streamObj.Position = 0;
+ if ((bomChar.charCodeAt(0) == 0xFE && bomChar.charCodeAt(1) == 0xFF) || (bomChar.charCodeAt(0) == 0xFF && bomChar.charCodeAt(1) == 0xFE)) {
+ streamObj.Charset = 'unicode';
+ } else if (bomChar.charCodeAt(0) == 0xEF && bomChar.charCodeAt(1) == 0xBB) {
+ streamObj.Charset = 'utf-8';
+ }
+
+ // Read the whole file
+ var str = streamObj.ReadText(-1);
+ streamObj.Close();
+ releaseStreamObject(streamObj);
+ return str;
+ } catch (err) {
+ IOUtils.throwIOError("Error reading file \"" + path + "\".", err);
+ }
+ },
+ writeFile: function (path, contents) {
+ var file = this.createFile(path);
+ file.Write(contents);
+ file.Close();
+ },
+ fileExists: function (path) {
+ return fso.FileExists(path);
+ },
+ resolvePath: function (path) {
+ return fso.GetAbsolutePathName(path);
+ },
+ dirName: function (path) {
+ return fso.GetParentFolderName(path);
+ },
+ findFile: function (rootPath, partialFilePath) {
+ var path = fso.GetAbsolutePathName(rootPath) + "/" + partialFilePath;
+
+ while (true) {
+ if (fso.FileExists(path)) {
+ try {
+ var content = this.readFile(path);
+ return { content: content, path: path };
+ } catch (err) {
+ //Tools.CompilerDiagnostics.debugPrint("Could not find " + path + ", trying parent");
+ }
+ } else {
+ rootPath = fso.GetParentFolderName(fso.GetAbsolutePathName(rootPath));
+
+ if (rootPath == "") {
+ return null;
+ } else {
+ path = fso.BuildPath(rootPath, partialFilePath);
+ }
+ }
+ }
+ },
+ deleteFile: function (path) {
+ try {
+ if (fso.FileExists(path)) {
+ fso.DeleteFile(path, true);
+ }
+ } catch (e) {
+ IOUtils.throwIOError("Couldn't delete file '" + path + "'.", e);
+ }
+ },
+ createFile: function (path, useUTF8) {
+ try {
+ var streamObj = getStreamObject();
+ streamObj.Charset = useUTF8 ? 'utf-8' : 'x-ansi';
+ streamObj.Open();
+ return {
+ Write: function (str) {
+ streamObj.WriteText(str, 0);
+ },
+ WriteLine: function (str) {
+ streamObj.WriteText(str, 1);
+ },
+ Close: function () {
+ try {
+ streamObj.SaveToFile(path, 2);
+ } catch (saveError) {
+ IOUtils.throwIOError("Couldn't write to file '" + path + "'.", saveError);
+ } finally {
+ if (streamObj.State != 0) {
+ streamObj.Close();
+ }
+ releaseStreamObject(streamObj);
+ }
+ }
+ };
+ } catch (creationError) {
+ IOUtils.throwIOError("Couldn't write to file '" + path + "'.", creationError);
+ }
+ },
+ directoryExists: function (path) {
+ return fso.FolderExists(path);
+ },
+ createDirectory: function (path) {
+ try {
+ if (!this.directoryExists(path)) {
+ fso.CreateFolder(path);
+ }
+ } catch (e) {
+ IOUtils.throwIOError("Couldn't create directory '" + path + "'.", e);
+ }
+ },
+ dir: function (path, spec, options) {
+ options = options || {};
+ function filesInFolder(folder, root) {
+ var paths = [];
+ var fc;
+
+ if (options.recursive) {
+ fc = new Enumerator(folder.subfolders);
+
+ for (; !fc.atEnd(); fc.moveNext()) {
+ paths = paths.concat(filesInFolder(fc.item(), root + "/" + fc.item().Name));
+ }
+ }
+
+ fc = new Enumerator(folder.files);
+
+ for (; !fc.atEnd(); fc.moveNext()) {
+ if (!spec || fc.item().Name.match(spec)) {
+ paths.push(root + "/" + fc.item().Name);
+ }
+ }
+
+ return paths;
+ }
+
+ var folder = fso.GetFolder(path);
+ var paths = [];
+
+ return filesInFolder(folder, path);
+ },
+ print: function (str) {
+ WScript.StdOut.Write(str);
+ },
+ printLine: function (str) {
+ WScript.Echo(str);
+ },
+ arguments: args,
+ stderr: WScript.StdErr,
+ stdout: WScript.StdOut,
+ watchFile: null,
+ run: function (source, filename) {
+ try {
+ eval(source);
+ } catch (e) {
+ IOUtils.throwIOError("Error while executing file '" + filename + "'.", e);
+ }
+ },
+ getExecutingFilePath: function () {
+ return WScript.ScriptFullName;
+ },
+ quit: function (exitCode) {
+ if (typeof exitCode === "undefined") { exitCode = 0; }
+ try {
+ WScript.Quit(exitCode);
+ } catch (e) {
+ }
+ }
+ };
+ }
+ ;
+
+ // Create an IO object for use inside Node.js hosts
+ // Depends on 'fs' and 'path' modules
+ function getNodeIO() {
+ var _fs = require('fs');
+ var _path = require('path');
+ var _module = require('module');
+
+ return {
+ readFile: function (file) {
+ try {
+ var buffer = _fs.readFileSync(file);
+ switch (buffer[0]) {
+ case 0xFE:
+ if (buffer[1] == 0xFF) {
+ // utf16-be. Reading the buffer as big endian is not supported, so convert it to
+ // Little Endian first
+ var i = 0;
+ while ((i + 1) < buffer.length) {
+ var temp = buffer[i];
+ buffer[i] = buffer[i + 1];
+ buffer[i + 1] = temp;
+ i += 2;
+ }
+ return buffer.toString("ucs2", 2);
+ }
+ break;
+ case 0xFF:
+ if (buffer[1] == 0xFE) {
+ // utf16-le
+ return buffer.toString("ucs2", 2);
+ }
+ break;
+ case 0xEF:
+ if (buffer[1] == 0xBB) {
+ // utf-8
+ return buffer.toString("utf8", 3);
+ }
+ }
+
+ // Default behaviour
+ return buffer.toString();
+ } catch (e) {
+ IOUtils.throwIOError("Error reading file \"" + file + "\".", e);
+ }
+ },
+ writeFile: _fs.writeFileSync,
+ deleteFile: function (path) {
+ try {
+ _fs.unlinkSync(path);
+ } catch (e) {
+ IOUtils.throwIOError("Couldn't delete file '" + path + "'.", e);
+ }
+ },
+ fileExists: function (path) {
+ return _fs.existsSync(path);
+ },
+ createFile: function (path, useUTF8) {
+ function mkdirRecursiveSync(path) {
+ var stats = _fs.statSync(path);
+ if (stats.isFile()) {
+ IOUtils.throwIOError("\"" + path + "\" exists but isn't a directory.", null);
+ } else if (stats.isDirectory()) {
+ return;
+ } else {
+ mkdirRecursiveSync(_path.dirname(path));
+ _fs.mkdirSync(path, 0775);
+ }
+ }
+
+ mkdirRecursiveSync(_path.dirname(path));
+
+ try {
+ var fd = _fs.openSync(path, 'w');
+ } catch (e) {
+ IOUtils.throwIOError("Couldn't write to file '" + path + "'.", e);
+ }
+ return {
+ Write: function (str) {
+ _fs.writeSync(fd, str);
+ },
+ WriteLine: function (str) {
+ _fs.writeSync(fd, str + '\r\n');
+ },
+ Close: function () {
+ _fs.closeSync(fd);
+ fd = null;
+ }
+ };
+ },
+ dir: function dir(path, spec, options) {
+ options = options || {};
+
+ function filesInFolder(folder, deep) {
+ var paths = [];
+
+ var files = _fs.readdirSync(folder);
+ for (var i = 0; i < files.length; i++) {
+ var stat = _fs.statSync(folder + "/" + files[i]);
+ if (options.recursive && stat.isDirectory()) {
+ if (deep < (options.deep || 100)) {
+ paths = paths.concat(filesInFolder(folder + "/" + files[i], 1));
+ }
+ } else if (stat.isFile() && (!spec || files[i].match(spec))) {
+ paths.push(folder + "/" + files[i]);
+ }
+ }
+
+ return paths;
+ }
+
+ return filesInFolder(path, 0);
+ },
+ createDirectory: function (path) {
+ try {
+ if (!this.directoryExists(path)) {
+ _fs.mkdirSync(path);
+ }
+ } catch (e) {
+ IOUtils.throwIOError("Couldn't create directory '" + path + "'.", e);
+ }
+ },
+ directoryExists: function (path) {
+ return _fs.existsSync(path) && _fs.lstatSync(path).isDirectory();
+ },
+ resolvePath: function (path) {
+ return _path.resolve(path);
+ },
+ dirName: function (path) {
+ return _path.dirname(path);
+ },
+ findFile: function (rootPath, partialFilePath) {
+ var path = rootPath + "/" + partialFilePath;
+
+ while (true) {
+ if (_fs.existsSync(path)) {
+ try {
+ var content = this.readFile(path);
+ return { content: content, path: path };
+ } catch (err) {
+ //Tools.CompilerDiagnostics.debugPrint(("Could not find " + path) + ", trying parent");
+ }
+ } else {
+ var parentPath = _path.resolve(rootPath, "..");
+
+ if (rootPath === parentPath) {
+ return null;
+ } else {
+ rootPath = parentPath;
+ path = _path.resolve(rootPath, partialFilePath);
+ }
+ }
+ }
+ },
+ print: function (str) {
+ process.stdout.write(str);
+ },
+ printLine: function (str) {
+ process.stdout.write(str + '\n');
+ },
+ arguments: process.argv.slice(2),
+ stderr: {
+ Write: function (str) {
+ process.stderr.write(str);
+ },
+ WriteLine: function (str) {
+ process.stderr.write(str + '\n');
+ },
+ Close: function () {
+ }
+ },
+ stdout: {
+ Write: function (str) {
+ process.stdout.write(str);
+ },
+ WriteLine: function (str) {
+ process.stdout.write(str + '\n');
+ },
+ Close: function () {
+ }
+ },
+ watchFile: function (filename, callback) {
+ var firstRun = true;
+ var processingChange = false;
+
+ var fileChanged = function (curr, prev) {
+ if (!firstRun) {
+ if (curr.mtime < prev.mtime) {
+ return;
+ }
+
+ _fs.unwatchFile(filename, fileChanged);
+ if (!processingChange) {
+ processingChange = true;
+ callback(filename);
+ setTimeout(function () {
+ processingChange = false;
+ }, 100);
+ }
+ }
+ firstRun = false;
+ _fs.watchFile(filename, { persistent: true, interval: 500 }, fileChanged);
+ };
+
+ fileChanged();
+ return {
+ filename: filename,
+ close: function () {
+ _fs.unwatchFile(filename, fileChanged);
+ }
+ };
+ },
+ run: function (source, filename) {
+ require.main.filename = filename;
+ require.main.paths = _module._nodeModulePaths(_path.dirname(_fs.realpathSync(filename)));
+ require.main._compile(source, filename);
+ },
+ getExecutingFilePath: function () {
+ return process.mainModule.filename;
+ },
+ quit: process.exit
+ };
+ }
+ ;
+
+ if (typeof ActiveXObject === "function")
+ return getWindowsScriptHostIO();
+else if (typeof require === "function")
+ return getNodeIO();
+else
+ return null;
+})();
+///
+///
+var DefinitelyTyped;
+(function (DefinitelyTyped) {
+ (function (TestManager) {
+ var path = require('path');
+
+ function endsWith(str, suffix) {
+ return str.indexOf(suffix, str.length - suffix.length) !== -1;
+ }
+
+ var Iterator = (function () {
+ function Iterator(list) {
+ this.list = list;
+ this.index = -1;
+ }
+ Iterator.prototype.next = function () {
+ this.index++;
+ return this.list[this.index];
+ };
+
+ Iterator.prototype.hasNext = function () {
+ return this.list[1 + this.index] != null;
+ };
+ return Iterator;
+ })();
+
+ var Tsc = (function () {
+ function Tsc() {
+ }
+ Tsc.run = function (tsfile, callback) {
+ var command = 'node ./_infrastructure/tests/typescript/tsc.js --module commonjs ';
+ if (IO.fileExists(tsfile + '.tscparams')) {
+ command += '@' + tsfile + '.tscparams';
+ }
+ Exec.exec(command, [tsfile], function (ExecResult) {
+ callback(ExecResult);
+ });
+ };
+ return Tsc;
+ })();
+
+ var Test = (function () {
+ function Test(tsfile) {
+ this.tsfile = tsfile;
+ }
+ Test.prototype.run = function (callback) {
+ Tsc.run(this.tsfile, callback);
+ };
+ return Test;
+ })();
+
+ var Typing = (function () {
+ function Typing(name, baseDir) {
+ this.name = name;
+ this.fileHandler = new FileHandler(baseDir + '/' + name + '/', /.\.ts/g);
+ }
+ return Typing;
+ })();
+
+ var FileHandler = (function () {
+ function FileHandler(path, pattern) {
+ this.path = path;
+ this.files = [];
+ this.typings = [];
+ this.files = IO.dir(path, pattern, { recursive: true }).sort();
+ }
+ FileHandler.prototype.allTS = function () {
+ return this.files;
+ };
+
+ FileHandler.prototype.allTests = function () {
+ var tests = [];
+
+ for (var i = 0; i < this.files.length; i++) {
+ if (endsWith(this.files[i].toUpperCase(), '-TESTS.TS')) {
+ tests.push(this.files[i]);
+ }
+ }
+
+ return tests;
+ };
+
+ FileHandler.prototype.allTypings = function () {
+ var typings = {};
+
+ for (var i = 0; i < this.files.length; i++) {
+ var file = this.files[i];
+ var firName = path.dirname(file.substr(this.path.length + 1)).replace('\\', '/');
+ var dir = firName.split('/')[0];
+
+ if (!typings[dir])
+ typings[dir] = true;
+ }
+
+ var list = [];
+ for (var attr in typings) {
+ list.push(attr);
+ }
+
+ return list;
+ };
+ return FileHandler;
+ })();
+
+ var Timer = (function () {
+ function Timer() {
+ this.time = 0;
+ }
+ Timer.prettyDate = function (date1, date2) {
+ var diff = ((date2 - date1) / 1000), day_diff = Math.floor(diff / 86400);
+
+ if (isNaN(day_diff) || day_diff < 0 || day_diff >= 31)
+ return;
+
+ return (day_diff == 0 && (diff < 60 && (diff + " secconds") || diff < 120 && "1 minute" || diff < 3600 && Math.floor(diff / 60) + " minutes" || diff < 7200 && "1 hour" || diff < 86400 && Math.floor(diff / 3600) + " hours") || day_diff == 1 && "Yesterday" || day_diff < 7 && day_diff + " days" || day_diff < 31 && Math.ceil(day_diff / 7) + " weeks");
+ };
+
+ Timer.prototype.start = function () {
+ this.time = 0;
+ this.startTime = this.now();
+ };
+
+ Timer.prototype.now = function () {
+ return Date.now();
+ };
+
+ Timer.prototype.end = function () {
+ this.time = (this.now() - this.startTime) / 1000;
+ this.asString = Timer.prettyDate(this.startTime, this.now());
+ };
+ return Timer;
+ })();
+
+ var Print = (function () {
+ function Print(version, typings, tsFiles) {
+ this.version = version;
+ this.typings = typings;
+ this.tsFiles = tsFiles;
+ }
+ Print.prototype.out = function (s) {
+ process.stdout.write(s);
+ };
+
+ Print.prototype.printHeader = function () {
+ this.out('=============================================================================\n');
+ this.out(' \33[36m\33[1mDefinitelyTyped test runner 0.3.0\33[0m\n');
+ this.out('=============================================================================\n');
+ this.out(' \33[36m\33[1mTypescript version:\33[0m ' + this.version + '\n');
+ this.out(' \33[36m\33[1mTypings :\33[0m ' + this.typings + '\n');
+ this.out(' \33[36m\33[1mTypeScript files :\33[0m ' + this.tsFiles + '\n');
+ };
+
+ Print.prototype.printSyntaxChecking = function () {
+ this.out('============================ \33[34m\33[1mSyntax checking\33[0m ================================\n');
+ };
+
+ Print.prototype.printTypingTests = function () {
+ this.out('============================= \33[34m\33[1mTyping tests\33[0m ==================================\n');
+ };
+
+ Print.prototype.printSuccess = function () {
+ this.out('\33[36m\33[1m.\33[0m');
+ };
+
+ Print.prototype.printFailure = function () {
+ this.out('x');
+ };
+
+ Print.prototype.printDiv = function () {
+ this.out('-----------------------------------------------------------------------------\n');
+ };
+
+ Print.prototype.printfilesWithSintaxErrorMessage = function () {
+ this.out(' \33[36m\33[1mFiles with syntax error\33[0m\n');
+ };
+
+ Print.prototype.printFailedTestMessage = function () {
+ this.out(' \33[36m\33[1mFailed tests\33[0m\n');
+ };
+
+ Print.prototype.printTypingsWithoutTestsMessage = function () {
+ this.out(' \33[36m\33[1mTyping without tests\33[0m\n');
+ };
+
+ Print.prototype.printTotalMessage = function () {
+ this.out(' \33[36m\33[1mTotal\33[0m\n');
+ };
+
+ Print.prototype.printErrorFile = function (file) {
+ this.out(' - ' + file + '\n');
+ };
+
+ Print.prototype.printTypingsWithoutTest = function (file) {
+ this.out(' - \33[33m\33[1m' + file + '\33[0m\n');
+ };
+
+ Print.prototype.breack = function () {
+ this.out('\n');
+ };
+
+ Print.prototype.printSuccessCount = function (current, total) {
+ this.out(' \33[36m\33[1mSuccessful :\33[0m \33[32m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
+ };
+
+ Print.prototype.printFailedCount = function (current, total) {
+ this.out(' \33[36m\33[1mFailure :\33[0m \33[31m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
+ };
+
+ Print.prototype.printElapsedTime = function (time, s) {
+ this.out(' \33[36m\33[1mElapsed time :\33[0m ~' + time + ' (' + s + 's)\n');
+ };
+
+ Print.prototype.printSyntaxErrorCount = function (current, total) {
+ this.out(' \33[36m\33[1mSyntax error :\33[0m \33[31m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
+ };
+
+ Print.prototype.printTestErrorCount = function (current, total) {
+ this.out(' \33[36m\33[1mFailed tests :\33[0m \33[31m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
+ };
+
+ Print.prototype.printWithoutTestCount = function (current, total) {
+ this.out(' \33[36m\33[1mWithout tests :\33[0m \33[33m\33[1m' + ((current / total) * 100).toFixed(2) + '% (' + current + '/' + total + ')\33[0m\n');
+ };
+ return Print;
+ })();
+
+ var File = (function () {
+ function File(name, hasError) {
+ this.name = name;
+ this.hasError = hasError;
+ }
+ File.prototype.formatName = function (baseDir) {
+ var dirName = path.dirname(this.name.substr(baseDir.length + 1)).replace('\\', '/');
+ var dir = dirName.split('/')[0];
+ var file = path.basename(this.name, '.ts');
+ var ext = path.extname(this.name);
+
+ return dir + ((dirName.split('/').length > 1) ? '/-/' : '/') + '\33[36m\33[1m' + file + '\33[0m' + ext;
+ };
+ return File;
+ })();
+
+ var SyntaxChecking = (function () {
+ function SyntaxChecking(fileHandler, out) {
+ this.fileHandler = fileHandler;
+ this.out = out;
+ this.files = [];
+ this.timer = new Timer();
+ }
+ SyntaxChecking.prototype.getFailedFiles = function () {
+ var list = [];
+
+ for (var i = 0; i < this.files.length; i++) {
+ if (this.files[i].hasError) {
+ list.push(this.files[i]);
+ }
+ }
+
+ return list;
+ };
+
+ SyntaxChecking.prototype.getSuccessFiles = function () {
+ var list = [];
+
+ for (var i = 0; i < this.files.length; i++) {
+ if (!this.files[i].hasError) {
+ list.push(this.files[i]);
+ }
+ }
+
+ return list;
+ };
+
+ SyntaxChecking.prototype.printStats = function () {
+ this.out.printDiv();
+ this.out.printElapsedTime(this.timer.asString, this.timer.time);
+ this.out.printSuccessCount(this.getSuccessFiles().length, this.files.length);
+ this.out.printFailedCount(this.getFailedFiles().length, this.files.length);
+ };
+
+ SyntaxChecking.prototype.printFailedFiles = function () {
+ if (this.getFailedFiles().length > 0) {
+ this.out.printDiv();
+
+ this.out.printfilesWithSintaxErrorMessage();
+
+ this.out.printDiv();
+
+ for (var i = 0; i < this.getFailedFiles().length; i++) {
+ var errorFile = this.getFailedFiles()[i];
+ this.out.printErrorFile(errorFile.formatName(this.fileHandler.path));
+ }
+ }
+ };
+
+ SyntaxChecking.prototype.run = function (it, file, len, maxLen, callback) {
+ var _this = this;
+ if (!endsWith(file.toUpperCase(), '-TESTS.TS') && endsWith(file.toUpperCase(), '.TS') && file.indexOf('../_infrastructure') < 0) {
+ new Test(file).run(function (o) {
+ var failed = false;
+
+ if (o.exitCode === 1) {
+ _this.out.printFailure();
+ failed = true;
+ len++;
+ } else {
+ _this.out.printSuccess();
+ len++;
+ }
+
+ _this.files.push(new File(file, failed));
+
+ if (len > maxLen) {
+ len = 0;
+ _this.out.breack();
+ }
+
+ if (it.hasNext()) {
+ _this.run(it, it.next(), len, maxLen, callback);
+ } else {
+ _this.out.breack();
+ _this.timer.end();
+ _this.printFailedFiles();
+ _this.printStats();
+
+ callback(_this.getFailedFiles().length, _this.files.length);
+ }
+ });
+ } else if (it.hasNext()) {
+ this.run(it, it.next(), len, maxLen, callback);
+ } else {
+ this.out.breack();
+ this.timer.end();
+ this.printStats();
+ this.printFailedFiles();
+
+ callback(this.getFailedFiles().length, this.files.length);
+ }
+ };
+
+ SyntaxChecking.prototype.start = function (callback) {
+ this.timer.start();
+
+ var tsFiles = this.fileHandler.allTS();
+
+ var it = new Iterator(tsFiles);
+
+ var len = 0;
+ var maxLen = 76;
+
+ if (it.hasNext()) {
+ this.run(it, it.next(), len, maxLen, callback);
+ }
+ };
+ return SyntaxChecking;
+ })();
+
+ var TestEval = (function () {
+ function TestEval(fileHandler, out) {
+ this.fileHandler = fileHandler;
+ this.out = out;
+ this.files = [];
+ this.timer = new Timer();
+ }
+ TestEval.prototype.getFailedFiles = function () {
+ var list = [];
+
+ for (var i = 0; i < this.files.length; i++) {
+ if (this.files[i].hasError) {
+ list.push(this.files[i]);
+ }
+ }
+
+ return list;
+ };
+
+ TestEval.prototype.getSuccessFiles = function () {
+ var list = [];
+
+ for (var i = 0; i < this.files.length; i++) {
+ if (!this.files[i].hasError) {
+ list.push(this.files[i]);
+ }
+ }
+
+ return list;
+ };
+
+ TestEval.prototype.printStats = function () {
+ this.out.printDiv();
+ this.out.printElapsedTime(this.timer.asString, this.timer.time);
+ this.out.printSuccessCount(this.getSuccessFiles().length, this.files.length);
+ this.out.printFailedCount(this.getFailedFiles().length, this.files.length);
+ };
+
+ TestEval.prototype.printFailedFiles = function () {
+ if (this.getFailedFiles().length > 0) {
+ this.out.printDiv();
+
+ this.out.printFailedTestMessage();
+
+ this.out.printDiv();
+
+ for (var i = 0; i < this.getFailedFiles().length; i++) {
+ var errorFile = this.getFailedFiles()[i];
+ this.out.printErrorFile(errorFile.formatName(this.fileHandler.path));
+ }
+ }
+ };
+
+ TestEval.prototype.run = function (it, file, len, maxLen, callback) {
+ var _this = this;
+ if (endsWith(file.toUpperCase(), '-TESTS.TS')) {
+ new Test(file).run(function (o) {
+ var failed = false;
+
+ if (o.exitCode === 1) {
+ _this.out.printFailure();
+ failed = true;
+ len++;
+ } else {
+ _this.out.printSuccess();
+ len++;
+ }
+
+ _this.files.push(new File(file, failed));
+
+ if (len > maxLen) {
+ len = 0;
+ _this.out.breack();
+ }
+
+ if (it.hasNext()) {
+ _this.run(it, it.next(), len, maxLen, callback);
+ } else {
+ _this.out.breack();
+ _this.timer.end();
+ _this.printFailedFiles();
+ _this.printStats();
+
+ callback(_this.getFailedFiles().length, _this.files.length);
+ }
+ });
+ } else if (it.hasNext()) {
+ this.run(it, it.next(), len, maxLen, callback);
+ } else {
+ this.out.breack();
+ this.timer.end();
+ this.printFailedFiles();
+ this.printStats();
+
+ callback(this.getFailedFiles().length, this.files.length);
+ }
+ };
+
+ TestEval.prototype.start = function (callback) {
+ this.timer.start();
+
+ var tsFiles = this.fileHandler.allTS();
+
+ var it = new Iterator(tsFiles);
+
+ var len = 0;
+ var maxLen = 76;
+
+ if (it.hasNext()) {
+ this.run(it, it.next(), len, maxLen, callback);
+ }
+ };
+ return TestEval;
+ })();
+
+ var TestRunner = (function () {
+ function TestRunner(dtPath) {
+ this.dtPath = dtPath;
+ this.typings = [];
+ this.fh = new FileHandler(dtPath, /.\.ts/g);
+ this.out = new Print('0.9.1.1', this.fh.allTypings().length, this.fh.allTS().length);
+ this.sc = new SyntaxChecking(this.fh, this.out);
+ this.te = new TestEval(this.fh, this.out);
+
+ var tpgs = this.fh.allTypings();
+ for (var i = 0; i < tpgs.length; i++) {
+ this.typings.push(new Typing(tpgs[i], this.dtPath));
+ }
+ }
+ TestRunner.prototype.printTypingsWithoutTest = function () {
+ var count = 0;
+
+ if (this.typings.length > 0) {
+ this.out.printDiv();
+
+ this.out.printTypingsWithoutTestsMessage();
+
+ this.out.printDiv();
+
+ for (var i = 0; i < this.typings.length; i++) {
+ var typing = this.typings[i];
+ if (typing.fileHandler.allTests().length == 0) {
+ if (typing.name != '_infrastructure' && typing.name != '_ReSharper.DefinitelyTyped' && typing.name != 'obj' && typing.name != 'bin' && typing.name != 'Properties') {
+ this.out.printTypingsWithoutTest(typing.name);
+ count++;
+ }
+ }
+ }
+ }
+
+ return count;
+ };
+
+ TestRunner.prototype.run = function () {
+ var _this = this;
+ var timer = new Timer();
+ timer.start();
+
+ this.out.printHeader();
+ this.out.printSyntaxChecking();
+
+ this.sc.start(function (syntaxFailedCount, syntaxTotal) {
+ _this.out.printTypingTests();
+ _this.te.start(function (testFailedCount, testTotal) {
+ var total = _this.printTypingsWithoutTest();
+
+ timer.end();
+
+ _this.out.printDiv();
+ _this.out.printTotalMessage();
+ _this.out.printDiv();
+
+ _this.out.printElapsedTime(timer.asString, timer.time);
+ _this.out.printSyntaxErrorCount(syntaxFailedCount, syntaxTotal);
+ _this.out.printTestErrorCount(testFailedCount, testTotal);
+ _this.out.printWithoutTestCount(total, _this.fh.allTypings().length);
+
+ _this.out.printDiv();
+
+ if (syntaxFailedCount > 0 || testFailedCount > 0) {
+ process.exit(1);
+ }
+ });
+ });
+ };
+ return TestRunner;
+ })();
+ TestManager.TestRunner = TestRunner;
+ })(DefinitelyTyped.TestManager || (DefinitelyTyped.TestManager = {}));
+ var TestManager = DefinitelyTyped.TestManager;
+})(DefinitelyTyped || (DefinitelyTyped = {}));
+
+var dtPath = __dirname + '/../..';
+
+var runner = new DefinitelyTyped.TestManager.TestRunner(dtPath);
+runner.run();
diff --git a/_infrastructure/tests/runner.ts b/_infrastructure/tests/runner.ts
index e7bf92926..c3d2a9da4 100644
--- a/_infrastructure/tests/runner.ts
+++ b/_infrastructure/tests/runner.ts
@@ -145,7 +145,7 @@ module DefinitelyTyped {
public printHeader() {
this.out('=============================================================================\n');
- this.out(' \33[36m\33[1mDefinitelyTyped test runner 0.2.1\33[0m\n');
+ this.out(' \33[36m\33[1mDefinitelyTyped test runner 0.3.0\33[0m\n');
this.out('=============================================================================\n');
this.out(' \33[36m\33[1mTypescript version:\33[0m ' + this.version + '\n');
this.out(' \33[36m\33[1mTypings :\33[0m ' + this.typings + '\n');
@@ -508,7 +508,7 @@ module DefinitelyTyped {
constructor(public dtPath: string) {
this.fh = new FileHandler(dtPath, /.\.ts/g);
- this.out = new Print('0.9.1.0', this.fh.allTypings().length, this.fh.allTS().length);
+ this.out = new Print('0.9.1.1', this.fh.allTypings().length, this.fh.allTS().length);
this.sc = new SyntaxChecking(this.fh, this.out);
this.te = new TestEval(this.fh, this.out);
diff --git a/_infrastructure/tests/typescript/tsc b/_infrastructure/tests/typescript/tsc
old mode 100644
new mode 100755
diff --git a/_infrastructure/tests/typescript/tsc.js b/_infrastructure/tests/typescript/tsc.js
index f366d7171..84cdce466 100644
--- a/_infrastructure/tests/typescript/tsc.js
+++ b/_infrastructure/tests/typescript/tsc.js
@@ -345,7 +345,9 @@ var TypeScript;
Option_mapRoot_cannot_be_specified_without_specifying_sourcemap_option: "Option mapRoot cannot be specified without specifying sourcemap option.",
Option_sourceRoot_cannot_be_specified_without_specifying_sourcemap_option: "Option sourceRoot cannot be specified without specifying sourcemap option.",
Options_mapRoot_and_sourceRoot_cannot_be_specified_without_specifying_sourcemap_option: "Options mapRoot and sourceRoot cannot be specified without specifying sourcemap option.",
- Concatenate_and_emit_output_to_single_file: "Concatenate and emit output to single file",
+ Option_0_specified_without_1: "Option '{0}' specified without '{1}'",
+ codepage_option_not_supported_on_current_platform: "'codepage' option not supported on current platform.",
+ Concatenate_and_emit_output_to_single_file: "Concatenate and emit output to single file.",
Generates_corresponding_0_file: "Generates corresponding {0} file",
Specifies_the_location_where_debugger_should_locate_map_files_instead_of_generated_locations: "Specifies the location where debugger should locate map files instead of generated locations.",
Specifies_the_location_where_debugger_should_locate_TypeScript_files_instead_of_source_locations: "Specifies the location where debugger should locate TypeScript files instead of source locations.",
@@ -361,7 +363,7 @@ var TypeScript;
Specify_locale_for_errors_and_messages_For_example_0_or_1: "Specify locale for errors and messages. For example '{0}' or '{1}'",
Syntax_0: "Syntax: {0}",
options: "options",
- file: "file",
+ file1: "file",
Examples: "Examples:",
Options: "Options:",
Insert_command_line_options_and_files_from_a_file: "Insert command line options and files from a file.",
@@ -370,10 +372,12 @@ var TypeScript;
NL_Recompiling_0: "{NL}Recompiling ({0}):",
STRING: "STRING",
KIND: "KIND",
- FILE: "FILE",
+ file2: "FILE",
VERSION: "VERSION",
LOCATION: "LOCATION",
DIRECTORY: "DIRECTORY",
+ NUMBER: "NUMBER",
+ Specify_the_codepage_to_use_when_opening_source_files: "Specify the codepage to use when opening source files.",
This_version_of_the_Javascript_runtime_does_not_support_the_0_function: "This version of the Javascript runtime does not support the '{0}' function.",
Looking_up_path_for_identifier_token_did_not_result_in_an_identifer: "Looking up path for identifier token did not result in an identifer.",
Unknown_rule: "Unknown rule",
@@ -389,7 +393,11 @@ var TypeScript;
Parameter_0_of_lambda_function_implicitly_has_an_any_type: "Parameter '{0}' of lambda function implicitly has an 'any' type.",
Constructor_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type: "Constructor signature, which lacks return-type annotation, implicitly has an 'any' return type.",
Lambda_Function_which_lacks_return_type_annotation_implicitly_has_an_any_return_type: "Lambda Function, which lacks return-type annotation, implicitly has an 'any' return type.",
- Array_Literal_implicitly_has_an_any_type_from_widening: "Array Literal implicitly has an 'any' type from widening."
+ Array_Literal_implicitly_has_an_any_type_from_widening: "Array Literal implicitly has an 'any' type from widening.",
+ Use_of_deprecated_type_bool_Use_boolean_instead: "Use of deprecated type 'bool'. Use 'boolean' instead.",
+ module_is_deprecated_Use_require_instead: "'module(...)' is deprecated. Use 'require(...)' instead.",
+ Allow_bool_as_a_synonym_for_boolean: "Allow 'bool' as a synonym for 'boolean'.",
+ Allow_module_as_a_synonym_for_require: "Allow 'module(...)' as a synonym for 'require(...)'."
};
})(TypeScript || (TypeScript = {}));
var TypeScript;
@@ -1068,18 +1076,16 @@ var TypeScript;
function getDiagnosticInfoFromKey(diagnosticKey) {
var result = TypeScript.diagnosticInformationMap[diagnosticKey];
- TypeScript.Debug.assert(result !== undefined && result !== null);
+
return result;
}
TypeScript.getDiagnosticInfoFromKey = getDiagnosticInfoFromKey;
function getLocalizedText(diagnosticKey, args) {
if (TypeScript.LocalizedDiagnosticMessages) {
- TypeScript.Debug.assert(TypeScript.LocalizedDiagnosticMessages.hasOwnProperty(diagnosticKey));
}
var diagnosticMessageText = TypeScript.LocalizedDiagnosticMessages ? TypeScript.LocalizedDiagnosticMessages[diagnosticKey] : diagnosticKey;
- TypeScript.Debug.assert(diagnosticMessageText !== undefined && diagnosticMessageText !== null);
var actualCount = args ? args.length : 0;
@@ -1178,8 +1184,19 @@ var Environment = (function () {
currentDirectory: function () {
return (WScript).CreateObject("WScript.Shell").CurrentDirectory;
},
- readFile: function (path) {
+ supportsCodePage: function () {
+ return (WScript).ReadFile;
+ },
+ readFile: function (path, codepage) {
try {
+ if (codepage !== null && this.supportsCodePage()) {
+ try {
+ var contents = (WScript).ReadFile(path, codepage);
+ return new FileInformation(contents, 0 /* None */);
+ } catch (e) {
+ }
+ }
+
var streamObj = getStreamObject();
streamObj.Open();
streamObj.Type = 2;
@@ -1304,7 +1321,14 @@ var Environment = (function () {
currentDirectory: function () {
return (process).cwd();
},
- readFile: function (file) {
+ supportsCodePage: function () {
+ return false;
+ },
+ readFile: function (file, codepage) {
+ if (codepage !== null) {
+ throw new Error(TypeScript.getDiagnosticMessage(TypeScript.DiagnosticCode.codepage_option_not_supported_on_current_platform, null));
+ }
+
var buffer = _fs.readFileSync(file);
switch (buffer[0]) {
case 0xFE:
@@ -2986,7 +3010,15 @@ var TypeScript;
"code": 5040,
"category": 1 /* Error */
},
- "Concatenate and emit output to single file": {
+ "Option '{0}' specified without '{1}'": {
+ "code": 5041,
+ "category": 1 /* Error */
+ },
+ "'codepage' option not supported on current platform.": {
+ "code": 5042,
+ "category": 1 /* Error */
+ },
+ "Concatenate and emit output to single file.": {
"code": 6001,
"category": 2 /* Message */
},
@@ -3050,7 +3082,7 @@ var TypeScript;
"code": 6024,
"category": 2 /* Message */
},
- "file": {
+ "file1": {
"code": 6025,
"category": 2 /* Message */
},
@@ -3086,7 +3118,7 @@ var TypeScript;
"code": 6034,
"category": 2 /* Message */
},
- "FILE": {
+ "file2": {
"code": 6035,
"category": 2 /* Message */
},
@@ -3102,6 +3134,14 @@ var TypeScript;
"code": 6038,
"category": 2 /* Message */
},
+ "NUMBER": {
+ "code": 6039,
+ "category": 2 /* Message */
+ },
+ "Specify the codepage to use when opening source files.": {
+ "code": 6040,
+ "category": 2 /* Message */
+ },
"This version of the Javascript runtime does not support the '{0}' function.": {
"code": 7000,
"category": 1 /* Error */
@@ -3165,6 +3205,22 @@ var TypeScript;
"Array Literal implicitly has an 'any' type from widening.": {
"code": 7014,
"category": 1 /* Error */
+ },
+ "Use of deprecated type 'bool'. Use 'boolean' instead.": {
+ "code": 7020,
+ "category": 0 /* Warning */
+ },
+ "'module(...)' is deprecated. Use 'require(...)' instead.": {
+ "code": 7021,
+ "category": 0 /* Warning */
+ },
+ "Allow 'bool' as a synonym for 'boolean'.": {
+ "code": 7022,
+ "category": 2 /* Message */
+ },
+ "Allow 'module(...)' as a synonym for 'require(...)'.": {
+ "code": 7022,
+ "category": 2 /* Message */
}
};
})(TypeScript || (TypeScript = {}));
@@ -4361,12 +4417,16 @@ var TypeScript;
var TypeScript;
(function (TypeScript) {
var ParseOptions = (function () {
- function ParseOptions(languageVersion, allowAutomaticSemicolonInsertion) {
+ function ParseOptions(languageVersion, allowAutomaticSemicolonInsertion, allowModuleKeywordInExternalModuleReference) {
this._languageVersion = languageVersion;
this._allowAutomaticSemicolonInsertion = allowAutomaticSemicolonInsertion;
+ this._allowModuleKeywordInExternalModuleReference = allowModuleKeywordInExternalModuleReference;
}
ParseOptions.prototype.toJSON = function (key) {
- return { allowAutomaticSemicolonInsertion: this._allowAutomaticSemicolonInsertion };
+ return {
+ allowAutomaticSemicolonInsertion: this._allowAutomaticSemicolonInsertion,
+ allowModuleKeywordInExternalModuleReference: this._allowModuleKeywordInExternalModuleReference
+ };
};
ParseOptions.prototype.languageVersion = function () {
@@ -4376,6 +4436,10 @@ var TypeScript;
ParseOptions.prototype.allowAutomaticSemicolonInsertion = function () {
return this._allowAutomaticSemicolonInsertion;
};
+
+ ParseOptions.prototype.allowModuleKeywordInExternalModuleReference = function () {
+ return this._allowModuleKeywordInExternalModuleReference;
+ };
return ParseOptions;
})();
TypeScript.ParseOptions = ParseOptions;
@@ -4757,206 +4821,207 @@ var TypeScript;
SyntaxKind[SyntaxKind["AnyKeyword"] = 60] = "AnyKeyword";
SyntaxKind[SyntaxKind["BooleanKeyword"] = 61] = "BooleanKeyword";
- SyntaxKind[SyntaxKind["ConstructorKeyword"] = 62] = "ConstructorKeyword";
- SyntaxKind[SyntaxKind["DeclareKeyword"] = 63] = "DeclareKeyword";
- SyntaxKind[SyntaxKind["GetKeyword"] = 64] = "GetKeyword";
- SyntaxKind[SyntaxKind["ModuleKeyword"] = 65] = "ModuleKeyword";
- SyntaxKind[SyntaxKind["RequireKeyword"] = 66] = "RequireKeyword";
- SyntaxKind[SyntaxKind["NumberKeyword"] = 67] = "NumberKeyword";
- SyntaxKind[SyntaxKind["SetKeyword"] = 68] = "SetKeyword";
- SyntaxKind[SyntaxKind["StringKeyword"] = 69] = "StringKeyword";
+ SyntaxKind[SyntaxKind["BoolKeyword"] = 62] = "BoolKeyword";
+ SyntaxKind[SyntaxKind["ConstructorKeyword"] = 63] = "ConstructorKeyword";
+ SyntaxKind[SyntaxKind["DeclareKeyword"] = 64] = "DeclareKeyword";
+ SyntaxKind[SyntaxKind["GetKeyword"] = 65] = "GetKeyword";
+ SyntaxKind[SyntaxKind["ModuleKeyword"] = 66] = "ModuleKeyword";
+ SyntaxKind[SyntaxKind["RequireKeyword"] = 67] = "RequireKeyword";
+ SyntaxKind[SyntaxKind["NumberKeyword"] = 68] = "NumberKeyword";
+ SyntaxKind[SyntaxKind["SetKeyword"] = 69] = "SetKeyword";
+ SyntaxKind[SyntaxKind["StringKeyword"] = 70] = "StringKeyword";
- SyntaxKind[SyntaxKind["OpenBraceToken"] = 70] = "OpenBraceToken";
- SyntaxKind[SyntaxKind["CloseBraceToken"] = 71] = "CloseBraceToken";
- SyntaxKind[SyntaxKind["OpenParenToken"] = 72] = "OpenParenToken";
- SyntaxKind[SyntaxKind["CloseParenToken"] = 73] = "CloseParenToken";
- SyntaxKind[SyntaxKind["OpenBracketToken"] = 74] = "OpenBracketToken";
- SyntaxKind[SyntaxKind["CloseBracketToken"] = 75] = "CloseBracketToken";
- SyntaxKind[SyntaxKind["DotToken"] = 76] = "DotToken";
- SyntaxKind[SyntaxKind["DotDotDotToken"] = 77] = "DotDotDotToken";
- SyntaxKind[SyntaxKind["SemicolonToken"] = 78] = "SemicolonToken";
- SyntaxKind[SyntaxKind["CommaToken"] = 79] = "CommaToken";
- SyntaxKind[SyntaxKind["LessThanToken"] = 80] = "LessThanToken";
- SyntaxKind[SyntaxKind["GreaterThanToken"] = 81] = "GreaterThanToken";
- SyntaxKind[SyntaxKind["LessThanEqualsToken"] = 82] = "LessThanEqualsToken";
- SyntaxKind[SyntaxKind["GreaterThanEqualsToken"] = 83] = "GreaterThanEqualsToken";
- SyntaxKind[SyntaxKind["EqualsEqualsToken"] = 84] = "EqualsEqualsToken";
- SyntaxKind[SyntaxKind["EqualsGreaterThanToken"] = 85] = "EqualsGreaterThanToken";
- SyntaxKind[SyntaxKind["ExclamationEqualsToken"] = 86] = "ExclamationEqualsToken";
- SyntaxKind[SyntaxKind["EqualsEqualsEqualsToken"] = 87] = "EqualsEqualsEqualsToken";
- SyntaxKind[SyntaxKind["ExclamationEqualsEqualsToken"] = 88] = "ExclamationEqualsEqualsToken";
- SyntaxKind[SyntaxKind["PlusToken"] = 89] = "PlusToken";
- SyntaxKind[SyntaxKind["MinusToken"] = 90] = "MinusToken";
- SyntaxKind[SyntaxKind["AsteriskToken"] = 91] = "AsteriskToken";
- SyntaxKind[SyntaxKind["PercentToken"] = 92] = "PercentToken";
- SyntaxKind[SyntaxKind["PlusPlusToken"] = 93] = "PlusPlusToken";
- SyntaxKind[SyntaxKind["MinusMinusToken"] = 94] = "MinusMinusToken";
- SyntaxKind[SyntaxKind["LessThanLessThanToken"] = 95] = "LessThanLessThanToken";
- SyntaxKind[SyntaxKind["GreaterThanGreaterThanToken"] = 96] = "GreaterThanGreaterThanToken";
- SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanToken"] = 97] = "GreaterThanGreaterThanGreaterThanToken";
- SyntaxKind[SyntaxKind["AmpersandToken"] = 98] = "AmpersandToken";
- SyntaxKind[SyntaxKind["BarToken"] = 99] = "BarToken";
- SyntaxKind[SyntaxKind["CaretToken"] = 100] = "CaretToken";
- SyntaxKind[SyntaxKind["ExclamationToken"] = 101] = "ExclamationToken";
- SyntaxKind[SyntaxKind["TildeToken"] = 102] = "TildeToken";
- SyntaxKind[SyntaxKind["AmpersandAmpersandToken"] = 103] = "AmpersandAmpersandToken";
- SyntaxKind[SyntaxKind["BarBarToken"] = 104] = "BarBarToken";
- SyntaxKind[SyntaxKind["QuestionToken"] = 105] = "QuestionToken";
- SyntaxKind[SyntaxKind["ColonToken"] = 106] = "ColonToken";
- SyntaxKind[SyntaxKind["EqualsToken"] = 107] = "EqualsToken";
- SyntaxKind[SyntaxKind["PlusEqualsToken"] = 108] = "PlusEqualsToken";
- SyntaxKind[SyntaxKind["MinusEqualsToken"] = 109] = "MinusEqualsToken";
- SyntaxKind[SyntaxKind["AsteriskEqualsToken"] = 110] = "AsteriskEqualsToken";
- SyntaxKind[SyntaxKind["PercentEqualsToken"] = 111] = "PercentEqualsToken";
- SyntaxKind[SyntaxKind["LessThanLessThanEqualsToken"] = 112] = "LessThanLessThanEqualsToken";
- SyntaxKind[SyntaxKind["GreaterThanGreaterThanEqualsToken"] = 113] = "GreaterThanGreaterThanEqualsToken";
- SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanEqualsToken"] = 114] = "GreaterThanGreaterThanGreaterThanEqualsToken";
- SyntaxKind[SyntaxKind["AmpersandEqualsToken"] = 115] = "AmpersandEqualsToken";
- SyntaxKind[SyntaxKind["BarEqualsToken"] = 116] = "BarEqualsToken";
- SyntaxKind[SyntaxKind["CaretEqualsToken"] = 117] = "CaretEqualsToken";
- SyntaxKind[SyntaxKind["SlashToken"] = 118] = "SlashToken";
- SyntaxKind[SyntaxKind["SlashEqualsToken"] = 119] = "SlashEqualsToken";
+ SyntaxKind[SyntaxKind["OpenBraceToken"] = 71] = "OpenBraceToken";
+ SyntaxKind[SyntaxKind["CloseBraceToken"] = 72] = "CloseBraceToken";
+ SyntaxKind[SyntaxKind["OpenParenToken"] = 73] = "OpenParenToken";
+ SyntaxKind[SyntaxKind["CloseParenToken"] = 74] = "CloseParenToken";
+ SyntaxKind[SyntaxKind["OpenBracketToken"] = 75] = "OpenBracketToken";
+ SyntaxKind[SyntaxKind["CloseBracketToken"] = 76] = "CloseBracketToken";
+ SyntaxKind[SyntaxKind["DotToken"] = 77] = "DotToken";
+ SyntaxKind[SyntaxKind["DotDotDotToken"] = 78] = "DotDotDotToken";
+ SyntaxKind[SyntaxKind["SemicolonToken"] = 79] = "SemicolonToken";
+ SyntaxKind[SyntaxKind["CommaToken"] = 80] = "CommaToken";
+ SyntaxKind[SyntaxKind["LessThanToken"] = 81] = "LessThanToken";
+ SyntaxKind[SyntaxKind["GreaterThanToken"] = 82] = "GreaterThanToken";
+ SyntaxKind[SyntaxKind["LessThanEqualsToken"] = 83] = "LessThanEqualsToken";
+ SyntaxKind[SyntaxKind["GreaterThanEqualsToken"] = 84] = "GreaterThanEqualsToken";
+ SyntaxKind[SyntaxKind["EqualsEqualsToken"] = 85] = "EqualsEqualsToken";
+ SyntaxKind[SyntaxKind["EqualsGreaterThanToken"] = 86] = "EqualsGreaterThanToken";
+ SyntaxKind[SyntaxKind["ExclamationEqualsToken"] = 87] = "ExclamationEqualsToken";
+ SyntaxKind[SyntaxKind["EqualsEqualsEqualsToken"] = 88] = "EqualsEqualsEqualsToken";
+ SyntaxKind[SyntaxKind["ExclamationEqualsEqualsToken"] = 89] = "ExclamationEqualsEqualsToken";
+ SyntaxKind[SyntaxKind["PlusToken"] = 90] = "PlusToken";
+ SyntaxKind[SyntaxKind["MinusToken"] = 91] = "MinusToken";
+ SyntaxKind[SyntaxKind["AsteriskToken"] = 92] = "AsteriskToken";
+ SyntaxKind[SyntaxKind["PercentToken"] = 93] = "PercentToken";
+ SyntaxKind[SyntaxKind["PlusPlusToken"] = 94] = "PlusPlusToken";
+ SyntaxKind[SyntaxKind["MinusMinusToken"] = 95] = "MinusMinusToken";
+ SyntaxKind[SyntaxKind["LessThanLessThanToken"] = 96] = "LessThanLessThanToken";
+ SyntaxKind[SyntaxKind["GreaterThanGreaterThanToken"] = 97] = "GreaterThanGreaterThanToken";
+ SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanToken"] = 98] = "GreaterThanGreaterThanGreaterThanToken";
+ SyntaxKind[SyntaxKind["AmpersandToken"] = 99] = "AmpersandToken";
+ SyntaxKind[SyntaxKind["BarToken"] = 100] = "BarToken";
+ SyntaxKind[SyntaxKind["CaretToken"] = 101] = "CaretToken";
+ SyntaxKind[SyntaxKind["ExclamationToken"] = 102] = "ExclamationToken";
+ SyntaxKind[SyntaxKind["TildeToken"] = 103] = "TildeToken";
+ SyntaxKind[SyntaxKind["AmpersandAmpersandToken"] = 104] = "AmpersandAmpersandToken";
+ SyntaxKind[SyntaxKind["BarBarToken"] = 105] = "BarBarToken";
+ SyntaxKind[SyntaxKind["QuestionToken"] = 106] = "QuestionToken";
+ SyntaxKind[SyntaxKind["ColonToken"] = 107] = "ColonToken";
+ SyntaxKind[SyntaxKind["EqualsToken"] = 108] = "EqualsToken";
+ SyntaxKind[SyntaxKind["PlusEqualsToken"] = 109] = "PlusEqualsToken";
+ SyntaxKind[SyntaxKind["MinusEqualsToken"] = 110] = "MinusEqualsToken";
+ SyntaxKind[SyntaxKind["AsteriskEqualsToken"] = 111] = "AsteriskEqualsToken";
+ SyntaxKind[SyntaxKind["PercentEqualsToken"] = 112] = "PercentEqualsToken";
+ SyntaxKind[SyntaxKind["LessThanLessThanEqualsToken"] = 113] = "LessThanLessThanEqualsToken";
+ SyntaxKind[SyntaxKind["GreaterThanGreaterThanEqualsToken"] = 114] = "GreaterThanGreaterThanEqualsToken";
+ SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanEqualsToken"] = 115] = "GreaterThanGreaterThanGreaterThanEqualsToken";
+ SyntaxKind[SyntaxKind["AmpersandEqualsToken"] = 116] = "AmpersandEqualsToken";
+ SyntaxKind[SyntaxKind["BarEqualsToken"] = 117] = "BarEqualsToken";
+ SyntaxKind[SyntaxKind["CaretEqualsToken"] = 118] = "CaretEqualsToken";
+ SyntaxKind[SyntaxKind["SlashToken"] = 119] = "SlashToken";
+ SyntaxKind[SyntaxKind["SlashEqualsToken"] = 120] = "SlashEqualsToken";
- SyntaxKind[SyntaxKind["SourceUnit"] = 120] = "SourceUnit";
+ SyntaxKind[SyntaxKind["SourceUnit"] = 121] = "SourceUnit";
- SyntaxKind[SyntaxKind["QualifiedName"] = 121] = "QualifiedName";
+ SyntaxKind[SyntaxKind["QualifiedName"] = 122] = "QualifiedName";
- SyntaxKind[SyntaxKind["ObjectType"] = 122] = "ObjectType";
- SyntaxKind[SyntaxKind["FunctionType"] = 123] = "FunctionType";
- SyntaxKind[SyntaxKind["ArrayType"] = 124] = "ArrayType";
- SyntaxKind[SyntaxKind["ConstructorType"] = 125] = "ConstructorType";
- SyntaxKind[SyntaxKind["GenericType"] = 126] = "GenericType";
- SyntaxKind[SyntaxKind["TypeQuery"] = 127] = "TypeQuery";
+ SyntaxKind[SyntaxKind["ObjectType"] = 123] = "ObjectType";
+ SyntaxKind[SyntaxKind["FunctionType"] = 124] = "FunctionType";
+ SyntaxKind[SyntaxKind["ArrayType"] = 125] = "ArrayType";
+ SyntaxKind[SyntaxKind["ConstructorType"] = 126] = "ConstructorType";
+ SyntaxKind[SyntaxKind["GenericType"] = 127] = "GenericType";
+ SyntaxKind[SyntaxKind["TypeQuery"] = 128] = "TypeQuery";
- SyntaxKind[SyntaxKind["InterfaceDeclaration"] = 128] = "InterfaceDeclaration";
- SyntaxKind[SyntaxKind["FunctionDeclaration"] = 129] = "FunctionDeclaration";
- SyntaxKind[SyntaxKind["ModuleDeclaration"] = 130] = "ModuleDeclaration";
- SyntaxKind[SyntaxKind["ClassDeclaration"] = 131] = "ClassDeclaration";
- SyntaxKind[SyntaxKind["EnumDeclaration"] = 132] = "EnumDeclaration";
- SyntaxKind[SyntaxKind["ImportDeclaration"] = 133] = "ImportDeclaration";
- SyntaxKind[SyntaxKind["ExportAssignment"] = 134] = "ExportAssignment";
+ SyntaxKind[SyntaxKind["InterfaceDeclaration"] = 129] = "InterfaceDeclaration";
+ SyntaxKind[SyntaxKind["FunctionDeclaration"] = 130] = "FunctionDeclaration";
+ SyntaxKind[SyntaxKind["ModuleDeclaration"] = 131] = "ModuleDeclaration";
+ SyntaxKind[SyntaxKind["ClassDeclaration"] = 132] = "ClassDeclaration";
+ SyntaxKind[SyntaxKind["EnumDeclaration"] = 133] = "EnumDeclaration";
+ SyntaxKind[SyntaxKind["ImportDeclaration"] = 134] = "ImportDeclaration";
+ SyntaxKind[SyntaxKind["ExportAssignment"] = 135] = "ExportAssignment";
- SyntaxKind[SyntaxKind["MemberFunctionDeclaration"] = 135] = "MemberFunctionDeclaration";
- SyntaxKind[SyntaxKind["MemberVariableDeclaration"] = 136] = "MemberVariableDeclaration";
- SyntaxKind[SyntaxKind["ConstructorDeclaration"] = 137] = "ConstructorDeclaration";
- SyntaxKind[SyntaxKind["GetMemberAccessorDeclaration"] = 138] = "GetMemberAccessorDeclaration";
- SyntaxKind[SyntaxKind["SetMemberAccessorDeclaration"] = 139] = "SetMemberAccessorDeclaration";
+ SyntaxKind[SyntaxKind["MemberFunctionDeclaration"] = 136] = "MemberFunctionDeclaration";
+ SyntaxKind[SyntaxKind["MemberVariableDeclaration"] = 137] = "MemberVariableDeclaration";
+ SyntaxKind[SyntaxKind["ConstructorDeclaration"] = 138] = "ConstructorDeclaration";
+ SyntaxKind[SyntaxKind["GetMemberAccessorDeclaration"] = 139] = "GetMemberAccessorDeclaration";
+ SyntaxKind[SyntaxKind["SetMemberAccessorDeclaration"] = 140] = "SetMemberAccessorDeclaration";
- SyntaxKind[SyntaxKind["PropertySignature"] = 140] = "PropertySignature";
- SyntaxKind[SyntaxKind["CallSignature"] = 141] = "CallSignature";
- SyntaxKind[SyntaxKind["ConstructSignature"] = 142] = "ConstructSignature";
- SyntaxKind[SyntaxKind["IndexSignature"] = 143] = "IndexSignature";
- SyntaxKind[SyntaxKind["MethodSignature"] = 144] = "MethodSignature";
+ SyntaxKind[SyntaxKind["PropertySignature"] = 141] = "PropertySignature";
+ SyntaxKind[SyntaxKind["CallSignature"] = 142] = "CallSignature";
+ SyntaxKind[SyntaxKind["ConstructSignature"] = 143] = "ConstructSignature";
+ SyntaxKind[SyntaxKind["IndexSignature"] = 144] = "IndexSignature";
+ SyntaxKind[SyntaxKind["MethodSignature"] = 145] = "MethodSignature";
- SyntaxKind[SyntaxKind["Block"] = 145] = "Block";
- SyntaxKind[SyntaxKind["IfStatement"] = 146] = "IfStatement";
- SyntaxKind[SyntaxKind["VariableStatement"] = 147] = "VariableStatement";
- SyntaxKind[SyntaxKind["ExpressionStatement"] = 148] = "ExpressionStatement";
- SyntaxKind[SyntaxKind["ReturnStatement"] = 149] = "ReturnStatement";
- SyntaxKind[SyntaxKind["SwitchStatement"] = 150] = "SwitchStatement";
- SyntaxKind[SyntaxKind["BreakStatement"] = 151] = "BreakStatement";
- SyntaxKind[SyntaxKind["ContinueStatement"] = 152] = "ContinueStatement";
- SyntaxKind[SyntaxKind["ForStatement"] = 153] = "ForStatement";
- SyntaxKind[SyntaxKind["ForInStatement"] = 154] = "ForInStatement";
- SyntaxKind[SyntaxKind["EmptyStatement"] = 155] = "EmptyStatement";
- SyntaxKind[SyntaxKind["ThrowStatement"] = 156] = "ThrowStatement";
- SyntaxKind[SyntaxKind["WhileStatement"] = 157] = "WhileStatement";
- SyntaxKind[SyntaxKind["TryStatement"] = 158] = "TryStatement";
- SyntaxKind[SyntaxKind["LabeledStatement"] = 159] = "LabeledStatement";
- SyntaxKind[SyntaxKind["DoStatement"] = 160] = "DoStatement";
- SyntaxKind[SyntaxKind["DebuggerStatement"] = 161] = "DebuggerStatement";
- SyntaxKind[SyntaxKind["WithStatement"] = 162] = "WithStatement";
+ SyntaxKind[SyntaxKind["Block"] = 146] = "Block";
+ SyntaxKind[SyntaxKind["IfStatement"] = 147] = "IfStatement";
+ SyntaxKind[SyntaxKind["VariableStatement"] = 148] = "VariableStatement";
+ SyntaxKind[SyntaxKind["ExpressionStatement"] = 149] = "ExpressionStatement";
+ SyntaxKind[SyntaxKind["ReturnStatement"] = 150] = "ReturnStatement";
+ SyntaxKind[SyntaxKind["SwitchStatement"] = 151] = "SwitchStatement";
+ SyntaxKind[SyntaxKind["BreakStatement"] = 152] = "BreakStatement";
+ SyntaxKind[SyntaxKind["ContinueStatement"] = 153] = "ContinueStatement";
+ SyntaxKind[SyntaxKind["ForStatement"] = 154] = "ForStatement";
+ SyntaxKind[SyntaxKind["ForInStatement"] = 155] = "ForInStatement";
+ SyntaxKind[SyntaxKind["EmptyStatement"] = 156] = "EmptyStatement";
+ SyntaxKind[SyntaxKind["ThrowStatement"] = 157] = "ThrowStatement";
+ SyntaxKind[SyntaxKind["WhileStatement"] = 158] = "WhileStatement";
+ SyntaxKind[SyntaxKind["TryStatement"] = 159] = "TryStatement";
+ SyntaxKind[SyntaxKind["LabeledStatement"] = 160] = "LabeledStatement";
+ SyntaxKind[SyntaxKind["DoStatement"] = 161] = "DoStatement";
+ SyntaxKind[SyntaxKind["DebuggerStatement"] = 162] = "DebuggerStatement";
+ SyntaxKind[SyntaxKind["WithStatement"] = 163] = "WithStatement";
- SyntaxKind[SyntaxKind["PlusExpression"] = 163] = "PlusExpression";
- SyntaxKind[SyntaxKind["NegateExpression"] = 164] = "NegateExpression";
- SyntaxKind[SyntaxKind["BitwiseNotExpression"] = 165] = "BitwiseNotExpression";
- SyntaxKind[SyntaxKind["LogicalNotExpression"] = 166] = "LogicalNotExpression";
- SyntaxKind[SyntaxKind["PreIncrementExpression"] = 167] = "PreIncrementExpression";
- SyntaxKind[SyntaxKind["PreDecrementExpression"] = 168] = "PreDecrementExpression";
- SyntaxKind[SyntaxKind["DeleteExpression"] = 169] = "DeleteExpression";
- SyntaxKind[SyntaxKind["TypeOfExpression"] = 170] = "TypeOfExpression";
- SyntaxKind[SyntaxKind["VoidExpression"] = 171] = "VoidExpression";
- SyntaxKind[SyntaxKind["CommaExpression"] = 172] = "CommaExpression";
- SyntaxKind[SyntaxKind["AssignmentExpression"] = 173] = "AssignmentExpression";
- SyntaxKind[SyntaxKind["AddAssignmentExpression"] = 174] = "AddAssignmentExpression";
- SyntaxKind[SyntaxKind["SubtractAssignmentExpression"] = 175] = "SubtractAssignmentExpression";
- SyntaxKind[SyntaxKind["MultiplyAssignmentExpression"] = 176] = "MultiplyAssignmentExpression";
- SyntaxKind[SyntaxKind["DivideAssignmentExpression"] = 177] = "DivideAssignmentExpression";
- SyntaxKind[SyntaxKind["ModuloAssignmentExpression"] = 178] = "ModuloAssignmentExpression";
- SyntaxKind[SyntaxKind["AndAssignmentExpression"] = 179] = "AndAssignmentExpression";
- SyntaxKind[SyntaxKind["ExclusiveOrAssignmentExpression"] = 180] = "ExclusiveOrAssignmentExpression";
- SyntaxKind[SyntaxKind["OrAssignmentExpression"] = 181] = "OrAssignmentExpression";
- SyntaxKind[SyntaxKind["LeftShiftAssignmentExpression"] = 182] = "LeftShiftAssignmentExpression";
- SyntaxKind[SyntaxKind["SignedRightShiftAssignmentExpression"] = 183] = "SignedRightShiftAssignmentExpression";
- SyntaxKind[SyntaxKind["UnsignedRightShiftAssignmentExpression"] = 184] = "UnsignedRightShiftAssignmentExpression";
- SyntaxKind[SyntaxKind["ConditionalExpression"] = 185] = "ConditionalExpression";
- SyntaxKind[SyntaxKind["LogicalOrExpression"] = 186] = "LogicalOrExpression";
- SyntaxKind[SyntaxKind["LogicalAndExpression"] = 187] = "LogicalAndExpression";
- SyntaxKind[SyntaxKind["BitwiseOrExpression"] = 188] = "BitwiseOrExpression";
- SyntaxKind[SyntaxKind["BitwiseExclusiveOrExpression"] = 189] = "BitwiseExclusiveOrExpression";
- SyntaxKind[SyntaxKind["BitwiseAndExpression"] = 190] = "BitwiseAndExpression";
- SyntaxKind[SyntaxKind["EqualsWithTypeConversionExpression"] = 191] = "EqualsWithTypeConversionExpression";
- SyntaxKind[SyntaxKind["NotEqualsWithTypeConversionExpression"] = 192] = "NotEqualsWithTypeConversionExpression";
- SyntaxKind[SyntaxKind["EqualsExpression"] = 193] = "EqualsExpression";
- SyntaxKind[SyntaxKind["NotEqualsExpression"] = 194] = "NotEqualsExpression";
- SyntaxKind[SyntaxKind["LessThanExpression"] = 195] = "LessThanExpression";
- SyntaxKind[SyntaxKind["GreaterThanExpression"] = 196] = "GreaterThanExpression";
- SyntaxKind[SyntaxKind["LessThanOrEqualExpression"] = 197] = "LessThanOrEqualExpression";
- SyntaxKind[SyntaxKind["GreaterThanOrEqualExpression"] = 198] = "GreaterThanOrEqualExpression";
- SyntaxKind[SyntaxKind["InstanceOfExpression"] = 199] = "InstanceOfExpression";
- SyntaxKind[SyntaxKind["InExpression"] = 200] = "InExpression";
- SyntaxKind[SyntaxKind["LeftShiftExpression"] = 201] = "LeftShiftExpression";
- SyntaxKind[SyntaxKind["SignedRightShiftExpression"] = 202] = "SignedRightShiftExpression";
- SyntaxKind[SyntaxKind["UnsignedRightShiftExpression"] = 203] = "UnsignedRightShiftExpression";
- SyntaxKind[SyntaxKind["MultiplyExpression"] = 204] = "MultiplyExpression";
- SyntaxKind[SyntaxKind["DivideExpression"] = 205] = "DivideExpression";
- SyntaxKind[SyntaxKind["ModuloExpression"] = 206] = "ModuloExpression";
- SyntaxKind[SyntaxKind["AddExpression"] = 207] = "AddExpression";
- SyntaxKind[SyntaxKind["SubtractExpression"] = 208] = "SubtractExpression";
- SyntaxKind[SyntaxKind["PostIncrementExpression"] = 209] = "PostIncrementExpression";
- SyntaxKind[SyntaxKind["PostDecrementExpression"] = 210] = "PostDecrementExpression";
- SyntaxKind[SyntaxKind["MemberAccessExpression"] = 211] = "MemberAccessExpression";
- SyntaxKind[SyntaxKind["InvocationExpression"] = 212] = "InvocationExpression";
- SyntaxKind[SyntaxKind["ArrayLiteralExpression"] = 213] = "ArrayLiteralExpression";
- SyntaxKind[SyntaxKind["ObjectLiteralExpression"] = 214] = "ObjectLiteralExpression";
- SyntaxKind[SyntaxKind["ObjectCreationExpression"] = 215] = "ObjectCreationExpression";
- SyntaxKind[SyntaxKind["ParenthesizedExpression"] = 216] = "ParenthesizedExpression";
- SyntaxKind[SyntaxKind["ParenthesizedArrowFunctionExpression"] = 217] = "ParenthesizedArrowFunctionExpression";
- SyntaxKind[SyntaxKind["SimpleArrowFunctionExpression"] = 218] = "SimpleArrowFunctionExpression";
- SyntaxKind[SyntaxKind["CastExpression"] = 219] = "CastExpression";
- SyntaxKind[SyntaxKind["ElementAccessExpression"] = 220] = "ElementAccessExpression";
- SyntaxKind[SyntaxKind["FunctionExpression"] = 221] = "FunctionExpression";
- SyntaxKind[SyntaxKind["OmittedExpression"] = 222] = "OmittedExpression";
+ SyntaxKind[SyntaxKind["PlusExpression"] = 164] = "PlusExpression";
+ SyntaxKind[SyntaxKind["NegateExpression"] = 165] = "NegateExpression";
+ SyntaxKind[SyntaxKind["BitwiseNotExpression"] = 166] = "BitwiseNotExpression";
+ SyntaxKind[SyntaxKind["LogicalNotExpression"] = 167] = "LogicalNotExpression";
+ SyntaxKind[SyntaxKind["PreIncrementExpression"] = 168] = "PreIncrementExpression";
+ SyntaxKind[SyntaxKind["PreDecrementExpression"] = 169] = "PreDecrementExpression";
+ SyntaxKind[SyntaxKind["DeleteExpression"] = 170] = "DeleteExpression";
+ SyntaxKind[SyntaxKind["TypeOfExpression"] = 171] = "TypeOfExpression";
+ SyntaxKind[SyntaxKind["VoidExpression"] = 172] = "VoidExpression";
+ SyntaxKind[SyntaxKind["CommaExpression"] = 173] = "CommaExpression";
+ SyntaxKind[SyntaxKind["AssignmentExpression"] = 174] = "AssignmentExpression";
+ SyntaxKind[SyntaxKind["AddAssignmentExpression"] = 175] = "AddAssignmentExpression";
+ SyntaxKind[SyntaxKind["SubtractAssignmentExpression"] = 176] = "SubtractAssignmentExpression";
+ SyntaxKind[SyntaxKind["MultiplyAssignmentExpression"] = 177] = "MultiplyAssignmentExpression";
+ SyntaxKind[SyntaxKind["DivideAssignmentExpression"] = 178] = "DivideAssignmentExpression";
+ SyntaxKind[SyntaxKind["ModuloAssignmentExpression"] = 179] = "ModuloAssignmentExpression";
+ SyntaxKind[SyntaxKind["AndAssignmentExpression"] = 180] = "AndAssignmentExpression";
+ SyntaxKind[SyntaxKind["ExclusiveOrAssignmentExpression"] = 181] = "ExclusiveOrAssignmentExpression";
+ SyntaxKind[SyntaxKind["OrAssignmentExpression"] = 182] = "OrAssignmentExpression";
+ SyntaxKind[SyntaxKind["LeftShiftAssignmentExpression"] = 183] = "LeftShiftAssignmentExpression";
+ SyntaxKind[SyntaxKind["SignedRightShiftAssignmentExpression"] = 184] = "SignedRightShiftAssignmentExpression";
+ SyntaxKind[SyntaxKind["UnsignedRightShiftAssignmentExpression"] = 185] = "UnsignedRightShiftAssignmentExpression";
+ SyntaxKind[SyntaxKind["ConditionalExpression"] = 186] = "ConditionalExpression";
+ SyntaxKind[SyntaxKind["LogicalOrExpression"] = 187] = "LogicalOrExpression";
+ SyntaxKind[SyntaxKind["LogicalAndExpression"] = 188] = "LogicalAndExpression";
+ SyntaxKind[SyntaxKind["BitwiseOrExpression"] = 189] = "BitwiseOrExpression";
+ SyntaxKind[SyntaxKind["BitwiseExclusiveOrExpression"] = 190] = "BitwiseExclusiveOrExpression";
+ SyntaxKind[SyntaxKind["BitwiseAndExpression"] = 191] = "BitwiseAndExpression";
+ SyntaxKind[SyntaxKind["EqualsWithTypeConversionExpression"] = 192] = "EqualsWithTypeConversionExpression";
+ SyntaxKind[SyntaxKind["NotEqualsWithTypeConversionExpression"] = 193] = "NotEqualsWithTypeConversionExpression";
+ SyntaxKind[SyntaxKind["EqualsExpression"] = 194] = "EqualsExpression";
+ SyntaxKind[SyntaxKind["NotEqualsExpression"] = 195] = "NotEqualsExpression";
+ SyntaxKind[SyntaxKind["LessThanExpression"] = 196] = "LessThanExpression";
+ SyntaxKind[SyntaxKind["GreaterThanExpression"] = 197] = "GreaterThanExpression";
+ SyntaxKind[SyntaxKind["LessThanOrEqualExpression"] = 198] = "LessThanOrEqualExpression";
+ SyntaxKind[SyntaxKind["GreaterThanOrEqualExpression"] = 199] = "GreaterThanOrEqualExpression";
+ SyntaxKind[SyntaxKind["InstanceOfExpression"] = 200] = "InstanceOfExpression";
+ SyntaxKind[SyntaxKind["InExpression"] = 201] = "InExpression";
+ SyntaxKind[SyntaxKind["LeftShiftExpression"] = 202] = "LeftShiftExpression";
+ SyntaxKind[SyntaxKind["SignedRightShiftExpression"] = 203] = "SignedRightShiftExpression";
+ SyntaxKind[SyntaxKind["UnsignedRightShiftExpression"] = 204] = "UnsignedRightShiftExpression";
+ SyntaxKind[SyntaxKind["MultiplyExpression"] = 205] = "MultiplyExpression";
+ SyntaxKind[SyntaxKind["DivideExpression"] = 206] = "DivideExpression";
+ SyntaxKind[SyntaxKind["ModuloExpression"] = 207] = "ModuloExpression";
+ SyntaxKind[SyntaxKind["AddExpression"] = 208] = "AddExpression";
+ SyntaxKind[SyntaxKind["SubtractExpression"] = 209] = "SubtractExpression";
+ SyntaxKind[SyntaxKind["PostIncrementExpression"] = 210] = "PostIncrementExpression";
+ SyntaxKind[SyntaxKind["PostDecrementExpression"] = 211] = "PostDecrementExpression";
+ SyntaxKind[SyntaxKind["MemberAccessExpression"] = 212] = "MemberAccessExpression";
+ SyntaxKind[SyntaxKind["InvocationExpression"] = 213] = "InvocationExpression";
+ SyntaxKind[SyntaxKind["ArrayLiteralExpression"] = 214] = "ArrayLiteralExpression";
+ SyntaxKind[SyntaxKind["ObjectLiteralExpression"] = 215] = "ObjectLiteralExpression";
+ SyntaxKind[SyntaxKind["ObjectCreationExpression"] = 216] = "ObjectCreationExpression";
+ SyntaxKind[SyntaxKind["ParenthesizedExpression"] = 217] = "ParenthesizedExpression";
+ SyntaxKind[SyntaxKind["ParenthesizedArrowFunctionExpression"] = 218] = "ParenthesizedArrowFunctionExpression";
+ SyntaxKind[SyntaxKind["SimpleArrowFunctionExpression"] = 219] = "SimpleArrowFunctionExpression";
+ SyntaxKind[SyntaxKind["CastExpression"] = 220] = "CastExpression";
+ SyntaxKind[SyntaxKind["ElementAccessExpression"] = 221] = "ElementAccessExpression";
+ SyntaxKind[SyntaxKind["FunctionExpression"] = 222] = "FunctionExpression";
+ SyntaxKind[SyntaxKind["OmittedExpression"] = 223] = "OmittedExpression";
- SyntaxKind[SyntaxKind["VariableDeclaration"] = 223] = "VariableDeclaration";
- SyntaxKind[SyntaxKind["VariableDeclarator"] = 224] = "VariableDeclarator";
+ SyntaxKind[SyntaxKind["VariableDeclaration"] = 224] = "VariableDeclaration";
+ SyntaxKind[SyntaxKind["VariableDeclarator"] = 225] = "VariableDeclarator";
- SyntaxKind[SyntaxKind["ArgumentList"] = 225] = "ArgumentList";
- SyntaxKind[SyntaxKind["ParameterList"] = 226] = "ParameterList";
- SyntaxKind[SyntaxKind["TypeArgumentList"] = 227] = "TypeArgumentList";
- SyntaxKind[SyntaxKind["TypeParameterList"] = 228] = "TypeParameterList";
+ SyntaxKind[SyntaxKind["ArgumentList"] = 226] = "ArgumentList";
+ SyntaxKind[SyntaxKind["ParameterList"] = 227] = "ParameterList";
+ SyntaxKind[SyntaxKind["TypeArgumentList"] = 228] = "TypeArgumentList";
+ SyntaxKind[SyntaxKind["TypeParameterList"] = 229] = "TypeParameterList";
- SyntaxKind[SyntaxKind["HeritageClause"] = 229] = "HeritageClause";
- SyntaxKind[SyntaxKind["EqualsValueClause"] = 230] = "EqualsValueClause";
- SyntaxKind[SyntaxKind["CaseSwitchClause"] = 231] = "CaseSwitchClause";
- SyntaxKind[SyntaxKind["DefaultSwitchClause"] = 232] = "DefaultSwitchClause";
- SyntaxKind[SyntaxKind["ElseClause"] = 233] = "ElseClause";
- SyntaxKind[SyntaxKind["CatchClause"] = 234] = "CatchClause";
- SyntaxKind[SyntaxKind["FinallyClause"] = 235] = "FinallyClause";
+ SyntaxKind[SyntaxKind["HeritageClause"] = 230] = "HeritageClause";
+ SyntaxKind[SyntaxKind["EqualsValueClause"] = 231] = "EqualsValueClause";
+ SyntaxKind[SyntaxKind["CaseSwitchClause"] = 232] = "CaseSwitchClause";
+ SyntaxKind[SyntaxKind["DefaultSwitchClause"] = 233] = "DefaultSwitchClause";
+ SyntaxKind[SyntaxKind["ElseClause"] = 234] = "ElseClause";
+ SyntaxKind[SyntaxKind["CatchClause"] = 235] = "CatchClause";
+ SyntaxKind[SyntaxKind["FinallyClause"] = 236] = "FinallyClause";
- SyntaxKind[SyntaxKind["TypeParameter"] = 236] = "TypeParameter";
- SyntaxKind[SyntaxKind["Constraint"] = 237] = "Constraint";
+ SyntaxKind[SyntaxKind["TypeParameter"] = 237] = "TypeParameter";
+ SyntaxKind[SyntaxKind["Constraint"] = 238] = "Constraint";
- SyntaxKind[SyntaxKind["SimplePropertyAssignment"] = 238] = "SimplePropertyAssignment";
- SyntaxKind[SyntaxKind["GetAccessorPropertyAssignment"] = 239] = "GetAccessorPropertyAssignment";
- SyntaxKind[SyntaxKind["SetAccessorPropertyAssignment"] = 240] = "SetAccessorPropertyAssignment";
- SyntaxKind[SyntaxKind["FunctionPropertyAssignment"] = 241] = "FunctionPropertyAssignment";
+ SyntaxKind[SyntaxKind["SimplePropertyAssignment"] = 239] = "SimplePropertyAssignment";
+ SyntaxKind[SyntaxKind["GetAccessorPropertyAssignment"] = 240] = "GetAccessorPropertyAssignment";
+ SyntaxKind[SyntaxKind["SetAccessorPropertyAssignment"] = 241] = "SetAccessorPropertyAssignment";
+ SyntaxKind[SyntaxKind["FunctionPropertyAssignment"] = 242] = "FunctionPropertyAssignment";
- SyntaxKind[SyntaxKind["Parameter"] = 242] = "Parameter";
- SyntaxKind[SyntaxKind["EnumElement"] = 243] = "EnumElement";
- SyntaxKind[SyntaxKind["TypeAnnotation"] = 244] = "TypeAnnotation";
- SyntaxKind[SyntaxKind["ExternalModuleReference"] = 245] = "ExternalModuleReference";
- SyntaxKind[SyntaxKind["ModuleNameModuleReference"] = 246] = "ModuleNameModuleReference";
+ SyntaxKind[SyntaxKind["Parameter"] = 243] = "Parameter";
+ SyntaxKind[SyntaxKind["EnumElement"] = 244] = "EnumElement";
+ SyntaxKind[SyntaxKind["TypeAnnotation"] = 245] = "TypeAnnotation";
+ SyntaxKind[SyntaxKind["ExternalModuleReference"] = 246] = "ExternalModuleReference";
+ SyntaxKind[SyntaxKind["ModuleNameModuleReference"] = 247] = "ModuleNameModuleReference";
SyntaxKind[SyntaxKind["FirstStandardKeyword"] = SyntaxKind.BreakKeyword] = "FirstStandardKeyword";
SyntaxKind[SyntaxKind["LastStandardKeyword"] = SyntaxKind.WithKeyword] = "LastStandardKeyword";
@@ -4989,6 +5054,7 @@ var TypeScript;
(function (SyntaxFacts) {
var textToKeywordKind = {
"any": 60 /* AnyKeyword */,
+ "bool": 62 /* BoolKeyword */,
"boolean": 61 /* BooleanKeyword */,
"break": 15 /* BreakKeyword */,
"case": 16 /* CaseKeyword */,
@@ -4996,9 +5062,9 @@ var TypeScript;
"class": 44 /* ClassKeyword */,
"continue": 18 /* ContinueKeyword */,
"const": 45 /* ConstKeyword */,
- "constructor": 62 /* ConstructorKeyword */,
+ "constructor": 63 /* ConstructorKeyword */,
"debugger": 19 /* DebuggerKeyword */,
- "declare": 63 /* DeclareKeyword */,
+ "declare": 64 /* DeclareKeyword */,
"default": 20 /* DefaultKeyword */,
"delete": 21 /* DeleteKeyword */,
"do": 22 /* DoKeyword */,
@@ -5010,7 +5076,7 @@ var TypeScript;
"finally": 25 /* FinallyKeyword */,
"for": 26 /* ForKeyword */,
"function": 27 /* FunctionKeyword */,
- "get": 64 /* GetKeyword */,
+ "get": 65 /* GetKeyword */,
"if": 28 /* IfKeyword */,
"implements": 51 /* ImplementsKeyword */,
"import": 49 /* ImportKeyword */,
@@ -5018,19 +5084,19 @@ var TypeScript;
"instanceof": 30 /* InstanceOfKeyword */,
"interface": 52 /* InterfaceKeyword */,
"let": 53 /* LetKeyword */,
- "module": 65 /* ModuleKeyword */,
+ "module": 66 /* ModuleKeyword */,
"new": 31 /* NewKeyword */,
"null": 32 /* NullKeyword */,
- "number": 67 /* NumberKeyword */,
+ "number": 68 /* NumberKeyword */,
"package": 54 /* PackageKeyword */,
"private": 55 /* PrivateKeyword */,
"protected": 56 /* ProtectedKeyword */,
"public": 57 /* PublicKeyword */,
- "require": 66 /* RequireKeyword */,
+ "require": 67 /* RequireKeyword */,
"return": 33 /* ReturnKeyword */,
- "set": 68 /* SetKeyword */,
+ "set": 69 /* SetKeyword */,
"static": 58 /* StaticKeyword */,
- "string": 69 /* StringKeyword */,
+ "string": 70 /* StringKeyword */,
"super": 50 /* SuperKeyword */,
"switch": 34 /* SwitchKeyword */,
"this": 35 /* ThisKeyword */,
@@ -5043,56 +5109,56 @@ var TypeScript;
"while": 42 /* WhileKeyword */,
"with": 43 /* WithKeyword */,
"yield": 59 /* YieldKeyword */,
- "{": 70 /* OpenBraceToken */,
- "}": 71 /* CloseBraceToken */,
- "(": 72 /* OpenParenToken */,
- ")": 73 /* CloseParenToken */,
- "[": 74 /* OpenBracketToken */,
- "]": 75 /* CloseBracketToken */,
- ".": 76 /* DotToken */,
- "...": 77 /* DotDotDotToken */,
- ";": 78 /* SemicolonToken */,
- ",": 79 /* CommaToken */,
- "<": 80 /* LessThanToken */,
- ">": 81 /* GreaterThanToken */,
- "<=": 82 /* LessThanEqualsToken */,
- ">=": 83 /* GreaterThanEqualsToken */,
- "==": 84 /* EqualsEqualsToken */,
- "=>": 85 /* EqualsGreaterThanToken */,
- "!=": 86 /* ExclamationEqualsToken */,
- "===": 87 /* EqualsEqualsEqualsToken */,
- "!==": 88 /* ExclamationEqualsEqualsToken */,
- "+": 89 /* PlusToken */,
- "-": 90 /* MinusToken */,
- "*": 91 /* AsteriskToken */,
- "%": 92 /* PercentToken */,
- "++": 93 /* PlusPlusToken */,
- "--": 94 /* MinusMinusToken */,
- "<<": 95 /* LessThanLessThanToken */,
- ">>": 96 /* GreaterThanGreaterThanToken */,
- ">>>": 97 /* GreaterThanGreaterThanGreaterThanToken */,
- "&": 98 /* AmpersandToken */,
- "|": 99 /* BarToken */,
- "^": 100 /* CaretToken */,
- "!": 101 /* ExclamationToken */,
- "~": 102 /* TildeToken */,
- "&&": 103 /* AmpersandAmpersandToken */,
- "||": 104 /* BarBarToken */,
- "?": 105 /* QuestionToken */,
- ":": 106 /* ColonToken */,
- "=": 107 /* EqualsToken */,
- "+=": 108 /* PlusEqualsToken */,
- "-=": 109 /* MinusEqualsToken */,
- "*=": 110 /* AsteriskEqualsToken */,
- "%=": 111 /* PercentEqualsToken */,
- "<<=": 112 /* LessThanLessThanEqualsToken */,
- ">>=": 113 /* GreaterThanGreaterThanEqualsToken */,
- ">>>=": 114 /* GreaterThanGreaterThanGreaterThanEqualsToken */,
- "&=": 115 /* AmpersandEqualsToken */,
- "|=": 116 /* BarEqualsToken */,
- "^=": 117 /* CaretEqualsToken */,
- "/": 118 /* SlashToken */,
- "/=": 119 /* SlashEqualsToken */
+ "{": 71 /* OpenBraceToken */,
+ "}": 72 /* CloseBraceToken */,
+ "(": 73 /* OpenParenToken */,
+ ")": 74 /* CloseParenToken */,
+ "[": 75 /* OpenBracketToken */,
+ "]": 76 /* CloseBracketToken */,
+ ".": 77 /* DotToken */,
+ "...": 78 /* DotDotDotToken */,
+ ";": 79 /* SemicolonToken */,
+ ",": 80 /* CommaToken */,
+ "<": 81 /* LessThanToken */,
+ ">": 82 /* GreaterThanToken */,
+ "<=": 83 /* LessThanEqualsToken */,
+ ">=": 84 /* GreaterThanEqualsToken */,
+ "==": 85 /* EqualsEqualsToken */,
+ "=>": 86 /* EqualsGreaterThanToken */,
+ "!=": 87 /* ExclamationEqualsToken */,
+ "===": 88 /* EqualsEqualsEqualsToken */,
+ "!==": 89 /* ExclamationEqualsEqualsToken */,
+ "+": 90 /* PlusToken */,
+ "-": 91 /* MinusToken */,
+ "*": 92 /* AsteriskToken */,
+ "%": 93 /* PercentToken */,
+ "++": 94 /* PlusPlusToken */,
+ "--": 95 /* MinusMinusToken */,
+ "<<": 96 /* LessThanLessThanToken */,
+ ">>": 97 /* GreaterThanGreaterThanToken */,
+ ">>>": 98 /* GreaterThanGreaterThanGreaterThanToken */,
+ "&": 99 /* AmpersandToken */,
+ "|": 100 /* BarToken */,
+ "^": 101 /* CaretToken */,
+ "!": 102 /* ExclamationToken */,
+ "~": 103 /* TildeToken */,
+ "&&": 104 /* AmpersandAmpersandToken */,
+ "||": 105 /* BarBarToken */,
+ "?": 106 /* QuestionToken */,
+ ":": 107 /* ColonToken */,
+ "=": 108 /* EqualsToken */,
+ "+=": 109 /* PlusEqualsToken */,
+ "-=": 110 /* MinusEqualsToken */,
+ "*=": 111 /* AsteriskEqualsToken */,
+ "%=": 112 /* PercentEqualsToken */,
+ "<<=": 113 /* LessThanLessThanEqualsToken */,
+ ">>=": 114 /* GreaterThanGreaterThanEqualsToken */,
+ ">>>=": 115 /* GreaterThanGreaterThanGreaterThanEqualsToken */,
+ "&=": 116 /* AmpersandEqualsToken */,
+ "|=": 117 /* BarEqualsToken */,
+ "^=": 118 /* CaretEqualsToken */,
+ "/": 119 /* SlashToken */,
+ "/=": 120 /* SlashEqualsToken */
};
var kindToText = new Array();
@@ -5103,7 +5169,7 @@ var TypeScript;
}
}
- kindToText[62 /* ConstructorKeyword */] = "constructor";
+ kindToText[63 /* ConstructorKeyword */] = "constructor";
function getTokenKind(text) {
if (textToKeywordKind.hasOwnProperty(text)) {
@@ -5121,12 +5187,12 @@ var TypeScript;
SyntaxFacts.getText = getText;
function isTokenKind(kind) {
- return kind >= 9 /* FirstToken */ && kind <= 119 /* LastToken */;
+ return kind >= 9 /* FirstToken */ && kind <= 120 /* LastToken */;
}
SyntaxFacts.isTokenKind = isTokenKind;
function isAnyKeyword(kind) {
- return kind >= 15 /* FirstKeyword */ && kind <= 69 /* LastKeyword */;
+ return kind >= 15 /* FirstKeyword */ && kind <= 70 /* LastKeyword */;
}
SyntaxFacts.isAnyKeyword = isAnyKeyword;
@@ -5146,7 +5212,7 @@ var TypeScript;
SyntaxFacts.isFutureReservedStrictKeyword = isFutureReservedStrictKeyword;
function isAnyPunctuation(kind) {
- return kind >= 70 /* FirstPunctuation */ && kind <= 119 /* LastPunctuation */;
+ return kind >= 71 /* FirstPunctuation */ && kind <= 120 /* LastPunctuation */;
}
SyntaxFacts.isAnyPunctuation = isAnyPunctuation;
@@ -5162,18 +5228,18 @@ var TypeScript;
function getPrefixUnaryExpressionFromOperatorToken(tokenKind) {
switch (tokenKind) {
- case 89 /* PlusToken */:
- return 163 /* PlusExpression */;
- case 90 /* MinusToken */:
- return 164 /* NegateExpression */;
- case 102 /* TildeToken */:
- return 165 /* BitwiseNotExpression */;
- case 101 /* ExclamationToken */:
- return 166 /* LogicalNotExpression */;
- case 93 /* PlusPlusToken */:
- return 167 /* PreIncrementExpression */;
- case 94 /* MinusMinusToken */:
- return 168 /* PreDecrementExpression */;
+ case 90 /* PlusToken */:
+ return 164 /* PlusExpression */;
+ case 91 /* MinusToken */:
+ return 165 /* NegateExpression */;
+ case 103 /* TildeToken */:
+ return 166 /* BitwiseNotExpression */;
+ case 102 /* ExclamationToken */:
+ return 167 /* LogicalNotExpression */;
+ case 94 /* PlusPlusToken */:
+ return 168 /* PreIncrementExpression */;
+ case 95 /* MinusMinusToken */:
+ return 169 /* PreDecrementExpression */;
default:
return 0 /* None */;
@@ -5183,10 +5249,10 @@ var TypeScript;
function getPostfixUnaryExpressionFromOperatorToken(tokenKind) {
switch (tokenKind) {
- case 93 /* PlusPlusToken */:
- return 209 /* PostIncrementExpression */;
- case 94 /* MinusMinusToken */:
- return 210 /* PostDecrementExpression */;
+ case 94 /* PlusPlusToken */:
+ return 210 /* PostIncrementExpression */;
+ case 95 /* MinusMinusToken */:
+ return 211 /* PostDecrementExpression */;
default:
return 0 /* None */;
}
@@ -5195,113 +5261,113 @@ var TypeScript;
function getBinaryExpressionFromOperatorToken(tokenKind) {
switch (tokenKind) {
- case 91 /* AsteriskToken */:
- return 204 /* MultiplyExpression */;
+ case 92 /* AsteriskToken */:
+ return 205 /* MultiplyExpression */;
- case 118 /* SlashToken */:
- return 205 /* DivideExpression */;
+ case 119 /* SlashToken */:
+ return 206 /* DivideExpression */;
- case 92 /* PercentToken */:
- return 206 /* ModuloExpression */;
+ case 93 /* PercentToken */:
+ return 207 /* ModuloExpression */;
- case 89 /* PlusToken */:
- return 207 /* AddExpression */;
+ case 90 /* PlusToken */:
+ return 208 /* AddExpression */;
- case 90 /* MinusToken */:
- return 208 /* SubtractExpression */;
+ case 91 /* MinusToken */:
+ return 209 /* SubtractExpression */;
- case 95 /* LessThanLessThanToken */:
- return 201 /* LeftShiftExpression */;
+ case 96 /* LessThanLessThanToken */:
+ return 202 /* LeftShiftExpression */;
- case 96 /* GreaterThanGreaterThanToken */:
- return 202 /* SignedRightShiftExpression */;
+ case 97 /* GreaterThanGreaterThanToken */:
+ return 203 /* SignedRightShiftExpression */;
- case 97 /* GreaterThanGreaterThanGreaterThanToken */:
- return 203 /* UnsignedRightShiftExpression */;
+ case 98 /* GreaterThanGreaterThanGreaterThanToken */:
+ return 204 /* UnsignedRightShiftExpression */;
- case 80 /* LessThanToken */:
- return 195 /* LessThanExpression */;
+ case 81 /* LessThanToken */:
+ return 196 /* LessThanExpression */;
- case 81 /* GreaterThanToken */:
- return 196 /* GreaterThanExpression */;
+ case 82 /* GreaterThanToken */:
+ return 197 /* GreaterThanExpression */;
- case 82 /* LessThanEqualsToken */:
- return 197 /* LessThanOrEqualExpression */;
+ case 83 /* LessThanEqualsToken */:
+ return 198 /* LessThanOrEqualExpression */;
- case 83 /* GreaterThanEqualsToken */:
- return 198 /* GreaterThanOrEqualExpression */;
+ case 84 /* GreaterThanEqualsToken */:
+ return 199 /* GreaterThanOrEqualExpression */;
case 30 /* InstanceOfKeyword */:
- return 199 /* InstanceOfExpression */;
+ return 200 /* InstanceOfExpression */;
case 29 /* InKeyword */:
- return 200 /* InExpression */;
+ return 201 /* InExpression */;
- case 84 /* EqualsEqualsToken */:
- return 191 /* EqualsWithTypeConversionExpression */;
+ case 85 /* EqualsEqualsToken */:
+ return 192 /* EqualsWithTypeConversionExpression */;
- case 86 /* ExclamationEqualsToken */:
- return 192 /* NotEqualsWithTypeConversionExpression */;
+ case 87 /* ExclamationEqualsToken */:
+ return 193 /* NotEqualsWithTypeConversionExpression */;
- case 87 /* EqualsEqualsEqualsToken */:
- return 193 /* EqualsExpression */;
+ case 88 /* EqualsEqualsEqualsToken */:
+ return 194 /* EqualsExpression */;
- case 88 /* ExclamationEqualsEqualsToken */:
- return 194 /* NotEqualsExpression */;
+ case 89 /* ExclamationEqualsEqualsToken */:
+ return 195 /* NotEqualsExpression */;
- case 98 /* AmpersandToken */:
- return 190 /* BitwiseAndExpression */;
+ case 99 /* AmpersandToken */:
+ return 191 /* BitwiseAndExpression */;
- case 100 /* CaretToken */:
- return 189 /* BitwiseExclusiveOrExpression */;
+ case 101 /* CaretToken */:
+ return 190 /* BitwiseExclusiveOrExpression */;
- case 99 /* BarToken */:
- return 188 /* BitwiseOrExpression */;
+ case 100 /* BarToken */:
+ return 189 /* BitwiseOrExpression */;
- case 103 /* AmpersandAmpersandToken */:
- return 187 /* LogicalAndExpression */;
+ case 104 /* AmpersandAmpersandToken */:
+ return 188 /* LogicalAndExpression */;
- case 104 /* BarBarToken */:
- return 186 /* LogicalOrExpression */;
+ case 105 /* BarBarToken */:
+ return 187 /* LogicalOrExpression */;
- case 116 /* BarEqualsToken */:
- return 181 /* OrAssignmentExpression */;
+ case 117 /* BarEqualsToken */:
+ return 182 /* OrAssignmentExpression */;
- case 115 /* AmpersandEqualsToken */:
- return 179 /* AndAssignmentExpression */;
+ case 116 /* AmpersandEqualsToken */:
+ return 180 /* AndAssignmentExpression */;
- case 117 /* CaretEqualsToken */:
- return 180 /* ExclusiveOrAssignmentExpression */;
+ case 118 /* CaretEqualsToken */:
+ return 181 /* ExclusiveOrAssignmentExpression */;
- case 112 /* LessThanLessThanEqualsToken */:
- return 182 /* LeftShiftAssignmentExpression */;
+ case 113 /* LessThanLessThanEqualsToken */:
+ return 183 /* LeftShiftAssignmentExpression */;
- case 113 /* GreaterThanGreaterThanEqualsToken */:
- return 183 /* SignedRightShiftAssignmentExpression */;
+ case 114 /* GreaterThanGreaterThanEqualsToken */:
+ return 184 /* SignedRightShiftAssignmentExpression */;
- case 114 /* GreaterThanGreaterThanGreaterThanEqualsToken */:
- return 184 /* UnsignedRightShiftAssignmentExpression */;
+ case 115 /* GreaterThanGreaterThanGreaterThanEqualsToken */:
+ return 185 /* UnsignedRightShiftAssignmentExpression */;
- case 108 /* PlusEqualsToken */:
- return 174 /* AddAssignmentExpression */;
+ case 109 /* PlusEqualsToken */:
+ return 175 /* AddAssignmentExpression */;
- case 109 /* MinusEqualsToken */:
- return 175 /* SubtractAssignmentExpression */;
+ case 110 /* MinusEqualsToken */:
+ return 176 /* SubtractAssignmentExpression */;
- case 110 /* AsteriskEqualsToken */:
- return 176 /* MultiplyAssignmentExpression */;
+ case 111 /* AsteriskEqualsToken */:
+ return 177 /* MultiplyAssignmentExpression */;
- case 119 /* SlashEqualsToken */:
- return 177 /* DivideAssignmentExpression */;
+ case 120 /* SlashEqualsToken */:
+ return 178 /* DivideAssignmentExpression */;
- case 111 /* PercentEqualsToken */:
- return 178 /* ModuloAssignmentExpression */;
+ case 112 /* PercentEqualsToken */:
+ return 179 /* ModuloAssignmentExpression */;
- case 107 /* EqualsToken */:
- return 173 /* AssignmentExpression */;
+ case 108 /* EqualsToken */:
+ return 174 /* AssignmentExpression */;
- case 79 /* CommaToken */:
- return 172 /* CommaExpression */;
+ case 80 /* CommaToken */:
+ return 173 /* CommaExpression */;
default:
return 0 /* None */;
@@ -5311,8 +5377,8 @@ var TypeScript;
function isAnyDivideToken(kind) {
switch (kind) {
- case 118 /* SlashToken */:
- case 119 /* SlashEqualsToken */:
+ case 119 /* SlashToken */:
+ case 120 /* SlashEqualsToken */:
return true;
default:
return false;
@@ -5322,8 +5388,8 @@ var TypeScript;
function isAnyDivideOrRegularExpressionToken(kind) {
switch (kind) {
- case 118 /* SlashToken */:
- case 119 /* SlashEqualsToken */:
+ case 119 /* SlashToken */:
+ case 120 /* SlashEqualsToken */:
case 12 /* RegularExpressionLiteral */:
return true;
default:
@@ -5334,11 +5400,11 @@ var TypeScript;
function isParserGenerated(kind) {
switch (kind) {
- case 96 /* GreaterThanGreaterThanToken */:
- case 97 /* GreaterThanGreaterThanGreaterThanToken */:
- case 83 /* GreaterThanEqualsToken */:
- case 113 /* GreaterThanGreaterThanEqualsToken */:
- case 114 /* GreaterThanGreaterThanGreaterThanEqualsToken */:
+ case 97 /* GreaterThanGreaterThanToken */:
+ case 98 /* GreaterThanGreaterThanGreaterThanToken */:
+ case 84 /* GreaterThanEqualsToken */:
+ case 114 /* GreaterThanGreaterThanEqualsToken */:
+ case 115 /* GreaterThanGreaterThanGreaterThanEqualsToken */:
return true;
default:
return false;
@@ -5348,42 +5414,42 @@ var TypeScript;
function isAnyBinaryExpression(kind) {
switch (kind) {
- case 172 /* CommaExpression */:
- case 173 /* AssignmentExpression */:
- case 174 /* AddAssignmentExpression */:
- case 175 /* SubtractAssignmentExpression */:
- case 176 /* MultiplyAssignmentExpression */:
- case 177 /* DivideAssignmentExpression */:
- case 178 /* ModuloAssignmentExpression */:
- case 179 /* AndAssignmentExpression */:
- case 180 /* ExclusiveOrAssignmentExpression */:
- case 181 /* OrAssignmentExpression */:
- case 182 /* LeftShiftAssignmentExpression */:
- case 183 /* SignedRightShiftAssignmentExpression */:
- case 184 /* UnsignedRightShiftAssignmentExpression */:
- case 186 /* LogicalOrExpression */:
- case 187 /* LogicalAndExpression */:
- case 188 /* BitwiseOrExpression */:
- case 189 /* BitwiseExclusiveOrExpression */:
- case 190 /* BitwiseAndExpression */:
- case 191 /* EqualsWithTypeConversionExpression */:
- case 192 /* NotEqualsWithTypeConversionExpression */:
- case 193 /* EqualsExpression */:
- case 194 /* NotEqualsExpression */:
- case 195 /* LessThanExpression */:
- case 196 /* GreaterThanExpression */:
- case 197 /* LessThanOrEqualExpression */:
- case 198 /* GreaterThanOrEqualExpression */:
- case 199 /* InstanceOfExpression */:
- case 200 /* InExpression */:
- case 201 /* LeftShiftExpression */:
- case 202 /* SignedRightShiftExpression */:
- case 203 /* UnsignedRightShiftExpression */:
- case 204 /* MultiplyExpression */:
- case 205 /* DivideExpression */:
- case 206 /* ModuloExpression */:
- case 207 /* AddExpression */:
- case 208 /* SubtractExpression */:
+ case 173 /* CommaExpression */:
+ case 174 /* AssignmentExpression */:
+ case 175 /* AddAssignmentExpression */:
+ case 176 /* SubtractAssignmentExpression */:
+ case 177 /* MultiplyAssignmentExpression */:
+ case 178 /* DivideAssignmentExpression */:
+ case 179 /* ModuloAssignmentExpression */:
+ case 180 /* AndAssignmentExpression */:
+ case 181 /* ExclusiveOrAssignmentExpression */:
+ case 182 /* OrAssignmentExpression */:
+ case 183 /* LeftShiftAssignmentExpression */:
+ case 184 /* SignedRightShiftAssignmentExpression */:
+ case 185 /* UnsignedRightShiftAssignmentExpression */:
+ case 187 /* LogicalOrExpression */:
+ case 188 /* LogicalAndExpression */:
+ case 189 /* BitwiseOrExpression */:
+ case 190 /* BitwiseExclusiveOrExpression */:
+ case 191 /* BitwiseAndExpression */:
+ case 192 /* EqualsWithTypeConversionExpression */:
+ case 193 /* NotEqualsWithTypeConversionExpression */:
+ case 194 /* EqualsExpression */:
+ case 195 /* NotEqualsExpression */:
+ case 196 /* LessThanExpression */:
+ case 197 /* GreaterThanExpression */:
+ case 198 /* LessThanOrEqualExpression */:
+ case 199 /* GreaterThanOrEqualExpression */:
+ case 200 /* InstanceOfExpression */:
+ case 201 /* InExpression */:
+ case 202 /* LeftShiftExpression */:
+ case 203 /* SignedRightShiftExpression */:
+ case 204 /* UnsignedRightShiftExpression */:
+ case 205 /* MultiplyExpression */:
+ case 206 /* DivideExpression */:
+ case 207 /* ModuloExpression */:
+ case 208 /* AddExpression */:
+ case 209 /* SubtractExpression */:
return true;
}
@@ -5415,7 +5481,7 @@ var TypeScript;
isNumericLiteralStart[46 /* dot */] = true;
- for (var keywordKind = 15 /* FirstKeyword */; keywordKind <= 69 /* LastKeyword */; keywordKind++) {
+ for (var keywordKind = 15 /* FirstKeyword */; keywordKind <= 70 /* LastKeyword */; keywordKind++) {
var keyword = TypeScript.SyntaxFacts.getText(keywordKind);
isKeywordStartCharacter[keyword.charCodeAt(0)] = true;
}
@@ -5822,40 +5888,40 @@ var TypeScript;
return this.scanLessThanToken();
case 62 /* greaterThan */:
- return this.advanceAndSetTokenKind(81 /* GreaterThanToken */);
+ return this.advanceAndSetTokenKind(82 /* GreaterThanToken */);
case 44 /* comma */:
- return this.advanceAndSetTokenKind(79 /* CommaToken */);
+ return this.advanceAndSetTokenKind(80 /* CommaToken */);
case 58 /* colon */:
- return this.advanceAndSetTokenKind(106 /* ColonToken */);
+ return this.advanceAndSetTokenKind(107 /* ColonToken */);
case 59 /* semicolon */:
- return this.advanceAndSetTokenKind(78 /* SemicolonToken */);
+ return this.advanceAndSetTokenKind(79 /* SemicolonToken */);
case 126 /* tilde */:
- return this.advanceAndSetTokenKind(102 /* TildeToken */);
+ return this.advanceAndSetTokenKind(103 /* TildeToken */);
case 40 /* openParen */:
- return this.advanceAndSetTokenKind(72 /* OpenParenToken */);
+ return this.advanceAndSetTokenKind(73 /* OpenParenToken */);
case 41 /* closeParen */:
- return this.advanceAndSetTokenKind(73 /* CloseParenToken */);
+ return this.advanceAndSetTokenKind(74 /* CloseParenToken */);
case 123 /* openBrace */:
- return this.advanceAndSetTokenKind(70 /* OpenBraceToken */);
+ return this.advanceAndSetTokenKind(71 /* OpenBraceToken */);
case 125 /* closeBrace */:
- return this.advanceAndSetTokenKind(71 /* CloseBraceToken */);
+ return this.advanceAndSetTokenKind(72 /* CloseBraceToken */);
case 91 /* openBracket */:
- return this.advanceAndSetTokenKind(74 /* OpenBracketToken */);
+ return this.advanceAndSetTokenKind(75 /* OpenBracketToken */);
case 93 /* closeBracket */:
- return this.advanceAndSetTokenKind(75 /* CloseBracketToken */);
+ return this.advanceAndSetTokenKind(76 /* CloseBracketToken */);
case 63 /* question */:
- return this.advanceAndSetTokenKind(105 /* QuestionToken */);
+ return this.advanceAndSetTokenKind(106 /* QuestionToken */);
}
if (isNumericLiteralStart[character]) {
@@ -6004,17 +6070,17 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 82 /* LessThanEqualsToken */;
+ return 83 /* LessThanEqualsToken */;
} else if (this.currentCharCode() === 60 /* lessThan */) {
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 112 /* LessThanLessThanEqualsToken */;
+ return 113 /* LessThanLessThanEqualsToken */;
} else {
- return 95 /* LessThanLessThanToken */;
+ return 96 /* LessThanLessThanToken */;
}
} else {
- return 80 /* LessThanToken */;
+ return 81 /* LessThanToken */;
}
};
@@ -6022,12 +6088,12 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 116 /* BarEqualsToken */;
+ return 117 /* BarEqualsToken */;
} else if (this.currentCharCode() === 124 /* bar */) {
this.slidingWindow.moveToNextItem();
- return 104 /* BarBarToken */;
+ return 105 /* BarBarToken */;
} else {
- return 99 /* BarToken */;
+ return 100 /* BarToken */;
}
};
@@ -6035,9 +6101,9 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 117 /* CaretEqualsToken */;
+ return 118 /* CaretEqualsToken */;
} else {
- return 100 /* CaretToken */;
+ return 101 /* CaretToken */;
}
};
@@ -6046,12 +6112,12 @@ var TypeScript;
var character = this.currentCharCode();
if (character === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 115 /* AmpersandEqualsToken */;
+ return 116 /* AmpersandEqualsToken */;
} else if (this.currentCharCode() === 38 /* ampersand */) {
this.slidingWindow.moveToNextItem();
- return 103 /* AmpersandAmpersandToken */;
+ return 104 /* AmpersandAmpersandToken */;
} else {
- return 98 /* AmpersandToken */;
+ return 99 /* AmpersandToken */;
}
};
@@ -6059,9 +6125,9 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 111 /* PercentEqualsToken */;
+ return 112 /* PercentEqualsToken */;
} else {
- return 92 /* PercentToken */;
+ return 93 /* PercentToken */;
}
};
@@ -6071,12 +6137,12 @@ var TypeScript;
if (character === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 109 /* MinusEqualsToken */;
+ return 110 /* MinusEqualsToken */;
} else if (character === 45 /* minus */) {
this.slidingWindow.moveToNextItem();
- return 94 /* MinusMinusToken */;
+ return 95 /* MinusMinusToken */;
} else {
- return 90 /* MinusToken */;
+ return 91 /* MinusToken */;
}
};
@@ -6085,12 +6151,12 @@ var TypeScript;
var character = this.currentCharCode();
if (character === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 108 /* PlusEqualsToken */;
+ return 109 /* PlusEqualsToken */;
} else if (character === 43 /* plus */) {
this.slidingWindow.moveToNextItem();
- return 93 /* PlusPlusToken */;
+ return 94 /* PlusPlusToken */;
} else {
- return 89 /* PlusToken */;
+ return 90 /* PlusToken */;
}
};
@@ -6098,9 +6164,9 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 110 /* AsteriskEqualsToken */;
+ return 111 /* AsteriskEqualsToken */;
} else {
- return 91 /* AsteriskToken */;
+ return 92 /* AsteriskToken */;
}
};
@@ -6113,15 +6179,15 @@ var TypeScript;
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 87 /* EqualsEqualsEqualsToken */;
+ return 88 /* EqualsEqualsEqualsToken */;
} else {
- return 84 /* EqualsEqualsToken */;
+ return 85 /* EqualsEqualsToken */;
}
} else if (character === 62 /* greaterThan */) {
this.slidingWindow.moveToNextItem();
- return 85 /* EqualsGreaterThanToken */;
+ return 86 /* EqualsGreaterThanToken */;
} else {
- return 107 /* EqualsToken */;
+ return 108 /* EqualsToken */;
}
};
@@ -6143,9 +6209,9 @@ var TypeScript;
if (this.currentCharCode() === 46 /* dot */ && this.slidingWindow.peekItemN(1) === 46 /* dot */) {
this.slidingWindow.moveToNextItem();
this.slidingWindow.moveToNextItem();
- return 77 /* DotDotDotToken */;
+ return 78 /* DotDotDotToken */;
} else {
- return 76 /* DotToken */;
+ return 77 /* DotToken */;
}
};
@@ -6160,9 +6226,9 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 119 /* SlashEqualsToken */;
+ return 120 /* SlashEqualsToken */;
} else {
- return 118 /* SlashToken */;
+ return 119 /* SlashToken */;
}
};
@@ -6231,12 +6297,12 @@ var TypeScript;
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 88 /* ExclamationEqualsEqualsToken */;
+ return 89 /* ExclamationEqualsEqualsToken */;
} else {
- return 86 /* ExclamationEqualsToken */;
+ return 87 /* ExclamationEqualsToken */;
}
} else {
- return 101 /* ExclamationToken */;
+ return 102 /* ExclamationToken */;
}
};
@@ -6490,9 +6556,9 @@ var TypeScript;
case 97 /* a */:
return (array[startIndex + 1] === 110 /* n */ && array[startIndex + 2] === 121 /* y */) ? 60 /* AnyKeyword */ : 11 /* IdentifierName */;
case 103 /* g */:
- return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 116 /* t */) ? 64 /* GetKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 116 /* t */) ? 65 /* GetKeyword */ : 11 /* IdentifierName */;
case 115 /* s */:
- return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 116 /* t */) ? 68 /* SetKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 116 /* t */) ? 69 /* SetKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6527,6 +6593,8 @@ var TypeScript;
return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 105 /* i */ && array[startIndex + 3] === 100 /* d */) ? 41 /* VoidKeyword */ : 11 /* IdentifierName */;
case 119 /* w */:
return (array[startIndex + 1] === 105 /* i */ && array[startIndex + 2] === 116 /* t */ && array[startIndex + 3] === 104 /* h */) ? 43 /* WithKeyword */ : 11 /* IdentifierName */;
+ case 98 /* b */:
+ return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 111 /* o */ && array[startIndex + 3] === 108 /* l */) ? 62 /* BoolKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6576,7 +6644,7 @@ var TypeScript;
case 97 /* a */:
return (array[startIndex + 3] === 116 /* t */ && array[startIndex + 4] === 105 /* i */ && array[startIndex + 5] === 99 /* c */) ? 58 /* StaticKeyword */ : 11 /* IdentifierName */;
case 114 /* r */:
- return (array[startIndex + 3] === 105 /* i */ && array[startIndex + 4] === 110 /* n */ && array[startIndex + 5] === 103 /* g */) ? 69 /* StringKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 3] === 105 /* i */ && array[startIndex + 4] === 110 /* n */ && array[startIndex + 5] === 103 /* g */) ? 70 /* StringKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6594,9 +6662,9 @@ var TypeScript;
case 112 /* p */:
return (array[startIndex + 1] === 117 /* u */ && array[startIndex + 2] === 98 /* b */ && array[startIndex + 3] === 108 /* l */ && array[startIndex + 4] === 105 /* i */ && array[startIndex + 5] === 99 /* c */) ? 57 /* PublicKeyword */ : 11 /* IdentifierName */;
case 109 /* m */:
- return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 100 /* d */ && array[startIndex + 3] === 117 /* u */ && array[startIndex + 4] === 108 /* l */ && array[startIndex + 5] === 101 /* e */) ? 65 /* ModuleKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 100 /* d */ && array[startIndex + 3] === 117 /* u */ && array[startIndex + 4] === 108 /* l */ && array[startIndex + 5] === 101 /* e */) ? 66 /* ModuleKeyword */ : 11 /* IdentifierName */;
case 110 /* n */:
- return (array[startIndex + 1] === 117 /* u */ && array[startIndex + 2] === 109 /* m */ && array[startIndex + 3] === 98 /* b */ && array[startIndex + 4] === 101 /* e */ && array[startIndex + 5] === 114 /* r */) ? 67 /* NumberKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 117 /* u */ && array[startIndex + 2] === 109 /* m */ && array[startIndex + 3] === 98 /* b */ && array[startIndex + 4] === 101 /* e */ && array[startIndex + 5] === 114 /* r */) ? 68 /* NumberKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6610,7 +6678,7 @@ var TypeScript;
case 102 /* f */:
return (array[startIndex + 3] === 97 /* a */ && array[startIndex + 4] === 117 /* u */ && array[startIndex + 5] === 108 /* l */ && array[startIndex + 6] === 116 /* t */) ? 20 /* DefaultKeyword */ : 11 /* IdentifierName */;
case 99 /* c */:
- return (array[startIndex + 3] === 108 /* l */ && array[startIndex + 4] === 97 /* a */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 101 /* e */) ? 63 /* DeclareKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 3] === 108 /* l */ && array[startIndex + 4] === 97 /* a */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 101 /* e */) ? 64 /* DeclareKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6636,7 +6704,7 @@ var TypeScript;
case 98 /* b */:
return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 111 /* o */ && array[startIndex + 3] === 108 /* l */ && array[startIndex + 4] === 101 /* e */ && array[startIndex + 5] === 97 /* a */ && array[startIndex + 6] === 110 /* n */) ? 61 /* BooleanKeyword */ : 11 /* IdentifierName */;
case 114 /* r */:
- return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 113 /* q */ && array[startIndex + 3] === 117 /* u */ && array[startIndex + 4] === 105 /* i */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 101 /* e */) ? 66 /* RequireKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 113 /* q */ && array[startIndex + 3] === 117 /* u */ && array[startIndex + 4] === 105 /* i */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 101 /* e */) ? 67 /* RequireKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6680,7 +6748,7 @@ var TypeScript;
}
case 11:
- return (array[startIndex] === 99 /* c */ && array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 110 /* n */ && array[startIndex + 3] === 115 /* s */ && array[startIndex + 4] === 116 /* t */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 117 /* u */ && array[startIndex + 7] === 99 /* c */ && array[startIndex + 8] === 116 /* t */ && array[startIndex + 9] === 111 /* o */ && array[startIndex + 10] === 114 /* r */) ? 62 /* ConstructorKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex] === 99 /* c */ && array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 110 /* n */ && array[startIndex + 3] === 115 /* s */ && array[startIndex + 4] === 116 /* t */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 117 /* u */ && array[startIndex + 7] === 99 /* c */ && array[startIndex + 8] === 116 /* t */ && array[startIndex + 9] === 111 /* o */ && array[startIndex + 10] === 114 /* r */) ? 63 /* ConstructorKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -7332,9 +7400,9 @@ var TypeScript;
var parentPositionedNode = positionedToken.containingNode();
var parentNode = parentPositionedNode.node();
- if (parentNode.kind() === 121 /* QualifiedName */ && (parentNode).right === token) {
+ if (parentNode.kind() === 122 /* QualifiedName */ && (parentNode).right === token) {
return parentPositionedNode;
- } else if (parentNode.kind() === 211 /* MemberAccessExpression */ && (parentNode).name === token) {
+ } else if (parentNode.kind() === 212 /* MemberAccessExpression */ && (parentNode).name === token) {
return parentPositionedNode;
}
}
@@ -7350,9 +7418,9 @@ var TypeScript;
if (parent !== null) {
switch (parent.kind()) {
- case 246 /* ModuleNameModuleReference */:
+ case 247 /* ModuleNameModuleReference */:
return true;
- case 121 /* QualifiedName */:
+ case 122 /* QualifiedName */:
return true;
default:
return isInTypeOnlyContext(positionedToken);
@@ -7373,13 +7441,13 @@ var TypeScript;
if (parent !== null) {
switch (parent.kind()) {
- case 124 /* ArrayType */:
+ case 125 /* ArrayType */:
return (parent).type === nodeOrToken;
- case 219 /* CastExpression */:
+ case 220 /* CastExpression */:
return (parent).type === nodeOrToken;
- case 244 /* TypeAnnotation */:
- case 229 /* HeritageClause */:
- case 227 /* TypeArgumentList */:
+ case 245 /* TypeAnnotation */:
+ case 230 /* HeritageClause */:
+ case 228 /* TypeArgumentList */:
return true;
}
}
@@ -7578,27 +7646,27 @@ var TypeScript;
Syntax.stringLiteralExpression = stringLiteralExpression;
function isSuperInvocationExpression(node) {
- return node.kind() === 212 /* InvocationExpression */ && (node).expression.kind() === 50 /* SuperKeyword */;
+ return node.kind() === 213 /* InvocationExpression */ && (node).expression.kind() === 50 /* SuperKeyword */;
}
Syntax.isSuperInvocationExpression = isSuperInvocationExpression;
function isSuperInvocationExpressionStatement(node) {
- return node.kind() === 148 /* ExpressionStatement */ && isSuperInvocationExpression((node).expression);
+ return node.kind() === 149 /* ExpressionStatement */ && isSuperInvocationExpression((node).expression);
}
Syntax.isSuperInvocationExpressionStatement = isSuperInvocationExpressionStatement;
function isSuperMemberAccessExpression(node) {
- return node.kind() === 211 /* MemberAccessExpression */ && (node).expression.kind() === 50 /* SuperKeyword */;
+ return node.kind() === 212 /* MemberAccessExpression */ && (node).expression.kind() === 50 /* SuperKeyword */;
}
Syntax.isSuperMemberAccessExpression = isSuperMemberAccessExpression;
function isSuperMemberAccessInvocationExpression(node) {
- return node.kind() === 212 /* InvocationExpression */ && isSuperMemberAccessExpression((node).expression);
+ return node.kind() === 213 /* InvocationExpression */ && isSuperMemberAccessExpression((node).expression);
}
Syntax.isSuperMemberAccessInvocationExpression = isSuperMemberAccessInvocationExpression;
function assignmentExpression(left, token, right) {
- return TypeScript.Syntax.normalModeFactory.binaryExpression(173 /* AssignmentExpression */, left, token, right);
+ return TypeScript.Syntax.normalModeFactory.binaryExpression(174 /* AssignmentExpression */, left, token, right);
}
Syntax.assignmentExpression = assignmentExpression;
@@ -7810,8 +7878,8 @@ var TypeScript;
function isIntegerLiteral(expression) {
if (expression) {
switch (expression.kind()) {
- case 163 /* PlusExpression */:
- case 164 /* NegateExpression */:
+ case 164 /* PlusExpression */:
+ case 165 /* NegateExpression */:
expression = (expression).operand;
return isInteger((expression).text());
@@ -7845,8 +7913,8 @@ var TypeScript;
NormalModeFactory.prototype.sourceUnit = function (moduleElements, endOfFileToken) {
return new TypeScript.SourceUnitSyntax(moduleElements, endOfFileToken, false);
};
- NormalModeFactory.prototype.externalModuleReference = function (requireKeyword, openParenToken, stringLiteral, closeParenToken) {
- return new TypeScript.ExternalModuleReferenceSyntax(requireKeyword, openParenToken, stringLiteral, closeParenToken, false);
+ NormalModeFactory.prototype.externalModuleReference = function (moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken) {
+ return new TypeScript.ExternalModuleReferenceSyntax(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken, false);
};
NormalModeFactory.prototype.moduleNameModuleReference = function (moduleName) {
return new TypeScript.ModuleNameModuleReferenceSyntax(moduleName, false);
@@ -8110,8 +8178,8 @@ var TypeScript;
StrictModeFactory.prototype.sourceUnit = function (moduleElements, endOfFileToken) {
return new TypeScript.SourceUnitSyntax(moduleElements, endOfFileToken, true);
};
- StrictModeFactory.prototype.externalModuleReference = function (requireKeyword, openParenToken, stringLiteral, closeParenToken) {
- return new TypeScript.ExternalModuleReferenceSyntax(requireKeyword, openParenToken, stringLiteral, closeParenToken, true);
+ StrictModeFactory.prototype.externalModuleReference = function (moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken) {
+ return new TypeScript.ExternalModuleReferenceSyntax(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken, true);
};
StrictModeFactory.prototype.moduleNameModuleReference = function (moduleName) {
return new TypeScript.ModuleNameModuleReferenceSyntax(moduleName, true);
@@ -8378,7 +8446,7 @@ var TypeScript;
(function (TypeScript) {
(function (SyntaxFacts) {
function isDirectivePrologueElement(node) {
- if (node.kind() === 148 /* ExpressionStatement */) {
+ if (node.kind() === 149 /* ExpressionStatement */) {
var expressionStatement = node;
var expression = expressionStatement.expression;
@@ -9013,7 +9081,7 @@ var TypeScript;
};
SyntaxNode.prototype.tryGetEndOfFileAt = function (position) {
- if (this.kind() === 120 /* SourceUnit */ && position === this.fullWidth()) {
+ if (this.kind() === 121 /* SourceUnit */ && position === this.fullWidth()) {
var sourceUnit = this;
return new TypeScript.PositionedToken(new TypeScript.PositionedNode(null, sourceUnit, 0), sourceUnit.endOfFileToken, sourceUnit.moduleElements.fullWidth());
}
@@ -9150,7 +9218,7 @@ var TypeScript;
};
SourceUnitSyntax.prototype.kind = function () {
- return 120 /* SourceUnit */;
+ return 121 /* SourceUnit */;
};
SourceUnitSyntax.prototype.childCount = function () {
@@ -9240,9 +9308,9 @@ var TypeScript;
var ExternalModuleReferenceSyntax = (function (_super) {
__extends(ExternalModuleReferenceSyntax, _super);
- function ExternalModuleReferenceSyntax(requireKeyword, openParenToken, stringLiteral, closeParenToken, parsedInStrictMode) {
+ function ExternalModuleReferenceSyntax(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken, parsedInStrictMode) {
_super.call(this, parsedInStrictMode);
- this.requireKeyword = requireKeyword;
+ this.moduleOrRequireKeyword = moduleOrRequireKeyword;
this.openParenToken = openParenToken;
this.stringLiteral = stringLiteral;
this.closeParenToken = closeParenToken;
@@ -9252,7 +9320,7 @@ var TypeScript;
};
ExternalModuleReferenceSyntax.prototype.kind = function () {
- return 245 /* ExternalModuleReference */;
+ return 246 /* ExternalModuleReference */;
};
ExternalModuleReferenceSyntax.prototype.childCount = function () {
@@ -9262,7 +9330,7 @@ var TypeScript;
ExternalModuleReferenceSyntax.prototype.childAt = function (slot) {
switch (slot) {
case 0:
- return this.requireKeyword;
+ return this.moduleOrRequireKeyword;
case 1:
return this.openParenToken;
case 2:
@@ -9274,16 +9342,16 @@ var TypeScript;
}
};
- ExternalModuleReferenceSyntax.prototype.update = function (requireKeyword, openParenToken, stringLiteral, closeParenToken) {
- if (this.requireKeyword === requireKeyword && this.openParenToken === openParenToken && this.stringLiteral === stringLiteral && this.closeParenToken === closeParenToken) {
+ ExternalModuleReferenceSyntax.prototype.update = function (moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken) {
+ if (this.moduleOrRequireKeyword === moduleOrRequireKeyword && this.openParenToken === openParenToken && this.stringLiteral === stringLiteral && this.closeParenToken === closeParenToken) {
return this;
}
- return new ExternalModuleReferenceSyntax(requireKeyword, openParenToken, stringLiteral, closeParenToken, this.parsedInStrictMode());
+ return new ExternalModuleReferenceSyntax(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken, this.parsedInStrictMode());
};
- ExternalModuleReferenceSyntax.create1 = function (stringLiteral) {
- return new ExternalModuleReferenceSyntax(TypeScript.Syntax.token(66 /* RequireKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), stringLiteral, TypeScript.Syntax.token(73 /* CloseParenToken */), false);
+ ExternalModuleReferenceSyntax.create1 = function (moduleOrRequireKeyword, stringLiteral) {
+ return new ExternalModuleReferenceSyntax(moduleOrRequireKeyword, TypeScript.Syntax.token(73 /* OpenParenToken */), stringLiteral, TypeScript.Syntax.token(74 /* CloseParenToken */), false);
};
ExternalModuleReferenceSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9294,20 +9362,20 @@ var TypeScript;
return _super.prototype.withTrailingTrivia.call(this, trivia);
};
- ExternalModuleReferenceSyntax.prototype.withRequireKeyword = function (requireKeyword) {
- return this.update(requireKeyword, this.openParenToken, this.stringLiteral, this.closeParenToken);
+ ExternalModuleReferenceSyntax.prototype.withModuleOrRequireKeyword = function (moduleOrRequireKeyword) {
+ return this.update(moduleOrRequireKeyword, this.openParenToken, this.stringLiteral, this.closeParenToken);
};
ExternalModuleReferenceSyntax.prototype.withOpenParenToken = function (openParenToken) {
- return this.update(this.requireKeyword, openParenToken, this.stringLiteral, this.closeParenToken);
+ return this.update(this.moduleOrRequireKeyword, openParenToken, this.stringLiteral, this.closeParenToken);
};
ExternalModuleReferenceSyntax.prototype.withStringLiteral = function (stringLiteral) {
- return this.update(this.requireKeyword, this.openParenToken, stringLiteral, this.closeParenToken);
+ return this.update(this.moduleOrRequireKeyword, this.openParenToken, stringLiteral, this.closeParenToken);
};
ExternalModuleReferenceSyntax.prototype.withCloseParenToken = function (closeParenToken) {
- return this.update(this.requireKeyword, this.openParenToken, this.stringLiteral, closeParenToken);
+ return this.update(this.moduleOrRequireKeyword, this.openParenToken, this.stringLiteral, closeParenToken);
};
ExternalModuleReferenceSyntax.prototype.isTypeScriptSpecific = function () {
@@ -9328,7 +9396,7 @@ var TypeScript;
};
ModuleNameModuleReferenceSyntax.prototype.kind = function () {
- return 246 /* ModuleNameModuleReference */;
+ return 247 /* ModuleNameModuleReference */;
};
ModuleNameModuleReferenceSyntax.prototype.childCount = function () {
@@ -9387,7 +9455,7 @@ var TypeScript;
};
ImportDeclarationSyntax.prototype.kind = function () {
- return 133 /* ImportDeclaration */;
+ return 134 /* ImportDeclaration */;
};
ImportDeclarationSyntax.prototype.childCount = function () {
@@ -9430,7 +9498,7 @@ var TypeScript;
};
ImportDeclarationSyntax.create1 = function (identifier, moduleReference) {
- return new ImportDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(49 /* ImportKeyword */), identifier, TypeScript.Syntax.token(107 /* EqualsToken */), moduleReference, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ImportDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(49 /* ImportKeyword */), identifier, TypeScript.Syntax.token(108 /* EqualsToken */), moduleReference, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ImportDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9490,7 +9558,7 @@ var TypeScript;
};
ExportAssignmentSyntax.prototype.kind = function () {
- return 134 /* ExportAssignment */;
+ return 135 /* ExportAssignment */;
};
ExportAssignmentSyntax.prototype.childCount = function () {
@@ -9525,7 +9593,7 @@ var TypeScript;
};
ExportAssignmentSyntax.create1 = function (identifier) {
- return new ExportAssignmentSyntax(TypeScript.Syntax.token(47 /* ExportKeyword */), TypeScript.Syntax.token(107 /* EqualsToken */), identifier, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ExportAssignmentSyntax(TypeScript.Syntax.token(47 /* ExportKeyword */), TypeScript.Syntax.token(108 /* EqualsToken */), identifier, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ExportAssignmentSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9577,7 +9645,7 @@ var TypeScript;
};
ClassDeclarationSyntax.prototype.kind = function () {
- return 131 /* ClassDeclaration */;
+ return 132 /* ClassDeclaration */;
};
ClassDeclarationSyntax.prototype.childCount = function () {
@@ -9624,7 +9692,7 @@ var TypeScript;
};
ClassDeclarationSyntax.create1 = function (identifier) {
- return new ClassDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(44 /* ClassKeyword */), identifier, null, TypeScript.Syntax.emptyList, TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new ClassDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(44 /* ClassKeyword */), identifier, null, TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
ClassDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9702,7 +9770,7 @@ var TypeScript;
};
InterfaceDeclarationSyntax.prototype.kind = function () {
- return 128 /* InterfaceDeclaration */;
+ return 129 /* InterfaceDeclaration */;
};
InterfaceDeclarationSyntax.prototype.childCount = function () {
@@ -9807,7 +9875,7 @@ var TypeScript;
};
HeritageClauseSyntax.prototype.kind = function () {
- return 229 /* HeritageClause */;
+ return 230 /* HeritageClause */;
};
HeritageClauseSyntax.prototype.childCount = function () {
@@ -9877,7 +9945,7 @@ var TypeScript;
};
ModuleDeclarationSyntax.prototype.kind = function () {
- return 130 /* ModuleDeclaration */;
+ return 131 /* ModuleDeclaration */;
};
ModuleDeclarationSyntax.prototype.childCount = function () {
@@ -9922,7 +9990,7 @@ var TypeScript;
};
ModuleDeclarationSyntax.create1 = function () {
- return new ModuleDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(65 /* ModuleKeyword */), null, null, TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new ModuleDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(66 /* ModuleKeyword */), null, null, TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
ModuleDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9992,7 +10060,7 @@ var TypeScript;
};
FunctionDeclarationSyntax.prototype.kind = function () {
- return 129 /* FunctionDeclaration */;
+ return 130 /* FunctionDeclaration */;
};
FunctionDeclarationSyntax.prototype.childCount = function () {
@@ -10107,7 +10175,7 @@ var TypeScript;
};
VariableStatementSyntax.prototype.kind = function () {
- return 147 /* VariableStatement */;
+ return 148 /* VariableStatement */;
};
VariableStatementSyntax.prototype.childCount = function () {
@@ -10148,7 +10216,7 @@ var TypeScript;
};
VariableStatementSyntax.create1 = function (variableDeclaration) {
- return new VariableStatementSyntax(TypeScript.Syntax.emptyList, variableDeclaration, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new VariableStatementSyntax(TypeScript.Syntax.emptyList, variableDeclaration, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
VariableStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10200,7 +10268,7 @@ var TypeScript;
};
VariableDeclarationSyntax.prototype.kind = function () {
- return 223 /* VariableDeclaration */;
+ return 224 /* VariableDeclaration */;
};
VariableDeclarationSyntax.prototype.childCount = function () {
@@ -10273,7 +10341,7 @@ var TypeScript;
};
VariableDeclaratorSyntax.prototype.kind = function () {
- return 224 /* VariableDeclarator */;
+ return 225 /* VariableDeclarator */;
};
VariableDeclaratorSyntax.prototype.childCount = function () {
@@ -10354,7 +10422,7 @@ var TypeScript;
};
EqualsValueClauseSyntax.prototype.kind = function () {
- return 230 /* EqualsValueClause */;
+ return 231 /* EqualsValueClause */;
};
EqualsValueClauseSyntax.prototype.childCount = function () {
@@ -10381,7 +10449,7 @@ var TypeScript;
};
EqualsValueClauseSyntax.create1 = function (value) {
- return new EqualsValueClauseSyntax(TypeScript.Syntax.token(107 /* EqualsToken */), value, false);
+ return new EqualsValueClauseSyntax(TypeScript.Syntax.token(108 /* EqualsToken */), value, false);
};
EqualsValueClauseSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10501,7 +10569,7 @@ var TypeScript;
};
ArrayLiteralExpressionSyntax.prototype.kind = function () {
- return 213 /* ArrayLiteralExpression */;
+ return 214 /* ArrayLiteralExpression */;
};
ArrayLiteralExpressionSyntax.prototype.childCount = function () {
@@ -10542,7 +10610,7 @@ var TypeScript;
};
ArrayLiteralExpressionSyntax.create1 = function () {
- return new ArrayLiteralExpressionSyntax(TypeScript.Syntax.token(74 /* OpenBracketToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(75 /* CloseBracketToken */), false);
+ return new ArrayLiteralExpressionSyntax(TypeScript.Syntax.token(75 /* OpenBracketToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(76 /* CloseBracketToken */), false);
};
ArrayLiteralExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10589,7 +10657,7 @@ var TypeScript;
};
OmittedExpressionSyntax.prototype.kind = function () {
- return 222 /* OmittedExpression */;
+ return 223 /* OmittedExpression */;
};
OmittedExpressionSyntax.prototype.childCount = function () {
@@ -10636,7 +10704,7 @@ var TypeScript;
};
ParenthesizedExpressionSyntax.prototype.kind = function () {
- return 216 /* ParenthesizedExpression */;
+ return 217 /* ParenthesizedExpression */;
};
ParenthesizedExpressionSyntax.prototype.childCount = function () {
@@ -10673,7 +10741,7 @@ var TypeScript;
};
ParenthesizedExpressionSyntax.create1 = function (expression) {
- return new ParenthesizedExpressionSyntax(TypeScript.Syntax.token(72 /* OpenParenToken */), expression, TypeScript.Syntax.token(73 /* CloseParenToken */), false);
+ return new ParenthesizedExpressionSyntax(TypeScript.Syntax.token(73 /* OpenParenToken */), expression, TypeScript.Syntax.token(74 /* CloseParenToken */), false);
};
ParenthesizedExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10747,7 +10815,7 @@ var TypeScript;
};
SimpleArrowFunctionExpressionSyntax.prototype.kind = function () {
- return 218 /* SimpleArrowFunctionExpression */;
+ return 219 /* SimpleArrowFunctionExpression */;
};
SimpleArrowFunctionExpressionSyntax.prototype.childCount = function () {
@@ -10776,7 +10844,7 @@ var TypeScript;
};
SimpleArrowFunctionExpressionSyntax.create1 = function (identifier, body) {
- return new SimpleArrowFunctionExpressionSyntax(identifier, TypeScript.Syntax.token(85 /* EqualsGreaterThanToken */), body, false);
+ return new SimpleArrowFunctionExpressionSyntax(identifier, TypeScript.Syntax.token(86 /* EqualsGreaterThanToken */), body, false);
};
SimpleArrowFunctionExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10817,7 +10885,7 @@ var TypeScript;
};
ParenthesizedArrowFunctionExpressionSyntax.prototype.kind = function () {
- return 217 /* ParenthesizedArrowFunctionExpression */;
+ return 218 /* ParenthesizedArrowFunctionExpression */;
};
ParenthesizedArrowFunctionExpressionSyntax.prototype.childCount = function () {
@@ -10846,7 +10914,7 @@ var TypeScript;
};
ParenthesizedArrowFunctionExpressionSyntax.create1 = function (body) {
- return new ParenthesizedArrowFunctionExpressionSyntax(CallSignatureSyntax.create1(), TypeScript.Syntax.token(85 /* EqualsGreaterThanToken */), body, false);
+ return new ParenthesizedArrowFunctionExpressionSyntax(CallSignatureSyntax.create1(), TypeScript.Syntax.token(86 /* EqualsGreaterThanToken */), body, false);
};
ParenthesizedArrowFunctionExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10889,7 +10957,7 @@ var TypeScript;
};
QualifiedNameSyntax.prototype.kind = function () {
- return 121 /* QualifiedName */;
+ return 122 /* QualifiedName */;
};
QualifiedNameSyntax.prototype.childCount = function () {
@@ -10934,7 +11002,7 @@ var TypeScript;
};
QualifiedNameSyntax.create1 = function (left, right) {
- return new QualifiedNameSyntax(left, TypeScript.Syntax.token(76 /* DotToken */), right, false);
+ return new QualifiedNameSyntax(left, TypeScript.Syntax.token(77 /* DotToken */), right, false);
};
QualifiedNameSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10977,7 +11045,7 @@ var TypeScript;
};
TypeArgumentListSyntax.prototype.kind = function () {
- return 227 /* TypeArgumentList */;
+ return 228 /* TypeArgumentList */;
};
TypeArgumentListSyntax.prototype.childCount = function () {
@@ -11010,7 +11078,7 @@ var TypeScript;
};
TypeArgumentListSyntax.create1 = function () {
- return new TypeArgumentListSyntax(TypeScript.Syntax.token(80 /* LessThanToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(81 /* GreaterThanToken */), false);
+ return new TypeArgumentListSyntax(TypeScript.Syntax.token(81 /* LessThanToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(82 /* GreaterThanToken */), false);
};
TypeArgumentListSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11059,7 +11127,7 @@ var TypeScript;
};
ConstructorTypeSyntax.prototype.kind = function () {
- return 125 /* ConstructorType */;
+ return 126 /* ConstructorType */;
};
ConstructorTypeSyntax.prototype.childCount = function () {
@@ -11108,7 +11176,7 @@ var TypeScript;
};
ConstructorTypeSyntax.create1 = function (type) {
- return new ConstructorTypeSyntax(TypeScript.Syntax.token(31 /* NewKeyword */), null, ParameterListSyntax.create1(), TypeScript.Syntax.token(85 /* EqualsGreaterThanToken */), type, false);
+ return new ConstructorTypeSyntax(TypeScript.Syntax.token(31 /* NewKeyword */), null, ParameterListSyntax.create1(), TypeScript.Syntax.token(86 /* EqualsGreaterThanToken */), type, false);
};
ConstructorTypeSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11160,7 +11228,7 @@ var TypeScript;
};
FunctionTypeSyntax.prototype.kind = function () {
- return 123 /* FunctionType */;
+ return 124 /* FunctionType */;
};
FunctionTypeSyntax.prototype.childCount = function () {
@@ -11207,7 +11275,7 @@ var TypeScript;
};
FunctionTypeSyntax.create1 = function (type) {
- return new FunctionTypeSyntax(null, ParameterListSyntax.create1(), TypeScript.Syntax.token(85 /* EqualsGreaterThanToken */), type, false);
+ return new FunctionTypeSyntax(null, ParameterListSyntax.create1(), TypeScript.Syntax.token(86 /* EqualsGreaterThanToken */), type, false);
};
FunctionTypeSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11254,7 +11322,7 @@ var TypeScript;
};
ObjectTypeSyntax.prototype.kind = function () {
- return 122 /* ObjectType */;
+ return 123 /* ObjectType */;
};
ObjectTypeSyntax.prototype.childCount = function () {
@@ -11299,7 +11367,7 @@ var TypeScript;
};
ObjectTypeSyntax.create1 = function () {
- return new ObjectTypeSyntax(TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new ObjectTypeSyntax(TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
ObjectTypeSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11346,7 +11414,7 @@ var TypeScript;
};
ArrayTypeSyntax.prototype.kind = function () {
- return 124 /* ArrayType */;
+ return 125 /* ArrayType */;
};
ArrayTypeSyntax.prototype.childCount = function () {
@@ -11387,7 +11455,7 @@ var TypeScript;
};
ArrayTypeSyntax.create1 = function (type) {
- return new ArrayTypeSyntax(type, TypeScript.Syntax.token(74 /* OpenBracketToken */), TypeScript.Syntax.token(75 /* CloseBracketToken */), false);
+ return new ArrayTypeSyntax(type, TypeScript.Syntax.token(75 /* OpenBracketToken */), TypeScript.Syntax.token(76 /* CloseBracketToken */), false);
};
ArrayTypeSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11429,7 +11497,7 @@ var TypeScript;
};
GenericTypeSyntax.prototype.kind = function () {
- return 126 /* GenericType */;
+ return 127 /* GenericType */;
};
GenericTypeSyntax.prototype.childCount = function () {
@@ -11506,7 +11574,7 @@ var TypeScript;
};
TypeQuerySyntax.prototype.kind = function () {
- return 127 /* TypeQuery */;
+ return 128 /* TypeQuery */;
};
TypeQuerySyntax.prototype.childCount = function () {
@@ -11583,7 +11651,7 @@ var TypeScript;
};
TypeAnnotationSyntax.prototype.kind = function () {
- return 244 /* TypeAnnotation */;
+ return 245 /* TypeAnnotation */;
};
TypeAnnotationSyntax.prototype.childCount = function () {
@@ -11610,7 +11678,7 @@ var TypeScript;
};
TypeAnnotationSyntax.create1 = function (type) {
- return new TypeAnnotationSyntax(TypeScript.Syntax.token(106 /* ColonToken */), type, false);
+ return new TypeAnnotationSyntax(TypeScript.Syntax.token(107 /* ColonToken */), type, false);
};
TypeAnnotationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11649,7 +11717,7 @@ var TypeScript;
};
BlockSyntax.prototype.kind = function () {
- return 145 /* Block */;
+ return 146 /* Block */;
};
BlockSyntax.prototype.childCount = function () {
@@ -11690,7 +11758,7 @@ var TypeScript;
};
BlockSyntax.create1 = function () {
- return new BlockSyntax(TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new BlockSyntax(TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
BlockSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11743,7 +11811,7 @@ var TypeScript;
};
ParameterSyntax.prototype.kind = function () {
- return 242 /* Parameter */;
+ return 243 /* Parameter */;
};
ParameterSyntax.prototype.childCount = function () {
@@ -11852,7 +11920,7 @@ var TypeScript;
};
MemberAccessExpressionSyntax.prototype.kind = function () {
- return 211 /* MemberAccessExpression */;
+ return 212 /* MemberAccessExpression */;
};
MemberAccessExpressionSyntax.prototype.childCount = function () {
@@ -11889,7 +11957,7 @@ var TypeScript;
};
MemberAccessExpressionSyntax.create1 = function (expression, name) {
- return new MemberAccessExpressionSyntax(expression, TypeScript.Syntax.token(76 /* DotToken */), name, false);
+ return new MemberAccessExpressionSyntax(expression, TypeScript.Syntax.token(77 /* DotToken */), name, false);
};
MemberAccessExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12014,7 +12082,7 @@ var TypeScript;
};
ElementAccessExpressionSyntax.prototype.kind = function () {
- return 220 /* ElementAccessExpression */;
+ return 221 /* ElementAccessExpression */;
};
ElementAccessExpressionSyntax.prototype.childCount = function () {
@@ -12053,7 +12121,7 @@ var TypeScript;
};
ElementAccessExpressionSyntax.create1 = function (expression, argumentExpression) {
- return new ElementAccessExpressionSyntax(expression, TypeScript.Syntax.token(74 /* OpenBracketToken */), argumentExpression, TypeScript.Syntax.token(75 /* CloseBracketToken */), false);
+ return new ElementAccessExpressionSyntax(expression, TypeScript.Syntax.token(75 /* OpenBracketToken */), argumentExpression, TypeScript.Syntax.token(76 /* CloseBracketToken */), false);
};
ElementAccessExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12105,7 +12173,7 @@ var TypeScript;
};
InvocationExpressionSyntax.prototype.kind = function () {
- return 212 /* InvocationExpression */;
+ return 213 /* InvocationExpression */;
};
InvocationExpressionSyntax.prototype.childCount = function () {
@@ -12186,7 +12254,7 @@ var TypeScript;
};
ArgumentListSyntax.prototype.kind = function () {
- return 225 /* ArgumentList */;
+ return 226 /* ArgumentList */;
};
ArgumentListSyntax.prototype.childCount = function () {
@@ -12221,7 +12289,7 @@ var TypeScript;
};
ArgumentListSyntax.create1 = function () {
- return new ArgumentListSyntax(null, TypeScript.Syntax.token(72 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(73 /* CloseParenToken */), false);
+ return new ArgumentListSyntax(null, TypeScript.Syntax.token(73 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(74 /* CloseParenToken */), false);
};
ArgumentListSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12364,7 +12432,7 @@ var TypeScript;
};
ConditionalExpressionSyntax.prototype.kind = function () {
- return 185 /* ConditionalExpression */;
+ return 186 /* ConditionalExpression */;
};
ConditionalExpressionSyntax.prototype.childCount = function () {
@@ -12401,7 +12469,7 @@ var TypeScript;
};
ConditionalExpressionSyntax.create1 = function (condition, whenTrue, whenFalse) {
- return new ConditionalExpressionSyntax(condition, TypeScript.Syntax.token(105 /* QuestionToken */), whenTrue, TypeScript.Syntax.token(106 /* ColonToken */), whenFalse, false);
+ return new ConditionalExpressionSyntax(condition, TypeScript.Syntax.token(106 /* QuestionToken */), whenTrue, TypeScript.Syntax.token(107 /* ColonToken */), whenFalse, false);
};
ConditionalExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12460,7 +12528,7 @@ var TypeScript;
};
ConstructSignatureSyntax.prototype.kind = function () {
- return 142 /* ConstructSignature */;
+ return 143 /* ConstructSignature */;
};
ConstructSignatureSyntax.prototype.childCount = function () {
@@ -12530,7 +12598,7 @@ var TypeScript;
};
MethodSignatureSyntax.prototype.kind = function () {
- return 144 /* MethodSignature */;
+ return 145 /* MethodSignature */;
};
MethodSignatureSyntax.prototype.childCount = function () {
@@ -12614,7 +12682,7 @@ var TypeScript;
};
IndexSignatureSyntax.prototype.kind = function () {
- return 143 /* IndexSignature */;
+ return 144 /* IndexSignature */;
};
IndexSignatureSyntax.prototype.childCount = function () {
@@ -12657,7 +12725,7 @@ var TypeScript;
};
IndexSignatureSyntax.create1 = function (parameter) {
- return new IndexSignatureSyntax(TypeScript.Syntax.token(74 /* OpenBracketToken */), parameter, TypeScript.Syntax.token(75 /* CloseBracketToken */), null, false);
+ return new IndexSignatureSyntax(TypeScript.Syntax.token(75 /* OpenBracketToken */), parameter, TypeScript.Syntax.token(76 /* CloseBracketToken */), null, false);
};
IndexSignatureSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12704,7 +12772,7 @@ var TypeScript;
};
PropertySignatureSyntax.prototype.kind = function () {
- return 140 /* PropertySignature */;
+ return 141 /* PropertySignature */;
};
PropertySignatureSyntax.prototype.childCount = function () {
@@ -12784,7 +12852,7 @@ var TypeScript;
};
CallSignatureSyntax.prototype.kind = function () {
- return 141 /* CallSignature */;
+ return 142 /* CallSignature */;
};
CallSignatureSyntax.prototype.childCount = function () {
@@ -12873,7 +12941,7 @@ var TypeScript;
};
ParameterListSyntax.prototype.kind = function () {
- return 226 /* ParameterList */;
+ return 227 /* ParameterList */;
};
ParameterListSyntax.prototype.childCount = function () {
@@ -12906,7 +12974,7 @@ var TypeScript;
};
ParameterListSyntax.create1 = function () {
- return new ParameterListSyntax(TypeScript.Syntax.token(72 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(73 /* CloseParenToken */), false);
+ return new ParameterListSyntax(TypeScript.Syntax.token(73 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(74 /* CloseParenToken */), false);
};
ParameterListSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12956,7 +13024,7 @@ var TypeScript;
};
TypeParameterListSyntax.prototype.kind = function () {
- return 228 /* TypeParameterList */;
+ return 229 /* TypeParameterList */;
};
TypeParameterListSyntax.prototype.childCount = function () {
@@ -12989,7 +13057,7 @@ var TypeScript;
};
TypeParameterListSyntax.create1 = function () {
- return new TypeParameterListSyntax(TypeScript.Syntax.token(80 /* LessThanToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(81 /* GreaterThanToken */), false);
+ return new TypeParameterListSyntax(TypeScript.Syntax.token(81 /* LessThanToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(82 /* GreaterThanToken */), false);
};
TypeParameterListSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13035,7 +13103,7 @@ var TypeScript;
};
TypeParameterSyntax.prototype.kind = function () {
- return 236 /* TypeParameter */;
+ return 237 /* TypeParameter */;
};
TypeParameterSyntax.prototype.childCount = function () {
@@ -13104,7 +13172,7 @@ var TypeScript;
};
ConstraintSyntax.prototype.kind = function () {
- return 237 /* Constraint */;
+ return 238 /* Constraint */;
};
ConstraintSyntax.prototype.childCount = function () {
@@ -13169,7 +13237,7 @@ var TypeScript;
};
ElseClauseSyntax.prototype.kind = function () {
- return 233 /* ElseClause */;
+ return 234 /* ElseClause */;
};
ElseClauseSyntax.prototype.childCount = function () {
@@ -13241,7 +13309,7 @@ var TypeScript;
};
IfStatementSyntax.prototype.kind = function () {
- return 146 /* IfStatement */;
+ return 147 /* IfStatement */;
};
IfStatementSyntax.prototype.childCount = function () {
@@ -13288,7 +13356,7 @@ var TypeScript;
};
IfStatementSyntax.create1 = function (condition, statement) {
- return new IfStatementSyntax(TypeScript.Syntax.token(28 /* IfKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), condition, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, null, false);
+ return new IfStatementSyntax(TypeScript.Syntax.token(28 /* IfKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), condition, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, null, false);
};
IfStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13351,7 +13419,7 @@ var TypeScript;
};
ExpressionStatementSyntax.prototype.kind = function () {
- return 148 /* ExpressionStatement */;
+ return 149 /* ExpressionStatement */;
};
ExpressionStatementSyntax.prototype.childCount = function () {
@@ -13386,7 +13454,7 @@ var TypeScript;
};
ExpressionStatementSyntax.create1 = function (expression) {
- return new ExpressionStatementSyntax(expression, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ExpressionStatementSyntax(expression, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ExpressionStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13429,7 +13497,7 @@ var TypeScript;
};
ConstructorDeclarationSyntax.prototype.kind = function () {
- return 137 /* ConstructorDeclaration */;
+ return 138 /* ConstructorDeclaration */;
};
ConstructorDeclarationSyntax.prototype.childCount = function () {
@@ -13468,7 +13536,7 @@ var TypeScript;
};
ConstructorDeclarationSyntax.create1 = function () {
- return new ConstructorDeclarationSyntax(TypeScript.Syntax.token(62 /* ConstructorKeyword */), ParameterListSyntax.create1(), null, null, false);
+ return new ConstructorDeclarationSyntax(TypeScript.Syntax.token(63 /* ConstructorKeyword */), ParameterListSyntax.create1(), null, null, false);
};
ConstructorDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13517,7 +13585,7 @@ var TypeScript;
};
MemberFunctionDeclarationSyntax.prototype.kind = function () {
- return 135 /* MemberFunctionDeclaration */;
+ return 136 /* MemberFunctionDeclaration */;
};
MemberFunctionDeclarationSyntax.prototype.childCount = function () {
@@ -13648,7 +13716,7 @@ var TypeScript;
};
GetMemberAccessorDeclarationSyntax.prototype.kind = function () {
- return 138 /* GetMemberAccessorDeclaration */;
+ return 139 /* GetMemberAccessorDeclaration */;
};
GetMemberAccessorDeclarationSyntax.prototype.childCount = function () {
@@ -13687,7 +13755,7 @@ var TypeScript;
};
GetMemberAccessorDeclarationSyntax.create1 = function (propertyName) {
- return new GetMemberAccessorDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(64 /* GetKeyword */), propertyName, ParameterListSyntax.create1(), null, BlockSyntax.create1(), false);
+ return new GetMemberAccessorDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(65 /* GetKeyword */), propertyName, ParameterListSyntax.create1(), null, BlockSyntax.create1(), false);
};
GetMemberAccessorDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13744,7 +13812,7 @@ var TypeScript;
};
SetMemberAccessorDeclarationSyntax.prototype.kind = function () {
- return 139 /* SetMemberAccessorDeclaration */;
+ return 140 /* SetMemberAccessorDeclaration */;
};
SetMemberAccessorDeclarationSyntax.prototype.childCount = function () {
@@ -13781,7 +13849,7 @@ var TypeScript;
};
SetMemberAccessorDeclarationSyntax.create1 = function (propertyName) {
- return new SetMemberAccessorDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(68 /* SetKeyword */), propertyName, ParameterListSyntax.create1(), BlockSyntax.create1(), false);
+ return new SetMemberAccessorDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(69 /* SetKeyword */), propertyName, ParameterListSyntax.create1(), BlockSyntax.create1(), false);
};
SetMemberAccessorDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13836,7 +13904,7 @@ var TypeScript;
};
MemberVariableDeclarationSyntax.prototype.kind = function () {
- return 136 /* MemberVariableDeclaration */;
+ return 137 /* MemberVariableDeclaration */;
};
MemberVariableDeclarationSyntax.prototype.childCount = function () {
@@ -13877,7 +13945,7 @@ var TypeScript;
};
MemberVariableDeclarationSyntax.create1 = function (variableDeclarator) {
- return new MemberVariableDeclarationSyntax(TypeScript.Syntax.emptyList, variableDeclarator, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new MemberVariableDeclarationSyntax(TypeScript.Syntax.emptyList, variableDeclarator, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
MemberVariableDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13924,7 +13992,7 @@ var TypeScript;
};
ThrowStatementSyntax.prototype.kind = function () {
- return 156 /* ThrowStatement */;
+ return 157 /* ThrowStatement */;
};
ThrowStatementSyntax.prototype.childCount = function () {
@@ -13961,7 +14029,7 @@ var TypeScript;
};
ThrowStatementSyntax.create1 = function (expression) {
- return new ThrowStatementSyntax(TypeScript.Syntax.token(36 /* ThrowKeyword */), expression, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ThrowStatementSyntax(TypeScript.Syntax.token(36 /* ThrowKeyword */), expression, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ThrowStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14007,7 +14075,7 @@ var TypeScript;
};
ReturnStatementSyntax.prototype.kind = function () {
- return 149 /* ReturnStatement */;
+ return 150 /* ReturnStatement */;
};
ReturnStatementSyntax.prototype.childCount = function () {
@@ -14048,7 +14116,7 @@ var TypeScript;
};
ReturnStatementSyntax.create1 = function () {
- return new ReturnStatementSyntax(TypeScript.Syntax.token(33 /* ReturnKeyword */), null, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ReturnStatementSyntax(TypeScript.Syntax.token(33 /* ReturnKeyword */), null, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ReturnStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14094,7 +14162,7 @@ var TypeScript;
};
ObjectCreationExpressionSyntax.prototype.kind = function () {
- return 215 /* ObjectCreationExpression */;
+ return 216 /* ObjectCreationExpression */;
};
ObjectCreationExpressionSyntax.prototype.childCount = function () {
@@ -14188,7 +14256,7 @@ var TypeScript;
};
SwitchStatementSyntax.prototype.kind = function () {
- return 150 /* SwitchStatement */;
+ return 151 /* SwitchStatement */;
};
SwitchStatementSyntax.prototype.childCount = function () {
@@ -14237,7 +14305,7 @@ var TypeScript;
};
SwitchStatementSyntax.create1 = function (expression) {
- return new SwitchStatementSyntax(TypeScript.Syntax.token(34 /* SwitchKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), expression, TypeScript.Syntax.token(73 /* CloseParenToken */), TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new SwitchStatementSyntax(TypeScript.Syntax.token(34 /* SwitchKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), expression, TypeScript.Syntax.token(74 /* CloseParenToken */), TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
SwitchStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14331,7 +14399,7 @@ var TypeScript;
};
CaseSwitchClauseSyntax.prototype.kind = function () {
- return 231 /* CaseSwitchClause */;
+ return 232 /* CaseSwitchClause */;
};
CaseSwitchClauseSyntax.prototype.childCount = function () {
@@ -14366,7 +14434,7 @@ var TypeScript;
};
CaseSwitchClauseSyntax.create1 = function (expression) {
- return new CaseSwitchClauseSyntax(TypeScript.Syntax.token(16 /* CaseKeyword */), expression, TypeScript.Syntax.token(106 /* ColonToken */), TypeScript.Syntax.emptyList, false);
+ return new CaseSwitchClauseSyntax(TypeScript.Syntax.token(16 /* CaseKeyword */), expression, TypeScript.Syntax.token(107 /* ColonToken */), TypeScript.Syntax.emptyList, false);
};
CaseSwitchClauseSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14421,7 +14489,7 @@ var TypeScript;
};
DefaultSwitchClauseSyntax.prototype.kind = function () {
- return 232 /* DefaultSwitchClause */;
+ return 233 /* DefaultSwitchClause */;
};
DefaultSwitchClauseSyntax.prototype.childCount = function () {
@@ -14454,7 +14522,7 @@ var TypeScript;
};
DefaultSwitchClauseSyntax.create1 = function () {
- return new DefaultSwitchClauseSyntax(TypeScript.Syntax.token(20 /* DefaultKeyword */), TypeScript.Syntax.token(106 /* ColonToken */), TypeScript.Syntax.emptyList, false);
+ return new DefaultSwitchClauseSyntax(TypeScript.Syntax.token(20 /* DefaultKeyword */), TypeScript.Syntax.token(107 /* ColonToken */), TypeScript.Syntax.emptyList, false);
};
DefaultSwitchClauseSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14504,7 +14572,7 @@ var TypeScript;
};
BreakStatementSyntax.prototype.kind = function () {
- return 151 /* BreakStatement */;
+ return 152 /* BreakStatement */;
};
BreakStatementSyntax.prototype.childCount = function () {
@@ -14545,7 +14613,7 @@ var TypeScript;
};
BreakStatementSyntax.create1 = function () {
- return new BreakStatementSyntax(TypeScript.Syntax.token(15 /* BreakKeyword */), null, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new BreakStatementSyntax(TypeScript.Syntax.token(15 /* BreakKeyword */), null, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
BreakStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14588,7 +14656,7 @@ var TypeScript;
};
ContinueStatementSyntax.prototype.kind = function () {
- return 152 /* ContinueStatement */;
+ return 153 /* ContinueStatement */;
};
ContinueStatementSyntax.prototype.childCount = function () {
@@ -14629,7 +14697,7 @@ var TypeScript;
};
ContinueStatementSyntax.create1 = function () {
- return new ContinueStatementSyntax(TypeScript.Syntax.token(18 /* ContinueKeyword */), null, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ContinueStatementSyntax(TypeScript.Syntax.token(18 /* ContinueKeyword */), null, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ContinueStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14727,7 +14795,7 @@ var TypeScript;
};
ForStatementSyntax.prototype.kind = function () {
- return 153 /* ForStatement */;
+ return 154 /* ForStatement */;
};
ForStatementSyntax.prototype.childCount = function () {
@@ -14774,7 +14842,7 @@ var TypeScript;
};
ForStatementSyntax.create1 = function (statement) {
- return new ForStatementSyntax(TypeScript.Syntax.token(26 /* ForKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), null, null, TypeScript.Syntax.token(78 /* SemicolonToken */), null, TypeScript.Syntax.token(78 /* SemicolonToken */), null, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, false);
+ return new ForStatementSyntax(TypeScript.Syntax.token(26 /* ForKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), null, null, TypeScript.Syntax.token(79 /* SemicolonToken */), null, TypeScript.Syntax.token(79 /* SemicolonToken */), null, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, false);
};
ForStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14860,7 +14928,7 @@ var TypeScript;
};
ForInStatementSyntax.prototype.kind = function () {
- return 154 /* ForInStatement */;
+ return 155 /* ForInStatement */;
};
ForInStatementSyntax.prototype.childCount = function () {
@@ -14903,7 +14971,7 @@ var TypeScript;
};
ForInStatementSyntax.create1 = function (expression, statement) {
- return new ForInStatementSyntax(TypeScript.Syntax.token(26 /* ForKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), null, null, TypeScript.Syntax.token(29 /* InKeyword */), expression, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, false);
+ return new ForInStatementSyntax(TypeScript.Syntax.token(26 /* ForKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), null, null, TypeScript.Syntax.token(29 /* InKeyword */), expression, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, false);
};
ForInStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14977,7 +15045,7 @@ var TypeScript;
};
WhileStatementSyntax.prototype.kind = function () {
- return 157 /* WhileStatement */;
+ return 158 /* WhileStatement */;
};
WhileStatementSyntax.prototype.childCount = function () {
@@ -15010,7 +15078,7 @@ var TypeScript;
};
WhileStatementSyntax.create1 = function (condition, statement) {
- return new WhileStatementSyntax(TypeScript.Syntax.token(42 /* WhileKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), condition, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, false);
+ return new WhileStatementSyntax(TypeScript.Syntax.token(42 /* WhileKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), condition, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, false);
};
WhileStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15069,7 +15137,7 @@ var TypeScript;
};
WithStatementSyntax.prototype.kind = function () {
- return 162 /* WithStatement */;
+ return 163 /* WithStatement */;
};
WithStatementSyntax.prototype.childCount = function () {
@@ -15110,7 +15178,7 @@ var TypeScript;
};
WithStatementSyntax.create1 = function (condition, statement) {
- return new WithStatementSyntax(TypeScript.Syntax.token(43 /* WithKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), condition, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, false);
+ return new WithStatementSyntax(TypeScript.Syntax.token(43 /* WithKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), condition, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, false);
};
WithStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15170,7 +15238,7 @@ var TypeScript;
};
EnumDeclarationSyntax.prototype.kind = function () {
- return 132 /* EnumDeclaration */;
+ return 133 /* EnumDeclaration */;
};
EnumDeclarationSyntax.prototype.childCount = function () {
@@ -15213,7 +15281,7 @@ var TypeScript;
};
EnumDeclarationSyntax.create1 = function (identifier) {
- return new EnumDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(46 /* EnumKeyword */), identifier, TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new EnumDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(46 /* EnumKeyword */), identifier, TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
EnumDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15275,7 +15343,7 @@ var TypeScript;
};
EnumElementSyntax.prototype.kind = function () {
- return 243 /* EnumElement */;
+ return 244 /* EnumElement */;
};
EnumElementSyntax.prototype.childCount = function () {
@@ -15349,7 +15417,7 @@ var TypeScript;
};
CastExpressionSyntax.prototype.kind = function () {
- return 219 /* CastExpression */;
+ return 220 /* CastExpression */;
};
CastExpressionSyntax.prototype.childCount = function () {
@@ -15388,7 +15456,7 @@ var TypeScript;
};
CastExpressionSyntax.create1 = function (type, expression) {
- return new CastExpressionSyntax(TypeScript.Syntax.token(80 /* LessThanToken */), type, TypeScript.Syntax.token(81 /* GreaterThanToken */), expression, false);
+ return new CastExpressionSyntax(TypeScript.Syntax.token(81 /* LessThanToken */), type, TypeScript.Syntax.token(82 /* GreaterThanToken */), expression, false);
};
CastExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15435,7 +15503,7 @@ var TypeScript;
};
ObjectLiteralExpressionSyntax.prototype.kind = function () {
- return 214 /* ObjectLiteralExpression */;
+ return 215 /* ObjectLiteralExpression */;
};
ObjectLiteralExpressionSyntax.prototype.childCount = function () {
@@ -15476,7 +15544,7 @@ var TypeScript;
};
ObjectLiteralExpressionSyntax.create1 = function () {
- return new ObjectLiteralExpressionSyntax(TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new ObjectLiteralExpressionSyntax(TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
ObjectLiteralExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15546,7 +15614,7 @@ var TypeScript;
};
SimplePropertyAssignmentSyntax.prototype.kind = function () {
- return 238 /* SimplePropertyAssignment */;
+ return 239 /* SimplePropertyAssignment */;
};
SimplePropertyAssignmentSyntax.prototype.childCount = function () {
@@ -15575,7 +15643,7 @@ var TypeScript;
};
SimplePropertyAssignmentSyntax.create1 = function (propertyName, expression) {
- return new SimplePropertyAssignmentSyntax(propertyName, TypeScript.Syntax.token(106 /* ColonToken */), expression, false);
+ return new SimplePropertyAssignmentSyntax(propertyName, TypeScript.Syntax.token(107 /* ColonToken */), expression, false);
};
SimplePropertyAssignmentSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15620,7 +15688,7 @@ var TypeScript;
};
FunctionPropertyAssignmentSyntax.prototype.kind = function () {
- return 241 /* FunctionPropertyAssignment */;
+ return 242 /* FunctionPropertyAssignment */;
};
FunctionPropertyAssignmentSyntax.prototype.childCount = function () {
@@ -15720,7 +15788,7 @@ var TypeScript;
};
GetAccessorPropertyAssignmentSyntax.prototype.kind = function () {
- return 239 /* GetAccessorPropertyAssignment */;
+ return 240 /* GetAccessorPropertyAssignment */;
};
GetAccessorPropertyAssignmentSyntax.prototype.childCount = function () {
@@ -15759,7 +15827,7 @@ var TypeScript;
};
GetAccessorPropertyAssignmentSyntax.create1 = function (propertyName) {
- return new GetAccessorPropertyAssignmentSyntax(TypeScript.Syntax.token(64 /* GetKeyword */), propertyName, TypeScript.Syntax.token(72 /* OpenParenToken */), TypeScript.Syntax.token(73 /* CloseParenToken */), null, BlockSyntax.create1(), false);
+ return new GetAccessorPropertyAssignmentSyntax(TypeScript.Syntax.token(65 /* GetKeyword */), propertyName, TypeScript.Syntax.token(73 /* OpenParenToken */), TypeScript.Syntax.token(74 /* CloseParenToken */), null, BlockSyntax.create1(), false);
};
GetAccessorPropertyAssignmentSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15819,7 +15887,7 @@ var TypeScript;
};
SetAccessorPropertyAssignmentSyntax.prototype.kind = function () {
- return 240 /* SetAccessorPropertyAssignment */;
+ return 241 /* SetAccessorPropertyAssignment */;
};
SetAccessorPropertyAssignmentSyntax.prototype.childCount = function () {
@@ -15854,7 +15922,7 @@ var TypeScript;
};
SetAccessorPropertyAssignmentSyntax.create1 = function (propertyName, parameter) {
- return new SetAccessorPropertyAssignmentSyntax(TypeScript.Syntax.token(68 /* SetKeyword */), propertyName, TypeScript.Syntax.token(72 /* OpenParenToken */), parameter, TypeScript.Syntax.token(73 /* CloseParenToken */), BlockSyntax.create1(), false);
+ return new SetAccessorPropertyAssignmentSyntax(TypeScript.Syntax.token(69 /* SetKeyword */), propertyName, TypeScript.Syntax.token(73 /* OpenParenToken */), parameter, TypeScript.Syntax.token(74 /* CloseParenToken */), BlockSyntax.create1(), false);
};
SetAccessorPropertyAssignmentSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15916,7 +15984,7 @@ var TypeScript;
};
FunctionExpressionSyntax.prototype.kind = function () {
- return 221 /* FunctionExpression */;
+ return 222 /* FunctionExpression */;
};
FunctionExpressionSyntax.prototype.childCount = function () {
@@ -16010,7 +16078,7 @@ var TypeScript;
};
EmptyStatementSyntax.prototype.kind = function () {
- return 155 /* EmptyStatement */;
+ return 156 /* EmptyStatement */;
};
EmptyStatementSyntax.prototype.childCount = function () {
@@ -16043,7 +16111,7 @@ var TypeScript;
};
EmptyStatementSyntax.create1 = function () {
- return new EmptyStatementSyntax(TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new EmptyStatementSyntax(TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
EmptyStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16079,7 +16147,7 @@ var TypeScript;
};
TryStatementSyntax.prototype.kind = function () {
- return 158 /* TryStatement */;
+ return 159 /* TryStatement */;
};
TryStatementSyntax.prototype.childCount = function () {
@@ -16181,7 +16249,7 @@ var TypeScript;
};
CatchClauseSyntax.prototype.kind = function () {
- return 234 /* CatchClause */;
+ return 235 /* CatchClause */;
};
CatchClauseSyntax.prototype.childCount = function () {
@@ -16220,7 +16288,7 @@ var TypeScript;
};
CatchClauseSyntax.create1 = function (identifier) {
- return new CatchClauseSyntax(TypeScript.Syntax.token(17 /* CatchKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), identifier, null, TypeScript.Syntax.token(73 /* CloseParenToken */), BlockSyntax.create1(), false);
+ return new CatchClauseSyntax(TypeScript.Syntax.token(17 /* CatchKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), identifier, null, TypeScript.Syntax.token(74 /* CloseParenToken */), BlockSyntax.create1(), false);
};
CatchClauseSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16280,7 +16348,7 @@ var TypeScript;
};
FinallyClauseSyntax.prototype.kind = function () {
- return 235 /* FinallyClause */;
+ return 236 /* FinallyClause */;
};
FinallyClauseSyntax.prototype.childCount = function () {
@@ -16349,7 +16417,7 @@ var TypeScript;
};
LabeledStatementSyntax.prototype.kind = function () {
- return 159 /* LabeledStatement */;
+ return 160 /* LabeledStatement */;
};
LabeledStatementSyntax.prototype.childCount = function () {
@@ -16386,7 +16454,7 @@ var TypeScript;
};
LabeledStatementSyntax.create1 = function (identifier, statement) {
- return new LabeledStatementSyntax(identifier, TypeScript.Syntax.token(106 /* ColonToken */), statement, false);
+ return new LabeledStatementSyntax(identifier, TypeScript.Syntax.token(107 /* ColonToken */), statement, false);
};
LabeledStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16433,7 +16501,7 @@ var TypeScript;
};
DoStatementSyntax.prototype.kind = function () {
- return 160 /* DoStatement */;
+ return 161 /* DoStatement */;
};
DoStatementSyntax.prototype.childCount = function () {
@@ -16470,7 +16538,7 @@ var TypeScript;
};
DoStatementSyntax.create1 = function (statement, condition) {
- return new DoStatementSyntax(TypeScript.Syntax.token(22 /* DoKeyword */), statement, TypeScript.Syntax.token(42 /* WhileKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), condition, TypeScript.Syntax.token(73 /* CloseParenToken */), TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new DoStatementSyntax(TypeScript.Syntax.token(22 /* DoKeyword */), statement, TypeScript.Syntax.token(42 /* WhileKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), condition, TypeScript.Syntax.token(74 /* CloseParenToken */), TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
DoStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16534,7 +16602,7 @@ var TypeScript;
};
TypeOfExpressionSyntax.prototype.kind = function () {
- return 170 /* TypeOfExpression */;
+ return 171 /* TypeOfExpression */;
};
TypeOfExpressionSyntax.prototype.childCount = function () {
@@ -16610,7 +16678,7 @@ var TypeScript;
};
DeleteExpressionSyntax.prototype.kind = function () {
- return 169 /* DeleteExpression */;
+ return 170 /* DeleteExpression */;
};
DeleteExpressionSyntax.prototype.childCount = function () {
@@ -16686,7 +16754,7 @@ var TypeScript;
};
VoidExpressionSyntax.prototype.kind = function () {
- return 171 /* VoidExpression */;
+ return 172 /* VoidExpression */;
};
VoidExpressionSyntax.prototype.childCount = function () {
@@ -16762,7 +16830,7 @@ var TypeScript;
};
DebuggerStatementSyntax.prototype.kind = function () {
- return 161 /* DebuggerStatement */;
+ return 162 /* DebuggerStatement */;
};
DebuggerStatementSyntax.prototype.childCount = function () {
@@ -16797,7 +16865,7 @@ var TypeScript;
};
DebuggerStatementSyntax.create1 = function () {
- return new DebuggerStatementSyntax(TypeScript.Syntax.token(19 /* DebuggerKeyword */), TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new DebuggerStatementSyntax(TypeScript.Syntax.token(19 /* DebuggerKeyword */), TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
DebuggerStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16889,7 +16957,7 @@ var TypeScript;
};
SyntaxRewriter.prototype.visitExternalModuleReference = function (node) {
- return node.update(this.visitToken(node.requireKeyword), this.visitToken(node.openParenToken), this.visitToken(node.stringLiteral), this.visitToken(node.closeParenToken));
+ return node.update(this.visitToken(node.moduleOrRequireKeyword), this.visitToken(node.openParenToken), this.visitToken(node.stringLiteral), this.visitToken(node.closeParenToken));
};
SyntaxRewriter.prototype.visitModuleNameModuleReference = function (node) {
@@ -19709,11 +19777,11 @@ var TypeScript;
SyntaxUtilities.isAngleBracket = function (positionedElement) {
var element = positionedElement.element();
var parent = positionedElement.parentElement();
- if (parent !== null && (element.kind() === 80 /* LessThanToken */ || element.kind() === 81 /* GreaterThanToken */)) {
+ if (parent !== null && (element.kind() === 81 /* LessThanToken */ || element.kind() === 82 /* GreaterThanToken */)) {
switch (parent.kind()) {
- case 227 /* TypeArgumentList */:
- case 228 /* TypeParameterList */:
- case 219 /* CastExpression */:
+ case 228 /* TypeArgumentList */:
+ case 229 /* TypeParameterList */:
+ case 220 /* CastExpression */:
return true;
}
}
@@ -19742,13 +19810,13 @@ var TypeScript;
SyntaxUtilities.getExportKeyword = function (moduleElement) {
switch (moduleElement.kind()) {
- case 130 /* ModuleDeclaration */:
- case 131 /* ClassDeclaration */:
- case 129 /* FunctionDeclaration */:
- case 147 /* VariableStatement */:
- case 132 /* EnumDeclaration */:
- case 128 /* InterfaceDeclaration */:
- case 133 /* ImportDeclaration */:
+ case 131 /* ModuleDeclaration */:
+ case 132 /* ClassDeclaration */:
+ case 130 /* FunctionDeclaration */:
+ case 148 /* VariableStatement */:
+ case 133 /* EnumDeclaration */:
+ case 129 /* InterfaceDeclaration */:
+ case 134 /* ImportDeclaration */:
return SyntaxUtilities.getToken((moduleElement).modifiers, 47 /* ExportKeyword */);
default:
return null;
@@ -19762,26 +19830,26 @@ var TypeScript;
var node = positionNode.node();
switch (node.kind()) {
- case 130 /* ModuleDeclaration */:
- case 131 /* ClassDeclaration */:
- case 129 /* FunctionDeclaration */:
- case 147 /* VariableStatement */:
- case 132 /* EnumDeclaration */:
- if (SyntaxUtilities.containsToken((node).modifiers, 63 /* DeclareKeyword */)) {
+ case 131 /* ModuleDeclaration */:
+ case 132 /* ClassDeclaration */:
+ case 130 /* FunctionDeclaration */:
+ case 148 /* VariableStatement */:
+ case 133 /* EnumDeclaration */:
+ if (SyntaxUtilities.containsToken((node).modifiers, 64 /* DeclareKeyword */)) {
return true;
}
- case 133 /* ImportDeclaration */:
- case 137 /* ConstructorDeclaration */:
- case 135 /* MemberFunctionDeclaration */:
- case 138 /* GetMemberAccessorDeclaration */:
- case 139 /* SetMemberAccessorDeclaration */:
- case 136 /* MemberVariableDeclaration */:
+ case 134 /* ImportDeclaration */:
+ case 138 /* ConstructorDeclaration */:
+ case 136 /* MemberFunctionDeclaration */:
+ case 139 /* GetMemberAccessorDeclaration */:
+ case 140 /* SetMemberAccessorDeclaration */:
+ case 137 /* MemberVariableDeclaration */:
if (node.isClassElement() || node.isModuleElement()) {
return SyntaxUtilities.isAmbientDeclarationSyntax(positionNode.containingNode());
}
- case 243 /* EnumElement */:
+ case 244 /* EnumElement */:
return SyntaxUtilities.isAmbientDeclarationSyntax(positionNode.containingNode().containingNode());
default:
@@ -20215,7 +20283,7 @@ var TypeScript;
};
SyntaxWalker.prototype.visitExternalModuleReference = function (node) {
- this.visitToken(node.requireKeyword);
+ this.visitToken(node.moduleOrRequireKeyword);
this.visitToken(node.openParenToken);
this.visitToken(node.stringLiteral);
this.visitToken(node.closeParenToken);
@@ -21627,7 +21695,7 @@ var TypeScript;
return !this.isInStrictMode;
}
- return tokenKind <= 69 /* LastTypeScriptKeyword */;
+ return tokenKind <= 70 /* LastTypeScriptKeyword */;
}
return false;
@@ -21671,7 +21739,7 @@ var TypeScript;
return true;
}
- if (token.tokenKind === 71 /* CloseBraceToken */) {
+ if (token.tokenKind === 72 /* CloseBraceToken */) {
return true;
}
@@ -21689,7 +21757,7 @@ var TypeScript;
ParserImpl.prototype.canEatExplicitOrAutomaticSemicolon = function (allowWithoutNewline) {
var token = this.currentToken();
- if (token.tokenKind === 78 /* SemicolonToken */) {
+ if (token.tokenKind === 79 /* SemicolonToken */) {
return true;
}
@@ -21699,12 +21767,12 @@ var TypeScript;
ParserImpl.prototype.eatExplicitOrAutomaticSemicolon = function (allowWithoutNewline) {
var token = this.currentToken();
- if (token.tokenKind === 78 /* SemicolonToken */) {
- return this.eatToken(78 /* SemicolonToken */);
+ if (token.tokenKind === 79 /* SemicolonToken */) {
+ return this.eatToken(79 /* SemicolonToken */);
}
if (this.canEatAutomaticSemicolon(allowWithoutNewline)) {
- var semicolonToken = TypeScript.Syntax.emptyToken(78 /* SemicolonToken */);
+ var semicolonToken = TypeScript.Syntax.emptyToken(79 /* SemicolonToken */);
if (!this.parseOptions.allowAutomaticSemicolonInsertion()) {
this.addDiagnostic(new TypeScript.Diagnostic(this.fileName, this.previousTokenEnd(), 0, TypeScript.DiagnosticCode.Automatic_semicolon_insertion_not_allowed, null));
@@ -21713,7 +21781,7 @@ var TypeScript;
return semicolonToken;
}
- return this.eatToken(78 /* SemicolonToken */);
+ return this.eatToken(79 /* SemicolonToken */);
};
ParserImpl.prototype.isKeyword = function (kind) {
@@ -21753,78 +21821,78 @@ var TypeScript;
ParserImpl.getPrecedence = function (expressionKind) {
switch (expressionKind) {
- case 172 /* CommaExpression */:
+ case 173 /* CommaExpression */:
return 1 /* CommaExpressionPrecedence */;
- case 173 /* AssignmentExpression */:
- case 174 /* AddAssignmentExpression */:
- case 175 /* SubtractAssignmentExpression */:
- case 176 /* MultiplyAssignmentExpression */:
- case 177 /* DivideAssignmentExpression */:
- case 178 /* ModuloAssignmentExpression */:
- case 179 /* AndAssignmentExpression */:
- case 180 /* ExclusiveOrAssignmentExpression */:
- case 181 /* OrAssignmentExpression */:
- case 182 /* LeftShiftAssignmentExpression */:
- case 183 /* SignedRightShiftAssignmentExpression */:
- case 184 /* UnsignedRightShiftAssignmentExpression */:
+ case 174 /* AssignmentExpression */:
+ case 175 /* AddAssignmentExpression */:
+ case 176 /* SubtractAssignmentExpression */:
+ case 177 /* MultiplyAssignmentExpression */:
+ case 178 /* DivideAssignmentExpression */:
+ case 179 /* ModuloAssignmentExpression */:
+ case 180 /* AndAssignmentExpression */:
+ case 181 /* ExclusiveOrAssignmentExpression */:
+ case 182 /* OrAssignmentExpression */:
+ case 183 /* LeftShiftAssignmentExpression */:
+ case 184 /* SignedRightShiftAssignmentExpression */:
+ case 185 /* UnsignedRightShiftAssignmentExpression */:
return 2 /* AssignmentExpressionPrecedence */;
- case 185 /* ConditionalExpression */:
+ case 186 /* ConditionalExpression */:
return 3 /* ConditionalExpressionPrecedence */;
- case 186 /* LogicalOrExpression */:
+ case 187 /* LogicalOrExpression */:
return 5 /* LogicalOrExpressionPrecedence */;
- case 187 /* LogicalAndExpression */:
+ case 188 /* LogicalAndExpression */:
return 6 /* LogicalAndExpressionPrecedence */;
- case 188 /* BitwiseOrExpression */:
+ case 189 /* BitwiseOrExpression */:
return 7 /* BitwiseOrExpressionPrecedence */;
- case 189 /* BitwiseExclusiveOrExpression */:
+ case 190 /* BitwiseExclusiveOrExpression */:
return 8 /* BitwiseExclusiveOrExpressionPrecedence */;
- case 190 /* BitwiseAndExpression */:
+ case 191 /* BitwiseAndExpression */:
return 9 /* BitwiseAndExpressionPrecedence */;
- case 191 /* EqualsWithTypeConversionExpression */:
- case 192 /* NotEqualsWithTypeConversionExpression */:
- case 193 /* EqualsExpression */:
- case 194 /* NotEqualsExpression */:
+ case 192 /* EqualsWithTypeConversionExpression */:
+ case 193 /* NotEqualsWithTypeConversionExpression */:
+ case 194 /* EqualsExpression */:
+ case 195 /* NotEqualsExpression */:
return 10 /* EqualityExpressionPrecedence */;
- case 195 /* LessThanExpression */:
- case 196 /* GreaterThanExpression */:
- case 197 /* LessThanOrEqualExpression */:
- case 198 /* GreaterThanOrEqualExpression */:
- case 199 /* InstanceOfExpression */:
- case 200 /* InExpression */:
+ case 196 /* LessThanExpression */:
+ case 197 /* GreaterThanExpression */:
+ case 198 /* LessThanOrEqualExpression */:
+ case 199 /* GreaterThanOrEqualExpression */:
+ case 200 /* InstanceOfExpression */:
+ case 201 /* InExpression */:
return 11 /* RelationalExpressionPrecedence */;
- case 201 /* LeftShiftExpression */:
- case 202 /* SignedRightShiftExpression */:
- case 203 /* UnsignedRightShiftExpression */:
+ case 202 /* LeftShiftExpression */:
+ case 203 /* SignedRightShiftExpression */:
+ case 204 /* UnsignedRightShiftExpression */:
return 12 /* ShiftExpressionPrecdence */;
- case 207 /* AddExpression */:
- case 208 /* SubtractExpression */:
+ case 208 /* AddExpression */:
+ case 209 /* SubtractExpression */:
return 13 /* AdditiveExpressionPrecedence */;
- case 204 /* MultiplyExpression */:
- case 205 /* DivideExpression */:
- case 206 /* ModuloExpression */:
+ case 205 /* MultiplyExpression */:
+ case 206 /* DivideExpression */:
+ case 207 /* ModuloExpression */:
return 14 /* MultiplicativeExpressionPrecedence */;
- case 163 /* PlusExpression */:
- case 164 /* NegateExpression */:
- case 165 /* BitwiseNotExpression */:
- case 166 /* LogicalNotExpression */:
- case 169 /* DeleteExpression */:
- case 170 /* TypeOfExpression */:
- case 171 /* VoidExpression */:
- case 167 /* PreIncrementExpression */:
- case 168 /* PreDecrementExpression */:
+ case 164 /* PlusExpression */:
+ case 165 /* NegateExpression */:
+ case 166 /* BitwiseNotExpression */:
+ case 167 /* LogicalNotExpression */:
+ case 170 /* DeleteExpression */:
+ case 171 /* TypeOfExpression */:
+ case 172 /* VoidExpression */:
+ case 168 /* PreIncrementExpression */:
+ case 169 /* PreDecrementExpression */:
return 15 /* UnaryExpressionPrecedence */;
}
@@ -21998,7 +22066,7 @@ var TypeScript;
var modifiers = this.parseModifiers();
var importKeyword = this.eatKeyword(49 /* ImportKeyword */);
var identifier = this.eatIdentifierToken();
- var equalsToken = this.eatToken(107 /* EqualsToken */);
+ var equalsToken = this.eatToken(108 /* EqualsToken */);
var moduleReference = this.parseModuleReference();
var semicolonToken = this.eatExplicitOrAutomaticSemicolon(false);
@@ -22006,12 +22074,12 @@ var TypeScript;
};
ParserImpl.prototype.isExportAssignment = function () {
- return this.currentToken().tokenKind === 47 /* ExportKeyword */ && this.peekToken(1).tokenKind === 107 /* EqualsToken */;
+ return this.currentToken().tokenKind === 47 /* ExportKeyword */ && this.peekToken(1).tokenKind === 108 /* EqualsToken */;
};
ParserImpl.prototype.parseExportAssignment = function () {
var exportKeyword = this.eatKeyword(47 /* ExportKeyword */);
- var equalsToken = this.eatToken(107 /* EqualsToken */);
+ var equalsToken = this.eatToken(108 /* EqualsToken */);
var identifier = this.eatIdentifierToken();
var semicolonToken = this.eatExplicitOrAutomaticSemicolon(false);
@@ -22028,20 +22096,20 @@ var TypeScript;
ParserImpl.prototype.isExternalModuleReference = function () {
var token0 = this.currentToken();
- if (token0.tokenKind === 66 /* RequireKeyword */) {
- return this.peekToken(1).tokenKind === 72 /* OpenParenToken */;
+ if (token0.tokenKind === 66 /* ModuleKeyword */ || token0.tokenKind === 67 /* RequireKeyword */) {
+ return this.peekToken(1).tokenKind === 73 /* OpenParenToken */;
}
return false;
};
ParserImpl.prototype.parseExternalModuleReference = function () {
- var requireKeyword = this.eatKeyword(66 /* RequireKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var moduleOrRequireKeyword = this.eatAnyToken();
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var stringLiteral = this.eatToken(14 /* StringLiteral */);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
- return this.factory.externalModuleReference(requireKeyword, openParenToken, stringLiteral, closeParenToken);
+ return this.factory.externalModuleReference(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken);
};
ParserImpl.prototype.parseModuleNameModuleReference = function () {
@@ -22059,7 +22127,7 @@ var TypeScript;
};
ParserImpl.prototype.tryParseTypeArgumentList = function (inExpression) {
- if (this.currentToken().kind() !== 80 /* LessThanToken */) {
+ if (this.currentToken().kind() !== 81 /* LessThanToken */) {
return null;
}
@@ -22069,26 +22137,26 @@ var TypeScript;
var typeArguments;
if (!inExpression) {
- lessThanToken = this.eatToken(80 /* LessThanToken */);
+ lessThanToken = this.eatToken(81 /* LessThanToken */);
result = this.parseSeparatedSyntaxList(262144 /* TypeArgumentList_Types */);
typeArguments = result.list;
lessThanToken = this.addSkippedTokensAfterToken(lessThanToken, result.skippedTokens);
- greaterThanToken = this.eatToken(81 /* GreaterThanToken */);
+ greaterThanToken = this.eatToken(82 /* GreaterThanToken */);
return this.factory.typeArgumentList(lessThanToken, typeArguments, greaterThanToken);
}
var rewindPoint = this.getRewindPoint();
try {
- lessThanToken = this.eatToken(80 /* LessThanToken */);
+ lessThanToken = this.eatToken(81 /* LessThanToken */);
result = this.parseSeparatedSyntaxList(262144 /* TypeArgumentList_Types */);
typeArguments = result.list;
lessThanToken = this.addSkippedTokensAfterToken(lessThanToken, result.skippedTokens);
- greaterThanToken = this.eatToken(81 /* GreaterThanToken */);
+ greaterThanToken = this.eatToken(82 /* GreaterThanToken */);
if (greaterThanToken.fullWidth() === 0 || !this.canFollowTypeArgumentListInExpression(this.currentToken().kind())) {
this.rewind(rewindPoint);
@@ -22103,25 +22171,25 @@ var TypeScript;
ParserImpl.prototype.canFollowTypeArgumentListInExpression = function (kind) {
switch (kind) {
- case 72 /* OpenParenToken */:
- case 76 /* DotToken */:
+ case 73 /* OpenParenToken */:
+ case 77 /* DotToken */:
- case 73 /* CloseParenToken */:
- case 75 /* CloseBracketToken */:
- case 106 /* ColonToken */:
- case 78 /* SemicolonToken */:
- case 79 /* CommaToken */:
- case 105 /* QuestionToken */:
- case 84 /* EqualsEqualsToken */:
- case 87 /* EqualsEqualsEqualsToken */:
- case 86 /* ExclamationEqualsToken */:
- case 88 /* ExclamationEqualsEqualsToken */:
- case 103 /* AmpersandAmpersandToken */:
- case 104 /* BarBarToken */:
- case 100 /* CaretToken */:
- case 98 /* AmpersandToken */:
- case 99 /* BarToken */:
- case 71 /* CloseBraceToken */:
+ case 74 /* CloseParenToken */:
+ case 76 /* CloseBracketToken */:
+ case 107 /* ColonToken */:
+ case 79 /* SemicolonToken */:
+ case 80 /* CommaToken */:
+ case 106 /* QuestionToken */:
+ case 85 /* EqualsEqualsToken */:
+ case 88 /* EqualsEqualsEqualsToken */:
+ case 87 /* ExclamationEqualsToken */:
+ case 89 /* ExclamationEqualsEqualsToken */:
+ case 104 /* AmpersandAmpersandToken */:
+ case 105 /* BarBarToken */:
+ case 101 /* CaretToken */:
+ case 99 /* AmpersandToken */:
+ case 100 /* BarToken */:
+ case 72 /* CloseBraceToken */:
case 10 /* EndOfFileToken */:
return true;
@@ -22134,8 +22202,8 @@ var TypeScript;
var shouldContinue = this.isIdentifier(this.currentToken());
var current = this.eatIdentifierToken();
- while (shouldContinue && this.currentToken().tokenKind === 76 /* DotToken */) {
- var dotToken = this.eatToken(76 /* DotToken */);
+ while (shouldContinue && this.currentToken().tokenKind === 77 /* DotToken */) {
+ var dotToken = this.eatToken(77 /* DotToken */);
var currentToken = this.currentToken();
var identifierName;
@@ -22169,7 +22237,7 @@ var TypeScript;
var enumKeyword = this.eatKeyword(46 /* EnumKeyword */);
var identifier = this.eatIdentifierToken();
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var enumElements = TypeScript.Syntax.emptySeparatedList;
if (openBraceToken.width() > 0) {
@@ -22178,13 +22246,13 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.enumDeclaration(modifiers, enumKeyword, identifier, openBraceToken, enumElements, closeBraceToken);
};
ParserImpl.prototype.isEnumElement = function (inErrorRecovery) {
- if (this.currentNode() !== null && this.currentNode().kind() === 243 /* EnumElement */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 244 /* EnumElement */) {
return true;
}
@@ -22192,7 +22260,7 @@ var TypeScript;
};
ParserImpl.prototype.parseEnumElement = function () {
- if (this.currentNode() !== null && this.currentNode().kind() === 243 /* EnumElement */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 244 /* EnumElement */) {
return this.eatNode();
}
@@ -22211,7 +22279,7 @@ var TypeScript;
case 55 /* PrivateKeyword */:
case 58 /* StaticKeyword */:
case 47 /* ExportKeyword */:
- case 63 /* DeclareKeyword */:
+ case 64 /* DeclareKeyword */:
return true;
default:
@@ -22281,7 +22349,7 @@ var TypeScript;
var identifier = this.eatIdentifierToken();
var typeParameterList = this.parseOptionalTypeParameterList(false);
var heritageClauses = this.parseHeritageClauses();
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var classElements = TypeScript.Syntax.emptyList;
if (openBraceToken.width() > 0) {
@@ -22291,12 +22359,12 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.classDeclaration(modifiers, classKeyword, identifier, typeParameterList, heritageClauses, openBraceToken, classElements, closeBraceToken);
};
ParserImpl.prototype.isConstructorDeclaration = function () {
- return this.currentToken().tokenKind === 62 /* ConstructorKeyword */;
+ return this.currentToken().tokenKind === 63 /* ConstructorKeyword */;
};
ParserImpl.isPublicOrPrivateKeyword = function (token) {
@@ -22306,7 +22374,7 @@ var TypeScript;
ParserImpl.prototype.isMemberAccessorDeclaration = function (inErrorRecovery) {
var index = this.modifierCount();
- if (this.peekToken(index).tokenKind !== 64 /* GetKeyword */ && this.peekToken(index).tokenKind !== 68 /* SetKeyword */) {
+ if (this.peekToken(index).tokenKind !== 65 /* GetKeyword */ && this.peekToken(index).tokenKind !== 69 /* SetKeyword */) {
return false;
}
@@ -22317,9 +22385,9 @@ var TypeScript;
ParserImpl.prototype.parseMemberAccessorDeclaration = function () {
var modifiers = this.parseModifiers();
- if (this.currentToken().tokenKind === 64 /* GetKeyword */) {
+ if (this.currentToken().tokenKind === 65 /* GetKeyword */) {
return this.parseGetMemberAccessorDeclaration(modifiers);
- } else if (this.currentToken().tokenKind === 68 /* SetKeyword */) {
+ } else if (this.currentToken().tokenKind === 69 /* SetKeyword */) {
return this.parseSetMemberAccessorDeclaration(modifiers);
} else {
throw TypeScript.Errors.invalidOperation();
@@ -22327,7 +22395,7 @@ var TypeScript;
};
ParserImpl.prototype.parseGetMemberAccessorDeclaration = function (modifiers) {
- var getKeyword = this.eatKeyword(64 /* GetKeyword */);
+ var getKeyword = this.eatKeyword(65 /* GetKeyword */);
var propertyName = this.eatPropertyName();
var parameterList = this.parseParameterList();
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
@@ -22337,7 +22405,7 @@ var TypeScript;
};
ParserImpl.prototype.parseSetMemberAccessorDeclaration = function (modifiers) {
- var setKeyword = this.eatKeyword(68 /* SetKeyword */);
+ var setKeyword = this.eatKeyword(69 /* SetKeyword */);
var propertyName = this.eatPropertyName();
var parameterList = this.parseParameterList();
var block = this.parseBlock(false, false);
@@ -22354,7 +22422,7 @@ var TypeScript;
};
ParserImpl.prototype.parseConstructorDeclaration = function () {
- var constructorKeyword = this.eatKeyword(62 /* ConstructorKeyword */);
+ var constructorKeyword = this.eatKeyword(63 /* ConstructorKeyword */);
var parameterList = this.parseParameterList();
var semicolonToken = null;
@@ -22425,10 +22493,10 @@ var TypeScript;
ParserImpl.prototype.isDefinitelyMemberVariablePropertyName = function (index) {
if (TypeScript.SyntaxFacts.isAnyKeyword(this.peekToken(index).tokenKind)) {
switch (this.peekToken(index + 1).tokenKind) {
- case 78 /* SemicolonToken */:
- case 107 /* EqualsToken */:
- case 106 /* ColonToken */:
- case 71 /* CloseBraceToken */:
+ case 79 /* SemicolonToken */:
+ case 108 /* EqualsToken */:
+ case 107 /* ColonToken */:
+ case 72 /* CloseBraceToken */:
case 10 /* EndOfFileToken */:
return true;
default:
@@ -22502,9 +22570,9 @@ var TypeScript;
ParserImpl.prototype.tryAddUnexpectedEqualsGreaterThanToken = function (callSignature) {
var token0 = this.currentToken();
- var hasEqualsGreaterThanToken = token0.tokenKind === 85 /* EqualsGreaterThanToken */;
+ var hasEqualsGreaterThanToken = token0.tokenKind === 86 /* EqualsGreaterThanToken */;
if (hasEqualsGreaterThanToken) {
- var diagnostic = new TypeScript.Diagnostic(this.fileName, this.currentTokenStart(), token0.width(), TypeScript.DiagnosticCode.Unexpected_token_0_expected, [TypeScript.SyntaxFacts.getText(70 /* OpenBraceToken */)]);
+ var diagnostic = new TypeScript.Diagnostic(this.fileName, this.currentTokenStart(), token0.width(), TypeScript.DiagnosticCode.Unexpected_token_0_expected, [TypeScript.SyntaxFacts.getText(71 /* OpenBraceToken */)]);
this.addDiagnostic(diagnostic);
var token = this.eatAnyToken();
@@ -22544,11 +22612,11 @@ var TypeScript;
ParserImpl.prototype.isModuleDeclaration = function () {
var index = this.modifierCount();
- if (index > 0 && this.peekToken(index).tokenKind === 65 /* ModuleKeyword */) {
+ if (index > 0 && this.peekToken(index).tokenKind === 66 /* ModuleKeyword */) {
return true;
}
- if (this.currentToken().tokenKind === 65 /* ModuleKeyword */) {
+ if (this.currentToken().tokenKind === 66 /* ModuleKeyword */) {
var token1 = this.peekToken(1);
return this.isIdentifier(token1) || token1.tokenKind === 14 /* StringLiteral */;
}
@@ -22558,7 +22626,7 @@ var TypeScript;
ParserImpl.prototype.parseModuleDeclaration = function () {
var modifiers = this.parseModifiers();
- var moduleKeyword = this.eatKeyword(65 /* ModuleKeyword */);
+ var moduleKeyword = this.eatKeyword(66 /* ModuleKeyword */);
var moduleName = null;
var stringLiteral = null;
@@ -22569,7 +22637,7 @@ var TypeScript;
moduleName = this.parseName();
}
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var moduleElements = TypeScript.Syntax.emptyList;
if (openBraceToken.width() > 0) {
@@ -22578,7 +22646,7 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.moduleDeclaration(modifiers, moduleKeyword, moduleName, stringLiteral, openBraceToken, moduleElements, closeBraceToken);
};
@@ -22605,7 +22673,7 @@ var TypeScript;
};
ParserImpl.prototype.parseObjectType = function () {
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var typeMembers = TypeScript.Syntax.emptySeparatedList;
if (openBraceToken.width() > 0) {
@@ -22614,7 +22682,7 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.objectType(openBraceToken, typeMembers, closeBraceToken);
};
@@ -22654,9 +22722,9 @@ var TypeScript;
};
ParserImpl.prototype.parseIndexSignature = function () {
- var openBracketToken = this.eatToken(74 /* OpenBracketToken */);
+ var openBracketToken = this.eatToken(75 /* OpenBracketToken */);
var parameter = this.parseParameter();
- var closeBracketToken = this.eatToken(75 /* CloseBracketToken */);
+ var closeBracketToken = this.eatToken(76 /* CloseBracketToken */);
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
return this.factory.indexSignature(openBracketToken, parameter, closeBracketToken, typeAnnotation);
@@ -22664,7 +22732,7 @@ var TypeScript;
ParserImpl.prototype.parseMethodSignature = function () {
var propertyName = this.eatPropertyName();
- var questionToken = this.tryEatToken(105 /* QuestionToken */);
+ var questionToken = this.tryEatToken(106 /* QuestionToken */);
var callSignature = this.parseCallSignature(false);
return this.factory.methodSignature(propertyName, questionToken, callSignature);
@@ -22672,7 +22740,7 @@ var TypeScript;
ParserImpl.prototype.parsePropertySignature = function () {
var propertyName = this.eatPropertyName();
- var questionToken = this.tryEatToken(105 /* QuestionToken */);
+ var questionToken = this.tryEatToken(106 /* QuestionToken */);
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
return this.factory.propertySignature(propertyName, questionToken, typeAnnotation);
@@ -22680,7 +22748,7 @@ var TypeScript;
ParserImpl.prototype.isCallSignature = function (tokenIndex) {
var tokenKind = this.peekToken(tokenIndex).tokenKind;
- return tokenKind === 72 /* OpenParenToken */ || tokenKind === 80 /* LessThanToken */;
+ return tokenKind === 73 /* OpenParenToken */ || tokenKind === 81 /* LessThanToken */;
};
ParserImpl.prototype.isConstructSignature = function () {
@@ -22689,11 +22757,11 @@ var TypeScript;
}
var token1 = this.peekToken(1);
- return token1.tokenKind === 80 /* LessThanToken */ || token1.tokenKind === 72 /* OpenParenToken */;
+ return token1.tokenKind === 81 /* LessThanToken */ || token1.tokenKind === 73 /* OpenParenToken */;
};
ParserImpl.prototype.isIndexSignature = function () {
- return this.currentToken().tokenKind === 74 /* OpenBracketToken */;
+ return this.currentToken().tokenKind === 75 /* OpenBracketToken */;
};
ParserImpl.prototype.isMethodSignature = function (inErrorRecovery) {
@@ -22702,7 +22770,7 @@ var TypeScript;
return true;
}
- if (this.peekToken(1).tokenKind === 105 /* QuestionToken */ && this.isCallSignature(2)) {
+ if (this.peekToken(1).tokenKind === 106 /* QuestionToken */ && this.isCallSignature(2)) {
return true;
}
}
@@ -22833,9 +22901,9 @@ var TypeScript;
var doKeyword = this.eatKeyword(22 /* DoKeyword */);
var statement = this.parseStatement();
var whileKeyword = this.eatKeyword(42 /* WhileKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var condition = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var semicolonToken = this.eatExplicitOrAutomaticSemicolon(true);
@@ -22843,12 +22911,12 @@ var TypeScript;
};
ParserImpl.prototype.isLabeledStatement = function () {
- return this.isIdentifier(this.currentToken()) && this.peekToken(1).tokenKind === 106 /* ColonToken */;
+ return this.isIdentifier(this.currentToken()) && this.peekToken(1).tokenKind === 107 /* ColonToken */;
};
ParserImpl.prototype.parseLabeledStatement = function () {
var identifier = this.eatIdentifierToken();
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var statement = this.parseStatement();
return this.factory.labeledStatement(identifier, colonToken, statement);
@@ -22885,10 +22953,10 @@ var TypeScript;
ParserImpl.prototype.parseCatchClause = function () {
var catchKeyword = this.eatKeyword(17 /* CatchKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var identifier = this.eatIdentifierToken();
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var savedListParsingState = this.listParsingState;
this.listParsingState |= 128 /* CatchBlock_Statements */;
@@ -22915,9 +22983,9 @@ var TypeScript;
ParserImpl.prototype.parseWithStatement = function () {
var withKeyword = this.eatKeyword(43 /* WithKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var condition = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
return this.factory.withStatement(withKeyword, openParenToken, condition, closeParenToken, statement);
@@ -22929,9 +22997,9 @@ var TypeScript;
ParserImpl.prototype.parseWhileStatement = function () {
var whileKeyword = this.eatKeyword(42 /* WhileKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var condition = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
return this.factory.whileStatement(whileKeyword, openParenToken, condition, closeParenToken, statement);
@@ -22942,11 +23010,11 @@ var TypeScript;
return false;
}
- return this.currentToken().tokenKind === 78 /* SemicolonToken */;
+ return this.currentToken().tokenKind === 79 /* SemicolonToken */;
};
ParserImpl.prototype.parseEmptyStatement = function () {
- var semicolonToken = this.eatToken(78 /* SemicolonToken */);
+ var semicolonToken = this.eatToken(79 /* SemicolonToken */);
return this.factory.emptyStatement(semicolonToken);
};
@@ -22956,12 +23024,12 @@ var TypeScript;
ParserImpl.prototype.parseForOrForInStatement = function () {
var forKeyword = this.eatKeyword(26 /* ForKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var currentToken = this.currentToken();
if (currentToken.tokenKind === 40 /* VarKeyword */) {
return this.parseForOrForInStatementWithVariableDeclaration(forKeyword, openParenToken);
- } else if (currentToken.tokenKind === 78 /* SemicolonToken */) {
+ } else if (currentToken.tokenKind === 79 /* SemicolonToken */) {
return this.parseForStatement(forKeyword, openParenToken);
} else {
return this.parseForOrForInStatementWithInitializer(forKeyword, openParenToken);
@@ -22981,7 +23049,7 @@ var TypeScript;
ParserImpl.prototype.parseForInStatementWithVariableDeclarationOrInitializer = function (forKeyword, openParenToken, variableDeclaration, initializer) {
var inKeyword = this.eatKeyword(29 /* InKeyword */);
var expression = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
return this.factory.forInStatement(forKeyword, openParenToken, variableDeclaration, initializer, inKeyword, expression, closeParenToken, statement);
@@ -22999,7 +23067,7 @@ var TypeScript;
ParserImpl.prototype.parseForStatement = function (forKeyword, openParenToken) {
var initializer = null;
- if (this.currentToken().tokenKind !== 78 /* SemicolonToken */ && this.currentToken().tokenKind !== 73 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
+ if (this.currentToken().tokenKind !== 79 /* SemicolonToken */ && this.currentToken().tokenKind !== 74 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
initializer = this.parseExpression(false);
}
@@ -23007,21 +23075,21 @@ var TypeScript;
};
ParserImpl.prototype.parseForStatementWithVariableDeclarationOrInitializer = function (forKeyword, openParenToken, variableDeclaration, initializer) {
- var firstSemicolonToken = this.eatToken(78 /* SemicolonToken */);
+ var firstSemicolonToken = this.eatToken(79 /* SemicolonToken */);
var condition = null;
- if (this.currentToken().tokenKind !== 78 /* SemicolonToken */ && this.currentToken().tokenKind !== 73 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
+ if (this.currentToken().tokenKind !== 79 /* SemicolonToken */ && this.currentToken().tokenKind !== 74 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
condition = this.parseExpression(true);
}
- var secondSemicolonToken = this.eatToken(78 /* SemicolonToken */);
+ var secondSemicolonToken = this.eatToken(79 /* SemicolonToken */);
var incrementor = null;
- if (this.currentToken().tokenKind !== 73 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
+ if (this.currentToken().tokenKind !== 74 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
incrementor = this.parseExpression(true);
}
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
return this.factory.forStatement(forKeyword, openParenToken, variableDeclaration, initializer, firstSemicolonToken, condition, secondSemicolonToken, incrementor, closeParenToken, statement);
@@ -23069,11 +23137,11 @@ var TypeScript;
ParserImpl.prototype.parseSwitchStatement = function () {
var switchKeyword = this.eatKeyword(34 /* SwitchKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var expression = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var switchClauses = TypeScript.Syntax.emptyList;
if (openBraceToken.width() > 0) {
@@ -23082,7 +23150,7 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.switchStatement(switchKeyword, openParenToken, expression, closeParenToken, openBraceToken, switchClauses, closeBraceToken);
};
@@ -23119,7 +23187,7 @@ var TypeScript;
ParserImpl.prototype.parseCaseSwitchClause = function () {
var caseKeyword = this.eatKeyword(16 /* CaseKeyword */);
var expression = this.parseExpression(true);
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var statements = TypeScript.Syntax.emptyList;
if (colonToken.fullWidth() > 0) {
@@ -23133,7 +23201,7 @@ var TypeScript;
ParserImpl.prototype.parseDefaultSwitchClause = function () {
var defaultKeyword = this.eatKeyword(20 /* DefaultKeyword */);
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var statements = TypeScript.Syntax.emptyList;
if (colonToken.fullWidth() > 0) {
@@ -23186,7 +23254,7 @@ var TypeScript;
var currentToken = this.currentToken();
var kind = currentToken.tokenKind;
- if (kind === 70 /* OpenBraceToken */ || kind === 27 /* FunctionKeyword */) {
+ if (kind === 71 /* OpenBraceToken */ || kind === 27 /* FunctionKeyword */) {
return false;
}
@@ -23194,7 +23262,7 @@ var TypeScript;
};
ParserImpl.prototype.isAssignmentOrOmittedExpression = function () {
- if (this.currentToken().tokenKind === 79 /* CommaToken */) {
+ if (this.currentToken().tokenKind === 80 /* CommaToken */) {
return true;
}
@@ -23202,7 +23270,7 @@ var TypeScript;
};
ParserImpl.prototype.parseAssignmentOrOmittedExpression = function () {
- if (this.currentToken().tokenKind === 79 /* CommaToken */) {
+ if (this.currentToken().tokenKind === 80 /* CommaToken */) {
return this.factory.omittedExpression();
}
@@ -23219,29 +23287,29 @@ var TypeScript;
case 12 /* RegularExpressionLiteral */:
return true;
- case 74 /* OpenBracketToken */:
- case 72 /* OpenParenToken */:
+ case 75 /* OpenBracketToken */:
+ case 73 /* OpenParenToken */:
return true;
- case 80 /* LessThanToken */:
+ case 81 /* LessThanToken */:
return true;
- case 93 /* PlusPlusToken */:
- case 94 /* MinusMinusToken */:
- case 89 /* PlusToken */:
- case 90 /* MinusToken */:
- case 102 /* TildeToken */:
- case 101 /* ExclamationToken */:
+ case 94 /* PlusPlusToken */:
+ case 95 /* MinusMinusToken */:
+ case 90 /* PlusToken */:
+ case 91 /* MinusToken */:
+ case 103 /* TildeToken */:
+ case 102 /* ExclamationToken */:
return true;
- case 70 /* OpenBraceToken */:
+ case 71 /* OpenBraceToken */:
return true;
- case 85 /* EqualsGreaterThanToken */:
+ case 86 /* EqualsGreaterThanToken */:
return true;
- case 118 /* SlashToken */:
- case 119 /* SlashEqualsToken */:
+ case 119 /* SlashToken */:
+ case 120 /* SlashEqualsToken */:
return true;
case 50 /* SuperKeyword */:
@@ -23284,9 +23352,9 @@ var TypeScript;
ParserImpl.prototype.parseIfStatement = function () {
var ifKeyword = this.eatKeyword(28 /* IfKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var condition = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
var elseClause = null;
@@ -23334,7 +23402,7 @@ var TypeScript;
};
ParserImpl.prototype.isVariableDeclarator = function () {
- if (this.currentNode() !== null && this.currentNode().kind() === 224 /* VariableDeclarator */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 225 /* VariableDeclarator */) {
return true;
}
@@ -23342,7 +23410,7 @@ var TypeScript;
};
ParserImpl.prototype.canReuseVariableDeclaratorNode = function (node) {
- if (node === null || node.kind() !== 224 /* VariableDeclarator */) {
+ if (node === null || node.kind() !== 225 /* VariableDeclarator */) {
return false;
}
@@ -23371,21 +23439,21 @@ var TypeScript;
};
ParserImpl.prototype.isColonValueClause = function () {
- return this.currentToken().tokenKind === 106 /* ColonToken */;
+ return this.currentToken().tokenKind === 107 /* ColonToken */;
};
ParserImpl.prototype.isEqualsValueClause = function (inParameter) {
var token0 = this.currentToken();
- if (token0.tokenKind === 107 /* EqualsToken */) {
+ if (token0.tokenKind === 108 /* EqualsToken */) {
return true;
}
if (!this.previousToken().hasTrailingNewLine()) {
- if (token0.tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (token0.tokenKind === 86 /* EqualsGreaterThanToken */) {
return false;
}
- if (token0.tokenKind === 70 /* OpenBraceToken */ && inParameter) {
+ if (token0.tokenKind === 71 /* OpenBraceToken */ && inParameter) {
return false;
}
@@ -23396,7 +23464,7 @@ var TypeScript;
};
ParserImpl.prototype.parseEqualsValueClause = function (allowIn) {
- var equalsToken = this.eatToken(107 /* EqualsToken */);
+ var equalsToken = this.eatToken(108 /* EqualsToken */);
var value = this.parseAssignmentExpression(allowIn);
return this.factory.equalsValueClause(equalsToken, value);
@@ -23466,11 +23534,11 @@ var TypeScript;
continue;
}
- if (token0Kind === 105 /* QuestionToken */ && precedence <= 3 /* ConditionalExpressionPrecedence */) {
- var questionToken = this.eatToken(105 /* QuestionToken */);
+ if (token0Kind === 106 /* QuestionToken */ && precedence <= 3 /* ConditionalExpressionPrecedence */) {
+ var questionToken = this.eatToken(106 /* QuestionToken */);
var whenTrueExpression = this.parseAssignmentExpression(allowIn);
- var colon = this.eatToken(106 /* ColonToken */);
+ var colon = this.eatToken(107 /* ColonToken */);
var whenFalseExpression = this.parseAssignmentExpression(allowIn);
leftOperand = this.factory.conditionalExpression(leftOperand, questionToken, whenTrueExpression, colon, whenFalseExpression);
@@ -23486,7 +23554,7 @@ var TypeScript;
ParserImpl.prototype.tryMergeBinaryExpressionTokens = function () {
var token0 = this.currentToken();
- if (token0.tokenKind === 81 /* GreaterThanToken */ && !token0.hasTrailingTrivia()) {
+ if (token0.tokenKind === 82 /* GreaterThanToken */ && !token0.hasTrailingTrivia()) {
var storage = this.mergeTokensStorage;
storage[0] = 0 /* None */;
storage[1] = 0 /* None */;
@@ -23504,20 +23572,20 @@ var TypeScript;
}
}
- if (storage[0] === 81 /* GreaterThanToken */) {
- if (storage[1] === 81 /* GreaterThanToken */) {
- if (storage[2] === 107 /* EqualsToken */) {
- return { tokenCount: 4, syntaxKind: 114 /* GreaterThanGreaterThanGreaterThanEqualsToken */ };
+ if (storage[0] === 82 /* GreaterThanToken */) {
+ if (storage[1] === 82 /* GreaterThanToken */) {
+ if (storage[2] === 108 /* EqualsToken */) {
+ return { tokenCount: 4, syntaxKind: 115 /* GreaterThanGreaterThanGreaterThanEqualsToken */ };
} else {
- return { tokenCount: 3, syntaxKind: 97 /* GreaterThanGreaterThanGreaterThanToken */ };
+ return { tokenCount: 3, syntaxKind: 98 /* GreaterThanGreaterThanGreaterThanToken */ };
}
- } else if (storage[1] === 107 /* EqualsToken */) {
- return { tokenCount: 3, syntaxKind: 113 /* GreaterThanGreaterThanEqualsToken */ };
+ } else if (storage[1] === 108 /* EqualsToken */) {
+ return { tokenCount: 3, syntaxKind: 114 /* GreaterThanGreaterThanEqualsToken */ };
} else {
- return { tokenCount: 2, syntaxKind: 96 /* GreaterThanGreaterThanToken */ };
+ return { tokenCount: 2, syntaxKind: 97 /* GreaterThanGreaterThanToken */ };
}
- } else if (storage[0] === 107 /* EqualsToken */) {
- return { tokenCount: 2, syntaxKind: 83 /* GreaterThanEqualsToken */ };
+ } else if (storage[0] === 108 /* EqualsToken */) {
+ return { tokenCount: 2, syntaxKind: 84 /* GreaterThanEqualsToken */ };
}
}
@@ -23526,18 +23594,18 @@ var TypeScript;
ParserImpl.prototype.isRightAssociative = function (expressionKind) {
switch (expressionKind) {
- case 173 /* AssignmentExpression */:
- case 174 /* AddAssignmentExpression */:
- case 175 /* SubtractAssignmentExpression */:
- case 176 /* MultiplyAssignmentExpression */:
- case 177 /* DivideAssignmentExpression */:
- case 178 /* ModuloAssignmentExpression */:
- case 179 /* AndAssignmentExpression */:
- case 180 /* ExclusiveOrAssignmentExpression */:
- case 181 /* OrAssignmentExpression */:
- case 182 /* LeftShiftAssignmentExpression */:
- case 183 /* SignedRightShiftAssignmentExpression */:
- case 184 /* UnsignedRightShiftAssignmentExpression */:
+ case 174 /* AssignmentExpression */:
+ case 175 /* AddAssignmentExpression */:
+ case 176 /* SubtractAssignmentExpression */:
+ case 177 /* MultiplyAssignmentExpression */:
+ case 178 /* DivideAssignmentExpression */:
+ case 179 /* ModuloAssignmentExpression */:
+ case 180 /* AndAssignmentExpression */:
+ case 181 /* ExclusiveOrAssignmentExpression */:
+ case 182 /* OrAssignmentExpression */:
+ case 183 /* LeftShiftAssignmentExpression */:
+ case 184 /* SignedRightShiftAssignmentExpression */:
+ case 185 /* UnsignedRightShiftAssignmentExpression */:
return true;
default:
return false;
@@ -23557,7 +23625,7 @@ var TypeScript;
while (true) {
var currentTokenKind = this.currentToken().tokenKind;
switch (currentTokenKind) {
- case 72 /* OpenParenToken */:
+ case 73 /* OpenParenToken */:
if (inObjectCreation) {
return expression;
}
@@ -23565,7 +23633,7 @@ var TypeScript;
expression = this.factory.invocationExpression(expression, this.parseArgumentList(null));
continue;
- case 80 /* LessThanToken */:
+ case 81 /* LessThanToken */:
if (inObjectCreation) {
return expression;
}
@@ -23578,12 +23646,12 @@ var TypeScript;
break;
- case 74 /* OpenBracketToken */:
+ case 75 /* OpenBracketToken */:
expression = this.parseElementAccessExpression(expression, inObjectCreation);
continue;
- case 93 /* PlusPlusToken */:
- case 94 /* MinusMinusToken */:
+ case 94 /* PlusPlusToken */:
+ case 95 /* MinusMinusToken */:
if (this.previousToken() !== null && this.previousToken().hasTrailingNewLine()) {
break;
}
@@ -23591,8 +23659,8 @@ var TypeScript;
expression = this.factory.postfixUnaryExpression(TypeScript.SyntaxFacts.getPostfixUnaryExpressionFromOperatorToken(currentTokenKind), expression, this.eatAnyToken());
continue;
- case 76 /* DotToken */:
- expression = this.factory.memberAccessExpression(expression, this.eatToken(76 /* DotToken */), this.eatIdentifierNameToken());
+ case 77 /* DotToken */:
+ expression = this.factory.memberAccessExpression(expression, this.eatToken(77 /* DotToken */), this.eatIdentifierNameToken());
continue;
}
@@ -23603,14 +23671,14 @@ var TypeScript;
ParserImpl.prototype.tryParseArgumentList = function () {
var typeArgumentList = null;
- if (this.currentToken().tokenKind === 80 /* LessThanToken */) {
+ if (this.currentToken().tokenKind === 81 /* LessThanToken */) {
var rewindPoint = this.getRewindPoint();
try {
typeArgumentList = this.tryParseTypeArgumentList(true);
var token0 = this.currentToken();
- var isOpenParen = token0.tokenKind === 72 /* OpenParenToken */;
- var isDot = token0.tokenKind === 76 /* DotToken */;
+ var isOpenParen = token0.tokenKind === 73 /* OpenParenToken */;
+ var isDot = token0.tokenKind === 77 /* DotToken */;
var isOpenParenOrDot = isOpenParen || isDot;
if (typeArgumentList === null || !isOpenParenOrDot) {
this.rewind(rewindPoint);
@@ -23621,14 +23689,14 @@ var TypeScript;
var diagnostic = new TypeScript.Diagnostic(this.fileName, this.currentTokenStart(), token0.width(), TypeScript.DiagnosticCode.A_parameter_list_must_follow_a_generic_type_argument_list_expected, null);
this.addDiagnostic(diagnostic);
- return this.factory.argumentList(typeArgumentList, TypeScript.Syntax.emptyToken(72 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.emptyToken(73 /* CloseParenToken */));
+ return this.factory.argumentList(typeArgumentList, TypeScript.Syntax.emptyToken(73 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.emptyToken(74 /* CloseParenToken */));
}
} finally {
this.releaseRewindPoint(rewindPoint);
}
}
- if (this.currentToken().tokenKind === 72 /* OpenParenToken */) {
+ if (this.currentToken().tokenKind === 73 /* OpenParenToken */) {
return this.parseArgumentList(typeArgumentList);
}
@@ -23636,7 +23704,7 @@ var TypeScript;
};
ParserImpl.prototype.parseArgumentList = function (typeArgumentList) {
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var arguments = TypeScript.Syntax.emptySeparatedList;
if (openParenToken.fullWidth() > 0) {
@@ -23645,17 +23713,17 @@ var TypeScript;
openParenToken = this.addSkippedTokensAfterToken(openParenToken, result.skippedTokens);
}
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
return this.factory.argumentList(typeArgumentList, openParenToken, arguments, closeParenToken);
};
ParserImpl.prototype.parseElementAccessExpression = function (expression, inObjectCreation) {
var start = this.currentTokenStart();
- var openBracketToken = this.eatToken(74 /* OpenBracketToken */);
+ var openBracketToken = this.eatToken(75 /* OpenBracketToken */);
var argumentExpression;
- if (this.currentToken().tokenKind === 75 /* CloseBracketToken */ && inObjectCreation) {
+ if (this.currentToken().tokenKind === 76 /* CloseBracketToken */ && inObjectCreation) {
var end = this.currentTokenStart() + this.currentToken().width();
var diagnostic = new TypeScript.Diagnostic(this.fileName, start, end - start, TypeScript.DiagnosticCode.new_T_cannot_be_used_to_create_an_array_Use_new_Array_T_instead, null);
this.addDiagnostic(diagnostic);
@@ -23665,7 +23733,7 @@ var TypeScript;
argumentExpression = this.parseExpression(true);
}
- var closeBracketToken = this.eatToken(75 /* CloseBracketToken */);
+ var closeBracketToken = this.eatToken(76 /* CloseBracketToken */);
return this.factory.elementAccessExpression(expression, openBracketToken, argumentExpression, closeBracketToken);
};
@@ -23673,7 +23741,7 @@ var TypeScript;
ParserImpl.prototype.parseTermWorker = function () {
var currentToken = this.currentToken();
- if (currentToken.tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (currentToken.tokenKind === 86 /* EqualsGreaterThanToken */) {
return this.parseSimpleArrowFunctionExpression();
}
@@ -23725,20 +23793,20 @@ var TypeScript;
case 14 /* StringLiteral */:
return this.parseLiteralExpression();
- case 74 /* OpenBracketToken */:
+ case 75 /* OpenBracketToken */:
return this.parseArrayLiteralExpression();
- case 70 /* OpenBraceToken */:
+ case 71 /* OpenBraceToken */:
return this.parseObjectLiteralExpression();
- case 72 /* OpenParenToken */:
+ case 73 /* OpenParenToken */:
return this.parseParenthesizedOrArrowFunctionExpression();
- case 80 /* LessThanToken */:
+ case 81 /* LessThanToken */:
return this.parseCastOrArrowFunctionExpression();
- case 118 /* SlashToken */:
- case 119 /* SlashEqualsToken */:
+ case 119 /* SlashToken */:
+ case 120 /* SlashEqualsToken */:
var result = this.tryReparseDivideAsRegularExpression();
if (result !== null) {
return result;
@@ -23766,17 +23834,17 @@ var TypeScript;
case 14 /* StringLiteral */:
case 13 /* NumericLiteral */:
case 12 /* RegularExpressionLiteral */:
- case 93 /* PlusPlusToken */:
- case 94 /* MinusMinusToken */:
- case 75 /* CloseBracketToken */:
- case 71 /* CloseBraceToken */:
+ case 94 /* PlusPlusToken */:
+ case 95 /* MinusMinusToken */:
+ case 76 /* CloseBracketToken */:
+ case 72 /* CloseBraceToken */:
return null;
}
}
currentToken = this.currentTokenAllowingRegularExpression();
- if (currentToken.tokenKind === 118 /* SlashToken */ || currentToken.tokenKind === 119 /* SlashEqualsToken */) {
+ if (currentToken.tokenKind === 119 /* SlashToken */ || currentToken.tokenKind === 120 /* SlashEqualsToken */) {
return null;
} else if (currentToken.tokenKind === 12 /* RegularExpressionLiteral */) {
return this.parseLiteralExpression();
@@ -23850,9 +23918,9 @@ var TypeScript;
};
ParserImpl.prototype.parseCastExpression = function () {
- var lessThanToken = this.eatToken(80 /* LessThanToken */);
+ var lessThanToken = this.eatToken(81 /* LessThanToken */);
var type = this.parseType();
- var greaterThanToken = this.eatToken(81 /* GreaterThanToken */);
+ var greaterThanToken = this.eatToken(82 /* GreaterThanToken */);
var expression = this.parseUnaryExpression();
return this.factory.castExpression(lessThanToken, type, greaterThanToken, expression);
@@ -23864,9 +23932,9 @@ var TypeScript;
return result;
}
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var expression = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
return this.factory.parenthesizedExpression(openParenToken, expression, closeParenToken);
};
@@ -23899,11 +23967,11 @@ var TypeScript;
var callSignature = this.parseCallSignature(true);
- if (requireArrow && this.currentToken().tokenKind !== 85 /* EqualsGreaterThanToken */) {
+ if (requireArrow && this.currentToken().tokenKind !== 86 /* EqualsGreaterThanToken */) {
return null;
}
- var equalsGreaterThanToken = this.eatToken(85 /* EqualsGreaterThanToken */);
+ var equalsGreaterThanToken = this.eatToken(86 /* EqualsGreaterThanToken */);
var body = this.parseArrowFunctionBody();
return this.factory.parenthesizedArrowFunctionExpression(callSignature, equalsGreaterThanToken, body);
@@ -23918,40 +23986,40 @@ var TypeScript;
};
ParserImpl.prototype.isSimpleArrowFunctionExpression = function () {
- if (this.currentToken().tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (this.currentToken().tokenKind === 86 /* EqualsGreaterThanToken */) {
return true;
}
- return this.isIdentifier(this.currentToken()) && this.peekToken(1).tokenKind === 85 /* EqualsGreaterThanToken */;
+ return this.isIdentifier(this.currentToken()) && this.peekToken(1).tokenKind === 86 /* EqualsGreaterThanToken */;
};
ParserImpl.prototype.parseSimpleArrowFunctionExpression = function () {
var identifier = this.eatIdentifierToken();
- var equalsGreaterThanToken = this.eatToken(85 /* EqualsGreaterThanToken */);
+ var equalsGreaterThanToken = this.eatToken(86 /* EqualsGreaterThanToken */);
var body = this.parseArrowFunctionBody();
return this.factory.simpleArrowFunctionExpression(identifier, equalsGreaterThanToken, body);
};
ParserImpl.prototype.isBlock = function () {
- return this.currentToken().tokenKind === 70 /* OpenBraceToken */;
+ return this.currentToken().tokenKind === 71 /* OpenBraceToken */;
};
ParserImpl.prototype.isDefinitelyArrowFunctionExpression = function () {
var token0 = this.currentToken();
- if (token0.tokenKind !== 72 /* OpenParenToken */) {
+ if (token0.tokenKind !== 73 /* OpenParenToken */) {
return false;
}
var token1 = this.peekToken(1);
var token2;
- if (token1.tokenKind === 73 /* CloseParenToken */) {
+ if (token1.tokenKind === 74 /* CloseParenToken */) {
token2 = this.peekToken(2);
- return token2.tokenKind === 106 /* ColonToken */ || token2.tokenKind === 85 /* EqualsGreaterThanToken */ || token2.tokenKind === 70 /* OpenBraceToken */;
+ return token2.tokenKind === 107 /* ColonToken */ || token2.tokenKind === 86 /* EqualsGreaterThanToken */ || token2.tokenKind === 71 /* OpenBraceToken */;
}
- if (token1.tokenKind === 77 /* DotDotDotToken */) {
+ if (token1.tokenKind === 78 /* DotDotDotToken */) {
return true;
}
@@ -23960,19 +24028,19 @@ var TypeScript;
}
token2 = this.peekToken(2);
- if (token2.tokenKind === 106 /* ColonToken */) {
+ if (token2.tokenKind === 107 /* ColonToken */) {
return true;
}
var token3 = this.peekToken(3);
- if (token2.tokenKind === 105 /* QuestionToken */) {
- if (token3.tokenKind === 106 /* ColonToken */ || token3.tokenKind === 73 /* CloseParenToken */ || token3.tokenKind === 79 /* CommaToken */) {
+ if (token2.tokenKind === 106 /* QuestionToken */) {
+ if (token3.tokenKind === 107 /* ColonToken */ || token3.tokenKind === 74 /* CloseParenToken */ || token3.tokenKind === 80 /* CommaToken */) {
return true;
}
}
- if (token2.tokenKind === 73 /* CloseParenToken */) {
- if (token3.tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (token2.tokenKind === 74 /* CloseParenToken */) {
+ if (token3.tokenKind === 86 /* EqualsGreaterThanToken */) {
return true;
}
}
@@ -23982,7 +24050,7 @@ var TypeScript;
ParserImpl.prototype.isPossiblyArrowFunctionExpression = function () {
var token0 = this.currentToken();
- if (token0.tokenKind !== 72 /* OpenParenToken */) {
+ if (token0.tokenKind !== 73 /* OpenParenToken */) {
return true;
}
@@ -23993,17 +24061,17 @@ var TypeScript;
}
var token2 = this.peekToken(2);
- if (token2.tokenKind === 107 /* EqualsToken */) {
+ if (token2.tokenKind === 108 /* EqualsToken */) {
return true;
}
- if (token2.tokenKind === 79 /* CommaToken */) {
+ if (token2.tokenKind === 80 /* CommaToken */) {
return true;
}
- if (token2.tokenKind === 73 /* CloseParenToken */) {
+ if (token2.tokenKind === 74 /* CloseParenToken */) {
var token3 = this.peekToken(3);
- if (token3.tokenKind === 106 /* ColonToken */) {
+ if (token3.tokenKind === 107 /* ColonToken */) {
return true;
}
}
@@ -24012,13 +24080,13 @@ var TypeScript;
};
ParserImpl.prototype.parseObjectLiteralExpression = function () {
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var result = this.parseSeparatedSyntaxList(32768 /* ObjectLiteralExpression_PropertyAssignments */);
var propertyAssignments = result.list;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.objectLiteralExpression(openBraceToken, propertyAssignments, closeBraceToken);
};
@@ -24042,14 +24110,14 @@ var TypeScript;
};
ParserImpl.prototype.isGetAccessorPropertyAssignment = function (inErrorRecovery) {
- return this.currentToken().tokenKind === 64 /* GetKeyword */ && this.isPropertyName(this.peekToken(1), inErrorRecovery);
+ return this.currentToken().tokenKind === 65 /* GetKeyword */ && this.isPropertyName(this.peekToken(1), inErrorRecovery);
};
ParserImpl.prototype.parseGetAccessorPropertyAssignment = function () {
- var getKeyword = this.eatKeyword(64 /* GetKeyword */);
+ var getKeyword = this.eatKeyword(65 /* GetKeyword */);
var propertyName = this.eatPropertyName();
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
var block = this.parseBlock(false, true);
@@ -24057,15 +24125,15 @@ var TypeScript;
};
ParserImpl.prototype.isSetAccessorPropertyAssignment = function (inErrorRecovery) {
- return this.currentToken().tokenKind === 68 /* SetKeyword */ && this.isPropertyName(this.peekToken(1), inErrorRecovery);
+ return this.currentToken().tokenKind === 69 /* SetKeyword */ && this.isPropertyName(this.peekToken(1), inErrorRecovery);
};
ParserImpl.prototype.parseSetAccessorPropertyAssignment = function () {
- var setKeyword = this.eatKeyword(68 /* SetKeyword */);
+ var setKeyword = this.eatKeyword(69 /* SetKeyword */);
var propertyName = this.eatPropertyName();
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var parameter = this.parseParameter();
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var block = this.parseBlock(false, true);
return this.factory.setAccessorPropertyAssignment(setKeyword, propertyName, openParenToken, parameter, closeParenToken, block);
@@ -24093,7 +24161,7 @@ var TypeScript;
ParserImpl.prototype.parseSimplePropertyAssignment = function () {
var propertyName = this.eatPropertyName();
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var expression = this.parseAssignmentExpression(true);
return this.factory.simplePropertyAssignment(propertyName, colonToken, expression);
@@ -24119,13 +24187,13 @@ var TypeScript;
};
ParserImpl.prototype.parseArrayLiteralExpression = function () {
- var openBracketToken = this.eatToken(74 /* OpenBracketToken */);
+ var openBracketToken = this.eatToken(75 /* OpenBracketToken */);
var result = this.parseSeparatedSyntaxList(65536 /* ArrayLiteralExpression_AssignmentExpressions */);
var expressions = result.list;
openBracketToken = this.addSkippedTokensAfterToken(openBracketToken, result.skippedTokens);
- var closeBracketToken = this.eatToken(75 /* CloseBracketToken */);
+ var closeBracketToken = this.eatToken(76 /* CloseBracketToken */);
return this.factory.arrayLiteralExpression(openBracketToken, expressions, closeBracketToken);
};
@@ -24140,7 +24208,7 @@ var TypeScript;
};
ParserImpl.prototype.parseBlock = function (parseBlockEvenWithNoOpenBrace, checkForStrictMode) {
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var statements = TypeScript.Syntax.emptyList;
@@ -24155,7 +24223,7 @@ var TypeScript;
this.setStrictMode(savedIsInStrictMode);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.block(openBraceToken, statements, closeBraceToken);
};
@@ -24169,19 +24237,19 @@ var TypeScript;
};
ParserImpl.prototype.parseOptionalTypeParameterList = function (requireCompleteTypeParameterList) {
- if (this.currentToken().tokenKind !== 80 /* LessThanToken */) {
+ if (this.currentToken().tokenKind !== 81 /* LessThanToken */) {
return null;
}
var rewindPoint = this.getRewindPoint();
try {
- var lessThanToken = this.eatToken(80 /* LessThanToken */);
+ var lessThanToken = this.eatToken(81 /* LessThanToken */);
var result = this.parseSeparatedSyntaxList(524288 /* TypeParameterList_TypeParameters */);
var typeParameterList = result.list;
lessThanToken = this.addSkippedTokensAfterToken(lessThanToken, result.skippedTokens);
- var greaterThanToken = this.eatToken(81 /* GreaterThanToken */);
+ var greaterThanToken = this.eatToken(82 /* GreaterThanToken */);
if (requireCompleteTypeParameterList && greaterThanToken.fullWidth() === 0) {
this.rewind(rewindPoint);
@@ -24217,7 +24285,7 @@ var TypeScript;
};
ParserImpl.prototype.parseParameterList = function () {
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var parameters = TypeScript.Syntax.emptySeparatedList;
if (openParenToken.width() > 0) {
@@ -24226,12 +24294,12 @@ var TypeScript;
openParenToken = this.addSkippedTokensAfterToken(openParenToken, result.skippedTokens);
}
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
return this.factory.parameterList(openParenToken, parameters, closeParenToken);
};
ParserImpl.prototype.isTypeAnnotation = function () {
- return this.currentToken().tokenKind === 106 /* ColonToken */;
+ return this.currentToken().tokenKind === 107 /* ColonToken */;
};
ParserImpl.prototype.parseOptionalTypeAnnotation = function (allowStringLiteral) {
@@ -24239,7 +24307,7 @@ var TypeScript;
};
ParserImpl.prototype.parseTypeAnnotation = function (allowStringLiteral) {
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var type = allowStringLiteral && this.currentToken().tokenKind === 14 /* StringLiteral */ ? this.eatToken(14 /* StringLiteral */) : this.parseType();
return this.factory.typeAnnotation(colonToken, type);
@@ -24255,9 +24323,9 @@ var TypeScript;
} else {
var type = this.parseNonArrayType();
- while (this.currentToken().tokenKind === 74 /* OpenBracketToken */) {
- var openBracketToken = this.eatToken(74 /* OpenBracketToken */);
- var closeBracketToken = this.eatToken(75 /* CloseBracketToken */);
+ while (this.currentToken().tokenKind === 75 /* OpenBracketToken */) {
+ var openBracketToken = this.eatToken(75 /* OpenBracketToken */);
+ var closeBracketToken = this.eatToken(76 /* CloseBracketToken */);
type = this.factory.arrayType(type, openBracketToken, closeBracketToken);
}
@@ -24309,7 +24377,7 @@ var TypeScript;
ParserImpl.prototype.parseFunctionType = function () {
var typeParameterList = this.parseOptionalTypeParameterList(false);
var parameterList = this.parseParameterList();
- var equalsGreaterThanToken = this.eatToken(85 /* EqualsGreaterThanToken */);
+ var equalsGreaterThanToken = this.eatToken(86 /* EqualsGreaterThanToken */);
var returnType = this.parseType();
return this.factory.functionType(typeParameterList, parameterList, equalsGreaterThanToken, returnType);
@@ -24318,7 +24386,7 @@ var TypeScript;
ParserImpl.prototype.parseConstructorType = function () {
var newKeyword = this.eatKeyword(31 /* NewKeyword */);
var parameterList = this.parseParameterList();
- var equalsGreaterThanToken = this.eatToken(85 /* EqualsGreaterThanToken */);
+ var equalsGreaterThanToken = this.eatToken(86 /* EqualsGreaterThanToken */);
var type = this.parseType();
return this.factory.constructorType(newKeyword, null, parameterList, equalsGreaterThanToken, type);
@@ -24329,12 +24397,12 @@ var TypeScript;
};
ParserImpl.prototype.isObjectType = function () {
- return this.currentToken().tokenKind === 70 /* OpenBraceToken */;
+ return this.currentToken().tokenKind === 71 /* OpenBraceToken */;
};
ParserImpl.prototype.isFunctionType = function () {
var tokenKind = this.currentToken().tokenKind;
- return tokenKind === 72 /* OpenParenToken */ || tokenKind === 80 /* LessThanToken */;
+ return tokenKind === 73 /* OpenParenToken */ || tokenKind === 81 /* LessThanToken */;
};
ParserImpl.prototype.isConstructorType = function () {
@@ -24348,9 +24416,10 @@ var TypeScript;
ParserImpl.prototype.isPredefinedType = function () {
switch (this.currentToken().tokenKind) {
case 60 /* AnyKeyword */:
- case 67 /* NumberKeyword */:
+ case 68 /* NumberKeyword */:
case 61 /* BooleanKeyword */:
- case 69 /* StringKeyword */:
+ case 62 /* BoolKeyword */:
+ case 70 /* StringKeyword */:
case 41 /* VoidKeyword */:
return true;
}
@@ -24359,12 +24428,12 @@ var TypeScript;
};
ParserImpl.prototype.isParameter = function () {
- if (this.currentNode() !== null && this.currentNode().kind() === 242 /* Parameter */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 243 /* Parameter */) {
return true;
}
var token = this.currentToken();
- if (token.tokenKind === 77 /* DotDotDotToken */) {
+ if (token.tokenKind === 78 /* DotDotDotToken */) {
return true;
}
@@ -24376,11 +24445,11 @@ var TypeScript;
};
ParserImpl.prototype.parseParameter = function () {
- if (this.currentNode() !== null && this.currentNode().kind() === 242 /* Parameter */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 243 /* Parameter */) {
return this.eatNode();
}
- var dotDotDotToken = this.tryEatToken(77 /* DotDotDotToken */);
+ var dotDotDotToken = this.tryEatToken(78 /* DotDotDotToken */);
var publicOrPrivateToken = null;
if (ParserImpl.isPublicOrPrivateKeyword(this.currentToken())) {
@@ -24388,7 +24457,7 @@ var TypeScript;
}
var identifier = this.eatIdentifierToken();
- var questionToken = this.tryEatToken(105 /* QuestionToken */);
+ var questionToken = this.tryEatToken(106 /* QuestionToken */);
var typeAnnotation = this.parseOptionalTypeAnnotation(true);
var equalsValueClause = null;
@@ -24526,7 +24595,7 @@ var TypeScript;
TypeScript.Debug.assert(skippedTokens !== items);
var separatorKind = this.separatorKind(currentListType);
- var allowAutomaticSemicolonInsertion = separatorKind === 78 /* SemicolonToken */;
+ var allowAutomaticSemicolonInsertion = separatorKind === 79 /* SemicolonToken */;
var inErrorRecovery = false;
var listWasTerminated = false;
@@ -24554,7 +24623,7 @@ var TypeScript;
inErrorRecovery = false;
var currentToken = this.currentToken();
- if (currentToken.tokenKind === separatorKind || currentToken.tokenKind === 79 /* CommaToken */) {
+ if (currentToken.tokenKind === separatorKind || currentToken.tokenKind === 80 /* CommaToken */) {
items.push(this.eatAnyToken());
continue;
}
@@ -24594,10 +24663,10 @@ var TypeScript;
case 65536 /* ArrayLiteralExpression_AssignmentExpressions */:
case 262144 /* TypeArgumentList_Types */:
case 524288 /* TypeParameterList_TypeParameters */:
- return 79 /* CommaToken */;
+ return 80 /* CommaToken */;
case 512 /* ObjectType_TypeMembers */:
- return 78 /* SemicolonToken */;
+ return 79 /* SemicolonToken */;
case 1 /* SourceUnit_ModuleElements */:
case 1024 /* ClassOrInterfaceDeclaration_HeritageClauses */:
@@ -24698,28 +24767,28 @@ var TypeScript;
};
ParserImpl.prototype.isExpectedEnumDeclaration_EnumElementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedModuleDeclaration_ModuleElementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedObjectType_TypeMembersTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedObjectLiteralExpression_PropertyAssignmentsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedLiteralExpression_AssignmentExpressionsTerminator = function () {
- return this.currentToken().tokenKind === 75 /* CloseBracketToken */;
+ return this.currentToken().tokenKind === 76 /* CloseBracketToken */;
};
ParserImpl.prototype.isExpectedTypeArgumentList_TypesTerminator = function () {
var token = this.currentToken();
- if (token.tokenKind === 81 /* GreaterThanToken */) {
+ if (token.tokenKind === 82 /* GreaterThanToken */) {
return true;
}
@@ -24732,11 +24801,11 @@ var TypeScript;
ParserImpl.prototype.isExpectedTypeParameterList_TypeParametersTerminator = function () {
var token = this.currentToken();
- if (token.tokenKind === 81 /* GreaterThanToken */) {
+ if (token.tokenKind === 82 /* GreaterThanToken */) {
return true;
}
- if (token.tokenKind === 72 /* OpenParenToken */ || token.tokenKind === 70 /* OpenBraceToken */ || token.tokenKind === 48 /* ExtendsKeyword */ || token.tokenKind === 51 /* ImplementsKeyword */) {
+ if (token.tokenKind === 73 /* OpenParenToken */ || token.tokenKind === 71 /* OpenBraceToken */ || token.tokenKind === 48 /* ExtendsKeyword */ || token.tokenKind === 51 /* ImplementsKeyword */) {
return true;
}
@@ -24745,15 +24814,15 @@ var TypeScript;
ParserImpl.prototype.isExpectedParameterList_ParametersTerminator = function () {
var token = this.currentToken();
- if (token.tokenKind === 73 /* CloseParenToken */) {
+ if (token.tokenKind === 74 /* CloseParenToken */) {
return true;
}
- if (token.tokenKind === 70 /* OpenBraceToken */) {
+ if (token.tokenKind === 71 /* OpenBraceToken */) {
return true;
}
- if (token.tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (token.tokenKind === 86 /* EqualsGreaterThanToken */) {
return true;
}
@@ -24761,7 +24830,7 @@ var TypeScript;
};
ParserImpl.prototype.isExpectedVariableDeclaration_VariableDeclarators_DisallowInTerminator = function () {
- if (this.currentToken().tokenKind === 78 /* SemicolonToken */ || this.currentToken().tokenKind === 73 /* CloseParenToken */) {
+ if (this.currentToken().tokenKind === 79 /* SemicolonToken */ || this.currentToken().tokenKind === 74 /* CloseParenToken */) {
return true;
}
@@ -24773,11 +24842,11 @@ var TypeScript;
};
ParserImpl.prototype.isExpectedVariableDeclaration_VariableDeclarators_AllowInTerminator = function () {
- if (this.previousToken().tokenKind === 79 /* CommaToken */) {
+ if (this.previousToken().tokenKind === 80 /* CommaToken */) {
return false;
}
- if (this.currentToken().tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (this.currentToken().tokenKind === 86 /* EqualsGreaterThanToken */) {
return true;
}
@@ -24786,7 +24855,7 @@ var TypeScript;
ParserImpl.prototype.isExpectedClassOrInterfaceDeclaration_HeritageClausesTerminator = function () {
var token0 = this.currentToken();
- if (token0.tokenKind === 70 /* OpenBraceToken */ || token0.tokenKind === 71 /* CloseBraceToken */) {
+ if (token0.tokenKind === 71 /* OpenBraceToken */ || token0.tokenKind === 72 /* CloseBraceToken */) {
return true;
}
@@ -24808,23 +24877,23 @@ var TypeScript;
ParserImpl.prototype.isExpectedArgumentList_AssignmentExpressionsTerminator = function () {
var token0 = this.currentToken();
- return token0.tokenKind === 73 /* CloseParenToken */ || token0.tokenKind === 78 /* SemicolonToken */;
+ return token0.tokenKind === 74 /* CloseParenToken */ || token0.tokenKind === 79 /* SemicolonToken */;
};
ParserImpl.prototype.isExpectedClassDeclaration_ClassElementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedSwitchStatement_SwitchClausesTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedSwitchClause_StatementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */ || this.isSwitchClause();
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */ || this.isSwitchClause();
};
ParserImpl.prototype.isExpectedBlock_StatementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedTryBlock_StatementsTerminator = function () {
@@ -24903,7 +24972,7 @@ var TypeScript;
return true;
}
- if (this.currentToken().tokenKind === 79 /* CommaToken */) {
+ if (this.currentToken().tokenKind === 80 /* CommaToken */) {
return true;
}
@@ -25347,7 +25416,7 @@ var TypeScript;
} else if (!parameter.typeAnnotation) {
this.pushDiagnostic1(parameterFullStart, parameter, TypeScript.DiagnosticCode.Index_signature_parameter_must_have_a_type_annotation);
return true;
- } else if (parameter.typeAnnotation.type.kind() !== 69 /* StringKeyword */ && parameter.typeAnnotation.type.kind() !== 67 /* NumberKeyword */) {
+ } else if (parameter.typeAnnotation.type.kind() !== 70 /* StringKeyword */ && parameter.typeAnnotation.type.kind() !== 68 /* NumberKeyword */) {
this.pushDiagnostic1(parameterFullStart, parameter, TypeScript.DiagnosticCode.Index_signature_parameter_type_must_be_string_or_number);
return true;
}
@@ -25415,7 +25484,7 @@ var TypeScript;
GrammarCheckerWalker.prototype.checkForDisallowedDeclareModifier = function (modifiers) {
if (this.inAmbientDeclaration) {
- var declareToken = TypeScript.SyntaxUtilities.getToken(modifiers, 63 /* DeclareKeyword */);
+ var declareToken = TypeScript.SyntaxUtilities.getToken(modifiers, 64 /* DeclareKeyword */);
if (declareToken) {
this.pushDiagnostic1(this.childFullStart(modifiers, declareToken), declareToken, TypeScript.DiagnosticCode.declare_modifier_not_allowed_for_code_already_in_an_ambient_context);
@@ -25428,7 +25497,7 @@ var TypeScript;
GrammarCheckerWalker.prototype.checkForRequiredDeclareModifier = function (moduleElement, typeKeyword, modifiers) {
if (!this.inAmbientDeclaration && this.syntaxTree.isDeclaration()) {
- if (!TypeScript.SyntaxUtilities.containsToken(modifiers, 63 /* DeclareKeyword */)) {
+ if (!TypeScript.SyntaxUtilities.containsToken(modifiers, 64 /* DeclareKeyword */)) {
this.pushDiagnostic1(this.childFullStart(moduleElement, typeKeyword), typeKeyword.firstToken(), TypeScript.DiagnosticCode.declare_modifier_required_for_top_level_element);
return true;
}
@@ -25447,7 +25516,7 @@ var TypeScript;
var lastElement = i === (n - 1);
if (inFunctionOverloadChain) {
- if (moduleElement.kind() !== 129 /* FunctionDeclaration */) {
+ if (moduleElement.kind() !== 130 /* FunctionDeclaration */) {
this.pushDiagnostic1(moduleElementFullStart, moduleElement.firstToken(), TypeScript.DiagnosticCode.Function_implementation_expected);
return true;
}
@@ -25460,9 +25529,9 @@ var TypeScript;
}
}
- if (moduleElement.kind() === 129 /* FunctionDeclaration */) {
+ if (moduleElement.kind() === 130 /* FunctionDeclaration */) {
functionDeclaration = moduleElement;
- if (!TypeScript.SyntaxUtilities.containsToken(functionDeclaration.modifiers, 63 /* DeclareKeyword */)) {
+ if (!TypeScript.SyntaxUtilities.containsToken(functionDeclaration.modifiers, 64 /* DeclareKeyword */)) {
inFunctionOverloadChain = functionDeclaration.block === null;
functionOverloadChainName = functionDeclaration.identifier.valueText();
@@ -25484,7 +25553,7 @@ var TypeScript;
};
GrammarCheckerWalker.prototype.checkClassOverloads = function (node) {
- if (!this.inAmbientDeclaration && !TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (!this.inAmbientDeclaration && !TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
var classElementFullStart = this.childFullStart(node, node.classElements);
var inFunctionOverloadChain = false;
@@ -25500,7 +25569,7 @@ var TypeScript;
var isStaticOverload = null;
if (inFunctionOverloadChain) {
- if (classElement.kind() !== 135 /* MemberFunctionDeclaration */) {
+ if (classElement.kind() !== 136 /* MemberFunctionDeclaration */) {
this.pushDiagnostic1(classElementFullStart, classElement.firstToken(), TypeScript.DiagnosticCode.Function_implementation_expected);
return true;
}
@@ -25519,13 +25588,13 @@ var TypeScript;
return true;
}
} else if (inConstructorOverloadChain) {
- if (classElement.kind() !== 137 /* ConstructorDeclaration */) {
+ if (classElement.kind() !== 138 /* ConstructorDeclaration */) {
this.pushDiagnostic1(classElementFullStart, classElement.firstToken(), TypeScript.DiagnosticCode.Constructor_implementation_expected);
return true;
}
}
- if (classElement.kind() === 135 /* MemberFunctionDeclaration */) {
+ if (classElement.kind() === 136 /* MemberFunctionDeclaration */) {
memberFunctionDeclaration = classElement;
inFunctionOverloadChain = memberFunctionDeclaration.block === null;
@@ -25536,7 +25605,7 @@ var TypeScript;
this.pushDiagnostic1(classElementFullStart, classElement.firstToken(), TypeScript.DiagnosticCode.Function_implementation_expected);
return true;
}
- } else if (classElement.kind() === 137 /* ConstructorDeclaration */) {
+ } else if (classElement.kind() === 138 /* ConstructorDeclaration */) {
var constructorDeclaration = classElement;
inConstructorOverloadChain = constructorDeclaration.block === null;
@@ -25560,7 +25629,7 @@ var TypeScript;
var current = name;
while (current !== null) {
- if (current.kind() === 121 /* QualifiedName */) {
+ if (current.kind() === 122 /* QualifiedName */) {
var qualifiedName = current;
token = qualifiedName.right;
tokenFullStart = nameFullStart + this.childFullStart(qualifiedName, token);
@@ -25575,6 +25644,7 @@ var TypeScript;
switch (token.valueText()) {
case "any":
case "number":
+ case "bool":
case "boolean":
case "string":
case "void":
@@ -25593,7 +25663,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitClassDeclaration.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -25631,7 +25701,7 @@ var TypeScript;
for (var i = 0, n = modifiers.childCount(); i < n; i++) {
var modifier = modifiers.childAt(i);
- if (modifier.tokenKind === 63 /* DeclareKeyword */) {
+ if (modifier.tokenKind === 64 /* DeclareKeyword */) {
this.pushDiagnostic1(modifierFullStart, modifier, TypeScript.DiagnosticCode.declare_modifier_cannot_appear_on_an_interface_declaration);
return true;
}
@@ -25805,7 +25875,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitEnumDeclaration.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -25872,7 +25942,7 @@ var TypeScript;
return true;
}
- if (modifier.tokenKind === 63 /* DeclareKeyword */) {
+ if (modifier.tokenKind === 64 /* DeclareKeyword */) {
if (seenDeclareModifier) {
this.pushDiagnostic1(modifierFullStart, modifier, TypeScript.DiagnosticCode.Accessibility_modifier_already_seen);
return;
@@ -25886,7 +25956,7 @@ var TypeScript;
}
if (seenDeclareModifier) {
- this.pushDiagnostic1(modifierFullStart, modifier, TypeScript.DiagnosticCode._0_modifier_must_precede_1_modifier, [TypeScript.SyntaxFacts.getText(47 /* ExportKeyword */), TypeScript.SyntaxFacts.getText(63 /* DeclareKeyword */)]);
+ this.pushDiagnostic1(modifierFullStart, modifier, TypeScript.DiagnosticCode._0_modifier_must_precede_1_modifier, [TypeScript.SyntaxFacts.getText(47 /* ExportKeyword */), TypeScript.SyntaxFacts.getText(64 /* DeclareKeyword */)]);
return;
}
@@ -25905,9 +25975,9 @@ var TypeScript;
for (var i = 0, n = node.moduleElements.childCount(); i < n; i++) {
var child = node.moduleElements.childAt(i);
- if (child.kind() === 133 /* ImportDeclaration */) {
+ if (child.kind() === 134 /* ImportDeclaration */) {
var importDeclaration = child;
- if (importDeclaration.moduleReference.kind() === 245 /* ExternalModuleReference */) {
+ if (importDeclaration.moduleReference.kind() === 246 /* ExternalModuleReference */) {
this.pushDiagnostic1(currentElementFullStart, importDeclaration, TypeScript.DiagnosticCode.Import_declarations_in_an_internal_module_cannot_reference_an_external_module, null);
}
}
@@ -25920,7 +25990,7 @@ var TypeScript;
};
GrammarCheckerWalker.prototype.checkForDisallowedDeclareModifierOnImportDeclaration = function (modifiers) {
- var declareToken = TypeScript.SyntaxUtilities.getToken(modifiers, 63 /* DeclareKeyword */);
+ var declareToken = TypeScript.SyntaxUtilities.getToken(modifiers, 64 /* DeclareKeyword */);
if (declareToken) {
this.pushDiagnostic1(this.childFullStart(modifiers, declareToken), declareToken, TypeScript.DiagnosticCode.declare_modifier_not_allowed_on_import_declaration);
@@ -25943,13 +26013,13 @@ var TypeScript;
return;
}
- if (!TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */) && this.checkFunctionOverloads(node, node.moduleElements)) {
+ if (!TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */) && this.checkFunctionOverloads(node, node.moduleElements)) {
this.skip(node);
return;
}
if (node.stringLiteral) {
- if (!this.inAmbientDeclaration && !TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (!this.inAmbientDeclaration && !TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
var stringLiteralFullStart = this.childFullStart(node, node.stringLiteral);
this.pushDiagnostic1(stringLiteralFullStart, node.stringLiteral, TypeScript.DiagnosticCode.Only_ambient_modules_can_use_quoted_names);
this.skip(node);
@@ -25963,7 +26033,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitModuleDeclaration.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -25984,7 +26054,7 @@ var TypeScript;
for (var i = 0, n = moduleElements.childCount(); i < n; i++) {
var child = moduleElements.childAt(i);
- if (child.kind() === 134 /* ExportAssignment */) {
+ if (child.kind() === 135 /* ExportAssignment */) {
this.pushDiagnostic1(moduleElementFullStart, child, TypeScript.DiagnosticCode.Export_assignment_not_allowed_in_module_with_exported_element);
return true;
}
@@ -26002,7 +26072,7 @@ var TypeScript;
var errorFound = false;
for (var i = 0, n = moduleElements.childCount(); i < n; i++) {
var child = moduleElements.childAt(i);
- if (child.kind() === 134 /* ExportAssignment */) {
+ if (child.kind() === 135 /* ExportAssignment */) {
if (seenExportAssignment) {
this.pushDiagnostic1(moduleElementFullStart, child, TypeScript.DiagnosticCode.Module_cannot_have_multiple_export_assignments);
errorFound = true;
@@ -26022,7 +26092,7 @@ var TypeScript;
for (var i = 0, n = node.moduleElements.childCount(); i < n; i++) {
var child = node.moduleElements.childAt(i);
- if (child.kind() === 134 /* ExportAssignment */) {
+ if (child.kind() === 135 /* ExportAssignment */) {
this.pushDiagnostic1(moduleElementFullStart, child, TypeScript.DiagnosticCode.Export_assignment_cannot_be_used_in_internal_modules);
return true;
@@ -26222,7 +26292,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitFunctionDeclaration.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -26234,7 +26304,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitVariableStatement.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -26255,7 +26325,7 @@ var TypeScript;
};
GrammarCheckerWalker.prototype.visitObjectType = function (node) {
- if (this.checkListSeparators(node, node.typeMembers, 78 /* SemicolonToken */)) {
+ if (this.checkListSeparators(node, node.typeMembers, 79 /* SemicolonToken */)) {
this.skip(node);
return;
}
@@ -26312,6 +26382,16 @@ var TypeScript;
_super.prototype.visitSourceUnit.call(this, node);
};
+
+ GrammarCheckerWalker.prototype.visitExternalModuleReference = function (node) {
+ if (node.moduleOrRequireKeyword.tokenKind === 66 /* ModuleKeyword */ && !this.syntaxTree.parseOptions().allowModuleKeywordInExternalModuleReference()) {
+ this.pushDiagnostic1(this.position(), node.moduleOrRequireKeyword, TypeScript.DiagnosticCode.module_is_deprecated_Use_require_instead);
+ this.skip(node);
+ return;
+ }
+
+ _super.prototype.visitExternalModuleReference.call(this, node);
+ };
return GrammarCheckerWalker;
})(TypeScript.PositionTrackingWalker);
})(TypeScript || (TypeScript = {}));
@@ -30140,6 +30220,15 @@ var TypeScript;
}
TypeScript.filePath = filePath;
+ function convertToDirectoryPath(dirPath) {
+ if (dirPath && dirPath.charAt(dirPath.length - 1) !== "/") {
+ dirPath += "/";
+ }
+
+ return dirPath;
+ }
+ TypeScript.convertToDirectoryPath = convertToDirectoryPath;
+
var normalizePathRegEx = /^\\\\[^\\]/;
function normalizePath(path) {
if (normalizePathRegEx.test(path)) {
@@ -30174,7 +30263,9 @@ var TypeScript;
this.removeComments = false;
this.watch = false;
this.noResolve = false;
+ this.allowBool = false;
this.allowAutomaticSemicolonInsertion = true;
+ this.allowModuleKeywordInExternalModuleReference = false;
this.noImplicitAny = false;
this.noLib = false;
this.codeGenTarget = 0 /* EcmaScript3 */;
@@ -30188,6 +30279,7 @@ var TypeScript;
this.useCaseSensitiveFileResolution = false;
this.gatherDiagnostics = false;
this.updateTC = false;
+ this.codepage = null;
}
return CompilationSettings;
})();
@@ -30251,13 +30343,13 @@ var TypeScript;
if (TypeScript.SyntaxFacts.isIdentifierNameOrAnyKeyword(token)) {
token = scanner.scan(scannerDiagnostics, false);
- if (token.tokenKind === 107 /* EqualsToken */) {
+ if (token.tokenKind === 108 /* EqualsToken */) {
token = scanner.scan(scannerDiagnostics, false);
- if (token.tokenKind === 65 /* ModuleKeyword */ || token.tokenKind === 66 /* RequireKeyword */) {
+ if (token.tokenKind === 66 /* ModuleKeyword */ || token.tokenKind === 67 /* RequireKeyword */) {
token = scanner.scan(scannerDiagnostics, false);
- if (token.tokenKind === 72 /* OpenParenToken */) {
+ if (token.tokenKind === 73 /* OpenParenToken */) {
var afterOpenParenPosition = scanner.absoluteIndex();
token = scanner.scan(scannerDiagnostics, false);
@@ -30347,7 +30439,7 @@ var TypeScript;
TypeScript.preProcessFile = preProcessFile;
function getParseOptions(settings) {
- return new TypeScript.ParseOptions(settings.codeGenTarget, settings.allowAutomaticSemicolonInsertion);
+ return new TypeScript.ParseOptions(settings.codeGenTarget, settings.allowAutomaticSemicolonInsertion, settings.allowModuleKeywordInExternalModuleReference);
}
TypeScript.getParseOptions = getParseOptions;
})(TypeScript || (TypeScript = {}));
@@ -31409,6 +31501,16 @@ var TypeScript;
return false;
};
+ DeclarationEmitter.prototype.resolveScriptReference = function (document, reference) {
+ if (!this.compiler.settings.noResolve || TypeScript.isRooted(reference)) {
+ return reference;
+ }
+
+ var documentDir = TypeScript.convertToDirectoryPath(TypeScript.switchToForwardSlashes(TypeScript.getRootFilePath(document.fileName)));
+ var resolvedReferencePath = this.compiler.emitOptions.ioHost.resolvePath(documentDir + reference);
+ return resolvedReferencePath;
+ };
+
DeclarationEmitter.prototype.emitReferencePaths = function (script) {
if (this.emittedReferencePaths) {
return;
@@ -31419,10 +31521,10 @@ var TypeScript;
var scriptReferences = script.referencedFiles;
var addedGlobalDocument = false;
for (var j = 0; j < scriptReferences.length; j++) {
- var currentReference = scriptReferences[j];
+ var currentReference = this.resolveScriptReference(this.document, scriptReferences[j]);
var document = this.compiler.getDocument(currentReference);
- if (this.compiler.emitOptions.outputMany || document.script.isDeclareFile || document.script.topLevelMod || !addedGlobalDocument) {
+ if (document && (this.compiler.emitOptions.outputMany || document.script.isDeclareFile || document.script.topLevelMod || !addedGlobalDocument)) {
documents = documents.concat(document);
if (!document.script.isDeclareFile && document.script.topLevelMod) {
addedGlobalDocument = true;
@@ -31435,10 +31537,10 @@ var TypeScript;
if (!allDocuments[i].script.isDeclareFile && !allDocuments[i].script.topLevelMod) {
var scriptReferences = allDocuments[i].script.referencedFiles;
for (var j = 0; j < scriptReferences.length; j++) {
- var currentReference = scriptReferences[j];
+ var currentReference = this.resolveScriptReference(allDocuments[i], scriptReferences[j]);
var document = this.compiler.getDocument(currentReference);
- if (document.script.isDeclareFile || document.script.topLevelMod) {
+ if (document && (document.script.isDeclareFile || document.script.topLevelMod)) {
for (var k = 0; k < documents.length; k++) {
if (documents[k] == document) {
break;
@@ -32568,6 +32670,10 @@ var TypeScript;
return true;
}
+ if (this.rootSymbol) {
+ return PullSymbol.getIsExternallyVisible(this.rootSymbol, this, inIsExternallyVisibleSymbols);
+ }
+
if (this.isType()) {
var associatedContainerSymbol = (this).getAssociatedContainerType();
if (associatedContainerSymbol) {
@@ -32581,6 +32687,19 @@ var TypeScript;
var container = this.getContainer();
if (container === null) {
+ var decls = this.getDeclarations();
+ if (decls.length) {
+ var parentDecl = decls[0].getParentDecl();
+ if (parentDecl) {
+ var parentSymbol = parentDecl.getSymbol();
+ if (!parentSymbol || parentDecl.kind == 1 /* Script */) {
+ return true;
+ }
+
+ return PullSymbol.getIsExternallyVisible(parentSymbol, this, inIsExternallyVisibleSymbols);
+ }
+ }
+
return true;
}
@@ -34707,7 +34826,7 @@ var TypeScript;
newSignature.mimicSignature(signature, resolver);
declAST = resolver.semanticInfoChain.getASTForDecl(decl);
- TypeScript.Debug.assert(declAST != null, "Call signature for type '" + typeToSpecialize.toString() + "' could not be specialized because of a stale declaration");
+ TypeScript.Debug.assert(declAST != null, "Call signature for type '" + typeToSpecialize.pullSymbolIDString + "' could not be specialized because of a stale declaration");
prevSpecializationSignature = decl.getSpecializingSignatureSymbol();
decl.setSpecializingSignatureSymbol(newSignature);
@@ -34779,7 +34898,7 @@ var TypeScript;
newSignature.mimicSignature(signature, resolver);
declAST = resolver.semanticInfoChain.getASTForDecl(decl);
- TypeScript.Debug.assert(declAST != null, "Construct signature for type '" + typeToSpecialize.toString() + "' could not be specialized because of a stale declaration");
+ TypeScript.Debug.assert(declAST != null, "Construct signature for type '" + typeToSpecialize.pullSymbolIDString + "' could not be specialized because of a stale declaration");
prevSpecializationSignature = decl.getSpecializingSignatureSymbol();
decl.setSpecializingSignatureSymbol(newSignature);
@@ -34851,7 +34970,7 @@ var TypeScript;
newSignature.mimicSignature(signature, resolver);
declAST = resolver.semanticInfoChain.getASTForDecl(decl);
- TypeScript.Debug.assert(declAST != null, "Index signature for type '" + typeToSpecialize.toString() + "' could not be specialized because of a stale declaration");
+ TypeScript.Debug.assert(declAST != null, "Index signature for type '" + typeToSpecialize.pullSymbolIDString + "' could not be specialized because of a stale declaration");
prevSpecializationSignature = decl.getSpecializingSignatureSymbol();
decl.setSpecializingSignatureSymbol(newSignature);
@@ -35118,9 +35237,22 @@ var TypeScript;
function getIDForTypeSubstitutions(types) {
var substitution = "";
+ var members = null;
for (var i = 0; i < types.length; i++) {
- substitution += types[i].pullSymbolIDString + "#";
+ if (types[i].kind != 8388608 /* ObjectType */) {
+ substitution += types[i].pullSymbolIDString + "#";
+ } else {
+ members = types[i].getMembers();
+
+ if (types[i].isResolved && members && members.length) {
+ for (var j = 0; j < members.length; j++) {
+ substitution += members[j].name + "@" + getIDForTypeSubstitutions([members[j].type]);
+ }
+ } else {
+ substitution += types[i].pullSymbolIDString + "#";
+ }
+ }
}
return substitution;
@@ -35338,6 +35470,7 @@ var TypeScript;
this.genericASTResolutionStack = [];
this.resolvingTypeReference = false;
this.resolvingNamespaceMemberAccess = false;
+ this.resolvingTypeQueryExpression = false;
this.resolveAggressively = false;
this.canUseTypeSymbol = false;
this.specializingToAny = false;
@@ -35722,7 +35855,7 @@ var TypeScript;
this._cachedRegExpInterfaceType = this.getSymbolFromDeclPath("RegExp", [], 16 /* Interface */);
}
- if (!this._cachedRegExpInterfaceType.isResolved) {
+ if (this._cachedRegExpInterfaceType && !this._cachedRegExpInterfaceType.isResolved) {
this.resolveDeclaredSymbol(this._cachedRegExpInterfaceType, null, new TypeScript.PullTypeResolutionContext());
}
@@ -36483,11 +36616,7 @@ var TypeScript;
this.validateVariableDeclarationGroups(containerDecl, context);
}
- if (!context.isInBaseTypeResolution()) {
- containerSymbol.setResolved();
- } else {
- containerSymbol.inResolution = false;
- }
+ containerSymbol.setResolved();
return containerSymbol;
};
@@ -36511,6 +36640,7 @@ var TypeScript;
};
PullTypeResolver.prototype.resolveReferenceTypeDeclaration = function (typeDeclAST, context) {
+ var _this = this;
var typeDecl = this.getDeclForAST(typeDeclAST);
var enclosingDecl = this.getEnclosingDecl(typeDecl);
var typeDeclSymbol = typeDecl.getSymbol();
@@ -36608,6 +36738,11 @@ var TypeScript;
if (wasInBaseTypeResolution) {
typeDeclSymbol.inResolution = false;
+
+ PullTypeResolver.typeCheckCallBacks.push(function () {
+ _this.resolveDeclaredSymbol(typeDeclSymbol, enclosingDecl, context);
+ });
+
return typeDeclSymbol;
}
@@ -37161,6 +37296,11 @@ var TypeScript;
if (funcDeclAST.returnTypeAnnotation) {
var returnTypeSymbol = this.resolveTypeReference(funcDeclAST.returnTypeAnnotation, functionDecl, context);
+ if (this.genericTypeIsUsedWithoutRequiredTypeArguments(returnTypeSymbol, funcDeclAST.returnTypeAnnotation, context)) {
+ context.postError(this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Generic_type_references_must_include_all_type_arguments, null, functionDecl);
+ returnTypeSymbol = this.specializeTypeToAny(returnTypeSymbol, functionDecl, context);
+ }
+
signature.returnType = returnTypeSymbol;
if (this.isTypeArgumentOrWrapper(returnTypeSymbol)) {
@@ -37414,7 +37554,10 @@ var TypeScript;
var savedResolvingTypeReference = context.resolvingTypeReference;
context.resolvingTypeReference = false;
+ var savedResolvingTypeQueryExpression = context.resolvingTypeQueryExpression;
+ context.resolvingTypeQueryExpression = true;
var valueSymbol = this.resolveAST(typeQueryTerm, false, enclosingDecl, context);
+ context.resolvingTypeQueryExpression = savedResolvingTypeQueryExpression;
context.resolvingTypeReference = savedResolvingTypeReference;
if (valueSymbol && valueSymbol.isAlias()) {
@@ -37653,13 +37796,25 @@ var TypeScript;
if (!(varDecl.typeExpr || varDecl.init)) {
var defaultType = this.semanticInfoChain.anyTypeSymbol;
- if (this.compilationSettings.noImplicitAny && ((varDecl.getVarFlags() & 16384 /* ForInVariable */) === 0)) {
- if (wrapperDecl.kind == 16384 /* Function */ || wrapperDecl.kind == 65536 /* Method */ || wrapperDecl.kind == 32768 /* ConstructorMethod */ || wrapperDecl.kind == 2097152 /* ConstructSignature */) {
+ if (this.compilationSettings.noImplicitAny && !TypeScript.hasFlag(varDecl.getVarFlags(), 16384 /* ForInVariable */)) {
+ if ((wrapperDecl.kind === 16384 /* Function */ || wrapperDecl.kind === 32768 /* ConstructorMethod */ || wrapperDecl.kind === 2097152 /* ConstructSignature */)) {
context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Parameter_0_of_1_implicitly_has_an_any_type, [varDecl.id.actualText, enclosingDecl.name], enclosingDecl);
- } else if (wrapperDecl.kind == 8388608 /* ObjectType */) {
+ } else if (wrapperDecl.kind === 65536 /* Method */) {
+ var parentDecl = wrapperDecl.getParentDecl();
+
+ if (!TypeScript.hasFlag(parentDecl.flags, 8 /* Ambient */)) {
+ context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Parameter_0_of_1_implicitly_has_an_any_type, [varDecl.id.actualText, enclosingDecl.name], enclosingDecl);
+ } else if (TypeScript.hasFlag(parentDecl.flags, 8 /* Ambient */) && !TypeScript.hasFlag(wrapperDecl.flags, 2 /* Private */)) {
+ context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Parameter_0_of_1_implicitly_has_an_any_type, [varDecl.id.actualText, enclosingDecl.name], enclosingDecl);
+ }
+ } else if (wrapperDecl.kind === 8388608 /* ObjectType */) {
context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Member_0_of_object_type_implicitly_has_an_any_type, [varDecl.id.actualText], enclosingDecl);
- } else if (wrapperDecl.kind != 1073741824 /* CatchBlock */) {
- context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Variable_0_implicitly_has_an_any_type, [varDecl.id.actualText], enclosingDecl);
+ } else if (wrapperDecl.kind !== 1073741824 /* CatchBlock */) {
+ if (!TypeScript.hasFlag(wrapperDecl.flags, 8 /* Ambient */)) {
+ context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Variable_0_implicitly_has_an_any_type, [varDecl.id.actualText], enclosingDecl);
+ } else if (TypeScript.hasFlag(wrapperDecl.flags, 8 /* Ambient */) && !TypeScript.hasFlag(varDecl.getVarFlags(), 2 /* Private */)) {
+ context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Variable_0_implicitly_has_an_any_type, [varDecl.id.actualText], enclosingDecl);
+ }
}
}
@@ -37889,6 +38044,10 @@ var TypeScript;
}
}
+ if (!functionSymbol.type && functionSymbol.isAccessor()) {
+ functionSymbol.type = signature.returnType;
+ }
+
if (this.isTypeArgumentOrWrapper(returnType) && functionSymbol) {
functionSymbol.type.setHasGenericSignature();
}
@@ -37896,8 +38055,121 @@ var TypeScript;
}
};
- PullTypeResolver.prototype.resolveFunctionDeclaration = function (funcDeclAST, context) {
+ PullTypeResolver.prototype.typeCheckFunctionDeclaration = function (funcDeclAST, funcDecl, signature, context) {
var _this = this;
+ if (context.inTypeCheck && (!context.inSpecialization || !signature.isGeneric())) {
+ PullTypeResolver.typeCheckCallBacks.push(function () {
+ if (signature.hasBeenChecked || signature.getRootSymbol() != signature) {
+ return;
+ }
+
+ var currentUnitPath = _this.unitPath;
+ _this.setUnitPath(funcDecl.getScriptName());
+ var prevSeenSuperConstructorCall = _this.seenSuperConstructorCall;
+ _this.seenSuperConstructorCall = false;
+
+ _this.resolveAST(funcDeclAST.block, false, funcDecl, context);
+
+ _this.validateVariableDeclarationGroups(funcDecl, context);
+
+ var enclosingDecl = _this.getEnclosingDecl(funcDecl);
+
+ var hasReturn = (funcDecl.flags & (2048 /* Signature */ | 4194304 /* HasReturnStatement */)) != 0;
+
+ var parameters = signature.parameters;
+
+ if (funcDeclAST.isConstructor || TypeScript.hasFlag(funcDeclAST.getFunctionFlags(), 1024 /* ConstructMember */)) {
+ if (funcDecl.getSignatureSymbol() && funcDecl.getSignatureSymbol().isDefinition() && _this.enclosingClassIsDerived(funcDecl)) {
+ if (!_this.seenSuperConstructorCall) {
+ context.postError(_this.unitPath, funcDeclAST.minChar, 11, TypeScript.DiagnosticCode.Constructors_for_derived_classes_must_contain_a_super_call, null, enclosingDecl);
+ } else if (_this.superCallMustBeFirstStatementInConstructor(funcDecl, enclosingDecl)) {
+ var firstStatement = _this.getFirstStatementFromFunctionDeclAST(funcDeclAST);
+ if (!firstStatement || !_this.isSuperCallNode(firstStatement)) {
+ context.postError(_this.unitPath, funcDeclAST.minChar, 11, TypeScript.DiagnosticCode.A_super_call_must_be_the_first_statement_in_the_constructor_when_a_class_contains_initialized_properties_or_has_parameter_properties, null, enclosingDecl);
+ }
+ }
+ }
+ _this.typeCheckFunctionOverloads(funcDeclAST, context);
+ } else if (TypeScript.hasFlag(funcDeclAST.getFunctionFlags(), 4096 /* IndexerMember */)) {
+ var allIndexSignatures = enclosingDecl.getSymbol().type.getIndexSignatures();
+
+ for (var i = 0; i < allIndexSignatures.length; i++) {
+ if (!allIndexSignatures[i].isResolved) {
+ _this.resolveDeclaredSymbol(allIndexSignatures[i], allIndexSignatures[i].getDeclarations()[0].getParentDecl(), context);
+ }
+
+ if (allIndexSignatures[i].parameters[0].type !== parameters[0].type) {
+ var stringIndexSignature = null;
+ var numberIndexSignature = null;
+
+ var indexSignature = signature;
+
+ var isNumericIndexer = parameters[0].type === _this.semanticInfoChain.numberTypeSymbol;
+
+ if (isNumericIndexer) {
+ numberIndexSignature = indexSignature;
+ stringIndexSignature = allIndexSignatures[i];
+ } else {
+ numberIndexSignature = allIndexSignatures[i];
+ stringIndexSignature = indexSignature;
+
+ if (enclosingDecl.getSymbol() === numberIndexSignature.getDeclarations()[0].getParentDecl().getSymbol()) {
+ break;
+ }
+ }
+ var comparisonInfo = new TypeComparisonInfo();
+ var resolutionContext = new TypeScript.PullTypeResolutionContext();
+ if (!_this.sourceIsSubtypeOfTarget(numberIndexSignature.returnType, stringIndexSignature.returnType, resolutionContext, comparisonInfo)) {
+ if (comparisonInfo.message) {
+ context.postError(_this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode.Numeric_indexer_type_0_must_be_a_subtype_of_string_indexer_type_1_NL_2, [numberIndexSignature.returnType.toString(), stringIndexSignature.returnType.toString(), comparisonInfo.message], enclosingDecl);
+ } else {
+ context.postError(_this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode.Numeric_indexer_type_0_must_be_a_subtype_of_string_indexer_type_1, [numberIndexSignature.returnType.toString(), stringIndexSignature.returnType.toString()], enclosingDecl);
+ }
+ }
+ break;
+ }
+ }
+
+ var allMembers = enclosingDecl.getSymbol().type.getAllMembers(TypeScript.PullElementKind.All, true);
+ for (var i = 0; i < allMembers.length; i++) {
+ var name = allMembers[i].name;
+ if (name) {
+ if (!allMembers[i].isResolved) {
+ _this.resolveDeclaredSymbol(allMembers[i], allMembers[i].getDeclarations()[0].getParentDecl(), context);
+ }
+
+ if (enclosingDecl.getSymbol() !== allMembers[i].getContainer()) {
+ var isMemberNumeric = isFinite(+name);
+ if (isNumericIndexer === isMemberNumeric) {
+ _this.checkThatMemberIsSubtypeOfIndexer(allMembers[i], indexSignature, funcDeclAST, context, enclosingDecl, isNumericIndexer);
+ }
+ }
+ }
+ }
+ } else {
+ if (funcDeclAST.block && funcDeclAST.returnTypeAnnotation != null && !hasReturn) {
+ var isVoidOrAny = _this.isAnyOrEquivalent(signature.returnType) || signature.returnType === _this.semanticInfoChain.voidTypeSymbol;
+
+ if (!isVoidOrAny && !(funcDeclAST.block.statements.members.length > 0 && funcDeclAST.block.statements.members[0].nodeType() === 96 /* ThrowStatement */)) {
+ var funcName = funcDecl.getDisplayName();
+ funcName = funcName ? funcName : "expression";
+
+ context.postError(_this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Function_0_declared_a_non_void_return_type_but_has_no_return_expression, [funcName], enclosingDecl);
+ }
+ }
+ _this.typeCheckFunctionOverloads(funcDeclAST, context);
+ }
+
+ _this.checkFunctionTypePrivacy(funcDeclAST, false, context);
+ _this.seenSuperConstructorCall = prevSeenSuperConstructorCall;
+
+ signature.hasBeenChecked = true;
+ _this.setUnitPath(currentUnitPath);
+ });
+ }
+ };
+
+ PullTypeResolver.prototype.resolveFunctionDeclaration = function (funcDeclAST, context) {
var funcDecl = this.getDeclForAST(funcDeclAST);
var funcSymbol = funcDecl.getSymbol();
@@ -37910,6 +38182,7 @@ var TypeScript;
if (signature) {
if (signature.isResolved) {
+ this.typeCheckFunctionDeclaration(funcDeclAST, funcDecl, signature, context);
return funcSymbol;
}
@@ -38009,6 +38282,11 @@ var TypeScript;
}
}
+ if (this.genericTypeIsUsedWithoutRequiredTypeArguments(returnTypeSymbol, funcDeclAST.returnTypeAnnotation, context)) {
+ context.postError(this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Generic_type_references_must_include_all_type_arguments, null, funcDecl);
+ returnTypeSymbol = this.specializeTypeToAny(returnTypeSymbol, funcDecl, context);
+ }
+
signature.returnType = returnTypeSymbol;
if (isConstructor && returnTypeSymbol === this.semanticInfoChain.voidTypeSymbol) {
@@ -38018,8 +38296,13 @@ var TypeScript;
} else if (!funcDeclAST.isConstructor && !funcDeclAST.isConstructMember()) {
if (funcDeclAST.isSignature()) {
signature.returnType = this.semanticInfoChain.anyTypeSymbol;
+ var parentDeclFlags = 0 /* None */;
+ if (TypeScript.hasFlag(funcDecl.kind, 65536 /* Method */) || TypeScript.hasFlag(funcDecl.kind, 32768 /* ConstructorMethod */)) {
+ var parentDecl = funcDecl.getParentDecl();
+ parentDeclFlags = parentDecl.flags;
+ }
- if (this.compilationSettings.noImplicitAny) {
+ if (this.compilationSettings.noImplicitAny && (!TypeScript.hasFlag(parentDeclFlags, 8 /* Ambient */) || (TypeScript.hasFlag(parentDeclFlags, 8 /* Ambient */) && !TypeScript.hasFlag(funcDecl.flags, 2 /* Private */)))) {
var funcDeclASTName = funcDeclAST.name;
if (funcDeclASTName) {
context.postError(this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode._0_which_lacks_return_type_annotation_implicitly_has_an_any_return_type, [funcDeclASTName.actualText], funcDecl);
@@ -38051,116 +38334,7 @@ var TypeScript;
}
}
- if (context.inTypeCheck && (!context.inSpecialization || !signature.isGeneric())) {
- var prevSeenSuperConstructorCall = this.seenSuperConstructorCall;
-
- PullTypeResolver.typeCheckCallBacks.push(function () {
- if (signature.hasBeenChecked) {
- return;
- }
-
- _this.setUnitPath(funcDecl.getScriptName());
- _this.seenSuperConstructorCall = false;
-
- _this.resolveAST(funcDeclAST.block, false, funcDecl, context);
-
- _this.validateVariableDeclarationGroups(funcDecl, context);
-
- var enclosingDecl = _this.getEnclosingDecl(funcDecl);
-
- var hasReturn = (funcDecl.flags & (2048 /* Signature */ | 4194304 /* HasReturnStatement */)) != 0;
-
- var parameters = signature.parameters;
-
- if (funcDeclAST.isConstructor || TypeScript.hasFlag(funcDeclAST.getFunctionFlags(), 1024 /* ConstructMember */)) {
- if (funcDecl.getSignatureSymbol() && funcDecl.getSignatureSymbol().isDefinition() && _this.enclosingClassIsDerived(funcDecl)) {
- if (!_this.seenSuperConstructorCall) {
- context.postError(_this.unitPath, funcDeclAST.minChar, 11, TypeScript.DiagnosticCode.Constructors_for_derived_classes_must_contain_a_super_call, null, enclosingDecl);
- } else if (_this.superCallMustBeFirstStatementInConstructor(funcDecl, enclosingDecl)) {
- var firstStatement = _this.getFirstStatementFromFunctionDeclAST(funcDeclAST);
- if (!firstStatement || !_this.isSuperCallNode(firstStatement)) {
- context.postError(_this.unitPath, funcDeclAST.minChar, 11, TypeScript.DiagnosticCode.A_super_call_must_be_the_first_statement_in_the_constructor_when_a_class_contains_initialized_properties_or_has_parameter_properties, null, enclosingDecl);
- }
- }
- }
- _this.typeCheckFunctionOverloads(funcDeclAST, context);
- } else if (TypeScript.hasFlag(funcDeclAST.getFunctionFlags(), 4096 /* IndexerMember */)) {
- var allIndexSignatures = enclosingDecl.getSymbol().type.getIndexSignatures();
-
- for (var i = 0; i < allIndexSignatures.length; i++) {
- if (!allIndexSignatures[i].isResolved) {
- _this.resolveDeclaredSymbol(allIndexSignatures[i], allIndexSignatures[i].getDeclarations()[0].getParentDecl(), context);
- }
-
- if (allIndexSignatures[i].parameters[0].type !== parameters[0].type) {
- var stringIndexSignature = null;
- var numberIndexSignature = null;
-
- var indexSignature = signature;
-
- var isNumericIndexer = parameters[0].type === _this.semanticInfoChain.numberTypeSymbol;
-
- if (isNumericIndexer) {
- numberIndexSignature = indexSignature;
- stringIndexSignature = allIndexSignatures[i];
- } else {
- numberIndexSignature = allIndexSignatures[i];
- stringIndexSignature = indexSignature;
-
- if (enclosingDecl.getSymbol() === numberIndexSignature.getDeclarations()[0].getParentDecl().getSymbol()) {
- break;
- }
- }
- var comparisonInfo = new TypeComparisonInfo();
- var resolutionContext = new TypeScript.PullTypeResolutionContext();
- if (!_this.sourceIsSubtypeOfTarget(numberIndexSignature.returnType, stringIndexSignature.returnType, resolutionContext, comparisonInfo)) {
- if (comparisonInfo.message) {
- context.postError(_this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode.Numeric_indexer_type_0_must_be_a_subtype_of_string_indexer_type_1_NL_2, [numberIndexSignature.returnType.toString(), stringIndexSignature.returnType.toString(), comparisonInfo.message], enclosingDecl);
- } else {
- context.postError(_this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode.Numeric_indexer_type_0_must_be_a_subtype_of_string_indexer_type_1, [numberIndexSignature.returnType.toString(), stringIndexSignature.returnType.toString()], enclosingDecl);
- }
- }
- break;
- }
- }
-
- var allMembers = enclosingDecl.getSymbol().type.getAllMembers(TypeScript.PullElementKind.All, true);
- for (var i = 0; i < allMembers.length; i++) {
- var name = allMembers[i].name;
- if (name) {
- if (!allMembers[i].isResolved) {
- _this.resolveDeclaredSymbol(allMembers[i], allMembers[i].getDeclarations()[0].getParentDecl(), context);
- }
-
- if (enclosingDecl.getSymbol() !== allMembers[i].getContainer()) {
- var isMemberNumeric = isFinite(+name);
- if (isNumericIndexer === isMemberNumeric) {
- _this.checkThatMemberIsSubtypeOfIndexer(allMembers[i], indexSignature, funcDeclAST, context, enclosingDecl, isNumericIndexer);
- }
- }
- }
- }
- } else {
- if (funcDeclAST.block && funcDeclAST.returnTypeAnnotation != null && !hasReturn) {
- var isVoidOrAny = _this.isAnyOrEquivalent(returnTypeSymbol) || returnTypeSymbol === _this.semanticInfoChain.voidTypeSymbol;
-
- if (!isVoidOrAny && !(funcDeclAST.block.statements.members.length > 0 && funcDeclAST.block.statements.members[0].nodeType() === 96 /* ThrowStatement */)) {
- var funcName = funcDecl.getDisplayName();
- funcName = funcName ? funcName : "expression";
-
- context.postError(_this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Function_0_declared_a_non_void_return_type_but_has_no_return_expression, [funcName], enclosingDecl);
- }
- }
- _this.typeCheckFunctionOverloads(funcDeclAST, context);
- }
-
- _this.checkFunctionTypePrivacy(funcDeclAST, false, context);
- _this.seenSuperConstructorCall = prevSeenSuperConstructorCall;
-
- signature.hasBeenChecked = true;
- });
- }
-
+ this.typeCheckFunctionDeclaration(funcDeclAST, funcDecl, signature, context);
return funcSymbol;
};
@@ -38178,6 +38352,9 @@ var TypeScript;
if (signature) {
if (signature.isResolved) {
+ if (!accessorSymbol.type) {
+ accessorSymbol.type = signature.returnType;
+ }
return accessorSymbol;
}
@@ -38185,6 +38362,10 @@ var TypeScript;
signature.returnType = this.semanticInfoChain.anyTypeSymbol;
signature.setResolved();
+ if (!accessorSymbol.type) {
+ accessorSymbol.type = signature.returnType;
+ }
+
return accessorSymbol;
}
@@ -38219,6 +38400,11 @@ var TypeScript;
}
}
+ if (this.genericTypeIsUsedWithoutRequiredTypeArguments(returnTypeSymbol, funcDeclAST.returnTypeAnnotation, context)) {
+ context.postError(this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Generic_type_references_must_include_all_type_arguments, null, funcDecl);
+ returnTypeSymbol = this.specializeTypeToAny(returnTypeSymbol, funcDecl, context);
+ }
+
signature.returnType = returnTypeSymbol;
}
} else {
@@ -39277,7 +39463,7 @@ var TypeScript;
this.resolveDeclaredSymbol(nameSymbol, enclosingDecl, context);
}
- if (nameSymbol && (nameSymbol.type != this.semanticInfoChain.anyTypeSymbol || nameSymbol.hasFlag(16777216 /* IsAnnotatedWithAny */))) {
+ if (nameSymbol && (nameSymbol.type != this.semanticInfoChain.anyTypeSymbol || nameSymbol.hasFlag(16777216 /* IsAnnotatedWithAny */ | 1 /* Exported */))) {
this.setSymbolForAST(nameAST, nameSymbol, context);
}
@@ -39327,7 +39513,9 @@ var TypeScript;
if (nameSymbol.isType() && nameSymbol.isAlias()) {
aliasSymbol = nameSymbol;
- aliasSymbol.isUsedAsValue = true;
+ if (!context.resolvingTypeQueryExpression) {
+ aliasSymbol.isUsedAsValue = true;
+ }
if (!nameSymbol.isResolved) {
this.resolveDeclaredSymbol(nameSymbol, enclosingDecl, context);
@@ -39414,7 +39602,9 @@ var TypeScript;
var lhsType = lhs.type;
if (lhs.isAlias()) {
- (lhs).isUsedAsValue = true;
+ if (!context.resolvingTypeQueryExpression) {
+ (lhs).isUsedAsValue = true;
+ }
lhsType = (lhs).getExportAssignedTypeSymbol();
}
@@ -39571,6 +39761,14 @@ var TypeScript;
return this.semanticInfoChain.stringTypeSymbol;
} else if (id === "number") {
return this.semanticInfoChain.numberTypeSymbol;
+ } else if (id === "bool") {
+ if (!this.compilationSettings.allowBool && !this.currentUnit.getProperties().unitContainsBool) {
+ this.currentUnit.getProperties().unitContainsBool = true;
+ context.postError(this.unitPath, nameAST.minChar, nameAST.getLength(), TypeScript.DiagnosticCode.Use_of_deprecated_type_bool_Use_boolean_instead, null, enclosingDecl);
+ return this.semanticInfoChain.booleanTypeSymbol;
+ } else {
+ return this.semanticInfoChain.booleanTypeSymbol;
+ }
} else if (id === "boolean") {
return this.semanticInfoChain.booleanTypeSymbol;
} else if (id === "void") {
@@ -39667,6 +39865,10 @@ var TypeScript;
} else {
typeArgs[i] = typeArg;
}
+
+ if (typeArgs[i].isError()) {
+ typeArgs[i] = this.semanticInfoChain.anyTypeSymbol;
+ }
}
}
context.isResolvingClassExtendedType = savedIsResolvingClassExtendedType;
@@ -39905,6 +40107,11 @@ var TypeScript;
if (funcDeclAST.returnTypeAnnotation) {
var returnTypeSymbol = this.resolveTypeReference(funcDeclAST.returnTypeAnnotation, functionDecl, context);
+ if (this.genericTypeIsUsedWithoutRequiredTypeArguments(returnTypeSymbol, funcDeclAST.returnTypeAnnotation, context)) {
+ context.postError(this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Generic_type_references_must_include_all_type_arguments, null, functionDecl);
+ returnTypeSymbol = this.specializeTypeToAny(returnTypeSymbol, functionDecl, context);
+ }
+
signature.returnType = returnTypeSymbol;
} else {
if (assigningFunctionSignature) {
@@ -39938,6 +40145,7 @@ var TypeScript;
if (context.typeCheck()) {
PullTypeResolver.typeCheckCallBacks.push(function () {
+ var currentUnitPath = _this.unitPath;
_this.setUnitPath(functionDecl.getScriptName());
_this.seenSuperConstructorCall = false;
@@ -39959,6 +40167,7 @@ var TypeScript;
}
_this.typeCheckFunctionOverloads(funcDeclAST, context);
+ _this.setUnitPath(currentUnitPath);
});
}
@@ -40415,6 +40624,7 @@ var TypeScript;
PullTypeResolver.prototype.computeIndexExpressionSymbol = function (callEx, inContextuallyTypedAssignment, enclosingDecl, context) {
var targetSymbol = this.resolveAST(callEx.operand1, inContextuallyTypedAssignment, enclosingDecl, context);
+ var indexType = this.resolveAST(callEx.operand2, inContextuallyTypedAssignment, enclosingDecl, context).type;
var targetTypeSymbol = targetSymbol.type;
@@ -40424,8 +40634,6 @@ var TypeScript;
var elementType = targetTypeSymbol.getElementType();
- var indexType = this.resolveAST(callEx.operand2, inContextuallyTypedAssignment, enclosingDecl, context).type;
-
var isNumberIndex = indexType === this.semanticInfoChain.numberTypeSymbol || TypeScript.PullHelpers.symbolIsEnum(indexType);
if (elementType && isNumberIndex) {
@@ -40438,6 +40646,10 @@ var TypeScript;
var member = this.getMemberSymbol(memberName, TypeScript.PullElementKind.SomeValue, targetTypeSymbol);
if (member) {
+ if (!member.isResolved) {
+ this.resolveDeclaredSymbol(member, enclosingDecl, context);
+ }
+
return member.type;
}
}
@@ -40462,10 +40674,10 @@ var TypeScript;
if (paramSymbols.length) {
paramType = paramSymbols[0].type;
- if (paramType === this.semanticInfoChain.stringTypeSymbol) {
+ if (!stringSignature && paramType === this.semanticInfoChain.stringTypeSymbol) {
stringSignature = signatures[i];
continue;
- } else if (paramType === this.semanticInfoChain.numberTypeSymbol || paramType.kind === 64 /* Enum */) {
+ } else if (!numberSignature && (paramType === this.semanticInfoChain.numberTypeSymbol || paramType.kind === 64 /* Enum */)) {
numberSignature = signatures[i];
continue;
}
@@ -40703,7 +40915,6 @@ var TypeScript;
PullTypeResolver.prototype.computeInvocationExpressionSymbol = function (callEx, inContextuallyTypedAssignment, enclosingDecl, context, additionalResults) {
var targetSymbol = this.resolveAST(callEx.target, inContextuallyTypedAssignment, enclosingDecl, context);
-
var targetAST = this.getLastIdentifierInTarget(callEx);
var targetTypeSymbol = targetSymbol.type;
@@ -40729,6 +40940,7 @@ var TypeScript;
targetTypeSymbol = targetSymbol.type;
} else {
context.postError(this.unitPath, targetAST.minChar, targetAST.getLength(), TypeScript.DiagnosticCode.Calls_to_super_are_only_valid_inside_a_class, null, enclosingDecl);
+ this.resolveAST(callEx.arguments, inContextuallyTypedAssignment, enclosingDecl, context);
return this.getNewErrorTypeSymbol(null);
}
@@ -40879,6 +41091,15 @@ var TypeScript;
additionalResults.actualParametersContextTypeSymbols = actualParametersContextTypeSymbols;
}
+ var prevIsResolvingSuperConstructorTarget = context.isResolvingSuperConstructorTarget;
+ if (isSuperCall) {
+ context.isResolvingSuperConstructorTarget = true;
+ }
+ this.resolveAST(callEx.arguments, inContextuallyTypedAssignment, enclosingDecl, context);
+ if (isSuperCall) {
+ context.isResolvingSuperConstructorTarget = prevIsResolvingSuperConstructorTarget;
+ }
+
if (!couldNotFindGenericOverload) {
if (this.cachedFunctionInterfaceType() && this.sourceIsSubtypeOfTarget(targetTypeSymbol, this.cachedFunctionInterfaceType(), context)) {
return this.semanticInfoChain.anyTypeSymbol;
@@ -41323,8 +41544,11 @@ var TypeScript;
}
return returnType;
- } else if (targetTypeSymbol.isClass()) {
- return returnType;
+ } else {
+ this.resolveAST(callEx.arguments, inContextuallyTypedAssignment, enclosingDecl, context);
+ if (targetTypeSymbol.isClass()) {
+ return returnType;
+ }
}
context.postError(this.unitPath, targetAST.minChar, targetAST.getLength(), TypeScript.DiagnosticCode.Invalid_new_expression, null, enclosingDecl);
@@ -41803,6 +42027,10 @@ var TypeScript;
return false;
}
+ if (!!(s1.typeParameters && s1.typeParameters.length) != !!(s2.typeParameters && s2.typeParameters.length)) {
+ return false;
+ }
+
if (s1.typeParameters && s2.typeParameters && (s1.typeParameters.length != s2.typeParameters.length)) {
return false;
}
@@ -41879,7 +42107,7 @@ var TypeScript;
for (var j = 0; j < extendsList.members.length; j++) {
extendsSymbol = this.semanticInfoChain.getSymbolForAST(extendsList.members[j], sourceDecls[i].getScriptName());
- if (extendsSymbol == target || this.sourceExtendsTarget(extendsSymbol, target, context)) {
+ if (extendsSymbol && (extendsSymbol == target || this.sourceExtendsTarget(extendsSymbol, target, context))) {
return true;
}
}
@@ -42681,6 +42909,11 @@ var TypeScript;
typeB = actuals[i];
+ if (typeB.isAlias()) {
+ (typeB).isUsedAsValue = true;
+ typeB = (typeB).getExportAssignedTypeSymbol();
+ }
+
if (typeA && !typeA.isResolved) {
this.resolveDeclaredSymbol(typeA, enclosingDecl, context);
}
@@ -43418,6 +43651,10 @@ var TypeScript;
if (!typeSymbol.isNamedTypeSymbol()) {
if (typeSymbol.inSymbolPrivacyCheck) {
+ var associatedContainerType = typeSymbol.getAssociatedContainerType();
+ if (associatedContainerType && associatedContainerType.isNamedTypeSymbol()) {
+ this.checkSymbolPrivacy(declSymbol, associatedContainerType, context, privacyErrorReporter);
+ }
return;
}
@@ -43441,18 +43678,17 @@ var TypeScript;
if (declSymbol.isExternallyVisible()) {
var symbolIsVisible = symbol.isExternallyVisible();
- if (symbolIsVisible) {
+ if (symbolIsVisible && symbol.kind != 2 /* Primitive */ && symbol.kind != 8192 /* TypeParameter */) {
var symbolPath = symbol.pathToRoot();
- if (symbolPath.length && symbolPath[symbolPath.length - 1].kind === 32 /* DynamicModule */) {
- var declSymbolPath = declSymbol.pathToRoot();
+ var declSymbolPath = declSymbol.pathToRoot();
+ if (symbolPath[symbolPath.length - 1].kind === 32 /* DynamicModule */ && declSymbolPath[declSymbolPath.length - 1].kind == 32 /* DynamicModule */) {
var verifyAlias = false;
- if (declSymbolPath.length) {
- if (declSymbolPath[declSymbolPath.length - 1] != symbolPath[symbolPath.length - 1]) {
+
+ if (declSymbolPath[declSymbolPath.length - 1] != symbolPath[symbolPath.length - 1]) {
+ verifyAlias = true;
+ } else if (symbolPath.length > 1 && symbolPath[symbolPath.length - 2].kind == 32 /* DynamicModule */) {
+ if (declSymbolPath.length < 2 || declSymbolPath[declSymbolPath.length - 2] != symbolPath[symbolPath.length - 2]) {
verifyAlias = true;
- } else if (symbolPath.length > 1 && symbolPath[symbolPath.length - 2].kind == 32 /* DynamicModule */) {
- if (declSymbolPath.length < 2 || declSymbolPath[declSymbolPath.length - 2] != symbolPath[symbolPath.length - 2]) {
- verifyAlias = true;
- }
}
}
@@ -43469,6 +43705,10 @@ var TypeScript;
symbol = symbolPath[symbolPath.length - 1];
}
}
+ } else if (symbol.kind == 256 /* TypeAlias */) {
+ var aliasSymbol = symbol;
+ symbolIsVisible = true;
+ aliasSymbol.typeUsedExternally = true;
}
if (!symbolIsVisible) {
@@ -44069,7 +44309,7 @@ var TypeScript;
var extendedConstructorTypeProp = extendedConstructorType.findMember(propName);
if (extendedConstructorTypeProp) {
if (!extendedConstructorTypeProp.isResolved) {
- var extendedClassAst = this.currentUnit.getASTForSymbol(extendedType);
+ var extendedClassAst = this.currentUnit.getASTForDecl(extendedType.getDeclarations()[0]);
var extendedClassDecl = this.currentUnit.getDeclForAST(extendedClassAst);
this.resolveDeclaredSymbol(extendedConstructorTypeProp, extendedClassDecl, resolutionContext);
}
@@ -44159,7 +44399,10 @@ var TypeScript;
var contextForBaseTypeResolution = new TypeScript.PullTypeResolutionContext();
contextForBaseTypeResolution.isResolvingClassExtendedType = true;
+ var prevResolvingTypeReference = context.resolvingTypeReference;
+ context.resolvingTypeReference = true;
var baseType = this.resolveAST(baseDeclAST, false, enclosingDecl, context);
+ context.resolvingTypeReference = prevResolvingTypeReference;
contextForBaseTypeResolution.isResolvingClassExtendedType = false;
var typeDeclIsClass = typeSymbol.isClass();
@@ -44380,6 +44623,7 @@ var TypeScript;
});
this.syntaxElementSymbolMap = new TypeScript.DataMap();
this.symbolSyntaxElementMap = new TypeScript.DataMap();
+ this.properties = new SemanticInfoProperties();
this.hasBeenTypeChecked = false;
this.compilationUnitPath = compilationUnitPath;
}
@@ -44515,10 +44759,22 @@ var TypeScript;
TypeScript.getDiagnosticsFromEnclosingDecl(this.topLevelDecls[i], semanticErrors);
}
};
+
+ SemanticInfo.prototype.getProperties = function () {
+ return this.properties;
+ };
return SemanticInfo;
})();
TypeScript.SemanticInfo = SemanticInfo;
+ var SemanticInfoProperties = (function () {
+ function SemanticInfoProperties() {
+ this.unitContainsBool = false;
+ }
+ return SemanticInfoProperties;
+ })();
+ TypeScript.SemanticInfoProperties = SemanticInfoProperties;
+
var SemanticInfoChain = (function () {
function SemanticInfoChain() {
this.units = [new SemanticInfo("")];
@@ -46731,7 +46987,7 @@ var TypeScript;
constructorTypeSymbol.addDeclaration(constructorTypeDeclaration);
this.semanticInfo.setSymbolForAST(constructorTypeAST, constructorTypeSymbol);
- var signature = new TypeScript.PullDefinitionSignatureSymbol(2097152 /* ConstructSignature */);
+ var signature = new TypeScript.PullSignatureSymbol(2097152 /* ConstructSignature */);
if ((constructorTypeAST).variableArgList) {
signature.hasVarArgs = true;
@@ -47337,7 +47593,7 @@ var TypeScript;
signature.addTypeParameter(typeParameter);
} else {
- var typeParameterAST = this.semanticInfoChain.getASTForDecl(typeParameterDecls[0]);
+ var typeParameterAST = this.semanticInfoChain.getASTForDecl(typeParameter.getDeclarations()[0]);
functionTypeDeclaration.addDiagnostic(new TypeScript.Diagnostic(this.semanticInfo.getPath(), typeParameterAST.minChar, typeParameterAST.getLength(), TypeScript.DiagnosticCode.Duplicate_identifier_0, [typeParameter.name]));
}
@@ -48347,9 +48603,9 @@ var TypeScript;
return true;
}
- if (moduleElement.kind() === 133 /* ImportDeclaration */) {
+ if (moduleElement.kind() === 134 /* ImportDeclaration */) {
var importDecl = moduleElement;
- if (importDecl.moduleReference.kind() === 245 /* ExternalModuleReference */) {
+ if (importDecl.moduleReference.kind() === 246 /* ExternalModuleReference */) {
return true;
}
}
@@ -48484,7 +48740,7 @@ var TypeScript;
flags = flags | 1 /* Exported */;
}
- if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
flags = flags | 8 /* Ambient */;
}
@@ -48563,7 +48819,7 @@ var TypeScript;
};
SyntaxTreeToAstVisitor.prototype.getModuleNamesHelper = function (name, result) {
- if (name.kind() === 121 /* QualifiedName */) {
+ if (name.kind() === 122 /* QualifiedName */) {
var qualifiedName = name;
this.getModuleNamesHelper(qualifiedName.left, result);
this.movePast(qualifiedName.dotToken);
@@ -48620,7 +48876,7 @@ var TypeScript;
};
SyntaxTreeToAstVisitor.prototype.completeModuleDeclaration = function (node, result) {
- if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
result.setModuleFlags(result.getModuleFlags() | 8 /* Ambient */);
}
};
@@ -48670,7 +48926,7 @@ var TypeScript;
flags = flags | 1 /* Exported */;
}
- if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
flags = flags | 8 /* Ambient */;
}
@@ -48764,8 +49020,8 @@ var TypeScript;
if (TypeScript.Syntax.isIntegerLiteral(expression)) {
var token;
switch (expression.kind()) {
- case 163 /* PlusExpression */:
- case 164 /* NegateExpression */:
+ case 164 /* PlusExpression */:
+ case 165 /* NegateExpression */:
token = (expression).operand;
break;
default:
@@ -48773,7 +49029,7 @@ var TypeScript;
}
var value = token.value();
- return value && expression.kind() === 164 /* NegateExpression */ ? -value : value;
+ return value && expression.kind() === 165 /* NegateExpression */ ? -value : value;
} else if (this.compilationSettings.propagateEnumConstants) {
switch (expression.kind()) {
case 11 /* IdentifierName */:
@@ -48782,7 +49038,7 @@ var TypeScript;
});
return variableDeclarator ? variableDeclarator.constantValue : null;
- case 201 /* LeftShiftExpression */:
+ case 202 /* LeftShiftExpression */:
var binaryExpression = expression;
return this.computeConstantValue(binaryExpression.left, declarators) << this.computeConstantValue(binaryExpression.right, declarators);
}
@@ -48858,7 +49114,7 @@ var TypeScript;
flags = flags | 1 /* Exported */;
}
- if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
flags = flags | 8 /* Ambient */;
}
@@ -48924,17 +49180,17 @@ var TypeScript;
SyntaxTreeToAstVisitor.prototype.getUnaryExpressionNodeType = function (kind) {
switch (kind) {
- case 163 /* PlusExpression */:
+ case 164 /* PlusExpression */:
return 27 /* PlusExpression */;
- case 164 /* NegateExpression */:
+ case 165 /* NegateExpression */:
return 28 /* NegateExpression */;
- case 165 /* BitwiseNotExpression */:
+ case 166 /* BitwiseNotExpression */:
return 73 /* BitwiseNotExpression */;
- case 166 /* LogicalNotExpression */:
+ case 167 /* LogicalNotExpression */:
return 74 /* LogicalNotExpression */;
- case 167 /* PreIncrementExpression */:
+ case 168 /* PreIncrementExpression */:
return 75 /* PreIncrementExpression */;
- case 168 /* PreDecrementExpression */:
+ case 169 /* PreDecrementExpression */:
return 76 /* PreDecrementExpression */;
default:
throw TypeScript.Errors.invalidOperation();
@@ -49000,7 +49256,7 @@ var TypeScript;
};
SyntaxTreeToAstVisitor.prototype.getArrowFunctionStatements = function (body) {
- if (body.kind() === 145 /* Block */) {
+ if (body.kind() === 146 /* Block */) {
return body.accept(this);
} else {
var expression = body.accept(this);
@@ -49297,7 +49553,7 @@ var TypeScript;
var operand = node.operand.accept(this);
this.movePast(node.operatorToken);
- var result = new TypeScript.UnaryExpression(node.kind() === 209 /* PostIncrementExpression */ ? 77 /* PostIncrementExpression */ : 78 /* PostDecrementExpression */, operand, null);
+ var result = new TypeScript.UnaryExpression(node.kind() === 210 /* PostIncrementExpression */ ? 77 /* PostIncrementExpression */ : 78 /* PostDecrementExpression */, operand, null);
this.setSpan(result, start, node);
return result;
@@ -49363,77 +49619,77 @@ var TypeScript;
SyntaxTreeToAstVisitor.prototype.getBinaryExpressionNodeType = function (node) {
switch (node.kind()) {
- case 172 /* CommaExpression */:
+ case 173 /* CommaExpression */:
return 26 /* CommaExpression */;
- case 173 /* AssignmentExpression */:
+ case 174 /* AssignmentExpression */:
return 39 /* AssignmentExpression */;
- case 174 /* AddAssignmentExpression */:
+ case 175 /* AddAssignmentExpression */:
return 40 /* AddAssignmentExpression */;
- case 175 /* SubtractAssignmentExpression */:
+ case 176 /* SubtractAssignmentExpression */:
return 41 /* SubtractAssignmentExpression */;
- case 176 /* MultiplyAssignmentExpression */:
+ case 177 /* MultiplyAssignmentExpression */:
return 43 /* MultiplyAssignmentExpression */;
- case 177 /* DivideAssignmentExpression */:
+ case 178 /* DivideAssignmentExpression */:
return 42 /* DivideAssignmentExpression */;
- case 178 /* ModuloAssignmentExpression */:
+ case 179 /* ModuloAssignmentExpression */:
return 44 /* ModuloAssignmentExpression */;
- case 179 /* AndAssignmentExpression */:
+ case 180 /* AndAssignmentExpression */:
return 45 /* AndAssignmentExpression */;
- case 180 /* ExclusiveOrAssignmentExpression */:
+ case 181 /* ExclusiveOrAssignmentExpression */:
return 46 /* ExclusiveOrAssignmentExpression */;
- case 181 /* OrAssignmentExpression */:
+ case 182 /* OrAssignmentExpression */:
return 47 /* OrAssignmentExpression */;
- case 182 /* LeftShiftAssignmentExpression */:
+ case 183 /* LeftShiftAssignmentExpression */:
return 48 /* LeftShiftAssignmentExpression */;
- case 183 /* SignedRightShiftAssignmentExpression */:
+ case 184 /* SignedRightShiftAssignmentExpression */:
return 49 /* SignedRightShiftAssignmentExpression */;
- case 184 /* UnsignedRightShiftAssignmentExpression */:
+ case 185 /* UnsignedRightShiftAssignmentExpression */:
return 50 /* UnsignedRightShiftAssignmentExpression */;
- case 186 /* LogicalOrExpression */:
+ case 187 /* LogicalOrExpression */:
return 52 /* LogicalOrExpression */;
- case 187 /* LogicalAndExpression */:
+ case 188 /* LogicalAndExpression */:
return 53 /* LogicalAndExpression */;
- case 188 /* BitwiseOrExpression */:
+ case 189 /* BitwiseOrExpression */:
return 54 /* BitwiseOrExpression */;
- case 189 /* BitwiseExclusiveOrExpression */:
+ case 190 /* BitwiseExclusiveOrExpression */:
return 55 /* BitwiseExclusiveOrExpression */;
- case 190 /* BitwiseAndExpression */:
+ case 191 /* BitwiseAndExpression */:
return 56 /* BitwiseAndExpression */;
- case 191 /* EqualsWithTypeConversionExpression */:
+ case 192 /* EqualsWithTypeConversionExpression */:
return 57 /* EqualsWithTypeConversionExpression */;
- case 192 /* NotEqualsWithTypeConversionExpression */:
+ case 193 /* NotEqualsWithTypeConversionExpression */:
return 58 /* NotEqualsWithTypeConversionExpression */;
- case 193 /* EqualsExpression */:
+ case 194 /* EqualsExpression */:
return 59 /* EqualsExpression */;
- case 194 /* NotEqualsExpression */:
+ case 195 /* NotEqualsExpression */:
return 60 /* NotEqualsExpression */;
- case 195 /* LessThanExpression */:
+ case 196 /* LessThanExpression */:
return 61 /* LessThanExpression */;
- case 196 /* GreaterThanExpression */:
+ case 197 /* GreaterThanExpression */:
return 63 /* GreaterThanExpression */;
- case 197 /* LessThanOrEqualExpression */:
+ case 198 /* LessThanOrEqualExpression */:
return 62 /* LessThanOrEqualExpression */;
- case 198 /* GreaterThanOrEqualExpression */:
+ case 199 /* GreaterThanOrEqualExpression */:
return 64 /* GreaterThanOrEqualExpression */;
- case 199 /* InstanceOfExpression */:
+ case 200 /* InstanceOfExpression */:
return 34 /* InstanceOfExpression */;
- case 200 /* InExpression */:
+ case 201 /* InExpression */:
return 32 /* InExpression */;
- case 201 /* LeftShiftExpression */:
+ case 202 /* LeftShiftExpression */:
return 70 /* LeftShiftExpression */;
- case 202 /* SignedRightShiftExpression */:
+ case 203 /* SignedRightShiftExpression */:
return 71 /* SignedRightShiftExpression */;
- case 203 /* UnsignedRightShiftExpression */:
+ case 204 /* UnsignedRightShiftExpression */:
return 72 /* UnsignedRightShiftExpression */;
- case 204 /* MultiplyExpression */:
+ case 205 /* MultiplyExpression */:
return 67 /* MultiplyExpression */;
- case 205 /* DivideExpression */:
+ case 206 /* DivideExpression */:
return 68 /* DivideExpression */;
- case 206 /* ModuloExpression */:
+ case 207 /* ModuloExpression */:
return 69 /* ModuloExpression */;
- case 207 /* AddExpression */:
+ case 208 /* AddExpression */:
return 65 /* AddExpression */;
- case 208 /* SubtractExpression */:
+ case 209 /* SubtractExpression */:
return 66 /* SubtractExpression */;
}
@@ -49842,7 +50098,7 @@ var TypeScript;
var switchClause = node.switchClauses.childAt(i);
var translated = switchClause.accept(this);
- if (switchClause.kind() === 232 /* DefaultSwitchClause */) {
+ if (switchClause.kind() === 233 /* DefaultSwitchClause */) {
defaultCase = translated;
}
@@ -51304,14 +51560,6 @@ var TypeScript;
return null;
};
- TypeScriptCompiler.prototype.convertToDirectoryPath = function (dirPath) {
- if (dirPath && dirPath.charAt(dirPath.length - 1) !== "/") {
- dirPath += "/";
- }
-
- return dirPath;
- };
-
TypeScriptCompiler.prototype.setEmitOptions = function (ioHost) {
this.emitOptions.ioHost = ioHost;
@@ -51331,8 +51579,8 @@ var TypeScript;
}
}
- this.emitOptions.compilationSettings.mapRoot = this.convertToDirectoryPath(TypeScript.switchToForwardSlashes(this.emitOptions.compilationSettings.mapRoot));
- this.emitOptions.compilationSettings.sourceRoot = this.convertToDirectoryPath(TypeScript.switchToForwardSlashes(this.emitOptions.compilationSettings.sourceRoot));
+ this.emitOptions.compilationSettings.mapRoot = TypeScript.convertToDirectoryPath(TypeScript.switchToForwardSlashes(this.emitOptions.compilationSettings.mapRoot));
+ this.emitOptions.compilationSettings.sourceRoot = TypeScript.convertToDirectoryPath(TypeScript.switchToForwardSlashes(this.emitOptions.compilationSettings.sourceRoot));
if (!this.emitOptions.compilationSettings.outFileOption && !this.emitOptions.compilationSettings.outDirOption && !this.emitOptions.compilationSettings.mapRoot && !this.emitOptions.compilationSettings.sourceRoot) {
this.emitOptions.outputMany = true;
@@ -51349,7 +51597,7 @@ var TypeScript;
if (this.emitOptions.compilationSettings.outDirOption) {
this.emitOptions.compilationSettings.outDirOption = TypeScript.switchToForwardSlashes(this.emitOptions.ioHost.resolvePath(this.emitOptions.compilationSettings.outDirOption));
- this.emitOptions.compilationSettings.outDirOption = this.convertToDirectoryPath(this.emitOptions.compilationSettings.outDirOption);
+ this.emitOptions.compilationSettings.outDirOption = TypeScript.convertToDirectoryPath(this.emitOptions.compilationSettings.outDirOption);
}
if (this.emitOptions.compilationSettings.outDirOption || this.emitOptions.compilationSettings.mapRoot || this.emitOptions.compilationSettings.sourceRoot) {
@@ -54750,8 +54998,8 @@ var IO = (function () {
}
return {
- readFile: function (path) {
- return Environment.readFile(path);
+ readFile: function (path, codepage) {
+ return Environment.readFile(path, codepage);
},
writeFile: function (path, contents, writeByteOrderMark) {
Environment.writeFile(path, contents, writeByteOrderMark);
@@ -54870,8 +55118,8 @@ var IO = (function () {
var _module = require('module');
return {
- readFile: function (file) {
- return Environment.readFile(file);
+ readFile: function (file, codepage) {
+ return Environment.readFile(file, codepage);
},
writeFile: function (path, contents, writeByteOrderMark) {
Environment.writeFile(path, contents, writeByteOrderMark);
@@ -55074,7 +55322,7 @@ var TypeScript;
this.printVersion();
var optionsWord = TypeScript.getLocalizedText(TypeScript.DiagnosticCode.options, null);
- var fileWord = TypeScript.getLocalizedText(TypeScript.DiagnosticCode.file, null);
+ var fileWord = TypeScript.getLocalizedText(TypeScript.DiagnosticCode.file1, null);
var tscSyntax = "tsc [" + optionsWord + "] [" + fileWord + " ..]";
var syntaxHelp = TypeScript.getLocalizedText(TypeScript.DiagnosticCode.Syntax_0, [tscSyntax]);
this.host.printLine(syntaxHelp);
@@ -55243,7 +55491,7 @@ var TypeScript;
if (match) {
if (match[1] === '@') {
- this.parseString(this.host.readFile(match[2]).contents);
+ this.parseString(this.host.readFile(match[2], null).contents);
} else {
var arg = match[2];
var option = this.findOption(arg);
@@ -55307,7 +55555,7 @@ var TypeScript;
var BatchCompiler = (function () {
function BatchCompiler(ioHost) {
this.ioHost = ioHost;
- this.compilerVersion = "0.9.1.0";
+ this.compilerVersion = "0.9.1.1";
this.inputFiles = [];
this.resolvedFiles = [];
this.inputFileNameToOutputFileName = new TypeScript.StringHashTable();
@@ -55405,9 +55653,11 @@ var TypeScript;
if (this.compilationSettings.generateDeclarationFiles) {
var references = TypeScript.getReferencedFiles(inputFile, this.getScriptSnapshot(inputFile));
- references.forEach(function (reference) {
- referencedFiles.push(reference.path);
- });
+ for (var j = 0; j < references.length; j++) {
+ referencedFiles.push(references[j].path);
+ }
+
+ inputFile = this.ioHost.resolvePath(inputFile);
}
resolvedFiles.push({
@@ -55560,7 +55810,7 @@ var TypeScript;
locCode: TypeScript.DiagnosticCode.Concatenate_and_emit_output_to_single_file,
args: null
},
- type: TypeScript.DiagnosticCode.FILE,
+ type: TypeScript.DiagnosticCode.file2,
set: function (str) {
_this.compilationSettings.outFileOption = str;
}
@@ -55745,6 +55995,26 @@ var TypeScript;
}
}, 'v');
+ opts.flag('allowbool', {
+ usage: {
+ locCode: TypeScript.DiagnosticCode.Allow_bool_as_a_synonym_for_boolean,
+ args: null
+ },
+ set: function () {
+ _this.compilationSettings.allowBool = true;
+ }
+ });
+
+ opts.flag('allowimportmodule', {
+ usage: {
+ locCode: TypeScript.DiagnosticCode.Allow_module_as_a_synonym_for_require,
+ args: null
+ },
+ set: function () {
+ _this.compilationSettings.allowModuleKeywordInExternalModuleReference = true;
+ }
+ });
+
var locale = null;
opts.option('locale', {
experimental: true,
@@ -55768,6 +56038,19 @@ var TypeScript;
}
});
+ if (Environment.supportsCodePage()) {
+ opts.option('codepage', {
+ usage: {
+ locCode: TypeScript.DiagnosticCode.Specify_the_codepage_to_use_when_opening_source_files,
+ args: null
+ },
+ type: TypeScript.DiagnosticCode.NUMBER,
+ set: function (arg) {
+ _this.compilationSettings.codepage = parseInt(arg, 10);
+ }
+ });
+ }
+
opts.parse(this.ioHost.arguments);
if (locale) {
@@ -55823,7 +56106,7 @@ var TypeScript;
return false;
}
- var fileContents = this.ioHost.readFile(filePath);
+ var fileContents = this.ioHost.readFile(filePath, this.compilationSettings.codepage);
TypeScript.LocalizedDiagnosticMessages = JSON.parse(fileContents.contents);
return true;
};
@@ -55896,9 +56179,9 @@ var TypeScript;
if (!firstTime) {
var fileNames = "";
- lastResolvedFileSet.forEach(function (f) {
- fileNames += Environment.newLine + " " + f;
- });
+ for (var k = 0; k < lastResolvedFileSet.length; k++) {
+ fileNames += Environment.newLine + " " + lastResolvedFileSet[k];
+ }
_this.ioHost.printLine(TypeScript.getLocalizedText(TypeScript.DiagnosticCode.NL_Recompiling_0, [fileNames]));
} else {
firstTime = false;
@@ -55918,7 +56201,7 @@ var TypeScript;
var fileInformation;
try {
- fileInformation = this.ioHost.readFile(fileName);
+ fileInformation = this.ioHost.readFile(fileName, this.compilationSettings.codepage);
} catch (e) {
this.addDiagnostic(new TypeScript.Diagnostic(null, 0, 0, TypeScript.DiagnosticCode.Cannot_read_file_0_1, [fileName, e.message]));
fileInformation = new FileInformation("", 0 /* None */);
diff --git a/_infrastructure/tests/typescript/typescript.js b/_infrastructure/tests/typescript/typescript.js
index d25291ab0..3e6a2402d 100644
--- a/_infrastructure/tests/typescript/typescript.js
+++ b/_infrastructure/tests/typescript/typescript.js
@@ -345,7 +345,9 @@ var TypeScript;
Option_mapRoot_cannot_be_specified_without_specifying_sourcemap_option: "Option mapRoot cannot be specified without specifying sourcemap option.",
Option_sourceRoot_cannot_be_specified_without_specifying_sourcemap_option: "Option sourceRoot cannot be specified without specifying sourcemap option.",
Options_mapRoot_and_sourceRoot_cannot_be_specified_without_specifying_sourcemap_option: "Options mapRoot and sourceRoot cannot be specified without specifying sourcemap option.",
- Concatenate_and_emit_output_to_single_file: "Concatenate and emit output to single file",
+ Option_0_specified_without_1: "Option '{0}' specified without '{1}'",
+ codepage_option_not_supported_on_current_platform: "'codepage' option not supported on current platform.",
+ Concatenate_and_emit_output_to_single_file: "Concatenate and emit output to single file.",
Generates_corresponding_0_file: "Generates corresponding {0} file",
Specifies_the_location_where_debugger_should_locate_map_files_instead_of_generated_locations: "Specifies the location where debugger should locate map files instead of generated locations.",
Specifies_the_location_where_debugger_should_locate_TypeScript_files_instead_of_source_locations: "Specifies the location where debugger should locate TypeScript files instead of source locations.",
@@ -361,7 +363,7 @@ var TypeScript;
Specify_locale_for_errors_and_messages_For_example_0_or_1: "Specify locale for errors and messages. For example '{0}' or '{1}'",
Syntax_0: "Syntax: {0}",
options: "options",
- file: "file",
+ file1: "file",
Examples: "Examples:",
Options: "Options:",
Insert_command_line_options_and_files_from_a_file: "Insert command line options and files from a file.",
@@ -370,10 +372,12 @@ var TypeScript;
NL_Recompiling_0: "{NL}Recompiling ({0}):",
STRING: "STRING",
KIND: "KIND",
- FILE: "FILE",
+ file2: "FILE",
VERSION: "VERSION",
LOCATION: "LOCATION",
DIRECTORY: "DIRECTORY",
+ NUMBER: "NUMBER",
+ Specify_the_codepage_to_use_when_opening_source_files: "Specify the codepage to use when opening source files.",
This_version_of_the_Javascript_runtime_does_not_support_the_0_function: "This version of the Javascript runtime does not support the '{0}' function.",
Looking_up_path_for_identifier_token_did_not_result_in_an_identifer: "Looking up path for identifier token did not result in an identifer.",
Unknown_rule: "Unknown rule",
@@ -389,7 +393,11 @@ var TypeScript;
Parameter_0_of_lambda_function_implicitly_has_an_any_type: "Parameter '{0}' of lambda function implicitly has an 'any' type.",
Constructor_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type: "Constructor signature, which lacks return-type annotation, implicitly has an 'any' return type.",
Lambda_Function_which_lacks_return_type_annotation_implicitly_has_an_any_return_type: "Lambda Function, which lacks return-type annotation, implicitly has an 'any' return type.",
- Array_Literal_implicitly_has_an_any_type_from_widening: "Array Literal implicitly has an 'any' type from widening."
+ Array_Literal_implicitly_has_an_any_type_from_widening: "Array Literal implicitly has an 'any' type from widening.",
+ Use_of_deprecated_type_bool_Use_boolean_instead: "Use of deprecated type 'bool'. Use 'boolean' instead.",
+ module_is_deprecated_Use_require_instead: "'module(...)' is deprecated. Use 'require(...)' instead.",
+ Allow_bool_as_a_synonym_for_boolean: "Allow 'bool' as a synonym for 'boolean'.",
+ Allow_module_as_a_synonym_for_require: "Allow 'module(...)' as a synonym for 'require(...)'."
};
})(TypeScript || (TypeScript = {}));
var TypeScript;
@@ -1068,18 +1076,16 @@ var TypeScript;
function getDiagnosticInfoFromKey(diagnosticKey) {
var result = TypeScript.diagnosticInformationMap[diagnosticKey];
- TypeScript.Debug.assert(result !== undefined && result !== null);
+
return result;
}
TypeScript.getDiagnosticInfoFromKey = getDiagnosticInfoFromKey;
function getLocalizedText(diagnosticKey, args) {
if (TypeScript.LocalizedDiagnosticMessages) {
- TypeScript.Debug.assert(TypeScript.LocalizedDiagnosticMessages.hasOwnProperty(diagnosticKey));
}
var diagnosticMessageText = TypeScript.LocalizedDiagnosticMessages ? TypeScript.LocalizedDiagnosticMessages[diagnosticKey] : diagnosticKey;
- TypeScript.Debug.assert(diagnosticMessageText !== undefined && diagnosticMessageText !== null);
var actualCount = args ? args.length : 0;
@@ -1178,8 +1184,19 @@ var Environment = (function () {
currentDirectory: function () {
return (WScript).CreateObject("WScript.Shell").CurrentDirectory;
},
- readFile: function (path) {
+ supportsCodePage: function () {
+ return (WScript).ReadFile;
+ },
+ readFile: function (path, codepage) {
try {
+ if (codepage !== null && this.supportsCodePage()) {
+ try {
+ var contents = (WScript).ReadFile(path, codepage);
+ return new FileInformation(contents, 0 /* None */);
+ } catch (e) {
+ }
+ }
+
var streamObj = getStreamObject();
streamObj.Open();
streamObj.Type = 2;
@@ -1304,7 +1321,14 @@ var Environment = (function () {
currentDirectory: function () {
return (process).cwd();
},
- readFile: function (file) {
+ supportsCodePage: function () {
+ return false;
+ },
+ readFile: function (file, codepage) {
+ if (codepage !== null) {
+ throw new Error(TypeScript.getDiagnosticMessage(TypeScript.DiagnosticCode.codepage_option_not_supported_on_current_platform, null));
+ }
+
var buffer = _fs.readFileSync(file);
switch (buffer[0]) {
case 0xFE:
@@ -2986,7 +3010,15 @@ var TypeScript;
"code": 5040,
"category": 1 /* Error */
},
- "Concatenate and emit output to single file": {
+ "Option '{0}' specified without '{1}'": {
+ "code": 5041,
+ "category": 1 /* Error */
+ },
+ "'codepage' option not supported on current platform.": {
+ "code": 5042,
+ "category": 1 /* Error */
+ },
+ "Concatenate and emit output to single file.": {
"code": 6001,
"category": 2 /* Message */
},
@@ -3050,7 +3082,7 @@ var TypeScript;
"code": 6024,
"category": 2 /* Message */
},
- "file": {
+ "file1": {
"code": 6025,
"category": 2 /* Message */
},
@@ -3086,7 +3118,7 @@ var TypeScript;
"code": 6034,
"category": 2 /* Message */
},
- "FILE": {
+ "file2": {
"code": 6035,
"category": 2 /* Message */
},
@@ -3102,6 +3134,14 @@ var TypeScript;
"code": 6038,
"category": 2 /* Message */
},
+ "NUMBER": {
+ "code": 6039,
+ "category": 2 /* Message */
+ },
+ "Specify the codepage to use when opening source files.": {
+ "code": 6040,
+ "category": 2 /* Message */
+ },
"This version of the Javascript runtime does not support the '{0}' function.": {
"code": 7000,
"category": 1 /* Error */
@@ -3165,6 +3205,22 @@ var TypeScript;
"Array Literal implicitly has an 'any' type from widening.": {
"code": 7014,
"category": 1 /* Error */
+ },
+ "Use of deprecated type 'bool'. Use 'boolean' instead.": {
+ "code": 7020,
+ "category": 0 /* Warning */
+ },
+ "'module(...)' is deprecated. Use 'require(...)' instead.": {
+ "code": 7021,
+ "category": 0 /* Warning */
+ },
+ "Allow 'bool' as a synonym for 'boolean'.": {
+ "code": 7022,
+ "category": 2 /* Message */
+ },
+ "Allow 'module(...)' as a synonym for 'require(...)'.": {
+ "code": 7022,
+ "category": 2 /* Message */
}
};
})(TypeScript || (TypeScript = {}));
@@ -4361,12 +4417,16 @@ var TypeScript;
var TypeScript;
(function (TypeScript) {
var ParseOptions = (function () {
- function ParseOptions(languageVersion, allowAutomaticSemicolonInsertion) {
+ function ParseOptions(languageVersion, allowAutomaticSemicolonInsertion, allowModuleKeywordInExternalModuleReference) {
this._languageVersion = languageVersion;
this._allowAutomaticSemicolonInsertion = allowAutomaticSemicolonInsertion;
+ this._allowModuleKeywordInExternalModuleReference = allowModuleKeywordInExternalModuleReference;
}
ParseOptions.prototype.toJSON = function (key) {
- return { allowAutomaticSemicolonInsertion: this._allowAutomaticSemicolonInsertion };
+ return {
+ allowAutomaticSemicolonInsertion: this._allowAutomaticSemicolonInsertion,
+ allowModuleKeywordInExternalModuleReference: this._allowModuleKeywordInExternalModuleReference
+ };
};
ParseOptions.prototype.languageVersion = function () {
@@ -4376,6 +4436,10 @@ var TypeScript;
ParseOptions.prototype.allowAutomaticSemicolonInsertion = function () {
return this._allowAutomaticSemicolonInsertion;
};
+
+ ParseOptions.prototype.allowModuleKeywordInExternalModuleReference = function () {
+ return this._allowModuleKeywordInExternalModuleReference;
+ };
return ParseOptions;
})();
TypeScript.ParseOptions = ParseOptions;
@@ -4757,206 +4821,207 @@ var TypeScript;
SyntaxKind[SyntaxKind["AnyKeyword"] = 60] = "AnyKeyword";
SyntaxKind[SyntaxKind["BooleanKeyword"] = 61] = "BooleanKeyword";
- SyntaxKind[SyntaxKind["ConstructorKeyword"] = 62] = "ConstructorKeyword";
- SyntaxKind[SyntaxKind["DeclareKeyword"] = 63] = "DeclareKeyword";
- SyntaxKind[SyntaxKind["GetKeyword"] = 64] = "GetKeyword";
- SyntaxKind[SyntaxKind["ModuleKeyword"] = 65] = "ModuleKeyword";
- SyntaxKind[SyntaxKind["RequireKeyword"] = 66] = "RequireKeyword";
- SyntaxKind[SyntaxKind["NumberKeyword"] = 67] = "NumberKeyword";
- SyntaxKind[SyntaxKind["SetKeyword"] = 68] = "SetKeyword";
- SyntaxKind[SyntaxKind["StringKeyword"] = 69] = "StringKeyword";
+ SyntaxKind[SyntaxKind["BoolKeyword"] = 62] = "BoolKeyword";
+ SyntaxKind[SyntaxKind["ConstructorKeyword"] = 63] = "ConstructorKeyword";
+ SyntaxKind[SyntaxKind["DeclareKeyword"] = 64] = "DeclareKeyword";
+ SyntaxKind[SyntaxKind["GetKeyword"] = 65] = "GetKeyword";
+ SyntaxKind[SyntaxKind["ModuleKeyword"] = 66] = "ModuleKeyword";
+ SyntaxKind[SyntaxKind["RequireKeyword"] = 67] = "RequireKeyword";
+ SyntaxKind[SyntaxKind["NumberKeyword"] = 68] = "NumberKeyword";
+ SyntaxKind[SyntaxKind["SetKeyword"] = 69] = "SetKeyword";
+ SyntaxKind[SyntaxKind["StringKeyword"] = 70] = "StringKeyword";
- SyntaxKind[SyntaxKind["OpenBraceToken"] = 70] = "OpenBraceToken";
- SyntaxKind[SyntaxKind["CloseBraceToken"] = 71] = "CloseBraceToken";
- SyntaxKind[SyntaxKind["OpenParenToken"] = 72] = "OpenParenToken";
- SyntaxKind[SyntaxKind["CloseParenToken"] = 73] = "CloseParenToken";
- SyntaxKind[SyntaxKind["OpenBracketToken"] = 74] = "OpenBracketToken";
- SyntaxKind[SyntaxKind["CloseBracketToken"] = 75] = "CloseBracketToken";
- SyntaxKind[SyntaxKind["DotToken"] = 76] = "DotToken";
- SyntaxKind[SyntaxKind["DotDotDotToken"] = 77] = "DotDotDotToken";
- SyntaxKind[SyntaxKind["SemicolonToken"] = 78] = "SemicolonToken";
- SyntaxKind[SyntaxKind["CommaToken"] = 79] = "CommaToken";
- SyntaxKind[SyntaxKind["LessThanToken"] = 80] = "LessThanToken";
- SyntaxKind[SyntaxKind["GreaterThanToken"] = 81] = "GreaterThanToken";
- SyntaxKind[SyntaxKind["LessThanEqualsToken"] = 82] = "LessThanEqualsToken";
- SyntaxKind[SyntaxKind["GreaterThanEqualsToken"] = 83] = "GreaterThanEqualsToken";
- SyntaxKind[SyntaxKind["EqualsEqualsToken"] = 84] = "EqualsEqualsToken";
- SyntaxKind[SyntaxKind["EqualsGreaterThanToken"] = 85] = "EqualsGreaterThanToken";
- SyntaxKind[SyntaxKind["ExclamationEqualsToken"] = 86] = "ExclamationEqualsToken";
- SyntaxKind[SyntaxKind["EqualsEqualsEqualsToken"] = 87] = "EqualsEqualsEqualsToken";
- SyntaxKind[SyntaxKind["ExclamationEqualsEqualsToken"] = 88] = "ExclamationEqualsEqualsToken";
- SyntaxKind[SyntaxKind["PlusToken"] = 89] = "PlusToken";
- SyntaxKind[SyntaxKind["MinusToken"] = 90] = "MinusToken";
- SyntaxKind[SyntaxKind["AsteriskToken"] = 91] = "AsteriskToken";
- SyntaxKind[SyntaxKind["PercentToken"] = 92] = "PercentToken";
- SyntaxKind[SyntaxKind["PlusPlusToken"] = 93] = "PlusPlusToken";
- SyntaxKind[SyntaxKind["MinusMinusToken"] = 94] = "MinusMinusToken";
- SyntaxKind[SyntaxKind["LessThanLessThanToken"] = 95] = "LessThanLessThanToken";
- SyntaxKind[SyntaxKind["GreaterThanGreaterThanToken"] = 96] = "GreaterThanGreaterThanToken";
- SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanToken"] = 97] = "GreaterThanGreaterThanGreaterThanToken";
- SyntaxKind[SyntaxKind["AmpersandToken"] = 98] = "AmpersandToken";
- SyntaxKind[SyntaxKind["BarToken"] = 99] = "BarToken";
- SyntaxKind[SyntaxKind["CaretToken"] = 100] = "CaretToken";
- SyntaxKind[SyntaxKind["ExclamationToken"] = 101] = "ExclamationToken";
- SyntaxKind[SyntaxKind["TildeToken"] = 102] = "TildeToken";
- SyntaxKind[SyntaxKind["AmpersandAmpersandToken"] = 103] = "AmpersandAmpersandToken";
- SyntaxKind[SyntaxKind["BarBarToken"] = 104] = "BarBarToken";
- SyntaxKind[SyntaxKind["QuestionToken"] = 105] = "QuestionToken";
- SyntaxKind[SyntaxKind["ColonToken"] = 106] = "ColonToken";
- SyntaxKind[SyntaxKind["EqualsToken"] = 107] = "EqualsToken";
- SyntaxKind[SyntaxKind["PlusEqualsToken"] = 108] = "PlusEqualsToken";
- SyntaxKind[SyntaxKind["MinusEqualsToken"] = 109] = "MinusEqualsToken";
- SyntaxKind[SyntaxKind["AsteriskEqualsToken"] = 110] = "AsteriskEqualsToken";
- SyntaxKind[SyntaxKind["PercentEqualsToken"] = 111] = "PercentEqualsToken";
- SyntaxKind[SyntaxKind["LessThanLessThanEqualsToken"] = 112] = "LessThanLessThanEqualsToken";
- SyntaxKind[SyntaxKind["GreaterThanGreaterThanEqualsToken"] = 113] = "GreaterThanGreaterThanEqualsToken";
- SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanEqualsToken"] = 114] = "GreaterThanGreaterThanGreaterThanEqualsToken";
- SyntaxKind[SyntaxKind["AmpersandEqualsToken"] = 115] = "AmpersandEqualsToken";
- SyntaxKind[SyntaxKind["BarEqualsToken"] = 116] = "BarEqualsToken";
- SyntaxKind[SyntaxKind["CaretEqualsToken"] = 117] = "CaretEqualsToken";
- SyntaxKind[SyntaxKind["SlashToken"] = 118] = "SlashToken";
- SyntaxKind[SyntaxKind["SlashEqualsToken"] = 119] = "SlashEqualsToken";
+ SyntaxKind[SyntaxKind["OpenBraceToken"] = 71] = "OpenBraceToken";
+ SyntaxKind[SyntaxKind["CloseBraceToken"] = 72] = "CloseBraceToken";
+ SyntaxKind[SyntaxKind["OpenParenToken"] = 73] = "OpenParenToken";
+ SyntaxKind[SyntaxKind["CloseParenToken"] = 74] = "CloseParenToken";
+ SyntaxKind[SyntaxKind["OpenBracketToken"] = 75] = "OpenBracketToken";
+ SyntaxKind[SyntaxKind["CloseBracketToken"] = 76] = "CloseBracketToken";
+ SyntaxKind[SyntaxKind["DotToken"] = 77] = "DotToken";
+ SyntaxKind[SyntaxKind["DotDotDotToken"] = 78] = "DotDotDotToken";
+ SyntaxKind[SyntaxKind["SemicolonToken"] = 79] = "SemicolonToken";
+ SyntaxKind[SyntaxKind["CommaToken"] = 80] = "CommaToken";
+ SyntaxKind[SyntaxKind["LessThanToken"] = 81] = "LessThanToken";
+ SyntaxKind[SyntaxKind["GreaterThanToken"] = 82] = "GreaterThanToken";
+ SyntaxKind[SyntaxKind["LessThanEqualsToken"] = 83] = "LessThanEqualsToken";
+ SyntaxKind[SyntaxKind["GreaterThanEqualsToken"] = 84] = "GreaterThanEqualsToken";
+ SyntaxKind[SyntaxKind["EqualsEqualsToken"] = 85] = "EqualsEqualsToken";
+ SyntaxKind[SyntaxKind["EqualsGreaterThanToken"] = 86] = "EqualsGreaterThanToken";
+ SyntaxKind[SyntaxKind["ExclamationEqualsToken"] = 87] = "ExclamationEqualsToken";
+ SyntaxKind[SyntaxKind["EqualsEqualsEqualsToken"] = 88] = "EqualsEqualsEqualsToken";
+ SyntaxKind[SyntaxKind["ExclamationEqualsEqualsToken"] = 89] = "ExclamationEqualsEqualsToken";
+ SyntaxKind[SyntaxKind["PlusToken"] = 90] = "PlusToken";
+ SyntaxKind[SyntaxKind["MinusToken"] = 91] = "MinusToken";
+ SyntaxKind[SyntaxKind["AsteriskToken"] = 92] = "AsteriskToken";
+ SyntaxKind[SyntaxKind["PercentToken"] = 93] = "PercentToken";
+ SyntaxKind[SyntaxKind["PlusPlusToken"] = 94] = "PlusPlusToken";
+ SyntaxKind[SyntaxKind["MinusMinusToken"] = 95] = "MinusMinusToken";
+ SyntaxKind[SyntaxKind["LessThanLessThanToken"] = 96] = "LessThanLessThanToken";
+ SyntaxKind[SyntaxKind["GreaterThanGreaterThanToken"] = 97] = "GreaterThanGreaterThanToken";
+ SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanToken"] = 98] = "GreaterThanGreaterThanGreaterThanToken";
+ SyntaxKind[SyntaxKind["AmpersandToken"] = 99] = "AmpersandToken";
+ SyntaxKind[SyntaxKind["BarToken"] = 100] = "BarToken";
+ SyntaxKind[SyntaxKind["CaretToken"] = 101] = "CaretToken";
+ SyntaxKind[SyntaxKind["ExclamationToken"] = 102] = "ExclamationToken";
+ SyntaxKind[SyntaxKind["TildeToken"] = 103] = "TildeToken";
+ SyntaxKind[SyntaxKind["AmpersandAmpersandToken"] = 104] = "AmpersandAmpersandToken";
+ SyntaxKind[SyntaxKind["BarBarToken"] = 105] = "BarBarToken";
+ SyntaxKind[SyntaxKind["QuestionToken"] = 106] = "QuestionToken";
+ SyntaxKind[SyntaxKind["ColonToken"] = 107] = "ColonToken";
+ SyntaxKind[SyntaxKind["EqualsToken"] = 108] = "EqualsToken";
+ SyntaxKind[SyntaxKind["PlusEqualsToken"] = 109] = "PlusEqualsToken";
+ SyntaxKind[SyntaxKind["MinusEqualsToken"] = 110] = "MinusEqualsToken";
+ SyntaxKind[SyntaxKind["AsteriskEqualsToken"] = 111] = "AsteriskEqualsToken";
+ SyntaxKind[SyntaxKind["PercentEqualsToken"] = 112] = "PercentEqualsToken";
+ SyntaxKind[SyntaxKind["LessThanLessThanEqualsToken"] = 113] = "LessThanLessThanEqualsToken";
+ SyntaxKind[SyntaxKind["GreaterThanGreaterThanEqualsToken"] = 114] = "GreaterThanGreaterThanEqualsToken";
+ SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanEqualsToken"] = 115] = "GreaterThanGreaterThanGreaterThanEqualsToken";
+ SyntaxKind[SyntaxKind["AmpersandEqualsToken"] = 116] = "AmpersandEqualsToken";
+ SyntaxKind[SyntaxKind["BarEqualsToken"] = 117] = "BarEqualsToken";
+ SyntaxKind[SyntaxKind["CaretEqualsToken"] = 118] = "CaretEqualsToken";
+ SyntaxKind[SyntaxKind["SlashToken"] = 119] = "SlashToken";
+ SyntaxKind[SyntaxKind["SlashEqualsToken"] = 120] = "SlashEqualsToken";
- SyntaxKind[SyntaxKind["SourceUnit"] = 120] = "SourceUnit";
+ SyntaxKind[SyntaxKind["SourceUnit"] = 121] = "SourceUnit";
- SyntaxKind[SyntaxKind["QualifiedName"] = 121] = "QualifiedName";
+ SyntaxKind[SyntaxKind["QualifiedName"] = 122] = "QualifiedName";
- SyntaxKind[SyntaxKind["ObjectType"] = 122] = "ObjectType";
- SyntaxKind[SyntaxKind["FunctionType"] = 123] = "FunctionType";
- SyntaxKind[SyntaxKind["ArrayType"] = 124] = "ArrayType";
- SyntaxKind[SyntaxKind["ConstructorType"] = 125] = "ConstructorType";
- SyntaxKind[SyntaxKind["GenericType"] = 126] = "GenericType";
- SyntaxKind[SyntaxKind["TypeQuery"] = 127] = "TypeQuery";
+ SyntaxKind[SyntaxKind["ObjectType"] = 123] = "ObjectType";
+ SyntaxKind[SyntaxKind["FunctionType"] = 124] = "FunctionType";
+ SyntaxKind[SyntaxKind["ArrayType"] = 125] = "ArrayType";
+ SyntaxKind[SyntaxKind["ConstructorType"] = 126] = "ConstructorType";
+ SyntaxKind[SyntaxKind["GenericType"] = 127] = "GenericType";
+ SyntaxKind[SyntaxKind["TypeQuery"] = 128] = "TypeQuery";
- SyntaxKind[SyntaxKind["InterfaceDeclaration"] = 128] = "InterfaceDeclaration";
- SyntaxKind[SyntaxKind["FunctionDeclaration"] = 129] = "FunctionDeclaration";
- SyntaxKind[SyntaxKind["ModuleDeclaration"] = 130] = "ModuleDeclaration";
- SyntaxKind[SyntaxKind["ClassDeclaration"] = 131] = "ClassDeclaration";
- SyntaxKind[SyntaxKind["EnumDeclaration"] = 132] = "EnumDeclaration";
- SyntaxKind[SyntaxKind["ImportDeclaration"] = 133] = "ImportDeclaration";
- SyntaxKind[SyntaxKind["ExportAssignment"] = 134] = "ExportAssignment";
+ SyntaxKind[SyntaxKind["InterfaceDeclaration"] = 129] = "InterfaceDeclaration";
+ SyntaxKind[SyntaxKind["FunctionDeclaration"] = 130] = "FunctionDeclaration";
+ SyntaxKind[SyntaxKind["ModuleDeclaration"] = 131] = "ModuleDeclaration";
+ SyntaxKind[SyntaxKind["ClassDeclaration"] = 132] = "ClassDeclaration";
+ SyntaxKind[SyntaxKind["EnumDeclaration"] = 133] = "EnumDeclaration";
+ SyntaxKind[SyntaxKind["ImportDeclaration"] = 134] = "ImportDeclaration";
+ SyntaxKind[SyntaxKind["ExportAssignment"] = 135] = "ExportAssignment";
- SyntaxKind[SyntaxKind["MemberFunctionDeclaration"] = 135] = "MemberFunctionDeclaration";
- SyntaxKind[SyntaxKind["MemberVariableDeclaration"] = 136] = "MemberVariableDeclaration";
- SyntaxKind[SyntaxKind["ConstructorDeclaration"] = 137] = "ConstructorDeclaration";
- SyntaxKind[SyntaxKind["GetMemberAccessorDeclaration"] = 138] = "GetMemberAccessorDeclaration";
- SyntaxKind[SyntaxKind["SetMemberAccessorDeclaration"] = 139] = "SetMemberAccessorDeclaration";
+ SyntaxKind[SyntaxKind["MemberFunctionDeclaration"] = 136] = "MemberFunctionDeclaration";
+ SyntaxKind[SyntaxKind["MemberVariableDeclaration"] = 137] = "MemberVariableDeclaration";
+ SyntaxKind[SyntaxKind["ConstructorDeclaration"] = 138] = "ConstructorDeclaration";
+ SyntaxKind[SyntaxKind["GetMemberAccessorDeclaration"] = 139] = "GetMemberAccessorDeclaration";
+ SyntaxKind[SyntaxKind["SetMemberAccessorDeclaration"] = 140] = "SetMemberAccessorDeclaration";
- SyntaxKind[SyntaxKind["PropertySignature"] = 140] = "PropertySignature";
- SyntaxKind[SyntaxKind["CallSignature"] = 141] = "CallSignature";
- SyntaxKind[SyntaxKind["ConstructSignature"] = 142] = "ConstructSignature";
- SyntaxKind[SyntaxKind["IndexSignature"] = 143] = "IndexSignature";
- SyntaxKind[SyntaxKind["MethodSignature"] = 144] = "MethodSignature";
+ SyntaxKind[SyntaxKind["PropertySignature"] = 141] = "PropertySignature";
+ SyntaxKind[SyntaxKind["CallSignature"] = 142] = "CallSignature";
+ SyntaxKind[SyntaxKind["ConstructSignature"] = 143] = "ConstructSignature";
+ SyntaxKind[SyntaxKind["IndexSignature"] = 144] = "IndexSignature";
+ SyntaxKind[SyntaxKind["MethodSignature"] = 145] = "MethodSignature";
- SyntaxKind[SyntaxKind["Block"] = 145] = "Block";
- SyntaxKind[SyntaxKind["IfStatement"] = 146] = "IfStatement";
- SyntaxKind[SyntaxKind["VariableStatement"] = 147] = "VariableStatement";
- SyntaxKind[SyntaxKind["ExpressionStatement"] = 148] = "ExpressionStatement";
- SyntaxKind[SyntaxKind["ReturnStatement"] = 149] = "ReturnStatement";
- SyntaxKind[SyntaxKind["SwitchStatement"] = 150] = "SwitchStatement";
- SyntaxKind[SyntaxKind["BreakStatement"] = 151] = "BreakStatement";
- SyntaxKind[SyntaxKind["ContinueStatement"] = 152] = "ContinueStatement";
- SyntaxKind[SyntaxKind["ForStatement"] = 153] = "ForStatement";
- SyntaxKind[SyntaxKind["ForInStatement"] = 154] = "ForInStatement";
- SyntaxKind[SyntaxKind["EmptyStatement"] = 155] = "EmptyStatement";
- SyntaxKind[SyntaxKind["ThrowStatement"] = 156] = "ThrowStatement";
- SyntaxKind[SyntaxKind["WhileStatement"] = 157] = "WhileStatement";
- SyntaxKind[SyntaxKind["TryStatement"] = 158] = "TryStatement";
- SyntaxKind[SyntaxKind["LabeledStatement"] = 159] = "LabeledStatement";
- SyntaxKind[SyntaxKind["DoStatement"] = 160] = "DoStatement";
- SyntaxKind[SyntaxKind["DebuggerStatement"] = 161] = "DebuggerStatement";
- SyntaxKind[SyntaxKind["WithStatement"] = 162] = "WithStatement";
+ SyntaxKind[SyntaxKind["Block"] = 146] = "Block";
+ SyntaxKind[SyntaxKind["IfStatement"] = 147] = "IfStatement";
+ SyntaxKind[SyntaxKind["VariableStatement"] = 148] = "VariableStatement";
+ SyntaxKind[SyntaxKind["ExpressionStatement"] = 149] = "ExpressionStatement";
+ SyntaxKind[SyntaxKind["ReturnStatement"] = 150] = "ReturnStatement";
+ SyntaxKind[SyntaxKind["SwitchStatement"] = 151] = "SwitchStatement";
+ SyntaxKind[SyntaxKind["BreakStatement"] = 152] = "BreakStatement";
+ SyntaxKind[SyntaxKind["ContinueStatement"] = 153] = "ContinueStatement";
+ SyntaxKind[SyntaxKind["ForStatement"] = 154] = "ForStatement";
+ SyntaxKind[SyntaxKind["ForInStatement"] = 155] = "ForInStatement";
+ SyntaxKind[SyntaxKind["EmptyStatement"] = 156] = "EmptyStatement";
+ SyntaxKind[SyntaxKind["ThrowStatement"] = 157] = "ThrowStatement";
+ SyntaxKind[SyntaxKind["WhileStatement"] = 158] = "WhileStatement";
+ SyntaxKind[SyntaxKind["TryStatement"] = 159] = "TryStatement";
+ SyntaxKind[SyntaxKind["LabeledStatement"] = 160] = "LabeledStatement";
+ SyntaxKind[SyntaxKind["DoStatement"] = 161] = "DoStatement";
+ SyntaxKind[SyntaxKind["DebuggerStatement"] = 162] = "DebuggerStatement";
+ SyntaxKind[SyntaxKind["WithStatement"] = 163] = "WithStatement";
- SyntaxKind[SyntaxKind["PlusExpression"] = 163] = "PlusExpression";
- SyntaxKind[SyntaxKind["NegateExpression"] = 164] = "NegateExpression";
- SyntaxKind[SyntaxKind["BitwiseNotExpression"] = 165] = "BitwiseNotExpression";
- SyntaxKind[SyntaxKind["LogicalNotExpression"] = 166] = "LogicalNotExpression";
- SyntaxKind[SyntaxKind["PreIncrementExpression"] = 167] = "PreIncrementExpression";
- SyntaxKind[SyntaxKind["PreDecrementExpression"] = 168] = "PreDecrementExpression";
- SyntaxKind[SyntaxKind["DeleteExpression"] = 169] = "DeleteExpression";
- SyntaxKind[SyntaxKind["TypeOfExpression"] = 170] = "TypeOfExpression";
- SyntaxKind[SyntaxKind["VoidExpression"] = 171] = "VoidExpression";
- SyntaxKind[SyntaxKind["CommaExpression"] = 172] = "CommaExpression";
- SyntaxKind[SyntaxKind["AssignmentExpression"] = 173] = "AssignmentExpression";
- SyntaxKind[SyntaxKind["AddAssignmentExpression"] = 174] = "AddAssignmentExpression";
- SyntaxKind[SyntaxKind["SubtractAssignmentExpression"] = 175] = "SubtractAssignmentExpression";
- SyntaxKind[SyntaxKind["MultiplyAssignmentExpression"] = 176] = "MultiplyAssignmentExpression";
- SyntaxKind[SyntaxKind["DivideAssignmentExpression"] = 177] = "DivideAssignmentExpression";
- SyntaxKind[SyntaxKind["ModuloAssignmentExpression"] = 178] = "ModuloAssignmentExpression";
- SyntaxKind[SyntaxKind["AndAssignmentExpression"] = 179] = "AndAssignmentExpression";
- SyntaxKind[SyntaxKind["ExclusiveOrAssignmentExpression"] = 180] = "ExclusiveOrAssignmentExpression";
- SyntaxKind[SyntaxKind["OrAssignmentExpression"] = 181] = "OrAssignmentExpression";
- SyntaxKind[SyntaxKind["LeftShiftAssignmentExpression"] = 182] = "LeftShiftAssignmentExpression";
- SyntaxKind[SyntaxKind["SignedRightShiftAssignmentExpression"] = 183] = "SignedRightShiftAssignmentExpression";
- SyntaxKind[SyntaxKind["UnsignedRightShiftAssignmentExpression"] = 184] = "UnsignedRightShiftAssignmentExpression";
- SyntaxKind[SyntaxKind["ConditionalExpression"] = 185] = "ConditionalExpression";
- SyntaxKind[SyntaxKind["LogicalOrExpression"] = 186] = "LogicalOrExpression";
- SyntaxKind[SyntaxKind["LogicalAndExpression"] = 187] = "LogicalAndExpression";
- SyntaxKind[SyntaxKind["BitwiseOrExpression"] = 188] = "BitwiseOrExpression";
- SyntaxKind[SyntaxKind["BitwiseExclusiveOrExpression"] = 189] = "BitwiseExclusiveOrExpression";
- SyntaxKind[SyntaxKind["BitwiseAndExpression"] = 190] = "BitwiseAndExpression";
- SyntaxKind[SyntaxKind["EqualsWithTypeConversionExpression"] = 191] = "EqualsWithTypeConversionExpression";
- SyntaxKind[SyntaxKind["NotEqualsWithTypeConversionExpression"] = 192] = "NotEqualsWithTypeConversionExpression";
- SyntaxKind[SyntaxKind["EqualsExpression"] = 193] = "EqualsExpression";
- SyntaxKind[SyntaxKind["NotEqualsExpression"] = 194] = "NotEqualsExpression";
- SyntaxKind[SyntaxKind["LessThanExpression"] = 195] = "LessThanExpression";
- SyntaxKind[SyntaxKind["GreaterThanExpression"] = 196] = "GreaterThanExpression";
- SyntaxKind[SyntaxKind["LessThanOrEqualExpression"] = 197] = "LessThanOrEqualExpression";
- SyntaxKind[SyntaxKind["GreaterThanOrEqualExpression"] = 198] = "GreaterThanOrEqualExpression";
- SyntaxKind[SyntaxKind["InstanceOfExpression"] = 199] = "InstanceOfExpression";
- SyntaxKind[SyntaxKind["InExpression"] = 200] = "InExpression";
- SyntaxKind[SyntaxKind["LeftShiftExpression"] = 201] = "LeftShiftExpression";
- SyntaxKind[SyntaxKind["SignedRightShiftExpression"] = 202] = "SignedRightShiftExpression";
- SyntaxKind[SyntaxKind["UnsignedRightShiftExpression"] = 203] = "UnsignedRightShiftExpression";
- SyntaxKind[SyntaxKind["MultiplyExpression"] = 204] = "MultiplyExpression";
- SyntaxKind[SyntaxKind["DivideExpression"] = 205] = "DivideExpression";
- SyntaxKind[SyntaxKind["ModuloExpression"] = 206] = "ModuloExpression";
- SyntaxKind[SyntaxKind["AddExpression"] = 207] = "AddExpression";
- SyntaxKind[SyntaxKind["SubtractExpression"] = 208] = "SubtractExpression";
- SyntaxKind[SyntaxKind["PostIncrementExpression"] = 209] = "PostIncrementExpression";
- SyntaxKind[SyntaxKind["PostDecrementExpression"] = 210] = "PostDecrementExpression";
- SyntaxKind[SyntaxKind["MemberAccessExpression"] = 211] = "MemberAccessExpression";
- SyntaxKind[SyntaxKind["InvocationExpression"] = 212] = "InvocationExpression";
- SyntaxKind[SyntaxKind["ArrayLiteralExpression"] = 213] = "ArrayLiteralExpression";
- SyntaxKind[SyntaxKind["ObjectLiteralExpression"] = 214] = "ObjectLiteralExpression";
- SyntaxKind[SyntaxKind["ObjectCreationExpression"] = 215] = "ObjectCreationExpression";
- SyntaxKind[SyntaxKind["ParenthesizedExpression"] = 216] = "ParenthesizedExpression";
- SyntaxKind[SyntaxKind["ParenthesizedArrowFunctionExpression"] = 217] = "ParenthesizedArrowFunctionExpression";
- SyntaxKind[SyntaxKind["SimpleArrowFunctionExpression"] = 218] = "SimpleArrowFunctionExpression";
- SyntaxKind[SyntaxKind["CastExpression"] = 219] = "CastExpression";
- SyntaxKind[SyntaxKind["ElementAccessExpression"] = 220] = "ElementAccessExpression";
- SyntaxKind[SyntaxKind["FunctionExpression"] = 221] = "FunctionExpression";
- SyntaxKind[SyntaxKind["OmittedExpression"] = 222] = "OmittedExpression";
+ SyntaxKind[SyntaxKind["PlusExpression"] = 164] = "PlusExpression";
+ SyntaxKind[SyntaxKind["NegateExpression"] = 165] = "NegateExpression";
+ SyntaxKind[SyntaxKind["BitwiseNotExpression"] = 166] = "BitwiseNotExpression";
+ SyntaxKind[SyntaxKind["LogicalNotExpression"] = 167] = "LogicalNotExpression";
+ SyntaxKind[SyntaxKind["PreIncrementExpression"] = 168] = "PreIncrementExpression";
+ SyntaxKind[SyntaxKind["PreDecrementExpression"] = 169] = "PreDecrementExpression";
+ SyntaxKind[SyntaxKind["DeleteExpression"] = 170] = "DeleteExpression";
+ SyntaxKind[SyntaxKind["TypeOfExpression"] = 171] = "TypeOfExpression";
+ SyntaxKind[SyntaxKind["VoidExpression"] = 172] = "VoidExpression";
+ SyntaxKind[SyntaxKind["CommaExpression"] = 173] = "CommaExpression";
+ SyntaxKind[SyntaxKind["AssignmentExpression"] = 174] = "AssignmentExpression";
+ SyntaxKind[SyntaxKind["AddAssignmentExpression"] = 175] = "AddAssignmentExpression";
+ SyntaxKind[SyntaxKind["SubtractAssignmentExpression"] = 176] = "SubtractAssignmentExpression";
+ SyntaxKind[SyntaxKind["MultiplyAssignmentExpression"] = 177] = "MultiplyAssignmentExpression";
+ SyntaxKind[SyntaxKind["DivideAssignmentExpression"] = 178] = "DivideAssignmentExpression";
+ SyntaxKind[SyntaxKind["ModuloAssignmentExpression"] = 179] = "ModuloAssignmentExpression";
+ SyntaxKind[SyntaxKind["AndAssignmentExpression"] = 180] = "AndAssignmentExpression";
+ SyntaxKind[SyntaxKind["ExclusiveOrAssignmentExpression"] = 181] = "ExclusiveOrAssignmentExpression";
+ SyntaxKind[SyntaxKind["OrAssignmentExpression"] = 182] = "OrAssignmentExpression";
+ SyntaxKind[SyntaxKind["LeftShiftAssignmentExpression"] = 183] = "LeftShiftAssignmentExpression";
+ SyntaxKind[SyntaxKind["SignedRightShiftAssignmentExpression"] = 184] = "SignedRightShiftAssignmentExpression";
+ SyntaxKind[SyntaxKind["UnsignedRightShiftAssignmentExpression"] = 185] = "UnsignedRightShiftAssignmentExpression";
+ SyntaxKind[SyntaxKind["ConditionalExpression"] = 186] = "ConditionalExpression";
+ SyntaxKind[SyntaxKind["LogicalOrExpression"] = 187] = "LogicalOrExpression";
+ SyntaxKind[SyntaxKind["LogicalAndExpression"] = 188] = "LogicalAndExpression";
+ SyntaxKind[SyntaxKind["BitwiseOrExpression"] = 189] = "BitwiseOrExpression";
+ SyntaxKind[SyntaxKind["BitwiseExclusiveOrExpression"] = 190] = "BitwiseExclusiveOrExpression";
+ SyntaxKind[SyntaxKind["BitwiseAndExpression"] = 191] = "BitwiseAndExpression";
+ SyntaxKind[SyntaxKind["EqualsWithTypeConversionExpression"] = 192] = "EqualsWithTypeConversionExpression";
+ SyntaxKind[SyntaxKind["NotEqualsWithTypeConversionExpression"] = 193] = "NotEqualsWithTypeConversionExpression";
+ SyntaxKind[SyntaxKind["EqualsExpression"] = 194] = "EqualsExpression";
+ SyntaxKind[SyntaxKind["NotEqualsExpression"] = 195] = "NotEqualsExpression";
+ SyntaxKind[SyntaxKind["LessThanExpression"] = 196] = "LessThanExpression";
+ SyntaxKind[SyntaxKind["GreaterThanExpression"] = 197] = "GreaterThanExpression";
+ SyntaxKind[SyntaxKind["LessThanOrEqualExpression"] = 198] = "LessThanOrEqualExpression";
+ SyntaxKind[SyntaxKind["GreaterThanOrEqualExpression"] = 199] = "GreaterThanOrEqualExpression";
+ SyntaxKind[SyntaxKind["InstanceOfExpression"] = 200] = "InstanceOfExpression";
+ SyntaxKind[SyntaxKind["InExpression"] = 201] = "InExpression";
+ SyntaxKind[SyntaxKind["LeftShiftExpression"] = 202] = "LeftShiftExpression";
+ SyntaxKind[SyntaxKind["SignedRightShiftExpression"] = 203] = "SignedRightShiftExpression";
+ SyntaxKind[SyntaxKind["UnsignedRightShiftExpression"] = 204] = "UnsignedRightShiftExpression";
+ SyntaxKind[SyntaxKind["MultiplyExpression"] = 205] = "MultiplyExpression";
+ SyntaxKind[SyntaxKind["DivideExpression"] = 206] = "DivideExpression";
+ SyntaxKind[SyntaxKind["ModuloExpression"] = 207] = "ModuloExpression";
+ SyntaxKind[SyntaxKind["AddExpression"] = 208] = "AddExpression";
+ SyntaxKind[SyntaxKind["SubtractExpression"] = 209] = "SubtractExpression";
+ SyntaxKind[SyntaxKind["PostIncrementExpression"] = 210] = "PostIncrementExpression";
+ SyntaxKind[SyntaxKind["PostDecrementExpression"] = 211] = "PostDecrementExpression";
+ SyntaxKind[SyntaxKind["MemberAccessExpression"] = 212] = "MemberAccessExpression";
+ SyntaxKind[SyntaxKind["InvocationExpression"] = 213] = "InvocationExpression";
+ SyntaxKind[SyntaxKind["ArrayLiteralExpression"] = 214] = "ArrayLiteralExpression";
+ SyntaxKind[SyntaxKind["ObjectLiteralExpression"] = 215] = "ObjectLiteralExpression";
+ SyntaxKind[SyntaxKind["ObjectCreationExpression"] = 216] = "ObjectCreationExpression";
+ SyntaxKind[SyntaxKind["ParenthesizedExpression"] = 217] = "ParenthesizedExpression";
+ SyntaxKind[SyntaxKind["ParenthesizedArrowFunctionExpression"] = 218] = "ParenthesizedArrowFunctionExpression";
+ SyntaxKind[SyntaxKind["SimpleArrowFunctionExpression"] = 219] = "SimpleArrowFunctionExpression";
+ SyntaxKind[SyntaxKind["CastExpression"] = 220] = "CastExpression";
+ SyntaxKind[SyntaxKind["ElementAccessExpression"] = 221] = "ElementAccessExpression";
+ SyntaxKind[SyntaxKind["FunctionExpression"] = 222] = "FunctionExpression";
+ SyntaxKind[SyntaxKind["OmittedExpression"] = 223] = "OmittedExpression";
- SyntaxKind[SyntaxKind["VariableDeclaration"] = 223] = "VariableDeclaration";
- SyntaxKind[SyntaxKind["VariableDeclarator"] = 224] = "VariableDeclarator";
+ SyntaxKind[SyntaxKind["VariableDeclaration"] = 224] = "VariableDeclaration";
+ SyntaxKind[SyntaxKind["VariableDeclarator"] = 225] = "VariableDeclarator";
- SyntaxKind[SyntaxKind["ArgumentList"] = 225] = "ArgumentList";
- SyntaxKind[SyntaxKind["ParameterList"] = 226] = "ParameterList";
- SyntaxKind[SyntaxKind["TypeArgumentList"] = 227] = "TypeArgumentList";
- SyntaxKind[SyntaxKind["TypeParameterList"] = 228] = "TypeParameterList";
+ SyntaxKind[SyntaxKind["ArgumentList"] = 226] = "ArgumentList";
+ SyntaxKind[SyntaxKind["ParameterList"] = 227] = "ParameterList";
+ SyntaxKind[SyntaxKind["TypeArgumentList"] = 228] = "TypeArgumentList";
+ SyntaxKind[SyntaxKind["TypeParameterList"] = 229] = "TypeParameterList";
- SyntaxKind[SyntaxKind["HeritageClause"] = 229] = "HeritageClause";
- SyntaxKind[SyntaxKind["EqualsValueClause"] = 230] = "EqualsValueClause";
- SyntaxKind[SyntaxKind["CaseSwitchClause"] = 231] = "CaseSwitchClause";
- SyntaxKind[SyntaxKind["DefaultSwitchClause"] = 232] = "DefaultSwitchClause";
- SyntaxKind[SyntaxKind["ElseClause"] = 233] = "ElseClause";
- SyntaxKind[SyntaxKind["CatchClause"] = 234] = "CatchClause";
- SyntaxKind[SyntaxKind["FinallyClause"] = 235] = "FinallyClause";
+ SyntaxKind[SyntaxKind["HeritageClause"] = 230] = "HeritageClause";
+ SyntaxKind[SyntaxKind["EqualsValueClause"] = 231] = "EqualsValueClause";
+ SyntaxKind[SyntaxKind["CaseSwitchClause"] = 232] = "CaseSwitchClause";
+ SyntaxKind[SyntaxKind["DefaultSwitchClause"] = 233] = "DefaultSwitchClause";
+ SyntaxKind[SyntaxKind["ElseClause"] = 234] = "ElseClause";
+ SyntaxKind[SyntaxKind["CatchClause"] = 235] = "CatchClause";
+ SyntaxKind[SyntaxKind["FinallyClause"] = 236] = "FinallyClause";
- SyntaxKind[SyntaxKind["TypeParameter"] = 236] = "TypeParameter";
- SyntaxKind[SyntaxKind["Constraint"] = 237] = "Constraint";
+ SyntaxKind[SyntaxKind["TypeParameter"] = 237] = "TypeParameter";
+ SyntaxKind[SyntaxKind["Constraint"] = 238] = "Constraint";
- SyntaxKind[SyntaxKind["SimplePropertyAssignment"] = 238] = "SimplePropertyAssignment";
- SyntaxKind[SyntaxKind["GetAccessorPropertyAssignment"] = 239] = "GetAccessorPropertyAssignment";
- SyntaxKind[SyntaxKind["SetAccessorPropertyAssignment"] = 240] = "SetAccessorPropertyAssignment";
- SyntaxKind[SyntaxKind["FunctionPropertyAssignment"] = 241] = "FunctionPropertyAssignment";
+ SyntaxKind[SyntaxKind["SimplePropertyAssignment"] = 239] = "SimplePropertyAssignment";
+ SyntaxKind[SyntaxKind["GetAccessorPropertyAssignment"] = 240] = "GetAccessorPropertyAssignment";
+ SyntaxKind[SyntaxKind["SetAccessorPropertyAssignment"] = 241] = "SetAccessorPropertyAssignment";
+ SyntaxKind[SyntaxKind["FunctionPropertyAssignment"] = 242] = "FunctionPropertyAssignment";
- SyntaxKind[SyntaxKind["Parameter"] = 242] = "Parameter";
- SyntaxKind[SyntaxKind["EnumElement"] = 243] = "EnumElement";
- SyntaxKind[SyntaxKind["TypeAnnotation"] = 244] = "TypeAnnotation";
- SyntaxKind[SyntaxKind["ExternalModuleReference"] = 245] = "ExternalModuleReference";
- SyntaxKind[SyntaxKind["ModuleNameModuleReference"] = 246] = "ModuleNameModuleReference";
+ SyntaxKind[SyntaxKind["Parameter"] = 243] = "Parameter";
+ SyntaxKind[SyntaxKind["EnumElement"] = 244] = "EnumElement";
+ SyntaxKind[SyntaxKind["TypeAnnotation"] = 245] = "TypeAnnotation";
+ SyntaxKind[SyntaxKind["ExternalModuleReference"] = 246] = "ExternalModuleReference";
+ SyntaxKind[SyntaxKind["ModuleNameModuleReference"] = 247] = "ModuleNameModuleReference";
SyntaxKind[SyntaxKind["FirstStandardKeyword"] = SyntaxKind.BreakKeyword] = "FirstStandardKeyword";
SyntaxKind[SyntaxKind["LastStandardKeyword"] = SyntaxKind.WithKeyword] = "LastStandardKeyword";
@@ -4989,6 +5054,7 @@ var TypeScript;
(function (SyntaxFacts) {
var textToKeywordKind = {
"any": 60 /* AnyKeyword */,
+ "bool": 62 /* BoolKeyword */,
"boolean": 61 /* BooleanKeyword */,
"break": 15 /* BreakKeyword */,
"case": 16 /* CaseKeyword */,
@@ -4996,9 +5062,9 @@ var TypeScript;
"class": 44 /* ClassKeyword */,
"continue": 18 /* ContinueKeyword */,
"const": 45 /* ConstKeyword */,
- "constructor": 62 /* ConstructorKeyword */,
+ "constructor": 63 /* ConstructorKeyword */,
"debugger": 19 /* DebuggerKeyword */,
- "declare": 63 /* DeclareKeyword */,
+ "declare": 64 /* DeclareKeyword */,
"default": 20 /* DefaultKeyword */,
"delete": 21 /* DeleteKeyword */,
"do": 22 /* DoKeyword */,
@@ -5010,7 +5076,7 @@ var TypeScript;
"finally": 25 /* FinallyKeyword */,
"for": 26 /* ForKeyword */,
"function": 27 /* FunctionKeyword */,
- "get": 64 /* GetKeyword */,
+ "get": 65 /* GetKeyword */,
"if": 28 /* IfKeyword */,
"implements": 51 /* ImplementsKeyword */,
"import": 49 /* ImportKeyword */,
@@ -5018,19 +5084,19 @@ var TypeScript;
"instanceof": 30 /* InstanceOfKeyword */,
"interface": 52 /* InterfaceKeyword */,
"let": 53 /* LetKeyword */,
- "module": 65 /* ModuleKeyword */,
+ "module": 66 /* ModuleKeyword */,
"new": 31 /* NewKeyword */,
"null": 32 /* NullKeyword */,
- "number": 67 /* NumberKeyword */,
+ "number": 68 /* NumberKeyword */,
"package": 54 /* PackageKeyword */,
"private": 55 /* PrivateKeyword */,
"protected": 56 /* ProtectedKeyword */,
"public": 57 /* PublicKeyword */,
- "require": 66 /* RequireKeyword */,
+ "require": 67 /* RequireKeyword */,
"return": 33 /* ReturnKeyword */,
- "set": 68 /* SetKeyword */,
+ "set": 69 /* SetKeyword */,
"static": 58 /* StaticKeyword */,
- "string": 69 /* StringKeyword */,
+ "string": 70 /* StringKeyword */,
"super": 50 /* SuperKeyword */,
"switch": 34 /* SwitchKeyword */,
"this": 35 /* ThisKeyword */,
@@ -5043,56 +5109,56 @@ var TypeScript;
"while": 42 /* WhileKeyword */,
"with": 43 /* WithKeyword */,
"yield": 59 /* YieldKeyword */,
- "{": 70 /* OpenBraceToken */,
- "}": 71 /* CloseBraceToken */,
- "(": 72 /* OpenParenToken */,
- ")": 73 /* CloseParenToken */,
- "[": 74 /* OpenBracketToken */,
- "]": 75 /* CloseBracketToken */,
- ".": 76 /* DotToken */,
- "...": 77 /* DotDotDotToken */,
- ";": 78 /* SemicolonToken */,
- ",": 79 /* CommaToken */,
- "<": 80 /* LessThanToken */,
- ">": 81 /* GreaterThanToken */,
- "<=": 82 /* LessThanEqualsToken */,
- ">=": 83 /* GreaterThanEqualsToken */,
- "==": 84 /* EqualsEqualsToken */,
- "=>": 85 /* EqualsGreaterThanToken */,
- "!=": 86 /* ExclamationEqualsToken */,
- "===": 87 /* EqualsEqualsEqualsToken */,
- "!==": 88 /* ExclamationEqualsEqualsToken */,
- "+": 89 /* PlusToken */,
- "-": 90 /* MinusToken */,
- "*": 91 /* AsteriskToken */,
- "%": 92 /* PercentToken */,
- "++": 93 /* PlusPlusToken */,
- "--": 94 /* MinusMinusToken */,
- "<<": 95 /* LessThanLessThanToken */,
- ">>": 96 /* GreaterThanGreaterThanToken */,
- ">>>": 97 /* GreaterThanGreaterThanGreaterThanToken */,
- "&": 98 /* AmpersandToken */,
- "|": 99 /* BarToken */,
- "^": 100 /* CaretToken */,
- "!": 101 /* ExclamationToken */,
- "~": 102 /* TildeToken */,
- "&&": 103 /* AmpersandAmpersandToken */,
- "||": 104 /* BarBarToken */,
- "?": 105 /* QuestionToken */,
- ":": 106 /* ColonToken */,
- "=": 107 /* EqualsToken */,
- "+=": 108 /* PlusEqualsToken */,
- "-=": 109 /* MinusEqualsToken */,
- "*=": 110 /* AsteriskEqualsToken */,
- "%=": 111 /* PercentEqualsToken */,
- "<<=": 112 /* LessThanLessThanEqualsToken */,
- ">>=": 113 /* GreaterThanGreaterThanEqualsToken */,
- ">>>=": 114 /* GreaterThanGreaterThanGreaterThanEqualsToken */,
- "&=": 115 /* AmpersandEqualsToken */,
- "|=": 116 /* BarEqualsToken */,
- "^=": 117 /* CaretEqualsToken */,
- "/": 118 /* SlashToken */,
- "/=": 119 /* SlashEqualsToken */
+ "{": 71 /* OpenBraceToken */,
+ "}": 72 /* CloseBraceToken */,
+ "(": 73 /* OpenParenToken */,
+ ")": 74 /* CloseParenToken */,
+ "[": 75 /* OpenBracketToken */,
+ "]": 76 /* CloseBracketToken */,
+ ".": 77 /* DotToken */,
+ "...": 78 /* DotDotDotToken */,
+ ";": 79 /* SemicolonToken */,
+ ",": 80 /* CommaToken */,
+ "<": 81 /* LessThanToken */,
+ ">": 82 /* GreaterThanToken */,
+ "<=": 83 /* LessThanEqualsToken */,
+ ">=": 84 /* GreaterThanEqualsToken */,
+ "==": 85 /* EqualsEqualsToken */,
+ "=>": 86 /* EqualsGreaterThanToken */,
+ "!=": 87 /* ExclamationEqualsToken */,
+ "===": 88 /* EqualsEqualsEqualsToken */,
+ "!==": 89 /* ExclamationEqualsEqualsToken */,
+ "+": 90 /* PlusToken */,
+ "-": 91 /* MinusToken */,
+ "*": 92 /* AsteriskToken */,
+ "%": 93 /* PercentToken */,
+ "++": 94 /* PlusPlusToken */,
+ "--": 95 /* MinusMinusToken */,
+ "<<": 96 /* LessThanLessThanToken */,
+ ">>": 97 /* GreaterThanGreaterThanToken */,
+ ">>>": 98 /* GreaterThanGreaterThanGreaterThanToken */,
+ "&": 99 /* AmpersandToken */,
+ "|": 100 /* BarToken */,
+ "^": 101 /* CaretToken */,
+ "!": 102 /* ExclamationToken */,
+ "~": 103 /* TildeToken */,
+ "&&": 104 /* AmpersandAmpersandToken */,
+ "||": 105 /* BarBarToken */,
+ "?": 106 /* QuestionToken */,
+ ":": 107 /* ColonToken */,
+ "=": 108 /* EqualsToken */,
+ "+=": 109 /* PlusEqualsToken */,
+ "-=": 110 /* MinusEqualsToken */,
+ "*=": 111 /* AsteriskEqualsToken */,
+ "%=": 112 /* PercentEqualsToken */,
+ "<<=": 113 /* LessThanLessThanEqualsToken */,
+ ">>=": 114 /* GreaterThanGreaterThanEqualsToken */,
+ ">>>=": 115 /* GreaterThanGreaterThanGreaterThanEqualsToken */,
+ "&=": 116 /* AmpersandEqualsToken */,
+ "|=": 117 /* BarEqualsToken */,
+ "^=": 118 /* CaretEqualsToken */,
+ "/": 119 /* SlashToken */,
+ "/=": 120 /* SlashEqualsToken */
};
var kindToText = new Array();
@@ -5103,7 +5169,7 @@ var TypeScript;
}
}
- kindToText[62 /* ConstructorKeyword */] = "constructor";
+ kindToText[63 /* ConstructorKeyword */] = "constructor";
function getTokenKind(text) {
if (textToKeywordKind.hasOwnProperty(text)) {
@@ -5121,12 +5187,12 @@ var TypeScript;
SyntaxFacts.getText = getText;
function isTokenKind(kind) {
- return kind >= 9 /* FirstToken */ && kind <= 119 /* LastToken */;
+ return kind >= 9 /* FirstToken */ && kind <= 120 /* LastToken */;
}
SyntaxFacts.isTokenKind = isTokenKind;
function isAnyKeyword(kind) {
- return kind >= 15 /* FirstKeyword */ && kind <= 69 /* LastKeyword */;
+ return kind >= 15 /* FirstKeyword */ && kind <= 70 /* LastKeyword */;
}
SyntaxFacts.isAnyKeyword = isAnyKeyword;
@@ -5146,7 +5212,7 @@ var TypeScript;
SyntaxFacts.isFutureReservedStrictKeyword = isFutureReservedStrictKeyword;
function isAnyPunctuation(kind) {
- return kind >= 70 /* FirstPunctuation */ && kind <= 119 /* LastPunctuation */;
+ return kind >= 71 /* FirstPunctuation */ && kind <= 120 /* LastPunctuation */;
}
SyntaxFacts.isAnyPunctuation = isAnyPunctuation;
@@ -5162,18 +5228,18 @@ var TypeScript;
function getPrefixUnaryExpressionFromOperatorToken(tokenKind) {
switch (tokenKind) {
- case 89 /* PlusToken */:
- return 163 /* PlusExpression */;
- case 90 /* MinusToken */:
- return 164 /* NegateExpression */;
- case 102 /* TildeToken */:
- return 165 /* BitwiseNotExpression */;
- case 101 /* ExclamationToken */:
- return 166 /* LogicalNotExpression */;
- case 93 /* PlusPlusToken */:
- return 167 /* PreIncrementExpression */;
- case 94 /* MinusMinusToken */:
- return 168 /* PreDecrementExpression */;
+ case 90 /* PlusToken */:
+ return 164 /* PlusExpression */;
+ case 91 /* MinusToken */:
+ return 165 /* NegateExpression */;
+ case 103 /* TildeToken */:
+ return 166 /* BitwiseNotExpression */;
+ case 102 /* ExclamationToken */:
+ return 167 /* LogicalNotExpression */;
+ case 94 /* PlusPlusToken */:
+ return 168 /* PreIncrementExpression */;
+ case 95 /* MinusMinusToken */:
+ return 169 /* PreDecrementExpression */;
default:
return 0 /* None */;
@@ -5183,10 +5249,10 @@ var TypeScript;
function getPostfixUnaryExpressionFromOperatorToken(tokenKind) {
switch (tokenKind) {
- case 93 /* PlusPlusToken */:
- return 209 /* PostIncrementExpression */;
- case 94 /* MinusMinusToken */:
- return 210 /* PostDecrementExpression */;
+ case 94 /* PlusPlusToken */:
+ return 210 /* PostIncrementExpression */;
+ case 95 /* MinusMinusToken */:
+ return 211 /* PostDecrementExpression */;
default:
return 0 /* None */;
}
@@ -5195,113 +5261,113 @@ var TypeScript;
function getBinaryExpressionFromOperatorToken(tokenKind) {
switch (tokenKind) {
- case 91 /* AsteriskToken */:
- return 204 /* MultiplyExpression */;
+ case 92 /* AsteriskToken */:
+ return 205 /* MultiplyExpression */;
- case 118 /* SlashToken */:
- return 205 /* DivideExpression */;
+ case 119 /* SlashToken */:
+ return 206 /* DivideExpression */;
- case 92 /* PercentToken */:
- return 206 /* ModuloExpression */;
+ case 93 /* PercentToken */:
+ return 207 /* ModuloExpression */;
- case 89 /* PlusToken */:
- return 207 /* AddExpression */;
+ case 90 /* PlusToken */:
+ return 208 /* AddExpression */;
- case 90 /* MinusToken */:
- return 208 /* SubtractExpression */;
+ case 91 /* MinusToken */:
+ return 209 /* SubtractExpression */;
- case 95 /* LessThanLessThanToken */:
- return 201 /* LeftShiftExpression */;
+ case 96 /* LessThanLessThanToken */:
+ return 202 /* LeftShiftExpression */;
- case 96 /* GreaterThanGreaterThanToken */:
- return 202 /* SignedRightShiftExpression */;
+ case 97 /* GreaterThanGreaterThanToken */:
+ return 203 /* SignedRightShiftExpression */;
- case 97 /* GreaterThanGreaterThanGreaterThanToken */:
- return 203 /* UnsignedRightShiftExpression */;
+ case 98 /* GreaterThanGreaterThanGreaterThanToken */:
+ return 204 /* UnsignedRightShiftExpression */;
- case 80 /* LessThanToken */:
- return 195 /* LessThanExpression */;
+ case 81 /* LessThanToken */:
+ return 196 /* LessThanExpression */;
- case 81 /* GreaterThanToken */:
- return 196 /* GreaterThanExpression */;
+ case 82 /* GreaterThanToken */:
+ return 197 /* GreaterThanExpression */;
- case 82 /* LessThanEqualsToken */:
- return 197 /* LessThanOrEqualExpression */;
+ case 83 /* LessThanEqualsToken */:
+ return 198 /* LessThanOrEqualExpression */;
- case 83 /* GreaterThanEqualsToken */:
- return 198 /* GreaterThanOrEqualExpression */;
+ case 84 /* GreaterThanEqualsToken */:
+ return 199 /* GreaterThanOrEqualExpression */;
case 30 /* InstanceOfKeyword */:
- return 199 /* InstanceOfExpression */;
+ return 200 /* InstanceOfExpression */;
case 29 /* InKeyword */:
- return 200 /* InExpression */;
+ return 201 /* InExpression */;
- case 84 /* EqualsEqualsToken */:
- return 191 /* EqualsWithTypeConversionExpression */;
+ case 85 /* EqualsEqualsToken */:
+ return 192 /* EqualsWithTypeConversionExpression */;
- case 86 /* ExclamationEqualsToken */:
- return 192 /* NotEqualsWithTypeConversionExpression */;
+ case 87 /* ExclamationEqualsToken */:
+ return 193 /* NotEqualsWithTypeConversionExpression */;
- case 87 /* EqualsEqualsEqualsToken */:
- return 193 /* EqualsExpression */;
+ case 88 /* EqualsEqualsEqualsToken */:
+ return 194 /* EqualsExpression */;
- case 88 /* ExclamationEqualsEqualsToken */:
- return 194 /* NotEqualsExpression */;
+ case 89 /* ExclamationEqualsEqualsToken */:
+ return 195 /* NotEqualsExpression */;
- case 98 /* AmpersandToken */:
- return 190 /* BitwiseAndExpression */;
+ case 99 /* AmpersandToken */:
+ return 191 /* BitwiseAndExpression */;
- case 100 /* CaretToken */:
- return 189 /* BitwiseExclusiveOrExpression */;
+ case 101 /* CaretToken */:
+ return 190 /* BitwiseExclusiveOrExpression */;
- case 99 /* BarToken */:
- return 188 /* BitwiseOrExpression */;
+ case 100 /* BarToken */:
+ return 189 /* BitwiseOrExpression */;
- case 103 /* AmpersandAmpersandToken */:
- return 187 /* LogicalAndExpression */;
+ case 104 /* AmpersandAmpersandToken */:
+ return 188 /* LogicalAndExpression */;
- case 104 /* BarBarToken */:
- return 186 /* LogicalOrExpression */;
+ case 105 /* BarBarToken */:
+ return 187 /* LogicalOrExpression */;
- case 116 /* BarEqualsToken */:
- return 181 /* OrAssignmentExpression */;
+ case 117 /* BarEqualsToken */:
+ return 182 /* OrAssignmentExpression */;
- case 115 /* AmpersandEqualsToken */:
- return 179 /* AndAssignmentExpression */;
+ case 116 /* AmpersandEqualsToken */:
+ return 180 /* AndAssignmentExpression */;
- case 117 /* CaretEqualsToken */:
- return 180 /* ExclusiveOrAssignmentExpression */;
+ case 118 /* CaretEqualsToken */:
+ return 181 /* ExclusiveOrAssignmentExpression */;
- case 112 /* LessThanLessThanEqualsToken */:
- return 182 /* LeftShiftAssignmentExpression */;
+ case 113 /* LessThanLessThanEqualsToken */:
+ return 183 /* LeftShiftAssignmentExpression */;
- case 113 /* GreaterThanGreaterThanEqualsToken */:
- return 183 /* SignedRightShiftAssignmentExpression */;
+ case 114 /* GreaterThanGreaterThanEqualsToken */:
+ return 184 /* SignedRightShiftAssignmentExpression */;
- case 114 /* GreaterThanGreaterThanGreaterThanEqualsToken */:
- return 184 /* UnsignedRightShiftAssignmentExpression */;
+ case 115 /* GreaterThanGreaterThanGreaterThanEqualsToken */:
+ return 185 /* UnsignedRightShiftAssignmentExpression */;
- case 108 /* PlusEqualsToken */:
- return 174 /* AddAssignmentExpression */;
+ case 109 /* PlusEqualsToken */:
+ return 175 /* AddAssignmentExpression */;
- case 109 /* MinusEqualsToken */:
- return 175 /* SubtractAssignmentExpression */;
+ case 110 /* MinusEqualsToken */:
+ return 176 /* SubtractAssignmentExpression */;
- case 110 /* AsteriskEqualsToken */:
- return 176 /* MultiplyAssignmentExpression */;
+ case 111 /* AsteriskEqualsToken */:
+ return 177 /* MultiplyAssignmentExpression */;
- case 119 /* SlashEqualsToken */:
- return 177 /* DivideAssignmentExpression */;
+ case 120 /* SlashEqualsToken */:
+ return 178 /* DivideAssignmentExpression */;
- case 111 /* PercentEqualsToken */:
- return 178 /* ModuloAssignmentExpression */;
+ case 112 /* PercentEqualsToken */:
+ return 179 /* ModuloAssignmentExpression */;
- case 107 /* EqualsToken */:
- return 173 /* AssignmentExpression */;
+ case 108 /* EqualsToken */:
+ return 174 /* AssignmentExpression */;
- case 79 /* CommaToken */:
- return 172 /* CommaExpression */;
+ case 80 /* CommaToken */:
+ return 173 /* CommaExpression */;
default:
return 0 /* None */;
@@ -5311,8 +5377,8 @@ var TypeScript;
function isAnyDivideToken(kind) {
switch (kind) {
- case 118 /* SlashToken */:
- case 119 /* SlashEqualsToken */:
+ case 119 /* SlashToken */:
+ case 120 /* SlashEqualsToken */:
return true;
default:
return false;
@@ -5322,8 +5388,8 @@ var TypeScript;
function isAnyDivideOrRegularExpressionToken(kind) {
switch (kind) {
- case 118 /* SlashToken */:
- case 119 /* SlashEqualsToken */:
+ case 119 /* SlashToken */:
+ case 120 /* SlashEqualsToken */:
case 12 /* RegularExpressionLiteral */:
return true;
default:
@@ -5334,11 +5400,11 @@ var TypeScript;
function isParserGenerated(kind) {
switch (kind) {
- case 96 /* GreaterThanGreaterThanToken */:
- case 97 /* GreaterThanGreaterThanGreaterThanToken */:
- case 83 /* GreaterThanEqualsToken */:
- case 113 /* GreaterThanGreaterThanEqualsToken */:
- case 114 /* GreaterThanGreaterThanGreaterThanEqualsToken */:
+ case 97 /* GreaterThanGreaterThanToken */:
+ case 98 /* GreaterThanGreaterThanGreaterThanToken */:
+ case 84 /* GreaterThanEqualsToken */:
+ case 114 /* GreaterThanGreaterThanEqualsToken */:
+ case 115 /* GreaterThanGreaterThanGreaterThanEqualsToken */:
return true;
default:
return false;
@@ -5348,42 +5414,42 @@ var TypeScript;
function isAnyBinaryExpression(kind) {
switch (kind) {
- case 172 /* CommaExpression */:
- case 173 /* AssignmentExpression */:
- case 174 /* AddAssignmentExpression */:
- case 175 /* SubtractAssignmentExpression */:
- case 176 /* MultiplyAssignmentExpression */:
- case 177 /* DivideAssignmentExpression */:
- case 178 /* ModuloAssignmentExpression */:
- case 179 /* AndAssignmentExpression */:
- case 180 /* ExclusiveOrAssignmentExpression */:
- case 181 /* OrAssignmentExpression */:
- case 182 /* LeftShiftAssignmentExpression */:
- case 183 /* SignedRightShiftAssignmentExpression */:
- case 184 /* UnsignedRightShiftAssignmentExpression */:
- case 186 /* LogicalOrExpression */:
- case 187 /* LogicalAndExpression */:
- case 188 /* BitwiseOrExpression */:
- case 189 /* BitwiseExclusiveOrExpression */:
- case 190 /* BitwiseAndExpression */:
- case 191 /* EqualsWithTypeConversionExpression */:
- case 192 /* NotEqualsWithTypeConversionExpression */:
- case 193 /* EqualsExpression */:
- case 194 /* NotEqualsExpression */:
- case 195 /* LessThanExpression */:
- case 196 /* GreaterThanExpression */:
- case 197 /* LessThanOrEqualExpression */:
- case 198 /* GreaterThanOrEqualExpression */:
- case 199 /* InstanceOfExpression */:
- case 200 /* InExpression */:
- case 201 /* LeftShiftExpression */:
- case 202 /* SignedRightShiftExpression */:
- case 203 /* UnsignedRightShiftExpression */:
- case 204 /* MultiplyExpression */:
- case 205 /* DivideExpression */:
- case 206 /* ModuloExpression */:
- case 207 /* AddExpression */:
- case 208 /* SubtractExpression */:
+ case 173 /* CommaExpression */:
+ case 174 /* AssignmentExpression */:
+ case 175 /* AddAssignmentExpression */:
+ case 176 /* SubtractAssignmentExpression */:
+ case 177 /* MultiplyAssignmentExpression */:
+ case 178 /* DivideAssignmentExpression */:
+ case 179 /* ModuloAssignmentExpression */:
+ case 180 /* AndAssignmentExpression */:
+ case 181 /* ExclusiveOrAssignmentExpression */:
+ case 182 /* OrAssignmentExpression */:
+ case 183 /* LeftShiftAssignmentExpression */:
+ case 184 /* SignedRightShiftAssignmentExpression */:
+ case 185 /* UnsignedRightShiftAssignmentExpression */:
+ case 187 /* LogicalOrExpression */:
+ case 188 /* LogicalAndExpression */:
+ case 189 /* BitwiseOrExpression */:
+ case 190 /* BitwiseExclusiveOrExpression */:
+ case 191 /* BitwiseAndExpression */:
+ case 192 /* EqualsWithTypeConversionExpression */:
+ case 193 /* NotEqualsWithTypeConversionExpression */:
+ case 194 /* EqualsExpression */:
+ case 195 /* NotEqualsExpression */:
+ case 196 /* LessThanExpression */:
+ case 197 /* GreaterThanExpression */:
+ case 198 /* LessThanOrEqualExpression */:
+ case 199 /* GreaterThanOrEqualExpression */:
+ case 200 /* InstanceOfExpression */:
+ case 201 /* InExpression */:
+ case 202 /* LeftShiftExpression */:
+ case 203 /* SignedRightShiftExpression */:
+ case 204 /* UnsignedRightShiftExpression */:
+ case 205 /* MultiplyExpression */:
+ case 206 /* DivideExpression */:
+ case 207 /* ModuloExpression */:
+ case 208 /* AddExpression */:
+ case 209 /* SubtractExpression */:
return true;
}
@@ -5415,7 +5481,7 @@ var TypeScript;
isNumericLiteralStart[46 /* dot */] = true;
- for (var keywordKind = 15 /* FirstKeyword */; keywordKind <= 69 /* LastKeyword */; keywordKind++) {
+ for (var keywordKind = 15 /* FirstKeyword */; keywordKind <= 70 /* LastKeyword */; keywordKind++) {
var keyword = TypeScript.SyntaxFacts.getText(keywordKind);
isKeywordStartCharacter[keyword.charCodeAt(0)] = true;
}
@@ -5822,40 +5888,40 @@ var TypeScript;
return this.scanLessThanToken();
case 62 /* greaterThan */:
- return this.advanceAndSetTokenKind(81 /* GreaterThanToken */);
+ return this.advanceAndSetTokenKind(82 /* GreaterThanToken */);
case 44 /* comma */:
- return this.advanceAndSetTokenKind(79 /* CommaToken */);
+ return this.advanceAndSetTokenKind(80 /* CommaToken */);
case 58 /* colon */:
- return this.advanceAndSetTokenKind(106 /* ColonToken */);
+ return this.advanceAndSetTokenKind(107 /* ColonToken */);
case 59 /* semicolon */:
- return this.advanceAndSetTokenKind(78 /* SemicolonToken */);
+ return this.advanceAndSetTokenKind(79 /* SemicolonToken */);
case 126 /* tilde */:
- return this.advanceAndSetTokenKind(102 /* TildeToken */);
+ return this.advanceAndSetTokenKind(103 /* TildeToken */);
case 40 /* openParen */:
- return this.advanceAndSetTokenKind(72 /* OpenParenToken */);
+ return this.advanceAndSetTokenKind(73 /* OpenParenToken */);
case 41 /* closeParen */:
- return this.advanceAndSetTokenKind(73 /* CloseParenToken */);
+ return this.advanceAndSetTokenKind(74 /* CloseParenToken */);
case 123 /* openBrace */:
- return this.advanceAndSetTokenKind(70 /* OpenBraceToken */);
+ return this.advanceAndSetTokenKind(71 /* OpenBraceToken */);
case 125 /* closeBrace */:
- return this.advanceAndSetTokenKind(71 /* CloseBraceToken */);
+ return this.advanceAndSetTokenKind(72 /* CloseBraceToken */);
case 91 /* openBracket */:
- return this.advanceAndSetTokenKind(74 /* OpenBracketToken */);
+ return this.advanceAndSetTokenKind(75 /* OpenBracketToken */);
case 93 /* closeBracket */:
- return this.advanceAndSetTokenKind(75 /* CloseBracketToken */);
+ return this.advanceAndSetTokenKind(76 /* CloseBracketToken */);
case 63 /* question */:
- return this.advanceAndSetTokenKind(105 /* QuestionToken */);
+ return this.advanceAndSetTokenKind(106 /* QuestionToken */);
}
if (isNumericLiteralStart[character]) {
@@ -6004,17 +6070,17 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 82 /* LessThanEqualsToken */;
+ return 83 /* LessThanEqualsToken */;
} else if (this.currentCharCode() === 60 /* lessThan */) {
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 112 /* LessThanLessThanEqualsToken */;
+ return 113 /* LessThanLessThanEqualsToken */;
} else {
- return 95 /* LessThanLessThanToken */;
+ return 96 /* LessThanLessThanToken */;
}
} else {
- return 80 /* LessThanToken */;
+ return 81 /* LessThanToken */;
}
};
@@ -6022,12 +6088,12 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 116 /* BarEqualsToken */;
+ return 117 /* BarEqualsToken */;
} else if (this.currentCharCode() === 124 /* bar */) {
this.slidingWindow.moveToNextItem();
- return 104 /* BarBarToken */;
+ return 105 /* BarBarToken */;
} else {
- return 99 /* BarToken */;
+ return 100 /* BarToken */;
}
};
@@ -6035,9 +6101,9 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 117 /* CaretEqualsToken */;
+ return 118 /* CaretEqualsToken */;
} else {
- return 100 /* CaretToken */;
+ return 101 /* CaretToken */;
}
};
@@ -6046,12 +6112,12 @@ var TypeScript;
var character = this.currentCharCode();
if (character === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 115 /* AmpersandEqualsToken */;
+ return 116 /* AmpersandEqualsToken */;
} else if (this.currentCharCode() === 38 /* ampersand */) {
this.slidingWindow.moveToNextItem();
- return 103 /* AmpersandAmpersandToken */;
+ return 104 /* AmpersandAmpersandToken */;
} else {
- return 98 /* AmpersandToken */;
+ return 99 /* AmpersandToken */;
}
};
@@ -6059,9 +6125,9 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 111 /* PercentEqualsToken */;
+ return 112 /* PercentEqualsToken */;
} else {
- return 92 /* PercentToken */;
+ return 93 /* PercentToken */;
}
};
@@ -6071,12 +6137,12 @@ var TypeScript;
if (character === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 109 /* MinusEqualsToken */;
+ return 110 /* MinusEqualsToken */;
} else if (character === 45 /* minus */) {
this.slidingWindow.moveToNextItem();
- return 94 /* MinusMinusToken */;
+ return 95 /* MinusMinusToken */;
} else {
- return 90 /* MinusToken */;
+ return 91 /* MinusToken */;
}
};
@@ -6085,12 +6151,12 @@ var TypeScript;
var character = this.currentCharCode();
if (character === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 108 /* PlusEqualsToken */;
+ return 109 /* PlusEqualsToken */;
} else if (character === 43 /* plus */) {
this.slidingWindow.moveToNextItem();
- return 93 /* PlusPlusToken */;
+ return 94 /* PlusPlusToken */;
} else {
- return 89 /* PlusToken */;
+ return 90 /* PlusToken */;
}
};
@@ -6098,9 +6164,9 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 110 /* AsteriskEqualsToken */;
+ return 111 /* AsteriskEqualsToken */;
} else {
- return 91 /* AsteriskToken */;
+ return 92 /* AsteriskToken */;
}
};
@@ -6113,15 +6179,15 @@ var TypeScript;
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 87 /* EqualsEqualsEqualsToken */;
+ return 88 /* EqualsEqualsEqualsToken */;
} else {
- return 84 /* EqualsEqualsToken */;
+ return 85 /* EqualsEqualsToken */;
}
} else if (character === 62 /* greaterThan */) {
this.slidingWindow.moveToNextItem();
- return 85 /* EqualsGreaterThanToken */;
+ return 86 /* EqualsGreaterThanToken */;
} else {
- return 107 /* EqualsToken */;
+ return 108 /* EqualsToken */;
}
};
@@ -6143,9 +6209,9 @@ var TypeScript;
if (this.currentCharCode() === 46 /* dot */ && this.slidingWindow.peekItemN(1) === 46 /* dot */) {
this.slidingWindow.moveToNextItem();
this.slidingWindow.moveToNextItem();
- return 77 /* DotDotDotToken */;
+ return 78 /* DotDotDotToken */;
} else {
- return 76 /* DotToken */;
+ return 77 /* DotToken */;
}
};
@@ -6160,9 +6226,9 @@ var TypeScript;
this.slidingWindow.moveToNextItem();
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 119 /* SlashEqualsToken */;
+ return 120 /* SlashEqualsToken */;
} else {
- return 118 /* SlashToken */;
+ return 119 /* SlashToken */;
}
};
@@ -6231,12 +6297,12 @@ var TypeScript;
if (this.currentCharCode() === 61 /* equals */) {
this.slidingWindow.moveToNextItem();
- return 88 /* ExclamationEqualsEqualsToken */;
+ return 89 /* ExclamationEqualsEqualsToken */;
} else {
- return 86 /* ExclamationEqualsToken */;
+ return 87 /* ExclamationEqualsToken */;
}
} else {
- return 101 /* ExclamationToken */;
+ return 102 /* ExclamationToken */;
}
};
@@ -6490,9 +6556,9 @@ var TypeScript;
case 97 /* a */:
return (array[startIndex + 1] === 110 /* n */ && array[startIndex + 2] === 121 /* y */) ? 60 /* AnyKeyword */ : 11 /* IdentifierName */;
case 103 /* g */:
- return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 116 /* t */) ? 64 /* GetKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 116 /* t */) ? 65 /* GetKeyword */ : 11 /* IdentifierName */;
case 115 /* s */:
- return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 116 /* t */) ? 68 /* SetKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 116 /* t */) ? 69 /* SetKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6527,6 +6593,8 @@ var TypeScript;
return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 105 /* i */ && array[startIndex + 3] === 100 /* d */) ? 41 /* VoidKeyword */ : 11 /* IdentifierName */;
case 119 /* w */:
return (array[startIndex + 1] === 105 /* i */ && array[startIndex + 2] === 116 /* t */ && array[startIndex + 3] === 104 /* h */) ? 43 /* WithKeyword */ : 11 /* IdentifierName */;
+ case 98 /* b */:
+ return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 111 /* o */ && array[startIndex + 3] === 108 /* l */) ? 62 /* BoolKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6576,7 +6644,7 @@ var TypeScript;
case 97 /* a */:
return (array[startIndex + 3] === 116 /* t */ && array[startIndex + 4] === 105 /* i */ && array[startIndex + 5] === 99 /* c */) ? 58 /* StaticKeyword */ : 11 /* IdentifierName */;
case 114 /* r */:
- return (array[startIndex + 3] === 105 /* i */ && array[startIndex + 4] === 110 /* n */ && array[startIndex + 5] === 103 /* g */) ? 69 /* StringKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 3] === 105 /* i */ && array[startIndex + 4] === 110 /* n */ && array[startIndex + 5] === 103 /* g */) ? 70 /* StringKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6594,9 +6662,9 @@ var TypeScript;
case 112 /* p */:
return (array[startIndex + 1] === 117 /* u */ && array[startIndex + 2] === 98 /* b */ && array[startIndex + 3] === 108 /* l */ && array[startIndex + 4] === 105 /* i */ && array[startIndex + 5] === 99 /* c */) ? 57 /* PublicKeyword */ : 11 /* IdentifierName */;
case 109 /* m */:
- return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 100 /* d */ && array[startIndex + 3] === 117 /* u */ && array[startIndex + 4] === 108 /* l */ && array[startIndex + 5] === 101 /* e */) ? 65 /* ModuleKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 100 /* d */ && array[startIndex + 3] === 117 /* u */ && array[startIndex + 4] === 108 /* l */ && array[startIndex + 5] === 101 /* e */) ? 66 /* ModuleKeyword */ : 11 /* IdentifierName */;
case 110 /* n */:
- return (array[startIndex + 1] === 117 /* u */ && array[startIndex + 2] === 109 /* m */ && array[startIndex + 3] === 98 /* b */ && array[startIndex + 4] === 101 /* e */ && array[startIndex + 5] === 114 /* r */) ? 67 /* NumberKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 117 /* u */ && array[startIndex + 2] === 109 /* m */ && array[startIndex + 3] === 98 /* b */ && array[startIndex + 4] === 101 /* e */ && array[startIndex + 5] === 114 /* r */) ? 68 /* NumberKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6610,7 +6678,7 @@ var TypeScript;
case 102 /* f */:
return (array[startIndex + 3] === 97 /* a */ && array[startIndex + 4] === 117 /* u */ && array[startIndex + 5] === 108 /* l */ && array[startIndex + 6] === 116 /* t */) ? 20 /* DefaultKeyword */ : 11 /* IdentifierName */;
case 99 /* c */:
- return (array[startIndex + 3] === 108 /* l */ && array[startIndex + 4] === 97 /* a */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 101 /* e */) ? 63 /* DeclareKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 3] === 108 /* l */ && array[startIndex + 4] === 97 /* a */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 101 /* e */) ? 64 /* DeclareKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6636,7 +6704,7 @@ var TypeScript;
case 98 /* b */:
return (array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 111 /* o */ && array[startIndex + 3] === 108 /* l */ && array[startIndex + 4] === 101 /* e */ && array[startIndex + 5] === 97 /* a */ && array[startIndex + 6] === 110 /* n */) ? 61 /* BooleanKeyword */ : 11 /* IdentifierName */;
case 114 /* r */:
- return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 113 /* q */ && array[startIndex + 3] === 117 /* u */ && array[startIndex + 4] === 105 /* i */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 101 /* e */) ? 66 /* RequireKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex + 1] === 101 /* e */ && array[startIndex + 2] === 113 /* q */ && array[startIndex + 3] === 117 /* u */ && array[startIndex + 4] === 105 /* i */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 101 /* e */) ? 67 /* RequireKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -6680,7 +6748,7 @@ var TypeScript;
}
case 11:
- return (array[startIndex] === 99 /* c */ && array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 110 /* n */ && array[startIndex + 3] === 115 /* s */ && array[startIndex + 4] === 116 /* t */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 117 /* u */ && array[startIndex + 7] === 99 /* c */ && array[startIndex + 8] === 116 /* t */ && array[startIndex + 9] === 111 /* o */ && array[startIndex + 10] === 114 /* r */) ? 62 /* ConstructorKeyword */ : 11 /* IdentifierName */;
+ return (array[startIndex] === 99 /* c */ && array[startIndex + 1] === 111 /* o */ && array[startIndex + 2] === 110 /* n */ && array[startIndex + 3] === 115 /* s */ && array[startIndex + 4] === 116 /* t */ && array[startIndex + 5] === 114 /* r */ && array[startIndex + 6] === 117 /* u */ && array[startIndex + 7] === 99 /* c */ && array[startIndex + 8] === 116 /* t */ && array[startIndex + 9] === 111 /* o */ && array[startIndex + 10] === 114 /* r */) ? 63 /* ConstructorKeyword */ : 11 /* IdentifierName */;
default:
return 11 /* IdentifierName */;
}
@@ -7332,9 +7400,9 @@ var TypeScript;
var parentPositionedNode = positionedToken.containingNode();
var parentNode = parentPositionedNode.node();
- if (parentNode.kind() === 121 /* QualifiedName */ && (parentNode).right === token) {
+ if (parentNode.kind() === 122 /* QualifiedName */ && (parentNode).right === token) {
return parentPositionedNode;
- } else if (parentNode.kind() === 211 /* MemberAccessExpression */ && (parentNode).name === token) {
+ } else if (parentNode.kind() === 212 /* MemberAccessExpression */ && (parentNode).name === token) {
return parentPositionedNode;
}
}
@@ -7350,9 +7418,9 @@ var TypeScript;
if (parent !== null) {
switch (parent.kind()) {
- case 246 /* ModuleNameModuleReference */:
+ case 247 /* ModuleNameModuleReference */:
return true;
- case 121 /* QualifiedName */:
+ case 122 /* QualifiedName */:
return true;
default:
return isInTypeOnlyContext(positionedToken);
@@ -7373,13 +7441,13 @@ var TypeScript;
if (parent !== null) {
switch (parent.kind()) {
- case 124 /* ArrayType */:
+ case 125 /* ArrayType */:
return (parent).type === nodeOrToken;
- case 219 /* CastExpression */:
+ case 220 /* CastExpression */:
return (parent).type === nodeOrToken;
- case 244 /* TypeAnnotation */:
- case 229 /* HeritageClause */:
- case 227 /* TypeArgumentList */:
+ case 245 /* TypeAnnotation */:
+ case 230 /* HeritageClause */:
+ case 228 /* TypeArgumentList */:
return true;
}
}
@@ -7578,27 +7646,27 @@ var TypeScript;
Syntax.stringLiteralExpression = stringLiteralExpression;
function isSuperInvocationExpression(node) {
- return node.kind() === 212 /* InvocationExpression */ && (node).expression.kind() === 50 /* SuperKeyword */;
+ return node.kind() === 213 /* InvocationExpression */ && (node).expression.kind() === 50 /* SuperKeyword */;
}
Syntax.isSuperInvocationExpression = isSuperInvocationExpression;
function isSuperInvocationExpressionStatement(node) {
- return node.kind() === 148 /* ExpressionStatement */ && isSuperInvocationExpression((node).expression);
+ return node.kind() === 149 /* ExpressionStatement */ && isSuperInvocationExpression((node).expression);
}
Syntax.isSuperInvocationExpressionStatement = isSuperInvocationExpressionStatement;
function isSuperMemberAccessExpression(node) {
- return node.kind() === 211 /* MemberAccessExpression */ && (node).expression.kind() === 50 /* SuperKeyword */;
+ return node.kind() === 212 /* MemberAccessExpression */ && (node).expression.kind() === 50 /* SuperKeyword */;
}
Syntax.isSuperMemberAccessExpression = isSuperMemberAccessExpression;
function isSuperMemberAccessInvocationExpression(node) {
- return node.kind() === 212 /* InvocationExpression */ && isSuperMemberAccessExpression((node).expression);
+ return node.kind() === 213 /* InvocationExpression */ && isSuperMemberAccessExpression((node).expression);
}
Syntax.isSuperMemberAccessInvocationExpression = isSuperMemberAccessInvocationExpression;
function assignmentExpression(left, token, right) {
- return TypeScript.Syntax.normalModeFactory.binaryExpression(173 /* AssignmentExpression */, left, token, right);
+ return TypeScript.Syntax.normalModeFactory.binaryExpression(174 /* AssignmentExpression */, left, token, right);
}
Syntax.assignmentExpression = assignmentExpression;
@@ -7810,8 +7878,8 @@ var TypeScript;
function isIntegerLiteral(expression) {
if (expression) {
switch (expression.kind()) {
- case 163 /* PlusExpression */:
- case 164 /* NegateExpression */:
+ case 164 /* PlusExpression */:
+ case 165 /* NegateExpression */:
expression = (expression).operand;
return isInteger((expression).text());
@@ -7845,8 +7913,8 @@ var TypeScript;
NormalModeFactory.prototype.sourceUnit = function (moduleElements, endOfFileToken) {
return new TypeScript.SourceUnitSyntax(moduleElements, endOfFileToken, false);
};
- NormalModeFactory.prototype.externalModuleReference = function (requireKeyword, openParenToken, stringLiteral, closeParenToken) {
- return new TypeScript.ExternalModuleReferenceSyntax(requireKeyword, openParenToken, stringLiteral, closeParenToken, false);
+ NormalModeFactory.prototype.externalModuleReference = function (moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken) {
+ return new TypeScript.ExternalModuleReferenceSyntax(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken, false);
};
NormalModeFactory.prototype.moduleNameModuleReference = function (moduleName) {
return new TypeScript.ModuleNameModuleReferenceSyntax(moduleName, false);
@@ -8110,8 +8178,8 @@ var TypeScript;
StrictModeFactory.prototype.sourceUnit = function (moduleElements, endOfFileToken) {
return new TypeScript.SourceUnitSyntax(moduleElements, endOfFileToken, true);
};
- StrictModeFactory.prototype.externalModuleReference = function (requireKeyword, openParenToken, stringLiteral, closeParenToken) {
- return new TypeScript.ExternalModuleReferenceSyntax(requireKeyword, openParenToken, stringLiteral, closeParenToken, true);
+ StrictModeFactory.prototype.externalModuleReference = function (moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken) {
+ return new TypeScript.ExternalModuleReferenceSyntax(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken, true);
};
StrictModeFactory.prototype.moduleNameModuleReference = function (moduleName) {
return new TypeScript.ModuleNameModuleReferenceSyntax(moduleName, true);
@@ -8378,7 +8446,7 @@ var TypeScript;
(function (TypeScript) {
(function (SyntaxFacts) {
function isDirectivePrologueElement(node) {
- if (node.kind() === 148 /* ExpressionStatement */) {
+ if (node.kind() === 149 /* ExpressionStatement */) {
var expressionStatement = node;
var expression = expressionStatement.expression;
@@ -9013,7 +9081,7 @@ var TypeScript;
};
SyntaxNode.prototype.tryGetEndOfFileAt = function (position) {
- if (this.kind() === 120 /* SourceUnit */ && position === this.fullWidth()) {
+ if (this.kind() === 121 /* SourceUnit */ && position === this.fullWidth()) {
var sourceUnit = this;
return new TypeScript.PositionedToken(new TypeScript.PositionedNode(null, sourceUnit, 0), sourceUnit.endOfFileToken, sourceUnit.moduleElements.fullWidth());
}
@@ -9150,7 +9218,7 @@ var TypeScript;
};
SourceUnitSyntax.prototype.kind = function () {
- return 120 /* SourceUnit */;
+ return 121 /* SourceUnit */;
};
SourceUnitSyntax.prototype.childCount = function () {
@@ -9240,9 +9308,9 @@ var TypeScript;
var ExternalModuleReferenceSyntax = (function (_super) {
__extends(ExternalModuleReferenceSyntax, _super);
- function ExternalModuleReferenceSyntax(requireKeyword, openParenToken, stringLiteral, closeParenToken, parsedInStrictMode) {
+ function ExternalModuleReferenceSyntax(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken, parsedInStrictMode) {
_super.call(this, parsedInStrictMode);
- this.requireKeyword = requireKeyword;
+ this.moduleOrRequireKeyword = moduleOrRequireKeyword;
this.openParenToken = openParenToken;
this.stringLiteral = stringLiteral;
this.closeParenToken = closeParenToken;
@@ -9252,7 +9320,7 @@ var TypeScript;
};
ExternalModuleReferenceSyntax.prototype.kind = function () {
- return 245 /* ExternalModuleReference */;
+ return 246 /* ExternalModuleReference */;
};
ExternalModuleReferenceSyntax.prototype.childCount = function () {
@@ -9262,7 +9330,7 @@ var TypeScript;
ExternalModuleReferenceSyntax.prototype.childAt = function (slot) {
switch (slot) {
case 0:
- return this.requireKeyword;
+ return this.moduleOrRequireKeyword;
case 1:
return this.openParenToken;
case 2:
@@ -9274,16 +9342,16 @@ var TypeScript;
}
};
- ExternalModuleReferenceSyntax.prototype.update = function (requireKeyword, openParenToken, stringLiteral, closeParenToken) {
- if (this.requireKeyword === requireKeyword && this.openParenToken === openParenToken && this.stringLiteral === stringLiteral && this.closeParenToken === closeParenToken) {
+ ExternalModuleReferenceSyntax.prototype.update = function (moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken) {
+ if (this.moduleOrRequireKeyword === moduleOrRequireKeyword && this.openParenToken === openParenToken && this.stringLiteral === stringLiteral && this.closeParenToken === closeParenToken) {
return this;
}
- return new ExternalModuleReferenceSyntax(requireKeyword, openParenToken, stringLiteral, closeParenToken, this.parsedInStrictMode());
+ return new ExternalModuleReferenceSyntax(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken, this.parsedInStrictMode());
};
- ExternalModuleReferenceSyntax.create1 = function (stringLiteral) {
- return new ExternalModuleReferenceSyntax(TypeScript.Syntax.token(66 /* RequireKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), stringLiteral, TypeScript.Syntax.token(73 /* CloseParenToken */), false);
+ ExternalModuleReferenceSyntax.create1 = function (moduleOrRequireKeyword, stringLiteral) {
+ return new ExternalModuleReferenceSyntax(moduleOrRequireKeyword, TypeScript.Syntax.token(73 /* OpenParenToken */), stringLiteral, TypeScript.Syntax.token(74 /* CloseParenToken */), false);
};
ExternalModuleReferenceSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9294,20 +9362,20 @@ var TypeScript;
return _super.prototype.withTrailingTrivia.call(this, trivia);
};
- ExternalModuleReferenceSyntax.prototype.withRequireKeyword = function (requireKeyword) {
- return this.update(requireKeyword, this.openParenToken, this.stringLiteral, this.closeParenToken);
+ ExternalModuleReferenceSyntax.prototype.withModuleOrRequireKeyword = function (moduleOrRequireKeyword) {
+ return this.update(moduleOrRequireKeyword, this.openParenToken, this.stringLiteral, this.closeParenToken);
};
ExternalModuleReferenceSyntax.prototype.withOpenParenToken = function (openParenToken) {
- return this.update(this.requireKeyword, openParenToken, this.stringLiteral, this.closeParenToken);
+ return this.update(this.moduleOrRequireKeyword, openParenToken, this.stringLiteral, this.closeParenToken);
};
ExternalModuleReferenceSyntax.prototype.withStringLiteral = function (stringLiteral) {
- return this.update(this.requireKeyword, this.openParenToken, stringLiteral, this.closeParenToken);
+ return this.update(this.moduleOrRequireKeyword, this.openParenToken, stringLiteral, this.closeParenToken);
};
ExternalModuleReferenceSyntax.prototype.withCloseParenToken = function (closeParenToken) {
- return this.update(this.requireKeyword, this.openParenToken, this.stringLiteral, closeParenToken);
+ return this.update(this.moduleOrRequireKeyword, this.openParenToken, this.stringLiteral, closeParenToken);
};
ExternalModuleReferenceSyntax.prototype.isTypeScriptSpecific = function () {
@@ -9328,7 +9396,7 @@ var TypeScript;
};
ModuleNameModuleReferenceSyntax.prototype.kind = function () {
- return 246 /* ModuleNameModuleReference */;
+ return 247 /* ModuleNameModuleReference */;
};
ModuleNameModuleReferenceSyntax.prototype.childCount = function () {
@@ -9387,7 +9455,7 @@ var TypeScript;
};
ImportDeclarationSyntax.prototype.kind = function () {
- return 133 /* ImportDeclaration */;
+ return 134 /* ImportDeclaration */;
};
ImportDeclarationSyntax.prototype.childCount = function () {
@@ -9430,7 +9498,7 @@ var TypeScript;
};
ImportDeclarationSyntax.create1 = function (identifier, moduleReference) {
- return new ImportDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(49 /* ImportKeyword */), identifier, TypeScript.Syntax.token(107 /* EqualsToken */), moduleReference, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ImportDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(49 /* ImportKeyword */), identifier, TypeScript.Syntax.token(108 /* EqualsToken */), moduleReference, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ImportDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9490,7 +9558,7 @@ var TypeScript;
};
ExportAssignmentSyntax.prototype.kind = function () {
- return 134 /* ExportAssignment */;
+ return 135 /* ExportAssignment */;
};
ExportAssignmentSyntax.prototype.childCount = function () {
@@ -9525,7 +9593,7 @@ var TypeScript;
};
ExportAssignmentSyntax.create1 = function (identifier) {
- return new ExportAssignmentSyntax(TypeScript.Syntax.token(47 /* ExportKeyword */), TypeScript.Syntax.token(107 /* EqualsToken */), identifier, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ExportAssignmentSyntax(TypeScript.Syntax.token(47 /* ExportKeyword */), TypeScript.Syntax.token(108 /* EqualsToken */), identifier, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ExportAssignmentSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9577,7 +9645,7 @@ var TypeScript;
};
ClassDeclarationSyntax.prototype.kind = function () {
- return 131 /* ClassDeclaration */;
+ return 132 /* ClassDeclaration */;
};
ClassDeclarationSyntax.prototype.childCount = function () {
@@ -9624,7 +9692,7 @@ var TypeScript;
};
ClassDeclarationSyntax.create1 = function (identifier) {
- return new ClassDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(44 /* ClassKeyword */), identifier, null, TypeScript.Syntax.emptyList, TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new ClassDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(44 /* ClassKeyword */), identifier, null, TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
ClassDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9702,7 +9770,7 @@ var TypeScript;
};
InterfaceDeclarationSyntax.prototype.kind = function () {
- return 128 /* InterfaceDeclaration */;
+ return 129 /* InterfaceDeclaration */;
};
InterfaceDeclarationSyntax.prototype.childCount = function () {
@@ -9807,7 +9875,7 @@ var TypeScript;
};
HeritageClauseSyntax.prototype.kind = function () {
- return 229 /* HeritageClause */;
+ return 230 /* HeritageClause */;
};
HeritageClauseSyntax.prototype.childCount = function () {
@@ -9877,7 +9945,7 @@ var TypeScript;
};
ModuleDeclarationSyntax.prototype.kind = function () {
- return 130 /* ModuleDeclaration */;
+ return 131 /* ModuleDeclaration */;
};
ModuleDeclarationSyntax.prototype.childCount = function () {
@@ -9922,7 +9990,7 @@ var TypeScript;
};
ModuleDeclarationSyntax.create1 = function () {
- return new ModuleDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(65 /* ModuleKeyword */), null, null, TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new ModuleDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(66 /* ModuleKeyword */), null, null, TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
ModuleDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -9992,7 +10060,7 @@ var TypeScript;
};
FunctionDeclarationSyntax.prototype.kind = function () {
- return 129 /* FunctionDeclaration */;
+ return 130 /* FunctionDeclaration */;
};
FunctionDeclarationSyntax.prototype.childCount = function () {
@@ -10107,7 +10175,7 @@ var TypeScript;
};
VariableStatementSyntax.prototype.kind = function () {
- return 147 /* VariableStatement */;
+ return 148 /* VariableStatement */;
};
VariableStatementSyntax.prototype.childCount = function () {
@@ -10148,7 +10216,7 @@ var TypeScript;
};
VariableStatementSyntax.create1 = function (variableDeclaration) {
- return new VariableStatementSyntax(TypeScript.Syntax.emptyList, variableDeclaration, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new VariableStatementSyntax(TypeScript.Syntax.emptyList, variableDeclaration, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
VariableStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10200,7 +10268,7 @@ var TypeScript;
};
VariableDeclarationSyntax.prototype.kind = function () {
- return 223 /* VariableDeclaration */;
+ return 224 /* VariableDeclaration */;
};
VariableDeclarationSyntax.prototype.childCount = function () {
@@ -10273,7 +10341,7 @@ var TypeScript;
};
VariableDeclaratorSyntax.prototype.kind = function () {
- return 224 /* VariableDeclarator */;
+ return 225 /* VariableDeclarator */;
};
VariableDeclaratorSyntax.prototype.childCount = function () {
@@ -10354,7 +10422,7 @@ var TypeScript;
};
EqualsValueClauseSyntax.prototype.kind = function () {
- return 230 /* EqualsValueClause */;
+ return 231 /* EqualsValueClause */;
};
EqualsValueClauseSyntax.prototype.childCount = function () {
@@ -10381,7 +10449,7 @@ var TypeScript;
};
EqualsValueClauseSyntax.create1 = function (value) {
- return new EqualsValueClauseSyntax(TypeScript.Syntax.token(107 /* EqualsToken */), value, false);
+ return new EqualsValueClauseSyntax(TypeScript.Syntax.token(108 /* EqualsToken */), value, false);
};
EqualsValueClauseSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10501,7 +10569,7 @@ var TypeScript;
};
ArrayLiteralExpressionSyntax.prototype.kind = function () {
- return 213 /* ArrayLiteralExpression */;
+ return 214 /* ArrayLiteralExpression */;
};
ArrayLiteralExpressionSyntax.prototype.childCount = function () {
@@ -10542,7 +10610,7 @@ var TypeScript;
};
ArrayLiteralExpressionSyntax.create1 = function () {
- return new ArrayLiteralExpressionSyntax(TypeScript.Syntax.token(74 /* OpenBracketToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(75 /* CloseBracketToken */), false);
+ return new ArrayLiteralExpressionSyntax(TypeScript.Syntax.token(75 /* OpenBracketToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(76 /* CloseBracketToken */), false);
};
ArrayLiteralExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10589,7 +10657,7 @@ var TypeScript;
};
OmittedExpressionSyntax.prototype.kind = function () {
- return 222 /* OmittedExpression */;
+ return 223 /* OmittedExpression */;
};
OmittedExpressionSyntax.prototype.childCount = function () {
@@ -10636,7 +10704,7 @@ var TypeScript;
};
ParenthesizedExpressionSyntax.prototype.kind = function () {
- return 216 /* ParenthesizedExpression */;
+ return 217 /* ParenthesizedExpression */;
};
ParenthesizedExpressionSyntax.prototype.childCount = function () {
@@ -10673,7 +10741,7 @@ var TypeScript;
};
ParenthesizedExpressionSyntax.create1 = function (expression) {
- return new ParenthesizedExpressionSyntax(TypeScript.Syntax.token(72 /* OpenParenToken */), expression, TypeScript.Syntax.token(73 /* CloseParenToken */), false);
+ return new ParenthesizedExpressionSyntax(TypeScript.Syntax.token(73 /* OpenParenToken */), expression, TypeScript.Syntax.token(74 /* CloseParenToken */), false);
};
ParenthesizedExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10747,7 +10815,7 @@ var TypeScript;
};
SimpleArrowFunctionExpressionSyntax.prototype.kind = function () {
- return 218 /* SimpleArrowFunctionExpression */;
+ return 219 /* SimpleArrowFunctionExpression */;
};
SimpleArrowFunctionExpressionSyntax.prototype.childCount = function () {
@@ -10776,7 +10844,7 @@ var TypeScript;
};
SimpleArrowFunctionExpressionSyntax.create1 = function (identifier, body) {
- return new SimpleArrowFunctionExpressionSyntax(identifier, TypeScript.Syntax.token(85 /* EqualsGreaterThanToken */), body, false);
+ return new SimpleArrowFunctionExpressionSyntax(identifier, TypeScript.Syntax.token(86 /* EqualsGreaterThanToken */), body, false);
};
SimpleArrowFunctionExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10817,7 +10885,7 @@ var TypeScript;
};
ParenthesizedArrowFunctionExpressionSyntax.prototype.kind = function () {
- return 217 /* ParenthesizedArrowFunctionExpression */;
+ return 218 /* ParenthesizedArrowFunctionExpression */;
};
ParenthesizedArrowFunctionExpressionSyntax.prototype.childCount = function () {
@@ -10846,7 +10914,7 @@ var TypeScript;
};
ParenthesizedArrowFunctionExpressionSyntax.create1 = function (body) {
- return new ParenthesizedArrowFunctionExpressionSyntax(CallSignatureSyntax.create1(), TypeScript.Syntax.token(85 /* EqualsGreaterThanToken */), body, false);
+ return new ParenthesizedArrowFunctionExpressionSyntax(CallSignatureSyntax.create1(), TypeScript.Syntax.token(86 /* EqualsGreaterThanToken */), body, false);
};
ParenthesizedArrowFunctionExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10889,7 +10957,7 @@ var TypeScript;
};
QualifiedNameSyntax.prototype.kind = function () {
- return 121 /* QualifiedName */;
+ return 122 /* QualifiedName */;
};
QualifiedNameSyntax.prototype.childCount = function () {
@@ -10934,7 +11002,7 @@ var TypeScript;
};
QualifiedNameSyntax.create1 = function (left, right) {
- return new QualifiedNameSyntax(left, TypeScript.Syntax.token(76 /* DotToken */), right, false);
+ return new QualifiedNameSyntax(left, TypeScript.Syntax.token(77 /* DotToken */), right, false);
};
QualifiedNameSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -10977,7 +11045,7 @@ var TypeScript;
};
TypeArgumentListSyntax.prototype.kind = function () {
- return 227 /* TypeArgumentList */;
+ return 228 /* TypeArgumentList */;
};
TypeArgumentListSyntax.prototype.childCount = function () {
@@ -11010,7 +11078,7 @@ var TypeScript;
};
TypeArgumentListSyntax.create1 = function () {
- return new TypeArgumentListSyntax(TypeScript.Syntax.token(80 /* LessThanToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(81 /* GreaterThanToken */), false);
+ return new TypeArgumentListSyntax(TypeScript.Syntax.token(81 /* LessThanToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(82 /* GreaterThanToken */), false);
};
TypeArgumentListSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11059,7 +11127,7 @@ var TypeScript;
};
ConstructorTypeSyntax.prototype.kind = function () {
- return 125 /* ConstructorType */;
+ return 126 /* ConstructorType */;
};
ConstructorTypeSyntax.prototype.childCount = function () {
@@ -11108,7 +11176,7 @@ var TypeScript;
};
ConstructorTypeSyntax.create1 = function (type) {
- return new ConstructorTypeSyntax(TypeScript.Syntax.token(31 /* NewKeyword */), null, ParameterListSyntax.create1(), TypeScript.Syntax.token(85 /* EqualsGreaterThanToken */), type, false);
+ return new ConstructorTypeSyntax(TypeScript.Syntax.token(31 /* NewKeyword */), null, ParameterListSyntax.create1(), TypeScript.Syntax.token(86 /* EqualsGreaterThanToken */), type, false);
};
ConstructorTypeSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11160,7 +11228,7 @@ var TypeScript;
};
FunctionTypeSyntax.prototype.kind = function () {
- return 123 /* FunctionType */;
+ return 124 /* FunctionType */;
};
FunctionTypeSyntax.prototype.childCount = function () {
@@ -11207,7 +11275,7 @@ var TypeScript;
};
FunctionTypeSyntax.create1 = function (type) {
- return new FunctionTypeSyntax(null, ParameterListSyntax.create1(), TypeScript.Syntax.token(85 /* EqualsGreaterThanToken */), type, false);
+ return new FunctionTypeSyntax(null, ParameterListSyntax.create1(), TypeScript.Syntax.token(86 /* EqualsGreaterThanToken */), type, false);
};
FunctionTypeSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11254,7 +11322,7 @@ var TypeScript;
};
ObjectTypeSyntax.prototype.kind = function () {
- return 122 /* ObjectType */;
+ return 123 /* ObjectType */;
};
ObjectTypeSyntax.prototype.childCount = function () {
@@ -11299,7 +11367,7 @@ var TypeScript;
};
ObjectTypeSyntax.create1 = function () {
- return new ObjectTypeSyntax(TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new ObjectTypeSyntax(TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
ObjectTypeSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11346,7 +11414,7 @@ var TypeScript;
};
ArrayTypeSyntax.prototype.kind = function () {
- return 124 /* ArrayType */;
+ return 125 /* ArrayType */;
};
ArrayTypeSyntax.prototype.childCount = function () {
@@ -11387,7 +11455,7 @@ var TypeScript;
};
ArrayTypeSyntax.create1 = function (type) {
- return new ArrayTypeSyntax(type, TypeScript.Syntax.token(74 /* OpenBracketToken */), TypeScript.Syntax.token(75 /* CloseBracketToken */), false);
+ return new ArrayTypeSyntax(type, TypeScript.Syntax.token(75 /* OpenBracketToken */), TypeScript.Syntax.token(76 /* CloseBracketToken */), false);
};
ArrayTypeSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11429,7 +11497,7 @@ var TypeScript;
};
GenericTypeSyntax.prototype.kind = function () {
- return 126 /* GenericType */;
+ return 127 /* GenericType */;
};
GenericTypeSyntax.prototype.childCount = function () {
@@ -11506,7 +11574,7 @@ var TypeScript;
};
TypeQuerySyntax.prototype.kind = function () {
- return 127 /* TypeQuery */;
+ return 128 /* TypeQuery */;
};
TypeQuerySyntax.prototype.childCount = function () {
@@ -11583,7 +11651,7 @@ var TypeScript;
};
TypeAnnotationSyntax.prototype.kind = function () {
- return 244 /* TypeAnnotation */;
+ return 245 /* TypeAnnotation */;
};
TypeAnnotationSyntax.prototype.childCount = function () {
@@ -11610,7 +11678,7 @@ var TypeScript;
};
TypeAnnotationSyntax.create1 = function (type) {
- return new TypeAnnotationSyntax(TypeScript.Syntax.token(106 /* ColonToken */), type, false);
+ return new TypeAnnotationSyntax(TypeScript.Syntax.token(107 /* ColonToken */), type, false);
};
TypeAnnotationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11649,7 +11717,7 @@ var TypeScript;
};
BlockSyntax.prototype.kind = function () {
- return 145 /* Block */;
+ return 146 /* Block */;
};
BlockSyntax.prototype.childCount = function () {
@@ -11690,7 +11758,7 @@ var TypeScript;
};
BlockSyntax.create1 = function () {
- return new BlockSyntax(TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new BlockSyntax(TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
BlockSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -11743,7 +11811,7 @@ var TypeScript;
};
ParameterSyntax.prototype.kind = function () {
- return 242 /* Parameter */;
+ return 243 /* Parameter */;
};
ParameterSyntax.prototype.childCount = function () {
@@ -11852,7 +11920,7 @@ var TypeScript;
};
MemberAccessExpressionSyntax.prototype.kind = function () {
- return 211 /* MemberAccessExpression */;
+ return 212 /* MemberAccessExpression */;
};
MemberAccessExpressionSyntax.prototype.childCount = function () {
@@ -11889,7 +11957,7 @@ var TypeScript;
};
MemberAccessExpressionSyntax.create1 = function (expression, name) {
- return new MemberAccessExpressionSyntax(expression, TypeScript.Syntax.token(76 /* DotToken */), name, false);
+ return new MemberAccessExpressionSyntax(expression, TypeScript.Syntax.token(77 /* DotToken */), name, false);
};
MemberAccessExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12014,7 +12082,7 @@ var TypeScript;
};
ElementAccessExpressionSyntax.prototype.kind = function () {
- return 220 /* ElementAccessExpression */;
+ return 221 /* ElementAccessExpression */;
};
ElementAccessExpressionSyntax.prototype.childCount = function () {
@@ -12053,7 +12121,7 @@ var TypeScript;
};
ElementAccessExpressionSyntax.create1 = function (expression, argumentExpression) {
- return new ElementAccessExpressionSyntax(expression, TypeScript.Syntax.token(74 /* OpenBracketToken */), argumentExpression, TypeScript.Syntax.token(75 /* CloseBracketToken */), false);
+ return new ElementAccessExpressionSyntax(expression, TypeScript.Syntax.token(75 /* OpenBracketToken */), argumentExpression, TypeScript.Syntax.token(76 /* CloseBracketToken */), false);
};
ElementAccessExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12105,7 +12173,7 @@ var TypeScript;
};
InvocationExpressionSyntax.prototype.kind = function () {
- return 212 /* InvocationExpression */;
+ return 213 /* InvocationExpression */;
};
InvocationExpressionSyntax.prototype.childCount = function () {
@@ -12186,7 +12254,7 @@ var TypeScript;
};
ArgumentListSyntax.prototype.kind = function () {
- return 225 /* ArgumentList */;
+ return 226 /* ArgumentList */;
};
ArgumentListSyntax.prototype.childCount = function () {
@@ -12221,7 +12289,7 @@ var TypeScript;
};
ArgumentListSyntax.create1 = function () {
- return new ArgumentListSyntax(null, TypeScript.Syntax.token(72 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(73 /* CloseParenToken */), false);
+ return new ArgumentListSyntax(null, TypeScript.Syntax.token(73 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(74 /* CloseParenToken */), false);
};
ArgumentListSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12364,7 +12432,7 @@ var TypeScript;
};
ConditionalExpressionSyntax.prototype.kind = function () {
- return 185 /* ConditionalExpression */;
+ return 186 /* ConditionalExpression */;
};
ConditionalExpressionSyntax.prototype.childCount = function () {
@@ -12401,7 +12469,7 @@ var TypeScript;
};
ConditionalExpressionSyntax.create1 = function (condition, whenTrue, whenFalse) {
- return new ConditionalExpressionSyntax(condition, TypeScript.Syntax.token(105 /* QuestionToken */), whenTrue, TypeScript.Syntax.token(106 /* ColonToken */), whenFalse, false);
+ return new ConditionalExpressionSyntax(condition, TypeScript.Syntax.token(106 /* QuestionToken */), whenTrue, TypeScript.Syntax.token(107 /* ColonToken */), whenFalse, false);
};
ConditionalExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12460,7 +12528,7 @@ var TypeScript;
};
ConstructSignatureSyntax.prototype.kind = function () {
- return 142 /* ConstructSignature */;
+ return 143 /* ConstructSignature */;
};
ConstructSignatureSyntax.prototype.childCount = function () {
@@ -12530,7 +12598,7 @@ var TypeScript;
};
MethodSignatureSyntax.prototype.kind = function () {
- return 144 /* MethodSignature */;
+ return 145 /* MethodSignature */;
};
MethodSignatureSyntax.prototype.childCount = function () {
@@ -12614,7 +12682,7 @@ var TypeScript;
};
IndexSignatureSyntax.prototype.kind = function () {
- return 143 /* IndexSignature */;
+ return 144 /* IndexSignature */;
};
IndexSignatureSyntax.prototype.childCount = function () {
@@ -12657,7 +12725,7 @@ var TypeScript;
};
IndexSignatureSyntax.create1 = function (parameter) {
- return new IndexSignatureSyntax(TypeScript.Syntax.token(74 /* OpenBracketToken */), parameter, TypeScript.Syntax.token(75 /* CloseBracketToken */), null, false);
+ return new IndexSignatureSyntax(TypeScript.Syntax.token(75 /* OpenBracketToken */), parameter, TypeScript.Syntax.token(76 /* CloseBracketToken */), null, false);
};
IndexSignatureSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12704,7 +12772,7 @@ var TypeScript;
};
PropertySignatureSyntax.prototype.kind = function () {
- return 140 /* PropertySignature */;
+ return 141 /* PropertySignature */;
};
PropertySignatureSyntax.prototype.childCount = function () {
@@ -12784,7 +12852,7 @@ var TypeScript;
};
CallSignatureSyntax.prototype.kind = function () {
- return 141 /* CallSignature */;
+ return 142 /* CallSignature */;
};
CallSignatureSyntax.prototype.childCount = function () {
@@ -12873,7 +12941,7 @@ var TypeScript;
};
ParameterListSyntax.prototype.kind = function () {
- return 226 /* ParameterList */;
+ return 227 /* ParameterList */;
};
ParameterListSyntax.prototype.childCount = function () {
@@ -12906,7 +12974,7 @@ var TypeScript;
};
ParameterListSyntax.create1 = function () {
- return new ParameterListSyntax(TypeScript.Syntax.token(72 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(73 /* CloseParenToken */), false);
+ return new ParameterListSyntax(TypeScript.Syntax.token(73 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(74 /* CloseParenToken */), false);
};
ParameterListSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -12956,7 +13024,7 @@ var TypeScript;
};
TypeParameterListSyntax.prototype.kind = function () {
- return 228 /* TypeParameterList */;
+ return 229 /* TypeParameterList */;
};
TypeParameterListSyntax.prototype.childCount = function () {
@@ -12989,7 +13057,7 @@ var TypeScript;
};
TypeParameterListSyntax.create1 = function () {
- return new TypeParameterListSyntax(TypeScript.Syntax.token(80 /* LessThanToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(81 /* GreaterThanToken */), false);
+ return new TypeParameterListSyntax(TypeScript.Syntax.token(81 /* LessThanToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(82 /* GreaterThanToken */), false);
};
TypeParameterListSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13035,7 +13103,7 @@ var TypeScript;
};
TypeParameterSyntax.prototype.kind = function () {
- return 236 /* TypeParameter */;
+ return 237 /* TypeParameter */;
};
TypeParameterSyntax.prototype.childCount = function () {
@@ -13104,7 +13172,7 @@ var TypeScript;
};
ConstraintSyntax.prototype.kind = function () {
- return 237 /* Constraint */;
+ return 238 /* Constraint */;
};
ConstraintSyntax.prototype.childCount = function () {
@@ -13169,7 +13237,7 @@ var TypeScript;
};
ElseClauseSyntax.prototype.kind = function () {
- return 233 /* ElseClause */;
+ return 234 /* ElseClause */;
};
ElseClauseSyntax.prototype.childCount = function () {
@@ -13241,7 +13309,7 @@ var TypeScript;
};
IfStatementSyntax.prototype.kind = function () {
- return 146 /* IfStatement */;
+ return 147 /* IfStatement */;
};
IfStatementSyntax.prototype.childCount = function () {
@@ -13288,7 +13356,7 @@ var TypeScript;
};
IfStatementSyntax.create1 = function (condition, statement) {
- return new IfStatementSyntax(TypeScript.Syntax.token(28 /* IfKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), condition, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, null, false);
+ return new IfStatementSyntax(TypeScript.Syntax.token(28 /* IfKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), condition, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, null, false);
};
IfStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13351,7 +13419,7 @@ var TypeScript;
};
ExpressionStatementSyntax.prototype.kind = function () {
- return 148 /* ExpressionStatement */;
+ return 149 /* ExpressionStatement */;
};
ExpressionStatementSyntax.prototype.childCount = function () {
@@ -13386,7 +13454,7 @@ var TypeScript;
};
ExpressionStatementSyntax.create1 = function (expression) {
- return new ExpressionStatementSyntax(expression, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ExpressionStatementSyntax(expression, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ExpressionStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13429,7 +13497,7 @@ var TypeScript;
};
ConstructorDeclarationSyntax.prototype.kind = function () {
- return 137 /* ConstructorDeclaration */;
+ return 138 /* ConstructorDeclaration */;
};
ConstructorDeclarationSyntax.prototype.childCount = function () {
@@ -13468,7 +13536,7 @@ var TypeScript;
};
ConstructorDeclarationSyntax.create1 = function () {
- return new ConstructorDeclarationSyntax(TypeScript.Syntax.token(62 /* ConstructorKeyword */), ParameterListSyntax.create1(), null, null, false);
+ return new ConstructorDeclarationSyntax(TypeScript.Syntax.token(63 /* ConstructorKeyword */), ParameterListSyntax.create1(), null, null, false);
};
ConstructorDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13517,7 +13585,7 @@ var TypeScript;
};
MemberFunctionDeclarationSyntax.prototype.kind = function () {
- return 135 /* MemberFunctionDeclaration */;
+ return 136 /* MemberFunctionDeclaration */;
};
MemberFunctionDeclarationSyntax.prototype.childCount = function () {
@@ -13648,7 +13716,7 @@ var TypeScript;
};
GetMemberAccessorDeclarationSyntax.prototype.kind = function () {
- return 138 /* GetMemberAccessorDeclaration */;
+ return 139 /* GetMemberAccessorDeclaration */;
};
GetMemberAccessorDeclarationSyntax.prototype.childCount = function () {
@@ -13687,7 +13755,7 @@ var TypeScript;
};
GetMemberAccessorDeclarationSyntax.create1 = function (propertyName) {
- return new GetMemberAccessorDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(64 /* GetKeyword */), propertyName, ParameterListSyntax.create1(), null, BlockSyntax.create1(), false);
+ return new GetMemberAccessorDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(65 /* GetKeyword */), propertyName, ParameterListSyntax.create1(), null, BlockSyntax.create1(), false);
};
GetMemberAccessorDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13744,7 +13812,7 @@ var TypeScript;
};
SetMemberAccessorDeclarationSyntax.prototype.kind = function () {
- return 139 /* SetMemberAccessorDeclaration */;
+ return 140 /* SetMemberAccessorDeclaration */;
};
SetMemberAccessorDeclarationSyntax.prototype.childCount = function () {
@@ -13781,7 +13849,7 @@ var TypeScript;
};
SetMemberAccessorDeclarationSyntax.create1 = function (propertyName) {
- return new SetMemberAccessorDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(68 /* SetKeyword */), propertyName, ParameterListSyntax.create1(), BlockSyntax.create1(), false);
+ return new SetMemberAccessorDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(69 /* SetKeyword */), propertyName, ParameterListSyntax.create1(), BlockSyntax.create1(), false);
};
SetMemberAccessorDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13836,7 +13904,7 @@ var TypeScript;
};
MemberVariableDeclarationSyntax.prototype.kind = function () {
- return 136 /* MemberVariableDeclaration */;
+ return 137 /* MemberVariableDeclaration */;
};
MemberVariableDeclarationSyntax.prototype.childCount = function () {
@@ -13877,7 +13945,7 @@ var TypeScript;
};
MemberVariableDeclarationSyntax.create1 = function (variableDeclarator) {
- return new MemberVariableDeclarationSyntax(TypeScript.Syntax.emptyList, variableDeclarator, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new MemberVariableDeclarationSyntax(TypeScript.Syntax.emptyList, variableDeclarator, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
MemberVariableDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -13924,7 +13992,7 @@ var TypeScript;
};
ThrowStatementSyntax.prototype.kind = function () {
- return 156 /* ThrowStatement */;
+ return 157 /* ThrowStatement */;
};
ThrowStatementSyntax.prototype.childCount = function () {
@@ -13961,7 +14029,7 @@ var TypeScript;
};
ThrowStatementSyntax.create1 = function (expression) {
- return new ThrowStatementSyntax(TypeScript.Syntax.token(36 /* ThrowKeyword */), expression, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ThrowStatementSyntax(TypeScript.Syntax.token(36 /* ThrowKeyword */), expression, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ThrowStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14007,7 +14075,7 @@ var TypeScript;
};
ReturnStatementSyntax.prototype.kind = function () {
- return 149 /* ReturnStatement */;
+ return 150 /* ReturnStatement */;
};
ReturnStatementSyntax.prototype.childCount = function () {
@@ -14048,7 +14116,7 @@ var TypeScript;
};
ReturnStatementSyntax.create1 = function () {
- return new ReturnStatementSyntax(TypeScript.Syntax.token(33 /* ReturnKeyword */), null, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ReturnStatementSyntax(TypeScript.Syntax.token(33 /* ReturnKeyword */), null, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ReturnStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14094,7 +14162,7 @@ var TypeScript;
};
ObjectCreationExpressionSyntax.prototype.kind = function () {
- return 215 /* ObjectCreationExpression */;
+ return 216 /* ObjectCreationExpression */;
};
ObjectCreationExpressionSyntax.prototype.childCount = function () {
@@ -14188,7 +14256,7 @@ var TypeScript;
};
SwitchStatementSyntax.prototype.kind = function () {
- return 150 /* SwitchStatement */;
+ return 151 /* SwitchStatement */;
};
SwitchStatementSyntax.prototype.childCount = function () {
@@ -14237,7 +14305,7 @@ var TypeScript;
};
SwitchStatementSyntax.create1 = function (expression) {
- return new SwitchStatementSyntax(TypeScript.Syntax.token(34 /* SwitchKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), expression, TypeScript.Syntax.token(73 /* CloseParenToken */), TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new SwitchStatementSyntax(TypeScript.Syntax.token(34 /* SwitchKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), expression, TypeScript.Syntax.token(74 /* CloseParenToken */), TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptyList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
SwitchStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14331,7 +14399,7 @@ var TypeScript;
};
CaseSwitchClauseSyntax.prototype.kind = function () {
- return 231 /* CaseSwitchClause */;
+ return 232 /* CaseSwitchClause */;
};
CaseSwitchClauseSyntax.prototype.childCount = function () {
@@ -14366,7 +14434,7 @@ var TypeScript;
};
CaseSwitchClauseSyntax.create1 = function (expression) {
- return new CaseSwitchClauseSyntax(TypeScript.Syntax.token(16 /* CaseKeyword */), expression, TypeScript.Syntax.token(106 /* ColonToken */), TypeScript.Syntax.emptyList, false);
+ return new CaseSwitchClauseSyntax(TypeScript.Syntax.token(16 /* CaseKeyword */), expression, TypeScript.Syntax.token(107 /* ColonToken */), TypeScript.Syntax.emptyList, false);
};
CaseSwitchClauseSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14421,7 +14489,7 @@ var TypeScript;
};
DefaultSwitchClauseSyntax.prototype.kind = function () {
- return 232 /* DefaultSwitchClause */;
+ return 233 /* DefaultSwitchClause */;
};
DefaultSwitchClauseSyntax.prototype.childCount = function () {
@@ -14454,7 +14522,7 @@ var TypeScript;
};
DefaultSwitchClauseSyntax.create1 = function () {
- return new DefaultSwitchClauseSyntax(TypeScript.Syntax.token(20 /* DefaultKeyword */), TypeScript.Syntax.token(106 /* ColonToken */), TypeScript.Syntax.emptyList, false);
+ return new DefaultSwitchClauseSyntax(TypeScript.Syntax.token(20 /* DefaultKeyword */), TypeScript.Syntax.token(107 /* ColonToken */), TypeScript.Syntax.emptyList, false);
};
DefaultSwitchClauseSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14504,7 +14572,7 @@ var TypeScript;
};
BreakStatementSyntax.prototype.kind = function () {
- return 151 /* BreakStatement */;
+ return 152 /* BreakStatement */;
};
BreakStatementSyntax.prototype.childCount = function () {
@@ -14545,7 +14613,7 @@ var TypeScript;
};
BreakStatementSyntax.create1 = function () {
- return new BreakStatementSyntax(TypeScript.Syntax.token(15 /* BreakKeyword */), null, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new BreakStatementSyntax(TypeScript.Syntax.token(15 /* BreakKeyword */), null, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
BreakStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14588,7 +14656,7 @@ var TypeScript;
};
ContinueStatementSyntax.prototype.kind = function () {
- return 152 /* ContinueStatement */;
+ return 153 /* ContinueStatement */;
};
ContinueStatementSyntax.prototype.childCount = function () {
@@ -14629,7 +14697,7 @@ var TypeScript;
};
ContinueStatementSyntax.create1 = function () {
- return new ContinueStatementSyntax(TypeScript.Syntax.token(18 /* ContinueKeyword */), null, TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new ContinueStatementSyntax(TypeScript.Syntax.token(18 /* ContinueKeyword */), null, TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
ContinueStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14727,7 +14795,7 @@ var TypeScript;
};
ForStatementSyntax.prototype.kind = function () {
- return 153 /* ForStatement */;
+ return 154 /* ForStatement */;
};
ForStatementSyntax.prototype.childCount = function () {
@@ -14774,7 +14842,7 @@ var TypeScript;
};
ForStatementSyntax.create1 = function (statement) {
- return new ForStatementSyntax(TypeScript.Syntax.token(26 /* ForKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), null, null, TypeScript.Syntax.token(78 /* SemicolonToken */), null, TypeScript.Syntax.token(78 /* SemicolonToken */), null, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, false);
+ return new ForStatementSyntax(TypeScript.Syntax.token(26 /* ForKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), null, null, TypeScript.Syntax.token(79 /* SemicolonToken */), null, TypeScript.Syntax.token(79 /* SemicolonToken */), null, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, false);
};
ForStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14860,7 +14928,7 @@ var TypeScript;
};
ForInStatementSyntax.prototype.kind = function () {
- return 154 /* ForInStatement */;
+ return 155 /* ForInStatement */;
};
ForInStatementSyntax.prototype.childCount = function () {
@@ -14903,7 +14971,7 @@ var TypeScript;
};
ForInStatementSyntax.create1 = function (expression, statement) {
- return new ForInStatementSyntax(TypeScript.Syntax.token(26 /* ForKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), null, null, TypeScript.Syntax.token(29 /* InKeyword */), expression, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, false);
+ return new ForInStatementSyntax(TypeScript.Syntax.token(26 /* ForKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), null, null, TypeScript.Syntax.token(29 /* InKeyword */), expression, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, false);
};
ForInStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -14977,7 +15045,7 @@ var TypeScript;
};
WhileStatementSyntax.prototype.kind = function () {
- return 157 /* WhileStatement */;
+ return 158 /* WhileStatement */;
};
WhileStatementSyntax.prototype.childCount = function () {
@@ -15010,7 +15078,7 @@ var TypeScript;
};
WhileStatementSyntax.create1 = function (condition, statement) {
- return new WhileStatementSyntax(TypeScript.Syntax.token(42 /* WhileKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), condition, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, false);
+ return new WhileStatementSyntax(TypeScript.Syntax.token(42 /* WhileKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), condition, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, false);
};
WhileStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15069,7 +15137,7 @@ var TypeScript;
};
WithStatementSyntax.prototype.kind = function () {
- return 162 /* WithStatement */;
+ return 163 /* WithStatement */;
};
WithStatementSyntax.prototype.childCount = function () {
@@ -15110,7 +15178,7 @@ var TypeScript;
};
WithStatementSyntax.create1 = function (condition, statement) {
- return new WithStatementSyntax(TypeScript.Syntax.token(43 /* WithKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), condition, TypeScript.Syntax.token(73 /* CloseParenToken */), statement, false);
+ return new WithStatementSyntax(TypeScript.Syntax.token(43 /* WithKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), condition, TypeScript.Syntax.token(74 /* CloseParenToken */), statement, false);
};
WithStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15170,7 +15238,7 @@ var TypeScript;
};
EnumDeclarationSyntax.prototype.kind = function () {
- return 132 /* EnumDeclaration */;
+ return 133 /* EnumDeclaration */;
};
EnumDeclarationSyntax.prototype.childCount = function () {
@@ -15213,7 +15281,7 @@ var TypeScript;
};
EnumDeclarationSyntax.create1 = function (identifier) {
- return new EnumDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(46 /* EnumKeyword */), identifier, TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new EnumDeclarationSyntax(TypeScript.Syntax.emptyList, TypeScript.Syntax.token(46 /* EnumKeyword */), identifier, TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
EnumDeclarationSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15275,7 +15343,7 @@ var TypeScript;
};
EnumElementSyntax.prototype.kind = function () {
- return 243 /* EnumElement */;
+ return 244 /* EnumElement */;
};
EnumElementSyntax.prototype.childCount = function () {
@@ -15349,7 +15417,7 @@ var TypeScript;
};
CastExpressionSyntax.prototype.kind = function () {
- return 219 /* CastExpression */;
+ return 220 /* CastExpression */;
};
CastExpressionSyntax.prototype.childCount = function () {
@@ -15388,7 +15456,7 @@ var TypeScript;
};
CastExpressionSyntax.create1 = function (type, expression) {
- return new CastExpressionSyntax(TypeScript.Syntax.token(80 /* LessThanToken */), type, TypeScript.Syntax.token(81 /* GreaterThanToken */), expression, false);
+ return new CastExpressionSyntax(TypeScript.Syntax.token(81 /* LessThanToken */), type, TypeScript.Syntax.token(82 /* GreaterThanToken */), expression, false);
};
CastExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15435,7 +15503,7 @@ var TypeScript;
};
ObjectLiteralExpressionSyntax.prototype.kind = function () {
- return 214 /* ObjectLiteralExpression */;
+ return 215 /* ObjectLiteralExpression */;
};
ObjectLiteralExpressionSyntax.prototype.childCount = function () {
@@ -15476,7 +15544,7 @@ var TypeScript;
};
ObjectLiteralExpressionSyntax.create1 = function () {
- return new ObjectLiteralExpressionSyntax(TypeScript.Syntax.token(70 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(71 /* CloseBraceToken */), false);
+ return new ObjectLiteralExpressionSyntax(TypeScript.Syntax.token(71 /* OpenBraceToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.token(72 /* CloseBraceToken */), false);
};
ObjectLiteralExpressionSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15546,7 +15614,7 @@ var TypeScript;
};
SimplePropertyAssignmentSyntax.prototype.kind = function () {
- return 238 /* SimplePropertyAssignment */;
+ return 239 /* SimplePropertyAssignment */;
};
SimplePropertyAssignmentSyntax.prototype.childCount = function () {
@@ -15575,7 +15643,7 @@ var TypeScript;
};
SimplePropertyAssignmentSyntax.create1 = function (propertyName, expression) {
- return new SimplePropertyAssignmentSyntax(propertyName, TypeScript.Syntax.token(106 /* ColonToken */), expression, false);
+ return new SimplePropertyAssignmentSyntax(propertyName, TypeScript.Syntax.token(107 /* ColonToken */), expression, false);
};
SimplePropertyAssignmentSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15620,7 +15688,7 @@ var TypeScript;
};
FunctionPropertyAssignmentSyntax.prototype.kind = function () {
- return 241 /* FunctionPropertyAssignment */;
+ return 242 /* FunctionPropertyAssignment */;
};
FunctionPropertyAssignmentSyntax.prototype.childCount = function () {
@@ -15720,7 +15788,7 @@ var TypeScript;
};
GetAccessorPropertyAssignmentSyntax.prototype.kind = function () {
- return 239 /* GetAccessorPropertyAssignment */;
+ return 240 /* GetAccessorPropertyAssignment */;
};
GetAccessorPropertyAssignmentSyntax.prototype.childCount = function () {
@@ -15759,7 +15827,7 @@ var TypeScript;
};
GetAccessorPropertyAssignmentSyntax.create1 = function (propertyName) {
- return new GetAccessorPropertyAssignmentSyntax(TypeScript.Syntax.token(64 /* GetKeyword */), propertyName, TypeScript.Syntax.token(72 /* OpenParenToken */), TypeScript.Syntax.token(73 /* CloseParenToken */), null, BlockSyntax.create1(), false);
+ return new GetAccessorPropertyAssignmentSyntax(TypeScript.Syntax.token(65 /* GetKeyword */), propertyName, TypeScript.Syntax.token(73 /* OpenParenToken */), TypeScript.Syntax.token(74 /* CloseParenToken */), null, BlockSyntax.create1(), false);
};
GetAccessorPropertyAssignmentSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15819,7 +15887,7 @@ var TypeScript;
};
SetAccessorPropertyAssignmentSyntax.prototype.kind = function () {
- return 240 /* SetAccessorPropertyAssignment */;
+ return 241 /* SetAccessorPropertyAssignment */;
};
SetAccessorPropertyAssignmentSyntax.prototype.childCount = function () {
@@ -15854,7 +15922,7 @@ var TypeScript;
};
SetAccessorPropertyAssignmentSyntax.create1 = function (propertyName, parameter) {
- return new SetAccessorPropertyAssignmentSyntax(TypeScript.Syntax.token(68 /* SetKeyword */), propertyName, TypeScript.Syntax.token(72 /* OpenParenToken */), parameter, TypeScript.Syntax.token(73 /* CloseParenToken */), BlockSyntax.create1(), false);
+ return new SetAccessorPropertyAssignmentSyntax(TypeScript.Syntax.token(69 /* SetKeyword */), propertyName, TypeScript.Syntax.token(73 /* OpenParenToken */), parameter, TypeScript.Syntax.token(74 /* CloseParenToken */), BlockSyntax.create1(), false);
};
SetAccessorPropertyAssignmentSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -15916,7 +15984,7 @@ var TypeScript;
};
FunctionExpressionSyntax.prototype.kind = function () {
- return 221 /* FunctionExpression */;
+ return 222 /* FunctionExpression */;
};
FunctionExpressionSyntax.prototype.childCount = function () {
@@ -16010,7 +16078,7 @@ var TypeScript;
};
EmptyStatementSyntax.prototype.kind = function () {
- return 155 /* EmptyStatement */;
+ return 156 /* EmptyStatement */;
};
EmptyStatementSyntax.prototype.childCount = function () {
@@ -16043,7 +16111,7 @@ var TypeScript;
};
EmptyStatementSyntax.create1 = function () {
- return new EmptyStatementSyntax(TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new EmptyStatementSyntax(TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
EmptyStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16079,7 +16147,7 @@ var TypeScript;
};
TryStatementSyntax.prototype.kind = function () {
- return 158 /* TryStatement */;
+ return 159 /* TryStatement */;
};
TryStatementSyntax.prototype.childCount = function () {
@@ -16181,7 +16249,7 @@ var TypeScript;
};
CatchClauseSyntax.prototype.kind = function () {
- return 234 /* CatchClause */;
+ return 235 /* CatchClause */;
};
CatchClauseSyntax.prototype.childCount = function () {
@@ -16220,7 +16288,7 @@ var TypeScript;
};
CatchClauseSyntax.create1 = function (identifier) {
- return new CatchClauseSyntax(TypeScript.Syntax.token(17 /* CatchKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), identifier, null, TypeScript.Syntax.token(73 /* CloseParenToken */), BlockSyntax.create1(), false);
+ return new CatchClauseSyntax(TypeScript.Syntax.token(17 /* CatchKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), identifier, null, TypeScript.Syntax.token(74 /* CloseParenToken */), BlockSyntax.create1(), false);
};
CatchClauseSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16280,7 +16348,7 @@ var TypeScript;
};
FinallyClauseSyntax.prototype.kind = function () {
- return 235 /* FinallyClause */;
+ return 236 /* FinallyClause */;
};
FinallyClauseSyntax.prototype.childCount = function () {
@@ -16349,7 +16417,7 @@ var TypeScript;
};
LabeledStatementSyntax.prototype.kind = function () {
- return 159 /* LabeledStatement */;
+ return 160 /* LabeledStatement */;
};
LabeledStatementSyntax.prototype.childCount = function () {
@@ -16386,7 +16454,7 @@ var TypeScript;
};
LabeledStatementSyntax.create1 = function (identifier, statement) {
- return new LabeledStatementSyntax(identifier, TypeScript.Syntax.token(106 /* ColonToken */), statement, false);
+ return new LabeledStatementSyntax(identifier, TypeScript.Syntax.token(107 /* ColonToken */), statement, false);
};
LabeledStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16433,7 +16501,7 @@ var TypeScript;
};
DoStatementSyntax.prototype.kind = function () {
- return 160 /* DoStatement */;
+ return 161 /* DoStatement */;
};
DoStatementSyntax.prototype.childCount = function () {
@@ -16470,7 +16538,7 @@ var TypeScript;
};
DoStatementSyntax.create1 = function (statement, condition) {
- return new DoStatementSyntax(TypeScript.Syntax.token(22 /* DoKeyword */), statement, TypeScript.Syntax.token(42 /* WhileKeyword */), TypeScript.Syntax.token(72 /* OpenParenToken */), condition, TypeScript.Syntax.token(73 /* CloseParenToken */), TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new DoStatementSyntax(TypeScript.Syntax.token(22 /* DoKeyword */), statement, TypeScript.Syntax.token(42 /* WhileKeyword */), TypeScript.Syntax.token(73 /* OpenParenToken */), condition, TypeScript.Syntax.token(74 /* CloseParenToken */), TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
DoStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16534,7 +16602,7 @@ var TypeScript;
};
TypeOfExpressionSyntax.prototype.kind = function () {
- return 170 /* TypeOfExpression */;
+ return 171 /* TypeOfExpression */;
};
TypeOfExpressionSyntax.prototype.childCount = function () {
@@ -16610,7 +16678,7 @@ var TypeScript;
};
DeleteExpressionSyntax.prototype.kind = function () {
- return 169 /* DeleteExpression */;
+ return 170 /* DeleteExpression */;
};
DeleteExpressionSyntax.prototype.childCount = function () {
@@ -16686,7 +16754,7 @@ var TypeScript;
};
VoidExpressionSyntax.prototype.kind = function () {
- return 171 /* VoidExpression */;
+ return 172 /* VoidExpression */;
};
VoidExpressionSyntax.prototype.childCount = function () {
@@ -16762,7 +16830,7 @@ var TypeScript;
};
DebuggerStatementSyntax.prototype.kind = function () {
- return 161 /* DebuggerStatement */;
+ return 162 /* DebuggerStatement */;
};
DebuggerStatementSyntax.prototype.childCount = function () {
@@ -16797,7 +16865,7 @@ var TypeScript;
};
DebuggerStatementSyntax.create1 = function () {
- return new DebuggerStatementSyntax(TypeScript.Syntax.token(19 /* DebuggerKeyword */), TypeScript.Syntax.token(78 /* SemicolonToken */), false);
+ return new DebuggerStatementSyntax(TypeScript.Syntax.token(19 /* DebuggerKeyword */), TypeScript.Syntax.token(79 /* SemicolonToken */), false);
};
DebuggerStatementSyntax.prototype.withLeadingTrivia = function (trivia) {
@@ -16889,7 +16957,7 @@ var TypeScript;
};
SyntaxRewriter.prototype.visitExternalModuleReference = function (node) {
- return node.update(this.visitToken(node.requireKeyword), this.visitToken(node.openParenToken), this.visitToken(node.stringLiteral), this.visitToken(node.closeParenToken));
+ return node.update(this.visitToken(node.moduleOrRequireKeyword), this.visitToken(node.openParenToken), this.visitToken(node.stringLiteral), this.visitToken(node.closeParenToken));
};
SyntaxRewriter.prototype.visitModuleNameModuleReference = function (node) {
@@ -19709,11 +19777,11 @@ var TypeScript;
SyntaxUtilities.isAngleBracket = function (positionedElement) {
var element = positionedElement.element();
var parent = positionedElement.parentElement();
- if (parent !== null && (element.kind() === 80 /* LessThanToken */ || element.kind() === 81 /* GreaterThanToken */)) {
+ if (parent !== null && (element.kind() === 81 /* LessThanToken */ || element.kind() === 82 /* GreaterThanToken */)) {
switch (parent.kind()) {
- case 227 /* TypeArgumentList */:
- case 228 /* TypeParameterList */:
- case 219 /* CastExpression */:
+ case 228 /* TypeArgumentList */:
+ case 229 /* TypeParameterList */:
+ case 220 /* CastExpression */:
return true;
}
}
@@ -19742,13 +19810,13 @@ var TypeScript;
SyntaxUtilities.getExportKeyword = function (moduleElement) {
switch (moduleElement.kind()) {
- case 130 /* ModuleDeclaration */:
- case 131 /* ClassDeclaration */:
- case 129 /* FunctionDeclaration */:
- case 147 /* VariableStatement */:
- case 132 /* EnumDeclaration */:
- case 128 /* InterfaceDeclaration */:
- case 133 /* ImportDeclaration */:
+ case 131 /* ModuleDeclaration */:
+ case 132 /* ClassDeclaration */:
+ case 130 /* FunctionDeclaration */:
+ case 148 /* VariableStatement */:
+ case 133 /* EnumDeclaration */:
+ case 129 /* InterfaceDeclaration */:
+ case 134 /* ImportDeclaration */:
return SyntaxUtilities.getToken((moduleElement).modifiers, 47 /* ExportKeyword */);
default:
return null;
@@ -19762,26 +19830,26 @@ var TypeScript;
var node = positionNode.node();
switch (node.kind()) {
- case 130 /* ModuleDeclaration */:
- case 131 /* ClassDeclaration */:
- case 129 /* FunctionDeclaration */:
- case 147 /* VariableStatement */:
- case 132 /* EnumDeclaration */:
- if (SyntaxUtilities.containsToken((node).modifiers, 63 /* DeclareKeyword */)) {
+ case 131 /* ModuleDeclaration */:
+ case 132 /* ClassDeclaration */:
+ case 130 /* FunctionDeclaration */:
+ case 148 /* VariableStatement */:
+ case 133 /* EnumDeclaration */:
+ if (SyntaxUtilities.containsToken((node).modifiers, 64 /* DeclareKeyword */)) {
return true;
}
- case 133 /* ImportDeclaration */:
- case 137 /* ConstructorDeclaration */:
- case 135 /* MemberFunctionDeclaration */:
- case 138 /* GetMemberAccessorDeclaration */:
- case 139 /* SetMemberAccessorDeclaration */:
- case 136 /* MemberVariableDeclaration */:
+ case 134 /* ImportDeclaration */:
+ case 138 /* ConstructorDeclaration */:
+ case 136 /* MemberFunctionDeclaration */:
+ case 139 /* GetMemberAccessorDeclaration */:
+ case 140 /* SetMemberAccessorDeclaration */:
+ case 137 /* MemberVariableDeclaration */:
if (node.isClassElement() || node.isModuleElement()) {
return SyntaxUtilities.isAmbientDeclarationSyntax(positionNode.containingNode());
}
- case 243 /* EnumElement */:
+ case 244 /* EnumElement */:
return SyntaxUtilities.isAmbientDeclarationSyntax(positionNode.containingNode().containingNode());
default:
@@ -20215,7 +20283,7 @@ var TypeScript;
};
SyntaxWalker.prototype.visitExternalModuleReference = function (node) {
- this.visitToken(node.requireKeyword);
+ this.visitToken(node.moduleOrRequireKeyword);
this.visitToken(node.openParenToken);
this.visitToken(node.stringLiteral);
this.visitToken(node.closeParenToken);
@@ -21627,7 +21695,7 @@ var TypeScript;
return !this.isInStrictMode;
}
- return tokenKind <= 69 /* LastTypeScriptKeyword */;
+ return tokenKind <= 70 /* LastTypeScriptKeyword */;
}
return false;
@@ -21671,7 +21739,7 @@ var TypeScript;
return true;
}
- if (token.tokenKind === 71 /* CloseBraceToken */) {
+ if (token.tokenKind === 72 /* CloseBraceToken */) {
return true;
}
@@ -21689,7 +21757,7 @@ var TypeScript;
ParserImpl.prototype.canEatExplicitOrAutomaticSemicolon = function (allowWithoutNewline) {
var token = this.currentToken();
- if (token.tokenKind === 78 /* SemicolonToken */) {
+ if (token.tokenKind === 79 /* SemicolonToken */) {
return true;
}
@@ -21699,12 +21767,12 @@ var TypeScript;
ParserImpl.prototype.eatExplicitOrAutomaticSemicolon = function (allowWithoutNewline) {
var token = this.currentToken();
- if (token.tokenKind === 78 /* SemicolonToken */) {
- return this.eatToken(78 /* SemicolonToken */);
+ if (token.tokenKind === 79 /* SemicolonToken */) {
+ return this.eatToken(79 /* SemicolonToken */);
}
if (this.canEatAutomaticSemicolon(allowWithoutNewline)) {
- var semicolonToken = TypeScript.Syntax.emptyToken(78 /* SemicolonToken */);
+ var semicolonToken = TypeScript.Syntax.emptyToken(79 /* SemicolonToken */);
if (!this.parseOptions.allowAutomaticSemicolonInsertion()) {
this.addDiagnostic(new TypeScript.Diagnostic(this.fileName, this.previousTokenEnd(), 0, TypeScript.DiagnosticCode.Automatic_semicolon_insertion_not_allowed, null));
@@ -21713,7 +21781,7 @@ var TypeScript;
return semicolonToken;
}
- return this.eatToken(78 /* SemicolonToken */);
+ return this.eatToken(79 /* SemicolonToken */);
};
ParserImpl.prototype.isKeyword = function (kind) {
@@ -21753,78 +21821,78 @@ var TypeScript;
ParserImpl.getPrecedence = function (expressionKind) {
switch (expressionKind) {
- case 172 /* CommaExpression */:
+ case 173 /* CommaExpression */:
return 1 /* CommaExpressionPrecedence */;
- case 173 /* AssignmentExpression */:
- case 174 /* AddAssignmentExpression */:
- case 175 /* SubtractAssignmentExpression */:
- case 176 /* MultiplyAssignmentExpression */:
- case 177 /* DivideAssignmentExpression */:
- case 178 /* ModuloAssignmentExpression */:
- case 179 /* AndAssignmentExpression */:
- case 180 /* ExclusiveOrAssignmentExpression */:
- case 181 /* OrAssignmentExpression */:
- case 182 /* LeftShiftAssignmentExpression */:
- case 183 /* SignedRightShiftAssignmentExpression */:
- case 184 /* UnsignedRightShiftAssignmentExpression */:
+ case 174 /* AssignmentExpression */:
+ case 175 /* AddAssignmentExpression */:
+ case 176 /* SubtractAssignmentExpression */:
+ case 177 /* MultiplyAssignmentExpression */:
+ case 178 /* DivideAssignmentExpression */:
+ case 179 /* ModuloAssignmentExpression */:
+ case 180 /* AndAssignmentExpression */:
+ case 181 /* ExclusiveOrAssignmentExpression */:
+ case 182 /* OrAssignmentExpression */:
+ case 183 /* LeftShiftAssignmentExpression */:
+ case 184 /* SignedRightShiftAssignmentExpression */:
+ case 185 /* UnsignedRightShiftAssignmentExpression */:
return 2 /* AssignmentExpressionPrecedence */;
- case 185 /* ConditionalExpression */:
+ case 186 /* ConditionalExpression */:
return 3 /* ConditionalExpressionPrecedence */;
- case 186 /* LogicalOrExpression */:
+ case 187 /* LogicalOrExpression */:
return 5 /* LogicalOrExpressionPrecedence */;
- case 187 /* LogicalAndExpression */:
+ case 188 /* LogicalAndExpression */:
return 6 /* LogicalAndExpressionPrecedence */;
- case 188 /* BitwiseOrExpression */:
+ case 189 /* BitwiseOrExpression */:
return 7 /* BitwiseOrExpressionPrecedence */;
- case 189 /* BitwiseExclusiveOrExpression */:
+ case 190 /* BitwiseExclusiveOrExpression */:
return 8 /* BitwiseExclusiveOrExpressionPrecedence */;
- case 190 /* BitwiseAndExpression */:
+ case 191 /* BitwiseAndExpression */:
return 9 /* BitwiseAndExpressionPrecedence */;
- case 191 /* EqualsWithTypeConversionExpression */:
- case 192 /* NotEqualsWithTypeConversionExpression */:
- case 193 /* EqualsExpression */:
- case 194 /* NotEqualsExpression */:
+ case 192 /* EqualsWithTypeConversionExpression */:
+ case 193 /* NotEqualsWithTypeConversionExpression */:
+ case 194 /* EqualsExpression */:
+ case 195 /* NotEqualsExpression */:
return 10 /* EqualityExpressionPrecedence */;
- case 195 /* LessThanExpression */:
- case 196 /* GreaterThanExpression */:
- case 197 /* LessThanOrEqualExpression */:
- case 198 /* GreaterThanOrEqualExpression */:
- case 199 /* InstanceOfExpression */:
- case 200 /* InExpression */:
+ case 196 /* LessThanExpression */:
+ case 197 /* GreaterThanExpression */:
+ case 198 /* LessThanOrEqualExpression */:
+ case 199 /* GreaterThanOrEqualExpression */:
+ case 200 /* InstanceOfExpression */:
+ case 201 /* InExpression */:
return 11 /* RelationalExpressionPrecedence */;
- case 201 /* LeftShiftExpression */:
- case 202 /* SignedRightShiftExpression */:
- case 203 /* UnsignedRightShiftExpression */:
+ case 202 /* LeftShiftExpression */:
+ case 203 /* SignedRightShiftExpression */:
+ case 204 /* UnsignedRightShiftExpression */:
return 12 /* ShiftExpressionPrecdence */;
- case 207 /* AddExpression */:
- case 208 /* SubtractExpression */:
+ case 208 /* AddExpression */:
+ case 209 /* SubtractExpression */:
return 13 /* AdditiveExpressionPrecedence */;
- case 204 /* MultiplyExpression */:
- case 205 /* DivideExpression */:
- case 206 /* ModuloExpression */:
+ case 205 /* MultiplyExpression */:
+ case 206 /* DivideExpression */:
+ case 207 /* ModuloExpression */:
return 14 /* MultiplicativeExpressionPrecedence */;
- case 163 /* PlusExpression */:
- case 164 /* NegateExpression */:
- case 165 /* BitwiseNotExpression */:
- case 166 /* LogicalNotExpression */:
- case 169 /* DeleteExpression */:
- case 170 /* TypeOfExpression */:
- case 171 /* VoidExpression */:
- case 167 /* PreIncrementExpression */:
- case 168 /* PreDecrementExpression */:
+ case 164 /* PlusExpression */:
+ case 165 /* NegateExpression */:
+ case 166 /* BitwiseNotExpression */:
+ case 167 /* LogicalNotExpression */:
+ case 170 /* DeleteExpression */:
+ case 171 /* TypeOfExpression */:
+ case 172 /* VoidExpression */:
+ case 168 /* PreIncrementExpression */:
+ case 169 /* PreDecrementExpression */:
return 15 /* UnaryExpressionPrecedence */;
}
@@ -21998,7 +22066,7 @@ var TypeScript;
var modifiers = this.parseModifiers();
var importKeyword = this.eatKeyword(49 /* ImportKeyword */);
var identifier = this.eatIdentifierToken();
- var equalsToken = this.eatToken(107 /* EqualsToken */);
+ var equalsToken = this.eatToken(108 /* EqualsToken */);
var moduleReference = this.parseModuleReference();
var semicolonToken = this.eatExplicitOrAutomaticSemicolon(false);
@@ -22006,12 +22074,12 @@ var TypeScript;
};
ParserImpl.prototype.isExportAssignment = function () {
- return this.currentToken().tokenKind === 47 /* ExportKeyword */ && this.peekToken(1).tokenKind === 107 /* EqualsToken */;
+ return this.currentToken().tokenKind === 47 /* ExportKeyword */ && this.peekToken(1).tokenKind === 108 /* EqualsToken */;
};
ParserImpl.prototype.parseExportAssignment = function () {
var exportKeyword = this.eatKeyword(47 /* ExportKeyword */);
- var equalsToken = this.eatToken(107 /* EqualsToken */);
+ var equalsToken = this.eatToken(108 /* EqualsToken */);
var identifier = this.eatIdentifierToken();
var semicolonToken = this.eatExplicitOrAutomaticSemicolon(false);
@@ -22028,20 +22096,20 @@ var TypeScript;
ParserImpl.prototype.isExternalModuleReference = function () {
var token0 = this.currentToken();
- if (token0.tokenKind === 66 /* RequireKeyword */) {
- return this.peekToken(1).tokenKind === 72 /* OpenParenToken */;
+ if (token0.tokenKind === 66 /* ModuleKeyword */ || token0.tokenKind === 67 /* RequireKeyword */) {
+ return this.peekToken(1).tokenKind === 73 /* OpenParenToken */;
}
return false;
};
ParserImpl.prototype.parseExternalModuleReference = function () {
- var requireKeyword = this.eatKeyword(66 /* RequireKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var moduleOrRequireKeyword = this.eatAnyToken();
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var stringLiteral = this.eatToken(14 /* StringLiteral */);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
- return this.factory.externalModuleReference(requireKeyword, openParenToken, stringLiteral, closeParenToken);
+ return this.factory.externalModuleReference(moduleOrRequireKeyword, openParenToken, stringLiteral, closeParenToken);
};
ParserImpl.prototype.parseModuleNameModuleReference = function () {
@@ -22059,7 +22127,7 @@ var TypeScript;
};
ParserImpl.prototype.tryParseTypeArgumentList = function (inExpression) {
- if (this.currentToken().kind() !== 80 /* LessThanToken */) {
+ if (this.currentToken().kind() !== 81 /* LessThanToken */) {
return null;
}
@@ -22069,26 +22137,26 @@ var TypeScript;
var typeArguments;
if (!inExpression) {
- lessThanToken = this.eatToken(80 /* LessThanToken */);
+ lessThanToken = this.eatToken(81 /* LessThanToken */);
result = this.parseSeparatedSyntaxList(262144 /* TypeArgumentList_Types */);
typeArguments = result.list;
lessThanToken = this.addSkippedTokensAfterToken(lessThanToken, result.skippedTokens);
- greaterThanToken = this.eatToken(81 /* GreaterThanToken */);
+ greaterThanToken = this.eatToken(82 /* GreaterThanToken */);
return this.factory.typeArgumentList(lessThanToken, typeArguments, greaterThanToken);
}
var rewindPoint = this.getRewindPoint();
try {
- lessThanToken = this.eatToken(80 /* LessThanToken */);
+ lessThanToken = this.eatToken(81 /* LessThanToken */);
result = this.parseSeparatedSyntaxList(262144 /* TypeArgumentList_Types */);
typeArguments = result.list;
lessThanToken = this.addSkippedTokensAfterToken(lessThanToken, result.skippedTokens);
- greaterThanToken = this.eatToken(81 /* GreaterThanToken */);
+ greaterThanToken = this.eatToken(82 /* GreaterThanToken */);
if (greaterThanToken.fullWidth() === 0 || !this.canFollowTypeArgumentListInExpression(this.currentToken().kind())) {
this.rewind(rewindPoint);
@@ -22103,25 +22171,25 @@ var TypeScript;
ParserImpl.prototype.canFollowTypeArgumentListInExpression = function (kind) {
switch (kind) {
- case 72 /* OpenParenToken */:
- case 76 /* DotToken */:
+ case 73 /* OpenParenToken */:
+ case 77 /* DotToken */:
- case 73 /* CloseParenToken */:
- case 75 /* CloseBracketToken */:
- case 106 /* ColonToken */:
- case 78 /* SemicolonToken */:
- case 79 /* CommaToken */:
- case 105 /* QuestionToken */:
- case 84 /* EqualsEqualsToken */:
- case 87 /* EqualsEqualsEqualsToken */:
- case 86 /* ExclamationEqualsToken */:
- case 88 /* ExclamationEqualsEqualsToken */:
- case 103 /* AmpersandAmpersandToken */:
- case 104 /* BarBarToken */:
- case 100 /* CaretToken */:
- case 98 /* AmpersandToken */:
- case 99 /* BarToken */:
- case 71 /* CloseBraceToken */:
+ case 74 /* CloseParenToken */:
+ case 76 /* CloseBracketToken */:
+ case 107 /* ColonToken */:
+ case 79 /* SemicolonToken */:
+ case 80 /* CommaToken */:
+ case 106 /* QuestionToken */:
+ case 85 /* EqualsEqualsToken */:
+ case 88 /* EqualsEqualsEqualsToken */:
+ case 87 /* ExclamationEqualsToken */:
+ case 89 /* ExclamationEqualsEqualsToken */:
+ case 104 /* AmpersandAmpersandToken */:
+ case 105 /* BarBarToken */:
+ case 101 /* CaretToken */:
+ case 99 /* AmpersandToken */:
+ case 100 /* BarToken */:
+ case 72 /* CloseBraceToken */:
case 10 /* EndOfFileToken */:
return true;
@@ -22134,8 +22202,8 @@ var TypeScript;
var shouldContinue = this.isIdentifier(this.currentToken());
var current = this.eatIdentifierToken();
- while (shouldContinue && this.currentToken().tokenKind === 76 /* DotToken */) {
- var dotToken = this.eatToken(76 /* DotToken */);
+ while (shouldContinue && this.currentToken().tokenKind === 77 /* DotToken */) {
+ var dotToken = this.eatToken(77 /* DotToken */);
var currentToken = this.currentToken();
var identifierName;
@@ -22169,7 +22237,7 @@ var TypeScript;
var enumKeyword = this.eatKeyword(46 /* EnumKeyword */);
var identifier = this.eatIdentifierToken();
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var enumElements = TypeScript.Syntax.emptySeparatedList;
if (openBraceToken.width() > 0) {
@@ -22178,13 +22246,13 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.enumDeclaration(modifiers, enumKeyword, identifier, openBraceToken, enumElements, closeBraceToken);
};
ParserImpl.prototype.isEnumElement = function (inErrorRecovery) {
- if (this.currentNode() !== null && this.currentNode().kind() === 243 /* EnumElement */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 244 /* EnumElement */) {
return true;
}
@@ -22192,7 +22260,7 @@ var TypeScript;
};
ParserImpl.prototype.parseEnumElement = function () {
- if (this.currentNode() !== null && this.currentNode().kind() === 243 /* EnumElement */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 244 /* EnumElement */) {
return this.eatNode();
}
@@ -22211,7 +22279,7 @@ var TypeScript;
case 55 /* PrivateKeyword */:
case 58 /* StaticKeyword */:
case 47 /* ExportKeyword */:
- case 63 /* DeclareKeyword */:
+ case 64 /* DeclareKeyword */:
return true;
default:
@@ -22281,7 +22349,7 @@ var TypeScript;
var identifier = this.eatIdentifierToken();
var typeParameterList = this.parseOptionalTypeParameterList(false);
var heritageClauses = this.parseHeritageClauses();
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var classElements = TypeScript.Syntax.emptyList;
if (openBraceToken.width() > 0) {
@@ -22291,12 +22359,12 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.classDeclaration(modifiers, classKeyword, identifier, typeParameterList, heritageClauses, openBraceToken, classElements, closeBraceToken);
};
ParserImpl.prototype.isConstructorDeclaration = function () {
- return this.currentToken().tokenKind === 62 /* ConstructorKeyword */;
+ return this.currentToken().tokenKind === 63 /* ConstructorKeyword */;
};
ParserImpl.isPublicOrPrivateKeyword = function (token) {
@@ -22306,7 +22374,7 @@ var TypeScript;
ParserImpl.prototype.isMemberAccessorDeclaration = function (inErrorRecovery) {
var index = this.modifierCount();
- if (this.peekToken(index).tokenKind !== 64 /* GetKeyword */ && this.peekToken(index).tokenKind !== 68 /* SetKeyword */) {
+ if (this.peekToken(index).tokenKind !== 65 /* GetKeyword */ && this.peekToken(index).tokenKind !== 69 /* SetKeyword */) {
return false;
}
@@ -22317,9 +22385,9 @@ var TypeScript;
ParserImpl.prototype.parseMemberAccessorDeclaration = function () {
var modifiers = this.parseModifiers();
- if (this.currentToken().tokenKind === 64 /* GetKeyword */) {
+ if (this.currentToken().tokenKind === 65 /* GetKeyword */) {
return this.parseGetMemberAccessorDeclaration(modifiers);
- } else if (this.currentToken().tokenKind === 68 /* SetKeyword */) {
+ } else if (this.currentToken().tokenKind === 69 /* SetKeyword */) {
return this.parseSetMemberAccessorDeclaration(modifiers);
} else {
throw TypeScript.Errors.invalidOperation();
@@ -22327,7 +22395,7 @@ var TypeScript;
};
ParserImpl.prototype.parseGetMemberAccessorDeclaration = function (modifiers) {
- var getKeyword = this.eatKeyword(64 /* GetKeyword */);
+ var getKeyword = this.eatKeyword(65 /* GetKeyword */);
var propertyName = this.eatPropertyName();
var parameterList = this.parseParameterList();
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
@@ -22337,7 +22405,7 @@ var TypeScript;
};
ParserImpl.prototype.parseSetMemberAccessorDeclaration = function (modifiers) {
- var setKeyword = this.eatKeyword(68 /* SetKeyword */);
+ var setKeyword = this.eatKeyword(69 /* SetKeyword */);
var propertyName = this.eatPropertyName();
var parameterList = this.parseParameterList();
var block = this.parseBlock(false, false);
@@ -22354,7 +22422,7 @@ var TypeScript;
};
ParserImpl.prototype.parseConstructorDeclaration = function () {
- var constructorKeyword = this.eatKeyword(62 /* ConstructorKeyword */);
+ var constructorKeyword = this.eatKeyword(63 /* ConstructorKeyword */);
var parameterList = this.parseParameterList();
var semicolonToken = null;
@@ -22425,10 +22493,10 @@ var TypeScript;
ParserImpl.prototype.isDefinitelyMemberVariablePropertyName = function (index) {
if (TypeScript.SyntaxFacts.isAnyKeyword(this.peekToken(index).tokenKind)) {
switch (this.peekToken(index + 1).tokenKind) {
- case 78 /* SemicolonToken */:
- case 107 /* EqualsToken */:
- case 106 /* ColonToken */:
- case 71 /* CloseBraceToken */:
+ case 79 /* SemicolonToken */:
+ case 108 /* EqualsToken */:
+ case 107 /* ColonToken */:
+ case 72 /* CloseBraceToken */:
case 10 /* EndOfFileToken */:
return true;
default:
@@ -22502,9 +22570,9 @@ var TypeScript;
ParserImpl.prototype.tryAddUnexpectedEqualsGreaterThanToken = function (callSignature) {
var token0 = this.currentToken();
- var hasEqualsGreaterThanToken = token0.tokenKind === 85 /* EqualsGreaterThanToken */;
+ var hasEqualsGreaterThanToken = token0.tokenKind === 86 /* EqualsGreaterThanToken */;
if (hasEqualsGreaterThanToken) {
- var diagnostic = new TypeScript.Diagnostic(this.fileName, this.currentTokenStart(), token0.width(), TypeScript.DiagnosticCode.Unexpected_token_0_expected, [TypeScript.SyntaxFacts.getText(70 /* OpenBraceToken */)]);
+ var diagnostic = new TypeScript.Diagnostic(this.fileName, this.currentTokenStart(), token0.width(), TypeScript.DiagnosticCode.Unexpected_token_0_expected, [TypeScript.SyntaxFacts.getText(71 /* OpenBraceToken */)]);
this.addDiagnostic(diagnostic);
var token = this.eatAnyToken();
@@ -22544,11 +22612,11 @@ var TypeScript;
ParserImpl.prototype.isModuleDeclaration = function () {
var index = this.modifierCount();
- if (index > 0 && this.peekToken(index).tokenKind === 65 /* ModuleKeyword */) {
+ if (index > 0 && this.peekToken(index).tokenKind === 66 /* ModuleKeyword */) {
return true;
}
- if (this.currentToken().tokenKind === 65 /* ModuleKeyword */) {
+ if (this.currentToken().tokenKind === 66 /* ModuleKeyword */) {
var token1 = this.peekToken(1);
return this.isIdentifier(token1) || token1.tokenKind === 14 /* StringLiteral */;
}
@@ -22558,7 +22626,7 @@ var TypeScript;
ParserImpl.prototype.parseModuleDeclaration = function () {
var modifiers = this.parseModifiers();
- var moduleKeyword = this.eatKeyword(65 /* ModuleKeyword */);
+ var moduleKeyword = this.eatKeyword(66 /* ModuleKeyword */);
var moduleName = null;
var stringLiteral = null;
@@ -22569,7 +22637,7 @@ var TypeScript;
moduleName = this.parseName();
}
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var moduleElements = TypeScript.Syntax.emptyList;
if (openBraceToken.width() > 0) {
@@ -22578,7 +22646,7 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.moduleDeclaration(modifiers, moduleKeyword, moduleName, stringLiteral, openBraceToken, moduleElements, closeBraceToken);
};
@@ -22605,7 +22673,7 @@ var TypeScript;
};
ParserImpl.prototype.parseObjectType = function () {
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var typeMembers = TypeScript.Syntax.emptySeparatedList;
if (openBraceToken.width() > 0) {
@@ -22614,7 +22682,7 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.objectType(openBraceToken, typeMembers, closeBraceToken);
};
@@ -22654,9 +22722,9 @@ var TypeScript;
};
ParserImpl.prototype.parseIndexSignature = function () {
- var openBracketToken = this.eatToken(74 /* OpenBracketToken */);
+ var openBracketToken = this.eatToken(75 /* OpenBracketToken */);
var parameter = this.parseParameter();
- var closeBracketToken = this.eatToken(75 /* CloseBracketToken */);
+ var closeBracketToken = this.eatToken(76 /* CloseBracketToken */);
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
return this.factory.indexSignature(openBracketToken, parameter, closeBracketToken, typeAnnotation);
@@ -22664,7 +22732,7 @@ var TypeScript;
ParserImpl.prototype.parseMethodSignature = function () {
var propertyName = this.eatPropertyName();
- var questionToken = this.tryEatToken(105 /* QuestionToken */);
+ var questionToken = this.tryEatToken(106 /* QuestionToken */);
var callSignature = this.parseCallSignature(false);
return this.factory.methodSignature(propertyName, questionToken, callSignature);
@@ -22672,7 +22740,7 @@ var TypeScript;
ParserImpl.prototype.parsePropertySignature = function () {
var propertyName = this.eatPropertyName();
- var questionToken = this.tryEatToken(105 /* QuestionToken */);
+ var questionToken = this.tryEatToken(106 /* QuestionToken */);
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
return this.factory.propertySignature(propertyName, questionToken, typeAnnotation);
@@ -22680,7 +22748,7 @@ var TypeScript;
ParserImpl.prototype.isCallSignature = function (tokenIndex) {
var tokenKind = this.peekToken(tokenIndex).tokenKind;
- return tokenKind === 72 /* OpenParenToken */ || tokenKind === 80 /* LessThanToken */;
+ return tokenKind === 73 /* OpenParenToken */ || tokenKind === 81 /* LessThanToken */;
};
ParserImpl.prototype.isConstructSignature = function () {
@@ -22689,11 +22757,11 @@ var TypeScript;
}
var token1 = this.peekToken(1);
- return token1.tokenKind === 80 /* LessThanToken */ || token1.tokenKind === 72 /* OpenParenToken */;
+ return token1.tokenKind === 81 /* LessThanToken */ || token1.tokenKind === 73 /* OpenParenToken */;
};
ParserImpl.prototype.isIndexSignature = function () {
- return this.currentToken().tokenKind === 74 /* OpenBracketToken */;
+ return this.currentToken().tokenKind === 75 /* OpenBracketToken */;
};
ParserImpl.prototype.isMethodSignature = function (inErrorRecovery) {
@@ -22702,7 +22770,7 @@ var TypeScript;
return true;
}
- if (this.peekToken(1).tokenKind === 105 /* QuestionToken */ && this.isCallSignature(2)) {
+ if (this.peekToken(1).tokenKind === 106 /* QuestionToken */ && this.isCallSignature(2)) {
return true;
}
}
@@ -22833,9 +22901,9 @@ var TypeScript;
var doKeyword = this.eatKeyword(22 /* DoKeyword */);
var statement = this.parseStatement();
var whileKeyword = this.eatKeyword(42 /* WhileKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var condition = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var semicolonToken = this.eatExplicitOrAutomaticSemicolon(true);
@@ -22843,12 +22911,12 @@ var TypeScript;
};
ParserImpl.prototype.isLabeledStatement = function () {
- return this.isIdentifier(this.currentToken()) && this.peekToken(1).tokenKind === 106 /* ColonToken */;
+ return this.isIdentifier(this.currentToken()) && this.peekToken(1).tokenKind === 107 /* ColonToken */;
};
ParserImpl.prototype.parseLabeledStatement = function () {
var identifier = this.eatIdentifierToken();
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var statement = this.parseStatement();
return this.factory.labeledStatement(identifier, colonToken, statement);
@@ -22885,10 +22953,10 @@ var TypeScript;
ParserImpl.prototype.parseCatchClause = function () {
var catchKeyword = this.eatKeyword(17 /* CatchKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var identifier = this.eatIdentifierToken();
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var savedListParsingState = this.listParsingState;
this.listParsingState |= 128 /* CatchBlock_Statements */;
@@ -22915,9 +22983,9 @@ var TypeScript;
ParserImpl.prototype.parseWithStatement = function () {
var withKeyword = this.eatKeyword(43 /* WithKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var condition = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
return this.factory.withStatement(withKeyword, openParenToken, condition, closeParenToken, statement);
@@ -22929,9 +22997,9 @@ var TypeScript;
ParserImpl.prototype.parseWhileStatement = function () {
var whileKeyword = this.eatKeyword(42 /* WhileKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var condition = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
return this.factory.whileStatement(whileKeyword, openParenToken, condition, closeParenToken, statement);
@@ -22942,11 +23010,11 @@ var TypeScript;
return false;
}
- return this.currentToken().tokenKind === 78 /* SemicolonToken */;
+ return this.currentToken().tokenKind === 79 /* SemicolonToken */;
};
ParserImpl.prototype.parseEmptyStatement = function () {
- var semicolonToken = this.eatToken(78 /* SemicolonToken */);
+ var semicolonToken = this.eatToken(79 /* SemicolonToken */);
return this.factory.emptyStatement(semicolonToken);
};
@@ -22956,12 +23024,12 @@ var TypeScript;
ParserImpl.prototype.parseForOrForInStatement = function () {
var forKeyword = this.eatKeyword(26 /* ForKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var currentToken = this.currentToken();
if (currentToken.tokenKind === 40 /* VarKeyword */) {
return this.parseForOrForInStatementWithVariableDeclaration(forKeyword, openParenToken);
- } else if (currentToken.tokenKind === 78 /* SemicolonToken */) {
+ } else if (currentToken.tokenKind === 79 /* SemicolonToken */) {
return this.parseForStatement(forKeyword, openParenToken);
} else {
return this.parseForOrForInStatementWithInitializer(forKeyword, openParenToken);
@@ -22981,7 +23049,7 @@ var TypeScript;
ParserImpl.prototype.parseForInStatementWithVariableDeclarationOrInitializer = function (forKeyword, openParenToken, variableDeclaration, initializer) {
var inKeyword = this.eatKeyword(29 /* InKeyword */);
var expression = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
return this.factory.forInStatement(forKeyword, openParenToken, variableDeclaration, initializer, inKeyword, expression, closeParenToken, statement);
@@ -22999,7 +23067,7 @@ var TypeScript;
ParserImpl.prototype.parseForStatement = function (forKeyword, openParenToken) {
var initializer = null;
- if (this.currentToken().tokenKind !== 78 /* SemicolonToken */ && this.currentToken().tokenKind !== 73 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
+ if (this.currentToken().tokenKind !== 79 /* SemicolonToken */ && this.currentToken().tokenKind !== 74 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
initializer = this.parseExpression(false);
}
@@ -23007,21 +23075,21 @@ var TypeScript;
};
ParserImpl.prototype.parseForStatementWithVariableDeclarationOrInitializer = function (forKeyword, openParenToken, variableDeclaration, initializer) {
- var firstSemicolonToken = this.eatToken(78 /* SemicolonToken */);
+ var firstSemicolonToken = this.eatToken(79 /* SemicolonToken */);
var condition = null;
- if (this.currentToken().tokenKind !== 78 /* SemicolonToken */ && this.currentToken().tokenKind !== 73 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
+ if (this.currentToken().tokenKind !== 79 /* SemicolonToken */ && this.currentToken().tokenKind !== 74 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
condition = this.parseExpression(true);
}
- var secondSemicolonToken = this.eatToken(78 /* SemicolonToken */);
+ var secondSemicolonToken = this.eatToken(79 /* SemicolonToken */);
var incrementor = null;
- if (this.currentToken().tokenKind !== 73 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
+ if (this.currentToken().tokenKind !== 74 /* CloseParenToken */ && this.currentToken().tokenKind !== 10 /* EndOfFileToken */) {
incrementor = this.parseExpression(true);
}
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
return this.factory.forStatement(forKeyword, openParenToken, variableDeclaration, initializer, firstSemicolonToken, condition, secondSemicolonToken, incrementor, closeParenToken, statement);
@@ -23069,11 +23137,11 @@ var TypeScript;
ParserImpl.prototype.parseSwitchStatement = function () {
var switchKeyword = this.eatKeyword(34 /* SwitchKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var expression = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var switchClauses = TypeScript.Syntax.emptyList;
if (openBraceToken.width() > 0) {
@@ -23082,7 +23150,7 @@ var TypeScript;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.switchStatement(switchKeyword, openParenToken, expression, closeParenToken, openBraceToken, switchClauses, closeBraceToken);
};
@@ -23119,7 +23187,7 @@ var TypeScript;
ParserImpl.prototype.parseCaseSwitchClause = function () {
var caseKeyword = this.eatKeyword(16 /* CaseKeyword */);
var expression = this.parseExpression(true);
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var statements = TypeScript.Syntax.emptyList;
if (colonToken.fullWidth() > 0) {
@@ -23133,7 +23201,7 @@ var TypeScript;
ParserImpl.prototype.parseDefaultSwitchClause = function () {
var defaultKeyword = this.eatKeyword(20 /* DefaultKeyword */);
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var statements = TypeScript.Syntax.emptyList;
if (colonToken.fullWidth() > 0) {
@@ -23186,7 +23254,7 @@ var TypeScript;
var currentToken = this.currentToken();
var kind = currentToken.tokenKind;
- if (kind === 70 /* OpenBraceToken */ || kind === 27 /* FunctionKeyword */) {
+ if (kind === 71 /* OpenBraceToken */ || kind === 27 /* FunctionKeyword */) {
return false;
}
@@ -23194,7 +23262,7 @@ var TypeScript;
};
ParserImpl.prototype.isAssignmentOrOmittedExpression = function () {
- if (this.currentToken().tokenKind === 79 /* CommaToken */) {
+ if (this.currentToken().tokenKind === 80 /* CommaToken */) {
return true;
}
@@ -23202,7 +23270,7 @@ var TypeScript;
};
ParserImpl.prototype.parseAssignmentOrOmittedExpression = function () {
- if (this.currentToken().tokenKind === 79 /* CommaToken */) {
+ if (this.currentToken().tokenKind === 80 /* CommaToken */) {
return this.factory.omittedExpression();
}
@@ -23219,29 +23287,29 @@ var TypeScript;
case 12 /* RegularExpressionLiteral */:
return true;
- case 74 /* OpenBracketToken */:
- case 72 /* OpenParenToken */:
+ case 75 /* OpenBracketToken */:
+ case 73 /* OpenParenToken */:
return true;
- case 80 /* LessThanToken */:
+ case 81 /* LessThanToken */:
return true;
- case 93 /* PlusPlusToken */:
- case 94 /* MinusMinusToken */:
- case 89 /* PlusToken */:
- case 90 /* MinusToken */:
- case 102 /* TildeToken */:
- case 101 /* ExclamationToken */:
+ case 94 /* PlusPlusToken */:
+ case 95 /* MinusMinusToken */:
+ case 90 /* PlusToken */:
+ case 91 /* MinusToken */:
+ case 103 /* TildeToken */:
+ case 102 /* ExclamationToken */:
return true;
- case 70 /* OpenBraceToken */:
+ case 71 /* OpenBraceToken */:
return true;
- case 85 /* EqualsGreaterThanToken */:
+ case 86 /* EqualsGreaterThanToken */:
return true;
- case 118 /* SlashToken */:
- case 119 /* SlashEqualsToken */:
+ case 119 /* SlashToken */:
+ case 120 /* SlashEqualsToken */:
return true;
case 50 /* SuperKeyword */:
@@ -23284,9 +23352,9 @@ var TypeScript;
ParserImpl.prototype.parseIfStatement = function () {
var ifKeyword = this.eatKeyword(28 /* IfKeyword */);
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var condition = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var statement = this.parseStatement();
var elseClause = null;
@@ -23334,7 +23402,7 @@ var TypeScript;
};
ParserImpl.prototype.isVariableDeclarator = function () {
- if (this.currentNode() !== null && this.currentNode().kind() === 224 /* VariableDeclarator */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 225 /* VariableDeclarator */) {
return true;
}
@@ -23342,7 +23410,7 @@ var TypeScript;
};
ParserImpl.prototype.canReuseVariableDeclaratorNode = function (node) {
- if (node === null || node.kind() !== 224 /* VariableDeclarator */) {
+ if (node === null || node.kind() !== 225 /* VariableDeclarator */) {
return false;
}
@@ -23371,21 +23439,21 @@ var TypeScript;
};
ParserImpl.prototype.isColonValueClause = function () {
- return this.currentToken().tokenKind === 106 /* ColonToken */;
+ return this.currentToken().tokenKind === 107 /* ColonToken */;
};
ParserImpl.prototype.isEqualsValueClause = function (inParameter) {
var token0 = this.currentToken();
- if (token0.tokenKind === 107 /* EqualsToken */) {
+ if (token0.tokenKind === 108 /* EqualsToken */) {
return true;
}
if (!this.previousToken().hasTrailingNewLine()) {
- if (token0.tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (token0.tokenKind === 86 /* EqualsGreaterThanToken */) {
return false;
}
- if (token0.tokenKind === 70 /* OpenBraceToken */ && inParameter) {
+ if (token0.tokenKind === 71 /* OpenBraceToken */ && inParameter) {
return false;
}
@@ -23396,7 +23464,7 @@ var TypeScript;
};
ParserImpl.prototype.parseEqualsValueClause = function (allowIn) {
- var equalsToken = this.eatToken(107 /* EqualsToken */);
+ var equalsToken = this.eatToken(108 /* EqualsToken */);
var value = this.parseAssignmentExpression(allowIn);
return this.factory.equalsValueClause(equalsToken, value);
@@ -23466,11 +23534,11 @@ var TypeScript;
continue;
}
- if (token0Kind === 105 /* QuestionToken */ && precedence <= 3 /* ConditionalExpressionPrecedence */) {
- var questionToken = this.eatToken(105 /* QuestionToken */);
+ if (token0Kind === 106 /* QuestionToken */ && precedence <= 3 /* ConditionalExpressionPrecedence */) {
+ var questionToken = this.eatToken(106 /* QuestionToken */);
var whenTrueExpression = this.parseAssignmentExpression(allowIn);
- var colon = this.eatToken(106 /* ColonToken */);
+ var colon = this.eatToken(107 /* ColonToken */);
var whenFalseExpression = this.parseAssignmentExpression(allowIn);
leftOperand = this.factory.conditionalExpression(leftOperand, questionToken, whenTrueExpression, colon, whenFalseExpression);
@@ -23486,7 +23554,7 @@ var TypeScript;
ParserImpl.prototype.tryMergeBinaryExpressionTokens = function () {
var token0 = this.currentToken();
- if (token0.tokenKind === 81 /* GreaterThanToken */ && !token0.hasTrailingTrivia()) {
+ if (token0.tokenKind === 82 /* GreaterThanToken */ && !token0.hasTrailingTrivia()) {
var storage = this.mergeTokensStorage;
storage[0] = 0 /* None */;
storage[1] = 0 /* None */;
@@ -23504,20 +23572,20 @@ var TypeScript;
}
}
- if (storage[0] === 81 /* GreaterThanToken */) {
- if (storage[1] === 81 /* GreaterThanToken */) {
- if (storage[2] === 107 /* EqualsToken */) {
- return { tokenCount: 4, syntaxKind: 114 /* GreaterThanGreaterThanGreaterThanEqualsToken */ };
+ if (storage[0] === 82 /* GreaterThanToken */) {
+ if (storage[1] === 82 /* GreaterThanToken */) {
+ if (storage[2] === 108 /* EqualsToken */) {
+ return { tokenCount: 4, syntaxKind: 115 /* GreaterThanGreaterThanGreaterThanEqualsToken */ };
} else {
- return { tokenCount: 3, syntaxKind: 97 /* GreaterThanGreaterThanGreaterThanToken */ };
+ return { tokenCount: 3, syntaxKind: 98 /* GreaterThanGreaterThanGreaterThanToken */ };
}
- } else if (storage[1] === 107 /* EqualsToken */) {
- return { tokenCount: 3, syntaxKind: 113 /* GreaterThanGreaterThanEqualsToken */ };
+ } else if (storage[1] === 108 /* EqualsToken */) {
+ return { tokenCount: 3, syntaxKind: 114 /* GreaterThanGreaterThanEqualsToken */ };
} else {
- return { tokenCount: 2, syntaxKind: 96 /* GreaterThanGreaterThanToken */ };
+ return { tokenCount: 2, syntaxKind: 97 /* GreaterThanGreaterThanToken */ };
}
- } else if (storage[0] === 107 /* EqualsToken */) {
- return { tokenCount: 2, syntaxKind: 83 /* GreaterThanEqualsToken */ };
+ } else if (storage[0] === 108 /* EqualsToken */) {
+ return { tokenCount: 2, syntaxKind: 84 /* GreaterThanEqualsToken */ };
}
}
@@ -23526,18 +23594,18 @@ var TypeScript;
ParserImpl.prototype.isRightAssociative = function (expressionKind) {
switch (expressionKind) {
- case 173 /* AssignmentExpression */:
- case 174 /* AddAssignmentExpression */:
- case 175 /* SubtractAssignmentExpression */:
- case 176 /* MultiplyAssignmentExpression */:
- case 177 /* DivideAssignmentExpression */:
- case 178 /* ModuloAssignmentExpression */:
- case 179 /* AndAssignmentExpression */:
- case 180 /* ExclusiveOrAssignmentExpression */:
- case 181 /* OrAssignmentExpression */:
- case 182 /* LeftShiftAssignmentExpression */:
- case 183 /* SignedRightShiftAssignmentExpression */:
- case 184 /* UnsignedRightShiftAssignmentExpression */:
+ case 174 /* AssignmentExpression */:
+ case 175 /* AddAssignmentExpression */:
+ case 176 /* SubtractAssignmentExpression */:
+ case 177 /* MultiplyAssignmentExpression */:
+ case 178 /* DivideAssignmentExpression */:
+ case 179 /* ModuloAssignmentExpression */:
+ case 180 /* AndAssignmentExpression */:
+ case 181 /* ExclusiveOrAssignmentExpression */:
+ case 182 /* OrAssignmentExpression */:
+ case 183 /* LeftShiftAssignmentExpression */:
+ case 184 /* SignedRightShiftAssignmentExpression */:
+ case 185 /* UnsignedRightShiftAssignmentExpression */:
return true;
default:
return false;
@@ -23557,7 +23625,7 @@ var TypeScript;
while (true) {
var currentTokenKind = this.currentToken().tokenKind;
switch (currentTokenKind) {
- case 72 /* OpenParenToken */:
+ case 73 /* OpenParenToken */:
if (inObjectCreation) {
return expression;
}
@@ -23565,7 +23633,7 @@ var TypeScript;
expression = this.factory.invocationExpression(expression, this.parseArgumentList(null));
continue;
- case 80 /* LessThanToken */:
+ case 81 /* LessThanToken */:
if (inObjectCreation) {
return expression;
}
@@ -23578,12 +23646,12 @@ var TypeScript;
break;
- case 74 /* OpenBracketToken */:
+ case 75 /* OpenBracketToken */:
expression = this.parseElementAccessExpression(expression, inObjectCreation);
continue;
- case 93 /* PlusPlusToken */:
- case 94 /* MinusMinusToken */:
+ case 94 /* PlusPlusToken */:
+ case 95 /* MinusMinusToken */:
if (this.previousToken() !== null && this.previousToken().hasTrailingNewLine()) {
break;
}
@@ -23591,8 +23659,8 @@ var TypeScript;
expression = this.factory.postfixUnaryExpression(TypeScript.SyntaxFacts.getPostfixUnaryExpressionFromOperatorToken(currentTokenKind), expression, this.eatAnyToken());
continue;
- case 76 /* DotToken */:
- expression = this.factory.memberAccessExpression(expression, this.eatToken(76 /* DotToken */), this.eatIdentifierNameToken());
+ case 77 /* DotToken */:
+ expression = this.factory.memberAccessExpression(expression, this.eatToken(77 /* DotToken */), this.eatIdentifierNameToken());
continue;
}
@@ -23603,14 +23671,14 @@ var TypeScript;
ParserImpl.prototype.tryParseArgumentList = function () {
var typeArgumentList = null;
- if (this.currentToken().tokenKind === 80 /* LessThanToken */) {
+ if (this.currentToken().tokenKind === 81 /* LessThanToken */) {
var rewindPoint = this.getRewindPoint();
try {
typeArgumentList = this.tryParseTypeArgumentList(true);
var token0 = this.currentToken();
- var isOpenParen = token0.tokenKind === 72 /* OpenParenToken */;
- var isDot = token0.tokenKind === 76 /* DotToken */;
+ var isOpenParen = token0.tokenKind === 73 /* OpenParenToken */;
+ var isDot = token0.tokenKind === 77 /* DotToken */;
var isOpenParenOrDot = isOpenParen || isDot;
if (typeArgumentList === null || !isOpenParenOrDot) {
this.rewind(rewindPoint);
@@ -23621,14 +23689,14 @@ var TypeScript;
var diagnostic = new TypeScript.Diagnostic(this.fileName, this.currentTokenStart(), token0.width(), TypeScript.DiagnosticCode.A_parameter_list_must_follow_a_generic_type_argument_list_expected, null);
this.addDiagnostic(diagnostic);
- return this.factory.argumentList(typeArgumentList, TypeScript.Syntax.emptyToken(72 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.emptyToken(73 /* CloseParenToken */));
+ return this.factory.argumentList(typeArgumentList, TypeScript.Syntax.emptyToken(73 /* OpenParenToken */), TypeScript.Syntax.emptySeparatedList, TypeScript.Syntax.emptyToken(74 /* CloseParenToken */));
}
} finally {
this.releaseRewindPoint(rewindPoint);
}
}
- if (this.currentToken().tokenKind === 72 /* OpenParenToken */) {
+ if (this.currentToken().tokenKind === 73 /* OpenParenToken */) {
return this.parseArgumentList(typeArgumentList);
}
@@ -23636,7 +23704,7 @@ var TypeScript;
};
ParserImpl.prototype.parseArgumentList = function (typeArgumentList) {
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var arguments = TypeScript.Syntax.emptySeparatedList;
if (openParenToken.fullWidth() > 0) {
@@ -23645,17 +23713,17 @@ var TypeScript;
openParenToken = this.addSkippedTokensAfterToken(openParenToken, result.skippedTokens);
}
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
return this.factory.argumentList(typeArgumentList, openParenToken, arguments, closeParenToken);
};
ParserImpl.prototype.parseElementAccessExpression = function (expression, inObjectCreation) {
var start = this.currentTokenStart();
- var openBracketToken = this.eatToken(74 /* OpenBracketToken */);
+ var openBracketToken = this.eatToken(75 /* OpenBracketToken */);
var argumentExpression;
- if (this.currentToken().tokenKind === 75 /* CloseBracketToken */ && inObjectCreation) {
+ if (this.currentToken().tokenKind === 76 /* CloseBracketToken */ && inObjectCreation) {
var end = this.currentTokenStart() + this.currentToken().width();
var diagnostic = new TypeScript.Diagnostic(this.fileName, start, end - start, TypeScript.DiagnosticCode.new_T_cannot_be_used_to_create_an_array_Use_new_Array_T_instead, null);
this.addDiagnostic(diagnostic);
@@ -23665,7 +23733,7 @@ var TypeScript;
argumentExpression = this.parseExpression(true);
}
- var closeBracketToken = this.eatToken(75 /* CloseBracketToken */);
+ var closeBracketToken = this.eatToken(76 /* CloseBracketToken */);
return this.factory.elementAccessExpression(expression, openBracketToken, argumentExpression, closeBracketToken);
};
@@ -23673,7 +23741,7 @@ var TypeScript;
ParserImpl.prototype.parseTermWorker = function () {
var currentToken = this.currentToken();
- if (currentToken.tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (currentToken.tokenKind === 86 /* EqualsGreaterThanToken */) {
return this.parseSimpleArrowFunctionExpression();
}
@@ -23725,20 +23793,20 @@ var TypeScript;
case 14 /* StringLiteral */:
return this.parseLiteralExpression();
- case 74 /* OpenBracketToken */:
+ case 75 /* OpenBracketToken */:
return this.parseArrayLiteralExpression();
- case 70 /* OpenBraceToken */:
+ case 71 /* OpenBraceToken */:
return this.parseObjectLiteralExpression();
- case 72 /* OpenParenToken */:
+ case 73 /* OpenParenToken */:
return this.parseParenthesizedOrArrowFunctionExpression();
- case 80 /* LessThanToken */:
+ case 81 /* LessThanToken */:
return this.parseCastOrArrowFunctionExpression();
- case 118 /* SlashToken */:
- case 119 /* SlashEqualsToken */:
+ case 119 /* SlashToken */:
+ case 120 /* SlashEqualsToken */:
var result = this.tryReparseDivideAsRegularExpression();
if (result !== null) {
return result;
@@ -23766,17 +23834,17 @@ var TypeScript;
case 14 /* StringLiteral */:
case 13 /* NumericLiteral */:
case 12 /* RegularExpressionLiteral */:
- case 93 /* PlusPlusToken */:
- case 94 /* MinusMinusToken */:
- case 75 /* CloseBracketToken */:
- case 71 /* CloseBraceToken */:
+ case 94 /* PlusPlusToken */:
+ case 95 /* MinusMinusToken */:
+ case 76 /* CloseBracketToken */:
+ case 72 /* CloseBraceToken */:
return null;
}
}
currentToken = this.currentTokenAllowingRegularExpression();
- if (currentToken.tokenKind === 118 /* SlashToken */ || currentToken.tokenKind === 119 /* SlashEqualsToken */) {
+ if (currentToken.tokenKind === 119 /* SlashToken */ || currentToken.tokenKind === 120 /* SlashEqualsToken */) {
return null;
} else if (currentToken.tokenKind === 12 /* RegularExpressionLiteral */) {
return this.parseLiteralExpression();
@@ -23850,9 +23918,9 @@ var TypeScript;
};
ParserImpl.prototype.parseCastExpression = function () {
- var lessThanToken = this.eatToken(80 /* LessThanToken */);
+ var lessThanToken = this.eatToken(81 /* LessThanToken */);
var type = this.parseType();
- var greaterThanToken = this.eatToken(81 /* GreaterThanToken */);
+ var greaterThanToken = this.eatToken(82 /* GreaterThanToken */);
var expression = this.parseUnaryExpression();
return this.factory.castExpression(lessThanToken, type, greaterThanToken, expression);
@@ -23864,9 +23932,9 @@ var TypeScript;
return result;
}
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var expression = this.parseExpression(true);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
return this.factory.parenthesizedExpression(openParenToken, expression, closeParenToken);
};
@@ -23899,11 +23967,11 @@ var TypeScript;
var callSignature = this.parseCallSignature(true);
- if (requireArrow && this.currentToken().tokenKind !== 85 /* EqualsGreaterThanToken */) {
+ if (requireArrow && this.currentToken().tokenKind !== 86 /* EqualsGreaterThanToken */) {
return null;
}
- var equalsGreaterThanToken = this.eatToken(85 /* EqualsGreaterThanToken */);
+ var equalsGreaterThanToken = this.eatToken(86 /* EqualsGreaterThanToken */);
var body = this.parseArrowFunctionBody();
return this.factory.parenthesizedArrowFunctionExpression(callSignature, equalsGreaterThanToken, body);
@@ -23918,40 +23986,40 @@ var TypeScript;
};
ParserImpl.prototype.isSimpleArrowFunctionExpression = function () {
- if (this.currentToken().tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (this.currentToken().tokenKind === 86 /* EqualsGreaterThanToken */) {
return true;
}
- return this.isIdentifier(this.currentToken()) && this.peekToken(1).tokenKind === 85 /* EqualsGreaterThanToken */;
+ return this.isIdentifier(this.currentToken()) && this.peekToken(1).tokenKind === 86 /* EqualsGreaterThanToken */;
};
ParserImpl.prototype.parseSimpleArrowFunctionExpression = function () {
var identifier = this.eatIdentifierToken();
- var equalsGreaterThanToken = this.eatToken(85 /* EqualsGreaterThanToken */);
+ var equalsGreaterThanToken = this.eatToken(86 /* EqualsGreaterThanToken */);
var body = this.parseArrowFunctionBody();
return this.factory.simpleArrowFunctionExpression(identifier, equalsGreaterThanToken, body);
};
ParserImpl.prototype.isBlock = function () {
- return this.currentToken().tokenKind === 70 /* OpenBraceToken */;
+ return this.currentToken().tokenKind === 71 /* OpenBraceToken */;
};
ParserImpl.prototype.isDefinitelyArrowFunctionExpression = function () {
var token0 = this.currentToken();
- if (token0.tokenKind !== 72 /* OpenParenToken */) {
+ if (token0.tokenKind !== 73 /* OpenParenToken */) {
return false;
}
var token1 = this.peekToken(1);
var token2;
- if (token1.tokenKind === 73 /* CloseParenToken */) {
+ if (token1.tokenKind === 74 /* CloseParenToken */) {
token2 = this.peekToken(2);
- return token2.tokenKind === 106 /* ColonToken */ || token2.tokenKind === 85 /* EqualsGreaterThanToken */ || token2.tokenKind === 70 /* OpenBraceToken */;
+ return token2.tokenKind === 107 /* ColonToken */ || token2.tokenKind === 86 /* EqualsGreaterThanToken */ || token2.tokenKind === 71 /* OpenBraceToken */;
}
- if (token1.tokenKind === 77 /* DotDotDotToken */) {
+ if (token1.tokenKind === 78 /* DotDotDotToken */) {
return true;
}
@@ -23960,19 +24028,19 @@ var TypeScript;
}
token2 = this.peekToken(2);
- if (token2.tokenKind === 106 /* ColonToken */) {
+ if (token2.tokenKind === 107 /* ColonToken */) {
return true;
}
var token3 = this.peekToken(3);
- if (token2.tokenKind === 105 /* QuestionToken */) {
- if (token3.tokenKind === 106 /* ColonToken */ || token3.tokenKind === 73 /* CloseParenToken */ || token3.tokenKind === 79 /* CommaToken */) {
+ if (token2.tokenKind === 106 /* QuestionToken */) {
+ if (token3.tokenKind === 107 /* ColonToken */ || token3.tokenKind === 74 /* CloseParenToken */ || token3.tokenKind === 80 /* CommaToken */) {
return true;
}
}
- if (token2.tokenKind === 73 /* CloseParenToken */) {
- if (token3.tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (token2.tokenKind === 74 /* CloseParenToken */) {
+ if (token3.tokenKind === 86 /* EqualsGreaterThanToken */) {
return true;
}
}
@@ -23982,7 +24050,7 @@ var TypeScript;
ParserImpl.prototype.isPossiblyArrowFunctionExpression = function () {
var token0 = this.currentToken();
- if (token0.tokenKind !== 72 /* OpenParenToken */) {
+ if (token0.tokenKind !== 73 /* OpenParenToken */) {
return true;
}
@@ -23993,17 +24061,17 @@ var TypeScript;
}
var token2 = this.peekToken(2);
- if (token2.tokenKind === 107 /* EqualsToken */) {
+ if (token2.tokenKind === 108 /* EqualsToken */) {
return true;
}
- if (token2.tokenKind === 79 /* CommaToken */) {
+ if (token2.tokenKind === 80 /* CommaToken */) {
return true;
}
- if (token2.tokenKind === 73 /* CloseParenToken */) {
+ if (token2.tokenKind === 74 /* CloseParenToken */) {
var token3 = this.peekToken(3);
- if (token3.tokenKind === 106 /* ColonToken */) {
+ if (token3.tokenKind === 107 /* ColonToken */) {
return true;
}
}
@@ -24012,13 +24080,13 @@ var TypeScript;
};
ParserImpl.prototype.parseObjectLiteralExpression = function () {
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var result = this.parseSeparatedSyntaxList(32768 /* ObjectLiteralExpression_PropertyAssignments */);
var propertyAssignments = result.list;
openBraceToken = this.addSkippedTokensAfterToken(openBraceToken, result.skippedTokens);
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.objectLiteralExpression(openBraceToken, propertyAssignments, closeBraceToken);
};
@@ -24042,14 +24110,14 @@ var TypeScript;
};
ParserImpl.prototype.isGetAccessorPropertyAssignment = function (inErrorRecovery) {
- return this.currentToken().tokenKind === 64 /* GetKeyword */ && this.isPropertyName(this.peekToken(1), inErrorRecovery);
+ return this.currentToken().tokenKind === 65 /* GetKeyword */ && this.isPropertyName(this.peekToken(1), inErrorRecovery);
};
ParserImpl.prototype.parseGetAccessorPropertyAssignment = function () {
- var getKeyword = this.eatKeyword(64 /* GetKeyword */);
+ var getKeyword = this.eatKeyword(65 /* GetKeyword */);
var propertyName = this.eatPropertyName();
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var typeAnnotation = this.parseOptionalTypeAnnotation(false);
var block = this.parseBlock(false, true);
@@ -24057,15 +24125,15 @@ var TypeScript;
};
ParserImpl.prototype.isSetAccessorPropertyAssignment = function (inErrorRecovery) {
- return this.currentToken().tokenKind === 68 /* SetKeyword */ && this.isPropertyName(this.peekToken(1), inErrorRecovery);
+ return this.currentToken().tokenKind === 69 /* SetKeyword */ && this.isPropertyName(this.peekToken(1), inErrorRecovery);
};
ParserImpl.prototype.parseSetAccessorPropertyAssignment = function () {
- var setKeyword = this.eatKeyword(68 /* SetKeyword */);
+ var setKeyword = this.eatKeyword(69 /* SetKeyword */);
var propertyName = this.eatPropertyName();
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var parameter = this.parseParameter();
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
var block = this.parseBlock(false, true);
return this.factory.setAccessorPropertyAssignment(setKeyword, propertyName, openParenToken, parameter, closeParenToken, block);
@@ -24093,7 +24161,7 @@ var TypeScript;
ParserImpl.prototype.parseSimplePropertyAssignment = function () {
var propertyName = this.eatPropertyName();
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var expression = this.parseAssignmentExpression(true);
return this.factory.simplePropertyAssignment(propertyName, colonToken, expression);
@@ -24119,13 +24187,13 @@ var TypeScript;
};
ParserImpl.prototype.parseArrayLiteralExpression = function () {
- var openBracketToken = this.eatToken(74 /* OpenBracketToken */);
+ var openBracketToken = this.eatToken(75 /* OpenBracketToken */);
var result = this.parseSeparatedSyntaxList(65536 /* ArrayLiteralExpression_AssignmentExpressions */);
var expressions = result.list;
openBracketToken = this.addSkippedTokensAfterToken(openBracketToken, result.skippedTokens);
- var closeBracketToken = this.eatToken(75 /* CloseBracketToken */);
+ var closeBracketToken = this.eatToken(76 /* CloseBracketToken */);
return this.factory.arrayLiteralExpression(openBracketToken, expressions, closeBracketToken);
};
@@ -24140,7 +24208,7 @@ var TypeScript;
};
ParserImpl.prototype.parseBlock = function (parseBlockEvenWithNoOpenBrace, checkForStrictMode) {
- var openBraceToken = this.eatToken(70 /* OpenBraceToken */);
+ var openBraceToken = this.eatToken(71 /* OpenBraceToken */);
var statements = TypeScript.Syntax.emptyList;
@@ -24155,7 +24223,7 @@ var TypeScript;
this.setStrictMode(savedIsInStrictMode);
}
- var closeBraceToken = this.eatToken(71 /* CloseBraceToken */);
+ var closeBraceToken = this.eatToken(72 /* CloseBraceToken */);
return this.factory.block(openBraceToken, statements, closeBraceToken);
};
@@ -24169,19 +24237,19 @@ var TypeScript;
};
ParserImpl.prototype.parseOptionalTypeParameterList = function (requireCompleteTypeParameterList) {
- if (this.currentToken().tokenKind !== 80 /* LessThanToken */) {
+ if (this.currentToken().tokenKind !== 81 /* LessThanToken */) {
return null;
}
var rewindPoint = this.getRewindPoint();
try {
- var lessThanToken = this.eatToken(80 /* LessThanToken */);
+ var lessThanToken = this.eatToken(81 /* LessThanToken */);
var result = this.parseSeparatedSyntaxList(524288 /* TypeParameterList_TypeParameters */);
var typeParameterList = result.list;
lessThanToken = this.addSkippedTokensAfterToken(lessThanToken, result.skippedTokens);
- var greaterThanToken = this.eatToken(81 /* GreaterThanToken */);
+ var greaterThanToken = this.eatToken(82 /* GreaterThanToken */);
if (requireCompleteTypeParameterList && greaterThanToken.fullWidth() === 0) {
this.rewind(rewindPoint);
@@ -24217,7 +24285,7 @@ var TypeScript;
};
ParserImpl.prototype.parseParameterList = function () {
- var openParenToken = this.eatToken(72 /* OpenParenToken */);
+ var openParenToken = this.eatToken(73 /* OpenParenToken */);
var parameters = TypeScript.Syntax.emptySeparatedList;
if (openParenToken.width() > 0) {
@@ -24226,12 +24294,12 @@ var TypeScript;
openParenToken = this.addSkippedTokensAfterToken(openParenToken, result.skippedTokens);
}
- var closeParenToken = this.eatToken(73 /* CloseParenToken */);
+ var closeParenToken = this.eatToken(74 /* CloseParenToken */);
return this.factory.parameterList(openParenToken, parameters, closeParenToken);
};
ParserImpl.prototype.isTypeAnnotation = function () {
- return this.currentToken().tokenKind === 106 /* ColonToken */;
+ return this.currentToken().tokenKind === 107 /* ColonToken */;
};
ParserImpl.prototype.parseOptionalTypeAnnotation = function (allowStringLiteral) {
@@ -24239,7 +24307,7 @@ var TypeScript;
};
ParserImpl.prototype.parseTypeAnnotation = function (allowStringLiteral) {
- var colonToken = this.eatToken(106 /* ColonToken */);
+ var colonToken = this.eatToken(107 /* ColonToken */);
var type = allowStringLiteral && this.currentToken().tokenKind === 14 /* StringLiteral */ ? this.eatToken(14 /* StringLiteral */) : this.parseType();
return this.factory.typeAnnotation(colonToken, type);
@@ -24255,9 +24323,9 @@ var TypeScript;
} else {
var type = this.parseNonArrayType();
- while (this.currentToken().tokenKind === 74 /* OpenBracketToken */) {
- var openBracketToken = this.eatToken(74 /* OpenBracketToken */);
- var closeBracketToken = this.eatToken(75 /* CloseBracketToken */);
+ while (this.currentToken().tokenKind === 75 /* OpenBracketToken */) {
+ var openBracketToken = this.eatToken(75 /* OpenBracketToken */);
+ var closeBracketToken = this.eatToken(76 /* CloseBracketToken */);
type = this.factory.arrayType(type, openBracketToken, closeBracketToken);
}
@@ -24309,7 +24377,7 @@ var TypeScript;
ParserImpl.prototype.parseFunctionType = function () {
var typeParameterList = this.parseOptionalTypeParameterList(false);
var parameterList = this.parseParameterList();
- var equalsGreaterThanToken = this.eatToken(85 /* EqualsGreaterThanToken */);
+ var equalsGreaterThanToken = this.eatToken(86 /* EqualsGreaterThanToken */);
var returnType = this.parseType();
return this.factory.functionType(typeParameterList, parameterList, equalsGreaterThanToken, returnType);
@@ -24318,7 +24386,7 @@ var TypeScript;
ParserImpl.prototype.parseConstructorType = function () {
var newKeyword = this.eatKeyword(31 /* NewKeyword */);
var parameterList = this.parseParameterList();
- var equalsGreaterThanToken = this.eatToken(85 /* EqualsGreaterThanToken */);
+ var equalsGreaterThanToken = this.eatToken(86 /* EqualsGreaterThanToken */);
var type = this.parseType();
return this.factory.constructorType(newKeyword, null, parameterList, equalsGreaterThanToken, type);
@@ -24329,12 +24397,12 @@ var TypeScript;
};
ParserImpl.prototype.isObjectType = function () {
- return this.currentToken().tokenKind === 70 /* OpenBraceToken */;
+ return this.currentToken().tokenKind === 71 /* OpenBraceToken */;
};
ParserImpl.prototype.isFunctionType = function () {
var tokenKind = this.currentToken().tokenKind;
- return tokenKind === 72 /* OpenParenToken */ || tokenKind === 80 /* LessThanToken */;
+ return tokenKind === 73 /* OpenParenToken */ || tokenKind === 81 /* LessThanToken */;
};
ParserImpl.prototype.isConstructorType = function () {
@@ -24348,9 +24416,10 @@ var TypeScript;
ParserImpl.prototype.isPredefinedType = function () {
switch (this.currentToken().tokenKind) {
case 60 /* AnyKeyword */:
- case 67 /* NumberKeyword */:
+ case 68 /* NumberKeyword */:
case 61 /* BooleanKeyword */:
- case 69 /* StringKeyword */:
+ case 62 /* BoolKeyword */:
+ case 70 /* StringKeyword */:
case 41 /* VoidKeyword */:
return true;
}
@@ -24359,12 +24428,12 @@ var TypeScript;
};
ParserImpl.prototype.isParameter = function () {
- if (this.currentNode() !== null && this.currentNode().kind() === 242 /* Parameter */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 243 /* Parameter */) {
return true;
}
var token = this.currentToken();
- if (token.tokenKind === 77 /* DotDotDotToken */) {
+ if (token.tokenKind === 78 /* DotDotDotToken */) {
return true;
}
@@ -24376,11 +24445,11 @@ var TypeScript;
};
ParserImpl.prototype.parseParameter = function () {
- if (this.currentNode() !== null && this.currentNode().kind() === 242 /* Parameter */) {
+ if (this.currentNode() !== null && this.currentNode().kind() === 243 /* Parameter */) {
return this.eatNode();
}
- var dotDotDotToken = this.tryEatToken(77 /* DotDotDotToken */);
+ var dotDotDotToken = this.tryEatToken(78 /* DotDotDotToken */);
var publicOrPrivateToken = null;
if (ParserImpl.isPublicOrPrivateKeyword(this.currentToken())) {
@@ -24388,7 +24457,7 @@ var TypeScript;
}
var identifier = this.eatIdentifierToken();
- var questionToken = this.tryEatToken(105 /* QuestionToken */);
+ var questionToken = this.tryEatToken(106 /* QuestionToken */);
var typeAnnotation = this.parseOptionalTypeAnnotation(true);
var equalsValueClause = null;
@@ -24526,7 +24595,7 @@ var TypeScript;
TypeScript.Debug.assert(skippedTokens !== items);
var separatorKind = this.separatorKind(currentListType);
- var allowAutomaticSemicolonInsertion = separatorKind === 78 /* SemicolonToken */;
+ var allowAutomaticSemicolonInsertion = separatorKind === 79 /* SemicolonToken */;
var inErrorRecovery = false;
var listWasTerminated = false;
@@ -24554,7 +24623,7 @@ var TypeScript;
inErrorRecovery = false;
var currentToken = this.currentToken();
- if (currentToken.tokenKind === separatorKind || currentToken.tokenKind === 79 /* CommaToken */) {
+ if (currentToken.tokenKind === separatorKind || currentToken.tokenKind === 80 /* CommaToken */) {
items.push(this.eatAnyToken());
continue;
}
@@ -24594,10 +24663,10 @@ var TypeScript;
case 65536 /* ArrayLiteralExpression_AssignmentExpressions */:
case 262144 /* TypeArgumentList_Types */:
case 524288 /* TypeParameterList_TypeParameters */:
- return 79 /* CommaToken */;
+ return 80 /* CommaToken */;
case 512 /* ObjectType_TypeMembers */:
- return 78 /* SemicolonToken */;
+ return 79 /* SemicolonToken */;
case 1 /* SourceUnit_ModuleElements */:
case 1024 /* ClassOrInterfaceDeclaration_HeritageClauses */:
@@ -24698,28 +24767,28 @@ var TypeScript;
};
ParserImpl.prototype.isExpectedEnumDeclaration_EnumElementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedModuleDeclaration_ModuleElementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedObjectType_TypeMembersTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedObjectLiteralExpression_PropertyAssignmentsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedLiteralExpression_AssignmentExpressionsTerminator = function () {
- return this.currentToken().tokenKind === 75 /* CloseBracketToken */;
+ return this.currentToken().tokenKind === 76 /* CloseBracketToken */;
};
ParserImpl.prototype.isExpectedTypeArgumentList_TypesTerminator = function () {
var token = this.currentToken();
- if (token.tokenKind === 81 /* GreaterThanToken */) {
+ if (token.tokenKind === 82 /* GreaterThanToken */) {
return true;
}
@@ -24732,11 +24801,11 @@ var TypeScript;
ParserImpl.prototype.isExpectedTypeParameterList_TypeParametersTerminator = function () {
var token = this.currentToken();
- if (token.tokenKind === 81 /* GreaterThanToken */) {
+ if (token.tokenKind === 82 /* GreaterThanToken */) {
return true;
}
- if (token.tokenKind === 72 /* OpenParenToken */ || token.tokenKind === 70 /* OpenBraceToken */ || token.tokenKind === 48 /* ExtendsKeyword */ || token.tokenKind === 51 /* ImplementsKeyword */) {
+ if (token.tokenKind === 73 /* OpenParenToken */ || token.tokenKind === 71 /* OpenBraceToken */ || token.tokenKind === 48 /* ExtendsKeyword */ || token.tokenKind === 51 /* ImplementsKeyword */) {
return true;
}
@@ -24745,15 +24814,15 @@ var TypeScript;
ParserImpl.prototype.isExpectedParameterList_ParametersTerminator = function () {
var token = this.currentToken();
- if (token.tokenKind === 73 /* CloseParenToken */) {
+ if (token.tokenKind === 74 /* CloseParenToken */) {
return true;
}
- if (token.tokenKind === 70 /* OpenBraceToken */) {
+ if (token.tokenKind === 71 /* OpenBraceToken */) {
return true;
}
- if (token.tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (token.tokenKind === 86 /* EqualsGreaterThanToken */) {
return true;
}
@@ -24761,7 +24830,7 @@ var TypeScript;
};
ParserImpl.prototype.isExpectedVariableDeclaration_VariableDeclarators_DisallowInTerminator = function () {
- if (this.currentToken().tokenKind === 78 /* SemicolonToken */ || this.currentToken().tokenKind === 73 /* CloseParenToken */) {
+ if (this.currentToken().tokenKind === 79 /* SemicolonToken */ || this.currentToken().tokenKind === 74 /* CloseParenToken */) {
return true;
}
@@ -24773,11 +24842,11 @@ var TypeScript;
};
ParserImpl.prototype.isExpectedVariableDeclaration_VariableDeclarators_AllowInTerminator = function () {
- if (this.previousToken().tokenKind === 79 /* CommaToken */) {
+ if (this.previousToken().tokenKind === 80 /* CommaToken */) {
return false;
}
- if (this.currentToken().tokenKind === 85 /* EqualsGreaterThanToken */) {
+ if (this.currentToken().tokenKind === 86 /* EqualsGreaterThanToken */) {
return true;
}
@@ -24786,7 +24855,7 @@ var TypeScript;
ParserImpl.prototype.isExpectedClassOrInterfaceDeclaration_HeritageClausesTerminator = function () {
var token0 = this.currentToken();
- if (token0.tokenKind === 70 /* OpenBraceToken */ || token0.tokenKind === 71 /* CloseBraceToken */) {
+ if (token0.tokenKind === 71 /* OpenBraceToken */ || token0.tokenKind === 72 /* CloseBraceToken */) {
return true;
}
@@ -24808,23 +24877,23 @@ var TypeScript;
ParserImpl.prototype.isExpectedArgumentList_AssignmentExpressionsTerminator = function () {
var token0 = this.currentToken();
- return token0.tokenKind === 73 /* CloseParenToken */ || token0.tokenKind === 78 /* SemicolonToken */;
+ return token0.tokenKind === 74 /* CloseParenToken */ || token0.tokenKind === 79 /* SemicolonToken */;
};
ParserImpl.prototype.isExpectedClassDeclaration_ClassElementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedSwitchStatement_SwitchClausesTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedSwitchClause_StatementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */ || this.isSwitchClause();
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */ || this.isSwitchClause();
};
ParserImpl.prototype.isExpectedBlock_StatementsTerminator = function () {
- return this.currentToken().tokenKind === 71 /* CloseBraceToken */;
+ return this.currentToken().tokenKind === 72 /* CloseBraceToken */;
};
ParserImpl.prototype.isExpectedTryBlock_StatementsTerminator = function () {
@@ -24903,7 +24972,7 @@ var TypeScript;
return true;
}
- if (this.currentToken().tokenKind === 79 /* CommaToken */) {
+ if (this.currentToken().tokenKind === 80 /* CommaToken */) {
return true;
}
@@ -25347,7 +25416,7 @@ var TypeScript;
} else if (!parameter.typeAnnotation) {
this.pushDiagnostic1(parameterFullStart, parameter, TypeScript.DiagnosticCode.Index_signature_parameter_must_have_a_type_annotation);
return true;
- } else if (parameter.typeAnnotation.type.kind() !== 69 /* StringKeyword */ && parameter.typeAnnotation.type.kind() !== 67 /* NumberKeyword */) {
+ } else if (parameter.typeAnnotation.type.kind() !== 70 /* StringKeyword */ && parameter.typeAnnotation.type.kind() !== 68 /* NumberKeyword */) {
this.pushDiagnostic1(parameterFullStart, parameter, TypeScript.DiagnosticCode.Index_signature_parameter_type_must_be_string_or_number);
return true;
}
@@ -25415,7 +25484,7 @@ var TypeScript;
GrammarCheckerWalker.prototype.checkForDisallowedDeclareModifier = function (modifiers) {
if (this.inAmbientDeclaration) {
- var declareToken = TypeScript.SyntaxUtilities.getToken(modifiers, 63 /* DeclareKeyword */);
+ var declareToken = TypeScript.SyntaxUtilities.getToken(modifiers, 64 /* DeclareKeyword */);
if (declareToken) {
this.pushDiagnostic1(this.childFullStart(modifiers, declareToken), declareToken, TypeScript.DiagnosticCode.declare_modifier_not_allowed_for_code_already_in_an_ambient_context);
@@ -25428,7 +25497,7 @@ var TypeScript;
GrammarCheckerWalker.prototype.checkForRequiredDeclareModifier = function (moduleElement, typeKeyword, modifiers) {
if (!this.inAmbientDeclaration && this.syntaxTree.isDeclaration()) {
- if (!TypeScript.SyntaxUtilities.containsToken(modifiers, 63 /* DeclareKeyword */)) {
+ if (!TypeScript.SyntaxUtilities.containsToken(modifiers, 64 /* DeclareKeyword */)) {
this.pushDiagnostic1(this.childFullStart(moduleElement, typeKeyword), typeKeyword.firstToken(), TypeScript.DiagnosticCode.declare_modifier_required_for_top_level_element);
return true;
}
@@ -25447,7 +25516,7 @@ var TypeScript;
var lastElement = i === (n - 1);
if (inFunctionOverloadChain) {
- if (moduleElement.kind() !== 129 /* FunctionDeclaration */) {
+ if (moduleElement.kind() !== 130 /* FunctionDeclaration */) {
this.pushDiagnostic1(moduleElementFullStart, moduleElement.firstToken(), TypeScript.DiagnosticCode.Function_implementation_expected);
return true;
}
@@ -25460,9 +25529,9 @@ var TypeScript;
}
}
- if (moduleElement.kind() === 129 /* FunctionDeclaration */) {
+ if (moduleElement.kind() === 130 /* FunctionDeclaration */) {
functionDeclaration = moduleElement;
- if (!TypeScript.SyntaxUtilities.containsToken(functionDeclaration.modifiers, 63 /* DeclareKeyword */)) {
+ if (!TypeScript.SyntaxUtilities.containsToken(functionDeclaration.modifiers, 64 /* DeclareKeyword */)) {
inFunctionOverloadChain = functionDeclaration.block === null;
functionOverloadChainName = functionDeclaration.identifier.valueText();
@@ -25484,7 +25553,7 @@ var TypeScript;
};
GrammarCheckerWalker.prototype.checkClassOverloads = function (node) {
- if (!this.inAmbientDeclaration && !TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (!this.inAmbientDeclaration && !TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
var classElementFullStart = this.childFullStart(node, node.classElements);
var inFunctionOverloadChain = false;
@@ -25500,7 +25569,7 @@ var TypeScript;
var isStaticOverload = null;
if (inFunctionOverloadChain) {
- if (classElement.kind() !== 135 /* MemberFunctionDeclaration */) {
+ if (classElement.kind() !== 136 /* MemberFunctionDeclaration */) {
this.pushDiagnostic1(classElementFullStart, classElement.firstToken(), TypeScript.DiagnosticCode.Function_implementation_expected);
return true;
}
@@ -25519,13 +25588,13 @@ var TypeScript;
return true;
}
} else if (inConstructorOverloadChain) {
- if (classElement.kind() !== 137 /* ConstructorDeclaration */) {
+ if (classElement.kind() !== 138 /* ConstructorDeclaration */) {
this.pushDiagnostic1(classElementFullStart, classElement.firstToken(), TypeScript.DiagnosticCode.Constructor_implementation_expected);
return true;
}
}
- if (classElement.kind() === 135 /* MemberFunctionDeclaration */) {
+ if (classElement.kind() === 136 /* MemberFunctionDeclaration */) {
memberFunctionDeclaration = classElement;
inFunctionOverloadChain = memberFunctionDeclaration.block === null;
@@ -25536,7 +25605,7 @@ var TypeScript;
this.pushDiagnostic1(classElementFullStart, classElement.firstToken(), TypeScript.DiagnosticCode.Function_implementation_expected);
return true;
}
- } else if (classElement.kind() === 137 /* ConstructorDeclaration */) {
+ } else if (classElement.kind() === 138 /* ConstructorDeclaration */) {
var constructorDeclaration = classElement;
inConstructorOverloadChain = constructorDeclaration.block === null;
@@ -25560,7 +25629,7 @@ var TypeScript;
var current = name;
while (current !== null) {
- if (current.kind() === 121 /* QualifiedName */) {
+ if (current.kind() === 122 /* QualifiedName */) {
var qualifiedName = current;
token = qualifiedName.right;
tokenFullStart = nameFullStart + this.childFullStart(qualifiedName, token);
@@ -25575,6 +25644,7 @@ var TypeScript;
switch (token.valueText()) {
case "any":
case "number":
+ case "bool":
case "boolean":
case "string":
case "void":
@@ -25593,7 +25663,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitClassDeclaration.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -25631,7 +25701,7 @@ var TypeScript;
for (var i = 0, n = modifiers.childCount(); i < n; i++) {
var modifier = modifiers.childAt(i);
- if (modifier.tokenKind === 63 /* DeclareKeyword */) {
+ if (modifier.tokenKind === 64 /* DeclareKeyword */) {
this.pushDiagnostic1(modifierFullStart, modifier, TypeScript.DiagnosticCode.declare_modifier_cannot_appear_on_an_interface_declaration);
return true;
}
@@ -25805,7 +25875,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitEnumDeclaration.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -25872,7 +25942,7 @@ var TypeScript;
return true;
}
- if (modifier.tokenKind === 63 /* DeclareKeyword */) {
+ if (modifier.tokenKind === 64 /* DeclareKeyword */) {
if (seenDeclareModifier) {
this.pushDiagnostic1(modifierFullStart, modifier, TypeScript.DiagnosticCode.Accessibility_modifier_already_seen);
return;
@@ -25886,7 +25956,7 @@ var TypeScript;
}
if (seenDeclareModifier) {
- this.pushDiagnostic1(modifierFullStart, modifier, TypeScript.DiagnosticCode._0_modifier_must_precede_1_modifier, [TypeScript.SyntaxFacts.getText(47 /* ExportKeyword */), TypeScript.SyntaxFacts.getText(63 /* DeclareKeyword */)]);
+ this.pushDiagnostic1(modifierFullStart, modifier, TypeScript.DiagnosticCode._0_modifier_must_precede_1_modifier, [TypeScript.SyntaxFacts.getText(47 /* ExportKeyword */), TypeScript.SyntaxFacts.getText(64 /* DeclareKeyword */)]);
return;
}
@@ -25905,9 +25975,9 @@ var TypeScript;
for (var i = 0, n = node.moduleElements.childCount(); i < n; i++) {
var child = node.moduleElements.childAt(i);
- if (child.kind() === 133 /* ImportDeclaration */) {
+ if (child.kind() === 134 /* ImportDeclaration */) {
var importDeclaration = child;
- if (importDeclaration.moduleReference.kind() === 245 /* ExternalModuleReference */) {
+ if (importDeclaration.moduleReference.kind() === 246 /* ExternalModuleReference */) {
this.pushDiagnostic1(currentElementFullStart, importDeclaration, TypeScript.DiagnosticCode.Import_declarations_in_an_internal_module_cannot_reference_an_external_module, null);
}
}
@@ -25920,7 +25990,7 @@ var TypeScript;
};
GrammarCheckerWalker.prototype.checkForDisallowedDeclareModifierOnImportDeclaration = function (modifiers) {
- var declareToken = TypeScript.SyntaxUtilities.getToken(modifiers, 63 /* DeclareKeyword */);
+ var declareToken = TypeScript.SyntaxUtilities.getToken(modifiers, 64 /* DeclareKeyword */);
if (declareToken) {
this.pushDiagnostic1(this.childFullStart(modifiers, declareToken), declareToken, TypeScript.DiagnosticCode.declare_modifier_not_allowed_on_import_declaration);
@@ -25943,13 +26013,13 @@ var TypeScript;
return;
}
- if (!TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */) && this.checkFunctionOverloads(node, node.moduleElements)) {
+ if (!TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */) && this.checkFunctionOverloads(node, node.moduleElements)) {
this.skip(node);
return;
}
if (node.stringLiteral) {
- if (!this.inAmbientDeclaration && !TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (!this.inAmbientDeclaration && !TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
var stringLiteralFullStart = this.childFullStart(node, node.stringLiteral);
this.pushDiagnostic1(stringLiteralFullStart, node.stringLiteral, TypeScript.DiagnosticCode.Only_ambient_modules_can_use_quoted_names);
this.skip(node);
@@ -25963,7 +26033,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitModuleDeclaration.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -25984,7 +26054,7 @@ var TypeScript;
for (var i = 0, n = moduleElements.childCount(); i < n; i++) {
var child = moduleElements.childAt(i);
- if (child.kind() === 134 /* ExportAssignment */) {
+ if (child.kind() === 135 /* ExportAssignment */) {
this.pushDiagnostic1(moduleElementFullStart, child, TypeScript.DiagnosticCode.Export_assignment_not_allowed_in_module_with_exported_element);
return true;
}
@@ -26002,7 +26072,7 @@ var TypeScript;
var errorFound = false;
for (var i = 0, n = moduleElements.childCount(); i < n; i++) {
var child = moduleElements.childAt(i);
- if (child.kind() === 134 /* ExportAssignment */) {
+ if (child.kind() === 135 /* ExportAssignment */) {
if (seenExportAssignment) {
this.pushDiagnostic1(moduleElementFullStart, child, TypeScript.DiagnosticCode.Module_cannot_have_multiple_export_assignments);
errorFound = true;
@@ -26022,7 +26092,7 @@ var TypeScript;
for (var i = 0, n = node.moduleElements.childCount(); i < n; i++) {
var child = node.moduleElements.childAt(i);
- if (child.kind() === 134 /* ExportAssignment */) {
+ if (child.kind() === 135 /* ExportAssignment */) {
this.pushDiagnostic1(moduleElementFullStart, child, TypeScript.DiagnosticCode.Export_assignment_cannot_be_used_in_internal_modules);
return true;
@@ -26222,7 +26292,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitFunctionDeclaration.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -26234,7 +26304,7 @@ var TypeScript;
}
var savedInAmbientDeclaration = this.inAmbientDeclaration;
- this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */);
+ this.inAmbientDeclaration = this.inAmbientDeclaration || this.syntaxTree.isDeclaration() || TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */);
_super.prototype.visitVariableStatement.call(this, node);
this.inAmbientDeclaration = savedInAmbientDeclaration;
};
@@ -26255,7 +26325,7 @@ var TypeScript;
};
GrammarCheckerWalker.prototype.visitObjectType = function (node) {
- if (this.checkListSeparators(node, node.typeMembers, 78 /* SemicolonToken */)) {
+ if (this.checkListSeparators(node, node.typeMembers, 79 /* SemicolonToken */)) {
this.skip(node);
return;
}
@@ -26312,6 +26382,16 @@ var TypeScript;
_super.prototype.visitSourceUnit.call(this, node);
};
+
+ GrammarCheckerWalker.prototype.visitExternalModuleReference = function (node) {
+ if (node.moduleOrRequireKeyword.tokenKind === 66 /* ModuleKeyword */ && !this.syntaxTree.parseOptions().allowModuleKeywordInExternalModuleReference()) {
+ this.pushDiagnostic1(this.position(), node.moduleOrRequireKeyword, TypeScript.DiagnosticCode.module_is_deprecated_Use_require_instead);
+ this.skip(node);
+ return;
+ }
+
+ _super.prototype.visitExternalModuleReference.call(this, node);
+ };
return GrammarCheckerWalker;
})(TypeScript.PositionTrackingWalker);
})(TypeScript || (TypeScript = {}));
@@ -30140,6 +30220,15 @@ var TypeScript;
}
TypeScript.filePath = filePath;
+ function convertToDirectoryPath(dirPath) {
+ if (dirPath && dirPath.charAt(dirPath.length - 1) !== "/") {
+ dirPath += "/";
+ }
+
+ return dirPath;
+ }
+ TypeScript.convertToDirectoryPath = convertToDirectoryPath;
+
var normalizePathRegEx = /^\\\\[^\\]/;
function normalizePath(path) {
if (normalizePathRegEx.test(path)) {
@@ -30174,7 +30263,9 @@ var TypeScript;
this.removeComments = false;
this.watch = false;
this.noResolve = false;
+ this.allowBool = false;
this.allowAutomaticSemicolonInsertion = true;
+ this.allowModuleKeywordInExternalModuleReference = false;
this.noImplicitAny = false;
this.noLib = false;
this.codeGenTarget = 0 /* EcmaScript3 */;
@@ -30188,6 +30279,7 @@ var TypeScript;
this.useCaseSensitiveFileResolution = false;
this.gatherDiagnostics = false;
this.updateTC = false;
+ this.codepage = null;
}
return CompilationSettings;
})();
@@ -30251,13 +30343,13 @@ var TypeScript;
if (TypeScript.SyntaxFacts.isIdentifierNameOrAnyKeyword(token)) {
token = scanner.scan(scannerDiagnostics, false);
- if (token.tokenKind === 107 /* EqualsToken */) {
+ if (token.tokenKind === 108 /* EqualsToken */) {
token = scanner.scan(scannerDiagnostics, false);
- if (token.tokenKind === 65 /* ModuleKeyword */ || token.tokenKind === 66 /* RequireKeyword */) {
+ if (token.tokenKind === 66 /* ModuleKeyword */ || token.tokenKind === 67 /* RequireKeyword */) {
token = scanner.scan(scannerDiagnostics, false);
- if (token.tokenKind === 72 /* OpenParenToken */) {
+ if (token.tokenKind === 73 /* OpenParenToken */) {
var afterOpenParenPosition = scanner.absoluteIndex();
token = scanner.scan(scannerDiagnostics, false);
@@ -30347,7 +30439,7 @@ var TypeScript;
TypeScript.preProcessFile = preProcessFile;
function getParseOptions(settings) {
- return new TypeScript.ParseOptions(settings.codeGenTarget, settings.allowAutomaticSemicolonInsertion);
+ return new TypeScript.ParseOptions(settings.codeGenTarget, settings.allowAutomaticSemicolonInsertion, settings.allowModuleKeywordInExternalModuleReference);
}
TypeScript.getParseOptions = getParseOptions;
})(TypeScript || (TypeScript = {}));
@@ -31409,6 +31501,16 @@ var TypeScript;
return false;
};
+ DeclarationEmitter.prototype.resolveScriptReference = function (document, reference) {
+ if (!this.compiler.settings.noResolve || TypeScript.isRooted(reference)) {
+ return reference;
+ }
+
+ var documentDir = TypeScript.convertToDirectoryPath(TypeScript.switchToForwardSlashes(TypeScript.getRootFilePath(document.fileName)));
+ var resolvedReferencePath = this.compiler.emitOptions.ioHost.resolvePath(documentDir + reference);
+ return resolvedReferencePath;
+ };
+
DeclarationEmitter.prototype.emitReferencePaths = function (script) {
if (this.emittedReferencePaths) {
return;
@@ -31419,10 +31521,10 @@ var TypeScript;
var scriptReferences = script.referencedFiles;
var addedGlobalDocument = false;
for (var j = 0; j < scriptReferences.length; j++) {
- var currentReference = scriptReferences[j];
+ var currentReference = this.resolveScriptReference(this.document, scriptReferences[j]);
var document = this.compiler.getDocument(currentReference);
- if (this.compiler.emitOptions.outputMany || document.script.isDeclareFile || document.script.topLevelMod || !addedGlobalDocument) {
+ if (document && (this.compiler.emitOptions.outputMany || document.script.isDeclareFile || document.script.topLevelMod || !addedGlobalDocument)) {
documents = documents.concat(document);
if (!document.script.isDeclareFile && document.script.topLevelMod) {
addedGlobalDocument = true;
@@ -31435,10 +31537,10 @@ var TypeScript;
if (!allDocuments[i].script.isDeclareFile && !allDocuments[i].script.topLevelMod) {
var scriptReferences = allDocuments[i].script.referencedFiles;
for (var j = 0; j < scriptReferences.length; j++) {
- var currentReference = scriptReferences[j];
+ var currentReference = this.resolveScriptReference(allDocuments[i], scriptReferences[j]);
var document = this.compiler.getDocument(currentReference);
- if (document.script.isDeclareFile || document.script.topLevelMod) {
+ if (document && (document.script.isDeclareFile || document.script.topLevelMod)) {
for (var k = 0; k < documents.length; k++) {
if (documents[k] == document) {
break;
@@ -32568,6 +32670,10 @@ var TypeScript;
return true;
}
+ if (this.rootSymbol) {
+ return PullSymbol.getIsExternallyVisible(this.rootSymbol, this, inIsExternallyVisibleSymbols);
+ }
+
if (this.isType()) {
var associatedContainerSymbol = (this).getAssociatedContainerType();
if (associatedContainerSymbol) {
@@ -32581,6 +32687,19 @@ var TypeScript;
var container = this.getContainer();
if (container === null) {
+ var decls = this.getDeclarations();
+ if (decls.length) {
+ var parentDecl = decls[0].getParentDecl();
+ if (parentDecl) {
+ var parentSymbol = parentDecl.getSymbol();
+ if (!parentSymbol || parentDecl.kind == 1 /* Script */) {
+ return true;
+ }
+
+ return PullSymbol.getIsExternallyVisible(parentSymbol, this, inIsExternallyVisibleSymbols);
+ }
+ }
+
return true;
}
@@ -34707,7 +34826,7 @@ var TypeScript;
newSignature.mimicSignature(signature, resolver);
declAST = resolver.semanticInfoChain.getASTForDecl(decl);
- TypeScript.Debug.assert(declAST != null, "Call signature for type '" + typeToSpecialize.toString() + "' could not be specialized because of a stale declaration");
+ TypeScript.Debug.assert(declAST != null, "Call signature for type '" + typeToSpecialize.pullSymbolIDString + "' could not be specialized because of a stale declaration");
prevSpecializationSignature = decl.getSpecializingSignatureSymbol();
decl.setSpecializingSignatureSymbol(newSignature);
@@ -34779,7 +34898,7 @@ var TypeScript;
newSignature.mimicSignature(signature, resolver);
declAST = resolver.semanticInfoChain.getASTForDecl(decl);
- TypeScript.Debug.assert(declAST != null, "Construct signature for type '" + typeToSpecialize.toString() + "' could not be specialized because of a stale declaration");
+ TypeScript.Debug.assert(declAST != null, "Construct signature for type '" + typeToSpecialize.pullSymbolIDString + "' could not be specialized because of a stale declaration");
prevSpecializationSignature = decl.getSpecializingSignatureSymbol();
decl.setSpecializingSignatureSymbol(newSignature);
@@ -34851,7 +34970,7 @@ var TypeScript;
newSignature.mimicSignature(signature, resolver);
declAST = resolver.semanticInfoChain.getASTForDecl(decl);
- TypeScript.Debug.assert(declAST != null, "Index signature for type '" + typeToSpecialize.toString() + "' could not be specialized because of a stale declaration");
+ TypeScript.Debug.assert(declAST != null, "Index signature for type '" + typeToSpecialize.pullSymbolIDString + "' could not be specialized because of a stale declaration");
prevSpecializationSignature = decl.getSpecializingSignatureSymbol();
decl.setSpecializingSignatureSymbol(newSignature);
@@ -35118,9 +35237,22 @@ var TypeScript;
function getIDForTypeSubstitutions(types) {
var substitution = "";
+ var members = null;
for (var i = 0; i < types.length; i++) {
- substitution += types[i].pullSymbolIDString + "#";
+ if (types[i].kind != 8388608 /* ObjectType */) {
+ substitution += types[i].pullSymbolIDString + "#";
+ } else {
+ members = types[i].getMembers();
+
+ if (types[i].isResolved && members && members.length) {
+ for (var j = 0; j < members.length; j++) {
+ substitution += members[j].name + "@" + getIDForTypeSubstitutions([members[j].type]);
+ }
+ } else {
+ substitution += types[i].pullSymbolIDString + "#";
+ }
+ }
}
return substitution;
@@ -35338,6 +35470,7 @@ var TypeScript;
this.genericASTResolutionStack = [];
this.resolvingTypeReference = false;
this.resolvingNamespaceMemberAccess = false;
+ this.resolvingTypeQueryExpression = false;
this.resolveAggressively = false;
this.canUseTypeSymbol = false;
this.specializingToAny = false;
@@ -35722,7 +35855,7 @@ var TypeScript;
this._cachedRegExpInterfaceType = this.getSymbolFromDeclPath("RegExp", [], 16 /* Interface */);
}
- if (!this._cachedRegExpInterfaceType.isResolved) {
+ if (this._cachedRegExpInterfaceType && !this._cachedRegExpInterfaceType.isResolved) {
this.resolveDeclaredSymbol(this._cachedRegExpInterfaceType, null, new TypeScript.PullTypeResolutionContext());
}
@@ -36483,11 +36616,7 @@ var TypeScript;
this.validateVariableDeclarationGroups(containerDecl, context);
}
- if (!context.isInBaseTypeResolution()) {
- containerSymbol.setResolved();
- } else {
- containerSymbol.inResolution = false;
- }
+ containerSymbol.setResolved();
return containerSymbol;
};
@@ -36511,6 +36640,7 @@ var TypeScript;
};
PullTypeResolver.prototype.resolveReferenceTypeDeclaration = function (typeDeclAST, context) {
+ var _this = this;
var typeDecl = this.getDeclForAST(typeDeclAST);
var enclosingDecl = this.getEnclosingDecl(typeDecl);
var typeDeclSymbol = typeDecl.getSymbol();
@@ -36608,6 +36738,11 @@ var TypeScript;
if (wasInBaseTypeResolution) {
typeDeclSymbol.inResolution = false;
+
+ PullTypeResolver.typeCheckCallBacks.push(function () {
+ _this.resolveDeclaredSymbol(typeDeclSymbol, enclosingDecl, context);
+ });
+
return typeDeclSymbol;
}
@@ -37161,6 +37296,11 @@ var TypeScript;
if (funcDeclAST.returnTypeAnnotation) {
var returnTypeSymbol = this.resolveTypeReference(funcDeclAST.returnTypeAnnotation, functionDecl, context);
+ if (this.genericTypeIsUsedWithoutRequiredTypeArguments(returnTypeSymbol, funcDeclAST.returnTypeAnnotation, context)) {
+ context.postError(this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Generic_type_references_must_include_all_type_arguments, null, functionDecl);
+ returnTypeSymbol = this.specializeTypeToAny(returnTypeSymbol, functionDecl, context);
+ }
+
signature.returnType = returnTypeSymbol;
if (this.isTypeArgumentOrWrapper(returnTypeSymbol)) {
@@ -37414,7 +37554,10 @@ var TypeScript;
var savedResolvingTypeReference = context.resolvingTypeReference;
context.resolvingTypeReference = false;
+ var savedResolvingTypeQueryExpression = context.resolvingTypeQueryExpression;
+ context.resolvingTypeQueryExpression = true;
var valueSymbol = this.resolveAST(typeQueryTerm, false, enclosingDecl, context);
+ context.resolvingTypeQueryExpression = savedResolvingTypeQueryExpression;
context.resolvingTypeReference = savedResolvingTypeReference;
if (valueSymbol && valueSymbol.isAlias()) {
@@ -37653,13 +37796,25 @@ var TypeScript;
if (!(varDecl.typeExpr || varDecl.init)) {
var defaultType = this.semanticInfoChain.anyTypeSymbol;
- if (this.compilationSettings.noImplicitAny && ((varDecl.getVarFlags() & 16384 /* ForInVariable */) === 0)) {
- if (wrapperDecl.kind == 16384 /* Function */ || wrapperDecl.kind == 65536 /* Method */ || wrapperDecl.kind == 32768 /* ConstructorMethod */ || wrapperDecl.kind == 2097152 /* ConstructSignature */) {
+ if (this.compilationSettings.noImplicitAny && !TypeScript.hasFlag(varDecl.getVarFlags(), 16384 /* ForInVariable */)) {
+ if ((wrapperDecl.kind === 16384 /* Function */ || wrapperDecl.kind === 32768 /* ConstructorMethod */ || wrapperDecl.kind === 2097152 /* ConstructSignature */)) {
context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Parameter_0_of_1_implicitly_has_an_any_type, [varDecl.id.actualText, enclosingDecl.name], enclosingDecl);
- } else if (wrapperDecl.kind == 8388608 /* ObjectType */) {
+ } else if (wrapperDecl.kind === 65536 /* Method */) {
+ var parentDecl = wrapperDecl.getParentDecl();
+
+ if (!TypeScript.hasFlag(parentDecl.flags, 8 /* Ambient */)) {
+ context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Parameter_0_of_1_implicitly_has_an_any_type, [varDecl.id.actualText, enclosingDecl.name], enclosingDecl);
+ } else if (TypeScript.hasFlag(parentDecl.flags, 8 /* Ambient */) && !TypeScript.hasFlag(wrapperDecl.flags, 2 /* Private */)) {
+ context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Parameter_0_of_1_implicitly_has_an_any_type, [varDecl.id.actualText, enclosingDecl.name], enclosingDecl);
+ }
+ } else if (wrapperDecl.kind === 8388608 /* ObjectType */) {
context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Member_0_of_object_type_implicitly_has_an_any_type, [varDecl.id.actualText], enclosingDecl);
- } else if (wrapperDecl.kind != 1073741824 /* CatchBlock */) {
- context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Variable_0_implicitly_has_an_any_type, [varDecl.id.actualText], enclosingDecl);
+ } else if (wrapperDecl.kind !== 1073741824 /* CatchBlock */) {
+ if (!TypeScript.hasFlag(wrapperDecl.flags, 8 /* Ambient */)) {
+ context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Variable_0_implicitly_has_an_any_type, [varDecl.id.actualText], enclosingDecl);
+ } else if (TypeScript.hasFlag(wrapperDecl.flags, 8 /* Ambient */) && !TypeScript.hasFlag(varDecl.getVarFlags(), 2 /* Private */)) {
+ context.postError(this.unitPath, varDecl.minChar, varDecl.getLength(), TypeScript.DiagnosticCode.Variable_0_implicitly_has_an_any_type, [varDecl.id.actualText], enclosingDecl);
+ }
}
}
@@ -37889,6 +38044,10 @@ var TypeScript;
}
}
+ if (!functionSymbol.type && functionSymbol.isAccessor()) {
+ functionSymbol.type = signature.returnType;
+ }
+
if (this.isTypeArgumentOrWrapper(returnType) && functionSymbol) {
functionSymbol.type.setHasGenericSignature();
}
@@ -37896,8 +38055,121 @@ var TypeScript;
}
};
- PullTypeResolver.prototype.resolveFunctionDeclaration = function (funcDeclAST, context) {
+ PullTypeResolver.prototype.typeCheckFunctionDeclaration = function (funcDeclAST, funcDecl, signature, context) {
var _this = this;
+ if (context.inTypeCheck && (!context.inSpecialization || !signature.isGeneric())) {
+ PullTypeResolver.typeCheckCallBacks.push(function () {
+ if (signature.hasBeenChecked || signature.getRootSymbol() != signature) {
+ return;
+ }
+
+ var currentUnitPath = _this.unitPath;
+ _this.setUnitPath(funcDecl.getScriptName());
+ var prevSeenSuperConstructorCall = _this.seenSuperConstructorCall;
+ _this.seenSuperConstructorCall = false;
+
+ _this.resolveAST(funcDeclAST.block, false, funcDecl, context);
+
+ _this.validateVariableDeclarationGroups(funcDecl, context);
+
+ var enclosingDecl = _this.getEnclosingDecl(funcDecl);
+
+ var hasReturn = (funcDecl.flags & (2048 /* Signature */ | 4194304 /* HasReturnStatement */)) != 0;
+
+ var parameters = signature.parameters;
+
+ if (funcDeclAST.isConstructor || TypeScript.hasFlag(funcDeclAST.getFunctionFlags(), 1024 /* ConstructMember */)) {
+ if (funcDecl.getSignatureSymbol() && funcDecl.getSignatureSymbol().isDefinition() && _this.enclosingClassIsDerived(funcDecl)) {
+ if (!_this.seenSuperConstructorCall) {
+ context.postError(_this.unitPath, funcDeclAST.minChar, 11, TypeScript.DiagnosticCode.Constructors_for_derived_classes_must_contain_a_super_call, null, enclosingDecl);
+ } else if (_this.superCallMustBeFirstStatementInConstructor(funcDecl, enclosingDecl)) {
+ var firstStatement = _this.getFirstStatementFromFunctionDeclAST(funcDeclAST);
+ if (!firstStatement || !_this.isSuperCallNode(firstStatement)) {
+ context.postError(_this.unitPath, funcDeclAST.minChar, 11, TypeScript.DiagnosticCode.A_super_call_must_be_the_first_statement_in_the_constructor_when_a_class_contains_initialized_properties_or_has_parameter_properties, null, enclosingDecl);
+ }
+ }
+ }
+ _this.typeCheckFunctionOverloads(funcDeclAST, context);
+ } else if (TypeScript.hasFlag(funcDeclAST.getFunctionFlags(), 4096 /* IndexerMember */)) {
+ var allIndexSignatures = enclosingDecl.getSymbol().type.getIndexSignatures();
+
+ for (var i = 0; i < allIndexSignatures.length; i++) {
+ if (!allIndexSignatures[i].isResolved) {
+ _this.resolveDeclaredSymbol(allIndexSignatures[i], allIndexSignatures[i].getDeclarations()[0].getParentDecl(), context);
+ }
+
+ if (allIndexSignatures[i].parameters[0].type !== parameters[0].type) {
+ var stringIndexSignature = null;
+ var numberIndexSignature = null;
+
+ var indexSignature = signature;
+
+ var isNumericIndexer = parameters[0].type === _this.semanticInfoChain.numberTypeSymbol;
+
+ if (isNumericIndexer) {
+ numberIndexSignature = indexSignature;
+ stringIndexSignature = allIndexSignatures[i];
+ } else {
+ numberIndexSignature = allIndexSignatures[i];
+ stringIndexSignature = indexSignature;
+
+ if (enclosingDecl.getSymbol() === numberIndexSignature.getDeclarations()[0].getParentDecl().getSymbol()) {
+ break;
+ }
+ }
+ var comparisonInfo = new TypeComparisonInfo();
+ var resolutionContext = new TypeScript.PullTypeResolutionContext();
+ if (!_this.sourceIsSubtypeOfTarget(numberIndexSignature.returnType, stringIndexSignature.returnType, resolutionContext, comparisonInfo)) {
+ if (comparisonInfo.message) {
+ context.postError(_this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode.Numeric_indexer_type_0_must_be_a_subtype_of_string_indexer_type_1_NL_2, [numberIndexSignature.returnType.toString(), stringIndexSignature.returnType.toString(), comparisonInfo.message], enclosingDecl);
+ } else {
+ context.postError(_this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode.Numeric_indexer_type_0_must_be_a_subtype_of_string_indexer_type_1, [numberIndexSignature.returnType.toString(), stringIndexSignature.returnType.toString()], enclosingDecl);
+ }
+ }
+ break;
+ }
+ }
+
+ var allMembers = enclosingDecl.getSymbol().type.getAllMembers(TypeScript.PullElementKind.All, true);
+ for (var i = 0; i < allMembers.length; i++) {
+ var name = allMembers[i].name;
+ if (name) {
+ if (!allMembers[i].isResolved) {
+ _this.resolveDeclaredSymbol(allMembers[i], allMembers[i].getDeclarations()[0].getParentDecl(), context);
+ }
+
+ if (enclosingDecl.getSymbol() !== allMembers[i].getContainer()) {
+ var isMemberNumeric = isFinite(+name);
+ if (isNumericIndexer === isMemberNumeric) {
+ _this.checkThatMemberIsSubtypeOfIndexer(allMembers[i], indexSignature, funcDeclAST, context, enclosingDecl, isNumericIndexer);
+ }
+ }
+ }
+ }
+ } else {
+ if (funcDeclAST.block && funcDeclAST.returnTypeAnnotation != null && !hasReturn) {
+ var isVoidOrAny = _this.isAnyOrEquivalent(signature.returnType) || signature.returnType === _this.semanticInfoChain.voidTypeSymbol;
+
+ if (!isVoidOrAny && !(funcDeclAST.block.statements.members.length > 0 && funcDeclAST.block.statements.members[0].nodeType() === 96 /* ThrowStatement */)) {
+ var funcName = funcDecl.getDisplayName();
+ funcName = funcName ? funcName : "expression";
+
+ context.postError(_this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Function_0_declared_a_non_void_return_type_but_has_no_return_expression, [funcName], enclosingDecl);
+ }
+ }
+ _this.typeCheckFunctionOverloads(funcDeclAST, context);
+ }
+
+ _this.checkFunctionTypePrivacy(funcDeclAST, false, context);
+ _this.seenSuperConstructorCall = prevSeenSuperConstructorCall;
+
+ signature.hasBeenChecked = true;
+ _this.setUnitPath(currentUnitPath);
+ });
+ }
+ };
+
+ PullTypeResolver.prototype.resolveFunctionDeclaration = function (funcDeclAST, context) {
var funcDecl = this.getDeclForAST(funcDeclAST);
var funcSymbol = funcDecl.getSymbol();
@@ -37910,6 +38182,7 @@ var TypeScript;
if (signature) {
if (signature.isResolved) {
+ this.typeCheckFunctionDeclaration(funcDeclAST, funcDecl, signature, context);
return funcSymbol;
}
@@ -38009,6 +38282,11 @@ var TypeScript;
}
}
+ if (this.genericTypeIsUsedWithoutRequiredTypeArguments(returnTypeSymbol, funcDeclAST.returnTypeAnnotation, context)) {
+ context.postError(this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Generic_type_references_must_include_all_type_arguments, null, funcDecl);
+ returnTypeSymbol = this.specializeTypeToAny(returnTypeSymbol, funcDecl, context);
+ }
+
signature.returnType = returnTypeSymbol;
if (isConstructor && returnTypeSymbol === this.semanticInfoChain.voidTypeSymbol) {
@@ -38018,8 +38296,13 @@ var TypeScript;
} else if (!funcDeclAST.isConstructor && !funcDeclAST.isConstructMember()) {
if (funcDeclAST.isSignature()) {
signature.returnType = this.semanticInfoChain.anyTypeSymbol;
+ var parentDeclFlags = 0 /* None */;
+ if (TypeScript.hasFlag(funcDecl.kind, 65536 /* Method */) || TypeScript.hasFlag(funcDecl.kind, 32768 /* ConstructorMethod */)) {
+ var parentDecl = funcDecl.getParentDecl();
+ parentDeclFlags = parentDecl.flags;
+ }
- if (this.compilationSettings.noImplicitAny) {
+ if (this.compilationSettings.noImplicitAny && (!TypeScript.hasFlag(parentDeclFlags, 8 /* Ambient */) || (TypeScript.hasFlag(parentDeclFlags, 8 /* Ambient */) && !TypeScript.hasFlag(funcDecl.flags, 2 /* Private */)))) {
var funcDeclASTName = funcDeclAST.name;
if (funcDeclASTName) {
context.postError(this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode._0_which_lacks_return_type_annotation_implicitly_has_an_any_return_type, [funcDeclASTName.actualText], funcDecl);
@@ -38051,116 +38334,7 @@ var TypeScript;
}
}
- if (context.inTypeCheck && (!context.inSpecialization || !signature.isGeneric())) {
- var prevSeenSuperConstructorCall = this.seenSuperConstructorCall;
-
- PullTypeResolver.typeCheckCallBacks.push(function () {
- if (signature.hasBeenChecked) {
- return;
- }
-
- _this.setUnitPath(funcDecl.getScriptName());
- _this.seenSuperConstructorCall = false;
-
- _this.resolveAST(funcDeclAST.block, false, funcDecl, context);
-
- _this.validateVariableDeclarationGroups(funcDecl, context);
-
- var enclosingDecl = _this.getEnclosingDecl(funcDecl);
-
- var hasReturn = (funcDecl.flags & (2048 /* Signature */ | 4194304 /* HasReturnStatement */)) != 0;
-
- var parameters = signature.parameters;
-
- if (funcDeclAST.isConstructor || TypeScript.hasFlag(funcDeclAST.getFunctionFlags(), 1024 /* ConstructMember */)) {
- if (funcDecl.getSignatureSymbol() && funcDecl.getSignatureSymbol().isDefinition() && _this.enclosingClassIsDerived(funcDecl)) {
- if (!_this.seenSuperConstructorCall) {
- context.postError(_this.unitPath, funcDeclAST.minChar, 11, TypeScript.DiagnosticCode.Constructors_for_derived_classes_must_contain_a_super_call, null, enclosingDecl);
- } else if (_this.superCallMustBeFirstStatementInConstructor(funcDecl, enclosingDecl)) {
- var firstStatement = _this.getFirstStatementFromFunctionDeclAST(funcDeclAST);
- if (!firstStatement || !_this.isSuperCallNode(firstStatement)) {
- context.postError(_this.unitPath, funcDeclAST.minChar, 11, TypeScript.DiagnosticCode.A_super_call_must_be_the_first_statement_in_the_constructor_when_a_class_contains_initialized_properties_or_has_parameter_properties, null, enclosingDecl);
- }
- }
- }
- _this.typeCheckFunctionOverloads(funcDeclAST, context);
- } else if (TypeScript.hasFlag(funcDeclAST.getFunctionFlags(), 4096 /* IndexerMember */)) {
- var allIndexSignatures = enclosingDecl.getSymbol().type.getIndexSignatures();
-
- for (var i = 0; i < allIndexSignatures.length; i++) {
- if (!allIndexSignatures[i].isResolved) {
- _this.resolveDeclaredSymbol(allIndexSignatures[i], allIndexSignatures[i].getDeclarations()[0].getParentDecl(), context);
- }
-
- if (allIndexSignatures[i].parameters[0].type !== parameters[0].type) {
- var stringIndexSignature = null;
- var numberIndexSignature = null;
-
- var indexSignature = signature;
-
- var isNumericIndexer = parameters[0].type === _this.semanticInfoChain.numberTypeSymbol;
-
- if (isNumericIndexer) {
- numberIndexSignature = indexSignature;
- stringIndexSignature = allIndexSignatures[i];
- } else {
- numberIndexSignature = allIndexSignatures[i];
- stringIndexSignature = indexSignature;
-
- if (enclosingDecl.getSymbol() === numberIndexSignature.getDeclarations()[0].getParentDecl().getSymbol()) {
- break;
- }
- }
- var comparisonInfo = new TypeComparisonInfo();
- var resolutionContext = new TypeScript.PullTypeResolutionContext();
- if (!_this.sourceIsSubtypeOfTarget(numberIndexSignature.returnType, stringIndexSignature.returnType, resolutionContext, comparisonInfo)) {
- if (comparisonInfo.message) {
- context.postError(_this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode.Numeric_indexer_type_0_must_be_a_subtype_of_string_indexer_type_1_NL_2, [numberIndexSignature.returnType.toString(), stringIndexSignature.returnType.toString(), comparisonInfo.message], enclosingDecl);
- } else {
- context.postError(_this.unitPath, funcDeclAST.minChar, funcDeclAST.getLength(), TypeScript.DiagnosticCode.Numeric_indexer_type_0_must_be_a_subtype_of_string_indexer_type_1, [numberIndexSignature.returnType.toString(), stringIndexSignature.returnType.toString()], enclosingDecl);
- }
- }
- break;
- }
- }
-
- var allMembers = enclosingDecl.getSymbol().type.getAllMembers(TypeScript.PullElementKind.All, true);
- for (var i = 0; i < allMembers.length; i++) {
- var name = allMembers[i].name;
- if (name) {
- if (!allMembers[i].isResolved) {
- _this.resolveDeclaredSymbol(allMembers[i], allMembers[i].getDeclarations()[0].getParentDecl(), context);
- }
-
- if (enclosingDecl.getSymbol() !== allMembers[i].getContainer()) {
- var isMemberNumeric = isFinite(+name);
- if (isNumericIndexer === isMemberNumeric) {
- _this.checkThatMemberIsSubtypeOfIndexer(allMembers[i], indexSignature, funcDeclAST, context, enclosingDecl, isNumericIndexer);
- }
- }
- }
- }
- } else {
- if (funcDeclAST.block && funcDeclAST.returnTypeAnnotation != null && !hasReturn) {
- var isVoidOrAny = _this.isAnyOrEquivalent(returnTypeSymbol) || returnTypeSymbol === _this.semanticInfoChain.voidTypeSymbol;
-
- if (!isVoidOrAny && !(funcDeclAST.block.statements.members.length > 0 && funcDeclAST.block.statements.members[0].nodeType() === 96 /* ThrowStatement */)) {
- var funcName = funcDecl.getDisplayName();
- funcName = funcName ? funcName : "expression";
-
- context.postError(_this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Function_0_declared_a_non_void_return_type_but_has_no_return_expression, [funcName], enclosingDecl);
- }
- }
- _this.typeCheckFunctionOverloads(funcDeclAST, context);
- }
-
- _this.checkFunctionTypePrivacy(funcDeclAST, false, context);
- _this.seenSuperConstructorCall = prevSeenSuperConstructorCall;
-
- signature.hasBeenChecked = true;
- });
- }
-
+ this.typeCheckFunctionDeclaration(funcDeclAST, funcDecl, signature, context);
return funcSymbol;
};
@@ -38178,6 +38352,9 @@ var TypeScript;
if (signature) {
if (signature.isResolved) {
+ if (!accessorSymbol.type) {
+ accessorSymbol.type = signature.returnType;
+ }
return accessorSymbol;
}
@@ -38185,6 +38362,10 @@ var TypeScript;
signature.returnType = this.semanticInfoChain.anyTypeSymbol;
signature.setResolved();
+ if (!accessorSymbol.type) {
+ accessorSymbol.type = signature.returnType;
+ }
+
return accessorSymbol;
}
@@ -38219,6 +38400,11 @@ var TypeScript;
}
}
+ if (this.genericTypeIsUsedWithoutRequiredTypeArguments(returnTypeSymbol, funcDeclAST.returnTypeAnnotation, context)) {
+ context.postError(this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Generic_type_references_must_include_all_type_arguments, null, funcDecl);
+ returnTypeSymbol = this.specializeTypeToAny(returnTypeSymbol, funcDecl, context);
+ }
+
signature.returnType = returnTypeSymbol;
}
} else {
@@ -39277,7 +39463,7 @@ var TypeScript;
this.resolveDeclaredSymbol(nameSymbol, enclosingDecl, context);
}
- if (nameSymbol && (nameSymbol.type != this.semanticInfoChain.anyTypeSymbol || nameSymbol.hasFlag(16777216 /* IsAnnotatedWithAny */))) {
+ if (nameSymbol && (nameSymbol.type != this.semanticInfoChain.anyTypeSymbol || nameSymbol.hasFlag(16777216 /* IsAnnotatedWithAny */ | 1 /* Exported */))) {
this.setSymbolForAST(nameAST, nameSymbol, context);
}
@@ -39327,7 +39513,9 @@ var TypeScript;
if (nameSymbol.isType() && nameSymbol.isAlias()) {
aliasSymbol = nameSymbol;
- aliasSymbol.isUsedAsValue = true;
+ if (!context.resolvingTypeQueryExpression) {
+ aliasSymbol.isUsedAsValue = true;
+ }
if (!nameSymbol.isResolved) {
this.resolveDeclaredSymbol(nameSymbol, enclosingDecl, context);
@@ -39414,7 +39602,9 @@ var TypeScript;
var lhsType = lhs.type;
if (lhs.isAlias()) {
- (lhs).isUsedAsValue = true;
+ if (!context.resolvingTypeQueryExpression) {
+ (lhs).isUsedAsValue = true;
+ }
lhsType = (lhs).getExportAssignedTypeSymbol();
}
@@ -39571,6 +39761,14 @@ var TypeScript;
return this.semanticInfoChain.stringTypeSymbol;
} else if (id === "number") {
return this.semanticInfoChain.numberTypeSymbol;
+ } else if (id === "bool") {
+ if (!this.compilationSettings.allowBool && !this.currentUnit.getProperties().unitContainsBool) {
+ this.currentUnit.getProperties().unitContainsBool = true;
+ context.postError(this.unitPath, nameAST.minChar, nameAST.getLength(), TypeScript.DiagnosticCode.Use_of_deprecated_type_bool_Use_boolean_instead, null, enclosingDecl);
+ return this.semanticInfoChain.booleanTypeSymbol;
+ } else {
+ return this.semanticInfoChain.booleanTypeSymbol;
+ }
} else if (id === "boolean") {
return this.semanticInfoChain.booleanTypeSymbol;
} else if (id === "void") {
@@ -39667,6 +39865,10 @@ var TypeScript;
} else {
typeArgs[i] = typeArg;
}
+
+ if (typeArgs[i].isError()) {
+ typeArgs[i] = this.semanticInfoChain.anyTypeSymbol;
+ }
}
}
context.isResolvingClassExtendedType = savedIsResolvingClassExtendedType;
@@ -39905,6 +40107,11 @@ var TypeScript;
if (funcDeclAST.returnTypeAnnotation) {
var returnTypeSymbol = this.resolveTypeReference(funcDeclAST.returnTypeAnnotation, functionDecl, context);
+ if (this.genericTypeIsUsedWithoutRequiredTypeArguments(returnTypeSymbol, funcDeclAST.returnTypeAnnotation, context)) {
+ context.postError(this.unitPath, funcDeclAST.returnTypeAnnotation.minChar, funcDeclAST.returnTypeAnnotation.getLength(), TypeScript.DiagnosticCode.Generic_type_references_must_include_all_type_arguments, null, functionDecl);
+ returnTypeSymbol = this.specializeTypeToAny(returnTypeSymbol, functionDecl, context);
+ }
+
signature.returnType = returnTypeSymbol;
} else {
if (assigningFunctionSignature) {
@@ -39938,6 +40145,7 @@ var TypeScript;
if (context.typeCheck()) {
PullTypeResolver.typeCheckCallBacks.push(function () {
+ var currentUnitPath = _this.unitPath;
_this.setUnitPath(functionDecl.getScriptName());
_this.seenSuperConstructorCall = false;
@@ -39959,6 +40167,7 @@ var TypeScript;
}
_this.typeCheckFunctionOverloads(funcDeclAST, context);
+ _this.setUnitPath(currentUnitPath);
});
}
@@ -40415,6 +40624,7 @@ var TypeScript;
PullTypeResolver.prototype.computeIndexExpressionSymbol = function (callEx, inContextuallyTypedAssignment, enclosingDecl, context) {
var targetSymbol = this.resolveAST(callEx.operand1, inContextuallyTypedAssignment, enclosingDecl, context);
+ var indexType = this.resolveAST(callEx.operand2, inContextuallyTypedAssignment, enclosingDecl, context).type;
var targetTypeSymbol = targetSymbol.type;
@@ -40424,8 +40634,6 @@ var TypeScript;
var elementType = targetTypeSymbol.getElementType();
- var indexType = this.resolveAST(callEx.operand2, inContextuallyTypedAssignment, enclosingDecl, context).type;
-
var isNumberIndex = indexType === this.semanticInfoChain.numberTypeSymbol || TypeScript.PullHelpers.symbolIsEnum(indexType);
if (elementType && isNumberIndex) {
@@ -40438,6 +40646,10 @@ var TypeScript;
var member = this.getMemberSymbol(memberName, TypeScript.PullElementKind.SomeValue, targetTypeSymbol);
if (member) {
+ if (!member.isResolved) {
+ this.resolveDeclaredSymbol(member, enclosingDecl, context);
+ }
+
return member.type;
}
}
@@ -40462,10 +40674,10 @@ var TypeScript;
if (paramSymbols.length) {
paramType = paramSymbols[0].type;
- if (paramType === this.semanticInfoChain.stringTypeSymbol) {
+ if (!stringSignature && paramType === this.semanticInfoChain.stringTypeSymbol) {
stringSignature = signatures[i];
continue;
- } else if (paramType === this.semanticInfoChain.numberTypeSymbol || paramType.kind === 64 /* Enum */) {
+ } else if (!numberSignature && (paramType === this.semanticInfoChain.numberTypeSymbol || paramType.kind === 64 /* Enum */)) {
numberSignature = signatures[i];
continue;
}
@@ -40703,7 +40915,6 @@ var TypeScript;
PullTypeResolver.prototype.computeInvocationExpressionSymbol = function (callEx, inContextuallyTypedAssignment, enclosingDecl, context, additionalResults) {
var targetSymbol = this.resolveAST(callEx.target, inContextuallyTypedAssignment, enclosingDecl, context);
-
var targetAST = this.getLastIdentifierInTarget(callEx);
var targetTypeSymbol = targetSymbol.type;
@@ -40729,6 +40940,7 @@ var TypeScript;
targetTypeSymbol = targetSymbol.type;
} else {
context.postError(this.unitPath, targetAST.minChar, targetAST.getLength(), TypeScript.DiagnosticCode.Calls_to_super_are_only_valid_inside_a_class, null, enclosingDecl);
+ this.resolveAST(callEx.arguments, inContextuallyTypedAssignment, enclosingDecl, context);
return this.getNewErrorTypeSymbol(null);
}
@@ -40879,6 +41091,15 @@ var TypeScript;
additionalResults.actualParametersContextTypeSymbols = actualParametersContextTypeSymbols;
}
+ var prevIsResolvingSuperConstructorTarget = context.isResolvingSuperConstructorTarget;
+ if (isSuperCall) {
+ context.isResolvingSuperConstructorTarget = true;
+ }
+ this.resolveAST(callEx.arguments, inContextuallyTypedAssignment, enclosingDecl, context);
+ if (isSuperCall) {
+ context.isResolvingSuperConstructorTarget = prevIsResolvingSuperConstructorTarget;
+ }
+
if (!couldNotFindGenericOverload) {
if (this.cachedFunctionInterfaceType() && this.sourceIsSubtypeOfTarget(targetTypeSymbol, this.cachedFunctionInterfaceType(), context)) {
return this.semanticInfoChain.anyTypeSymbol;
@@ -41323,8 +41544,11 @@ var TypeScript;
}
return returnType;
- } else if (targetTypeSymbol.isClass()) {
- return returnType;
+ } else {
+ this.resolveAST(callEx.arguments, inContextuallyTypedAssignment, enclosingDecl, context);
+ if (targetTypeSymbol.isClass()) {
+ return returnType;
+ }
}
context.postError(this.unitPath, targetAST.minChar, targetAST.getLength(), TypeScript.DiagnosticCode.Invalid_new_expression, null, enclosingDecl);
@@ -41803,6 +42027,10 @@ var TypeScript;
return false;
}
+ if (!!(s1.typeParameters && s1.typeParameters.length) != !!(s2.typeParameters && s2.typeParameters.length)) {
+ return false;
+ }
+
if (s1.typeParameters && s2.typeParameters && (s1.typeParameters.length != s2.typeParameters.length)) {
return false;
}
@@ -41879,7 +42107,7 @@ var TypeScript;
for (var j = 0; j < extendsList.members.length; j++) {
extendsSymbol = this.semanticInfoChain.getSymbolForAST(extendsList.members[j], sourceDecls[i].getScriptName());
- if (extendsSymbol == target || this.sourceExtendsTarget(extendsSymbol, target, context)) {
+ if (extendsSymbol && (extendsSymbol == target || this.sourceExtendsTarget(extendsSymbol, target, context))) {
return true;
}
}
@@ -42681,6 +42909,11 @@ var TypeScript;
typeB = actuals[i];
+ if (typeB.isAlias()) {
+ (typeB).isUsedAsValue = true;
+ typeB = (typeB).getExportAssignedTypeSymbol();
+ }
+
if (typeA && !typeA.isResolved) {
this.resolveDeclaredSymbol(typeA, enclosingDecl, context);
}
@@ -43418,6 +43651,10 @@ var TypeScript;
if (!typeSymbol.isNamedTypeSymbol()) {
if (typeSymbol.inSymbolPrivacyCheck) {
+ var associatedContainerType = typeSymbol.getAssociatedContainerType();
+ if (associatedContainerType && associatedContainerType.isNamedTypeSymbol()) {
+ this.checkSymbolPrivacy(declSymbol, associatedContainerType, context, privacyErrorReporter);
+ }
return;
}
@@ -43441,18 +43678,17 @@ var TypeScript;
if (declSymbol.isExternallyVisible()) {
var symbolIsVisible = symbol.isExternallyVisible();
- if (symbolIsVisible) {
+ if (symbolIsVisible && symbol.kind != 2 /* Primitive */ && symbol.kind != 8192 /* TypeParameter */) {
var symbolPath = symbol.pathToRoot();
- if (symbolPath.length && symbolPath[symbolPath.length - 1].kind === 32 /* DynamicModule */) {
- var declSymbolPath = declSymbol.pathToRoot();
+ var declSymbolPath = declSymbol.pathToRoot();
+ if (symbolPath[symbolPath.length - 1].kind === 32 /* DynamicModule */ && declSymbolPath[declSymbolPath.length - 1].kind == 32 /* DynamicModule */) {
var verifyAlias = false;
- if (declSymbolPath.length) {
- if (declSymbolPath[declSymbolPath.length - 1] != symbolPath[symbolPath.length - 1]) {
+
+ if (declSymbolPath[declSymbolPath.length - 1] != symbolPath[symbolPath.length - 1]) {
+ verifyAlias = true;
+ } else if (symbolPath.length > 1 && symbolPath[symbolPath.length - 2].kind == 32 /* DynamicModule */) {
+ if (declSymbolPath.length < 2 || declSymbolPath[declSymbolPath.length - 2] != symbolPath[symbolPath.length - 2]) {
verifyAlias = true;
- } else if (symbolPath.length > 1 && symbolPath[symbolPath.length - 2].kind == 32 /* DynamicModule */) {
- if (declSymbolPath.length < 2 || declSymbolPath[declSymbolPath.length - 2] != symbolPath[symbolPath.length - 2]) {
- verifyAlias = true;
- }
}
}
@@ -43469,6 +43705,10 @@ var TypeScript;
symbol = symbolPath[symbolPath.length - 1];
}
}
+ } else if (symbol.kind == 256 /* TypeAlias */) {
+ var aliasSymbol = symbol;
+ symbolIsVisible = true;
+ aliasSymbol.typeUsedExternally = true;
}
if (!symbolIsVisible) {
@@ -44069,7 +44309,7 @@ var TypeScript;
var extendedConstructorTypeProp = extendedConstructorType.findMember(propName);
if (extendedConstructorTypeProp) {
if (!extendedConstructorTypeProp.isResolved) {
- var extendedClassAst = this.currentUnit.getASTForSymbol(extendedType);
+ var extendedClassAst = this.currentUnit.getASTForDecl(extendedType.getDeclarations()[0]);
var extendedClassDecl = this.currentUnit.getDeclForAST(extendedClassAst);
this.resolveDeclaredSymbol(extendedConstructorTypeProp, extendedClassDecl, resolutionContext);
}
@@ -44159,7 +44399,10 @@ var TypeScript;
var contextForBaseTypeResolution = new TypeScript.PullTypeResolutionContext();
contextForBaseTypeResolution.isResolvingClassExtendedType = true;
+ var prevResolvingTypeReference = context.resolvingTypeReference;
+ context.resolvingTypeReference = true;
var baseType = this.resolveAST(baseDeclAST, false, enclosingDecl, context);
+ context.resolvingTypeReference = prevResolvingTypeReference;
contextForBaseTypeResolution.isResolvingClassExtendedType = false;
var typeDeclIsClass = typeSymbol.isClass();
@@ -44380,6 +44623,7 @@ var TypeScript;
});
this.syntaxElementSymbolMap = new TypeScript.DataMap();
this.symbolSyntaxElementMap = new TypeScript.DataMap();
+ this.properties = new SemanticInfoProperties();
this.hasBeenTypeChecked = false;
this.compilationUnitPath = compilationUnitPath;
}
@@ -44515,10 +44759,22 @@ var TypeScript;
TypeScript.getDiagnosticsFromEnclosingDecl(this.topLevelDecls[i], semanticErrors);
}
};
+
+ SemanticInfo.prototype.getProperties = function () {
+ return this.properties;
+ };
return SemanticInfo;
})();
TypeScript.SemanticInfo = SemanticInfo;
+ var SemanticInfoProperties = (function () {
+ function SemanticInfoProperties() {
+ this.unitContainsBool = false;
+ }
+ return SemanticInfoProperties;
+ })();
+ TypeScript.SemanticInfoProperties = SemanticInfoProperties;
+
var SemanticInfoChain = (function () {
function SemanticInfoChain() {
this.units = [new SemanticInfo("")];
@@ -46731,7 +46987,7 @@ var TypeScript;
constructorTypeSymbol.addDeclaration(constructorTypeDeclaration);
this.semanticInfo.setSymbolForAST(constructorTypeAST, constructorTypeSymbol);
- var signature = new TypeScript.PullDefinitionSignatureSymbol(2097152 /* ConstructSignature */);
+ var signature = new TypeScript.PullSignatureSymbol(2097152 /* ConstructSignature */);
if ((constructorTypeAST).variableArgList) {
signature.hasVarArgs = true;
@@ -47337,7 +47593,7 @@ var TypeScript;
signature.addTypeParameter(typeParameter);
} else {
- var typeParameterAST = this.semanticInfoChain.getASTForDecl(typeParameterDecls[0]);
+ var typeParameterAST = this.semanticInfoChain.getASTForDecl(typeParameter.getDeclarations()[0]);
functionTypeDeclaration.addDiagnostic(new TypeScript.Diagnostic(this.semanticInfo.getPath(), typeParameterAST.minChar, typeParameterAST.getLength(), TypeScript.DiagnosticCode.Duplicate_identifier_0, [typeParameter.name]));
}
@@ -48347,9 +48603,9 @@ var TypeScript;
return true;
}
- if (moduleElement.kind() === 133 /* ImportDeclaration */) {
+ if (moduleElement.kind() === 134 /* ImportDeclaration */) {
var importDecl = moduleElement;
- if (importDecl.moduleReference.kind() === 245 /* ExternalModuleReference */) {
+ if (importDecl.moduleReference.kind() === 246 /* ExternalModuleReference */) {
return true;
}
}
@@ -48484,7 +48740,7 @@ var TypeScript;
flags = flags | 1 /* Exported */;
}
- if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
flags = flags | 8 /* Ambient */;
}
@@ -48563,7 +48819,7 @@ var TypeScript;
};
SyntaxTreeToAstVisitor.prototype.getModuleNamesHelper = function (name, result) {
- if (name.kind() === 121 /* QualifiedName */) {
+ if (name.kind() === 122 /* QualifiedName */) {
var qualifiedName = name;
this.getModuleNamesHelper(qualifiedName.left, result);
this.movePast(qualifiedName.dotToken);
@@ -48620,7 +48876,7 @@ var TypeScript;
};
SyntaxTreeToAstVisitor.prototype.completeModuleDeclaration = function (node, result) {
- if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
result.setModuleFlags(result.getModuleFlags() | 8 /* Ambient */);
}
};
@@ -48670,7 +48926,7 @@ var TypeScript;
flags = flags | 1 /* Exported */;
}
- if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
flags = flags | 8 /* Ambient */;
}
@@ -48764,8 +49020,8 @@ var TypeScript;
if (TypeScript.Syntax.isIntegerLiteral(expression)) {
var token;
switch (expression.kind()) {
- case 163 /* PlusExpression */:
- case 164 /* NegateExpression */:
+ case 164 /* PlusExpression */:
+ case 165 /* NegateExpression */:
token = (expression).operand;
break;
default:
@@ -48773,7 +49029,7 @@ var TypeScript;
}
var value = token.value();
- return value && expression.kind() === 164 /* NegateExpression */ ? -value : value;
+ return value && expression.kind() === 165 /* NegateExpression */ ? -value : value;
} else if (this.compilationSettings.propagateEnumConstants) {
switch (expression.kind()) {
case 11 /* IdentifierName */:
@@ -48782,7 +49038,7 @@ var TypeScript;
});
return variableDeclarator ? variableDeclarator.constantValue : null;
- case 201 /* LeftShiftExpression */:
+ case 202 /* LeftShiftExpression */:
var binaryExpression = expression;
return this.computeConstantValue(binaryExpression.left, declarators) << this.computeConstantValue(binaryExpression.right, declarators);
}
@@ -48858,7 +49114,7 @@ var TypeScript;
flags = flags | 1 /* Exported */;
}
- if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 63 /* DeclareKeyword */)) {
+ if (TypeScript.SyntaxUtilities.containsToken(node.modifiers, 64 /* DeclareKeyword */)) {
flags = flags | 8 /* Ambient */;
}
@@ -48924,17 +49180,17 @@ var TypeScript;
SyntaxTreeToAstVisitor.prototype.getUnaryExpressionNodeType = function (kind) {
switch (kind) {
- case 163 /* PlusExpression */:
+ case 164 /* PlusExpression */:
return 27 /* PlusExpression */;
- case 164 /* NegateExpression */:
+ case 165 /* NegateExpression */:
return 28 /* NegateExpression */;
- case 165 /* BitwiseNotExpression */:
+ case 166 /* BitwiseNotExpression */:
return 73 /* BitwiseNotExpression */;
- case 166 /* LogicalNotExpression */:
+ case 167 /* LogicalNotExpression */:
return 74 /* LogicalNotExpression */;
- case 167 /* PreIncrementExpression */:
+ case 168 /* PreIncrementExpression */:
return 75 /* PreIncrementExpression */;
- case 168 /* PreDecrementExpression */:
+ case 169 /* PreDecrementExpression */:
return 76 /* PreDecrementExpression */;
default:
throw TypeScript.Errors.invalidOperation();
@@ -49000,7 +49256,7 @@ var TypeScript;
};
SyntaxTreeToAstVisitor.prototype.getArrowFunctionStatements = function (body) {
- if (body.kind() === 145 /* Block */) {
+ if (body.kind() === 146 /* Block */) {
return body.accept(this);
} else {
var expression = body.accept(this);
@@ -49297,7 +49553,7 @@ var TypeScript;
var operand = node.operand.accept(this);
this.movePast(node.operatorToken);
- var result = new TypeScript.UnaryExpression(node.kind() === 209 /* PostIncrementExpression */ ? 77 /* PostIncrementExpression */ : 78 /* PostDecrementExpression */, operand, null);
+ var result = new TypeScript.UnaryExpression(node.kind() === 210 /* PostIncrementExpression */ ? 77 /* PostIncrementExpression */ : 78 /* PostDecrementExpression */, operand, null);
this.setSpan(result, start, node);
return result;
@@ -49363,77 +49619,77 @@ var TypeScript;
SyntaxTreeToAstVisitor.prototype.getBinaryExpressionNodeType = function (node) {
switch (node.kind()) {
- case 172 /* CommaExpression */:
+ case 173 /* CommaExpression */:
return 26 /* CommaExpression */;
- case 173 /* AssignmentExpression */:
+ case 174 /* AssignmentExpression */:
return 39 /* AssignmentExpression */;
- case 174 /* AddAssignmentExpression */:
+ case 175 /* AddAssignmentExpression */:
return 40 /* AddAssignmentExpression */;
- case 175 /* SubtractAssignmentExpression */:
+ case 176 /* SubtractAssignmentExpression */:
return 41 /* SubtractAssignmentExpression */;
- case 176 /* MultiplyAssignmentExpression */:
+ case 177 /* MultiplyAssignmentExpression */:
return 43 /* MultiplyAssignmentExpression */;
- case 177 /* DivideAssignmentExpression */:
+ case 178 /* DivideAssignmentExpression */:
return 42 /* DivideAssignmentExpression */;
- case 178 /* ModuloAssignmentExpression */:
+ case 179 /* ModuloAssignmentExpression */:
return 44 /* ModuloAssignmentExpression */;
- case 179 /* AndAssignmentExpression */:
+ case 180 /* AndAssignmentExpression */:
return 45 /* AndAssignmentExpression */;
- case 180 /* ExclusiveOrAssignmentExpression */:
+ case 181 /* ExclusiveOrAssignmentExpression */:
return 46 /* ExclusiveOrAssignmentExpression */;
- case 181 /* OrAssignmentExpression */:
+ case 182 /* OrAssignmentExpression */:
return 47 /* OrAssignmentExpression */;
- case 182 /* LeftShiftAssignmentExpression */:
+ case 183 /* LeftShiftAssignmentExpression */:
return 48 /* LeftShiftAssignmentExpression */;
- case 183 /* SignedRightShiftAssignmentExpression */:
+ case 184 /* SignedRightShiftAssignmentExpression */:
return 49 /* SignedRightShiftAssignmentExpression */;
- case 184 /* UnsignedRightShiftAssignmentExpression */:
+ case 185 /* UnsignedRightShiftAssignmentExpression */:
return 50 /* UnsignedRightShiftAssignmentExpression */;
- case 186 /* LogicalOrExpression */:
+ case 187 /* LogicalOrExpression */:
return 52 /* LogicalOrExpression */;
- case 187 /* LogicalAndExpression */:
+ case 188 /* LogicalAndExpression */:
return 53 /* LogicalAndExpression */;
- case 188 /* BitwiseOrExpression */:
+ case 189 /* BitwiseOrExpression */:
return 54 /* BitwiseOrExpression */;
- case 189 /* BitwiseExclusiveOrExpression */:
+ case 190 /* BitwiseExclusiveOrExpression */:
return 55 /* BitwiseExclusiveOrExpression */;
- case 190 /* BitwiseAndExpression */:
+ case 191 /* BitwiseAndExpression */:
return 56 /* BitwiseAndExpression */;
- case 191 /* EqualsWithTypeConversionExpression */:
+ case 192 /* EqualsWithTypeConversionExpression */:
return 57 /* EqualsWithTypeConversionExpression */;
- case 192 /* NotEqualsWithTypeConversionExpression */:
+ case 193 /* NotEqualsWithTypeConversionExpression */:
return 58 /* NotEqualsWithTypeConversionExpression */;
- case 193 /* EqualsExpression */:
+ case 194 /* EqualsExpression */:
return 59 /* EqualsExpression */;
- case 194 /* NotEqualsExpression */:
+ case 195 /* NotEqualsExpression */:
return 60 /* NotEqualsExpression */;
- case 195 /* LessThanExpression */:
+ case 196 /* LessThanExpression */:
return 61 /* LessThanExpression */;
- case 196 /* GreaterThanExpression */:
+ case 197 /* GreaterThanExpression */:
return 63 /* GreaterThanExpression */;
- case 197 /* LessThanOrEqualExpression */:
+ case 198 /* LessThanOrEqualExpression */:
return 62 /* LessThanOrEqualExpression */;
- case 198 /* GreaterThanOrEqualExpression */:
+ case 199 /* GreaterThanOrEqualExpression */:
return 64 /* GreaterThanOrEqualExpression */;
- case 199 /* InstanceOfExpression */:
+ case 200 /* InstanceOfExpression */:
return 34 /* InstanceOfExpression */;
- case 200 /* InExpression */:
+ case 201 /* InExpression */:
return 32 /* InExpression */;
- case 201 /* LeftShiftExpression */:
+ case 202 /* LeftShiftExpression */:
return 70 /* LeftShiftExpression */;
- case 202 /* SignedRightShiftExpression */:
+ case 203 /* SignedRightShiftExpression */:
return 71 /* SignedRightShiftExpression */;
- case 203 /* UnsignedRightShiftExpression */:
+ case 204 /* UnsignedRightShiftExpression */:
return 72 /* UnsignedRightShiftExpression */;
- case 204 /* MultiplyExpression */:
+ case 205 /* MultiplyExpression */:
return 67 /* MultiplyExpression */;
- case 205 /* DivideExpression */:
+ case 206 /* DivideExpression */:
return 68 /* DivideExpression */;
- case 206 /* ModuloExpression */:
+ case 207 /* ModuloExpression */:
return 69 /* ModuloExpression */;
- case 207 /* AddExpression */:
+ case 208 /* AddExpression */:
return 65 /* AddExpression */;
- case 208 /* SubtractExpression */:
+ case 209 /* SubtractExpression */:
return 66 /* SubtractExpression */;
}
@@ -49842,7 +50098,7 @@ var TypeScript;
var switchClause = node.switchClauses.childAt(i);
var translated = switchClause.accept(this);
- if (switchClause.kind() === 232 /* DefaultSwitchClause */) {
+ if (switchClause.kind() === 233 /* DefaultSwitchClause */) {
defaultCase = translated;
}
@@ -51304,14 +51560,6 @@ var TypeScript;
return null;
};
- TypeScriptCompiler.prototype.convertToDirectoryPath = function (dirPath) {
- if (dirPath && dirPath.charAt(dirPath.length - 1) !== "/") {
- dirPath += "/";
- }
-
- return dirPath;
- };
-
TypeScriptCompiler.prototype.setEmitOptions = function (ioHost) {
this.emitOptions.ioHost = ioHost;
@@ -51331,8 +51579,8 @@ var TypeScript;
}
}
- this.emitOptions.compilationSettings.mapRoot = this.convertToDirectoryPath(TypeScript.switchToForwardSlashes(this.emitOptions.compilationSettings.mapRoot));
- this.emitOptions.compilationSettings.sourceRoot = this.convertToDirectoryPath(TypeScript.switchToForwardSlashes(this.emitOptions.compilationSettings.sourceRoot));
+ this.emitOptions.compilationSettings.mapRoot = TypeScript.convertToDirectoryPath(TypeScript.switchToForwardSlashes(this.emitOptions.compilationSettings.mapRoot));
+ this.emitOptions.compilationSettings.sourceRoot = TypeScript.convertToDirectoryPath(TypeScript.switchToForwardSlashes(this.emitOptions.compilationSettings.sourceRoot));
if (!this.emitOptions.compilationSettings.outFileOption && !this.emitOptions.compilationSettings.outDirOption && !this.emitOptions.compilationSettings.mapRoot && !this.emitOptions.compilationSettings.sourceRoot) {
this.emitOptions.outputMany = true;
@@ -51349,7 +51597,7 @@ var TypeScript;
if (this.emitOptions.compilationSettings.outDirOption) {
this.emitOptions.compilationSettings.outDirOption = TypeScript.switchToForwardSlashes(this.emitOptions.ioHost.resolvePath(this.emitOptions.compilationSettings.outDirOption));
- this.emitOptions.compilationSettings.outDirOption = this.convertToDirectoryPath(this.emitOptions.compilationSettings.outDirOption);
+ this.emitOptions.compilationSettings.outDirOption = TypeScript.convertToDirectoryPath(this.emitOptions.compilationSettings.outDirOption);
}
if (this.emitOptions.compilationSettings.outDirOption || this.emitOptions.compilationSettings.mapRoot || this.emitOptions.compilationSettings.sourceRoot) {