Hi,

At Wed, 25 Feb 2004 23:39:49 +0900,
Sean Russell wrote in [ruby-talk:93644]:
> > I don't think UConv is obsolete, and as for IConv, which is a
> > standard part certainly, also needs another library, libiconv
> > which may not be available on all platform.
> 
> I wasn't aware of this.  I thought iconv was standard now, a
> guaranteed part of the Ruby distribution.

Iconv for ruby is just a wrapper for external iconv library.

> > But current encoding code also doesn't seem thread-safe.  What
> > happens if the context switches between setting the class
> > variable and instance_eval?
> 
> Yes, this needs to be fixed by synchronization.

I feel it is due to unnecessarily introduced thread-shared
resource, a class variable.  Since aliasing method is atomic in
ruby level, the method in [ruby-core:01960] could get rid of
the race conditions if no name clashes, I expect.

-- 
Nobu Nakada