mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-22 17:49:43 +01:00
Move xoshiro_seed
debug print to top
In its previous location, it would only print the value of `s` after it had been mutated by `splitmix32` four times, and it doesn't get used after that, so the print isn't very useful. Mixing code and declarations here is fine because starting from a few months ago, we compile with C99 and if we ever need to compile with C90 then it's trivial to add braces surrounding the declarations.
This commit is contained in:
parent
876362365b
commit
e6a3df6ca6
1 changed files with 2 additions and 2 deletions
|
@ -53,13 +53,13 @@ uint32_t xoshiro_next(void)
|
|||
|
||||
void xoshiro_seed(uint32_t s)
|
||||
{
|
||||
vlog_debug("Xoshiro seeded with %u.", s);
|
||||
|
||||
const uint32_t s0 = splitmix32(&s);
|
||||
const uint32_t s1 = splitmix32(&s);
|
||||
const uint32_t s2 = splitmix32(&s);
|
||||
const uint32_t s3 = splitmix32(&s);
|
||||
seed(s0, s1, s2, s3);
|
||||
|
||||
vlog_debug("Xoshiro seeded with %u.", s);
|
||||
}
|
||||
|
||||
float xoshiro_rand(void)
|
||||
|
|
Loading…
Reference in a new issue