|
From: | Paul Eggert |
Subject: | bug#16481: dfa.c and Rational Range Interpretation |
Date: | Sun, 09 Feb 2014 18:35:50 -0800 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 |
Paolo Bonzini wrote:
The correct course of action for grep is to defer range interpretation to regex, because otherwise you can get mismatches between regexes with backreferences and those without.
It depends on what one means by "correct". POSIX doesn't say what to do in this situation, so it's OK as far as POSIX is concerned for grep to use RRI in the typical case (i.e., without backreferences), and for grep to use some other interpretation in the rare cases when backreferences are used.
The documentation for 'grep' attempts to address this issue, perhaps not as clearly as it could. Maybe the installation instructions should talk about it as well, and suggest --with-included-regex for people who care about this sort of thing.
[Prev in Thread] | Current Thread | [Next in Thread] |