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

Method brace_body_end

codegraph-kernel/src/ccpp/mod.rs:1135–1138  ·  view source on GitHub ↗

cppBodyEnd: where a class-like node ends in brace scopes — the `}` that closes its body — or None to keep the tree's.

(&self, body: Node<'t>)

Source from the content-addressed store, hash-verified

1133 /// cppBodyEnd: where a class-like node ends in brace scopes — the `}`
1134 /// that closes its body — or None to keep the tree's.
1135 fn brace_body_end(&self, body: Node<'t>) -> Option<(u32, u32)> {
1136 let close = self.brace_scopes.as_ref()?.close_of(body.start_byte())?;
1137 Some(BraceScopes::position_of(self.src, &self.line_starts, close + 1))
1138 }
1139
1140 /// openCppClassScope: a class-like node's body as a scope for visit_in_brace_scope.
1141 fn open_class_scope(&mut self, scope: &Scope, body: Node<'t>) {

Callers 2

extract_classMethod · 0.80
extract_aggregateMethod · 0.80

Calls 1

close_ofMethod · 0.80

Tested by

no test coverage detected