(sourceFile, toMove, needExport, useEs6Exports)
| 162273 | return ts.factory.createCallExpression(ts.factory.createIdentifier("require"), /*typeArguments*/ undefined, [moduleSpecifier]); |
| 162274 | } |
| 162275 | function addExports(sourceFile, toMove, needExport, useEs6Exports) { |
| 162276 | return ts.flatMap(toMove, function (statement) { |
| 162277 | if (isTopLevelDeclarationStatement(statement) && |
| 162278 | !isExported(sourceFile, statement, useEs6Exports) && |
| 162279 | forEachTopLevelDeclaration(statement, function (d) { return needExport.has(ts.Debug.checkDefined(d.symbol)); })) { |
| 162280 | var exports = addExport(statement, useEs6Exports); |
| 162281 | if (exports) |
| 162282 | return exports; |
| 162283 | } |
| 162284 | return statement; |
| 162285 | }); |
| 162286 | } |
| 162287 | function deleteUnusedImports(sourceFile, importDecl, changes, isUnused) { |
| 162288 | switch (importDecl.kind) { |
| 162289 | case 266 /* SyntaxKind.ImportDeclaration */: |
no test coverage detected