shithub: scc

ref: 34fbebfbdb9eefea9c87a4065b95aee8c454cdbb
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;
}