QtLingo 1
QtLingo is an Application to make Qt Computer Translations easier
efl_hash.h File Reference

Go to the source code of this file.

Typedefs

typedef unsigned long hash_t
 type of efl_hash. More...
 

Functions

hash_t efl_hash (const wchar_t *s)
 do some fancy bitwanking on the string. efl_hash More...
 

Typedef Documentation

◆ hash_t

type of efl_hash.

Definition at line 7 of file efl_hash.h.

Function Documentation

◆ efl_hash()

hash_t efl_hash ( const wchar_t *  s)
inline

do some fancy bitwanking on the string. efl_hash

Definition at line 12 of file efl_hash.h.

13{
14 const wchar_t *name = (const wchar_t*) (wchar_t*) s;
15 unsigned long h = 0;
16 while (*name != L'\0')
17 {
18 unsigned long g;
19 h = (h << 4) + (hash_t)(*name++);
20 if ((g = (h & 0xF0000000UL))!=0) { h ^= (g >> 24); }
21 h &= ~g;
22 }
23 return h;
24}
unsigned long hash_t
type of efl_hash.
Definition: efl_hash.h:7