1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-19 12:39:11 +00:00

Codechange: use const auto & instead of making a copy

This commit is contained in:
Rubidium
2025-03-08 20:42:02 +01:00
committed by rubidium42
parent 91d22f7617
commit a23dda7ffe
5 changed files with 5 additions and 5 deletions

View File

@@ -85,7 +85,7 @@ TEST_CASE("PartialPixelSlopeAdditionTest - A half tile steep slope is a one corn
* @param expected The expect partial pixels Z values.
* @return True iff at all GetPartialPixelZ results are the same as the expected Z-coordinates.
*/
bool CheckPartialPixelZ(Slope slope, std::array<int, TILE_SIZE * TILE_SIZE> expected)
bool CheckPartialPixelZ(Slope slope, const std::array<int, TILE_SIZE * TILE_SIZE> &expected)
{
for (uint i = 0; i < expected.size(); i++) {
int actual = GetPartialPixelZ(GB(i, 4, 4), GB(i, 0, 4), slope);