10 stable releases

1.5.0 Mar 15, 2022
1.4.0 Mar 15, 2022
1.2.0 Jan 31, 2022
1.1.2 Nov 25, 2021

#7 in #postfix

Download history 1/week @ 2024-01-15 4/week @ 2024-02-12 25/week @ 2024-02-19 20/week @ 2024-02-26 18/week @ 2024-03-04 20/week @ 2024-03-11 10/week @ 2024-03-18 10/week @ 2024-03-25 28/week @ 2024-04-01 88/week @ 2024-04-08 85/week @ 2024-04-15 29/week @ 2024-04-22

232 downloads per month
Used in 2 crates (via baker)

MIT license

6KB
101 lines

Somok - postfix Result/Option wrapping

Usage:

Add following to your cargo toml:

somok = "1.0"

Then use postfix wrapping as follows:

use somok::{ Somok, Either };

fn foo() -> Result<Option<Either<String, Vec<u8>>>> {
    String::from("Foobar").left().some().okay()
}

lib.rs:

Somok - postfix Result/Option wrapping

Usage:

Add following to your cargo toml:

somok = "1.0"

Then use postfix wrapping as follows:

use somok::Somok;

fn foo() -> Result<Option<String>> {
    String::from("Foobar").some().okay()
}

No runtime deps