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

Issue 12472: Added a debugger call to run a JavaScript function in the debugger. When call... (Closed)

Created:
12 years ago by Søren Thygesen Gjesse
Modified:
9 years, 7 months ago
CC:
v8-dev
Visibility:
Public.

Description

Added a debugger call to run a JavaScript function in the debugger. When called the debugger will be entered and the JavaScript function will be called with the debugger ExecutionState object as its first parameter. This makes it possible to get information like current line number, current script resource, backtrace information etc. which is not part of the normal API. Committed: http://code.google.com/p/v8/source/detail?r=854

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+223 lines, -0 lines) Patch
M include/v8-debug.h View 1 2 1 chunk +20 lines, -0 lines 0 comments Download
M src/api.cc View 1 1 chunk +20 lines, -0 lines 0 comments Download
M src/debug.h View 1 2 chunks +7 lines, -0 lines 0 comments Download
M src/debug.cc View 1 1 chunk +24 lines, -0 lines 0 comments Download
M test/cctest/test-debug.cc View 1 1 chunk +152 lines, -0 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Søren Thygesen Gjesse
12 years ago (2008-11-26 14:31:49 UTC) #1
Mads Ager (chromium)
LGTM. Maybe you can add a test that shows what happens if you pass in ...
12 years ago (2008-11-26 15:02:42 UTC) #2
Søren Thygesen Gjesse
Added a function which captures a context variable as an additional test. http://codereview.chromium.org/12472/diff/1/4 File src/api.cc ...
12 years ago (2008-11-26 19:53:11 UTC) #3
Christian Plesner Hansen
Lgtm http://codereview.chromium.org/12472/diff/9/210 File include/v8-debug.h (right): http://codereview.chromium.org/12472/diff/9/210#newcode132 Line 132: // Run a JavaScript function in the ...
12 years ago (2008-11-27 07:09:08 UTC) #4
Søren Thygesen Gjesse
12 years ago (2008-11-27 08:01:36 UTC) #5
http://codereview.chromium.org/12472/diff/9/210
File include/v8-debug.h (right):

http://codereview.chromium.org/12472/diff/9/210#newcode132
Line 132: // Run a JavaScript function in the debugger.
On 2008/11/27 07:09:08, Christian Plesner Hansen wrote:
> From this comment it's not obvious what this means, exactly.  Is it just a way
> to get your hands on the execution state?  What would people use this for?

Added some documentation including a simple sample for getting the current line
of JavaScript executing.

Powered by Google App Engine
This is Rietveld 408576698