https://github.com/berrysoft/trylog
Log if `Err` or `None`.
https://github.com/berrysoft/trylog
Last synced: 9 months ago
JSON representation
Log if `Err` or `None`.
- Host: GitHub
- URL: https://github.com/berrysoft/trylog
- Owner: Berrysoft
- License: mit
- Created: 2022-09-27T09:53:52.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2022-12-06T04:22:25.000Z (over 3 years ago)
- Last Synced: 2025-09-17T05:28:36.194Z (9 months ago)
- Language: Rust
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# trylog
This crate is inspired by [`tracing-unwrap`](https://crates.io/crates/tracing-unwrap),
and provides `inspect` and `unwrap_or_default` series of methods.
It also supports all types implemented `Try`.
## Log level
| method | level |
| ------------------------ | ----- |
| `inspect_or_log*` | info |
| `unwrap_or_default_log*` | warn |
| `unwrap_or_log*` | error |