diff options
author | Koichi Sasada <ko1@atdot.net> | 2020-10-23 13:27:21 +0900 |
---|---|---|
committer | Koichi Sasada <ko1@atdot.net> | 2020-10-29 23:42:55 +0900 |
commit | 07c03bc30984a496558d9e830bc4fb2f8cfb1854 (patch) | |
tree | 961a2eaa656943974221bbdf8cae28a9116e5f37 /template | |
parent | bf951c763d00a4aee8f8c896d1a97c387fa8f30e (diff) |
check isolated Proc more strictly
Isolated Proc prohibit to access outer local variables, but it was
violated by binding and so on, so they should be error.
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/3721
Diffstat (limited to 'template')
-rw-r--r-- | template/prelude.c.tmpl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/template/prelude.c.tmpl b/template/prelude.c.tmpl index 0ba6b0ba4b..eec8a32da9 100644 --- a/template/prelude.c.tmpl +++ b/template/prelude.c.tmpl @@ -202,7 +202,7 @@ prelude_eval(VALUE code, VALUE name, int line) rb_ast_t *ast = prelude_ast(name, code, line); rb_iseq_eval(rb_iseq_new_with_opt(&ast->body, name, name, Qnil, INT2FIX(line), - NULL, ISEQ_TYPE_TOP, &optimization)); + NULL, 0, ISEQ_TYPE_TOP, &optimization)); rb_ast_dispose(ast); } COMPILER_WARNING_POP |