diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-09-27 05:34:41 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-09-27 05:34:41 +0000 |
commit | 99902a451b3f12ddd61dc6d8249362795f419298 (patch) | |
tree | e07fa4f59f6f4aca979494bdce713b8d2cafbe6c /iseq.c | |
parent | 5e77410451410e3ce349b10486ecbfd60b2ff98f (diff) | |
download | ruby-99902a451b3f12ddd61dc6d8249362795f419298.tar.gz |
iseq.c: file name encoding
* iseq.c (iseqw_s_compile): keep the encoding of file name.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r-- | iseq.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -817,19 +817,17 @@ iseqw_s_compile_file(int argc, VALUE *argv, VALUE self) VALUE parser; VALUE f; NODE *node; - const char *fname; rb_compile_option_t option; rb_secure(1); rb_scan_args(argc, argv, "11", &file, &opt); FilePathValue(file); file = rb_fstring(file); /* rb_io_t->pathv gets frozen anyways */ - fname = StringValueCStr(file); f = rb_file_open_str(file, "r"); parser = rb_parser_new(); - node = rb_parser_compile_file(parser, fname, f, NUM2INT(line)); + node = rb_parser_compile_file_path(parser, file, f, NUM2INT(line)); rb_io_close(f); |