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

Unified Diff: test/cctest/test-debug.cc

Issue 43130: Fix the handling of line offset when getting the source line from a ScriptMirror (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 9 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/mirror-delay.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-debug.cc
===================================================================
--- test/cctest/test-debug.cc (revision 1480)
+++ test/cctest/test-debug.cc (working copy)
@@ -3720,6 +3720,17 @@
// Test that a function with closure can be run in the debugger.
v8::Script::Compile(v8::String::New("CheckClosure()"))->Run();
+
+
+ // Test that the source line is correct when there is a line offset.
+ v8::ScriptOrigin origin(v8::String::New("test"),
+ v8::Integer::New(7));
+ v8::Script::Compile(v8::String::New("CheckSourceLine(7)"), &origin)->Run();
+ v8::Script::Compile(v8::String::New("function f() {\n"
+ " CheckSourceLine(8)\n"
+ " CheckSourceLine(9)\n"
+ " CheckSourceLine(10)\n"
+ "}; f()"), &origin)->Run();
}
« no previous file with comments | « src/mirror-delay.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698