Lines Matching refs:from_len
2459 const char *from_s, Py_ssize_t from_len, in replace_delete_substring() argument
2471 from_s, from_len, in replace_delete_substring()
2479 result_len = self_len - (count * from_len); in replace_delete_substring()
2492 from_s, from_len, in replace_delete_substring()
2501 start = next+from_len; in replace_delete_substring()
2555 const char *from_s, Py_ssize_t from_len, in replace_substring_in_place() argument
2570 from_s, from_len, in replace_substring_in_place()
2586 Py_MEMCPY(start, to_s, from_len); in replace_substring_in_place()
2587 start += from_len; in replace_substring_in_place()
2592 from_s, from_len, in replace_substring_in_place()
2596 Py_MEMCPY(start+offset, to_s, from_len); in replace_substring_in_place()
2597 start += offset+from_len; in replace_substring_in_place()
2673 const char *from_s, Py_ssize_t from_len, in replace_substring() argument
2686 from_s, from_len, in replace_substring()
2696 product = count * (to_len-from_len); in replace_substring()
2697 if (product / (to_len-from_len) != count) { in replace_substring()
2716 from_s, from_len, in replace_substring()
2725 start += from_len; in replace_substring()
2732 start = next+from_len; in replace_substring()
2744 const char *from_s, Py_ssize_t from_len, in replace() argument
2756 (from_len == 0 && to_len == 0)) { in replace()
2763 if (from_len == 0) { in replace()
2779 if (from_len == 1) { in replace()
2783 return replace_delete_substring(self, from_s, from_len, maxcount); in replace()
2789 if (from_len == to_len) { in replace()
2790 if (from_len == 1) { in replace()
2798 self, from_s, from_len, to_s, to_len, maxcount); in replace()
2803 if (from_len == 1) { 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
2832 from_len = PyString_GET_SIZE(from); in string_replace()
2839 else if (PyObject_AsCharBuffer(from, &from_s, &from_len)) in string_replace()
2855 from_s, from_len, in string_replace()