           (.seek (aget key-ix->intersection key-ix) key)
           (.maintain this)))
   (down [this]
-        (assert (< key-ix (- (alength key-ix->iterators) 1)))
+        (assert (false? end?)) ;; have to be at a key to descend
+        (assert (< key-ix (- (alength key-ix->intersection) 1)))
         (set! key-ix (+ key-ix 1))
         (let [iterator->present? (aget key-ix->iterator->present? key-ix)]
           (dotimes [i (alength iterator->present?)]

            (.up (aget iterators i))
            (.reset (aget iterators i))))
        (.maintain this))))

;; TESTS


            (set! end? true)
            (.search this 1)))))

;; TODO treeterator (key-ix->needed? , key-ix->produced?)

(defn intersection [iterators]
  (if (> (alength iterators) 1)
