Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/stevebeeblebrox/or_panic

Extract ok values from Rust results or panic with the contained error.
https://github.com/stevebeeblebrox/or_panic

Last synced: 28 days ago
JSON representation

Extract ok values from Rust results or panic with the contained error.

Awesome Lists containing this project

README

        

# or_panic
Extract ok values from Rust results or panic with the contained error. This works with any error type that implements `Display`.
```rust
use or_panic::OrPanic as _;

println!("{:?}", Path::new("./foo.txt").canonicalize().or_panic());
```