PostGIS 3.7.0dev-r@@SVN_REVISION@@
Loading...
Searching...
No Matches

◆ partition()

static double * partition ( double *  left,
double *  right,
double  pivot 
)
static

Definition at line 67 of file rt_statistics.c.

67 {
68 while (left <= right) {
69 while (*left < pivot) ++left;
70 while (*right >= pivot) --right;
71
72 if (left < right) {
73 SWAP(*left, *right);
74 ++left;
75 --right;
76 }
77 }
78
79 return left;
80}
#define SWAP(x, y)
static double pivot(double *left, double *right)

References pivot(), and SWAP.

Referenced by quicksort().

Here is the call graph for this function:
Here is the caller graph for this function: