summaryrefslogtreecommitdiff
path: root/test/mono/assert.sail
diff options
context:
space:
mode:
Diffstat (limited to 'test/mono/assert.sail')
-rw-r--r--test/mono/assert.sail10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/mono/assert.sail b/test/mono/assert.sail
index 91826822..ea286e93 100644
--- a/test/mono/assert.sail
+++ b/test/mono/assert.sail
@@ -21,6 +21,15 @@ function f(n,m) = {
()
}
+val f' : forall 'n 'm. (atom('n), atom('m)) -> unit effect {escape}
+
+function f'(n,m) = {
+ assert(constraint(('n = 8 | 'n = 16) & 'm < 'n), "nconstraint");
+ let 'p = 2 * n in
+ let x : bits('p) = replicate_bits(0b0,'p) in
+ ()
+}
+
val g : forall 'n 'm. (atom('n), atom('m)) -> unit effect {escape}
function g(n,m) = {
@@ -42,6 +51,7 @@ val run : unit -> unit effect {escape}
function run () = {
f(8,3);
+ f'(8,3);
g(16,3);
h(8,3);
} \ No newline at end of file