Lines Matching defs:dt
25 ** dt: dictionary being searched
33 static Void_t* dttree(Dt_t* dt, Void_t* obj, int type)
35 static Void_t* dttree(dt,obj,type)
36 Dt_t* dt;
49 UNFLATTEN(dt);
50 disc = dt->disc; _DTDSC(disc,ky,sz,lk,cmpf);
51 dt->type &= ~DT_FOUND;
53 root = dt->data->here;
65 (*disc->freef)(dt,_DTOBJ(root,lk),disc);
67 (*dt->memoryf)(dt,(Void_t*)root,0,disc);
71 dt->data->size = 0;
72 dt->data->here = NIL(Dtlink_t*);
85 dt->data->here = root;
94 if(dt->meth->type == DT_OBAG && (type&(DT_DELETE|DT_DETACH)) )
96 for(o = dtsearch(dt,obj); o; o = dtnext(dt,o) )
98 if(_DTCMP(dt,key,k,disc,cmpf,sz) != 0)
101 { root = dt->data->here;
124 if(dt->meth->type == DT_OSET &&
125 (minp = dt->data->minp) != 0 && (type&(DT_MATCH|DT_SEARCH)) )
129 if((cmp = _DTCMP(dt,key,k,disc,cmpf,sz)) == 0)
171 if((cmp = _DTCMP(dt,key,k,disc,cmpf,sz)) == 0)
176 if((cmp = _DTCMP(dt,key,k,disc,cmpf,sz)) < 0)
203 if((cmp = _DTCMP(dt,key,k,disc,cmpf,sz)) > 0)
232 dt->type |= DT_FOUND;
240 if((dt->meth->type&DT_OBAG) && (type&(DT_SEARCH|DT_MATCH)) )
250 if(_DTCMP(dt,key,k,disc,cmpf,sz) != 0)
255 dt->data->here = root;
289 (*disc->freef)(dt,obj,disc);
291 (*dt->memoryf)(dt,(Void_t*)root,0,disc);
292 if((dt->data->size -= 1) < 0)
293 dt->data->size = -1;
297 { if(dt->meth->type&DT_OSET)
307 { if(dt->meth->type&DT_OSET)
309 (*disc->freef)(dt,obj,disc);
311 (*dt->memoryf)(dt,(Void_t*)me,0,disc);
317 dt->data->size += 1;
336 dt->data->here = link.left;
342 obj = (*disc->makef)(dt,obj,disc);
347 { root = (Dtlink_t*)(*dt->memoryf)
348 (dt,NIL(Void_t*),sizeof(Dthold_t),disc);
353 (*disc->freef)(dt,obj,disc);
357 { if(dt->data->size >= 0)
358 dt->data->size += 1;
365 dt->data->size += 1;