summaryrefslogtreecommitdiff
path: root/test/ocaml/pattern1
diff options
context:
space:
mode:
Diffstat (limited to 'test/ocaml/pattern1')
-rw-r--r--test/ocaml/pattern1/expect1
-rw-r--r--test/ocaml/pattern1/pattern.sail9
2 files changed, 10 insertions, 0 deletions
diff --git a/test/ocaml/pattern1/expect b/test/ocaml/pattern1/expect
new file mode 100644
index 00000000..2ae28399
--- /dev/null
+++ b/test/ocaml/pattern1/expect
@@ -0,0 +1 @@
+pass
diff --git a/test/ocaml/pattern1/pattern.sail b/test/ocaml/pattern1/pattern.sail
new file mode 100644
index 00000000..3c28d46e
--- /dev/null
+++ b/test/ocaml/pattern1/pattern.sail
@@ -0,0 +1,9 @@
+val main : unit -> unit
+
+function main () = {
+ vec = 0x4F;
+ match vec {
+ 0b01 @ x : bits(2) @ 0xF => if x == 0b00 then print("pass") else print("x is incorrect"),
+ _ => print("pattern fail")
+ }
+}