Skip to content

Commit

Permalink
[wasm][debugger] Implementing support to Debugger::Break.
Browse files Browse the repository at this point in the history
  • Loading branch information
thaystg committed Nov 5, 2020
1 parent 8513b8b commit 6855d9b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
7 changes: 7 additions & 0 deletions mono/mini/mini-wasm-debugger.c
Original file line number Diff line number Diff line change
Expand Up @@ -444,6 +444,7 @@ mono_wasm_debugger_init (void)
objrefs = g_hash_table_new_full (NULL, NULL, NULL, mono_debugger_free_objref);

mini_get_dbg_callbacks ()->handle_exception = handle_exception;
mini_get_dbg_callbacks ()->user_break = mono_wasm_user_break;
}

MONO_API void
Expand Down Expand Up @@ -663,6 +664,12 @@ mono_wasm_breakpoint_hit (void)
// mono_wasm_fire_bp ();
}

void
mono_wasm_user_break (void)
{
mono_wasm_fire_bp ();
}

EMSCRIPTEN_KEEPALIVE int
mono_wasm_current_bp_id (void)
{
Expand Down
1 change: 1 addition & 0 deletions mono/mini/mini-wasm.h
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ void mono_wasm_set_timeout (int timeout, int id);

void mono_wasm_single_step_hit (void);
void mono_wasm_breakpoint_hit (void);
void mono_wasm_user_break (void);

int mono_wasm_assembly_already_added (const char *assembly_name);

Expand Down

0 comments on commit 6855d9b

Please sign in to comment.