summaryrefslogtreecommitdiff
path: root/core/debugger
diff options
context:
space:
mode:
Diffstat (limited to 'core/debugger')
-rw-r--r--core/debugger/debugger_marshalls.cpp10
-rw-r--r--core/debugger/local_debugger.cpp6
-rw-r--r--core/debugger/remote_debugger.cpp14
3 files changed, 15 insertions, 15 deletions
diff --git a/core/debugger/debugger_marshalls.cpp b/core/debugger/debugger_marshalls.cpp
index 26f82c2658..2353a6ebf8 100644
--- a/core/debugger/debugger_marshalls.cpp
+++ b/core/debugger/debugger_marshalls.cpp
@@ -40,11 +40,11 @@ Array DebuggerMarshalls::ResourceUsage::serialize() {
Array arr;
arr.push_back(infos.size() * 4);
- for (List<ResourceInfo>::Element *E = infos.front(); E; E = E->next()) {
- arr.push_back(E->get().path);
- arr.push_back(E->get().format);
- arr.push_back(E->get().type);
- arr.push_back(E->get().vram);
+ for (const ResourceInfo &E : infos) {
+ arr.push_back(E.path);
+ arr.push_back(E.format);
+ arr.push_back(E.type);
+ arr.push_back(E.vram);
}
return arr;
}
diff --git a/core/debugger/local_debugger.cpp b/core/debugger/local_debugger.cpp
index ab368471e4..24833711d5 100644
--- a/core/debugger/local_debugger.cpp
+++ b/core/debugger/local_debugger.cpp
@@ -320,13 +320,13 @@ void LocalDebugger::print_variables(const List<String> &names, const List<Varian
String value;
Vector<String> value_lines;
const List<Variant>::Element *V = values.front();
- for (const List<String>::Element *E = names.front(); E; E = E->next()) {
+ for (const String &E : names) {
value = String(V->get());
if (variable_prefix.is_empty()) {
- print_line(E->get() + ": " + String(V->get()));
+ print_line(E + ": " + String(V->get()));
} else {
- print_line(E->get() + ":");
+ print_line(E + ":");
value_lines = value.split("\n");
for (int i = 0; i < value_lines.size(); ++i) {
print_line(variable_prefix + value_lines[i]);
diff --git a/core/debugger/remote_debugger.cpp b/core/debugger/remote_debugger.cpp
index f5595ac037..62d5126e57 100644
--- a/core/debugger/remote_debugger.cpp
+++ b/core/debugger/remote_debugger.cpp
@@ -427,16 +427,16 @@ void RemoteDebugger::_send_resource_usage() {
List<RS::TextureInfo> tinfo;
RS::get_singleton()->texture_debug_usage(&tinfo);
- for (List<RS::TextureInfo>::Element *E = tinfo.front(); E; E = E->next()) {
+ for (const RS::TextureInfo &E : tinfo) {
DebuggerMarshalls::ResourceInfo info;
- info.path = E->get().path;
- info.vram = E->get().bytes;
- info.id = E->get().texture;
+ info.path = E.path;
+ info.vram = E.bytes;
+ info.id = E.texture;
info.type = "Texture";
- if (E->get().depth == 0) {
- info.format = itos(E->get().width) + "x" + itos(E->get().height) + " " + Image::get_format_name(E->get().format);
+ if (E.depth == 0) {
+ info.format = itos(E.width) + "x" + itos(E.height) + " " + Image::get_format_name(E.format);
} else {
- info.format = itos(E->get().width) + "x" + itos(E->get().height) + "x" + itos(E->get().depth) + " " + Image::get_format_name(E->get().format);
+ info.format = itos(E.width) + "x" + itos(E.height) + "x" + itos(E.depth) + " " + Image::get_format_name(E.format);
}
usage.infos.push_back(info);
}