From c63b18507d21b8a213c073bced9057b571cdcd7a Mon Sep 17 00:00:00 2001
From: Lightning_A <aaronjrecord@gmail.com>
Date: Mon, 9 Aug 2021 14:13:42 -0600
Subject: Use range iterators for `Map`

---
 servers/rendering/shader_warnings.cpp | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

(limited to 'servers/rendering/shader_warnings.cpp')

diff --git a/servers/rendering/shader_warnings.cpp b/servers/rendering/shader_warnings.cpp
index 0c1d6408c9..0b8476478c 100644
--- a/servers/rendering/shader_warnings.cpp
+++ b/servers/rendering/shader_warnings.cpp
@@ -119,10 +119,10 @@ ShaderWarning::CodeFlags ShaderWarning::get_flags_from_codemap(const Map<Code, b
 		init_code_to_flags_map();
 	}
 
-	for (Map<Code, bool>::Element *E = p_map.front(); E; E = E->next()) {
-		if (E->get()) {
-			ERR_FAIL_COND_V(!code_to_flags_map->has((int)E->key()), ShaderWarning::NONE_FLAG);
-			result |= (*code_to_flags_map)[(int)E->key()];
+	for (const KeyValue<Code, bool> &E : p_map) {
+		if (E.value) {
+			ERR_FAIL_COND_V(!code_to_flags_map->has((int)E.key), ShaderWarning::NONE_FLAG);
+			result |= (*code_to_flags_map)[(int)E.key];
 		}
 	}
 	return (CodeFlags)result;
-- 
cgit v1.2.3