On Mon, Feb 23, 2009 at 02:55:24PM +0900, Nobuyoshi Nakada wrote:
> Hi,
> 
> At Mon, 23 Feb 2009 14:52:26 +0900,
> Aaron Patterson wrote in [ruby-core:22346]:
> > Is there an easy way to set my string enoding from the C api?
> > 
> > rb_str_new2() gives me #<Encoding:ASCII-8BIT>, but I know that the
> > string is UTF-8.
> 
> In include/ruby/encoding.h:
> VALUE rb_enc_str_new(const char*, long, rb_encoding*);

Rock and roll.

教えてくれてありがとう!

Thanks a bunch!

-- 
Aaron Patterson
http://tenderlovemaking.com/