name: duk_is_object proto: | duk_bool_t duk_is_object(duk_context *ctx, duk_idx_t index); stack: | [ ... val! ... ] summary: |

Returns 1 if value at index is an object, otherwise returns 0. If index is invalid, also returns 0.

Note that many values are considered to be an object, e.g.:

Specific object types can be checked with separate API calls, e.g. duk_is_array().

example: | if (duk_is_object(ctx, -3)) { /* ... */ } tags: - stack - object introduced: 1.0.0