Fix refactoring misses

This commit is contained in:
Andrew Branch committed 2019-09-12 13:29:14 -07:00
1 parent ca8b8f0638
commit 9c33590965
6 files changed
+6 -6

No files matched your search

+1 -1
View File
@@ -2064,7 +2064,7 @@ namespace ts {
}
const startLine = sourceFile.getLineAndCharacterOfPosition(node.getEnd()).line;
const endLine = sourceFile.getLineAndCharacterOfPosition(node.getStart(sourceFile)).line;
const endLine = sourceFile.getLineAndCharacterOfPosition(nextToken.getStart(sourceFile)).line;
return startLine !== endLine;
}
@@ -2,7 +2,7 @@
// @noImplicitAny: true
////function wrap( [| arr |] ) {
//// arr.sort(function (a: number, b: number) { return a < b ? -1 : 1 })
//// arr.sort(function (a: number, b: number) { return a < b ? -1 : 1 });
//// }
// https://github.com/Microsoft/TypeScript/issues/29330
@@ -23,7 +23,7 @@
////declare module 'bar'
////type T = { x: string, y: number }
format.setFormatOptions({ ...format.copyFormatOptions(), insertTrailingSemicolon: true });
format.setFormatOptions({ ...format.copyFormatOptions(), semicolons: ts.SemicolonPreference.Insert });
format.document();
verify.currentFileContentIs(`console.log(1);
console.log(2);
@@ -37,7 +37,7 @@
//// ();
////}
format.setFormatOptions({ ...format.copyFormatOptions(), insertTrailingSemicolon: false });
format.setFormatOptions({ ...format.copyFormatOptions(), semicolons: ts.SemicolonPreference.Remove });
format.document();
verify.currentFileContentIs(`; (function f() { })()
const a = 3;
@@ -12,7 +12,7 @@
////}
////let z = 0; //
format.setFormatOptions({ ...format.copyFormatOptions(), insertTrailingSemicolon: false });
format.setFormatOptions({ ...format.copyFormatOptions(), semicolons: ts.SemicolonPreference.Remove });
format.document();
verify.currentFileContentIs(`namespace ts {
let x = 0
@@ -4,7 +4,7 @@
////// Start with signatures at empty array in case of recursive types
////(<InterfaceTypeWithDeclaredMembers>type).declaredCallSignatures = emptyArray;
format.setFormatOptions({ ...format.copyFormatOptions(), insertTrailingSemicolon: false });
format.setFormatOptions({ ...format.copyFormatOptions(), semicolons: ts.SemicolonPreference.Remove });
format.document();
verify.currentFileContentIs(`(<InterfaceTypeWithDeclaredMembers>type).declaredProperties = getNamedMembers(members);
// Start with signatures at empty array in case of recursive types