commit | acaf608c3fcc83f9feb15ece7c23e3770d230927 | [log] [tgz] |
---|---|---|
author | Joel Galenson <[email protected]> | Thu Jun 03 20:25:14 2021 +0000 |
committer | Automerger Merge Worker <[email protected]> | Thu Jun 03 20:25:14 2021 +0000 |
tree | bec0501e1094cccd9e6fbeded10ef744d623fd62 | |
parent | 4ce34f22a26324c1f70b1d9e38619ce08ce11e80 [diff] | |
parent | b3fa6077a0d4a66f1dd728ce23ea48a454c11bb8 [diff] |
Use new c2a functionality instead of a patch. am: b3fa6077a0 Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/rand_xorshift/+/1725432 Change-Id: I184270046981f1be7d88a516b35eb8f50900f67f
Implements the Xorshift random number generator.
The Xorshift[^1] algorithm is not suitable for cryptographic purposes but is very fast. If you do not know for sure that it fits your requirements, use a more secure one such as StdRng
or OsRng
.
[^1]: Marsaglia, George (July 2003). “Xorshift RNGs”. Journal of Statistical Software. Vol. 8 (Issue 14).
Links:
rand_xorshift
is no_std
compatible. It does not require any functionality outside of the core
lib, thus there are no features to configure.
The serde1
feature includes implementations of Serialize
and Deserialize
for the included RNGs.
rand_xorshift
is distributed under the terms of both the MIT license and the Apache License (Version 2.0).
See LICENSE-APACHE and LICENSE-MIT, and COPYRIGHT for details.