(node: any)
| 69 | parentClassName?: string, |
| 70 | ): FoundSymbol[] { |
| 71 | const matches: FoundSymbol[] = []; |
| 72 | |
| 73 | function getSymbolName(node: any): string | null { |
| 74 | // Try common field names |
| 75 | for (const field of ['name']) { |
| 76 | const f = node.childForFieldName(field); |
| 77 | if (f) return f.text; |
| 78 | } |
| 79 | // Fallback: look for first identifier child |
| 80 | for (let i = 0; i < node.childCount; i++) { |
| 81 | const c = node.child(i); |
| 82 | if (c && (c.type === 'identifier' || c.type === 'property_identifier' || c.type === 'type_identifier')) { |
| 83 | return c.text; |
| 84 | } |
| 85 | } |
| 86 | return null; |
| 87 | } |
| 88 |
no test coverage detected