File tree Expand file tree Collapse file tree 1 file changed +3
-9
lines changed Expand file tree Collapse file tree 1 file changed +3
-9
lines changed Original file line number Diff line number Diff line change @@ -1789,11 +1789,6 @@ namespace ts {
1789
1789
sourceFile . moduleName = moduleName ;
1790
1790
}
1791
1791
1792
- // Store syntactic diagnostics
1793
- if ( diagnostics && sourceFile . parseDiagnostics ) {
1794
- diagnostics . push ( ...sourceFile . parseDiagnostics ) ;
1795
- }
1796
-
1797
1792
let newLine = getNewLineCharacter ( options ) ;
1798
1793
1799
1794
// Output
@@ -1815,9 +1810,8 @@ namespace ts {
1815
1810
1816
1811
var program = createProgram ( [ inputFileName ] , options , compilerHost ) ;
1817
1812
1818
- if ( diagnostics ) {
1819
- diagnostics . push ( ...program . getCompilerOptionsDiagnostics ( ) ) ;
1820
- }
1813
+ addRange ( /*to*/ diagnostics , /*from*/ sourceFile . parseDiagnostics ) ;
1814
+ addRange ( /*to*/ diagnostics , /*from*/ program . getCompilerOptionsDiagnostics ( ) ) ;
1821
1815
1822
1816
// Emit
1823
1817
program . emit ( ) ;
@@ -4188,7 +4182,7 @@ namespace ts {
4188
4182
var result : DefinitionInfo [ ] = [ ] ;
4189
4183
forEach ( ( < UnionType > type ) . types , t => {
4190
4184
if ( t . symbol ) {
4191
- result . push ( ... getDefinitionFromSymbol ( t . symbol , node ) ) ;
4185
+ addRange ( /*to*/ result , /*from*/ getDefinitionFromSymbol ( t . symbol , node ) ) ;
4192
4186
}
4193
4187
} ) ;
4194
4188
return result ;
You can’t perform that action at this time.
0 commit comments