cpp_find_references
Find all usages of a C++ function, class, or variable in the indexed codebase. Provide the identifier and type to retrieve matching file, line, and snippet references.
Instructions
Find all usages of a C++ identifier across the indexed codebase.
Performs a pattern-aware search:
type='function' matches 'Identifier(' calls
type='class' matches word-boundary class references
type='variable' matches word-boundary variable references
Call cpp_set_codebase_path() first.
Args: identifier: Name to search for (e.g. 'HandleCommand', 'UUnrealMCPBridge'). type: 'class' | 'function' | 'variable'. Default 'function'. limit: Max hits to return. Default 100.
Returns: JSON StructuredResult with outputs: identifier, hits [{file, line, snippet}], total, truncated
KB: see knowledge_base/12_MCP_TOOL_USAGE_GUIDE.md#overview Example: cpp_find_references(identifier="Example")
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | No | function | |
| limit | No | ||
| identifier | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |