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

Function getTypeParametersForTypeReference

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

Source from the content-addressed store, hash-verified

80651 return result;
80652 }
80653 function getTypeParametersForTypeReference(node) {
80654 var type = getTypeFromTypeReference(node);
80655 if (!isErrorType(type)) {
80656 var symbol = getNodeLinks(node).resolvedSymbol;
80657 if (symbol) {
80658 return symbol.flags & 524288 /* SymbolFlags.TypeAlias */ && getSymbolLinks(symbol).typeParameters ||
80659 (ts.getObjectFlags(type) & 4 /* ObjectFlags.Reference */ ? type.target.localTypeParameters : undefined);
80660 }
80661 }
80662 return undefined;
80663 }
80664 function checkTypeReferenceNode(node) {
80665 checkGrammarTypeArguments(node, node.typeArguments);
80666 if (node.kind === 178 /* SyntaxKind.TypeReference */ && node.typeName.jsdocDotPos !== undefined && !ts.isInJSFile(node) && !ts.isInJSDoc(node)) {

Callers 3

checkTypeReferenceNodeFunction · 0.85

Calls 4

getTypeFromTypeReferenceFunction · 0.85
isErrorTypeFunction · 0.85
getNodeLinksFunction · 0.85
getSymbolLinksFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…