rust/src/test/auxiliary/cci_iter_lib.rs

10 lines
142 B
Rust
Raw Normal View History

#[inline]
fn iter<T>(v: [T], f: fn(T)) {
let i = 0u;
let n = vec::len(v);
while i < n {
f(v[i]);
i += 1u;
}
}