summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adamc@hcoop.net>2008-07-22 18:46:04 -0400
committerGravatar Adam Chlipala <adamc@hcoop.net>2008-07-22 18:46:04 -0400
commit6c5b16aa47eeb84d5f6ee9fc6cb265424e63f74c (patch)
tree51ff2855edcd09b36ce549bdb2bf91cd4d2c5caa /tests
parentcedc70524a84b860f438078c8abc6f1aa0557994 (diff)
Meta-programming forms
Diffstat (limited to 'tests')
-rw-r--r--tests/gform.lac13
1 files changed, 11 insertions, 2 deletions
diff --git a/tests/gform.lac b/tests/gform.lac
index 51df468c..4ce75e3e 100644
--- a/tests/gform.lac
+++ b/tests/gform.lac
@@ -19,12 +19,21 @@ functor F (M : S) : S' where con rs = M.rs = struct
</body></html>
val page = fn () => <html><body>
-
+ <lform>
+ {fold [fn rs :: {Unit} => xml lform [] (stringify rs)]
+ (fn nm :: Name => fn u :: Unit => fn rest :: {Unit} =>
+ fn frag : xml lform [] (stringify rest) =>
+ <lform><li>{frag} <textbox{nm}/></li></lform>)
+ <lform></lform>
+ [rs]}
+
+ <submit action={handler}/>
+ </lform>
</body></html>
end
structure M = F(struct
- con rs = []
+ con rs = [A, B, C]
end)
open M