summaryrefslogtreecommitdiff
path: root/forum/author.ur
diff options
context:
space:
mode:
Diffstat (limited to 'forum/author.ur')
-rw-r--r--forum/author.ur14
1 files changed, 14 insertions, 0 deletions
diff --git a/forum/author.ur b/forum/author.ur
index f58d4cf..5cbc136 100644
--- a/forum/author.ur
+++ b/forum/author.ur
@@ -57,8 +57,22 @@ val sql_username = sql_prim
fun name uOrA = uOrA
+val nameError = MyOption.getError
+
val orAnonymous = Some
+(* I can't express this in terms of whenIdentified'--I get a "substitution in
+constructor is blocked by a too-deep unification variable." *)
+fun whenIdentified [ctx] [use] uOrA text =
+ case uOrA of
+ None => <xml/>
+ | Some u => text
+
+fun whenIdentified' [ctx] [use] uOrA generator =
+ case uOrA of
+ None => <xml/>
+ | Some u => generator u
+
fun toOptionTag [_use] uOrA =
case uOrA of
None => <xml/>