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

Unified Diff: test/mjsunit/debug-evaluate-with.js

Issue 6875005: Fix debuger evaluation on a breakpoint inside eval (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/runtime.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/debug-evaluate-with.js
===================================================================
--- test/mjsunit/debug-evaluate-with.js (revision 7630)
+++ test/mjsunit/debug-evaluate-with.js (working copy)
@@ -42,13 +42,13 @@
// Break point in first with block.
assertEquals(2, exec_state.frame(0).evaluate('a').value());
assertEquals(2, exec_state.frame(0).evaluate('b').value());
- } else {
+ } else if (breakPointCount == 2) {
// Break point in second with block.
assertEquals(3, exec_state.frame(0).evaluate('a').value());
assertEquals(1, exec_state.frame(0).evaluate('b').value());
-
- // Indicate that all was processed.
- listenerComplete = true;
+ } else if (breakPointCount == 3) {
+ // Break point in eval with block.
+ assertEquals('local', exec_state.frame(0).evaluate('foo').value());
}
}
} catch (e) {
@@ -72,6 +72,10 @@
};
f();
+
+var foo = "global";
+eval("with({bar:'with'}) { (function g() { var foo = 'local'; debugger; })(); }");
+
// Make sure that the debug event listener vas invoked.
-assertTrue(listenerComplete);
+assertEquals(3, breakPointCount);
assertFalse(exception, "exception in listener")
« no previous file with comments | « src/runtime.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698