diff options
author | wtc%netscape.com <devnull@localhost> | 2003-04-10 18:10:12 +0000 |
---|---|---|
committer | wtc%netscape.com <devnull@localhost> | 2003-04-10 18:10:12 +0000 |
commit | 46ea18e5e4d89fff1abae6bdb0d8a5ead07e267b (patch) | |
tree | fcaa2cf4b1b3d68067778ec6eb8f69548a23ff73 | |
parent | 40e8b75635f838516dd95ec573be30a94224927d (diff) | |
download | nspr-hg-46ea18e5e4d89fff1abae6bdb0d8a5ead07e267b.tar.gz |
Explain how the GOLDEN_RATIO constant was calculated.
-rw-r--r-- | lib/ds/plhash.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ds/plhash.c b/lib/ds/plhash.c index f02b5132..8cfce081 100644 --- a/lib/ds/plhash.c +++ b/lib/ds/plhash.c @@ -179,7 +179,7 @@ PL_HashTableDestroy(PLHashTable *ht) /* ** Multiplicative hash, from Knuth 6.4. */ -#define GOLDEN_RATIO 0x9E3779B9U +#define GOLDEN_RATIO 0x9E3779B9U /* 2/(1+sqrt(5))*(2^32) */ PR_IMPLEMENT(PLHashEntry **) PL_HashTableRawLookup(PLHashTable *ht, PLHashNumber keyHash, const void *key) |