#include "defs.h" /* chose routine for sort on x */ DPIN chosex(strt, prev ) DPIN strt; PIN prev; { INT bx=0, by=0; REG PIN pp; DPIN best; REG DPIN dv; best = 0; for (dv = strt; dv < &pinvec[npins]; dv++) { pp = dv->pinp; if (best) { if (pp->x > bx) continue; if (pp->x == bx && pp->y > by) continue; } best = dv; bx = pp->x; by = pp->y; } return(best); }