extractInheritance — the swift inheritance_specifier case: FIRST type_identifier of each specifier's user_type, everything as `extends` (conformances included; `: Module.Base` takes `Module`).
(&mut self, node: Node<'t>, class_row: u32)
| 1195 | /// type_identifier of each specifier's user_type, everything as `extends` |
| 1196 | /// (conformances included; `: Module.Base` takes `Module`). |
| 1197 | fn extract_inheritance(&mut self, node: Node<'t>, class_row: u32) { |
| 1198 | let extends_kind = edge_kind_index("extends").unwrap(); |
| 1199 | for child in node.named_children(&mut node.walk()) { |
| 1200 | if child.kind() != "inheritance_specifier" { |
| 1201 | continue; |
| 1202 | } |
| 1203 | let user_type = (0..child.named_child_count()) |
| 1204 | .filter_map(|j| child.named_child(j)) |
| 1205 | .find(|c| c.kind() == "user_type"); |
| 1206 | let Some(user_type) = user_type else { continue }; |
| 1207 | let type_id = (0..user_type.named_child_count()) |
| 1208 | .filter_map(|j| user_type.named_child(j)) |
| 1209 | .find(|c| c.kind() == "type_identifier"); |
| 1210 | let Some(type_id) = type_id else { continue }; |
| 1211 | let name = self.text(type_id).to_string(); |
| 1212 | self.push_ref_at(class_row, &name, extends_kind, type_id); |
| 1213 | } |
| 1214 | } |
| 1215 | |
| 1216 | /// extractTypeAnnotations — generic path: the 'parameter' field NEVER |
| 1217 | /// resolves (zero param refs), 'return_type' DOES; the direct |
no test coverage detected