summaryrefslogtreecommitdiff
path: root/src/saveload
diff options
context:
space:
mode:
authorglx <glx@openttd.org>2019-12-17 18:57:53 +0100
committerNiels Martin Hansen <nielsm@indvikleren.dk>2019-12-21 20:13:03 +0100
commit11f178a312d1a601aa14f9188f05f4a4cd033cf9 (patch)
treedfc50d0f6714abfae49305d70842856ec9d75f8e /src/saveload
parentd8a1be48cd60c690235de175e9a044b95f92ea28 (diff)
downloadopenttd-11f178a312d1a601aa14f9188f05f4a4cd033cf9.tar.xz
Codechange: Replace FOR_ALL_STORAGES with range-based for loops
Diffstat (limited to 'src/saveload')
-rw-r--r--src/saveload/storage_sl.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/saveload/storage_sl.cpp b/src/saveload/storage_sl.cpp
index 8c8a96915..7abe396f3 100644
--- a/src/saveload/storage_sl.cpp
+++ b/src/saveload/storage_sl.cpp
@@ -36,10 +36,8 @@ static void Load_PSAC()
/** Save persistent storage data. */
static void Save_PSAC()
{
- PersistentStorage *ps;
-
/* Write the industries */
- FOR_ALL_STORAGES(ps) {
+ for (PersistentStorage *ps : PersistentStorage::Iterate()) {
ps->ClearChanges();
SlSetArrayIndex(ps->index);
SlObject(ps, _storage_desc);