2 stable releases

Uses new Rust 2021

2.0.0 Apr 23, 2022
1.0.0 Apr 21, 2022

#771 in Rust patterns

Unlicense OR CC0-1.0 OR MIT OR Apache-2.0

5KB

yeet!

Replace return Err(x) and return None with:

fn foo() -> Option<u32> {
    yeet!();
}

fn bar() -> Result<u32, u32> {
    yeet!(42);
}

fn baz(x: u32) -> Result<u32, u32> {
    if x % 2 == 1 {
        yeet!(x);
    }
    Ok(x)
}

That's pretty much it.


lib.rs:

Poor man's yeet keyword on stable.

No runtime deps