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

Method visit

codegraph-kernel/src/rlang.rs:301–314  ·  view source on GitHub ↗
(&mut self, node: Node<'t>)

Source from the content-addressed store, hash-verified

299 // else plain recursion over namedChildren in order.
300
301 fn visit(&mut self, node: Node<'t>) {
302 stack_guard!();
303 if self.hook(node) {
304 return;
305 }
306 if node.kind() == "call" {
307 self.extract_call(node);
308 }
309 let mut cursor = node.walk();
310 let children: Vec<Node<'t>> = node.named_children(&mut cursor).collect();
311 for child in children {
312 self.visit(child);
313 }
314 }
315
316 /// The visitNode hook (r.ts:180-309). Returns true when consumed.
317 fn hook(&mut self, node: Node<'t>) -> bool {

Callers 4

extractFunction · 0.45
hook_callMethod · 0.45
hook_binary_operatorMethod · 0.45
emit_method_argMethod · 0.45

Calls 4

walkMethod · 0.80
hookMethod · 0.45
extract_callMethod · 0.45
collectMethod · 0.45

Tested by

no test coverage detected