rust/src/test/run-pass/class-methods-cross-crate.rs

14 lines
290 B
Rust
Raw Normal View History

// xfail-fast
// aux-build:cci_class_3.rs
extern mod cci_class_3;
2012-09-05 14:32:05 -05:00
use cci_class_3::kitties::*;
fn main() {
let nyan : cat = cat(52u, 99);
let kitty = cat(1000u, 2);
assert(nyan.how_hungry == 99);
assert(kitty.how_hungry == 2);
nyan.speak();
assert(nyan.meow_count() == 53u);
}