File tree Expand file tree Collapse file tree 1 file changed +12
-13
lines changed Expand file tree Collapse file tree 1 file changed +12
-13
lines changed Original file line number Diff line number Diff line change 647
647
[repl-env {:keys [init need-prompt prompt flush read eval print caught reader
648
648
print-no-newline source-map-inline wrap repl-requires
649
649
compiler-env]
650
- :or {init #()
651
- need-prompt #(if (readers/indexing-reader? *in*)
652
- (== (readers/get-column-number *in*) 1 )
653
- (identity true ))
650
+ :or {need-prompt #(if (readers/indexing-reader? *in*)
651
+ (== (readers/get-column-number *in*) 1 )
652
+ (identity true ))
654
653
prompt repl-prompt
655
654
flush flush
656
655
read repl-read
674
673
(merge-with (fn [a b] (if (nil? b) a b))
675
674
repl-opts
676
675
opts
677
- {:init init
678
- :prompt prompt
676
+ {:prompt prompt
679
677
:need-prompt need-prompt
680
678
:flush flush
681
679
:read read
711
709
(catch Throwable e
712
710
(caught e repl-env opts)
713
711
opts))))
712
+ init (or init
713
+ #(evaluate-form repl-env env " <cljs repl>"
714
+ (with-meta
715
+ `(~'ns ~'cljs.user
716
+ (:require ~@repl-requires))
717
+ {:line 1 :column 1 })
718
+ identity opts))
714
719
read-eval-print
715
720
(fn []
716
721
(let [input (binding [*ns* (create-ns ana/*cljs-ns*)
733
738
(fn []
734
739
(binding [*repl-opts* opts]
735
740
(try
736
- (init )
737
741
(when analyze-path
738
742
(analyze-source analyze-path opts))
739
- (evaluate-form repl-env env " <cljs repl>"
740
- (with-meta
741
- `(~'ns ~'cljs.user
742
- (:require ~@repl-requires))
743
- {:line 1 :column 1 })
744
- identity opts)
743
+ (init )
745
744
(catch Throwable e
746
745
(caught e repl-env opts)))
747
746
(when-let [src (:watch opts)]
You can’t perform that action at this time.
0 commit comments