FreeBSD/contrib/ntp/ntpd/keyword-gen.c
/* Define a function that takes a list of (keyword, token) values and
 * creates a keywords scanner out of it.
 */
Define a function that takes a list of (keyword, token) values and
creates a keywords scanner out of it.
Define a function that takes a list of ( keyword token ) values and creates a keywords scanner out of it .
static u_short
create_keyword_scanner(void)
{
	u_short scanner;
	u_short i;
	sst_highwater = 1;	
	scanner = 0;
	for (i = 0; i < COUNTOF(ntp_keywords); i++) {
		current_keyword = ntp_keywords[i].key;
		scanner =
		    create_scan_states(
			ntp_keywords[i].key,
			ntp_keywords[i].token,
			ntp_keywords[i].followedby,
			scanner);
	}
	return scanner;
}
static u_short create_keyword_scanner ( void ) { u_short scanner ; u_short i ; sst_highwater = 1 ; scanner = 0 ; for ( i = 0 ; i < COUNTOF ( ntp_keywords ) ; i ++ ) { current_keyword = ntp_keywords [ i ] . key ; scanner = create_scan_states ( ntp_keywords [ i ] . key , ntp_keywords [ i ] . token , ntp_keywords [ i ] . followedby , scanner ) ; } return scanner ; }
Define a function that takes a list of (keyword, token) values and
 creates a keywords scanner out of it.
Define a function that takes a list of ( keyword token ) values and creates a keywords scanner out of it .
/* index 0 invalid, unused */