| 6026 | const xpath_node_set dummy_node_set; |
| 6027 | |
| 6028 | unsigned int hash_string(const char_t* str) |
| 6029 | { |
| 6030 | // Jenkins one-at-a-time hash (http://en.wikipedia.org/wiki/Jenkins_hash_function#one-at-a-time) |
| 6031 | unsigned int result = 0; |
| 6032 | |
| 6033 | while (*str) |
| 6034 | { |
| 6035 | result += static_cast<unsigned int>(*str++); |
| 6036 | result += result << 10; |
| 6037 | result ^= result >> 6; |
| 6038 | } |
| 6039 | |
| 6040 | result += result << 3; |
| 6041 | result ^= result >> 11; |
| 6042 | result += result << 15; |
| 6043 | |
| 6044 | return result; |
| 6045 | } |
| 6046 | |
| 6047 | template <typename T> T* new_xpath_variable(const char_t* name) |
| 6048 | { |