/third_party/protobuf/src/google/protobuf/stubs/ |
H A D | stringpiece_unittest.cc | 371 EXPECT_EQ(a.rfind(b), 0); in TEST() 372 EXPECT_EQ(a.rfind(b, 1), 0); in TEST() 373 EXPECT_EQ(a.rfind(c), 23); in TEST() 374 EXPECT_EQ(a.rfind(c, 22), StringPiece::npos); in TEST() 375 EXPECT_EQ(a.rfind(c, 1), StringPiece::npos); in TEST() 376 EXPECT_EQ(a.rfind(c, 0), StringPiece::npos); in TEST() 377 EXPECT_EQ(b.rfind(c), StringPiece::npos); in TEST() 378 EXPECT_EQ(b.rfind(c, 0), StringPiece::npos); in TEST() 379 EXPECT_EQ(a.rfind(d), a.as_string().rfind(strin in TEST() [all...] |
H A D | stringpiece.h | 368 stringpiece_ssize_type rfind(StringPiece s, size_type pos = npos) const; 369 stringpiece_ssize_type rfind(char c, size_type pos = npos) const; 381 return rfind(c, pos); in find_last_of()
|
/third_party/skia/third_party/externals/abseil-cpp/absl/strings/ |
H A D | string_view_test.cc | 470 EXPECT_EQ(a.rfind(b), 0); in TEST() 471 EXPECT_EQ(a.rfind(b, 1), 0); in TEST() 472 EXPECT_EQ(a.rfind(c), 23); in TEST() 473 EXPECT_EQ(a.rfind(c, 22), absl::string_view::npos); in TEST() 474 EXPECT_EQ(a.rfind(c, 1), absl::string_view::npos); in TEST() 475 EXPECT_EQ(a.rfind(c, 0), absl::string_view::npos); in TEST() 476 EXPECT_EQ(b.rfind(c), absl::string_view::npos); in TEST() 477 EXPECT_EQ(b.rfind(c, 0), absl::string_view::npos); in TEST() 478 EXPECT_EQ(a.rfind(d), std::string(a).rfind(st in TEST() [all...] |
H A D | string_view.h | 475 // string_view::rfind() 480 size_type rfind(string_view s, size_type pos = npos) const noexcept; 482 // Overload of `string_view::rfind()` for finding the last given character `c` 484 size_type rfind(char c, size_type pos = npos) const noexcept; 486 // Overload of `string_view::rfind()` for finding a substring of a different 488 size_type rfind(const char* s, size_type pos, size_type count) const { 489 return rfind(string_view(s, count), pos); 492 // Overload of `string_view::rfind()` for finding a different C-style string 494 size_type rfind(const char* s, size_type pos = npos) const { 495 return rfind(string_vie [all...] |
/third_party/rust/crates/memchr/src/memmem/ |
H A D | mod.rs | 290 /// assert_eq!(Some(0), memmem::rfind(haystack, b"foo")); 291 /// assert_eq!(Some(4), memmem::rfind(haystack, b"bar")); 292 /// assert_eq!(Some(8), memmem::rfind(haystack, b"ba")); 293 /// assert_eq!(None, memmem::rfind(haystack, b"quux")); 296 pub fn rfind(haystack: &[u8], needle: &[u8]) -> Option<usize> { in rfind() functions 298 rabinkarp::rfind(haystack, needle) in rfind() 300 FinderRev::new(needle).rfind(haystack) in rfind() 420 let result = self.finder.rfind(&self.haystack[..pos]); in next() 569 /// using [`rfind`] is good enough, but `FinderRev` is useful when you can 610 /// assert_eq!(Some(0), FinderRev::new("foo").rfind(haystac 614 pub fn rfind<B: AsRef<[u8]>>(&self, haystack: B) -> Option<usize> { rfind() functions 1109 fn rfind(&self, haystack: &[u8]) -> Option<usize> { rfind() functions [all...] |
H A D | rabinkarp.rs | 71 pub(crate) fn rfind(haystack: &[u8], needle: &[u8]) -> Option<usize> { 227 define_memmem_simple_tests!(super::find, super::rfind); 232 define_memmem_quickcheck_tests!(super::find, super::rfind);
|
H A D | twoway.rs | 275 pub(crate) fn rfind( 296 /// Like rfind, but handles the degenerate substring test cases. This is 306 self.rfind(haystack, needle) in rfind_general() 873 let rfind = super::simpletests::twoway_rfind; in regression_rev_small_period() 876 assert_eq!(Some(0), rfind(haystack.as_bytes(), needle.as_bytes())); in regression_rev_small_period()
|
/third_party/python/Lib/ |
H A D | genericpath.py | 128 sepIndex = p.rfind(sep) 130 altsepIndex = p.rfind(altsep) 133 dotIndex = p.rfind(extsep)
|
/third_party/rust/crates/memchr/bench/src/memmem/ |
H A D | imp.rs | 68 memmem::rfind(haystack.as_bytes(), needle.as_bytes()).is_some() 75 move |h| finder.rfind(h.as_bytes()).is_some() 172 finder(needle.as_bytes()).rfind(haystack.as_bytes()).is_some() in finder() 179 move |h| finder.rfind(h.as_bytes()).is_some() 189 |h, n| finder(n).rfind(h), 264 bstr::ByteSlice::rfind(haystack.as_bytes(), needle.as_bytes()) 272 move |h| finder.rfind(h.as_bytes()).is_some() 297 move |h, _| self.0.rfind(h), 835 mut rfind: impl FnMut(&[u8], &[u8]) -> Option<usize> + 'a, in iter_from_rfind() 843 match rfind( [all...] |
/third_party/vk-gl-cts/external/amber/src/src/vkscript/ |
H A D | section_parser.cc | 55 size_t pos = data.rfind(" spirv hex"); in NameToNodeType() 60 pos = data.rfind(" spirv"); in NameToNodeType() 69 pos = data.rfind(" passthrough"); in NameToNodeType() 191 size_t name_end = line.rfind("]"); in SplitSections()
|
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-subzero/include/llvm/ADT/ |
H A D | SmallString.h | 163 size_t rfind(char C, size_t From = StringRef::npos) const { in rfind() function in llvm::SmallString 164 return str().rfind(C, From); in rfind() 171 size_t rfind(StringRef Str) const { in rfind() function in llvm::SmallString 172 return str().rfind(Str); in rfind()
|
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/include/llvm/ADT/ |
H A D | SmallString.h | 162 size_t rfind(char C, size_t From = StringRef::npos) const { in rfind() function in llvm::SmallString 163 return str().rfind(C, From); in rfind() 170 size_t rfind(StringRef Str) const { in rfind() function in llvm::SmallString 171 return str().rfind(Str); in rfind()
|
/third_party/node/deps/icu-small/source/tools/escapesrc/ |
H A D | escapesrc.cpp | 333 while((pos>0) && (pos = linestr.rfind("u\"", pos)) != std::string::npos) { in fixLine() 342 while((pos>0) && (pos = linestr.rfind("u'", pos)) != std::string::npos) { in fixLine() 351 while((pos>0) && (pos = linestr.rfind("u8\"", pos)) != std::string::npos) { in fixLine()
|
/third_party/icu/icu4c/source/tools/escapesrc/ |
H A D | escapesrc.cpp | 333 while((pos>0) && (pos = linestr.rfind("u\"", pos)) != std::string::npos) { in fixLine() 342 while((pos>0) && (pos = linestr.rfind("u'", pos)) != std::string::npos) { in fixLine() 351 while((pos>0) && (pos = linestr.rfind("u8\"", pos)) != std::string::npos) { in fixLine()
|
/third_party/libphonenumber/cpp/src/phonenumbers/base/strings/ |
H A D | string_piece.h | 140 size_type rfind(const StringPiece& s, size_type pos = npos) const; 141 size_type rfind(char c, size_type pos = npos) const; 151 return rfind(c, pos); in find_last_of()
|
/third_party/skia/third_party/externals/icu/source/tools/escapesrc/ |
H A D | escapesrc.cpp | 333 while((pos>0) && (pos = linestr.rfind("u\"", pos)) != std::string::npos) { in fixLine() 342 while((pos>0) && (pos = linestr.rfind("u'", pos)) != std::string::npos) { in fixLine() 351 while((pos>0) && (pos = linestr.rfind("u8\"", pos)) != std::string::npos) { in fixLine()
|
/third_party/icu/icu4c/source/python/icutools/databuilder/ |
H A D | filtration.py | 55 start = file.filename.rfind("/") 56 limit = file.filename.rfind(".") 61 limit = file.filename.rfind("/") 230 i = locale.rfind("_") 340 file.filename[file.filename.rfind("/")+1:]
|
/third_party/skia/third_party/externals/icu/source/python/icutools/databuilder/ |
H A D | filtration.py | 55 start = file.filename.rfind("/") 56 limit = file.filename.rfind(".") 61 limit = file.filename.rfind("/") 230 i = locale.rfind("_") 340 file.filename[file.filename.rfind("/")+1:]
|
/third_party/python/Objects/stringlib/ |
H A D | find.h | 27 STRINGLIB(rfind)(const STRINGLIB_CHAR* str, Py_ssize_t str_len, in rfind() function 58 return STRINGLIB(rfind)(str + start, end - start, sub, sub_len, start); in rfind_slice() 75 This function is a helper for the "find" family (find, rfind, index,
|
/third_party/vulkan-loader/tests/framework/ |
H A D | test_util.cpp | 305 auto last_div = contents.rfind(path_separator); in parent_path() 310 auto last_div = contents.rfind(path_separator); in has_parent_path() 314 auto last_div = contents.rfind(path_separator); in filename() 319 auto last_div = contents.rfind(path_separator); in extension() 320 auto ext_div = contents.rfind('.'); in extension() 329 auto last_div = contents.rfind(path_separator); in stem() 330 auto ext_div = contents.rfind('.'); in stem()
|
/third_party/rust/crates/os_str_bytes/src/ |
H A D | raw_str.rs | 25 use memchr::memmem::rfind; 46 fn rfind(string: &[u8], pat: &[u8]) -> Option<usize> { in rfind() functions 48 .rfind(|&x| string[..x].ends_with(pat)) in rfind() 421 /// Equivalent to [`str::rfind`]. 429 /// assert_eq!(Some(2), raw.rfind("o")); 430 /// assert_eq!(None, raw.rfind("of")); 434 pub fn rfind<P>(&self, pat: P) -> Option<usize> in rfind() functions 441 rfind(&self.0, pat) in rfind() 465 self.split_once_raw_with(pat, rfind)
|
/third_party/glslang/gtests/ |
H A D | TestFixture.cpp | 176 const size_t pos = name.rfind('.'); in GetSuffix() 177 return (pos == std::string::npos) ? "" : name.substr(name.rfind('.') + 1); in GetSuffix()
|
/third_party/node/deps/googletest/include/gtest/internal/ |
H A D | gtest-type-util.h | 110 // Only strip the leading "struct " and "class ", so uses rfind == 0 to in GetTypeName() 112 if (s.rfind("struct ", 0) == 0) { in GetTypeName() 114 } else if (s.rfind("class ", 0) == 0) { in GetTypeName()
|
/third_party/python/Tools/stringbench/ |
H A D | stringbench.py | 222 #### Same tests for 'rfind' 224 @bench('("A"*1000).rfind("A")', "early match, single character", 1000) 228 s1_rfind = s1.rfind 232 @bench('("A"*1000).rfind("B")', "no match, single character", 1000) 236 s1_rfind = s1.rfind 241 @bench('("AB"*1000).rfind("AB")', "early match, two characters", 1000) 245 s1_rfind = s1.rfind 249 @bench('("AB"*1000).rfind("BC")', "no match, two characters", 1000) 253 s1_rfind = s1.rfind 257 @bench('("AB"*1000).rfind("C [all...] |
/third_party/python/Lib/idlelib/ |
H A D | pyparse.py | 156 i = code.rfind(":\n", 0, limit) 159 i = code.rfind('\n', 0, i) + 1 # start of colon line (-1+1=0) 370 p = code.rfind('\n', 0, p-1) + 1 468 origi = i = code.rfind('\n', 0, j) + 1
|