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

Function getTypeForBindingElement

test/fixtures/snapshot/typescript.js:55847–55851  ·  view source on GitHub ↗

Return the inferred type for a binding element

(declaration)

Source from the content-addressed store, hash-verified

55845 }
55846 /** Return the inferred type for a binding element */
55847 function getTypeForBindingElement(declaration) {
55848 var checkMode = declaration.dotDotDotToken ? 64 /* CheckMode.RestBindingElement */ : 0 /* CheckMode.Normal */;
55849 var parentType = getTypeForBindingElementParent(declaration.parent.parent, checkMode);
55850 return parentType && getBindingElementTypeFromParentType(declaration, parentType);
55851 }
55852 function getBindingElementTypeFromParentType(declaration, parentType) {
55853 // If an any type was inferred for parent, infer that for the binding element
55854 if (isTypeAny(parentType)) {

Callers 1

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…