mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-03 20:23:59 +00:00
433da1fc04
They pass fine.
15 lines
289 B
Rust
15 lines
289 B
Rust
extern crate dep_with_staticlib;
|
|
|
|
fn main() {
|
|
unsafe {
|
|
let v = dep_with_staticlib::my_function();
|
|
if cfg!(foo) {
|
|
assert_eq!(v, 1);
|
|
} else if cfg!(bar) {
|
|
assert_eq!(v, 3);
|
|
} else {
|
|
panic!("unknown");
|
|
}
|
|
}
|
|
}
|