 
   (_check-clean [this]
     (when (== dirtyness maybe-dirty)
-      (let [ar auto-run]
+      (let [ar auto-run
+            len (arr-len watching)]
         (set! auto-run nil)
-        (doseq [w watching :while (== dirtyness maybe-dirty)]
-          (when (and (instance? Reaction w)
-                     (false? (._check-clean w)))
-            (._try-run w this)))
+        (loop [i 0]
+          (when (< i len)
+            (let [w (aget watching i)]
+              (when (and (instance? Reaction w)
+                         (false? (._check-clean w)))
+                (._try-run w this)))
+            (when (== dirtyness maybe-dirty)
+              (recur (inc i)))))
         (set! auto-run ar))
       (when (== dirtyness maybe-dirty)
         (set! dirtyness clean)))


(declare ^:dynamic *ratom-context*)
(defonce cached-reactions {})

(defn ^boolean reactive? []
  (not (nil? *ratom-context*)))

(defonce ^boolean debug false)
(defonce ^boolean silent false)
(defonce generation 0)

(defonce -running (clojure.core/atom 0))

(defn running []
  (+ @-running

    (let [oldstate state
          res (capture-derefed f this)
          derefed (-captured this)]
      (when-not (arr-eq derefed watching)
        (._update-watching this derefed))
      (set! dirtyness clean)
      (when-not nocache?
