1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

rand: speed up MT19937RNG.u64

This commit is contained in:
Delyan Angelov 2022-04-10 13:07:35 +03:00
parent 6c25f5b291
commit a0e7a46be4

View File

@ -147,7 +147,7 @@ pub fn (mut rng MT19937RNG) u32() u32 {
const mag01 = [u64(0), u64(matrix_a)]
// u64 returns a pseudorandom 64bit int in range `[0, 2⁶⁴)`.
[inline]
[direct_array_access; inline]
pub fn (mut rng MT19937RNG) u64() u64 {
mut x := u64(0)
mut i := int(0)