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

Function classInitializer

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

* Whether a routine is a class constructor or destructor (`class constructor * Create;`), which only the runtime runs: no `inherited Create` reaches one, * and an `inherited` written in one links nothing.

(routine: Node, context: ResolutionContext)

Source from the content-addressed store, hash-verified

232 * and an `inherited` written in one links nothing.
233 */
234function classInitializer(routine: Node, context: ResolutionContext): boolean {
235 if (routine.isStatic !== true) return false;
236 const keyword = routineKeyword(routine, context);
237 return keyword === 'constructor' || keyword === 'destructor';
238}
239
240/**
241 * The classes an `inherited` call made in a method of `cls` looks in, nearest

Callers 1

matchPascalInheritedCallFunction · 0.85

Calls 1

routineKeywordFunction · 0.85

Tested by

no test coverage detected