Lines Matching refs:haystack

110 	char *haystack, *needle;  in PHP_FUNCTION()  local
118 …if (zend_parse_parameters(ZEND_NUM_ARGS(), "ss|l", &haystack, &haystack_len, &needle, &needle_len,… in PHP_FUNCTION()
144 found = php_memnstr(haystack + noffset, needle, needle_len, haystack + haystack_len); in PHP_FUNCTION()
152 if ( grapheme_ascii_check((unsigned char *)haystack, haystack_len) >= 0 ) { in PHP_FUNCTION()
153 RETURN_LONG(found - haystack); in PHP_FUNCTION()
158 …ret_pos = grapheme_strpos_utf16(haystack, haystack_len, needle, needle_len, offset, NULL, 0 /* fIg… in PHP_FUNCTION()
173 char *haystack, *needle; in PHP_FUNCTION() local
181 …if (zend_parse_parameters(ZEND_NUM_ARGS(), "ss|l", &haystack, &haystack_len, &needle, &needle_len,… in PHP_FUNCTION()
202 is_ascii = ( grapheme_ascii_check((unsigned char*)haystack, haystack_len) >= 0 ); in PHP_FUNCTION()
209 haystack_dup = estrndup(haystack, haystack_len); in PHP_FUNCTION()
228 …ret_pos = grapheme_strpos_utf16(haystack, haystack_len, needle, needle_len, offset, NULL, 1 /* fIg… in PHP_FUNCTION()
243 char *haystack, *needle; in PHP_FUNCTION() local
250 …if (zend_parse_parameters(ZEND_NUM_ARGS(), "ss|l", &haystack, &haystack_len, &needle, &needle_len,… in PHP_FUNCTION()
271 is_ascii = grapheme_ascii_check((unsigned char *)haystack, haystack_len) >= 0; in PHP_FUNCTION()
275 ret_pos = grapheme_strrpos_ascii(haystack, haystack_len, needle, needle_len, offset); in PHP_FUNCTION()
290 …ret_pos = grapheme_strpos_utf16(haystack, haystack_len, needle, needle_len, offset, NULL, 0 /* f_i… in PHP_FUNCTION()
306 char *haystack, *needle; in PHP_FUNCTION() local
313 …if (zend_parse_parameters(ZEND_NUM_ARGS(), "ss|l", &haystack, &haystack_len, &needle, &needle_len,… in PHP_FUNCTION()
334 is_ascii = grapheme_ascii_check((unsigned char *)haystack, haystack_len) >= 0; in PHP_FUNCTION()
341 haystack_dup = estrndup(haystack, haystack_len); in PHP_FUNCTION()
362 …ret_pos = grapheme_strpos_utf16(haystack, haystack_len, needle, needle_len, offset, NULL, 1 /* f_… in PHP_FUNCTION()
594 char *haystack, *needle; in strstr_common_handler() local
600 …if (zend_parse_parameters(ZEND_NUM_ARGS(), "ss|b", &haystack, &haystack_len, &needle, &needle_len,… in strstr_common_handler()
621 found = php_memnstr(haystack, needle, needle_len, haystack + haystack_len); in strstr_common_handler()
629 if ( grapheme_ascii_check((unsigned char *)haystack, haystack_len) >= 0 ) { in strstr_common_handler()
630 size_t found_offset = found - haystack; in strstr_common_handler()
633 RETURN_STRINGL(haystack, found_offset); in strstr_common_handler()
642 …ret_pos = grapheme_strpos_utf16(haystack, haystack_len, needle, needle_len, 0, &uchar_pos, f_ignor… in strstr_common_handler()
651 U8_FWD_N(haystack, ret_pos, haystack_len, uchar_pos); in strstr_common_handler()
654 RETURN_STRINGL(haystack, ret_pos); in strstr_common_handler()
656 RETURN_STRINGL(haystack + ret_pos, haystack_len - ret_pos); in strstr_common_handler()