Home | History | Annotate | Download | only in Support

Lines Matching refs:Regex

1 //===-- Regex.cpp - Regular Expression matcher implementation -------------===//
14 #include "llvm/Support/Regex.h"
22 Regex::Regex(StringRef regex, unsigned Flags) {
25 preg->re_endp = regex.end();
32 error = llvm_regcomp(preg, regex.data(), flags|REG_PEND);
35 Regex::~Regex() {
40 bool Regex::isValid(std::string &Error) {
51 /// getNumMatches - In a valid regex, return the number of parenthesized
53 unsigned Regex::getNumMatches() const {
57 bool Regex::match(StringRef String, SmallVectorImpl<StringRef> *Matches){
96 std::string Regex::sub(StringRef Repl, StringRef String,
172 bool Regex::isLiteralERE(StringRef Str) {
173 // Check for regex metacharacters. This list was derived from our regex