   `(let [val# (a/<! ~chan)]
      (cond
        (= val# ::nil) nil
-       (-> val# meta ::exception) (throw (first val#))
+       (instance? ChannelException val#) (throw (:z val#))
        (nil? val#) ::complete
        :else val#)))
 


;; core.async wrappers

(defn channel? [ch]
  (instance? Channel ch))


  `(let [val# (a/<!! ~chan)]
     (cond
       (= val# ::nil) nil
       (instance? ChannelException val#) (throw (:z val#))
       (nil? val#) ::complete
       :else val#)))

