summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adamc@hcoop.net>2008-11-06 09:21:34 -0500
committerGravatar Adam Chlipala <adamc@hcoop.net>2008-11-06 09:21:34 -0500
commitd7bd7d38e8f785b7366495ce977379929e5eb913 (patch)
treeba523b94cf3cd06fdc212a16b0ae735ad2d11aa9 /lib
parenteaa8aa9f310d95a31747ea4c81ee1013c1734a7d (diff)
Monoizing FFI transactions correctly
Diffstat (limited to 'lib')
-rw-r--r--lib/basis.urs23
1 files changed, 16 insertions, 7 deletions
diff --git a/lib/basis.urs b/lib/basis.urs
index ca81c95f..806a9623 100644
--- a/lib/basis.urs
+++ b/lib/basis.urs
@@ -69,6 +69,22 @@ val read_bool : read bool
val read_time : read time
+(** * Transactions *)
+
+con transaction :: Type -> Type
+
+val return : t ::: Type
+ -> t -> transaction t
+val bind : t1 ::: Type -> t2 ::: Type
+ -> transaction t1 -> (t1 -> transaction t2)
+ -> transaction t2
+
+
+(** HTTP operations *)
+
+val requestHeader : string -> transaction (option string)
+
+
(** SQL *)
con sql_table :: {Type} -> Type
@@ -233,13 +249,6 @@ val sql_current_timestamp : sql_nfunc time
(*** Executing queries *)
-con transaction :: Type -> Type
-val return : t ::: Type
- -> t -> transaction t
-val bind : t1 ::: Type -> t2 ::: Type
- -> transaction t1 -> (t1 -> transaction t2)
- -> transaction t2
-
val query : tables ::: {{Type}} -> exps ::: {Type}
-> fn [tables ~ exps] =>
state ::: Type