summaryrefslogtreecommitdiff
path: root/tests/rpcSource.ur
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adam@chlipala.net>2011-12-03 10:00:10 -0500
committerGravatar Adam Chlipala <adam@chlipala.net>2011-12-03 10:00:10 -0500
commit8e7573e9187d583bcc478676ad92dd94a9ba8387 (patch)
tree999270929063a6966b6a45583e091ce015e612b3 /tests/rpcSource.ur
parent0f14aa67e5446391904c6a4d2ee7b4f00b803158 (diff)
Allow sources to be returned by RPCs
Diffstat (limited to 'tests/rpcSource.ur')
-rw-r--r--tests/rpcSource.ur13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/rpcSource.ur b/tests/rpcSource.ur
new file mode 100644
index 00000000..ad144cd6
--- /dev/null
+++ b/tests/rpcSource.ur
@@ -0,0 +1,13 @@
+fun remote () =
+ s <- source <xml/>;
+ return (s, <xml><dyn signal={signal s}/></xml>)
+
+fun main () : transaction page =
+ x <- source <xml/>;
+ return <xml><body>
+ <dyn signal={signal x}/>
+ <hr/>
+ <button onclick={p <- rpc (remote ());
+ set x p.2;
+ set p.1 <xml>Hi!</xml>}/>
+ </body></xml>