diff options
author | Chris Lattner <sabre@nondot.org> | 2009-09-21 02:30:42 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-09-21 02:30:42 +0000 |
commit | 81115765218f1c1505ab6faf843ee4baf292d45f (patch) | |
tree | 75c445eb9d7e38fadbfd943ba1fb15ab3afb0648 /utils/FileCheck | |
parent | 06e483dae04b0ad714f9d8bb0a929b98720bf483 (diff) |
fix a FileCheck bug where:
; CHECK: foo
; CHECK-NOT: foo
; CHECK: bar
would always fail.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82424 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/FileCheck')
-rw-r--r-- | utils/FileCheck/FileCheck.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/utils/FileCheck/FileCheck.cpp b/utils/FileCheck/FileCheck.cpp index 8f48c3a0cf..a6c1f74f6d 100644 --- a/utils/FileCheck/FileCheck.cpp +++ b/utils/FileCheck/FileCheck.cpp @@ -361,10 +361,10 @@ int main(int argc, char **argv) { } - // Otherwise, everything is good. Remember this as the last match and move - // on to the next one. - LastMatch = Buffer.data(); + // Otherwise, everything is good. Step over the matched text and remember + // the position after the match as the end of the last match. Buffer = Buffer.substr(CheckStr.Str.size()); + LastMatch = Buffer.data(); } return 0; |