commit 063f7b1ecdf8698f0174bb922832521779b483c3
parent fdcf6982235c67cdd900c427dee633e461bfb829
Author: Drew DeVault <sir@cmpwn.com>
Date: Mon, 22 Feb 2021 09:54:52 -0500
18-match: update match syntax
Diffstat:
1 file changed, 4 insertions(+), 12 deletions(-)
diff --git a/tests/18-match.ha b/tests/18-match.ha
@@ -109,9 +109,7 @@ fn transitivity() void = {
let visit = false;
match (x) {
int => abort(),
- foo => {
- visit = true;
- },
+ foo => visit = true,
bar => abort(),
};
assert(visit);
@@ -121,9 +119,7 @@ fn transitivity() void = {
match (x) {
int => abort(),
foo => abort(),
- foobar => {
- visit = true;
- },
+ foobar => visit = true,
};
assert(visit);
@@ -140,9 +136,7 @@ fn transitivity() void = {
let y: foobarbaz = 10;
visit = false;
match (y) {
- baz => {
- visit = true;
- },
+ baz => visit = true,
foo => abort(),
bar => abort(),
};
@@ -152,9 +146,7 @@ fn transitivity() void = {
visit = false;
match (y) {
baz => abort(),
- foo => {
- visit = true;
- },
+ foo => visit = true,
bar => abort(),
};
assert(visit);