aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/lux/concurrency/task.lux
diff options
context:
space:
mode:
authorEduardo Julian2018-02-07 00:37:35 -0400
committerEduardo Julian2018-02-07 00:37:35 -0400
commit844a44f87bd03fc9c65e18149c6dd2ccf8e9cb32 (patch)
treed94e855ddf39c710f2cecf52f6e43851fdfb25d5 /stdlib/source/lux/concurrency/task.lux
parent17d5280a5e05c70cdb0b2cf44606c186b000c7c1 (diff)
- Improved the way exceptions work.
Diffstat (limited to '')
-rw-r--r--stdlib/source/lux/concurrency/task.lux5
1 files changed, 3 insertions, 2 deletions
diff --git a/stdlib/source/lux/concurrency/task.lux b/stdlib/source/lux/concurrency/task.lux
index a740d7398..603dfc808 100644
--- a/stdlib/source/lux/concurrency/task.lux
+++ b/stdlib/source/lux/concurrency/task.lux
@@ -18,8 +18,9 @@
(:: P.Applicative<Promise> wrap (#E.Error error)))
(def: #export (throw exception message)
- (All [a] (-> Exception Text (Task a)))
- (fail (exception message)))
+ (All [e a] (-> (Exception e) e (Task a)))
+ (:: P.Applicative<Promise> wrap
+ (ex.throw exception message)))
(def: #export (return value)
(All [a] (-> a (Task a)))