Chromium Code Reviews| Index: runtime/vm/object.cc |
| =================================================================== |
| --- runtime/vm/object.cc (revision 22181) |
| +++ runtime/vm/object.cc (working copy) |
| @@ -4469,6 +4469,9 @@ |
| if (IsLocalFunction()) { |
| const Function& parent = Function::Handle(parent_function()); |
| tmp = parent.QualifiedUserVisibleName(); |
| + if (UserVisibleName() != Symbols::AnonymousClosure().raw()) { |
| + return tmp.raw(); |
| + } |
|
srdjan
2013/04/30 21:46:52
Removed this because it hides closures from nested
|
| } else { |
| return UserVisibleName(); |
| } |
| @@ -12364,7 +12367,14 @@ |
| const char* Array::ToCString() const { |
| - return "Array"; |
| + if (IsNull()) { |
| + return "Array NULL"; |
| + } |
| + const char* format = "Array len:%"Pd""; |
| + intptr_t len = OS::SNPrint(NULL, 0, format, Length()) + 1; |
| + char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); |
| + OS::SNPrint(chars, len, format, Length()); |
| + return chars; |
| } |
| @@ -12429,7 +12439,14 @@ |
| const char* ImmutableArray::ToCString() const { |
| - return "ImmutableArray"; |
| + if (IsNull()) { |
| + return "ImmutableArray NULL"; |
| + } |
| + const char* format = "ImmutableArray len:%"Pd""; |
| + intptr_t len = OS::SNPrint(NULL, 0, format, Length()) + 1; |
| + char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); |
| + OS::SNPrint(chars, len, format, Length()); |
| + return chars; |
| } |
| @@ -12540,7 +12557,14 @@ |
| const char* GrowableObjectArray::ToCString() const { |
| - return "GrowableObjectArray"; |
| + if (IsNull()) { |
| + return "GrowableObjectArray NULL"; |
| + } |
| + const char* format = "GrowableObjectArray len:%"Pd""; |
| + intptr_t len = OS::SNPrint(NULL, 0, format, Length()) + 1; |
| + char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); |
| + OS::SNPrint(chars, len, format, Length()); |
| + return chars; |
| } |