aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/lux/world/db/jdbc/input.lux
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/lux/world/db/jdbc/input.lux')
-rw-r--r--stdlib/source/lux/world/db/jdbc/input.lux16
1 files changed, 8 insertions, 8 deletions
diff --git a/stdlib/source/lux/world/db/jdbc/input.lux b/stdlib/source/lux/world/db/jdbc/input.lux
index b160c5a5c..30634a3df 100644
--- a/stdlib/source/lux/world/db/jdbc/input.lux
+++ b/stdlib/source/lux/world/db/jdbc/input.lux
@@ -2,9 +2,9 @@
[lux (#- and int)
[control
[functor (#+ Contravariant)]
- [monad (#+ Monad do)]]
+ [monad (#+ Monad do)]
+ ["." try (#+ Try)]]
[data
- ["." error (#+ Error)]
[collection
["." list ("#;." fold)]]]
[time
@@ -47,7 +47,7 @@
(type: #export (Input a)
(-> a [Nat java/sql/PreparedStatement]
- (Error [Nat java/sql/PreparedStatement])))
+ (Try [Nat java/sql/PreparedStatement])))
(structure: #export contravariant (Contravariant Input)
(def: (map-1 f fb)
@@ -57,25 +57,25 @@
(def: #export (and pre post)
(All [l r] (-> (Input l) (Input r) (Input [l r])))
(function (_ [left right] context)
- (do error.monad
+ (do try.monad
[context (pre left context)]
(post right context))))
(def: #export (fail error)
(All [a] (-> Text (Input a)))
(function (_ value [idx context])
- (#error.Failure error)))
+ (#try.Failure error)))
(def: #export empty
(Input Any)
(function (_ value context)
- (#error.Success context)))
+ (#try.Success context)))
(template [<function> <type> <setter>]
[(def: #export <function>
(Input <type>)
(function (_ value [idx statement])
- (do error.monad
+ (do try.monad
[_ (<setter> (.int idx) value statement)]
(wrap [(.inc idx) statement]))))]
@@ -97,7 +97,7 @@
[(def: #export <function>
(Input Instant)
(function (_ value [idx statement])
- (do error.monad
+ (do try.monad
[_ (<setter> (.int idx)
(<constructor> (instant.to-millis value))
statement)]