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

Function emitBlockFunctionBodyWorker

test/fixtures/snapshot/typescript.js:112843–112856  ·  view source on GitHub ↗
(body, emitBlockFunctionBodyOnSingleLine)

Source from the content-addressed store, hash-verified

112841 emitBlockFunctionBodyWorker(body, /*emitBlockFunctionBodyOnSingleLine*/ true);
112842 }
112843 function emitBlockFunctionBodyWorker(body, emitBlockFunctionBodyOnSingleLine) {
112844 // Emit all the prologue directives (like "use strict").
112845 var statementOffset = emitPrologueDirectives(body.statements);
112846 var pos = writer.getTextPos();
112847 emitHelpers(body);
112848 if (statementOffset === 0 && pos === writer.getTextPos() && emitBlockFunctionBodyOnSingleLine) {
112849 decreaseIndent();
112850 emitList(body, body.statements, 768 /* ListFormat.SingleLineFunctionBodyStatements */);
112851 increaseIndent();
112852 }
112853 else {
112854 emitList(body, body.statements, 1 /* ListFormat.MultiLineFunctionBodyStatements */, /*parenthesizerRule*/ undefined, statementOffset);
112855 }
112856 }
112857 function emitClassDeclaration(node) {
112858 emitClassDeclarationOrExpression(node);
112859 }

Callers 1

Calls 5

emitPrologueDirectivesFunction · 0.85
emitHelpersFunction · 0.85
decreaseIndentFunction · 0.85
emitListFunction · 0.85
increaseIndentFunction · 0.85

Tested by

no test coverage detected