MCPcopy Create free account
hub / github.com/PerroEngine/Perro / hash_combine

Function hash_combine

perro_source/api_modules/perro_modules/src/random.rs:55–62  ·  view source on GitHub ↗
(a: u32, b: u32)

Source from the content-addressed store, hash-verified

53
54#[inline]
55pub const fn hash_combine(a: u32, b: u32) -> u32 {
56 hash_u32(
57 a ^ b
58 .wrapping_add(0x9e37_79b9)
59 .wrapping_add(a << 6)
60 .wrapping_add(a >> 2),
61 )
62}
63
64#[inline]
65pub const fn hash_combine3(a: u32, b: u32, c: u32) -> u32 {

Callers 4

hash_combine3Function · 0.85
hash_combine4Function · 0.85
hash2_u32Function · 0.85

Calls 1

hash_u32Function · 0.70

Tested by 1