2 * Copyright 2009, Ingo Weinhold, ingo_weinhold@gmx.de. All Rights Reserved.
3 * Distributed under the terms of the MIT License.
6 #include "StringUtils.h"
9 // from the Dragon Book: a slightly modified hashpjw()
11 StringUtils::HashValue(const char* string
)
18 for (; *string
; string
++) {
19 uint32 g
= h
& 0xf0000000;
22 h
= (h
<< 4) + *string
;