shithub: scc

ref: 4cd120c00e9285d5900c7e5a568f82ba6413cb7e
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;
}