rust/tests/pretty/for-comment.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

12 lines
196 B
Rust
Raw Permalink Normal View History

//@ compile-flags: --crate-type=lib
2013-07-05 13:56:54 +08:00
//@ pp-exact
fn f(v: &[isize]) -> isize {
2013-07-05 13:56:54 +08:00
let mut n = 0;
2015-02-01 01:20:46 +08:00
for e in v {
2013-07-05 13:56:54 +08:00
n = *e; // This comment once triggered pretty printer bug
}
2013-08-17 23:37:42 +08:00
n
2013-07-05 13:56:54 +08:00
}