rust/tests/compile-fail/intrinsics/exact_div2.rs
2020-06-26 20:36:08 +02:00

6 lines
188 B
Rust

#![feature(core_intrinsics)]
fn main() {
// divison with a remainder
unsafe { std::intrinsics::exact_div(2u16, 3); } //~ ERROR 2_u16 cannot be divided by 3_u16 without remainder
}