[ SortOutList obj i k l; ! print "^^Sorting out list from ", (name) obj, "^ "; ! for (i=child(location):i~=0:i=sibling(i)) ! print (name) i, " --> "; ! new_line; .AP_SOL; for (i=obj:i~=0:i=sibling(i)) { k=i.list_together; if (k~=0) { ! print "Scanning ", (name) i, " with lt=", k, "^"; for (i=sibling(i):i~=0 && i.list_together==k:) i=sibling(i); if (i==0) rfalse; !print "First not in block is ", (name) i, ! " with lt=", i.list_together, "^"; for (l=sibling(i):l~=0:l=sibling(l)) if (l.list_together==k) { SortTogether(parent(obj), k); ! print "^^After ST:^ "; ! for (i=child(location):i~=0:i=sibling(i)) ! print (name) i, " --> "; ! new_line; obj = child(parent(obj)); jump AP_SOL; } } } ];