From: nobu.nakada@... Date: 2002-03-04T22:34:20+09:00 Subject: [ruby-dev:16208] Re: Defining (Python) Source Code Encoding なかだです。 At Mon, 4 Mar 2002 02:24:20 +0900, Nobuyoshi-Nakada wrote: > なるほど。とりあえず合わせてみますか。ってかなり手抜き。 これを忘れてました。 Index: parse.y =================================================================== RCS file: /cvs/ruby/src/ruby/parse.y,v retrieving revision 1.156 diff -u -2 -p -r1.156 parse.y --- parse.y 2002/02/20 04:31:50 1.156 +++ parse.y 2002/03/04 12:59:09 @@ -2098,4 +2098,5 @@ yycompile(f, line) int n; NODE *node = 0; + const char *kcode_save; if (!compile_for_eval && rb_safe_level() == 0 && @@ -2121,4 +2122,5 @@ yycompile(f, line) } + kcode_save = rb_get_kcode(); ruby__end__seen = 0; ruby_eval_tree = 0; @@ -2137,4 +2139,5 @@ yycompile(f, line) in_def = 0; cur_mid = 0; + rb_set_kcode(kcode_save); if (n == 0) node = ruby_eval_tree; -- --- 僕の前にBugはない。 --- 僕の後ろにBugはできる。 中田 伸悦