Skip to content

Add finish debugger command. #2240

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 12, 2018
Merged

Add finish debugger command. #2240

merged 1 commit into from
Mar 12, 2018

Conversation

knightburton
Copy link
Member

With this command the engine continue running just after the function
in the current stack frame returns.

JerryScript-DCO-1.0-Signed-off-by: Imre Kiss [email protected]

@@ -35,7 +35,7 @@
* debugger versioning.
*/
JERRY_STATIC_ASSERT (JERRY_DEBUGGER_MESSAGES_OUT_MAX_COUNT == 27
&& JERRY_DEBUGGER_MESSAGES_IN_MAX_COUNT == 18
&& JERRY_DEBUGGER_MESSAGES_IN_MAX_COUNT == 19
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please increase the ERRY_DEBUGGER_VERSION number.

JERRY_DEBUGGER_CHECK_PACKET_SIZE (jerry_debugger_receive_type_t);

JERRY_DEBUGGER_SET_FLAGS (JERRY_DEBUGGER_VM_STOP);
JERRY_CONTEXT (debugger_stop_context) = JERRY_CONTEXT (vm_top_context_p->prev_context_p);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is worth a comment to describe the NULL case (and why this code is correct).

@@ -1367,6 +1368,7 @@ <h2>JerryScript HTML (WebSocket) Debugger Client</h2>
" continue|c - continue execution\n" +
" step|s - step-in execution\n" +
" next|n - execution until the next breakpoint\n" +
" finish|f - continue running just after function in the current stack frame returns\n" +
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comment: continue running until the current function returns

@@ -286,6 +287,13 @@ def do_next(self, args):

do_n = do_next

def do_finish(self, args):
""" Continue running just after function in the current stack frame returns """
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ditto.

finish
step
finish
continue
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

last one could be a finish as well

@knightburton
Copy link
Member Author

@zherczeg I've updated the PR based on your requests.

Copy link
Member

@zherczeg zherczeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

With this command the engine continue running just after the function
in the current stack frame returns.

JerryScript-DCO-1.0-Signed-off-by: Imre Kiss [email protected]
Copy link
Contributor

@LaszloLango LaszloLango left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@LaszloLango LaszloLango merged commit a79c217 into jerryscript-project:master Mar 12, 2018
@martijnthe
Copy link
Contributor

For future changes: I think it would have been nicer to not shuffle the existing message enums.
That way it would be a bit easier for a client to support multiple versions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants