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

Unified Diff: tests/standalone/debugger/closure_debugger_test.dart

Issue 18750004: Faster invocation of fields as methods. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/raw_object.h ('k') | tests/standalone/debugger/nosuchmethod_debugger_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/debugger/closure_debugger_test.dart
===================================================================
--- tests/standalone/debugger/closure_debugger_test.dart (revision 24991)
+++ tests/standalone/debugger/closure_debugger_test.dart (working copy)
@@ -21,8 +21,19 @@
var f = bar;
f("closure call");
bar(12);
+ var a = new A();
+ for (var i = 0; i < 2; ++i) {
+ a.foo(i);
+ }
}
+class A {
+ A() {
+ foo =
+ (x) => print(x);
+ }
+ var foo;
+}
// Expected debugger events and commands.
var testScript = [
@@ -37,5 +48,18 @@
SetBreakpoint(15), // Breakpoint in bar();
Resume(),
MatchFrames(["bar", "main"]),
+ SetBreakpoint(26), // Breakpoint in main() at a.field(i).
+ SetBreakpoint(33), // Breakpoint in closure.
Resume(),
-];
+ MatchFrame(0, "main"), // Should be in main().
+ MatchLocals({"i": "0"}),
+ StepInto(),
+ StepInto(),
+ MatchFrames(["A.<anonymous closure>", "main"]), // In closure function.
+ Resume(),
+ MatchFrame(0, "main"), // Back in main().
+ MatchLocals({"i": "1"}),
+ Resume(),
+ MatchFrames(["A.<anonymous closure>", "main"]), // In closure function.
+ Resume()
+];
« no previous file with comments | « runtime/vm/raw_object.h ('k') | tests/standalone/debugger/nosuchmethod_debugger_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698