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

Method visit_enum_entry_body

codegraph-kernel/src/kotlin.rs:1163–1173  ·  view source on GitHub ↗

`NewBuffer { override fun pipe() … }`: an entry's own class_body declares members of its own, scoped under the entry.

(&mut self, node: Node<'t>, member: Option<(u32, String)>)

Source from the content-addressed store, hash-verified

1161 /// `NewBuffer { override fun pipe() … }`: an entry's own class_body
1162 /// declares members of its own, scoped under the entry.
1163 fn visit_enum_entry_body(&mut self, node: Node<'t>, member: Option<(u32, String)>) {
1164 let Some((row, name)) = member else { return };
1165 let Some(body) = (0..node.named_child_count()).filter_map(|i| node.named_child(i)).find(|c| c.kind() == "class_body") else { return };
1166 self.stack.push(Scope { row, kind: "enum_member", name });
1167 for i in 0..body.named_child_count() {
1168 if let Some(c) = body.named_child(i) {
1169 self.visit_node(c);
1170 }
1171 }
1172 self.stack.pop();
1173 }
1174
1175 /// extractTypeAlias — plain node; the alias-value ref walk reads the
1176 /// `value` FIELD → null (zero fields) → NO refs. Returns false →

Callers 1

extract_enumMethod · 0.80

Calls 2

pushMethod · 0.80
visit_nodeMethod · 0.45

Tested by

no test coverage detected