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

Function isProceduralData

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

* Whether data holds a routine, by its declared type: one written in place * (`FProc: procedure of object`, `F: reference to function: Integer`), a * project type declared as one (`TOnLog = procedure(...) of object;`), or a * type the project doesn't declare that the RTL's names say is one * (`T

(node: Node, context: ResolutionContext)

Source from the content-addressed store, hash-verified

2674 * (`TNotifyEvent`, `TWndMethod`, `TProc<T>`).
2675 */
2676function isProceduralData(node: Node, context: ResolutionContext): boolean {
2677 const memo = memos(context).procedural;
2678 const hit = memo.get(node.id);
2679 if (hit !== undefined) return hit;
2680 const procedural = isProceduralTypeText(declaredTypeText(node, context), context, 0);
2681 memo.set(node.id, procedural);
2682 return procedural;
2683}
2684
2685/**
2686 * Whether a written type is a routine's: written out

Callers 6

matchPascalSystemCallFunction · 0.85
gatePascalCallFunction · 0.85
gatePascalDataCallFunction · 0.85
matchPascalNestedCallFunction · 0.85
gatePascalNestedTargetFunction · 0.85
memberThroughPathFunction · 0.85

Calls 5

memosFunction · 0.85
isProceduralTypeTextFunction · 0.85
declaredTypeTextFunction · 0.85
getMethod · 0.65
setMethod · 0.45

Tested by

no test coverage detected