Home | History | Annotate | Download | only in src

Lines Matching refs:needle

1514 // This group of overloaded functions return true iff needle is a
1518 bool IsSubstringPred(const char* needle, const char* haystack) {
1519 if (needle == NULL || haystack == NULL)
1520 return needle == haystack;
1522 return strstr(haystack, needle) != NULL;
1525 bool IsSubstringPred(const wchar_t* needle, const wchar_t* haystack) {
1526 if (needle == NULL || haystack == NULL)
1527 return needle == haystack;
1529 return wcsstr(haystack, needle) != NULL;
1534 bool IsSubstringPred(const StringType& needle,
1536 return haystack.find(needle) != StringType::npos;
1547 const StringType& needle, const StringType& haystack) {
1548 if (IsSubstringPred(needle, haystack) == expected_to_be_substring)
1551 const bool is_wide_string = sizeof(needle[0]) > 1;
1555 << " Actual: " << begin_string_quote << needle << "\"\n"
1563 // IsSubstring() and IsNotSubstring() check whether needle is a
1569 const char* needle, const char* haystack) {
1570 return IsSubstringImpl(true, needle_expr, haystack_expr, needle, haystack);
1575 const wchar_t* needle, const wchar_t* haystack) {
1576 return IsSubstringImpl(true, needle_expr, haystack_expr, needle, haystack);
1581 const char* needle, const char* haystack) {
1582 return IsSubstringImpl(false, needle_expr, haystack_expr, needle, haystack);
1587 const wchar_t* needle, const wchar_t* haystack) {
1588 return IsSubstringImpl(false, needle_expr, haystack_expr, needle, haystack);
1593 const ::std::string& needle, const ::std::string& haystack) {
1594 return IsSubstringImpl(true, needle_expr, haystack_expr, needle, haystack);
1599 const ::std::string& needle, const ::std::string& haystack) {
1600 return IsSubstringImpl(false, needle_expr, haystack_expr, needle, haystack);
1606 const ::std::wstring& needle, const ::std::wstring& haystack) {
1607 return IsSubstringImpl(true, needle_expr, haystack_expr, needle, haystack);
1612 const ::std::wstring& needle, const ::std::wstring& haystack) {
1613 return IsSubstringImpl(false, needle_expr, haystack_expr, needle, haystack);