mirror of
https://github.com/boostorg/core.git
synced 2025-07-31 13:27:29 +02:00
Update bit_ceil_test.cpp
This commit is contained in:
@@ -19,14 +19,15 @@ template<class T> void test_bit_ceil( T x )
|
||||
|
||||
T y = boost::core::bit_ceil( x );
|
||||
|
||||
BOOST_TEST( boost::core::has_single_bit( y ) );
|
||||
BOOST_TEST_GE( +y, +x );
|
||||
|
||||
if( x == 0 )
|
||||
{
|
||||
BOOST_TEST_EQ( y, 1 );
|
||||
}
|
||||
else
|
||||
{
|
||||
BOOST_TEST( boost::core::has_single_bit( y ) );
|
||||
BOOST_TEST_GE( +y, +x );
|
||||
BOOST_TEST_LT( y >> 1, +x );
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user