diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2019-02-20 22:24:58 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-20 22:24:58 +0100 |
commit | 8107fc98b6ceae749b3c10e6f0432e904961867b (patch) | |
tree | 6c0ab829b02aba47ff3dc27b9a14d3c3a0658a3b /editor/property_editor.cpp | |
parent | 132e2f458df7a3551a251d68afeccd0362ca6be2 (diff) | |
parent | 8d51618949d5ea8a94e0f504401e8f852a393968 (diff) |
Merge pull request #25853 from marxin/fix-25316-wshadow-local
Add -Wshadow=local to warnings and fix reported issues (#25316).
Diffstat (limited to 'editor/property_editor.cpp')
-rw-r--r-- | editor/property_editor.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/editor/property_editor.cpp b/editor/property_editor.cpp index 46e2bb18fe..c45a97800c 100644 --- a/editor/property_editor.cpp +++ b/editor/property_editor.cpp @@ -905,8 +905,8 @@ bool CustomPropertyEditor::edit(Object *p_owner, const String &p_name, Variant:: List<StringName> inheritors; ClassDB::get_inheriters_from_class(base.strip_edges(), &inheritors); - for (int i = 0; i < custom_resources.size(); i++) { - inheritors.push_back(custom_resources[i].name); + for (int j = 0; j < custom_resources.size(); j++) { + inheritors.push_back(custom_resources[j].name); } List<StringName>::Element *E = inheritors.front(); @@ -915,17 +915,17 @@ bool CustomPropertyEditor::edit(Object *p_owner, const String &p_name, Variant:: E = E->next(); } - for (Set<String>::Element *E = valid_inheritors.front(); E; E = E->next()) { - String t = E->get(); + for (Set<String>::Element *j = valid_inheritors.front(); j; j = j->next()) { + String t = j->get(); bool is_custom_resource = false; Ref<Texture> icon; if (!custom_resources.empty()) { - for (int i = 0; i < custom_resources.size(); i++) { - if (custom_resources[i].name == t) { + for (int k = 0; k < custom_resources.size(); k++) { + if (custom_resources[k].name == t) { is_custom_resource = true; - if (custom_resources[i].icon.is_valid()) - icon = custom_resources[i].icon; + if (custom_resources[k].icon.is_valid()) + icon = custom_resources[k].icon; break; } } |