From: ts Date: 2003-11-13T19:39:20+09:00 Subject: Re: problems with rb_str_split() >>>>> "I" == Ian Macdonald writes: I> So, it was just a bug in 1.8.0? Unfortunately, that's still the latest I> official version, so I'm stuck with the issue at work for the time I> being. svg% diff -u aa.c~ aa.c --- aa.c~ 2003-11-13 11:34:19.000000000 +0100 +++ aa.c 2003-11-13 11:37:33.000000000 +0100 @@ -2,11 +2,14 @@ void Init_aa() { - VALUE res; + VALUE res, rv; const char *comma_sp = ", "; int i; + rv = ruby_verbose; + ruby_verbose = Qnil; res = rb_str_split(rb_str_new2("abc, def"), ", "); + ruby_verbose = rv; for (i = 0; i < RARRAY(res)->len; i++) { rb_warn("found %s", StringValuePtr(RARRAY(res)->ptr[i])); } svg% svg% ruby -raa -vwe 1 ruby 1.8.0 (2003-08-04) [i686-linux] ./aa.so: warning: found abc ./aa.so: warning: found def -e:1: warning: useless use of a literal in void context svg% Guy Decoux