Merge branch 'compilation_fixes'

Fixes the compilation of the current master.
This commit is contained in:
Mark de Wever 2014-04-05 21:24:36 +02:00
commit 1e8078d13d
4 changed files with 23 additions and 23 deletions

View file

@ -372,6 +372,7 @@ add_library(wesnoth-sdl
target_link_libraries(wesnoth-sdl
${SDL_LIBRARY}
${SDLIMAGE_LIBRARY}
)
# The main library is rather huge especially in debug mode, causing quite a bit

View file

@ -371,12 +371,12 @@ set_scontext_local_choice::~set_scontext_local_choice()
random_seed_choice::random_seed_choice()
{
};
}
random_seed_choice::~random_seed_choice()
{
};
}
config random_seed_choice::query_user() const
{
@ -386,7 +386,7 @@ config random_seed_choice::query_user() const
config retv;
retv["new_seed"] = rand();
return retv;
};
}
config random_seed_choice::random_choice() const
{
//it obviously doesn't make sense to call the uninitialized random generator to generatoe a seed ofr the same random generator;

View file

@ -57,7 +57,6 @@ public:
it would make things easier if that was possible.
@param save_in_replay whether data should be saved in replay.
@param use_undo this parameter is used to ignore undos during an ai move to optimize.
@param store_in_replay only true if called by do_replay_handle
@param error_handler an error handler for the case that data contains invalid data.
@ -179,4 +178,4 @@ public:
};
#endif
#endif

View file

@ -83,10 +83,10 @@ BOOST_AUTO_TEST_CASE( test_bit_width )
BOOST_CHECK( bit_width<boost::uint32_t>() == 32 );
BOOST_CHECK( bit_width<boost::uint64_t>() == 64 );
BOOST_CHECK( bit_width((boost::uint8_t) 0) == 8 );
BOOST_CHECK( bit_width((boost::uint16_t) 0) == 16 );
BOOST_CHECK( bit_width((boost::uint32_t) 0) == 32 );
BOOST_CHECK( bit_width((boost::uint64_t) 0) == 64 );
BOOST_CHECK( bit_width(static_cast<boost::uint8_t>(0)) == 8 );
BOOST_CHECK( bit_width(static_cast<boost::uint16_t>(0)) == 16 );
BOOST_CHECK( bit_width(static_cast<boost::uint32_t>(0)) == 32 );
BOOST_CHECK( bit_width(static_cast<boost::uint64_t>(0)) == 64 );
}
BOOST_AUTO_TEST_CASE( test_count_ones )
@ -106,16 +106,16 @@ BOOST_AUTO_TEST_CASE( test_count_ones )
BOOST_AUTO_TEST_CASE( test_count_leading_zeros )
{
BOOST_CHECK( count_leading_zeros((boost::uint8_t) 1) == 7 );
BOOST_CHECK( count_leading_zeros((boost::uint16_t) 1) == 15 );
BOOST_CHECK( count_leading_zeros((boost::uint32_t) 1) == 31 );
BOOST_CHECK( count_leading_zeros((boost::uint64_t) 1) == 63 );
BOOST_CHECK( count_leading_zeros((boost::uint8_t) 0xFF) == 0 );
BOOST_CHECK( count_leading_zeros((unsigned int) 0)
BOOST_CHECK( count_leading_zeros(static_cast<boost::uint8_t>(1)) == 7 );
BOOST_CHECK( count_leading_zeros(static_cast<boost::uint16_t>(1)) == 15 );
BOOST_CHECK( count_leading_zeros(static_cast<boost::uint32_t>(1)) == 31 );
BOOST_CHECK( count_leading_zeros(static_cast<boost::uint64_t>(1)) == 63 );
BOOST_CHECK( count_leading_zeros(static_cast<boost::uint8_t>(0xFF)) == 0 );
BOOST_CHECK( count_leading_zeros(static_cast<unsigned int>(0))
== bit_width<unsigned int>() );
BOOST_CHECK( count_leading_zeros((unsigned long int) 0)
BOOST_CHECK( count_leading_zeros(static_cast<unsigned long int>(0))
== bit_width<unsigned long int>() );
BOOST_CHECK( count_leading_zeros((unsigned long long int) 0)
BOOST_CHECK( count_leading_zeros(static_cast<unsigned long long int>(0))
== bit_width<unsigned long long int>() );
BOOST_CHECK( count_leading_zeros('\0')
== bit_width<char>() );
@ -131,13 +131,13 @@ BOOST_AUTO_TEST_CASE( test_count_leading_ones )
{
BOOST_CHECK( count_leading_ones(0) == 0 );
BOOST_CHECK( count_leading_ones(1) == 0 );
BOOST_CHECK( count_leading_ones((boost::uint8_t) 0xFF) == 8 );
BOOST_CHECK( count_leading_ones((boost::uint16_t) 0xFFFF) == 16 );
BOOST_CHECK( count_leading_ones((boost::uint32_t) 0xFFFFFFFF) == 32 );
BOOST_CHECK( count_leading_ones((boost::uint64_t) 0xFFFFFFFFFFFFFFFF)
BOOST_CHECK( count_leading_ones(static_cast<boost::uint8_t>(0xFF)) == 8 );
BOOST_CHECK( count_leading_ones(static_cast<boost::uint16_t>(0xFFFF)) == 16 );
BOOST_CHECK( count_leading_ones(static_cast<boost::uint32_t>(0xFFFFFFFF)) == 32 );
BOOST_CHECK( count_leading_ones(static_cast<boost::uint64_t>(0xFFFFFFFFFFFFFFFF))
== 64 );
BOOST_CHECK( count_leading_ones((boost::uint8_t) 0xF8) == 5 );
BOOST_CHECK( count_leading_ones((boost::uint16_t) 54321) == 2 );
BOOST_CHECK( count_leading_ones(static_cast<boost::uint8_t>(0xF8)) == 5 );
BOOST_CHECK( count_leading_ones(static_cast<boost::uint16_t>(54321)) == 2 );
}
/* vim: set ts=4 sw=4: */