Lines Matching refs:rchild
107 int lchild[N + 1], rchild[N + 257], parent[N + 1];
175 * For i = 0 to N - 1, rchild[i] and lchild[i] will be the right and left
178 * for 'not used.' For i = 0 to 255, rchild[N + i + 1] is the root of the
190 sp->rchild[i] = NIL;
211 sp->rchild[r] = sp->lchild[r] = NIL;
215 if (sp->rchild[p] != NIL)
216 p = sp->rchild[p];
218 sp->rchild[p] = r;
243 sp->rchild[r] = sp->rchild[p];
245 sp->parent[sp->rchild[p]] = r;
246 if (sp->rchild[sp->parent[p]] == p)
247 sp->rchild[sp->parent[p]] = r;
260 if (sp->rchild[p] == NIL)
263 q = sp->rchild[p];
266 if (sp->rchild[q] != NIL) {
268 q = sp->rchild[q];
269 } while (sp->rchild[q] != NIL);
270 sp->rchild[sp->parent[q]] = sp->lchild[q];
275 sp->rchild[q] = sp->rchild[p];
276 sp->parent[sp->rchild[p]] = q;
279 if (sp->rchild[sp->parent[p]] == p)
280 sp->rchild[sp->parent[p]] = q;