Lines Matching refs:to_len
2356 const char *to_s, Py_ssize_t to_len, in replace_interleave() argument
2373 product = count * to_len; in replace_interleave()
2374 if (product / to_len != count) { in replace_interleave()
2396 Py_MEMCPY(result_s, to_s, to_len); in replace_interleave()
2397 result_s += to_len; in replace_interleave()
2402 Py_MEMCPY(result_s, to_s, to_len); in replace_interleave()
2403 result_s += to_len; in replace_interleave()
2556 const char *to_s, Py_ssize_t to_len, in replace_substring_in_place() argument
2607 const char *to_s, Py_ssize_t to_len, in replace_single_character() argument
2627 product = count * (to_len-1); in replace_single_character()
2628 if (product / (to_len-1) != count) { in replace_single_character()
2652 Py_MEMCPY(result_s, to_s, to_len); in replace_single_character()
2653 result_s += to_len; in replace_single_character()
2659 Py_MEMCPY(result_s, to_s, to_len); in replace_single_character()
2660 result_s += to_len; in replace_single_character()
2674 const char *to_s, Py_ssize_t to_len, in replace_substring() argument
2696 product = count * (to_len-from_len); in replace_substring()
2697 if (product / (to_len-from_len) != count) { in replace_substring()
2723 Py_MEMCPY(result_s, to_s, to_len); in replace_substring()
2724 result_s += to_len; in replace_substring()
2730 Py_MEMCPY(result_s, to_s, to_len); in replace_substring()
2731 result_s += to_len; in replace_substring()
2745 const char *to_s, Py_ssize_t to_len, in replace() argument
2756 (from_len == 0 && to_len == 0)) { in replace()
2767 return replace_interleave(self, to_s, to_len, maxcount); in replace()
2777 if (to_len == 0) { in replace()
2789 if (from_len == to_len) { in replace()
2798 self, from_s, from_len, to_s, to_len, maxcount); in replace()
2805 to_s, to_len, maxcount); in replace()
2808 return replace_substring(self, from_s, from_len, to_s, to_len, maxcount); in replace()
2825 Py_ssize_t from_len, to_len; in string_replace() local
2844 to_len = PyString_GET_SIZE(to); in string_replace()
2851 else if (PyObject_AsCharBuffer(to, &to_s, &to_len)) in string_replace()
2856 to_s, to_len, count); in string_replace()