1
0
Fork 0

Codechange: remove std::source_location since it's unused now

pull/12259/head
Rubidium 2024-03-10 14:35:28 +01:00
parent 6b613957d8
commit 8d86a5de56
2 changed files with 5 additions and 5 deletions

View File

@ -64,7 +64,7 @@
#ifdef _DEBUG #ifdef _DEBUG
TileIndex TILE_ADD(TileIndex tile, TileIndexDiff offset, std::source_location location) TileIndex TILE_ADD(TileIndex tile, TileIndexDiff offset)
{ {
int dx = offset & Map::MaxX(); int dx = offset & Map::MaxX();
if (dx >= (int)Map::SizeX() / 2) dx -= Map::SizeX(); if (dx >= (int)Map::SizeX() / 2) dx -= Map::SizeX();

View File

@ -463,9 +463,9 @@ inline TileIndexDiff ToTileIndexDiff(TileIndexDiffC tidc)
* @return The resulting tile. * @return The resulting tile.
*/ */
#ifndef _DEBUG #ifndef _DEBUG
constexpr TileIndex TILE_ADD(TileIndex tile, TileIndexDiff offset, [[maybe_unused]] const std::source_location location = std::source_location::current()) { return tile + offset; } constexpr TileIndex TILE_ADD(TileIndex tile, TileIndexDiff offset) { return tile + offset; }
#else #else
TileIndex TILE_ADD(TileIndex tile, TileIndexDiff offset, const std::source_location location = std::source_location::current()); TileIndex TILE_ADD(TileIndex tile, TileIndexDiff offset);
#endif #endif
/** /**
@ -476,9 +476,9 @@ inline TileIndexDiff ToTileIndexDiff(TileIndexDiffC tidc)
* @param y The y offset to add to the tile. * @param y The y offset to add to the tile.
* @return The resulting tile. * @return The resulting tile.
*/ */
inline TileIndex TILE_ADDXY(TileIndex tile, int x, int y, const std::source_location location = std::source_location::current()) inline TileIndex TILE_ADDXY(TileIndex tile, int x, int y)
{ {
return TILE_ADD(tile, TileDiffXY(x, y), location); return TILE_ADD(tile, TileDiffXY(x, y));
} }
TileIndex TileAddWrap(TileIndex tile, int addx, int addy); TileIndex TileAddWrap(TileIndex tile, int addx, int addy);