Skip to content

Commit bd5ea7b

Browse files
committed
Fixes docs
1 parent 9d23a70 commit bd5ea7b

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/jtk_dvlp/async.cljc

+6-6
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333

3434
#?(:clj
3535
(defmacro go
36-
"Like `core.async/go` but carries thrown error / exception as result."
36+
"Like `core.async/go` but carries thrown exception (will convert to `ExceptionInfo`) as result."
3737
[& body]
3838
(if (:ns &env)
3939
`(cljs.core.async/go
@@ -53,15 +53,15 @@
5353

5454
#?(:clj
5555
(defmacro go-loop
56-
"Like `core.async/go-loop` but carries thrown error / exception as result."
56+
"Like `core.async/go-loop` but carries thrown exception (will convert to `ExceptionInfo`) as result."
5757
[bindings & body]
5858
`(jtk-dvlp.async/go
5959
(loop ~bindings
6060
~@body))))
6161

6262
#?(:clj
6363
(defmacro <!
64-
"Like `core.async/<!` but tests taken val of error / exception, if so throws it."
64+
"Like `core.async/<!` but tests taken val of exception (`ExceptionInfo`), if so throws it."
6565
[?exp]
6666
(if (:ns &env)
6767
`(let [v# (cljs.core.async/<! ~?exp)]
@@ -83,7 +83,7 @@
8383
v#))))
8484

8585
(defn map
86-
"Like `core.async/map` but carries thrown error / exception as result."
86+
"Like `core.async/map` but carries thrown exception (will convert to `ExceptionInfo`) as result."
8787
[f chs]
8888
(async/map
8989
(fn [& args]
@@ -98,7 +98,7 @@
9898
chs))
9999

100100
(defn reduce
101-
"Like `core.async/reduce` but carries thrown error / exception as result."
101+
"Like `core.async/reduce` but carries thrown exception (will convert to `ExceptionInfo`) as result."
102102
[f init ch]
103103
(async/reduce
104104
(fn [accu v]
@@ -113,6 +113,6 @@
113113
init ch))
114114

115115
(defn into
116-
"Like `core.async/into` but carries thrown error / exception as result."
116+
"Like `core.async/into` but carries thrown exception (will convert to `ExceptionInfo`) as result."
117117
[coll ch]
118118
(reduce conj coll ch))

src/jtk_dvlp/async/interop/promise.cljc

+2-2
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656

5757
(defn c->p
5858
"Creates a promise and resolves it with the val of channel `c`
59-
taken by `<!` or rejects it on error / exception. Closes the channel after took val."
59+
taken by `<!` or rejects it on exception (`ExceptionInfo`). Closes the channel after took val."
6060
[c]
6161
(create-promise
6262
(fn [resolve reject]
@@ -73,7 +73,7 @@
7373
Given function `f` can be used to fill the promise.
7474
`f` will be called with one arg functions `resolve` and `reject`
7575
to resolve or reject the created promise. Rejection value will
76-
will be used as `ex-info` `cause`."
76+
be wrapped in `ExceptionInfo` as `cause`."
7777
([]
7878
(async/promise-chan))
7979

0 commit comments

Comments
 (0)