find_references
Locate all occurrences of a specific identifier within a source file to survey where it appears before renaming or refactoring. Provides line numbers and source lines for quick reference analysis.
Instructions
Return all occurrences of an identifier named target in a source file, as
'line N: '. Read-only, syntactic only (no scope awareness), so
results may include unrelated identifiers that happen to share the same name.
Use this when: You're about to rename or refactor a symbol and need a quick survey of where it appears in the file. Don't use this when: You need cross-file or scope-aware analysis -> use a full language server.
Example: target="LRUCache"
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_path | Yes | ||
| target | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |