File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change 1197
1197
(.refer-all which-ns new-ns)
1198
1198
1199
1199
(:refer opts)
1200
- (add-refers new-ns (:refer opts))
1200
+ (add-refers current-ns new-ns (:refer opts))
1201
1201
1202
1202
:else nil))))
1203
1203
1254
1254
(let [doc (when (string? (first opts))
1255
1255
(first opts))
1256
1256
opts (if doc (rest opts) opts)
1257
- opts (reduce (fn [m opt]
1258
- (let [opt-name (first opt)
1259
- options (rest opt)]
1260
- (when-not (keyword? opt-name)
1261
- (throw (ex-info "Namespace option must be a keyword"
1262
- {:option opt-name})))
1263
- (assoc m opt-name (vec options))))
1264
- {}
1265
- opts)
1257
+ opts (when (seq opts)
1258
+ (reduce (fn [m opt]
1259
+ (let [opt-name (first opt)
1260
+ options (rest opt)]
1261
+ (when-not (keyword? opt-name)
1262
+ (throw (ex-info "Namespace option must be a keyword"
1263
+ {:option opt-name})))
1264
+ (assoc m opt-name (vec options))))
1265
+ {}
1266
+ opts))
1266
1267
1267
1268
requires (when (:require opts)
1268
- `(require ~@(:require opts)))
1269
+ `(require ~@(map #(list 'quote %) ( :require opts) )))
1269
1270
imports (when (:import opts)
1270
1271
(map (fn [v]
1271
1272
`(import ~v))
You can’t perform that action at this time.
0 commit comments