MCPcopy Create free account
hub / github.com/compilets/compilets / constructor

Method constructor

src/cpp-syntax.ts:816–821  ·  view source on GitHub ↗
(name: string, modifiers: string[], type: Type, initializer?: Expression)

Source from the content-addressed store, hash-verified

814 initializer?: Expression;
815
816 constructor(name: string, modifiers: string[], type: Type, initializer?: Expression) {
817 super(name, modifiers);
818 this.type = type;
819 if (initializer)
820 this.initializer = castExpression(initializer, type);
821 }
822
823 override print(ctx: PrintContext) {
824 this.type.markUsed(ctx);

Callers

nothing calls this directly

Calls 1

castExpressionFunction · 0.90

Tested by

no test coverage detected