diff tests/aborter2.ur @ 425:7009b0ac1501

Properly freeing libpq results on errors
author Adam Chlipala <adamc@hcoop.net>
date Fri, 24 Oct 2008 17:30:07 -0400
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/aborter2.ur	Fri Oct 24 17:30:07 2008 -0400
@@ -0,0 +1,7 @@
+table t : { X : int }
+
+fun main () : transaction page =
+    v <- query (SELECT * FROM t)
+         (fn r (_ : int) => return (error <xml>Shot down!</xml>))
+         0;
+    return <xml>Result: {[v]}</xml>