From: Gary Wright Date: 2007-09-30T13:44:55+09:00 Subject: Re: String.force_encoding On Sep 29, 2007, at 3:07 AM, Martin Duerst wrote: > At 13:39 07/09/29, David Flanagan wrote: > >> I don't want to re-open a discussion if this decision has already >> been firmly made. > > It's not completely firm yet, it's just that Nobu had some code to > check > in, and needed a name, and it's better to start with a long and > strange > name and make it shorter if that's necessary than the other way round. In my quick look at the source it seems that str.encoding returns the current encoding of str. So my own POLS would suggest str.encoding = "binary" to change the encoding. It just seems completely non-Ruby-like to have: str.force_encoding("binary") Gary Wright