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

Function emitTryStatement

test/fixtures/snapshot/typescript.js:112717–112731  ·  view source on GitHub ↗
(node)

Source from the content-addressed store, hash-verified

112715 writeTrailingSemicolon();
112716 }
112717 function emitTryStatement(node) {
112718 emitTokenWithComment(111 /* SyntaxKind.TryKeyword */, node.pos, writeKeyword, node);
112719 writeSpace();
112720 emit(node.tryBlock);
112721 if (node.catchClause) {
112722 writeLineOrSpace(node, node.tryBlock, node.catchClause);
112723 emit(node.catchClause);
112724 }
112725 if (node.finallyBlock) {
112726 writeLineOrSpace(node, node.catchClause || node.tryBlock, node.finallyBlock);
112727 emitTokenWithComment(96 /* SyntaxKind.FinallyKeyword */, (node.catchClause || node.tryBlock).end, writeKeyword, node);
112728 writeSpace();
112729 emit(node.finallyBlock);
112730 }
112731 }
112732 function emitDebuggerStatement(node) {
112733 writeToken(87 /* SyntaxKind.DebuggerKeyword */, node.pos, writeKeyword);
112734 writeTrailingSemicolon();

Callers 1

Calls 4

emitTokenWithCommentFunction · 0.85
writeSpaceFunction · 0.85
writeLineOrSpaceFunction · 0.85
emitFunction · 0.70

Tested by

no test coverage detected