Merge: Codechange: Use null pointer literal instead of the NULL macro

This commit is contained in:
Jonathan G Rennison
2019-04-11 18:14:13 +01:00
585 changed files with 6604 additions and 6604 deletions

View File

@@ -233,7 +233,7 @@ struct SpecializedStation : public BaseStation {
*/
static inline T *GetIfValid(size_t index)
{
return IsValidID(index) ? Get(index) : NULL;
return IsValidID(index) ? Get(index) : nullptr;
}
/**
@@ -270,7 +270,7 @@ struct SpecializedStation : public BaseStation {
};
#define FOR_ALL_BASE_STATIONS_OF_TYPE(name, var) \
for (size_t station_index = 0; var = NULL, station_index < name::GetPoolSize(); station_index++) \
if ((var = name::GetIfValid(station_index)) != NULL)
for (size_t station_index = 0; var = nullptr, station_index < name::GetPoolSize(); station_index++) \
if ((var = name::GetIfValid(station_index)) != nullptr)
#endif /* BASE_STATION_BASE_H */