1
0
mirror of https://github.com/janet-lang/janet synced 2024-11-25 01:37:19 +00:00

Update error handling, kill a bikeshed argument

This commit is contained in:
Andrew Owen 2021-01-15 01:53:14 -07:00
parent 71f9e2b1d7
commit c4a95e9a1e

View File

@ -3283,9 +3283,9 @@
(var *debug* false) (var *debug* false)
(var *compile-only* false) (var *compile-only* false)
(when-let [jp (getenv-alias "JANET_PATH")] (setdyn :syspath jp)) (if-let [jp (getenv-alias "JANET_PATH")] (setdyn :syspath jp))
(when-let [jp (getenv-alias "JANET_HEADERPATH")] (setdyn :headerpath jp)) (if-let [jp (getenv-alias "JANET_HEADERPATH")] (setdyn :headerpath jp))
(when-let [jprofile (getenv-alias "JANET_PROFILE")] (setdyn :profilepath jprofile)) (if-let [jprofile (getenv-alias "JANET_PROFILE")] (setdyn :profilepath jprofile))
# Flag handlers # Flag handlers
(def handlers (def handlers
@ -3378,7 +3378,7 @@
(file/read stdin :line buf)) (file/read stdin :line buf))
(def env (make-env)) (def env (make-env))
(when-let [profile.janet (dyn :profilepath)] (when-let [profile.janet (dyn :profilepath)]
(def new-env (dofile profile.janet :exit *exit-on-error* :env env)) (def new-env (dofile profile.janet :exit true :env env))
(merge-module env new-env "" false)) (merge-module env new-env "" false))
(if *debug* (put env :debug true)) (if *debug* (put env :debug true))
(def getter (if *raw-stdin* getstdin getline)) (def getter (if *raw-stdin* getstdin getline))