Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
- IO::Scalar doesn't do binmode?
September 23, 2005, 4:28 pm
rate this thread
I was playing with Lingua::RU::Number, and noticed that it could only
output WINDOWS-1251 character set. Well, no problem, I think, I'll just
wrap it with IO::Scalar and let the encoding abstraction handle the
conversion to UTF8 for me.
So, I did this:
perl -MLingua::RU::Number=rur_in_words -MIO::Scalar \
$s=new IO::Scalar $win; \
And got WINDOWS-1251 output again. Did I miss something, or is
IO::Scalar not supporting encoding conversion via binmode?
Re: IO::Scalar doesn't do binmode?
With 5.8.x, there's no need to use IO::Scalar. You can use open() on a
scalar variable (i.e. open($fh, "<", $variable)). I suppose that all
PerlIO is available in this case.
Slaven Rezic - slaven <at> rezic <dot> de
Tired of using file selectors? Real programmers use the TAB key for
completion and not for jumping around. Try
- » what modules best for communicationg with a UART with cygwin
- — Next thread in » PERL Modules Announcements