unwrap_helpers

Unwrap Macros to help Clean up code and improve production. This does include a pub use of https://github.com/Mrp1Dev/loop_unwrap to gain access to unwrap loop macros.

https://crates.io/crates/unwrap_helpers Docs

Works like .unwrap, if it's an Err() or None it calls return. Will return No data or Data, Also will run a Closure if one inserted.loopunwrap

Examples

{ let input = Option::None; let parsed_input = unwrap_or_return!(input); } { let input = Option::None; let parsed_input = unwrap_or_return!(input, 1); } { let input = Option::None; let mut x = 5; let parsed_input = unwrap_or_return!(input, || x + 1); }