aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/lux/abstract/enum.lux
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/lux/abstract/enum.lux')
-rw-r--r--stdlib/source/lux/abstract/enum.lux8
1 files changed, 4 insertions, 4 deletions
diff --git a/stdlib/source/lux/abstract/enum.lux b/stdlib/source/lux/abstract/enum.lux
index 5bbb7df38..27690b286 100644
--- a/stdlib/source/lux/abstract/enum.lux
+++ b/stdlib/source/lux/abstract/enum.lux
@@ -1,11 +1,11 @@
(.module:
[lux #*]
[//
- ["." order]])
+ ["." order (#+ Order)]])
(signature: #export (Enum e)
{#.doc "Enumerable types, with a notion of moving forward and backwards through a type's instances."}
- (: (order.Order e) &order)
+ (: (Order e) &order)
(: (-> e e) succ)
(: (-> e e) pred))
@@ -15,7 +15,7 @@
(#.Cons from (range' <= succ (succ from) to))
#.Nil))
-(def: #export (range (^open ".") from to)
+(def: #export (range (^open ",@.") from to)
{#.doc "An inclusive [from, to] range of values."}
(All [a] (-> (Enum a) a a (List a)))
- (range' <= succ from to))
+ (range' (order.<= ,@&order) ,@succ from to))