Index: runtime/vm/service_test.cc |
=================================================================== |
--- runtime/vm/service_test.cc (revision 37860) |
+++ runtime/vm/service_test.cc (working copy) |
@@ -89,7 +89,7 @@ |
}; |
-static RawInstance* Eval(Dart_Handle lib, const char* expr) { |
+static RawArray* Eval(Dart_Handle lib, const char* expr) { |
Dart_Handle expr_val = Dart_EvaluateExpr(lib, NewString(expr)); |
EXPECT_VALID(expr_val); |
Isolate* isolate = Isolate::Current(); |
@@ -107,7 +107,7 @@ |
} |
-static RawInstance* EvalF(Dart_Handle lib, const char* fmt, ...) { |
+static RawArray* EvalF(Dart_Handle lib, const char* fmt, ...) { |
Isolate* isolate = Isolate::Current(); |
va_list args; |
@@ -181,7 +181,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// Get the isolate summary. |
service_msg = Eval(lib, "[0, port, [], [], []]"); |
@@ -232,7 +232,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// Get the stacktrace. |
service_msg = Eval(lib, "[0, port, ['stacktrace'], [], []]"); |
@@ -272,7 +272,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// Add a breakpoint. |
const String& url = String::Handle(String::New(TestCase::url())); |
@@ -380,7 +380,7 @@ |
EXPECT_VALID(valid_id); |
EXPECT_VALID(Dart_SetField(lib, NewString("validId"), valid_id)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// null |
service_msg = Eval(lib, "[0, port, ['objects', 'null'], [], []]"); |
@@ -641,7 +641,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// Request library. |
service_msg = EvalF(h_lib, |
@@ -707,7 +707,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// Request an invalid class id. |
service_msg = Eval(h_lib, "[0, port, ['classes', '999999'], [], []]"); |
@@ -890,7 +890,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// Request the class A over the service. |
service_msg = EvalF(h_lib, "[0, port, ['classes', '%" Pd "'], [], []]", cid); |
@@ -996,7 +996,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// Request an invalid code object. |
service_msg = Eval(h_lib, "[0, port, ['code', '0'], [], []]"); |
@@ -1100,7 +1100,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(lib, "[0, port, ['vm'], [], []]"); |
Service::HandleRootMessage(service_msg); |
@@ -1132,7 +1132,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(lib, "[0, port, ['flags'], [], []]"); |
// Make sure we can get the FlagList. |
@@ -1181,7 +1181,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(h_lib, "[0, port, ['scripts', 'test-lib'], [], []]"); |
Service::HandleIsolateMessage(isolate, service_msg); |
handler.HandleNextMessage(); |
@@ -1224,7 +1224,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(h_lib, "[0, port, ['coverage'], [], []]"); |
Service::HandleIsolateMessage(isolate, service_msg); |
handler.HandleNextMessage(); |
@@ -1263,7 +1263,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval( |
h_lib, "[0, port, ['scripts', 'test-lib', 'coverage'], [], []]"); |
Service::HandleIsolateMessage(isolate, service_msg); |
@@ -1317,7 +1317,7 @@ |
OS::SNPrint(buf, sizeof(buf), |
"[0, port, ['libraries', '%" Pd "', 'coverage'], [], []]", i); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(h_lib, buf); |
Service::HandleIsolateMessage(isolate, service_msg); |
handler.HandleNextMessage(); |
@@ -1379,7 +1379,7 @@ |
OS::SNPrint(buf, sizeof(buf), |
"[0, port, ['classes', '%" Pd "', 'coverage'], [], []]", i); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(h_lib, buf); |
Service::HandleIsolateMessage(isolate, service_msg); |
handler.HandleNextMessage(); |
@@ -1420,7 +1420,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(h_lib, "[0, port, ['allocationprofile'], [], []]"); |
Service::HandleIsolateMessage(isolate, service_msg); |
handler.HandleNextMessage(); |
@@ -1487,7 +1487,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(lib, "[0, port, ['heapmap'], [], []]"); |
Service::HandleIsolateMessage(isolate, service_msg); |
handler.HandleNextMessage(); |
@@ -1515,7 +1515,7 @@ |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
const String& str = String::Handle(String::New("foobar", Heap::kOld)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
// Note: If we ever introduce old space compaction, this test might fail. |
uword start_addr = RawObject::ToAddr(str.raw()); |
// Expect to find 'str', also from internal addresses. |
@@ -1592,7 +1592,7 @@ |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(lib, "[0, port, ['alpha'], [], []]"); |
Service::HandleRootMessage(service_msg); |
handler.HandleNextMessage(); |
@@ -1629,7 +1629,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(lib, "[0, port, ['alpha'], [], []]"); |
Service::HandleIsolateMessage(isolate, service_msg); |
handler.HandleNextMessage(); |
@@ -1670,7 +1670,7 @@ |
EXPECT_VALID(port); |
EXPECT_VALID(Dart_SetField(h_lib, NewString("port"), port)); |
- Instance& service_msg = Instance::Handle(); |
+ Array& service_msg = Array::Handle(); |
service_msg = Eval(h_lib, "[0, port, ['profile'], [], []]"); |
Service::HandleIsolateMessage(isolate, service_msg); |
handler.HandleNextMessage(); |