summaryrefslogtreecommitdiff
path: root/src/tag.sml
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adamc@hcoop.net>2008-11-11 18:39:38 -0500
committerGravatar Adam Chlipala <adamc@hcoop.net>2008-11-11 18:39:38 -0500
commit1d3089850988710149c0fd8d4a72aa3339e6caca (patch)
tree4dfd76fccafb08fbb1f8a4dff3262515b7a0c590 /src/tag.sml
parent6fc6d97b44658bbd4fc279be5964cf6187772f3c (diff)
Handle nullary transaction pages; avoid marking up headers array when reading cookies
Diffstat (limited to 'src/tag.sml')
-rw-r--r--src/tag.sml9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/tag.sml b/src/tag.sml
index b19a0544..715da9ed 100644
--- a/src/tag.sml
+++ b/src/tag.sml
@@ -184,6 +184,8 @@ fun tag file =
val newDs = map
(fn (ek, f, cn) =>
let
+ val unit = (TRecord (CRecord ((KType, loc), []), loc), loc)
+
fun unravel (all as (t, _)) =
case t of
TFun (dom, ran) =>
@@ -197,15 +199,14 @@ fun tag file =
val (fnam, t, _, tag) = E.lookupENamed env f
val (args, result) = unravel t
- val unit = (TRecord (CRecord ((KType, loc), []), loc), loc)
-
val (abs, t) =
case args of
[] =>
let
- val body = (EWrite (ENamed f, loc), loc)
+ val app = (EApp ((ENamed f, loc), (ERecord [], loc)), loc)
+ val body = (EWrite app, loc)
in
- ((EAbs ("x", unit, unit, body), loc),
+ (body,
(TFun (unit, unit), loc))
end
| _ =>