mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-01 06:51:58 +00:00
12 lines
200 B
Rust
12 lines
200 B
Rust
// run-pass
|
|
#![feature(core_intrinsics)]
|
|
|
|
use std::intrinsics::*;
|
|
|
|
fn main() {
|
|
unsafe {
|
|
assert_eq!(nearbyintf32(5.234f32), 5f32);
|
|
assert_eq!(nearbyintf64(6.777f64), 7f64);
|
|
}
|
|
}
|