[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Patch for lookaround assertion in regexp
From: |
Štěpán Němec |
Subject: |
Re: Patch for lookaround assertion in regexp |
Date: |
Mon, 23 Jan 2012 19:45:00 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) |
On Mon, 23 Jan 2012 18:11:26 +0100
Stefan Monnier wrote:
>>> If it doesn't then it's a job for the translation layer. Char syntaxes
>>> and categories could be converted into the standard [...] format.
>> Enumerating the syntax/category members is not an option.
>
> Indeed.
>
>> There is no easy way to do that.
>
> For `categories', there is a way, but the result is a *very* large [...]
> chunk, so it's impractical. For `syntax' there is indeed no way, since
> the syntax of a char doesn't only depend on the char itself but also of
> the `char-table' text-property that might be applied to that particular
> character position (and of course, if we ignore this problem, we're
> still back to the same problem of enormous [...] expressions, as is the
> case for categories).
> These entities really need to be implemented inside the regexp-engine
> (but they're usually pretty easy to implement there).
OTOH using something like PCRE would finally fix the currently erroneous
implementation of classes like [:space:], which now is the same as \s-.
(And personally I would gladly forgo the syntax categories for standard
[:classes:], although I imagine the former might be used by the
font-locking or somewhere... I never felt the need for them.)
--
Štěpán
- Patch for lookaround assertion in regexp, Colin Fraizer, 2012/01/23
- Re: Patch for lookaround assertion in regexp, Stefan Monnier, 2012/01/23
- Re: Patch for lookaround assertion in regexp, Tom, 2012/01/23
- Re: Patch for lookaround assertion in regexp, Andreas Schwab, 2012/01/23
- Re: Patch for lookaround assertion in regexp, Tom, 2012/01/23
- Re: Patch for lookaround assertion in regexp, Andreas Schwab, 2012/01/23
- Re: Patch for lookaround assertion in regexp, Stefan Monnier, 2012/01/23
- Re: Patch for lookaround assertion in regexp,
Štěpán Němec <=
- Re: Patch for lookaround assertion in regexp, Juri Linkov, 2012/01/29
- Re: Patch for lookaround assertion in regexp, Stefan Monnier, 2012/01/23
Re: Patch for lookaround assertion in regexp, Nikolai Weibull, 2012/01/24
Re: Patch for lookaround assertion in regexp, David De La Harpe Golden, 2012/01/24
Re: Patch for lookaround assertion in regexp, Nikolai Weibull, 2012/01/25