From a2d520d7508dfdec271a7c69e618eb2c1dd0685f Mon Sep 17 00:00:00 2001 From: Sami Vaarala Date: Wed, 16 Aug 2017 00:03:43 +0300 Subject: [PATCH] API doc fix for duk_push_proxy() flags --- website/api/duk_push_proxy.yaml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/website/api/duk_push_proxy.yaml b/website/api/duk_push_proxy.yaml index 9f1fc5650d..54db095871 100644 --- a/website/api/duk_push_proxy.yaml +++ b/website/api/duk_push_proxy.yaml @@ -1,14 +1,16 @@ name: duk_push_proxy proto: | - duk_idx_t duk_push_proxy(duk_context *ctx); + duk_idx_t duk_push_proxy(duk_context *ctx, duk_uint_t proxy_flags); stack: | [ ... target! handler! ] -> [ ... proxy! ] summary: |

Push a new Proxy object for target and handler table given on the value - stack, equivalent to new Proxy(target, handler).

+ stack, equivalent to new Proxy(target, handler). The + proxy_flags argument is currently (Duktape 2.2) unused, calling + code must pass in a zero.

example: | duk_idx_t proxy_idx; @@ -17,7 +19,7 @@ example: | duk_push_object(ctx); /* handler */ duk_push_c_function(ctx, my_get, 3); /* 'get' trap */ duk_put_prop_string(ctx, -2, "get"); - proxy_idx = duk_push_proxy(ctx); /* [ target handler ] -> [ proxy ] */ + proxy_idx = duk_push_proxy(ctx, 0); /* [ target handler ] -> [ proxy ] */ tags: - stack