Use C++ iterators for Lists in many situations
This commit is contained in:
parent
b918c4c3ce
commit
4e6efd1b07
218 changed files with 2755 additions and 3004 deletions
|
|
@ -214,8 +214,8 @@ bool Engine::has_singleton(const String &p_name) const {
|
|||
}
|
||||
|
||||
void Engine::get_singletons(List<Singleton> *p_singletons) {
|
||||
for (List<Singleton>::Element *E = singletons.front(); E; E = E->next()) {
|
||||
p_singletons->push_back(E->get());
|
||||
for (Singleton &E : singletons) {
|
||||
p_singletons->push_back(E);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue