INNER CODE UNIT · C

y

chjj/liburkel · src/bits.c:32

  size_t y = URKEL_KEY_BITS - depth;
  size_t len = x < y ? x : y;
  size_t count = 0;
  size_t i;

  CHECK(bits->size <= URKEL_KEY_BITS);
  CHECK(index <= bits->size);
  CHECK(depth <= URKEL_KEY_BITS);

  for (i = 0; i < len; i++) {
    if (urkel_bits_get(bits, index) != urkel_get_bit(key, depth))
      break;

    index += 1;
    depth += 1;
    count += 1;
  }

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…