Fun2<TreeLayoutNode, TreeLayoutNode, num> splitFun = (a, b) { return a.parent == b.parent ? 1 : 2; };