Decision Workspace
scope-guard vs scopeguard vs scopeguard-lite
Side-by-side comparison of Rust crates
43
scope-guard
growingv1.2.0
Simple RAII scope guard
60
scopeguard
growingv1.2.0
A RAII scope guard that will run a given closure when it goes out of scope, even if the code between panics (assuming unwinding panic). Defines the macros `defer!`, `defer_on_unwind!`, `defer_on_success!` as shorthands for guards with one of the implemented strategies.
45
scopeguard-lite
growingv1.0.0
A lightweight way to defer execution of a block to the end of the scope, and to run code during an unwind.
Core Metrics
| scope-guard | scopeguard | scopeguard-lite | |
|---|---|---|---|
| Health Score | 43 | 60 | 45 |
| Total Downloads | 20.2K | 597.9M | 338 |
| 30d Downloads | 729 | 39.1M | 3 |
| Dependents | 0 | 7.0K | 0 |
| Releases | 3 | 11 | 1 |
| Last Updated | 1113d ago | 984d ago | 183d ago |
| Age | 5y | 10y 11m | 6m |
Health Breakdown
scope-guard
Maintenance
4
Quality
22
Community
5
Popularity
5
Documentation
7
scopeguard
Maintenance
4
Quality
20
Community
17
Popularity
8
Documentation
11
scopeguard-lite
Maintenance
5
Quality
19
Community
6
Popularity
3
Documentation
12
Technical Details
| scope-guard | scopeguard | scopeguard-lite | |
|---|---|---|---|
| Version | 1.2.0 | 1.2.0 | 1.0.0 |
| Stable (≥1.0) | ✓ Yes | ✓ Yes | ✓ Yes |
| License | BSL-1.0 | MIT OR Apache-2.0 | MIT OR Apache-2.0 |
| Dependencies | 0 | 0 | 0 |
| Crate Size | 3KB | 12KB | 8KB |
| Features | 1 | 2 | 0 |
| Yanked % | 0.0% | 9.1% | 0.0% |
| Edition | 2018 | — | 2021 |
| MSRV | — | — | 1.61 |
| Owners | 1 | 2 | 1 |
Links
Quick Verdict
- •scopeguard leads with a health score of 60/100, but none of the options score above 80.
- •scopeguard is depended on by 7.0K crates — strongest ecosystem trust.
- •⚠ scope-guard, scopeguard have not been updated in over a year.