diff options
author | glx <glx@openttd.org> | 2019-12-16 17:53:40 +0100 |
---|---|---|
committer | Niels Martin Hansen <nielsm@indvikleren.dk> | 2019-12-21 20:13:03 +0100 |
commit | f58ce3db19be038e2a0725b2dd28de9d6c27d416 (patch) | |
tree | 013db03bdecb1eee501947ee9650a051dc4c92cb /src/economy.cpp | |
parent | 1f6b3a37f9c39adb22eb61d3153b0c62bfa20551 (diff) | |
download | openttd-f58ce3db19be038e2a0725b2dd28de9d6c27d416.tar.xz |
Codechange: Replace FOR_ALL_GOALS with range-based for loops
Diffstat (limited to 'src/economy.cpp')
-rw-r--r-- | src/economy.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/economy.cpp b/src/economy.cpp index 468111a8e..b0e723c57 100644 --- a/src/economy.cpp +++ b/src/economy.cpp @@ -532,8 +532,7 @@ void ChangeOwnershipOfCompanyItems(Owner old_owner, Owner new_owner) } /* Remove Game Script created Goals, CargoMonitors and Story pages. */ - Goal *g; - FOR_ALL_GOALS(g) { + for (Goal *g : Goal::Iterate()) { if (g->company == old_owner) delete g; } |