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

Function addDeclarationToLateBoundSymbol

test/fixtures/snapshot/typescript.js:57730–57745  ·  view source on GitHub ↗

* Adds a declaration to a late-bound dynamic member. This performs the same function for * late-bound members that `addDeclarationToSymbol` in binder.ts performs for early-bound * members.

(symbol, member, symbolFlags)

Source from the content-addressed store, hash-verified

57728 * members.
57729 */
57730 function addDeclarationToLateBoundSymbol(symbol, member, symbolFlags) {
57731 ts.Debug.assert(!!(ts.getCheckFlags(symbol) & 4096 /* CheckFlags.Late */), "Expected a late-bound symbol.");
57732 symbol.flags |= symbolFlags;
57733 getSymbolLinks(member.symbol).lateSymbol = symbol;
57734 if (!symbol.declarations) {
57735 symbol.declarations = [member];
57736 }
57737 else if (!member.symbol.isReplaceableByMethod) {
57738 symbol.declarations.push(member);
57739 }
57740 if (symbolFlags & 111551 /* SymbolFlags.Value */) {
57741 if (!symbol.valueDeclaration || symbol.valueDeclaration.kind !== member.kind) {
57742 symbol.valueDeclaration = member;
57743 }
57744 }
57745 }
57746 /**
57747 * Performs late-binding of a dynamic member. This performs the same function for
57748 * late-bound members that `declareSymbol` in binder.ts performs for early-bound

Callers 1

lateBindMemberFunction · 0.85

Calls 3

getSymbolLinksFunction · 0.85
assertMethod · 0.80
pushMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…