Re: UTF8 with BOM support in psql
От | Itagaki Takahiro |
---|---|
Тема | Re: UTF8 with BOM support in psql |
Дата | |
Msg-id | 20091117093151.14F2.52131E4D@oss.ntt.co.jp обсуждение исходный текст |
Ответ на | Re: UTF8 with BOM support in psql (Peter Eisentraut <peter_e@gmx.net>) |
Ответы |
Re: UTF8 with BOM support in psql
Re: UTF8 with BOM support in psql Re: UTF8 with BOM support in psql |
Список | pgsql-hackers |
Peter Eisentraut <peter_e@gmx.net> wrote: > OK, I think the consensus here is: > - Eat BOM at beginning of file (as you implemented) > - Only when client encoding is UTF-8 --> please fix that Are they AND condition? If so, this patch will be useless. Please remember \encoding or SET client_encoding appear *after* BOM at beginning of file. I'll agree if the condition is "Eat BOM at beginning of file and <<set client encoding to UTF-8>>", like: Defining Python Source Code Encodings: http://www.python.org/dev/peps/pep-0263/ > I'm not sure if replacing a BOM by three spaces is a good way to > implement "eating", because it might throw off a column indicator > somewhere, say, but I couldn't reproduce a problem. Note that the U > +FEFF character is defined as *zero-width* non-breaking space. I assumed psql discards whitespaces automatically, but I see it is more robust to remove BOM bytes explitly. I'll fix it. Regards, --- ITAGAKI Takahiro NTT Open Source Software Center
В списке pgsql-hackers по дате отправления: