MCPcopy Create free account
hub / github.com/d1ll0n/stack-packer / parseEnum

Function parseEnum

src/parser/parser.ts:111–116  ·  view source on GitHub ↗
(scopeName: string, subNode: EnumDefinition)

Source from the content-addressed store, hash-verified

109// export function parseFunction()
110
111export function parseEnum(scopeName: string, subNode: EnumDefinition): EnumType {
112 const {type, name, members} = subNode;
113 const namePath = `${scopeName}.${name}`;
114 const fields = members.map(({ name }) => name);
115 return { name, type, namePath, fields };
116}
117
118type SubNodeType = StructDefinition | EnumDefinition | FunctionDefinition | CustomErrorDefinition | EventDefinition
119const SubNodeTypeStrings = [

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected