Skip to content

Commit

Permalink
Update LKG.
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielRosenwasser authored Nov 1, 2022
1 parent 31bee56 commit 107f832
Show file tree
Hide file tree
Showing 7 changed files with 85 additions and 61 deletions.
2 changes: 1 addition & 1 deletion lib/cancellationToken.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

24 changes: 14 additions & 10 deletions lib/tsc.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
function verb(n) { return function (v) { return step([n, v]); }; }
function step(op) {
if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
if (y = 0, t) op = [op[0] & 2, t.value];
switch (op[0]) {
Expand Down Expand Up @@ -98124,14 +98124,16 @@ var ts;
}
return setReadFileCache(key, fileName);
};
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersion, onError, shouldCreateNewSourceFile) {
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
var key = toPath(fileName);
var value = sourceFileCache.get(key);
var impliedNodeFormat = typeof languageVersionOrOptions === "object" ? languageVersionOrOptions.impliedNodeFormat : undefined;
var forImpliedNodeFormat = sourceFileCache.get(impliedNodeFormat);
var value = forImpliedNodeFormat === null || forImpliedNodeFormat === void 0 ? void 0 : forImpliedNodeFormat.get(key);
if (value)
return value;
var sourceFile = getSourceFile(fileName, languageVersion, onError, shouldCreateNewSourceFile);
var sourceFile = getSourceFile(fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile);
if (sourceFile && (ts.isDeclarationFileName(fileName) || ts.fileExtensionIs(fileName, ".json"))) {
sourceFileCache.set(key, sourceFile);
sourceFileCache.set(impliedNodeFormat, (forImpliedNodeFormat || new ts.Map()).set(key, sourceFile));
}
return sourceFile;
} : undefined;
Expand All @@ -98155,13 +98157,15 @@ var ts;
var value = readFileCache.get(key);
if (value !== undefined && value !== data) {
readFileCache.delete(key);
sourceFileCache.delete(key);
sourceFileCache.forEach(function (map) { return map.delete(key); });
}
else if (getSourceFileWithCache) {
var sourceFile = sourceFileCache.get(key);
if (sourceFile && sourceFile.text !== data) {
sourceFileCache.delete(key);
}
sourceFileCache.forEach(function (map) {
var sourceFile = map.get(key);
if (sourceFile && sourceFile.text !== data) {
map.delete(key);
}
});
}
originalWriteFile.call.apply(originalWriteFile, __spreadArray([host, fileName, data], rest, false));
};
Expand Down
24 changes: 14 additions & 10 deletions lib/tsserver.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
function verb(n) { return function (v) { return step([n, v]); }; }
function step(op) {
if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
if (y = 0, t) op = [op[0] & 2, t.value];
switch (op[0]) {
Expand Down Expand Up @@ -118604,14 +118604,16 @@ var ts;
}
return setReadFileCache(key, fileName);
};
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersion, onError, shouldCreateNewSourceFile) {
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
var key = toPath(fileName);
var value = sourceFileCache.get(key);
var impliedNodeFormat = typeof languageVersionOrOptions === "object" ? languageVersionOrOptions.impliedNodeFormat : undefined;
var forImpliedNodeFormat = sourceFileCache.get(impliedNodeFormat);
var value = forImpliedNodeFormat === null || forImpliedNodeFormat === void 0 ? void 0 : forImpliedNodeFormat.get(key);
if (value)
return value;
var sourceFile = getSourceFile(fileName, languageVersion, onError, shouldCreateNewSourceFile);
var sourceFile = getSourceFile(fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile);
if (sourceFile && (ts.isDeclarationFileName(fileName) || ts.fileExtensionIs(fileName, ".json" /* Extension.Json */))) {
sourceFileCache.set(key, sourceFile);
sourceFileCache.set(impliedNodeFormat, (forImpliedNodeFormat || new ts.Map()).set(key, sourceFile));
}
return sourceFile;
} : undefined;
Expand All @@ -118636,13 +118638,15 @@ var ts;
var value = readFileCache.get(key);
if (value !== undefined && value !== data) {
readFileCache.delete(key);
sourceFileCache.delete(key);
sourceFileCache.forEach(function (map) { return map.delete(key); });
}
else if (getSourceFileWithCache) {
var sourceFile = sourceFileCache.get(key);
if (sourceFile && sourceFile.text !== data) {
sourceFileCache.delete(key);
}
sourceFileCache.forEach(function (map) {
var sourceFile = map.get(key);
if (sourceFile && sourceFile.text !== data) {
map.delete(key);
}
});
}
originalWriteFile.call.apply(originalWriteFile, __spreadArray([host, fileName, data], rest, false));
};
Expand Down
24 changes: 14 additions & 10 deletions lib/tsserverlibrary.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
function verb(n) { return function (v) { return step([n, v]); }; }
function step(op) {
if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
if (y = 0, t) op = [op[0] & 2, t.value];
switch (op[0]) {
Expand Down Expand Up @@ -118603,14 +118603,16 @@ var ts;
}
return setReadFileCache(key, fileName);
};
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersion, onError, shouldCreateNewSourceFile) {
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
var key = toPath(fileName);
var value = sourceFileCache.get(key);
var impliedNodeFormat = typeof languageVersionOrOptions === "object" ? languageVersionOrOptions.impliedNodeFormat : undefined;
var forImpliedNodeFormat = sourceFileCache.get(impliedNodeFormat);
var value = forImpliedNodeFormat === null || forImpliedNodeFormat === void 0 ? void 0 : forImpliedNodeFormat.get(key);
if (value)
return value;
var sourceFile = getSourceFile(fileName, languageVersion, onError, shouldCreateNewSourceFile);
var sourceFile = getSourceFile(fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile);
if (sourceFile && (ts.isDeclarationFileName(fileName) || ts.fileExtensionIs(fileName, ".json" /* Extension.Json */))) {
sourceFileCache.set(key, sourceFile);
sourceFileCache.set(impliedNodeFormat, (forImpliedNodeFormat || new ts.Map()).set(key, sourceFile));
}
return sourceFile;
} : undefined;
Expand All @@ -118635,13 +118637,15 @@ var ts;
var value = readFileCache.get(key);
if (value !== undefined && value !== data) {
readFileCache.delete(key);
sourceFileCache.delete(key);
sourceFileCache.forEach(function (map) { return map.delete(key); });
}
else if (getSourceFileWithCache) {
var sourceFile = sourceFileCache.get(key);
if (sourceFile && sourceFile.text !== data) {
sourceFileCache.delete(key);
}
sourceFileCache.forEach(function (map) {
var sourceFile = map.get(key);
if (sourceFile && sourceFile.text !== data) {
map.delete(key);
}
});
}
originalWriteFile.call.apply(originalWriteFile, __spreadArray([host, fileName, data], rest, false));
};
Expand Down
24 changes: 14 additions & 10 deletions lib/typescript.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
function verb(n) { return function (v) { return step([n, v]); }; }
function step(op) {
if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
if (y = 0, t) op = [op[0] & 2, t.value];
switch (op[0]) {
Expand Down Expand Up @@ -118594,14 +118594,16 @@ var ts;
}
return setReadFileCache(key, fileName);
};
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersion, onError, shouldCreateNewSourceFile) {
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
var key = toPath(fileName);
var value = sourceFileCache.get(key);
var impliedNodeFormat = typeof languageVersionOrOptions === "object" ? languageVersionOrOptions.impliedNodeFormat : undefined;
var forImpliedNodeFormat = sourceFileCache.get(impliedNodeFormat);
var value = forImpliedNodeFormat === null || forImpliedNodeFormat === void 0 ? void 0 : forImpliedNodeFormat.get(key);
if (value)
return value;
var sourceFile = getSourceFile(fileName, languageVersion, onError, shouldCreateNewSourceFile);
var sourceFile = getSourceFile(fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile);
if (sourceFile && (ts.isDeclarationFileName(fileName) || ts.fileExtensionIs(fileName, ".json" /* Extension.Json */))) {
sourceFileCache.set(key, sourceFile);
sourceFileCache.set(impliedNodeFormat, (forImpliedNodeFormat || new ts.Map()).set(key, sourceFile));
}
return sourceFile;
} : undefined;
Expand All @@ -118626,13 +118628,15 @@ var ts;
var value = readFileCache.get(key);
if (value !== undefined && value !== data) {
readFileCache.delete(key);
sourceFileCache.delete(key);
sourceFileCache.forEach(function (map) { return map.delete(key); });
}
else if (getSourceFileWithCache) {
var sourceFile = sourceFileCache.get(key);
if (sourceFile && sourceFile.text !== data) {
sourceFileCache.delete(key);
}
sourceFileCache.forEach(function (map) {
var sourceFile = map.get(key);
if (sourceFile && sourceFile.text !== data) {
map.delete(key);
}
});
}
originalWriteFile.call.apply(originalWriteFile, __spreadArray([host, fileName, data], rest, false));
};
Expand Down
24 changes: 14 additions & 10 deletions lib/typescriptServices.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
function verb(n) { return function (v) { return step([n, v]); }; }
function step(op) {
if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
if (y = 0, t) op = [op[0] & 2, t.value];
switch (op[0]) {
Expand Down Expand Up @@ -118594,14 +118594,16 @@ var ts;
}
return setReadFileCache(key, fileName);
};
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersion, onError, shouldCreateNewSourceFile) {
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
var key = toPath(fileName);
var value = sourceFileCache.get(key);
var impliedNodeFormat = typeof languageVersionOrOptions === "object" ? languageVersionOrOptions.impliedNodeFormat : undefined;
var forImpliedNodeFormat = sourceFileCache.get(impliedNodeFormat);
var value = forImpliedNodeFormat === null || forImpliedNodeFormat === void 0 ? void 0 : forImpliedNodeFormat.get(key);
if (value)
return value;
var sourceFile = getSourceFile(fileName, languageVersion, onError, shouldCreateNewSourceFile);
var sourceFile = getSourceFile(fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile);
if (sourceFile && (ts.isDeclarationFileName(fileName) || ts.fileExtensionIs(fileName, ".json" /* Extension.Json */))) {
sourceFileCache.set(key, sourceFile);
sourceFileCache.set(impliedNodeFormat, (forImpliedNodeFormat || new ts.Map()).set(key, sourceFile));
}
return sourceFile;
} : undefined;
Expand All @@ -118626,13 +118628,15 @@ var ts;
var value = readFileCache.get(key);
if (value !== undefined && value !== data) {
readFileCache.delete(key);
sourceFileCache.delete(key);
sourceFileCache.forEach(function (map) { return map.delete(key); });
}
else if (getSourceFileWithCache) {
var sourceFile = sourceFileCache.get(key);
if (sourceFile && sourceFile.text !== data) {
sourceFileCache.delete(key);
}
sourceFileCache.forEach(function (map) {
var sourceFile = map.get(key);
if (sourceFile && sourceFile.text !== data) {
map.delete(key);
}
});
}
originalWriteFile.call.apply(originalWriteFile, __spreadArray([host, fileName, data], rest, false));
};
Expand Down
24 changes: 14 additions & 10 deletions lib/typingsInstaller.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
function verb(n) { return function (v) { return step([n, v]); }; }
function step(op) {
if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
if (y = 0, t) op = [op[0] & 2, t.value];
switch (op[0]) {
Expand Down Expand Up @@ -118584,14 +118584,16 @@ var ts;
}
return setReadFileCache(key, fileName);
};
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersion, onError, shouldCreateNewSourceFile) {
var getSourceFileWithCache = getSourceFile ? function (fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
var key = toPath(fileName);
var value = sourceFileCache.get(key);
var impliedNodeFormat = typeof languageVersionOrOptions === "object" ? languageVersionOrOptions.impliedNodeFormat : undefined;
var forImpliedNodeFormat = sourceFileCache.get(impliedNodeFormat);
var value = forImpliedNodeFormat === null || forImpliedNodeFormat === void 0 ? void 0 : forImpliedNodeFormat.get(key);
if (value)
return value;
var sourceFile = getSourceFile(fileName, languageVersion, onError, shouldCreateNewSourceFile);
var sourceFile = getSourceFile(fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile);
if (sourceFile && (ts.isDeclarationFileName(fileName) || ts.fileExtensionIs(fileName, ".json" /* Extension.Json */))) {
sourceFileCache.set(key, sourceFile);
sourceFileCache.set(impliedNodeFormat, (forImpliedNodeFormat || new ts.Map()).set(key, sourceFile));
}
return sourceFile;
} : undefined;
Expand All @@ -118616,13 +118618,15 @@ var ts;
var value = readFileCache.get(key);
if (value !== undefined && value !== data) {
readFileCache.delete(key);
sourceFileCache.delete(key);
sourceFileCache.forEach(function (map) { return map.delete(key); });
}
else if (getSourceFileWithCache) {
var sourceFile = sourceFileCache.get(key);
if (sourceFile && sourceFile.text !== data) {
sourceFileCache.delete(key);
}
sourceFileCache.forEach(function (map) {
var sourceFile = map.get(key);
if (sourceFile && sourceFile.text !== data) {
map.delete(key);
}
});
}
originalWriteFile.call.apply(originalWriteFile, __spreadArray([host, fileName, data], rest, false));
};
Expand Down

0 comments on commit 107f832

Please sign in to comment.