rust/src/test/compile-fail/issue-2150.rs

8 lines
210 B
Rust
Raw Normal View History

fn fail_len(v: ~[const int]) -> uint {
let mut i = fail;
2012-06-30 18:19:07 -05:00
for v.each |x| { i += 1u; }
//~^ WARNING unreachable statement
//~^^ ERROR the type of this value must be known
ret i;
}
fn main() {}