[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug in grep handling [^^] (not caret) character class
From: |
Ivan Heffner |
Subject: |
bug in grep handling [^^] (not caret) character class |
Date: |
Tue, 20 Jul 2004 14:35:39 -0700 |
grep (v2.4.2) appears to have a problem trying to match [^^].
Expected:
If I have a file foo.txt that contains lines with a single character on
each line, I should be able to find all lines that do not contain a
caret by doing
grep '^[^^]$' foo.txt
Actual:
This command returns lines that contain a single caret. In fact, if I
have all alpha-numeric and standard US symbols by them selves on
different lines, this grep will only return
$ grep '^[^^]$' foo.txt
^
-
[end]
Ivan Heffner
- bug in grep handling [^^] (not caret) character class,
Ivan Heffner <=