summaryrefslogtreecommitdiff
path: root/src/depot_base.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/depot_base.h')
-rw-r--r--src/depot_base.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/depot_base.h b/src/depot_base.h
index b22b7e50f..350eaee8f 100644
--- a/src/depot_base.h
+++ b/src/depot_base.h
@@ -24,7 +24,7 @@ struct Depot : PoolItem<Depot, DepotID, &_Depot_pool> {
Depot *GetDepotByTile(TileIndex tile);
-#define FOR_ALL_DEPOTS_FROM(d, start) for (d = Depot::Get(start); d != NULL; d = (d->index + 1U < Depot::GetPoolSize()) ? Depot::Get(d->index + 1U) : NULL) if (d->IsValid())
-#define FOR_ALL_DEPOTS(d) FOR_ALL_DEPOTS_FROM(d, 0)
+#define FOR_ALL_DEPOTS_FROM(var, start) FOR_ALL_ITEMS_FROM(Depot, depot_index, var, start)
+#define FOR_ALL_DEPOTS(var) FOR_ALL_DEPOTS_FROM(var, 0)
#endif /* DEPOT_BASE_H */