Re: [HACKERS] plperl and regexps with accented characters - incompatible?

From: "Greg Sabino Mullane" <greg(at)turnstep(dot)com>
To: andrew(at)dunslane(dot)net
Cc: pgsql-general(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [HACKERS] plperl and regexps with accented characters - incompatible?
Date: 2007-11-14 02:58:42
Message-ID: 14996936d2b5e8add6e180348fb2c490@biglumber.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers pgsql-patches


-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160

> Ugh, in testing I see some nastiness here without any explicit
> require. It looks like there's an implicit require if the text
> contains certain chars.

Exactly.

> Looks like it's going to be very hard, unless someone has some
> brilliant insight I'm missing :-(

The only way I see around it is to do:

$PLContainer->permit('require');
...
$PLContainer->reval('use utf8;');
...
$PLContainer->deny('require');"

Not ideal. Part of me says we do this because something like //i
shouldn't suddenly fail just because you added an accented
character. The other part of me says to just have people use plperlu.
At the very least, we should probably mention it in the docs as
a gotcha.

- --
Greg Sabino Mullane greg(at)turnstep(dot)com
End Point Corporation
PGP Key: 0x14964AC8 200711132155
http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8

-----BEGIN PGP SIGNATURE-----

iD8DBQFHOmQLvJuQZxSWSsgRA6bJAKDX9tN6ridD6aP8PywuUOUKRnHFvQCeJizW
Rcq+43grmuckX1I4Rm75eTU=
=3cmn
-----END PGP SIGNATURE-----

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Andrew Dunstan 2007-11-14 03:03:40 Re: [HACKERS] plperl and regexps with accented characters - incompatible?
Previous Message Merlin Moncure 2007-11-14 02:44:07 Re: Insert statements really slow

Browse pgsql-hackers by date

  From Date Subject
Next Message Merlin Moncure 2007-11-14 03:02:59 Re: How to keep a table in memory?
Previous Message Andrew Dunstan 2007-11-14 02:58:27 Re: Simplifying Text Search

Browse pgsql-patches by date

  From Date Subject
Next Message Andrew Dunstan 2007-11-14 03:03:40 Re: [HACKERS] plperl and regexps with accented characters - incompatible?
Previous Message Jan Urbański 2007-11-14 02:48:02 Re: a tsearch2 (8.2.4) dictionary that only filters out stopwords