On Jul 7, 2012, at 1:46 PM, Tom Lane <t...@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 conversion is largely untested, but 
it's also pretty simple code.  Sure, it could have bugs, but so could whatever 
work-around you cobble together to avoid back-patching it.  And it's not like 
we'll break anything else, either: the code will only be used in the case that 
is buggy right now anyway.

...Robert
-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to