Re: regex_fixed_prefix() is still a few bricks shy of a load

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: regex_fixed_prefix() is still a few bricks shy of a load
Дата
Msg-id E9AC540E-516E-49F8-B07C-379E100F3B48@gmail.com
обсуждение исходный текст
Ответ на regex_fixed_prefix() is still a few bricks shy of a load  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: regex_fixed_prefix() is still a few bricks shy of a load  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Jul 7, 2012, at 1:46 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> 3. Try another approach entirely.  The idea that I've got in mind here
> is to compile the regex using the regex library and then look at the
> compiled NFA representation to see if there must be a fixed prefix.
> I would not have risked this before this year, but after last winter's
> expeditions into the darkest corners of the regex library I feel
> competent to do it, and some quick study suggests that it might not take
> very much code to produce something that is significantly brighter than
> what we have now.  However, there are a couple of arguments against
> pursuing this path:

I think this is clearly the best way forward, probably even in the back branches.  It's true that the wchar to mb
conversionis largely untested, but it's also pretty simple code.  Sure, it could have bugs, but so could whatever
work-aroundyou cobble together to avoid back-patching it.  And it's not like we'll break anything else, either: the
codewill only be used in the case that is buggy right now anyway. 

...Robert

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: Schema version management
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Schema version management