pub fn generate_vartime(mut rng: impl RngCore) -> Self {
        let mut bytes = FieldBytes::default();

        // TODO: pre-generate several scalars to bring the probability of non-constant-timeness down?
        loop {
            rng.fill_bytes(&mut bytes);
            if let Some(scalar) = Scalar::from_repr(bytes) {
                return scalar;
            }
        }
    }
/// Returns a uniformly-random scalar, generated using rejection sampling.
// TODO(tarcieri): make this a `CryptoRng` when `ff` allows it
Returns a uniformly-random scalar, generated using rejection sampling.
TODO(tarcieri): make this a `CryptoRng` when `ff` allows it
Returns a uniformly - random scalar generated using rejection sampling . TODO ( tarcieri ) : make this a ` CryptoRng ` when ` ff ` allows it
pub fn generate_vartime(mut rng: impl RngCore) -> Self {
        let mut bytes = FieldBytes::default();
        // TODO: pre-generate several scalars to bring the probability of non-constant-timeness down?
        loop {
            rng.fill_bytes(&mut bytes);
            if let Some(scalar) = Scalar::from_repr(bytes) {
                return scalar;
            }
        }
    }
pub fn generate_vartime ( mut rng : impl RngCore ) -> Self { let mut bytes = FieldBytes :: default ( ) ; // TODO: pre-generate several scalars to bring the probability of non-constant-timeness down? loop { rng . fill_bytes ( & mut bytes ) ; if let Some ( scalar ) = Scalar :: from_repr ( bytes ) { return scalar ; } } }
Returns a uniformly-random scalar, generated using rejection sampling.
Returns a uniformly - random scalar generated using rejection sampling .
rng
impl RngCore
rng
impl RngCore