File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed
src/main/clojure/clojure/core Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -165,16 +165,16 @@ IOC and vthread code.
165
165
(timers/timeout msecs))
166
166
167
167
(defn- defparkingop-helper [op doc arglist body]
168
- (let [as (mapv #(list 'quote %) arglist)]
169
- ( list `def ( with-meta op { :arglists `(list ~as) :doc doc})
170
- ( if dispatch/vthreads-available-and-allowed?
171
- ( let [blockingop ( -> op name ( str " ! " ) symbol)]
172
- ` (fn [~'& ~'args] ~(list* apply blockingop '[args]) ))
173
- ` (fn ~arglist ~@body)))))
168
+ (let [as (mapv #(list 'quote %) arglist)
169
+ blockingop ( -> op name ( str " ! " ) symbol)]
170
+ `( def ~( with-meta op { :arglists `(list ~as) :doc doc})
171
+ ( if dispatch/vthreads-available-and-allowed?
172
+ (fn [~'& ~'args] ~(list* apply blockingop '[args]))
173
+ (fn ~arglist ~@body)))))
174
174
175
175
(defmacro defparkingop
176
- " Emits either parking op or reimplement as blocking op when vthreads
177
- available."
176
+ " Emits a Var definition that initializes as a parking op or as a
177
+ blocking op when vthreads available and allowed ."
178
178
[op doc arglist & body]
179
179
(defparkingop-helper op doc arglist body ))
180
180
You can’t perform that action at this time.
0 commit comments