rust/src/test/run-pass/issue-980.rs

14 lines
191 B
Rust
Raw Normal View History

enum maybe_pointy {
2011-09-27 01:24:53 -05:00
no_pointy;
yes_pointy(@pointy);
}
type pointy = {
mutable x : maybe_pointy
};
fn main() {
let m = @{ mutable x : no_pointy };
m.x = yes_pointy(m);
}