Closed
Description
We've had questions about when Rand will reach 1.0. We're not there yet, but it is still worth discussing the dependency on getrandom
.
From memory & quick skim the only part of the API which is affected by getrandom
is rand_core::Error
, and only in two ways:
- The declared constants must match those in
getrandom::Error
. This doesn't really requiregetrandom
to be 1.0 so long as there is a stability promise affecting these. impl From<getrandom::Error> for Error
, which thus pinsrand_core
to a singlegetrandom
major-minor version.
Potential solutions:
- Stabilise
getrandom
1.0 soon? Seems unlikely? - A separate crate just for
Error
— perhaps viable but definitely not desirable - Use the promise above and deprecate that
impl
, forcing users to rely ongetrandom::Error::code() -> NonZeroU32
andimpl From<NonZeroU32> for Error
CC @vks @newpavlov
Metadata
Metadata
Assignees
Labels
No labels