mirror of
https://github.com/DeusData/codebase-memory-mcp.git
synced 2026-11-04 08:13:37 +08:00
MCP server that indexes codebases into a queryable knowledge graph. Single Go binary, SQLite storage, 12 languages via tree-sitter. Features: call graph, cross-service HTTP linking, dead code detection, route nodes, Cypher queries, incremental reindex, JSON config scanning.
41 lines
1.1 KiB
Go
41 lines
1.1 KiB
Go
package lang
|
|
|
|
func init() {
|
|
Register(&LanguageSpec{
|
|
Language: CPP,
|
|
FileExtensions: []string{".cpp", ".h", ".hpp", ".cc", ".cxx", ".hxx", ".hh", ".ixx", ".cppm", ".ccm"},
|
|
FunctionNodeTypes: []string{
|
|
"function_definition",
|
|
"declaration",
|
|
"field_declaration",
|
|
"template_declaration",
|
|
"lambda_expression",
|
|
},
|
|
ClassNodeTypes: []string{
|
|
"class_specifier",
|
|
"struct_specifier",
|
|
"union_specifier",
|
|
"enum_specifier",
|
|
},
|
|
ModuleNodeTypes: []string{
|
|
"translation_unit",
|
|
"namespace_definition",
|
|
"linkage_specification",
|
|
"declaration",
|
|
},
|
|
CallNodeTypes: []string{
|
|
"call_expression",
|
|
"field_expression",
|
|
"subscript_expression",
|
|
"new_expression",
|
|
"delete_expression",
|
|
"binary_expression",
|
|
"unary_expression",
|
|
"update_expression",
|
|
},
|
|
ImportNodeTypes: []string{"preproc_include", "template_function", "declaration"},
|
|
ImportFromTypes: []string{"preproc_include", "template_function", "declaration"},
|
|
PackageIndicators: []string{"CMakeLists.txt", "Makefile", "*.vcxproj", "conanfile.txt"},
|
|
})
|
|
}
|