Closed alexheretic closed 5 years ago
Replacing lazystatic in my codebases I've found I'm doing `Lazy::new(<>::default)` a fair bit generally for Mutex use.
This pr streamlines that to Lazy::default(), in a similar way to Arc, Mutex wrappers. Although it won't work in static contexts, which sucks.
Lazy::default()
Arc
Mutex
Makes sense to add, yeah!
bors r+
published as 1.1.0
Replacing lazystatic in my codebases I've found I'm doing `Lazy::new(<>::default)` a fair bit generally for Mutex use.
This pr streamlines that to
Lazy::default()
, in a similar way toArc
,Mutex
wrappers. Although it won't work in static contexts, which sucks.