readVarUint = decoder => {
  let num = 0;
  let len = 0;

  while (true) {
    const r = decoder.arr[decoder.pos++];
    num = num | (r & binary.BITS7) << len;
    len += 7;

    if (r < binary.BIT8) {
      return num >>> 0; // return unsigned number!
    }
    /* istanbul ignore if */


    if (len > 35) {
      throw new Error('Integer out of range!');
    }
  }
}
Read unsigned integer (32bit) with variable length.
1/8th of the storage is used as encoding overhead.
 * numbers < 2^7 is stored in one bytlength
 * numbers < 2^14 is stored in two bylength

@function
@param {Decoder} decoder
@return {number} An unsigned integer.length