Home | History | Annotate | Download | only in FileCheck

Lines Matching defs:Pattern

49 // Pattern Handling Code.
52 class Pattern {
55 /// MatchEOF - When set, this pattern only matches the end of file. This is
59 /// FixedStr - If non-empty, this pattern is a fixed string match with the
63 /// RegEx - If non-empty, this is a regex pattern.
67 /// pattern, e.g. "foo[[bar]]baz". In this case, the RegExStr will contain
73 /// the pattern, e.g. "foo[[bar:.*]]baz". In this case, the RegExStr will
80 Pattern(bool matchEOF = false) : MatchEOF(matchEOF) { }
84 /// Match - Match the pattern string against the input buffer Buffer. This
94 /// involving this pattern.
103 /// matching this pattern at the start of \arg Buffer; a distance of zero
110 bool Pattern::ParsePattern(StringRef PatternStr, SourceMgr &SM) {
137 // Otherwise, there is at least one regex piece. Build up the regex pattern
237 void Pattern::AddFixedStringToRegEx(StringRef FixedStr, std::string &TheStr) {
264 bool Pattern::AddRegExToRegEx(StringRef RegexStr, unsigned &CurParen,
279 /// Match - Match the pattern string against the input buffer Buffer. This
282 size_t Pattern::Match(StringRef Buffer, size_t &MatchLen,
284 // If this is the EOF pattern, match it immediately.
290 // If this is a fixed string pattern, just match it now.
347 unsigned Pattern::ComputeMatchDistance(StringRef Buffer,
365 void Pattern::PrintFailureInfo(const SourceMgr &SM, StringRef Buffer,
405 // looking for something which looks like a pattern.
438 /// Pat - The pattern to match.
439 Pattern Pat;
451 std::vector<std::pair<SMLoc, Pattern> > NotStrings;
453 CheckString(const Pattern &P, SMLoc L, bool isCheckNext)
516 std::vector<std::pair<SMLoc, Pattern> > NotMatches;
555 // Remember the location of the start of the pattern, for diagnostics.
558 // Parse the pattern.
559 Pattern P;
589 // Add an EOF pattern for any trailing CHECK-NOTs.
591 CheckStrings.push_back(CheckString(Pattern(true),
620 // Allow the pattern to print additional information if desired.
749 CheckPrefix+"-NOT: pattern specified here", "note");