Skip to content

Commit

Permalink
Add another test for issue #31856
Browse files Browse the repository at this point in the history
  • Loading branch information
jseyfried committed Apr 15, 2016
1 parent 974f1ef commit ca1d29c
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/test/compile-fail/issue-32922.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,18 @@ macro_rules! bar { // test issue #31856
)
}

macro_rules! baz {
($i:ident) => {
let mut $i = 2;
$i = $i + 1;
}
}

#[rustc_error]
fn main() { //~ ERROR compilation successful
foo! {};
bar! {};

let mut a = true;
baz!(a);
}

0 comments on commit ca1d29c

Please sign in to comment.