rust/tests/ui/cross-crate/cci_nested_exe.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

21 lines
575 B
Rust
Raw Normal View History

//@ run-pass
//@ aux-build:cci_nested_lib.rs
extern crate cci_nested_lib;
2012-09-05 19:32:05 +00:00
use cci_nested_lib::*;
pub fn main() {
let lst = new_int_alist();
2014-05-25 10:10:11 +00:00
alist_add(&lst, 22, "hi".to_string());
alist_add(&lst, 44, "ho".to_string());
assert_eq!(alist_get(&lst, 22), "hi".to_string());
assert_eq!(alist_get(&lst, 44), "ho".to_string());
let lst = new_int_alist_2();
2014-05-25 10:10:11 +00:00
alist_add(&lst, 22, "hi".to_string());
alist_add(&lst, 44, "ho".to_string());
assert_eq!(alist_get(&lst, 22), "hi".to_string());
assert_eq!(alist_get(&lst, 44), "ho".to_string());
}