copyright notices/updates
[sbp.git] / src / edu / berkeley / sbp / Forest.java
index ee3bfbc..bdaedca 100644 (file)
@@ -1,3 +1,5 @@
+// Copyright 2006 all rights reserved; see LICENSE file for BSD-style license
+
 package edu.berkeley.sbp;
 import edu.berkeley.sbp.*;
 import edu.berkeley.sbp.Sequence.Position;
@@ -21,6 +23,7 @@ public abstract class Forest<NodeType> implements GraphViz.ToGraphViz {
     public void expand(HashSet<Tree<NodeType>> ht) { expand(ht, new HashSet<Forest<NodeType>>(), null); }
 
     static <NodeType> Forest<NodeType> create(Input.Region loc, NodeType head, Forest<NodeType>[] children, boolean lift) {
+        if (loc == null) throw new Error();
         return new One<NodeType>(loc, head, children, lift);
     }