From 4e6efd1b07f1c6d53d226977ddc729333b74306a Mon Sep 17 00:00:00 2001 From: Aaron Franke Date: Thu, 15 Jul 2021 23:45:57 -0400 Subject: Use C++ iterators for Lists in many situations --- core/config/engine.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core/config/engine.cpp') diff --git a/core/config/engine.cpp b/core/config/engine.cpp index ad31966a65..c03c872f17 100644 --- a/core/config/engine.cpp +++ b/core/config/engine.cpp @@ -214,8 +214,8 @@ bool Engine::has_singleton(const String &p_name) const { } void Engine::get_singletons(List *p_singletons) { - for (List::Element *E = singletons.front(); E; E = E->next()) { - p_singletons->push_back(E->get()); + for (Singleton &E : singletons) { + p_singletons->push_back(E); } } -- cgit v1.2.3