summaryrefslogtreecommitdiff
path: root/utils/FileCheck
diff options
context:
space:
mode:
authorMatt Arsenault <Matthew.Arsenault@amd.com>2013-09-17 23:15:35 +0000
committerMatt Arsenault <Matthew.Arsenault@amd.com>2013-09-17 23:15:35 +0000
commitc61c8116212c68ebc81a9dc06327d6cc806b1f08 (patch)
tree7743ab60b5bddd158a7c3ff0184887ef38973f02 /utils/FileCheck
parent53bb26f61c65b6f63e9aa2950429bb889683bc11 (diff)
downloadllvm-c61c8116212c68ebc81a9dc06327d6cc806b1f08.tar.gz
llvm-c61c8116212c68ebc81a9dc06327d6cc806b1f08.tar.bz2
llvm-c61c8116212c68ebc81a9dc06327d6cc806b1f08.tar.xz
Missed using check type enum in one place
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190897 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/FileCheck')
-rw-r--r--utils/FileCheck/FileCheck.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/utils/FileCheck/FileCheck.cpp b/utils/FileCheck/FileCheck.cpp
index c91565378b..120fdd7283 100644
--- a/utils/FileCheck/FileCheck.cpp
+++ b/utils/FileCheck/FileCheck.cpp
@@ -609,7 +609,7 @@ struct CheckString {
: Pat(P), Loc(L), CheckTy(Ty) {}
/// Check - Match check string and its "not strings" and/or "dag strings".
- size_t Check(const SourceMgr &SM, StringRef Buffer, bool IsLabel,
+ size_t Check(const SourceMgr &SM, StringRef Buffer,
size_t &MatchLen, StringMap<StringRef> &VariableTable) const;
/// CheckNext - Verify there is a single line in the given buffer.
@@ -874,12 +874,12 @@ static unsigned CountNumNewlinesBetween(StringRef Range) {
}
size_t CheckString::Check(const SourceMgr &SM, StringRef Buffer,
- bool IsLabel, size_t &MatchLen,
+ size_t &MatchLen,
StringMap<StringRef> &VariableTable) const {
size_t LastPos = 0;
std::vector<const Pattern *> NotStrings;
- if (!IsLabel) {
+ if (CheckTy != Check::CheckLabel) {
// Match "dag strings" (with mixed "not strings" if any).
LastPos = CheckDag(SM, Buffer, NotStrings, VariableTable);
if (LastPos == StringRef::npos)
@@ -895,7 +895,7 @@ size_t CheckString::Check(const SourceMgr &SM, StringRef Buffer,
}
MatchPos += LastPos;
- if (!IsLabel) {
+ if (CheckTy != Check::CheckLabel) {
StringRef SkippedRegion = Buffer.substr(LastPos, MatchPos);
// If this check is a "CHECK-NEXT", verify that the previous match was on
@@ -1119,7 +1119,7 @@ int main(int argc, char **argv) {
// Scan to next CHECK-LABEL match, ignoring CHECK-NOT and CHECK-DAG
size_t MatchLabelLen = 0;
- size_t MatchLabelPos = CheckLabelStr.Check(SM, Buffer, true,
+ size_t MatchLabelPos = CheckLabelStr.Check(SM, Buffer,
MatchLabelLen, VariableTable);
if (MatchLabelPos == StringRef::npos) {
hasError = true;
@@ -1137,7 +1137,7 @@ int main(int argc, char **argv) {
// Check each string within the scanned region, including a second check
// of any final CHECK-LABEL (to verify CHECK-NOT and CHECK-DAG)
size_t MatchLen = 0;
- size_t MatchPos = CheckStr.Check(SM, CheckRegion, false, MatchLen,
+ size_t MatchPos = CheckStr.Check(SM, CheckRegion, MatchLen,
VariableTable);
if (MatchPos == StringRef::npos) {