Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(67)

Side by Side Diff: runtime/vm/compiler_test.cc

Issue 249533003: Support evaluation of expressions in context of a stack frame (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/lib/mirrors.cc ('k') | runtime/vm/debugger.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // TODO(zra): Remove when tests are ready to enable. 5 // TODO(zra): Remove when tests are ready to enable.
6 #include "platform/globals.h" 6 #include "platform/globals.h"
7 #if !defined(TARGET_ARCH_ARM64) 7 #if !defined(TARGET_ARCH_ARM64)
8 8
9 #include "platform/assert.h" 9 #include "platform/assert.h"
10 #include "vm/class_finalizer.h" 10 #include "vm/class_finalizer.h"
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 Dart_Invoke(lib, Dart_NewStringFromCString("makeObj"), 0, NULL); 87 Dart_Invoke(lib, Dart_NewStringFromCString("makeObj"), 0, NULL);
88 EXPECT(!Dart_IsNull(obj_handle)); 88 EXPECT(!Dart_IsNull(obj_handle));
89 EXPECT(!Dart_IsError(obj_handle)); 89 EXPECT(!Dart_IsError(obj_handle));
90 const Object& obj = Object::Handle(Api::UnwrapHandle(obj_handle)); 90 const Object& obj = Object::Handle(Api::UnwrapHandle(obj_handle));
91 EXPECT(!obj.IsNull()); 91 EXPECT(!obj.IsNull());
92 EXPECT(obj.IsInstance()); 92 EXPECT(obj.IsInstance());
93 93
94 String& expr_text = String::Handle(); 94 String& expr_text = String::Handle();
95 expr_text = String::New("apa + ' ${calc(10)}' + dot"); 95 expr_text = String::New("apa + ' ${calc(10)}' + dot");
96 Object& val = Object::Handle(); 96 Object& val = Object::Handle();
97 val = Instance::Cast(obj).Evaluate(expr_text); 97 val = Instance::Cast(obj).Evaluate(expr_text,
98 Array::empty_array(),
99 Array::empty_array());
98 EXPECT(!val.IsNull()); 100 EXPECT(!val.IsNull());
99 EXPECT(!val.IsError()); 101 EXPECT(!val.IsError());
100 EXPECT(val.IsString()); 102 EXPECT(val.IsString());
101 EXPECT_STREQ("Herr Nilsson 100.", val.ToCString()); 103 EXPECT_STREQ("Herr Nilsson 100.", val.ToCString());
102 } 104 }
103 105
104 } // namespace dart 106 } // namespace dart
105 107
106 #endif // !defined(TARGET_ARCH_ARM64) 108 #endif // !defined(TARGET_ARCH_ARM64)
OLDNEW
« no previous file with comments | « runtime/lib/mirrors.cc ('k') | runtime/vm/debugger.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698