public static void createTaxonomySpanningTree(TaxonomyGraph graph, TaxonomyNode node) {
    if (node.label != Stella.NULL_INTEGER) {
      return;
    }
    node.label = Stella.MARKER_LABEL;
    { TaxonomyNode maxparent = null;
      int maxparentvalue = Stella.NULL_INTEGER;

      { TaxonomyNode parent = null;
        Cons iter000 = node.parents;

        for (;!(iter000 == Stella.NIL); iter000 = iter000.rest) {
          parent = ((TaxonomyNode)(iter000.value));
          if ((maxparentvalue == Stella.NULL_INTEGER) ||
              (parent.totalAncestors > maxparentvalue)) {
            maxparent = parent;
            maxparentvalue = parent.totalAncestors;
          }
        }
      }
      { TaxonomyNode parent = null;
        Cons iter001 = node.parents;

        for (;!(iter001 == Stella.NIL); iter001 = iter001.rest) {
          parent = ((TaxonomyNode)(iter001.value));
          if (parent == maxparent) {
            parent.treeChildren = Cons.cons(node, parent.treeChildren);
          }
          else {
            graph.brokenLinks.push(Cons.cons(parent, Cons.cons(node, Stella.NIL)));
          }
        }
      }
      { TaxonomyNode child = null;
        Cons iter002 = node.children;

        for (;!(iter002 == Stella.NIL); iter002 = iter002.rest) {
          child = ((TaxonomyNode)(iter002.value));
          TaxonomyGraph.createTaxonomySpanningTree(graph, child);
        }
      }
    }
  }