2 ms·
It's idiomatic in Rust, even: let result = { let b = foo(a); let mut c = b.see(); while (c) { c.frob(); } baz(c)
by pshc 12y ago
It's idiomatic in Rust, even:
let result = {
let b = foo(a);
let mut c = b.see();
while (c) {
c.frob();
}
baz(c)
};
- masklinn 12y agoAlthough the style described above will also work just fine: let result; { let b = foo(a); let mut c = b.see(); while (c) { c.frob(); } result = baz(c); }