shithub: scc

ref: 050797f4780ad8b7737975cfe9a60d52d4bc67a4
dir: /src/libscc/genhash.c/

View raw version
unsigned
genhash(char *name)
{
	unsigned h;
	char c;

	for (h = 0; c = *name; ++name)
		h = h*33 ^ c;

	return h;
}