Changeset - r21245:199363a7a788
[Not reviewed]
master
0 2 0
frosch - 10 years ago 2014-02-11 20:34:48
frosch@openttd.org
(svn r26333) -Fix: Compilation without static_assert.
2 files changed with 3 insertions and 3 deletions:
0 comments (0 inline, 0 general)
src/cargopacket.cpp
Show inline comments
 
@@ -557,8 +557,8 @@ void VehicleCargoList::InvalidateCache()
 
template<VehicleCargoList::MoveToAction Tfrom, VehicleCargoList::MoveToAction Tto>
 
uint VehicleCargoList::Reassign(uint max_move, TileOrStationID)
 
{
 
	assert_compile(Tfrom != MTA_TRANSFER && Tto != MTA_TRANSFER);
 
	assert_compile(Tfrom - Tto == 1 || Tto - Tfrom == 1);
 
	assert_tcompile(Tfrom != MTA_TRANSFER && Tto != MTA_TRANSFER);
 
	assert_tcompile(Tfrom - Tto == 1 || Tto - Tfrom == 1);
 
	max_move = min(this->action_counts[Tfrom], max_move);
 
	this->action_counts[Tfrom] -= max_move;
 
	this->action_counts[Tto] += max_move;
src/core/pool_type.hpp
Show inline comments
 
@@ -82,7 +82,7 @@ private:
 
template <class Titem, typename Tindex, size_t Tgrowth_step, size_t Tmax_size, PoolType Tpool_type = PT_NORMAL, bool Tcache = false, bool Tzero = true>
 
struct Pool : PoolBase {
 
	/* Ensure Tmax_size is within the bounds of Tindex. */
 
	assert_compile((Tmax_size - 1) >> 8 * sizeof(Tindex) == 0);
 
	assert_compile((uint64)(Tmax_size - 1) >> 8 * sizeof(Tindex) == 0);
 

	
 
	static const size_t MAX_SIZE = Tmax_size; ///< Make template parameter accessible from outside
 

	
0 comments (0 inline, 0 general)