MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / hash_string

Function hash_string

Source/ThirdParty/pugixml/pugixml.cpp:7655–7672  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7653 static const xpath_node_set dummy_node_set;
7654
7655 PUGI__FN unsigned int hash_string(const char_t* str)
7656 {
7657 // Jenkins one-at-a-time hash (http://en.wikipedia.org/wiki/Jenkins_hash_function#one-at-a-time)
7658 unsigned int result = 0;
7659
7660 while (*str)
7661 {
7662 result += static_cast<unsigned int>(*str++);
7663 result += result << 10;
7664 result ^= result >> 6;
7665 }
7666
7667 result += result << 3;
7668 result ^= result >> 11;
7669 result += result << 15;
7670
7671 return result;
7672 }
7673
7674 template <typename T> PUGI__FN T* new_xpath_variable(const char_t* name)
7675 {

Callers 2

findMethod · 0.85
addMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected