Forest[] holder = r.holder;
Forest old = holder[pos];
- for(Forest result : results())
+ HashSet<Forest> rr = new HashSet<Forest>();
+ for(Forest result : results()) rr.add(result);
+ for(Forest result : rr)
for(Node child : ((Forest.Ref<?>)result).parents) {
if (only != null && child!=only) continue;
holder[pos] = result;