mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* parse.y (ripper_initialize): too early to set parser->enc.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15114 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
5e0824bcd8
commit
956666cf5a
2 changed files with 7 additions and 1 deletions
|
@ -1,3 +1,7 @@
|
|||
Fri Jan 18 20:19:51 2008 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
|
||||
* parse.y (ripper_initialize): too early to set parser->enc.
|
||||
|
||||
Fri Jan 18 20:03:05 2008 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
|
||||
* win32/setup.mak (BASERUBY): nmake cannot execute ruby collectly
|
||||
|
|
4
parse.y
4
parse.y
|
@ -9677,7 +9677,6 @@ ripper_initialize(int argc, VALUE *argv, VALUE self)
|
|||
else {
|
||||
StringValue(src);
|
||||
parser->parser_lex_gets = lex_get_str;
|
||||
parser->enc = rb_enc_get(src);
|
||||
}
|
||||
parser->parser_lex_input = src;
|
||||
parser->eofp = Qfalse;
|
||||
|
@ -9690,6 +9689,9 @@ ripper_initialize(int argc, VALUE *argv, VALUE self)
|
|||
rb_str_append(fname2, fname);
|
||||
}
|
||||
parser_initialize(parser);
|
||||
if (parser->parser_lex_gets == lex_get_str) {
|
||||
parser->enc = rb_enc_get(src);
|
||||
}
|
||||
|
||||
parser->parser_ruby_sourcefile_string = fname2;
|
||||
parser->parser_ruby_sourcefile = RSTRING_PTR(fname2)+1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue