/external/regex-re2/re2/testing/ |
D | parse_test.cc | 14 static const Regexp::ParseFlags TestZeroFlags = Regexp::ParseFlags(1<<30); 19 Regexp::ParseFlags flags; 22 static Regexp::ParseFlags kTestFlags = Regexp::MatchNL | 23 Regexp::PerlX | 24 Regexp::PerlClasses | 25 Regexp::UnicodeGroups; 152 { "[^ ]", "cc{0-0x9 0xb-0x1f 0x21-0x10ffff}", Regexp::FoldCase }, 153 { "[^ ]", "cc{0-0x9 0xb-0x1f 0x21-0x10ffff}", Regexp::NeverNL }, 154 { "[^ ]", "cc{0-0x9 0xb-0x1f 0x21-0x10ffff}", Regexp::NeverNL | Regexp::FoldCase }, 156 { "[^ \f]", "cc{0-0x9 0xb 0xd-0x1f 0x21-0x10ffff}", Regexp::FoldCase }, [all …]
|
D | regexp_test.cc | 15 TEST(Regexp, BigRef) { in TEST() argument 16 Regexp* re; in TEST() 17 re = Regexp::Parse("x", Regexp::NoParseFlags, NULL); in TEST() 28 TEST(Regexp, BigConcat) { in TEST() argument 29 Regexp* x; in TEST() 30 x = Regexp::Parse("x", Regexp::NoParseFlags, NULL); in TEST() 31 vector<Regexp*> v(90000, x); // ToString bails out at 100000 in TEST() 35 Regexp* re = Regexp::Concat(&v[0], v.size(), Regexp::NoParseFlags); in TEST() 42 TEST(Regexp, NamedCaptures) { in TEST() argument 43 Regexp* x; in TEST() [all …]
|
D | regexp_benchmark.cc | 24 Regexp* re = Regexp::Parse("(\\d+)-(\\d+)-(\\d+)", Regexp::LikePerl, NULL); in Test() 46 Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); in MemoryUsage() 568 Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); in ParseRegexp() 576 Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); in SimplifyRegexp() 578 Regexp* sre = re->Simplify(); in SimplifyRegexp() 586 Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); in NullWalkRegexp() 596 Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); in SimplifyCompileRegexp() 598 Regexp* sre = re->Simplify(); in SimplifyCompileRegexp() 610 Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); in CompileRegexp() 620 Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); in CompileToProg() [all …]
|
D | dfa_test.cc | 45 Regexp* re = Regexp::Parse(s.c_str(), Regexp::LikePerl, NULL); in TEST() 60 Regexp* re = Regexp::Parse(s.c_str(), Regexp::LikePerl, NULL); in TEST() 96 Regexp* re = Regexp::Parse(s.c_str(), Regexp::LikePerl, NULL); in TEST() 184 Regexp* re = Regexp::Parse(StringPrintf("0[01]{%d}$", n), in TEST() 185 Regexp::LikePerl, NULL); in TEST() 266 Regexp* re = Regexp::Parse(StringPrintf("0[01]{%d}$", n), in TEST() 267 Regexp::LikePerl, NULL); in TEST() 328 Regexp* re = Regexp::Parse(t.regexp, Regexp::LikePerl, NULL); in TEST()
|
D | compile_test.cc | 108 Regexp* re = Regexp::Parse(t.regexp, Regexp::PerlX|Regexp::Latin1, NULL); in TEST() 159 Regexp* re = Regexp::Parse(".", Regexp::PerlX, NULL); in TEST()
|
D | simplify_test.cc | 145 Regexp* re = Regexp::Parse(tests[i].regexp, in TEST() 146 Regexp::MatchNL | (Regexp::LikePerl & in TEST() 147 ~Regexp::OneLine), in TEST() 150 Regexp* sre = re->Simplify(); in TEST()
|
D | required_prefix_test.cc | 43 Regexp::ParseFlags flags = Regexp::LikePerl; in TEST() 45 flags = flags | Regexp::Latin1; in TEST() 46 Regexp* re = Regexp::Parse(t.regexp, flags, NULL); in TEST() 50 Regexp* s = NULL; in TEST()
|
D | null_walker.cc | 13 class NullWalker : public Regexp::Walker<bool> { 16 bool PostVisit(Regexp* re, bool parent_arg, bool pre_arg, 19 bool ShortVisit(Regexp* re, bool a) { in ShortVisit() 33 bool NullWalker::PostVisit(Regexp* re, bool parent_arg, bool pre_arg, in PostVisit() 39 void Regexp::NullWalk() { in NullWalk()
|
D | mimics_pcre_test.cc | 63 Regexp::ParseFlags flags = Regexp::LikePerl; in TEST() 65 flags = flags | Regexp::Latin1; in TEST() 66 Regexp* re = Regexp::Parse(t.regexp, flags, NULL); in TEST()
|
D | tester.cc | 135 Regexp::ParseFlags parse_flags; 139 static const Regexp::ParseFlags single_line = 140 Regexp::LikePerl; 141 static const Regexp::ParseFlags multi_line = 142 static_cast<Regexp::ParseFlags>(Regexp::LikePerl & ~Regexp::OneLine); 146 { single_line|Regexp::Latin1, "single-line, latin1" }, 148 { multi_line|Regexp::NonGreedy, "multiline, nongreedy" }, 149 { multi_line|Regexp::Latin1, "multiline, latin1" }, 152 static string FormatMode(Regexp::ParseFlags flags) { in FormatMode() 162 Regexp::ParseFlags flags) in TestInstance() [all …]
|
D | dump.cc | 57 static void DumpRegexpAppending(Regexp* re, string* s) { in DumpRegexpAppending() 68 if (re->parse_flags() & Regexp::NonGreedy) in DumpRegexpAppending() 73 if (re->op() == kRegexpLiteral && (re->parse_flags() & Regexp::FoldCase)) { in DumpRegexpAppending() 78 if (re->op() == kRegexpLiteralString && (re->parse_flags() & Regexp::FoldCase)) { in DumpRegexpAppending() 93 if (!(re->parse_flags() & Regexp::WasDollar)) { in DumpRegexpAppending() 151 string Regexp::Dump() { in Dump()
|
D | tester.h | 19 class Regexp; variable 55 Regexp::ParseFlags flags); 57 Regexp::ParseFlags flags() { return flags_; } in flags() 77 Regexp::ParseFlags flags_; // flags for parsing regexp_str_ 80 Regexp* regexp_; // parsed regexp
|
/external/regex-re2/re2/ |
D | simplify.cc | 18 bool Regexp::SimplifyRegexp(const StringPiece& src, ParseFlags flags, in SimplifyRegexp() 21 Regexp* re = Parse(src, flags, status); in SimplifyRegexp() 24 Regexp* sre = re->Simplify(); in SimplifyRegexp() 42 bool Regexp::ComputeSimple() { in ComputeSimple() 43 Regexp** subs; in ComputeSimple() 103 class SimplifyWalker : public Regexp::Walker<Regexp*> { 106 virtual Regexp* PreVisit(Regexp* re, Regexp* parent_arg, bool* stop); 107 virtual Regexp* PostVisit(Regexp* re, 108 Regexp* parent_arg, 109 Regexp* pre_arg, [all …]
|
D | regexp.h | 267 class Regexp { 319 Regexp** sub() { in sub() 337 Regexp* Incref(); 345 static Regexp* Parse(const StringPiece& s, ParseFlags flags, 355 Regexp* Simplify(); 386 static Regexp* Plus(Regexp* sub, ParseFlags flags); 387 static Regexp* Star(Regexp* sub, ParseFlags flags); 388 static Regexp* Quest(Regexp* sub, ParseFlags flags); 389 static Regexp* Concat(Regexp** subs, int nsubs, ParseFlags flags); 390 static Regexp* Alternate(Regexp** subs, int nsubs, ParseFlags flags); [all …]
|
D | regexp.cc | 16 Regexp::Regexp(RegexpOp op, ParseFlags parse_flags) in Regexp() function in re2::Regexp 32 Regexp::~Regexp() { in ~Regexp() 54 bool Regexp::QuickDestroy() { in QuickDestroy() 62 static map<Regexp*, int> *ref_map; 65 int Regexp::Ref() { in Ref() 79 Regexp* Regexp::Incref() { in Incref() 84 ref_map = new map<Regexp*, int>; in Incref() 103 void Regexp::Decref() { in Decref() 123 void Regexp::Destroy() { in Destroy() 130 Regexp* stack = this; in Destroy() [all …]
|
D | parse.cc | 44 class Regexp::ParseState { 60 bool PushRegexp(Regexp* re); 104 Regexp* DoFinish(); 109 Regexp* FinishRegexp(Regexp*); 118 bool ParseCharClass(StringPiece* s, Regexp** out_re, 155 Regexp* stacktop_; 166 Regexp::ParseState::ParseState(ParseFlags flags, in ParseState() 178 Regexp::ParseState::~ParseState() { in ~ParseState() 179 Regexp* next; in ~ParseState() 180 for (Regexp* re = stacktop_; re != NULL; re = next) { in ~ParseState() [all …]
|
D | walker-inl.h | 22 template<typename T> class Regexp::Walker { 36 virtual T PreVisit(Regexp* re, T parent_arg, bool* stop); 47 virtual T PostVisit(Regexp* re, T parent_arg, T pre_arg, 62 virtual T ShortVisit(Regexp* re, T parent_arg) = 0; 67 T Walk(Regexp* re, T top_arg); 77 T WalkExponential(Regexp* re, T top_arg, int max_visits); 93 T WalkInternal(Regexp* re, T top_arg, bool use_copy); 98 template<typename T> T Regexp::Walker<T>::PreVisit(Regexp* re, in PreVisit() 104 template<typename T> T Regexp::Walker<T>::PostVisit(Regexp* re, in PostVisit() 112 template<typename T> T Regexp::Walker<T>::Copy(T arg) { in Copy() [all …]
|
D | set.cc | 34 Regexp::ParseFlags pf = static_cast<Regexp::ParseFlags>( in Add() 38 re2::Regexp* re = Regexp::Parse(pattern, pf, &status); in Add() 49 re2::Regexp* m = re2::Regexp::HaveMatch(n, pf); in Add() 52 re2::Regexp** sub = new re2::Regexp*[nsub + 1]; in Add() 57 re = re2::Regexp::Concat(sub, nsub + 1, pf); in Add() 60 re2::Regexp* sub[2]; in Add() 63 re = re2::Regexp::Concat(sub, 2, pf); in Add() 76 Regexp::ParseFlags pf = static_cast<Regexp::ParseFlags>( in Compile() 78 re2::Regexp* re = re2::Regexp::Alternate(const_cast<re2::Regexp**>(&re_[0]), in Compile() 81 re2::Regexp* sre = re->Simplify(); in Compile()
|
D | mimics_pcre.cc | 32 static bool CanBeEmptyString(Regexp *re); 37 class PCREWalker : public Regexp::Walker<bool> { 40 bool PostVisit(Regexp* re, bool parent_arg, bool pre_arg, bool* child_args, 43 bool ShortVisit(Regexp* re, bool a) { in ShortVisit() 53 bool PCREWalker::PostVisit(Regexp* re, bool parent_arg, bool pre_arg, in PostVisit() 83 if (re->parse_flags() & Regexp::WasDollar) in PostVisit() 101 bool Regexp::MimicsPCRE() { in MimicsPCRE() 114 class EmptyStringWalker : public Regexp::Walker<bool> { 117 bool PostVisit(Regexp* re, bool parent_arg, bool pre_arg, 120 bool ShortVisit(Regexp* re, bool a) { in ShortVisit() [all …]
|
D | tostring.cc | 31 class ToStringWalker : public Regexp::Walker<int> { 35 virtual int PreVisit(Regexp* re, int parent_arg, bool* stop); 36 virtual int PostVisit(Regexp* re, int parent_arg, int pre_arg, 38 virtual int ShortVisit(Regexp* re, int parent_arg) { in ShortVisit() 48 string Regexp::ToString() { in ToString() 61 int ToStringWalker::PreVisit(Regexp* re, int parent_arg, bool* stop) { in PreVisit() 139 int ToStringWalker::PostVisit(Regexp* re, int parent_arg, int pre_arg, in PostVisit() 157 AppendLiteral(t_, re->rune(), re->parse_flags() & Regexp::FoldCase); in PostVisit() 162 AppendLiteral(t_, re->runes()[i], re->parse_flags() & Regexp::FoldCase); in PostVisit() 185 if (re->parse_flags() & Regexp::NonGreedy) in PostVisit() [all …]
|
D | compile.cc | 122 class Compiler : public Regexp::Walker<Frag> { 131 static Prog *Compile(Regexp* re, bool reversed, int64 max_mem); 136 Regexp* re); 146 Frag PreVisit(Regexp* re, Frag parent_arg, bool* stop); 147 Frag PostVisit(Regexp* re, Frag parent_arg, Frag pre_arg, Frag* child_args, 149 Frag ShortVisit(Regexp* re, Frag parent_arg); 211 void Setup(Regexp::ParseFlags, int64, RE2::Anchor); 676 Frag Compiler::ShortVisit(Regexp* re, Frag) { in ShortVisit() 682 Frag Compiler::PreVisit(Regexp* re, Frag, bool* stop) { in PreVisit() 713 Frag Compiler::PostVisit(Regexp* re, Frag, Frag, Frag* child_frags, in PostVisit() [all …]
|
/external/llvm/lib/Support/ |
D | SpecialCaseList.cpp | 107 std::string Regexp = SplitRegexp.first; in parse() local 111 if (Regex::isLiteralERE(Regexp)) { in parse() 112 Entries[Prefix][Category].Strings.insert(Regexp); in parse() 117 for (size_t pos = 0; (pos = Regexp.find("*", pos)) != std::string::npos; in parse() 119 Regexp.replace(pos, strlen("*"), ".*"); in parse() 123 Regex CheckRE(Regexp); in parse() 134 Regexps[Prefix][Category] += "^" + Regexp + "$"; in parse()
|
/external/libxml2/result/regexp/ |
D | ranges | 1 Regexp: a{2,3} 6 Regexp: ba{2,3}c 11 Regexp: a(b|c){2,3}d
|
D | bug316338 | 1 Regexp: (((C|c)(([\s]*\-?[0-9]+(\.[0-9]+)?((e|E)\-?[0-9]+)?){3})+[\s]*))+ 7 Regexp: (((C|c)(([\s]+\-?[0-9]+(\.[0-9]+)?((e|E)\-?[0-9]+)?){3})+[\s]*))+ 13 Regexp: (((C|c)(([\s]+\-?[0-9]+(\.[0-9]+)?[\s]*,[\s]*\-?[0-9]+(\.[0-9]+)?){3})+[\s]*))+ 19 Regexp: (((M|m)([\s]+\-?[0-9]+(\.[0-9]+)?((e|E)\-?[0-9]+)?[\s]*,[\s]*\-?[0-9]+(\.[0-9]+)?((e|E)\-?[…
|
/external/regex-re2/ |
D | ucs2.diff | 27 - if (prog_->flags() & Regexp::UCS2) 165 if (re->parse_flags() & Regexp::Latin1) 167 - else if (re->parse_flags() & Regexp::UCS2) 190 - bool ucs2 = prog_->flags() & Regexp::UCS2; 240 bool Regexp::ParseState::PushCarat() { 255 bool Regexp::ParseState::PushWordBoundary(bool word) { 289 flags |= Regexp::Latin1; 292 - flags |= Regexp::UCS2; 317 bool Regexp::RequiredPrefix(string *prefix, bool *foldcase, Regexp** suffix) { 352 - if (prog_->flags() & Regexp::UCS2) [all …]
|