resolveBody (dart.ts:158-171).
(&self, node: Node<'t>)
| 664 | |
| 665 | /// resolveBody (dart.ts:158-171). |
| 666 | fn resolve_body(&self, node: Node<'t>) -> Option<Node<'t>> { |
| 667 | if matches!(node.kind(), "function_signature" | "method_signature") { |
| 668 | let next = node.next_named_sibling()?; |
| 669 | if next.kind() == "function_body" { |
| 670 | return Some(next); |
| 671 | } |
| 672 | return None; |
| 673 | } |
| 674 | if let Some(standard) = node.child_by_field_name("body") { |
| 675 | return Some(standard); |
| 676 | } |
| 677 | let mut cursor = node.walk(); |
| 678 | let found = node |
| 679 | .named_children(&mut cursor) |
| 680 | .find(|c| matches!(c.kind(), "class_body" | "extension_body")); |
| 681 | found |
| 682 | } |
| 683 | |
| 684 | /// extractName (tree-sitter.ts:90-192) — resolveName (ctor names) → |
| 685 | /// name field → the method_signature inner unwrap → identifier-ish |
no test coverage detected