(nodes: Node[])
| 5633 | // but defines no ≥3-impl supertype, so the named spare keeps it full.) |
| 5634 | const superMany = new Map<string, boolean>(); |
| 5635 | const definesPolymorphicSupertype = (nodes: Node[]): boolean => { |
| 5636 | for (const n of nodes) { |
| 5637 | if (n.kind !== 'class' && n.kind !== 'interface' && n.kind !== 'struct' && n.kind !== 'union' |
| 5638 | && n.kind !== 'trait' && n.kind !== 'protocol' && n.kind !== 'type_alias') continue; |
| 5639 | let many = superMany.get(n.id); |
| 5640 | if (many === undefined) { |
| 5641 | many = cg.getIncomingEdges(n.id) |
| 5642 | .filter((x) => x.kind === 'implements' || x.kind === 'extends').length >= MIN_SIBLINGS; |
| 5643 | superMany.set(n.id, many); |
| 5644 | } |
| 5645 | if (many) return true; |
| 5646 | } |
| 5647 | return false; |
| 5648 | }; |
| 5649 | |
| 5650 | lines.push('**Source Code**'); |
| 5651 | lines.push(''); |
nothing calls this directly
no test coverage detected