why doesn't the compiler panic if I cast -22.0 to u32 but make it 0?

72 points chaosprint
fn main() {
    let a = -22.0;
    let b = a as u32;
    println!("b: {}", b); // result => "b: 0"
}