windows-nt/Source/XPSP1/NT/sdktools/masm/hash.c

17 lines
245 B
C
Raw Normal View History

2020-09-26 03:20:57 -05:00
/*
** hash : hashes the given string by adding all the chars in the string.
*/
unsigned short
hash ( name )
register char *name;
{
register unsigned short i = 0;
register unsigned short c;
while (c = *name++)
i += c;
return( i );
}