Codechange: use "[[maybe_unused]]" instead of a wide variety of other ways we had
While at it, replace OTTD_ASSERT with WITH_ASSERT, as this is always set if assert() is valid. No matter if NDEBUG is set or not.
This commit is contained in:

committed by
Patric Stout

parent
f8dd5dd00a
commit
28e90769f7
@@ -600,9 +600,7 @@ static char *MakeCzechTownName(char *buf, const char *last, uint32 seed)
|
||||
return strecpy(buf, _name_czech_real[SeedModChance(4, lengthof(_name_czech_real), seed)], last);
|
||||
}
|
||||
|
||||
#ifdef WITH_ASSERT
|
||||
const char *orig = buf;
|
||||
#endif
|
||||
[[maybe_unused]] const char *orig = buf;
|
||||
|
||||
/* Probability of prefixes/suffixes
|
||||
* 0..11 prefix, 12..13 prefix+suffix, 14..17 suffix, 18..31 nothing */
|
||||
|
Reference in New Issue
Block a user