/external/rust/crates/grpcio-sys/grpc/third_party/re2/re2/ |
D | simplify.cc | 15 #include "re2/regexp.h" 20 // Parses the regexp src and then simplifies it and sets *dst to the 23 bool Regexp::SimplifyRegexp(const StringPiece& src, ParseFlags flags, in SimplifyRegexp() 25 Regexp* re = Parse(src, flags, status); in SimplifyRegexp() 28 Regexp* sre = re->Simplify(); in SimplifyRegexp() 45 // is this Regexp* simple? 46 bool Regexp::ComputeSimple() { in ComputeSimple() 47 Regexp** subs; in ComputeSimple() 108 class CoalesceWalker : public Regexp::Walker<Regexp*> { 111 virtual Regexp* PostVisit(Regexp* re, Regexp* parent_arg, Regexp* pre_arg, [all …]
|
D | regexp.h | 20 // Any operation that traverses the Regexp structures should be written 21 // using Regexp::Walker (see walker-inl.h), not recursively, because deeply nested 30 // Regexp::Parse parses regular expressions encoded in UTF-8. 42 // Regexp::Parse. In particular, many of the basic Perl additions 45 // If parsed with the flag Regexp::Latin1, both the regular expression 51 // Once Regexp has parsed a regular expression, it provides methods 56 // To call a sublibrary, Regexp does not simply prepare a 58 // sublibrary. Instead, Regexp prepares, from its own parsed form, the 64 // to be that used by Regexp's parser, not the syntax expected 65 // by the sublibrary. Regexp might accept a restricted or [all …]
|
D | regexp.cc | 8 #include "re2/regexp.h" 30 Regexp::Regexp(RegexpOp op, ParseFlags parse_flags) in Regexp() function in re2::Regexp 46 Regexp::~Regexp() { in ~Regexp() 48 LOG(DFATAL) << "Regexp not destroyed."; in ~Regexp() 67 // If it's possible to destroy this regexp without recurring, 69 bool Regexp::QuickDestroy() { in QuickDestroy() 79 static std::map<Regexp*, int>* ref_map; 81 int Regexp::Ref() { in Ref() 90 Regexp* Regexp::Incref() { in Incref() 95 ref_map = new std::map<Regexp*, int>; in Incref() [all …]
|
D | parse.cc | 9 // of the ParseState class. The Regexp::Parse function is 17 // See regexp.h for rationale. 33 #include "re2/regexp.h" 56 // Regexp pointers called the stack. Left parenthesis and vertical 67 // form LeftParen regexp VerticalBar regexp VerticalBar ... regexp VerticalBar. 71 class Regexp::ParseState { 87 bool PushRegexp(Regexp* re); 92 // Pushes a regexp with the given op (and no args) onto the stack. 107 // Pushes a repeat operator regexp onto the stack. 112 // Pushes a repetition regexp onto the stack. [all …]
|
D | walker-inl.h | 19 #include "re2/regexp.h" 25 template<typename T> class Regexp::Walker { 34 // At the top-most Regexp, parent_arg is arg passed to walk. 39 virtual T PreVisit(Regexp* re, T parent_arg, bool* stop); 50 virtual T PostVisit(Regexp* re, T parent_arg, T pre_arg, 65 virtual T ShortVisit(Regexp* re, T parent_arg) = 0; 70 T Walk(Regexp* re, T top_arg); 80 T WalkExponential(Regexp* re, T top_arg, int max_visits); 96 T WalkInternal(Regexp* re, T top_arg, bool use_copy); 102 template<typename T> T Regexp::Walker<T>::PreVisit(Regexp* re, in PreVisit() [all …]
|
D | mimics_pcre.cc | 6 // for a particular Regexp. (If so, the testing framework can 10 // * the regexp contains a repetition of an empty string, 23 // Regexp::MimicsPCRE checks for any of these conditions. 27 #include "re2/regexp.h" 33 static bool CanBeEmptyString(Regexp *re); 35 // Walker class to compute whether library handles a regexp 38 class PCREWalker : public Regexp::Walker<bool> { 42 virtual bool PostVisit(Regexp* re, bool parent_arg, bool pre_arg, 45 virtual bool ShortVisit(Regexp* re, bool a) { in ShortVisit() 61 bool PCREWalker::PostVisit(Regexp* re, bool parent_arg, bool pre_arg, in PostVisit() [all …]
|
D | set.cc | 16 #include "re2/regexp.h" 42 Regexp::ParseFlags pf = static_cast<Regexp::ParseFlags>( in Add() 45 re2::Regexp* re = Regexp::Parse(pattern, pf, &status); in Add() 56 re2::Regexp* m = re2::Regexp::HaveMatch(n, pf); in Add() 59 PODArray<re2::Regexp*> sub(nsub + 1); in Add() 64 re = re2::Regexp::Concat(sub.data(), nsub + 1, pf); in Add() 66 re2::Regexp* sub[2]; in Add() 69 re = re2::Regexp::Concat(sub, 2, pf); in Add() 84 // until we have a Regexp comparison function. (Maybe someday...) in Compile() 90 PODArray<re2::Regexp*> sub(size_); in Compile() [all …]
|
/external/rust/crates/grpcio-sys/grpc/third_party/re2/re2/testing/ |
D | regexp_benchmark.cc | 22 #include "re2/regexp.h" 35 Regexp* re = Regexp::Parse("(\\d+)-(\\d+)-(\\d+)", Regexp::LikePerl, NULL); in Test() 54 const char* regexp = "(\\d+)-(\\d+)-(\\d+)"; in MemoryUsage() local 58 Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); in MemoryUsage() 62 fprintf(stderr, "Regexp: %7lld bytes (peak=%lld)\n", in MemoryUsage() 85 PCRE re(regexp, PCRE::UTF8); in MemoryUsage() 96 PCRE* re = new PCRE(regexp, PCRE::UTF8); in MemoryUsage() 108 RE2 re(regexp); in MemoryUsage() 128 typedef void SearchImpl(benchmark::State& state, const char* regexp, 136 typedef void ParseImpl(benchmark::State& state, const char* regexp, [all …]
|
D | parse_test.cc | 11 #include "re2/regexp.h" 18 static const Regexp::ParseFlags TestZeroFlags = Regexp::WasDollar; 21 const char* regexp; member 23 Regexp::ParseFlags flags; 26 static Regexp::ParseFlags kTestFlags = Regexp::MatchNL | 27 Regexp::PerlX | 28 Regexp::PerlClasses | 29 Regexp::UnicodeGroups; 177 { "[^ ]", "cc{0-0x9 0xb-0x1f 0x21-0x10ffff}", Regexp::FoldCase }, 178 { "[^ ]", "cc{0-0x9 0xb-0x1f 0x21-0x10ffff}", Regexp::NeverNL }, [all …]
|
D | required_prefix_test.cc | 10 #include "re2/regexp.h" 15 const char* regexp; member 28 // If the regexp has no ^, there's no required prefix. 31 // If the regexp immediately goes into 50 Regexp::ParseFlags flags = Regexp::LikePerl; in TEST() 52 flags = flags | Regexp::Latin1; in TEST() 53 Regexp* re = Regexp::Parse(t.regexp, flags, NULL); in TEST() 54 ASSERT_TRUE(re != NULL) << " " << t.regexp; in TEST() 58 Regexp* s; in TEST() 60 << " " << t.regexp << " " << (j == 0 ? "latin1" : "utf8") in TEST() [all …]
|
D | regexp_test.cc | 14 #include "re2/regexp.h" 19 TEST(Regexp, BigRef) { in TEST() argument 20 Regexp* re; in TEST() 21 re = Regexp::Parse("x", Regexp::NoParseFlags, NULL); in TEST() 32 TEST(Regexp, BigConcat) { in TEST() argument 33 Regexp* x; in TEST() 34 x = Regexp::Parse("x", Regexp::NoParseFlags, NULL); in TEST() 35 std::vector<Regexp*> v(90000, x); // ToString bails out at 100000 in TEST() 39 Regexp* re = Regexp::Concat(v.data(), static_cast<int>(v.size()), in TEST() 40 Regexp::NoParseFlags); in TEST() [all …]
|
D | compile_test.cc | 11 #include "re2/regexp.h" 17 // the regexp compiles to the expected code. 23 const char* regexp; member 118 Regexp* re = Regexp::Parse(t.regexp, Regexp::PerlX|Regexp::Latin1, NULL); in TEST() 120 LOG(ERROR) << "Cannot parse: " << t.regexp; in TEST() 126 LOG(ERROR) << "Cannot compile: " << t.regexp; in TEST() 134 LOG(ERROR) << "Incorrect compiled code for: " << t.regexp; in TEST() 145 static void DumpByteMap(StringPiece pattern, Regexp::ParseFlags flags, in DumpByteMap() 147 Regexp* re = Regexp::Parse(pattern, flags, NULL); in DumpByteMap() 172 DumpByteMap(".", Regexp::PerlX|Regexp::Latin1, &bytemap); in TEST() [all …]
|
D | possible_match_test.cc | 14 #include "re2/regexp.h" 30 const char* regexp; member 115 LOG(INFO) << "Checking regexp=" << CEscape(t.regexp); in TEST() 116 Regexp* re = Regexp::Parse(t.regexp, Regexp::LikePerl, NULL); in TEST() 121 << " " << t.regexp; in TEST() 125 ASSERT_TRUE(RE2(t.regexp).PossibleMatchRange(&min, &max, t.maxlen)); in TEST() 127 EXPECT_EQ(t.min, min) << t.regexp; in TEST() 128 EXPECT_EQ(t.max, max) << t.regexp; in TEST() 162 // Fails because it's a malformed regexp. in TEST() 170 // the regexp matches each of the strings. [all …]
|
D | dfa_test.cc | 17 #include "re2/regexp.h" 51 // Create regexp with 2^FLAGS_size states in DFA. in TEST() 56 Regexp* re = Regexp::Parse(s, Regexp::LikePerl, NULL); in TEST() 93 // Create regexp with 2^30 states in DFA. in TEST() 94 Regexp* re = Regexp::Parse("a[ab]{30}b", Regexp::LikePerl, NULL); in TEST() 132 // If we run this regexp to search in a string that contains 140 // The De Bruijn string is the worst case input for this regexp. in TEST() 157 Regexp* re = Regexp::Parse(StringPrintf("0[01]{%d}$", n), in TEST() 158 Regexp::LikePerl, NULL); in TEST() 227 Regexp* re = Regexp::Parse(StringPrintf("0[01]{%d}$", n), in TEST() [all …]
|
D | tester.h | 15 #include "re2/regexp.h" 21 // All the supported regexp engines. 47 // A TestInstance caches per-regexp state for a given 54 TestInstance(const StringPiece& regexp, Prog::MatchKind kind, 55 Regexp::ParseFlags flags); 57 Regexp::ParseFlags flags() { return flags_; } in flags() 75 const StringPiece regexp_str_; // regexp being tested 77 Regexp::ParseFlags flags_; // flags for parsing regexp_str_ 80 Regexp* regexp_; // parsed regexp 94 explicit Tester(const StringPiece& regexp); [all …]
|
D | tester.cc | 19 #include "re2/regexp.h" 21 DEFINE_FLAG(bool, dump_prog, false, "dump regexp program"); 23 DEFINE_FLAG(bool, dump_rprog, false, "dump reversed regexp program"); 26 "maximum number of regexp test failures (-1 = unlimited)"); 29 "pattern to select regexp engines to test"); 145 Regexp::ParseFlags parse_flags; 149 static const Regexp::ParseFlags single_line = 150 Regexp::LikePerl; 151 static const Regexp::ParseFlags multi_line = 152 static_cast<Regexp::ParseFlags>(Regexp::LikePerl & ~Regexp::OneLine); [all …]
|
D | mimics_pcre_test.cc | 8 #include "re2/regexp.h" 13 const char* regexp; member 64 Regexp::ParseFlags flags = Regexp::LikePerl; in TEST() 66 flags = flags | Regexp::Latin1; in TEST() 67 Regexp* re = Regexp::Parse(t.regexp, flags, NULL); in TEST() 68 ASSERT_TRUE(re != NULL) << " " << t.regexp; in TEST() 70 << " " << t.regexp << " " in TEST()
|
/external/icu/icu4c/source/i18n/ |
D | uregex.cpp | 326 RegularExpression *regexp = (RegularExpression*)regexp2; in uregex_pattern() local 328 if (validateRE(regexp, FALSE, status) == FALSE) { in uregex_pattern() 332 *patLength = regexp->fPatStringLen; in uregex_pattern() 334 return regexp->fPatString; in uregex_pattern() 346 RegularExpression *regexp = (RegularExpression*)regexp2; in uregex_patternUText() local 347 return regexp->fPat->patternText(*status); in uregex_patternUText() 358 RegularExpression *regexp = (RegularExpression*)regexp2; in uregex_flags() local 359 if (validateRE(regexp, FALSE, status) == FALSE) { in uregex_flags() 362 int32_t flags = regexp->fPat->flags(); in uregex_flags() 377 RegularExpression *regexp = (RegularExpression*)regexp2; in uregex_setText() local [all …]
|
/external/icu/libicu/cts_headers/unicode/ |
D | uregex.h | 210 * @param regexp The regular expression to be closed. 214 uregex_close(URegularExpression *regexp); 248 * @param regexp The compiled regular expression to be cloned. 254 uregex_clone(const URegularExpression *regexp, UErrorCode *status); 260 * @param regexp The compiled regular expression. 274 uregex_pattern(const URegularExpression *regexp, 282 * @param regexp The compiled regular expression. 290 uregex_patternUText(const URegularExpression *regexp, 296 * @param regexp The compiled regular expression. 302 uregex_flags(const URegularExpression *regexp, [all …]
|
/external/icu/libandroidicu/include/unicode/ |
D | uregex.h | 210 * @param regexp The regular expression to be closed. 214 uregex_close(URegularExpression *regexp); 248 * @param regexp The compiled regular expression to be cloned. 254 uregex_clone(const URegularExpression *regexp, UErrorCode *status); 260 * @param regexp The compiled regular expression. 274 uregex_pattern(const URegularExpression *regexp, 282 * @param regexp The compiled regular expression. 290 uregex_patternUText(const URegularExpression *regexp, 296 * @param regexp The compiled regular expression. 302 uregex_flags(const URegularExpression *regexp, [all …]
|
/external/icu/icu4c/source/i18n/unicode/ |
D | uregex.h | 210 * @param regexp The regular expression to be closed. 214 uregex_close(URegularExpression *regexp); 248 * @param regexp The compiled regular expression to be cloned. 254 uregex_clone(const URegularExpression *regexp, UErrorCode *status); 260 * @param regexp The compiled regular expression. 274 uregex_pattern(const URegularExpression *regexp, 282 * @param regexp The compiled regular expression. 290 uregex_patternUText(const URegularExpression *regexp, 296 * @param regexp The compiled regular expression. 302 uregex_flags(const URegularExpression *regexp, [all …]
|
/external/llvm-project/llvm/utils/emacs/ |
D | llvm-mode.el | 24 `(,(regexp-opt 38 …`(,(regexp-opt '("void" "i1" "i8" "i16" "i32" "i64" "i128" "float" "double" "type" "label" "opaque… 46 `(,(regexp-opt 62 `(,(regexp-opt '("add" "sub" "mul" "sdiv" "udiv" "urem" "srem" "and" "or" "xor" 65 `(,(regexp-opt '("fadd" "fsub" "fneg" "fmul" "fdiv" "frem") 'symbols) . font-lock-keyword-face) 67 …`(,(regexp-opt '("phi" "tail" "call" "select" "to" "shl" "lshr" "ashr" "fcmp" "icmp" "va_arg" "lan… 69 …`(,(regexp-opt '("ret" "br" "switch" "invoke" "resume" "unwind" "unreachable" "indirectbr" "callbr… 71 …`(,(regexp-opt '("malloc" "alloca" "free" "load" "store" "getelementptr" "fence" "cmpxchg" "atomic… 73 …`(,(regexp-opt '("bitcast" "inttoptr" "ptrtoint" "trunc" "zext" "sext" "fptrunc" "fpext" "fptoui" … 75 …`(,(regexp-opt '("extractelement" "insertelement" "shufflevector") 'symbols) . font-lock-keyword-f… [all …]
|
/external/llvm/utils/emacs/ |
D | llvm-mode.el | 29 …`(,(regexp-opt '("void" "i1" "i8" "i16" "i32" "i64" "i128" "float" "double" "type" "label" "opaque… 37 `(,(regexp-opt '("begin" "end" "true" "false" "zeroinitializer" "declare" 43 `(,(regexp-opt '("add" "sub" "mul" "sdiv" "udiv" "urem" "srem" "and" "or" "xor" 46 `(,(regexp-opt '("fadd" "fsub" "fmul" "fdiv" "frem") 'symbols) . font-lock-keyword-face) 48 …`(,(regexp-opt '("phi" "tail" "call" "select" "to" "shl" "lshr" "ashr" "fcmp" "icmp" "va_arg" "lan… 50 …`(,(regexp-opt '("ret" "br" "switch" "invoke" "resume" "unwind" "unreachable" "indirectbr") 'symbo… 52 …`(,(regexp-opt '("malloc" "alloca" "free" "load" "store" "getelementptr" "fence" "cmpxchg" "atomic… 54 …`(,(regexp-opt '("bitcast" "inttoptr" "ptrtoint" "trunc" "zext" "sext" "fptrunc" "fpext" "fptoui" … 56 …`(,(regexp-opt '("extractelement" "insertelement" "shufflevector") 'symbols) . font-lock-keyword-f… 58 `(,(regexp-opt '("extractvalue" "insertvalue") 'symbols) . font-lock-keyword-face) [all …]
|
/external/rust/crates/grpcio-sys/grpc/third_party/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; 298 ErrorBadUTF8, // invalid UTF-8 in regexp 313 ==== re2/regexp.cc#15 - re2/regexp.cc#16 ==== [all …]
|
/external/libxml2/ |
D | testAutomata.c | 2 * testAutomata.c: simple module for testing regexp automata 38 xmlRegexpPtr regexp = NULL; in testRegexpFile() local 171 regexp = xmlAutomataCompile(am); in testRegexpFile() 174 if (regexp == NULL) { in testRegexpFile() 180 if (regexp == NULL) { in testRegexpFile() 184 exec = xmlRegNewExecCtxt(regexp, NULL, NULL); in testRegexpFile() 198 } else if (regexp != NULL) { in testRegexpFile() 200 exec = xmlRegNewExecCtxt(regexp, NULL, NULL); in testRegexpFile() 209 if (regexp != NULL) in testRegexpFile() 210 xmlRegFreeRegexp(regexp); in testRegexpFile() [all …]
|