      {:*compiler*     state
       :*cljs-ns*      'cljs.user
       :*ns*           (create-ns ana/*cljs-ns*)
-      :*data-readers* tags/*cljs-data-readers*}
+      :*data-readers* tags/*cljs-data-readers*
+      :*load-fn*      (or (:load-fn opts) *load-fn*)
+      :*eval-fn*      (or (:eval-fn opts) *eval-fn*)}
      source name opts cb)))
 
 ;; -----------------------------------------------------------------------------

                       (comp/emit (ana/analyze ana-env form nil opts)))})))))

(defn eval
  ([state form cb]
   (eval state form nil cb))
  ([state form opts cb]

                               :source js-source}))))))))))

(defn eval-str
  "Evalute ClojureScript source given as a string. The parameters:

  state (atom)
    the compiler state

  source (string)
    the ClojureScript source

  name (symbol)
    optional, the name of the source

  opts (map)
    compilation options.

    :eval-fn    - eval function to invoke, see *eval-fn*
    :load-fn    - library resolution function, see *load-fn*
    :source-map - set to true to generate inline source map information

  cb (function)
    callback, will be invoked with result of evalution"
  ([state source cb]
   (eval-str state source nil cb))
  ([state source name cb]
