1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-28 08:25:07 +00:00

LibCore: Include object names in Object::dump_tree() output

This commit is contained in:
Andreas Kling 2020-09-14 13:00:51 +02:00
parent 2e547ce7a3
commit aa3c28957a

View file

@ -155,7 +155,10 @@ void Object::dump_tree(int indent)
for (int i = 0; i < indent; ++i) {
printf(" ");
}
printf("%s{%p}\n", class_name(), this);
printf("%s{%p}", class_name(), this);
if (!name().is_null())
printf(" %s", name().characters());
printf("\n");
for_each_child([&](auto& child) {
child.dump_tree(indent + 2);