diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/fbx/fbx_parser/FBXMaterial.cpp | 2 | ||||
-rw-r--r-- | modules/fbx/fbx_parser/FBXParser.h | 2 | ||||
-rw-r--r-- | modules/fbx/fbx_parser/FBXUtil.cpp | 2 | ||||
-rw-r--r-- | modules/gdnavigation/gd_navigation_server.cpp | 10 | ||||
-rw-r--r-- | modules/gdnavigation/nav_map.cpp | 8 | ||||
-rw-r--r-- | modules/gdscript/tests/gdscript_test_runner.cpp | 4 | ||||
-rw-r--r-- | modules/mono/csharp_script.cpp | 4 | ||||
-rw-r--r-- | modules/mono/mono_gd/gd_mono.cpp | 4 |
8 files changed, 18 insertions, 18 deletions
diff --git a/modules/fbx/fbx_parser/FBXMaterial.cpp b/modules/fbx/fbx_parser/FBXMaterial.cpp index 08fff5714a..bf8922267e 100644 --- a/modules/fbx/fbx_parser/FBXMaterial.cpp +++ b/modules/fbx/fbx_parser/FBXMaterial.cpp @@ -325,7 +325,7 @@ Video::Video(uint64_t id, const ElementPtr element, const Document &doc, const s DOMError("embedded content is not surrounded by quotation marks", element); } else { size_t targetLength = 0; - auto numTokens = Content->Tokens().size(); + const size_t numTokens = Content->Tokens().size(); // First time compute size (it could be large like 64Gb and it is good to allocate it once) for (uint32_t tokenIdx = 0; tokenIdx < numTokens; ++tokenIdx) { const Token *dataToken = GetRequiredToken(Content, tokenIdx); diff --git a/modules/fbx/fbx_parser/FBXParser.h b/modules/fbx/fbx_parser/FBXParser.h index bfbcb22ffa..8b248e8791 100644 --- a/modules/fbx/fbx_parser/FBXParser.h +++ b/modules/fbx/fbx_parser/FBXParser.h @@ -160,7 +160,7 @@ public: } ElementPtr FindElementCaseInsensitive(const std::string &elementName) const { - for (auto element = elements.begin(); element != elements.end(); ++element) { + for (FBXDocParser::ElementMap::const_iterator element = elements.begin(); element != elements.end(); ++element) { if (element->first.compare(elementName)) { return element->second; } diff --git a/modules/fbx/fbx_parser/FBXUtil.cpp b/modules/fbx/fbx_parser/FBXUtil.cpp index 4295cb6f5e..1f14a69099 100644 --- a/modules/fbx/fbx_parser/FBXUtil.cpp +++ b/modules/fbx/fbx_parser/FBXUtil.cpp @@ -121,7 +121,7 @@ static const uint8_t base64DecodeTable[128] = { }; uint8_t DecodeBase64(char ch) { - const auto idx = static_cast<uint8_t>(ch); + const uint8_t idx = static_cast<uint8_t>(ch); if (idx > 127) { return 255; } diff --git a/modules/gdnavigation/gd_navigation_server.cpp b/modules/gdnavigation/gd_navigation_server.cpp index 39f208c7a4..88ef434e0f 100644 --- a/modules/gdnavigation/gd_navigation_server.cpp +++ b/modules/gdnavigation/gd_navigation_server.cpp @@ -122,7 +122,7 @@ GdNavigationServer::~GdNavigationServer() { } void GdNavigationServer::add_command(SetCommand *command) const { - auto mut_this = const_cast<GdNavigationServer *>(this); + GdNavigationServer *mut_this = const_cast<GdNavigationServer *>(this); { MutexLock lock(commands_mutex); mut_this->commands.push_back(command); @@ -130,7 +130,7 @@ void GdNavigationServer::add_command(SetCommand *command) const { } RID GdNavigationServer::map_create() const { - auto mut_this = const_cast<GdNavigationServer *>(this); + GdNavigationServer *mut_this = const_cast<GdNavigationServer *>(this); MutexLock lock(mut_this->operations_mutex); NavMap *space = memnew(NavMap); RID rid = map_owner.make_rid(space); @@ -240,7 +240,7 @@ RID GdNavigationServer::map_get_closest_point_owner(RID p_map, const Vector3 &p_ } RID GdNavigationServer::region_create() const { - auto mut_this = const_cast<GdNavigationServer *>(this); + GdNavigationServer *mut_this = const_cast<GdNavigationServer *>(this); MutexLock lock(mut_this->operations_mutex); NavRegion *reg = memnew(NavRegion); RID rid = region_owner.make_rid(reg); @@ -330,7 +330,7 @@ Vector3 GdNavigationServer::region_get_connection_pathway_end(RID p_region, int } RID GdNavigationServer::agent_create() const { - auto mut_this = const_cast<GdNavigationServer *>(this); + GdNavigationServer *mut_this = const_cast<GdNavigationServer *>(this); MutexLock lock(mut_this->operations_mutex); RvoAgent *agent = memnew(RvoAgent()); RID rid = agent_owner.make_rid(agent); @@ -504,7 +504,7 @@ COMMAND_1(free, RID, p_object) { } void GdNavigationServer::set_active(bool p_active) const { - auto mut_this = const_cast<GdNavigationServer *>(this); + GdNavigationServer *mut_this = const_cast<GdNavigationServer *>(this); MutexLock lock(mut_this->operations_mutex); mut_this->active = p_active; } diff --git a/modules/gdnavigation/nav_map.cpp b/modules/gdnavigation/nav_map.cpp index 464082221f..2513c62b6a 100644 --- a/modules/gdnavigation/nav_map.cpp +++ b/modules/gdnavigation/nav_map.cpp @@ -168,7 +168,7 @@ Vector<Vector3> NavMap::get_path(Vector3 p_origin, Vector3 p_destination, bool p const Vector3 new_entry = Geometry3D::get_closest_point_to_segment(least_cost_poly->entry, pathway); const float new_distance = least_cost_poly->entry.distance_to(new_entry) + least_cost_poly->traveled_distance; - auto it = std::find( + const std::vector<gd::NavigationPoly>::iterator it = std::find( navigation_polys.begin(), navigation_polys.end(), gd::NavigationPoly(connection.polygon)); @@ -504,7 +504,7 @@ void NavMap::add_region(NavRegion *p_region) { } void NavMap::remove_region(NavRegion *p_region) { - std::vector<NavRegion *>::iterator it = std::find(regions.begin(), regions.end(), p_region); + const std::vector<NavRegion *>::iterator it = std::find(regions.begin(), regions.end(), p_region); if (it != regions.end()) { regions.erase(it); regenerate_links = true; @@ -524,7 +524,7 @@ void NavMap::add_agent(RvoAgent *agent) { void NavMap::remove_agent(RvoAgent *agent) { remove_agent_as_controlled(agent); - auto it = std::find(agents.begin(), agents.end(), agent); + const std::vector<RvoAgent *>::iterator it = std::find(agents.begin(), agents.end(), agent); if (it != agents.end()) { agents.erase(it); agents_dirty = true; @@ -540,7 +540,7 @@ void NavMap::set_agent_as_controlled(RvoAgent *agent) { } void NavMap::remove_agent_as_controlled(RvoAgent *agent) { - auto it = std::find(controlled_agents.begin(), controlled_agents.end(), agent); + const std::vector<RvoAgent *>::iterator it = std::find(controlled_agents.begin(), controlled_agents.end(), agent); if (it != controlled_agents.end()) { controlled_agents.erase(it); } diff --git a/modules/gdscript/tests/gdscript_test_runner.cpp b/modules/gdscript/tests/gdscript_test_runner.cpp index f53c3046e6..76ae43e792 100644 --- a/modules/gdscript/tests/gdscript_test_runner.cpp +++ b/modules/gdscript/tests/gdscript_test_runner.cpp @@ -441,7 +441,7 @@ GDScriptTest::TestResult GDScriptTest::execute_test_code(bool p_is_generating) { result.output = get_text_for_status(result.status) + "\n"; const List<GDScriptParser::ParserError> &errors = parser.get_errors(); - for (auto *E = errors.front(); E; E = E->next()) { + for (const List<GDScriptParser::ParserError>::Element *E = errors.front(); E; E = E->next()) { result.output += E->get().message + "\n"; // TODO: line, column? break; // Only the first error since the following might be cascading. } @@ -460,7 +460,7 @@ GDScriptTest::TestResult GDScriptTest::execute_test_code(bool p_is_generating) { result.output = get_text_for_status(result.status) + "\n"; const List<GDScriptParser::ParserError> &errors = parser.get_errors(); - for (auto *E = errors.front(); E; E = E->next()) { + for (const List<GDScriptParser::ParserError>::Element *E = errors.front(); E; E = E->next()) { result.output += E->get().message + "\n"; // TODO: line, column? break; // Only the first error since the following might be cascading. } diff --git a/modules/mono/csharp_script.cpp b/modules/mono/csharp_script.cpp index 43f57a7caa..09f3ea1f50 100644 --- a/modules/mono/csharp_script.cpp +++ b/modules/mono/csharp_script.cpp @@ -2016,7 +2016,7 @@ void CSharpInstance::connect_event_signals() { StringName signal_name = event_signal.field->get_name(); // TODO: Use pooling for ManagedCallable instances. - auto event_signal_callable = memnew(EventSignalCallable(owner, &event_signal)); + EventSignalCallable *event_signal_callable = memnew(EventSignalCallable(owner, &event_signal)); Callable callable(event_signal_callable); connected_event_signals.push_back(callable); @@ -2027,7 +2027,7 @@ void CSharpInstance::connect_event_signals() { void CSharpInstance::disconnect_event_signals() { for (const List<Callable>::Element *E = connected_event_signals.front(); E; E = E->next()) { const Callable &callable = E->get(); - auto event_signal_callable = static_cast<const EventSignalCallable *>(callable.get_custom()); + const EventSignalCallable *event_signal_callable = static_cast<const EventSignalCallable *>(callable.get_custom()); owner->disconnect(event_signal_callable->get_signal(), callable); } diff --git a/modules/mono/mono_gd/gd_mono.cpp b/modules/mono/mono_gd/gd_mono.cpp index 560788fb3a..c523d381f6 100644 --- a/modules/mono/mono_gd/gd_mono.cpp +++ b/modules/mono/mono_gd/gd_mono.cpp @@ -119,11 +119,11 @@ void gd_mono_profiler_init() { const String env_var_name = "MONO_ENV_OPTIONS"; if (OS::get_singleton()->has_environment(env_var_name)) { - const auto mono_env_ops = OS::get_singleton()->get_environment(env_var_name); + const String mono_env_ops = OS::get_singleton()->get_environment(env_var_name); // Usually MONO_ENV_OPTIONS looks like: --profile=jb:prof=timeline,ctl=remote,host=127.0.0.1:55467 const String prefix = "--profile="; if (mono_env_ops.begins_with(prefix)) { - const auto ops = mono_env_ops.substr(prefix.length(), mono_env_ops.length()); + const String ops = mono_env_ops.substr(prefix.length(), mono_env_ops.length()); mono_profiler_load(ops.utf8()); } } |