On Wed 14 Feb 2007 at 23:42:10 +0900, Ian Macdonald wrote: > On Wed 14 Feb 2007 at 18:00:22 +0900, Robert Klemme wrote: > > > Another idea: maybe the readline lib interferes with encodings somehow > > in IRB? What happens if you invoke your script from within IRB via "load"? > > It runs as if run from the command line: > > irb(main):001:0> load 'foo' > 2 > 2 I beg your pardon. I must have had the locale set incorrectly on that run. It runs as if typed interactively into irb: $ irb irb(main):001:0> load 'foo' nil 2 Ian -- Ian Macdonald | A small town that cannot support one lawyer ian / caliban.org | can always support two. http://www.caliban.org/ | | |