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

Function forEachLeadingCommentToEmit

test/fixtures/snapshot/typescript.js:114966–114976  ·  view source on GitHub ↗
(pos, cb)

Source from the content-addressed store, hash-verified

114964 }
114965 }
114966 function forEachLeadingCommentToEmit(pos, cb) {
114967 // Emit the leading comments only if the container's pos doesn't match because the container should take care of emitting these comments
114968 if (currentSourceFile && (containerPos === -1 || pos !== containerPos)) {
114969 if (hasDetachedComments(pos)) {
114970 forEachLeadingCommentWithoutDetachedComments(cb);
114971 }
114972 else {
114973 ts.forEachLeadingCommentRange(currentSourceFile.text, pos, cb, /*state*/ pos);
114974 }
114975 }
114976 }
114977 function forEachTrailingCommentToEmit(end, cb) {
114978 // Emit the trailing comments only if the container's end doesn't match because the container should take care of emitting these comments
114979 if (currentSourceFile && (containerEnd === -1 || (end !== containerEnd && end !== declarationListContainerEnd))) {

Callers 1

emitLeadingCommentsFunction · 0.85

Tested by

no test coverage detected