Skip to content

Commit

Permalink
Build: Fix MSVC type casting warning in overmap.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
BrettDong authored and kevingranade committed Jul 10, 2017
1 parent cb01f5b commit f522d86
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/overmap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ void overmap_specials::finalize()
void overmap_specials::check_consistency()
{
const size_t max_count = ( OMAPX / OMSPEC_FREQ ) * ( OMAPY / OMSPEC_FREQ ) / 2;
const size_t actual_count = std::accumulate( specials.get_all().begin(), specials.get_all().end(), 0,
const size_t actual_count = std::accumulate( specials.get_all().begin(), specials.get_all().end(), static_cast< size_t >( 0 ),
[]( size_t sum, const overmap_special &elem ) {
return sum + ( elem.flags.count( "UNIQUE" ) == ( size_t )0 ? ( size_t )std::max( elem.occurrences.min, 0 ) : ( size_t )1 );
} );
Expand Down

0 comments on commit f522d86

Please sign in to comment.