Remove variable name 'res' from test suite
This commit is contained in:
parent
c772269f08
commit
781a265b88
19 changed files with 153 additions and 153 deletions
|
@ -5,14 +5,14 @@
|
|||
|
||||
// Tests for if as expressions returning structural types
|
||||
fn test_rec() {
|
||||
auto res = if (true) { rec(i=100) } else { rec(i=101) };
|
||||
assert (res == rec(i=100));
|
||||
auto rs = if (true) { rec(i=100) } else { rec(i=101) };
|
||||
assert (rs == rec(i=100));
|
||||
}
|
||||
|
||||
fn test_tag() {
|
||||
tag mood { happy; sad; }
|
||||
auto res = if (true) { happy } else { sad };
|
||||
assert (res == happy);
|
||||
auto rs = if (true) { happy } else { sad };
|
||||
assert (rs == happy);
|
||||
}
|
||||
|
||||
fn main() { test_rec(); test_tag(); }
|
Loading…
Add table
Add a link
Reference in a new issue