summaryrefslogtreecommitdiff
path: root/vm_eval.c
diff options
context:
space:
mode:
author卜部昌平 <shyouhei@ruby-lang.org>2019-09-03 12:18:36 +0900
committer卜部昌平 <shyouhei@ruby-lang.org>2019-09-03 14:43:08 +0900
commite913fa94d30e5d3007fe52f5d7840576c0f86c78 (patch)
tree6e612002ab94eb25ba4f78e16c002efbcc32225e /vm_eval.c
parent1a9cc3b27c020c33c87d8b4fe659243aacfeedf3 (diff)
downloadruby-e913fa94d30e5d3007fe52f5d7840576c0f86c78.tar.gz
delete ruby_eval_string_from_file_protect
Not used from anywhere.
Diffstat (limited to 'vm_eval.c')
-rw-r--r--vm_eval.c21
1 files changed, 0 insertions, 21 deletions
diff --git a/vm_eval.c b/vm_eval.c
index a31f4865ed..e0c308ab76 100644
--- a/vm_eval.c
+++ b/vm_eval.c
@@ -1429,27 +1429,6 @@ ruby_eval_string_from_file(const char *str, const char *filename)
return eval_string_with_cref(rb_vm_top_self(), rb_str_new2(str), NULL, file, 1);
}
-struct eval_string_from_file_arg {
- VALUE str;
- VALUE filename;
-};
-
-static VALUE
-eval_string_from_file_helper(VALUE data)
-{
- const struct eval_string_from_file_arg *const arg = (struct eval_string_from_file_arg*)data;
- return eval_string_with_cref(rb_vm_top_self(), arg->str, NULL, arg->filename, 1);
-}
-
-VALUE
-ruby_eval_string_from_file_protect(const char *str, const char *filename, int *state)
-{
- struct eval_string_from_file_arg arg;
- arg.str = rb_str_new_cstr(str);
- arg.filename = filename ? rb_str_new_cstr(filename) : 0;
- return rb_protect(eval_string_from_file_helper, (VALUE)&arg, state);
-}
-
/**
* Evaluates the given string in an isolated binding.
*