Index: runtime/vm/object.cc |
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc |
index d92562b8489e103e6084159d5cb24c62589eea1d..dddc632d809aa31303a7c81e9b3260de3b472c76 100644 |
--- a/runtime/vm/object.cc |
+++ b/runtime/vm/object.cc |
@@ -13712,7 +13712,12 @@ void Context::Dump(int indent) const { |
for (intptr_t i = 0; i < num_variables(); i++) { |
IndentN(indent + 2); |
obj = At(i); |
- THR_Print("[%" Pd "] = %s\n", i, obj.ToCString()); |
+ const char* s = obj.ToCString(); |
+ if (strlen(s) > 50) { |
+ THR_Print("[%" Pd "] = [first 50 chars:] %.50s...\n", i, s); |
+ } else { |
+ THR_Print("[%" Pd "] = %s\n", i, s); |
+ } |
} |
const Context& parent_ctx = Context::Handle(parent()); |