wtx 0.45.0

A collection of different transport implementations and related tools focused primarily on web technologies.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use crate::rng::Rng;

cfg_select! {
  feature = "rand_core" => {
    /// Marker trait used to indicate that an [`Rng`] implementation is supposed to be
    /// cryptographically secure.
    pub trait CryptoRng: rand_core::CryptoRng + Rng {}

    impl<T> CryptoRng for &mut T where T: rand_core::CryptoRng + Rng {}
  }
  _ => {
    /// Marker trait used to indicate that an [`Rng`] implementation is supposed to be
    /// cryptographically secure.
    pub trait CryptoRng: Rng {}

    impl<T> CryptoRng for &mut T where T: Rng {}
  }
}