int match(State *start, char *s) { List *clist, *nlist, *t; clist = startlist(start, &l1); nlist = &l2; for (; *s; s++) { char c = *s & 0xFF; step(clist, c, nlist); t = clist; clist = nlist; nlist = t; } return ismatch(clist); }
DState* startdstate(State *start) { return dstate(startlist(start, &l1)); }