|
|
@ -1,5 +1,5 @@ |
|
|
|
=proto |
|
|
|
void duk_debugger_attach(duk_context *ctx, duk_debug_read_function read_cb, duk_debug_write_function write_cb, void *udata); |
|
|
|
void duk_debugger_attach(duk_context *ctx, duk_debug_read_function read_cb, duk_debug_write_function write_cb, duk_debug_peek_function peek_cb, duk_debug_read_flush_function read_flush_cb, duk_debug_write_flush_function write_flush_cb, duk_debug_detached_function detached_cb, void *udata); |
|
|
|
|
|
|
|
=summary |
|
|
|
<p>Attach a debugger to the Duktape heap. If debugger support is not |
|
|
@ -7,10 +7,19 @@ compiled into Duktape, throws an error. See |
|
|
|
<a href="https://github.com/svaarala/duktape/blob/master/doc/debugger.rst">debugger.rst</a> |
|
|
|
for more information.</p> |
|
|
|
|
|
|
|
<p>The <code>read_cb</code> and <code>write_cb</code> callbacks are mandatory. |
|
|
|
The <code>peek_cb</code> is strongly recommended but optional. The |
|
|
|
<code>read_flush_cb</code> and <code>write_flush_cb</code> callbacks are |
|
|
|
optional. Unimplemented callbacks are indicated using a <code>NULL</code>.</p> |
|
|
|
|
|
|
|
=example |
|
|
|
duk_debugger_attach(ctx, |
|
|
|
my_read_cb, |
|
|
|
my_write_cb, |
|
|
|
my_peek_cb, |
|
|
|
NULL, |
|
|
|
NULL, |
|
|
|
my_detached_cb, |
|
|
|
my_udata); |
|
|
|
|
|
|
|
=tags |
|
|
@ -21,4 +30,4 @@ experimental |
|
|
|
duk_debugger_detach |
|
|
|
|
|
|
|
=introduced |
|
|
|
1.1.0 |
|
|
|
1.2.0 |
|
|
|