File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -609,6 +609,25 @@ class DemanglingForTypeRef
609
609
nominalNode->addChild (parentNode, Dem);
610
610
nominalNode->addChild (identifierNode, Dem);
611
611
612
+ // Peel off the "Type" node.
613
+ parentNode = parentNode->getFirstChild ();
614
+
615
+ auto nominalNode = unspecializedType->getFirstChild ();
616
+
617
+ if (nominalNode->getNumChildren () != 2 )
618
+ return genericNode;
619
+
620
+ // Save identifier for reinsertion later, we have to remove it
621
+ // so we can insert the parent node as the first child.
622
+ auto identifierNode = nominalNode->getLastChild ();
623
+
624
+ // Remove all children.
625
+ nominalNode->removeChildAt (1 );
626
+ nominalNode->removeChildAt (0 );
627
+
628
+ // Add the parent we just visited back in, followed by the identifier.
629
+ nominalNode->addChild (parentNode, Dem);
630
+ nominalNode->addChild (identifierNode, Dem);
612
631
return genericNode;
613
632
}
614
633
You can’t perform that action at this time.
0 commit comments