mirror of
https://github.com/boostorg/dynamic_bitset.git
synced 2026-01-19 04:12:09 +00:00
Merge branch 'master' into develop
This commit is contained in:
@@ -1310,7 +1310,7 @@ dynamic_bitset<Block, Allocator>::m_do_find_from(size_type first_block) const
|
||||
if (i >= num_blocks())
|
||||
return npos; // not found
|
||||
|
||||
return i * bits_per_block + boost::lowest_bit(m_bits[i]);
|
||||
return i * bits_per_block + static_cast<size_type>(boost::lowest_bit(m_bits[i]));
|
||||
|
||||
}
|
||||
|
||||
@@ -1341,7 +1341,7 @@ dynamic_bitset<Block, Allocator>::find_next(size_type pos) const
|
||||
const Block fore = m_bits[blk] >> ind;
|
||||
|
||||
return fore?
|
||||
pos + lowest_bit(fore)
|
||||
pos + static_cast<size_type>(lowest_bit(fore))
|
||||
:
|
||||
m_do_find_from(blk + 1);
|
||||
|
||||
@@ -1779,7 +1779,7 @@ inline typename dynamic_bitset<Block, Allocator>::size_type
|
||||
dynamic_bitset<Block, Allocator>::calc_num_blocks(size_type num_bits)
|
||||
{
|
||||
return num_bits / bits_per_block
|
||||
+ static_cast<int>( num_bits % bits_per_block != 0 );
|
||||
+ static_cast<size_type>( num_bits % bits_per_block != 0 );
|
||||
}
|
||||
|
||||
// gives a reference to the highest block
|
||||
|
||||
Reference in New Issue
Block a user