Add some [[maybe_unused]] tags for when asserts are disabled
This commit is contained in:
@@ -836,7 +836,7 @@ static void PublicRoad_FoundEndNode(AyStar *aystar, OpenListNode *current)
|
|||||||
// We only get here if we have a parent and we're not adjacent to it. River/Tunnel time!
|
// We only get here if we have a parent and we're not adjacent to it. River/Tunnel time!
|
||||||
const DiagDirection road_direction = DiagdirBetweenTiles(tile, path->parent->node.tile);
|
const DiagDirection road_direction = DiagdirBetweenTiles(tile, path->parent->node.tile);
|
||||||
|
|
||||||
auto end_tile = INVALID_TILE;
|
[[maybe_unused]] auto end_tile = INVALID_TILE;
|
||||||
|
|
||||||
const Slope tile_slope = GetTileSlope(tile);
|
const Slope tile_slope = GetTileSlope(tile);
|
||||||
if (IsUpwardsSlope(tile_slope, road_direction)) {
|
if (IsUpwardsSlope(tile_slope, road_direction)) {
|
||||||
|
@@ -3430,7 +3430,7 @@ private:
|
|||||||
* Show a drop down list using @p list_set, setting the pre-selected item to the one corresponding to @p value
|
* Show a drop down list using @p list_set, setting the pre-selected item to the one corresponding to @p value
|
||||||
* This asserts if @p value is not in @p list_set, and @p missing_ok is false
|
* This asserts if @p value is not in @p list_set, and @p missing_ok is false
|
||||||
*/
|
*/
|
||||||
void ShowCompanyDropDownListWithValue(CompanyID value, bool missing_ok, int button)
|
void ShowCompanyDropDownListWithValue(CompanyID value, [[maybe_unused]] bool missing_ok, int button)
|
||||||
{
|
{
|
||||||
DropDownList list;
|
DropDownList list;
|
||||||
|
|
||||||
|
@@ -49,7 +49,7 @@ Tunnel::~Tunnel()
|
|||||||
tunnel_tile_index_map.erase(this->tile_s);
|
tunnel_tile_index_map.erase(this->tile_s);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool have_erased = false;
|
[[maybe_unused]] bool have_erased = false;
|
||||||
const auto key = GetTunnelAxisHeightCacheKey(this);
|
const auto key = GetTunnelAxisHeightCacheKey(this);
|
||||||
for (auto it = tunnel_axis_height_index.lower_bound(key); it != tunnel_axis_height_index.end() && it->first == key; ++it) {
|
for (auto it = tunnel_axis_height_index.lower_bound(key); it != tunnel_axis_height_index.end() && it->first == key; ++it) {
|
||||||
if (it->second == this) {
|
if (it->second == this) {
|
||||||
|
Reference in New Issue
Block a user