projects
/
sbp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
14e2fc1
)
intermediate checkpoint
author
adam
<adam@megacz.com>
Sun, 8 Jan 2006 01:14:33 +0000
(20:14 -0500)
committer
adam
<adam@megacz.com>
Sun, 8 Jan 2006 01:14:33 +0000
(20:14 -0500)
darcs-hash:
20060108011433
-5007d-
134a60b378e5912dd938349f73c4e6ec1a613a4d
.gz
src/edu/berkeley/sbp/Forest.java
patch
|
blob
|
history
diff --git
a/src/edu/berkeley/sbp/Forest.java
b/src/edu/berkeley/sbp/Forest.java
index
8ed6eb5
..
ef420a8
100644
(file)
--- a/
src/edu/berkeley/sbp/Forest.java
+++ b/
src/edu/berkeley/sbp/Forest.java
@@
-159,8
+159,9
@@
public abstract class Forest<T> {
public String toString() { return resolve().toString(); }
public Forest resolve() {
if (hp==null) return res;
public String toString() { return resolve().toString(); }
public Forest resolve() {
if (hp==null) return res;
- HashSet<Body> results = null;
FastSet<Body> nh = new FastSet<Body>();
FastSet<Body> nh = new FastSet<Body>();
+ /*
+ HashSet<Body> results = null;
for(Forest<?> p : hp)
for(Body<?> b : (IterableForest<?>)p) {
if (b.keep() && (b.creator==null || !b.creator.lame)) {
for(Forest<?> p : hp)
for(Body<?> b : (IterableForest<?>)p) {
if (b.keep() && (b.creator==null || !b.creator.lame)) {
@@
-183,7
+184,13
@@
public abstract class Forest<T> {
}
}
hp = null;
}
}
hp = null;
- res = new MultiForest(nh, valid);
+ */
+ for(Forest<?> p : hp)
+ for(Body<?> b : (IterableForest<?>)p)
+ if (b.creator==null || !b.creator.lame)
+ b.addTo(nh);
+ res = new MultiForest(nh, nh.size()>0);
+ hp = null;
return res;
}
}
return res;
}
}