diff options
| author | e4m2 <git@e4m2.com> | 2024-02-08 15:21:35 +0100 |
|---|---|---|
| committer | e4m2 <git@e4m2.com> | 2024-02-08 15:21:35 +0100 |
| commit | 8d56e472c9fa97dc6eeae9866eed927910f7dfe2 (patch) | |
| tree | 76886b87aee7e499e51b9852701c4ebb75dd135d /lib/std/Random/ChaCha.zig | |
| parent | 9af077d71eaf2c004d63405fc5c017e237cb9c6c (diff) | |
| download | zig-8d56e472c9fa97dc6eeae9866eed927910f7dfe2.tar.gz zig-8d56e472c9fa97dc6eeae9866eed927910f7dfe2.zip | |
Replace std.rand references with std.Random
Diffstat (limited to 'lib/std/Random/ChaCha.zig')
| -rw-r--r-- | lib/std/Random/ChaCha.zig | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/std/Random/ChaCha.zig b/lib/std/Random/ChaCha.zig index 75f62c9a47..5783ee4152 100644 --- a/lib/std/Random/ChaCha.zig +++ b/lib/std/Random/ChaCha.zig @@ -5,7 +5,6 @@ const std = @import("std"); const mem = std.mem; -const Random = std.rand.Random; const Self = @This(); const Cipher = std.crypto.stream.chacha.ChaCha8IETF; @@ -53,9 +52,9 @@ pub fn addEntropy(self: *Self, bytes: []const u8) void { self.refill(); } -/// Returns a `std.rand.Random` structure backed by the current RNG. -pub fn random(self: *Self) Random { - return Random.init(self, fill); +/// Returns a `std.Random` structure backed by the current RNG. +pub fn random(self: *Self) std.Random { + return std.Random.init(self, fill); } // Refills the buffer with random bytes, overwriting the previous key. |
