bridge/class-master/depend/pari/src/basemath/bibli2.c
/* indirect sort: return the permutation that would sort x */
indirect sort: return the permutation that would sort x
indirect sort : return the permutation that would sort x
GEN
gen_indexsort(GEN x, void *E, int (*cmp)(void*,GEN,GEN))
{
  long tx, lx;
  init_sort(&x, &tx, &lx);
  if (lx==1) return cgetg(1, t_VECSMALL);
  return gen_sortspec(x,lx-1,E,cmp);
}
GEN gen_indexsort ( GEN x , void * E , int ( * cmp ) ( void * , GEN , GEN ) ) { long tx , lx ; init_sort ( & x , & tx , & lx ) ; if ( lx == 1 ) return cgetg ( 1 , t_VECSMALL ) ; return gen_sortspec ( x , lx - 1 , E , cmp ) ; }
indirect sort: return the permutation that would sort x
indirect sort : return the permutation that would sort x