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

Method brace_body_end

codegraph-kernel/src/ccpp/mod.rs:1125–1128  ·  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

1123 /// cppBodyEnd: where a class-like node ends in brace scopes — the `}`
1124 /// that closes its body — or None to keep the tree's.
1125 fn brace_body_end(&self, body: Node<'t>) -> Option<(u32, u32)> {
1126 let close = self.brace_scopes.as_ref()?.close_of(body.start_byte())?;
1127 Some(BraceScopes::position_of(self.src, &self.line_starts, close + 1))
1128 }
1129
1130 /// openCppClassScope: a class-like node's body as a scope for visit_in_brace_scope.
1131 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