File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 217
217
table
218
218
(assoc table val (gen-constant-id val))))))
219
219
env (update-in [::namespaces (-> env :ns :name ) ::constants ]
220
- (fnil conj #{}) val))))))
220
+ (fn [{:keys [seen order] :or {seen #{} order []} :as constants}]
221
+ (cond-> constants
222
+ (not (contains? seen val))
223
+ (assoc
224
+ :seen (conj seen val)
225
+ :order (conj order val))))))))))
221
226
222
227
(def default-namespaces '{cljs.core {:name cljs.core}
223
228
cljs.user {:name cljs.user}})
@@ -2005,7 +2010,7 @@ argument, which the reader will use in any emitted errors."
2005
2010
(swap! env/*compiler*
2006
2011
(fn [cenv]
2007
2012
(let [cached-ns (edn/read-string (slurp cache))]
2008
- (doseq [x (::constants cached-ns)]
2013
+ (doseq [x (get-in cached-ns [ ::constants :order ] )]
2009
2014
(register-constant! x))
2010
2015
(-> cenv
2011
2016
(assoc-in [::analyzed-cljs path] true )
You can’t perform that action at this time.
0 commit comments