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

Function find_anonymous_class_body

codegraph-kernel/src/csharp.rs:1757–1766  ·  view source on GitHub ↗
(node: Node)

Source from the content-addressed store, hash-verified

1755}
1756
1757fn find_anonymous_class_body(node: Node) -> Option<Node> {
1758 for i in 0..node.named_child_count() {
1759 if let Some(child) = node.named_child(i) {
1760 if matches!(child.kind(), "class_body" | "declaration_list") {
1761 return Some(child);
1762 }
1763 }
1764 }
1765 None
1766}
1767
1768/// The `new ns.Foo<T>()` name normalization shared by instantiation /
1769/// anonymous-class extraction: strip `<...` from the first `<` (index > 0),

Callers 2

visit_nodeMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected