pike.git / src / modules / _Stdio / buffer.cmod

version» Context lines:

pike.git/src/modules/_Stdio/buffer.cmod:1413:    *!    */    PIKEFUN Buffer add_hint( object|int i, int len_width )    {    int width;    pop_stack(); /* width */    if( TYPEOF(*i) == PIKE_T_INT )    {    INT_TYPE ui = i->u.integer;    for( width=0; width<SIZEOF_INT_TYPE; width++ ) -  if( ui < (1<<(width*8)) && ui >= -(1<<(width*8-1)) ) +  if( ui < (((INT_TYPE)1)<<(width*8)) && +  ui >= -(((INT_TYPE)1)<<(width*8-1)) )    break;    io_add_int( THIS, width, len_width );    io_add_int( THIS, i->u.integer, width );    Pike_sp--;    }    else    {    convert_stack_top_to_bignum();    width = (mpz_sizeinbase( (void*)i->u.object->storage, 2)+7)/8;    io_add_int( THIS, width, len_width );