diff --git a/ConflictSet.cpp b/ConflictSet.cpp index 84313db..742abae 100644 --- a/ConflictSet.cpp +++ b/ConflictSet.cpp @@ -374,10 +374,8 @@ inline void Node16::copyChildrenAndKeyFrom(const Node48 &other) { other.bitSet.forEachInRange( [&](int c) { // Suppress a false positive -Waggressive-loop-optimizations warning - // in gcc. `assume` doesn't work for some reason. - if (!(i < Node16::kMaxNodes)) { - __builtin_unreachable(); // GCOVR_EXCL_LINE - } + // in gcc + assume(i < Node16::kMaxNodes); index[i] = c; children[i] = other.children[other.index[c]]; assert(children[i].child->parent == &other); @@ -430,10 +428,8 @@ inline void Node48::copyChildrenAndKeyFrom(const Node256 &other) { bitSet.forEachInRange( [&](int c) { // Suppress a false positive -Waggressive-loop-optimizations warning - // in gcc. `assume` doesn't work for some reason. - if (!(i < Node48::kMaxNodes)) { - __builtin_unreachable(); // GCOVR_EXCL_LINE - } + // in gcc. + assume(i < Node48::kMaxNodes); index[c] = i; children[i] = other.children[c]; assert(children[i].child->parent == &other);