Lines Matching defs:first

303  *   new = link_machines( first, last );
305 * new - a machine constructed by connecting first to last
306 * first - the machine whose successor is to be last
307 * last - the machine whose predecessor is to be first
309 * note: this routine concatenates the machine first with the machine
310 * last to produce a machine new which will pattern-match first first
316 link_machines(int first, int last)
318 if (first == NIL)
322 return first;
325 mkxtion(finalst[first], last);
326 finalst[first] = finalst[last];
327 lastst[first] = MAX(lastst[first], lastst[last]);
328 firstst[first] = MIN(firstst[first], firstst[last]);
330 return first;
339 * The "beginning" states are the epsilon closure of the first state
374 * branch = mkbranch( first, second );
376 * branch - a machine which matches either first's pattern or second's
377 * first, second - machines whose patterns are to be or'ed (the | operator)
379 * Note that first and second are NEITHER destroyed by the operation. Also,
385 mkbranch(int first, int second)
389 if (first == NO_TRANSITION)
393 return first;
397 mkxtion(eps, first);
460 * new = mkor( first, second );
462 * new - a machine which matches either first's pattern or second's
463 * first, second - machines whose patterns are to be or'ed (the | operator)
465 * note that first and second are both destroyed by the operation
471 mkor(int first, int second)
475 if (first == NIL)
479 return first;
483 * See comment in mkopt() about why we can't use the first
484 * state of "first" or "second" if they satisfy
489 first = link_machines(eps, first);
491 mkxtion(first, second);
493 if (SUPER_FREE_EPSILON(finalst[first]) &&
494 accptnum[finalst[first]] == NIL) {
495 orend = finalst[first];
500 mkxtion(finalst[first], orend);
504 first = link_machines(first, eps);
505 orend = finalst[first];
511 finalst[first] = orend;
512 return first;
645 * was already done when the ccl was created for the first