MCPcopy Index your code
hub / github.com/nodejs/node / transformDeclarationsForJS

Function transformDeclarationsForJS

test/fixtures/snapshot/typescript.js:108238–108249  ·  view source on GitHub ↗
(sourceFile, bundled)

Source from the content-addressed store, hash-verified

108236 }
108237 }
108238 function transformDeclarationsForJS(sourceFile, bundled) {
108239 var oldDiag = getSymbolAccessibilityDiagnostic;
108240 getSymbolAccessibilityDiagnostic = function (s) { return (s.errorNode && ts.canProduceDiagnostics(s.errorNode) ? ts.createGetSymbolAccessibilityDiagnosticForNode(s.errorNode)(s) : ({
108241 diagnosticMessage: s.errorModuleName
108242 ? ts.Diagnostics.Declaration_emit_for_this_file_requires_using_private_name_0_from_module_1_An_explicit_type_annotation_may_unblock_declaration_emit
108243 : ts.Diagnostics.Declaration_emit_for_this_file_requires_using_private_name_0_An_explicit_type_annotation_may_unblock_declaration_emit,
108244 errorNode: s.errorNode || sourceFile
108245 })); };
108246 var result = resolver.getDeclarationStatementsForSourceFile(sourceFile, declarationEmitNodeBuilderFlags, symbolTracker, bundled);
108247 getSymbolAccessibilityDiagnostic = oldDiag;
108248 return result;
108249 }
108250 function transformRoot(node) {
108251 if (node.kind === 305 /* SyntaxKind.SourceFile */ && node.isDeclarationFile) {
108252 return node;

Callers 1

transformRootFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected