Skip to content

Commit 84f5f61

Browse files
author
dnolen
committed
clarify the need for pluggability of :wrap by custom REPL evaluation environments
1 parent de15ba8 commit 84f5f61

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/clj/cljs/repl.clj

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -489,6 +489,8 @@
489489
(assoc env :ns (ana/get-namespace ana/*cljs-ns*))
490490
"<cljs repl>"
491491
form
492+
;; the pluggability of :wrap is needed for older JS runtimes like Rhino
493+
;; where catching the error will swallow the original trace
492494
((or (:wrap opts) wrap-fn) form)
493495
opts)))
494496

@@ -599,7 +601,7 @@
599601
'load-file load-file-fn
600602
'clojure.core/load-file load-file-fn
601603
'load-namespace
602-
(fn self
604+
(fn selfe
603605
([repl-env env form]
604606
(self env repl-env form nil))
605607
([repl-env env [_ ns :as form] opts]

0 commit comments

Comments
 (0)