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

Method cpp_defined_name

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

cppDefinedName (languages/c-cpp.ts): a definition's name node as named, a `template_function`'s without its template arguments (`ReadPrimitive ` is `ReadPrimitive`).

(&self, name: Node)

Source from the content-addressed store, hash-verified

800 /// named, a `template_function`'s without its template arguments
801 /// (`ReadPrimitive<int32_t, WireFormatLite::TYPE_INT32>` is `ReadPrimitive`).
802 fn cpp_defined_name(&self, name: Node) -> String {
803 let own = if name.kind() == "template_function" { name.child_by_field_name("name") } else { None };
804 self.text(own.unwrap_or(name)).trim().to_string()
805 }
806
807 /// cppSpecializedFunctionName (languages/c-cpp.ts): the name of a
808 /// function an explicit specialization defines, without its template

Calls 1

textMethod · 0.65

Tested by

no test coverage detected