Assert on the precondition to pop_back()

This commit is contained in:
Gennaro Prota
2025-06-22 18:16:21 +02:00
parent 32ae43ef6d
commit f56b3dde37

View File

@@ -793,6 +793,7 @@ template <typename Block, typename Allocator>
void dynamic_bitset<Block, Allocator>::
pop_back()
{
BOOST_ASSERT( !empty() );
const size_type old_num_blocks = num_blocks();
const size_type required_blocks = calc_num_blocks(m_num_bits - 1);