summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2022-05-21 01:38:39 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2022-05-21 02:41:20 -0700
commita368a60eb81ea6e3264e0c8c2cb12f2ee7f0585d (patch)
treebb635fe6a73b75f387af5f4ede2bf8c98d0b5a1d /doc
parent2169fa36c9235d13bf64e20009fc3a639ca5670a (diff)
downloadgrep-a368a60eb81ea6e3264e0c8c2cb12f2ee7f0585d.tar.gz
grep: assume POSIX.1-2017 for [:space:]
* src/dfasearch.c (dfawarn): Always call dfaerror now, regardless of POSIXLY_CORRECT. * tests/warn-char-classes: Omit test of POSIX.1-2008 behavior, since POSIX.1-2017 allows the GNU behavior.
Diffstat (limited to 'doc')
-rw-r--r--doc/grep.texi8
1 files changed, 2 insertions, 6 deletions
diff --git a/doc/grep.texi b/doc/grep.texi
index b073fa76..71e19e04 100644
--- a/doc/grep.texi
+++ b/doc/grep.texi
@@ -1056,8 +1056,6 @@ follow file names must be treated as file names;
by default,
such options are permuted to the front of the operand list
and are treated as options.
-Also, @env{POSIXLY_CORRECT} disables special handling of an
-invalid bracket expression. @xref{invalid-bracket-expr}.
@item _@var{N}_GNU_nonoption_argv_flags_
@vindex _@var{N}_GNU_nonoption_argv_flags_ @r{environment variable}
@@ -1401,12 +1399,10 @@ Note that the brackets in these class names are
part of the symbolic names, and must be included in addition to
the brackets delimiting the bracket expression.
-@anchor{invalid-bracket-expr}
If you mistakenly omit the outer brackets, and search for say, @samp{[:upper:]},
GNU @command{grep} prints a diagnostic and exits with status 2, on
-the assumption that you did not intend to search for the nominally
-equivalent regular expression: @samp{[:epru]}.
-Set the @env{POSIXLY_CORRECT} environment variable to disable this feature.
+the assumption that you did not intend to search for the
+regular expression @samp{[:epru]}.
Special characters lose their special meaning inside bracket expressions.