Skip to content

Commit

Permalink
Bump version to 3.9.10 and LKG
Browse files Browse the repository at this point in the history
  • Loading branch information
typescript-bot committed Jun 16, 2021
1 parent 022bdea commit b7de5e3
Show file tree
Hide file tree
Showing 8 changed files with 153 additions and 56 deletions.
29 changes: 20 additions & 9 deletions lib/tsc.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cook
var ts;
(function (ts) {
ts.versionMajorMinor = "3.9";
ts.version = "3.9.9";
ts.version = "3.9.10";
function tryGetNativeMap() {
return typeof Map !== "undefined" && "entries" in Map.prototype ? Map : undefined;
}
Expand Down Expand Up @@ -3279,8 +3279,8 @@ var ts;
},
getFileSize: function (path) {
try {
var stat = _fs.statSync(path);
if (stat.isFile()) {
var stat = statSync(path);
if (stat === null || stat === void 0 ? void 0 : stat.isFile()) {
return stat.size;
}
}
Expand Down Expand Up @@ -3325,6 +3325,9 @@ var ts;
}
};
return nodeSystem;
function statSync(path) {
return _fs.statSync(path, { throwIfNoEntry: false });
}
function enableCPUProfiler(path, cb) {
if (activeSession) {
cb();
Expand Down Expand Up @@ -3370,19 +3373,20 @@ var ts;
if (activeSession && activeSession !== "stopping") {
var s_1 = activeSession;
activeSession.post("Profiler.stop", function (err, _a) {
var _b;
var profile = _a.profile;
if (!err) {
try {
if (_fs.statSync(profilePath).isDirectory()) {
if ((_b = statSync(profilePath)) === null || _b === void 0 ? void 0 : _b.isDirectory()) {
profilePath = _path.join(profilePath, (new Date()).toISOString().replace(/:/g, "-") + "+P" + process.pid + ".cpuprofile");
}
}
catch (_b) {
catch (_c) {
}
try {
_fs.mkdirSync(_path.dirname(profilePath), { recursive: true });
}
catch (_c) {
catch (_d) {
}
_fs.writeFileSync(profilePath, JSON.stringify(cleanupPaths(profile)));
}
Expand Down Expand Up @@ -3571,7 +3575,10 @@ var ts;
if (typeof dirent === "string" || dirent.isSymbolicLink()) {
var name = ts.combinePaths(path, entry);
try {
stat = _fs.statSync(name);
stat = statSync(name);
if (!stat) {
continue;
}
}
catch (e) {
continue;
Expand Down Expand Up @@ -3600,7 +3607,10 @@ var ts;
}
function fileSystemEntryExists(path, entryKind) {
try {
var stat = _fs.statSync(path);
var stat = statSync(path);
if (!stat) {
return false;
}
switch (entryKind) {
case 0: return stat.isFile();
case 1: return stat.isDirectory();
Expand Down Expand Up @@ -3629,8 +3639,9 @@ var ts;
}
}
function getModifiedTime(path) {
var _a;
try {
return _fs.statSync(path).mtime;
return (_a = statSync(path)) === null || _a === void 0 ? void 0 : _a.mtime;
}
catch (e) {
return undefined;
Expand Down
36 changes: 27 additions & 9 deletions lib/tsserver.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ var ts;
// If changing the text in this section, be sure to test `configurePrerelease` too.
ts.versionMajorMinor = "3.9";
/** The version of the TypeScript compiler release */
ts.version = "3.9.9";
ts.version = "3.9.10";
/**
* Returns the native Map implementation if it is available and compatible (i.e. supports iteration).
*/
Expand Down Expand Up @@ -5516,8 +5516,8 @@ var ts;
},
getFileSize: function (path) {
try {
var stat = _fs.statSync(path);
if (stat.isFile()) {
var stat = statSync(path);
if (stat === null || stat === void 0 ? void 0 : stat.isFile()) {
return stat.size;
}
}
Expand Down Expand Up @@ -5563,6 +5563,15 @@ var ts;
}
};
return nodeSystem;
/**
* `throwIfNoEntry` was added so recently that it's not in the node types.
* This helper encapsulates the mitigating usage of `any`.
* See https://github.com/nodejs/node/pull/33716
*/
function statSync(path) {
// throwIfNoEntry will be ignored by older versions of node
return _fs.statSync(path, { throwIfNoEntry: false });
}
/**
* Uses the builtin inspector APIs to capture a CPU profile
* See https://nodejs.org/api/inspector.html#inspector_example_usage for details
Expand Down Expand Up @@ -5617,20 +5626,21 @@ var ts;
if (activeSession && activeSession !== "stopping") {
var s_1 = activeSession;
activeSession.post("Profiler.stop", function (err, _a) {
var _b;
var profile = _a.profile;
if (!err) {
try {
if (_fs.statSync(profilePath).isDirectory()) {
if ((_b = statSync(profilePath)) === null || _b === void 0 ? void 0 : _b.isDirectory()) {
profilePath = _path.join(profilePath, (new Date()).toISOString().replace(/:/g, "-") + "+P" + process.pid + ".cpuprofile");
}
}
catch (_b) {
catch (_c) {
// do nothing and ignore fallible fs operation
}
try {
_fs.mkdirSync(_path.dirname(profilePath), { recursive: true });
}
catch (_c) {
catch (_d) {
// do nothing and ignore fallible fs operation
}
_fs.writeFileSync(profilePath, JSON.stringify(cleanupPaths(profile)));
Expand Down Expand Up @@ -5869,7 +5879,10 @@ var ts;
if (typeof dirent === "string" || dirent.isSymbolicLink()) {
var name = ts.combinePaths(path, entry);
try {
stat = _fs.statSync(name);
stat = statSync(name);
if (!stat) {
continue;
}
}
catch (e) {
continue;
Expand Down Expand Up @@ -5898,7 +5911,10 @@ var ts;
}
function fileSystemEntryExists(path, entryKind) {
try {
var stat = _fs.statSync(path);
var stat = statSync(path);
if (!stat) {
return false;
}
switch (entryKind) {
case 0 /* File */: return stat.isFile();
case 1 /* Directory */: return stat.isDirectory();
Expand Down Expand Up @@ -5927,8 +5943,9 @@ var ts;
}
}
function getModifiedTime(path) {
var _a;
try {
return _fs.statSync(path).mtime;
return (_a = statSync(path)) === null || _a === void 0 ? void 0 : _a.mtime;
}
catch (e) {
return undefined;
Expand Down Expand Up @@ -150988,6 +151005,7 @@ var ts;
var nextFileToCheck = 0;
return { getModifiedTime: getModifiedTime, poll: poll, startWatchTimer: startWatchTimer, addFile: addFile, removeFile: removeFile };
function getModifiedTime(fileName) {
// Caller guarantees that `fileName` exists, so there'd be no benefit from throwIfNoEntry
return fs.statSync(fileName).mtime;
}
function poll(checkedIndex) {
Expand Down
35 changes: 26 additions & 9 deletions lib/tsserverlibrary.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ var ts;
// If changing the text in this section, be sure to test `configurePrerelease` too.
ts.versionMajorMinor = "3.9";
/** The version of the TypeScript compiler release */
ts.version = "3.9.9";
ts.version = "3.9.10";
/**
* Returns the native Map implementation if it is available and compatible (i.e. supports iteration).
*/
Expand Down Expand Up @@ -5666,8 +5666,8 @@ var ts;
},
getFileSize: function (path) {
try {
var stat = _fs.statSync(path);
if (stat.isFile()) {
var stat = statSync(path);
if (stat === null || stat === void 0 ? void 0 : stat.isFile()) {
return stat.size;
}
}
Expand Down Expand Up @@ -5713,6 +5713,15 @@ var ts;
}
};
return nodeSystem;
/**
* `throwIfNoEntry` was added so recently that it's not in the node types.
* This helper encapsulates the mitigating usage of `any`.
* See https://github.com/nodejs/node/pull/33716
*/
function statSync(path) {
// throwIfNoEntry will be ignored by older versions of node
return _fs.statSync(path, { throwIfNoEntry: false });
}
/**
* Uses the builtin inspector APIs to capture a CPU profile
* See https://nodejs.org/api/inspector.html#inspector_example_usage for details
Expand Down Expand Up @@ -5767,20 +5776,21 @@ var ts;
if (activeSession && activeSession !== "stopping") {
var s_1 = activeSession;
activeSession.post("Profiler.stop", function (err, _a) {
var _b;
var profile = _a.profile;
if (!err) {
try {
if (_fs.statSync(profilePath).isDirectory()) {
if ((_b = statSync(profilePath)) === null || _b === void 0 ? void 0 : _b.isDirectory()) {
profilePath = _path.join(profilePath, (new Date()).toISOString().replace(/:/g, "-") + "+P" + process.pid + ".cpuprofile");
}
}
catch (_b) {
catch (_c) {
// do nothing and ignore fallible fs operation
}
try {
_fs.mkdirSync(_path.dirname(profilePath), { recursive: true });
}
catch (_c) {
catch (_d) {
// do nothing and ignore fallible fs operation
}
_fs.writeFileSync(profilePath, JSON.stringify(cleanupPaths(profile)));
Expand Down Expand Up @@ -6019,7 +6029,10 @@ var ts;
if (typeof dirent === "string" || dirent.isSymbolicLink()) {
var name = ts.combinePaths(path, entry);
try {
stat = _fs.statSync(name);
stat = statSync(name);
if (!stat) {
continue;
}
}
catch (e) {
continue;
Expand Down Expand Up @@ -6048,7 +6061,10 @@ var ts;
}
function fileSystemEntryExists(path, entryKind) {
try {
var stat = _fs.statSync(path);
var stat = statSync(path);
if (!stat) {
return false;
}
switch (entryKind) {
case 0 /* File */: return stat.isFile();
case 1 /* Directory */: return stat.isDirectory();
Expand Down Expand Up @@ -6077,8 +6093,9 @@ var ts;
}
}
function getModifiedTime(path) {
var _a;
try {
return _fs.statSync(path).mtime;
return (_a = statSync(path)) === null || _a === void 0 ? void 0 : _a.mtime;
}
catch (e) {
return undefined;
Expand Down
35 changes: 26 additions & 9 deletions lib/typescript.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ var ts;
// If changing the text in this section, be sure to test `configurePrerelease` too.
ts.versionMajorMinor = "3.9";
/** The version of the TypeScript compiler release */
ts.version = "3.9.9";
ts.version = "3.9.10";
/**
* Returns the native Map implementation if it is available and compatible (i.e. supports iteration).
*/
Expand Down Expand Up @@ -5666,8 +5666,8 @@ var ts;
},
getFileSize: function (path) {
try {
var stat = _fs.statSync(path);
if (stat.isFile()) {
var stat = statSync(path);
if (stat === null || stat === void 0 ? void 0 : stat.isFile()) {
return stat.size;
}
}
Expand Down Expand Up @@ -5713,6 +5713,15 @@ var ts;
}
};
return nodeSystem;
/**
* `throwIfNoEntry` was added so recently that it's not in the node types.
* This helper encapsulates the mitigating usage of `any`.
* See https://github.com/nodejs/node/pull/33716
*/
function statSync(path) {
// throwIfNoEntry will be ignored by older versions of node
return _fs.statSync(path, { throwIfNoEntry: false });
}
/**
* Uses the builtin inspector APIs to capture a CPU profile
* See https://nodejs.org/api/inspector.html#inspector_example_usage for details
Expand Down Expand Up @@ -5767,20 +5776,21 @@ var ts;
if (activeSession && activeSession !== "stopping") {
var s_1 = activeSession;
activeSession.post("Profiler.stop", function (err, _a) {
var _b;
var profile = _a.profile;
if (!err) {
try {
if (_fs.statSync(profilePath).isDirectory()) {
if ((_b = statSync(profilePath)) === null || _b === void 0 ? void 0 : _b.isDirectory()) {
profilePath = _path.join(profilePath, (new Date()).toISOString().replace(/:/g, "-") + "+P" + process.pid + ".cpuprofile");
}
}
catch (_b) {
catch (_c) {
// do nothing and ignore fallible fs operation
}
try {
_fs.mkdirSync(_path.dirname(profilePath), { recursive: true });
}
catch (_c) {
catch (_d) {
// do nothing and ignore fallible fs operation
}
_fs.writeFileSync(profilePath, JSON.stringify(cleanupPaths(profile)));
Expand Down Expand Up @@ -6019,7 +6029,10 @@ var ts;
if (typeof dirent === "string" || dirent.isSymbolicLink()) {
var name = ts.combinePaths(path, entry);
try {
stat = _fs.statSync(name);
stat = statSync(name);
if (!stat) {
continue;
}
}
catch (e) {
continue;
Expand Down Expand Up @@ -6048,7 +6061,10 @@ var ts;
}
function fileSystemEntryExists(path, entryKind) {
try {
var stat = _fs.statSync(path);
var stat = statSync(path);
if (!stat) {
return false;
}
switch (entryKind) {
case 0 /* File */: return stat.isFile();
case 1 /* Directory */: return stat.isDirectory();
Expand Down Expand Up @@ -6077,8 +6093,9 @@ var ts;
}
}
function getModifiedTime(path) {
var _a;
try {
return _fs.statSync(path).mtime;
return (_a = statSync(path)) === null || _a === void 0 ? void 0 : _a.mtime;
}
catch (e) {
return undefined;
Expand Down

0 comments on commit b7de5e3

Please sign in to comment.