You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
688 B

name: duk_get_c_function
proto: |
duk_c_function duk_get_c_function(duk_context *ctx, duk_idx_t index);
stack: |
[ ... val! ... ]
summary: |
<p>Get the Duktape/C function pointer (a <code>duk_c_function</code>) from an
Ecmascript function object associated with a Duktape/C function. If the
value is not such a function or <code>index</code> is invalid, returns <code>NULL</code>.</p>
<p>If you prefer an error to be thrown for an invalid value or index, use
<code><a href="#duk_require_c_function">duk_require_c_function()</a></code>.</p>
example: |
duk_c_function funcptr;
funcptr = duk_get_c_function(ctx, -3);
tags:
- stack
- function
introduced: 1.0.0