You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// If there are multiple symbol graphs (for example for different source languages or platforms) then the nodes may have already been added to the hierarchy.
159
142
vartopLevelCandidates= nodes.filter{ _, node in node.parent ==nil}
160
143
forrelationshipin graph.relationships where relationship.kind.formsHierarchy {
@@ -283,7 +266,43 @@ struct PathHierarchy {
283
266
parent.add(symbolChild: node)
284
267
}
285
268
}
286
-
269
+
270
+
// Overload group don't exist in the individual symbol graphs.
271
+
// Since overload groups don't change the _structure_ of the path hierarchy, we can add them after after all symbols for all platforms have already been added.
272
+
forunifiedGraphin loader.unifiedGraphs.values {
273
+
// Create nodes for all the overload groups
274
+
letoverloadGroupNodes:[String:Node]= unifiedGraph.overloadGroupSymbols.reduce(into:[:]){ acc, uniqueID in
275
+
assert(allNodes[uniqueID]==nil,
276
+
"Overload group ID \(uniqueID) already has a symbol node in the hierarchy: \(allNodes[uniqueID]!.map(\.name).sorted().joined(separator:","))")
0 commit comments