From 31f790299c1649680b48c00230e89318d864624f Mon Sep 17 00:00:00 2001 From: Lyuma Date: Thu, 26 Aug 2021 20:46:51 -0700 Subject: Use OrderedHashMap for autoloads to preserve order --- modules/gdscript/editor/gdscript_highlighter.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'modules/gdscript/editor') diff --git a/modules/gdscript/editor/gdscript_highlighter.cpp b/modules/gdscript/editor/gdscript_highlighter.cpp index 8b9bd2659d..ab441d194a 100644 --- a/modules/gdscript/editor/gdscript_highlighter.cpp +++ b/modules/gdscript/editor/gdscript_highlighter.cpp @@ -471,9 +471,9 @@ void GDScriptSyntaxHighlighter::_update_cache() { } /* Autoloads. */ - Map autoloads = ProjectSettings::get_singleton()->get_autoload_list(); - for (Map::Element *E = autoloads.front(); E; E = E->next()) { - const ProjectSettings::AutoloadInfo &info = E->value(); + OrderedHashMap autoloads = ProjectSettings::get_singleton()->get_autoload_list(); + for (OrderedHashMap::Element E = autoloads.front(); E; E = E.next()) { + const ProjectSettings::AutoloadInfo &info = E.value(); if (info.is_singleton) { keywords[info.name] = usertype_color; } -- cgit v1.2.3