Skip to main content

path_hash

Function path_hash 

Source
fn path_hash(s: &str) -> u32
Expand description

Math.abs(TQ(cwd)): 31·h + c over UTF-16 code units, wrapping at 32 bits (Java’s String.hashCode). i32::MIN’s absolute value doesn’t fit an i32, and JavaScript numbers don’t wrap, so the magnitude is returned unsigned.