MCPcopy Create free account
hub / github.com/nodejs/node / toContextSpan

Function toContextSpan

test/fixtures/snapshot/typescript.js:136947–136956  ·  view source on GitHub ↗
(textSpan, sourceFile, context)

Source from the content-addressed store, hash-verified

136945 }
136946 FindAllReferences.getContextNode = getContextNode;
136947 function toContextSpan(textSpan, sourceFile, context) {
136948 if (!context)
136949 return undefined;
136950 var contextSpan = isContextWithStartAndEndNode(context) ?
136951 getTextSpan(context.start, sourceFile, context.end) :
136952 getTextSpan(context, sourceFile);
136953 return contextSpan.start !== textSpan.start || contextSpan.length !== textSpan.length ?
136954 { contextSpan: contextSpan } :
136955 undefined;
136956 }
136957 FindAllReferences.toContextSpan = toContextSpan;
136958 var FindReferencesUse;
136959 (function (FindReferencesUse) {

Callers 2

entryToDocumentSpanFunction · 0.85

Calls 2

getTextSpanFunction · 0.85

Tested by

no test coverage detected