pike.git / src / pike_search_engine.c

version» Context lines:

pike.git/src/pike_search_engine.c:61:    ptrdiff_t needlelen,    ptrdiff_t max_haystacklen)   {    INT32 tmp, h;    ptrdiff_t hsize, e, max;    NCHAR *q;    struct hubbe_search_link *ptr;    INT32 linklen[NELEM(s->set)];    INT32 maxlinklength;    -  NEEDLE=needle; -  NEEDLELEN=needlelen; +  s->needle=needle; +  s->needlelen=needlelen;      #ifdef PIKE_DEBUG    if(needlelen < 7)    fatal("hubbe search does not work with search strings shorter than 7 characters!\n");   #endif      #ifdef TUNAFISH    hsize=52+(max_haystacklen >> 7) - (needlelen >> 8);    max =13+(max_haystacklen >> 4) - (needlelen >> 5);   
pike.git/src/pike_search_engine.c:154:   }         void NameN(init_boyer_moore_hubbe)(struct boyer_moore_hubbe_searcher *s,    NCHAR *needle,    ptrdiff_t needlelen,    ptrdiff_t max_haystacklen)   {    ptrdiff_t e;    -  NEEDLE=needle; -  NEEDLELEN=needlelen; +  s->needle=needle; +  s->needlelen=needlelen;      #ifdef PIKE_DEBUG    if(needlelen < 2)    fatal("boyer-boore-hubbe search does not work with single-character search strings!\n");   #endif      #ifdef TUNAFISH    s->plen = 8 + ((max_haystacklen-needlelen) >> 5);    if(s->plen>needlelen) s->plen=needlelen;    if(s->plen>BMLEN) s->plen=BMLEN;