pike.git / src / stralloc.c

version» Context lines:

pike.git/src/stralloc.c:273:       if(!s->size_shift)    STR0(s)[pos]=value;    else if(s->size_shift == 1)    STR1(s)[pos]=value;    else    STR2(s)[pos]=value;   }      #ifdef PIKE_DEBUG - PMOD_EXPORT struct pike_string *debug_check_size_shift(struct pike_string *a, int shift) + PMOD_EXPORT struct pike_string *debug_check_size_shift(const struct pike_string *a, int shift)   {    if(a->size_shift != shift)    Pike_fatal("Wrong STRX macro used!\n");    return (struct pike_string*)a;   }   #endif      #define CONVERT(FROM,TO) \    void PIKE_CONCAT4(convert_,FROM,_to_,TO) (PIKE_CONCAT(p_wchar,TO) *to, \    const PIKE_CONCAT(p_wchar,FROM) *from, \
pike.git/src/stralloc.c:1374: Inside #if defined(PIKE_DEBUG)
   if(p==foo)    {    return 1;    }    }    }    return 0;   }      /* for once, this is actually a debug function! */ - struct pike_string *debug_findstring(const struct pike_string *foo) + const struct pike_string *debug_findstring(const struct pike_string *foo)   { -  return safe_debug_finstring(foo) ? foo : 0; +  return safe_debug_findstring(foo) ? foo : 0;   }      PMOD_EXPORT void debug_dump_pike_string(const struct pike_string *s, INT32 max)   {    INT32 e;    fprintf(stderr,"0x%p: %ld refs, len=%ld, size_shift=%d, hval=%lux (%lx)\n",    s,    (long)s->refs,    DO_NOT_WARN((long)s->len),    s->size_shift,