aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/lux/concurrency/promise.lux
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/lux/concurrency/promise.lux')
-rw-r--r--stdlib/source/lux/concurrency/promise.lux16
1 files changed, 4 insertions, 12 deletions
diff --git a/stdlib/source/lux/concurrency/promise.lux b/stdlib/source/lux/concurrency/promise.lux
index f2a7ffc05..4492f955e 100644
--- a/stdlib/source/lux/concurrency/promise.lux
+++ b/stdlib/source/lux/concurrency/promise.lux
@@ -31,19 +31,11 @@
(atom {#value ?value
#observers (list)}))
-(syntax: #export (promise [?type (p;opt s;any)])
+(syntax: #export (promise [type s;any])
{#;doc (doc "Makes an uninitialized Promise (in this example, of Unit)."
- (promise Unit)
-
- "The type is optional."
- (promise))}
- (case ?type
- (#;Some type)
- (wrap (list (` (: (Promise (~ type))
- (promise' #;None)))))
-
- #;None
- (wrap (list (` (promise' #;None))))))
+ (promise Unit))}
+ (wrap (list (` (: (Promise (~ type))
+ (promise' #;None))))))
(def: #export (poll promise)
{#;doc "Polls a Promise's value."}