about summary refs log tree commit diff stats
path: root/lib/quickjs/quickjs.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/quickjs/quickjs.c')
-rw-r--r--lib/quickjs/quickjs.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/quickjs/quickjs.c b/lib/quickjs/quickjs.c
index e6a5d2e9..ffc4977f 100644
--- a/lib/quickjs/quickjs.c
+++ b/lib/quickjs/quickjs.c
@@ -30216,8 +30216,7 @@ static void add_eval_variables(JSContext *ctx, JSFunctionDef *s)
                 /* do not close top level last result */
                 if (vd->scope_level == 0 &&
                     vd->var_name != JS_ATOM__ret_ &&
-                    vd->var_name != JS_ATOM_NULL &&
-                    (!has_this_binding || vd->var_name != JS_ATOM_this)) {
+                    vd->var_name != JS_ATOM_NULL) {
                     get_closure_var(ctx, s, fd,
                                     FALSE, i, vd->var_name, FALSE, FALSE,
                                     JS_VAR_NORMAL);