From: Christian Neukirchen Date: 2005-03-21T01:45:57+09:00 Subject: Re: Ruby UTF-8 Florian Gross writes: > Nikolai Weibull wrote: > >>>>I'm working with Japanese character sets in Windows. I can save my >>>>*.rb files with notepad using UTF-8 but I can't run them with Ruby. >> >>>The Windows-Editor writes always a "Byte Order Mark" (BOM) at the >>>beginning of UTF-8/16LE/16BE coded files. In this case a UTF-8 coded >>>file begins with "EF BB BF" (hex). These non-characters should usually >>>be ignored (for more information see http://www.unicode.org/). >> Why does it write a BOM for UTF-8 encoded files? It's utterly >> meaningless to discuss byte order for UTF-8 encoded text, > > So that it can identify the file as UTF-8 encoded in the future > without having to guess based on byte count, I assume. > > I think that that behavior makes sense and would like to see it > supported in Ruby. To what extent do BOMs interfere with shebang-lines? -- Christian Neukirchen http://chneukirchen.org