148763Sbostic /*-
2*62360Sbostic  * Copyright (c) 1988, 1993
3*62360Sbostic  *	The Regents of the University of California.  All rights reserved.
431896Sminshall  *
548763Sbostic  * %sccs.include.redist.c%
633811Sbostic  *
7*62360Sbostic  *	@(#)dohits.h	8.1 (Berkeley) 06/06/93
831896Sminshall  */
931896Sminshall 
1029994Sminshall #define	numberof(x)	(sizeof x/sizeof x[0])
1129994Sminshall #define	highestof(x)	(numberof(x)-1)
1229994Sminshall 
1329994Sminshall #define	firstentry(x)	(table[dohash(0, (x))%highestof(table)])
1429994Sminshall 
1530052Sminshall struct Hits {
1629994Sminshall     struct hits hits;
1729994Sminshall     char *name[4];
1829994Sminshall };
1929994Sminshall 
2029994Sminshall struct thing {
2129994Sminshall     struct thing *next;
2229994Sminshall     struct Hits *hits;
2329994Sminshall     unsigned char value;
2429994Sminshall     char name[100];
2529994Sminshall };
2629994Sminshall 
2729994Sminshall extern struct Hits Hits[256];		/* one for each of 0x00-0xff */
2829994Sminshall extern struct thing *table[100];
2929994Sminshall 
3029994Sminshall extern unsigned int dohash();
31