Codechange: Replace assert_compile macro with static_assert

This commit is contained in:
Charles Pigott
2020-12-27 10:44:22 +00:00
parent 395a5d9991
commit 860c270c73
77 changed files with 133 additions and 135 deletions

View File

@@ -37,7 +37,7 @@ AirportTileOverrideManager _airporttile_mngr(NEW_AIRPORTTILE_OFFSET, NUM_AIRPORT
{
/* should be assert(gfx < lengthof(tiles)), but that gives compiler warnings
* since it's always true if the following holds: */
assert_compile(MAX_UVALUE(StationGfx) + 1 == lengthof(tiles));
static_assert(MAX_UVALUE(StationGfx) + 1 == lengthof(tiles));
return &AirportTileSpec::tiles[gfx];
}