Home
last modified time | relevance | path

Searched refs:self_len (Results 1 – 3 of 3) sorted by relevance

/external/python/cpython3/Objects/stringlib/
Dtransmogrify.h243 Py_ssize_t self_len, result_len; in stringlib_replace_interleave() local
247 self_len = STRINGLIB_LEN(self); in stringlib_replace_interleave()
251 if (maxcount <= self_len) { in stringlib_replace_interleave()
256 count = self_len + 1; in stringlib_replace_interleave()
262 if (to_len > (PY_SSIZE_T_MAX - self_len) / count) { in stringlib_replace_interleave()
267 result_len = count * to_len + self_len; in stringlib_replace_interleave()
300 memcpy(result_s, self_s, self_len - i); in stringlib_replace_interleave()
313 Py_ssize_t self_len, result_len; in stringlib_replace_delete_single_character() local
317 self_len = STRINGLIB_LEN(self); in stringlib_replace_delete_single_character()
320 count = countchar(self_s, self_len, from_c, maxcount); in stringlib_replace_delete_single_character()
[all …]
/external/python/cpython2/Objects/
Dbytearrayobject.c1594 Py_ssize_t self_len, result_len; in replace_interleave() local
1598 self_len = PyByteArray_GET_SIZE(self); in replace_interleave()
1602 if (maxcount <= self_len) { in replace_interleave()
1607 count = self_len + 1; in replace_interleave()
1613 if (to_len > (PY_SSIZE_T_MAX - self_len) / count) { in replace_interleave()
1618 result_len = count * to_len + self_len; in replace_interleave()
1640 Py_MEMCPY(result_s, self_s, self_len-i); in replace_interleave()
1653 Py_ssize_t self_len, result_len; in replace_delete_single_character() local
1657 self_len = PyByteArray_GET_SIZE(self); in replace_delete_single_character()
1660 count = countchar(self_s, self_len, from_c, maxcount); in replace_delete_single_character()
[all …]
Dstringobject.c2366 Py_ssize_t self_len, result_len; in replace_interleave() local
2370 self_len = PyString_GET_SIZE(self); in replace_interleave()
2374 if (maxcount <= self_len) { in replace_interleave()
2379 count = self_len + 1; in replace_interleave()
2385 if (to_len > (PY_SSIZE_T_MAX - self_len) / count) { in replace_interleave()
2390 result_len = count * to_len + self_len; in replace_interleave()
2412 Py_MEMCPY(result_s, self_s, self_len-i); in replace_interleave()
2425 Py_ssize_t self_len, result_len; in replace_delete_single_character() local
2429 self_len = PyString_GET_SIZE(self); in replace_delete_single_character()
2432 count = countchar(self_s, self_len, from_c, maxcount); in replace_delete_single_character()
[all …]