MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / takesExactly

Function takesExactly

src/resolution/pascal-scope.ts:407–411  ·  view source on GitHub ↗

Whether a routine takes exactly a call's argument count, none of them left to a default.

(routine: Node, ref: UnresolvedRef, context: ResolutionContext)

Source from the content-addressed store, hash-verified

405
406/** Whether a routine takes exactly a call's argument count, none of them left to a default. */
407function takesExactly(routine: Node, ref: UnresolvedRef, context: ResolutionContext): boolean {
408 const count = pascalCallArgumentCount(ref, context);
409 const range = pascalParameterRange(routine.signature);
410 return count !== null && range !== null && range[0] === count && range[1] === count;
411}
412
413/**
414 * Whether two routine nodes are the same routine, or overloads of it: the

Callers 1

gatePascalCallFunction · 0.85

Calls 2

pascalCallArgumentCountFunction · 0.85
pascalParameterRangeFunction · 0.85

Tested by

no test coverage detected