Home
last modified time | relevance | path

Searched refs:PyBytes_AS_STRING (Results 1 – 25 of 96) sorted by relevance

1234

/external/python/cpython3/Objects/
Dbytesobject.c490 *p = PyBytes_AS_STRING(arg)[0]; in byte_converter()
538 *pbuf = PyBytes_AS_STRING(v); in format_obj()
563 *pbuf = PyBytes_AS_STRING(result); in format_obj()
910 pbuf = PyBytes_AS_STRING(temp); in _PyBytes_FormatEx()
1097 PyBytes_AS_STRING(w), in _PyBytes_DecodeEscapeRecode()
1294 *s = PyBytes_AS_STRING(obj); in PyBytes_AsStringAndSize()
1451 memcpy(PyBytes_AS_STRING(result), va.buf, va.len); in bytes_concat()
1452 memcpy(PyBytes_AS_STRING(result) + va.len, vb.buf, vb.len); in bytes_concat()
1518 return _Py_bytes_contains(PyBytes_AS_STRING(self), PyBytes_GET_SIZE(self), arg); in bytes_contains()
1690 PyBytes_AS_STRING(self) + start, in bytes_subscript()
[all …]
Dunicodeobject.c3074 PyBytes_AS_STRING(obj), PyBytes_GET_SIZE(obj), in PyUnicode_FromEncodedObject()
3472 len2 = wcstombs(PyBytes_AS_STRING(bytes), wstr, len+1); in PyUnicode_EncodeLocale()
3886 data = PyBytes_AS_STRING(output); in PyUnicode_FSConverter()
3942 output = PyUnicode_DecodeFSDefaultAndSize(PyBytes_AS_STRING(path_bytes), in PyUnicode_FSDecoder()
3996 PyBytes_AS_STRING(bytes), in PyUnicode_AsUTF8AndSize()
4298 *input = PyBytes_AS_STRING(inputobj); in unicode_decode_call_errorhandler_wchar()
4400 *input = PyBytes_AS_STRING(inputobj); in unicode_decode_call_errorhandler_writer()
4761 start = out = PyBytes_AS_STRING(v); in _PyUnicode_EncodeUTF7()
5402 assert(_Py_IS_ALIGNED(PyBytes_AS_STRING(v), 4)); in _PyUnicode_EncodeUTF32()
5403 out = (uint32_t *)PyBytes_AS_STRING(v); in _PyUnicode_EncodeUTF32()
[all …]
/external/python/cpython3/Modules/_io/
Dbytesio.c71 start = PyBytes_AS_STRING(self->buf) + self->pos; in scan_eol()
97 memcpy(PyBytes_AS_STRING(new_buf), PyBytes_AS_STRING(self->buf), in unshare_buffer()
186 memset(PyBytes_AS_STRING(self->buf) + self->string_size, '\0', in write_bytes()
192 memcpy(PyBytes_AS_STRING(self->buf) + self->pos, bytes, len); in write_bytes()
308 return PyBytes_FromStringAndSize(PyBytes_AS_STRING(self->buf), in _io_BytesIO_getvalue_impl()
370 output = PyBytes_AS_STRING(self->buf) + self->pos; in read_bytes()
521 output = PyBytes_AS_STRING(self->buf) + self->pos; in _io_BytesIO_readlines_impl()
572 memcpy(buffer->buf, PyBytes_AS_STRING(self->buf) + self->pos, len); in _io_BytesIO_readinto_impl()
1111 PyBytes_AS_STRING(b->buf), b->string_size, in bytesiobuf_getbuffer()
Dtextio.c695 return _PyUnicode_AsASCIIString(text, PyBytes_AS_STRING(self->errors)); in ascii_encode()
702 PyBytes_AS_STRING(self->errors), 1); in utf16be_encode()
709 PyBytes_AS_STRING(self->errors), -1); in utf16le_encode()
724 PyBytes_AS_STRING(self->errors), 0); in utf16_encode()
731 PyBytes_AS_STRING(self->errors), 1); in utf32be_encode()
738 PyBytes_AS_STRING(self->errors), -1); in utf32le_encode()
753 PyBytes_AS_STRING(self->errors), 0); in utf32_encode()
759 return _PyUnicode_AsUTF8String(text, PyBytes_AS_STRING(self->errors)); in utf8_encode()
765 return _PyUnicode_AsLatin1String(text, PyBytes_AS_STRING(self->errors)); in latin1_encode()
2353 input = PyBytes_AS_STRING(next_input); in _io_TextIOWrapper_tell_impl()
[all …]
Dfileio.c294 name = PyBytes_AS_STRING(stringobj);
744 PyBytes_AS_STRING(result) + bytes_read,
808 ptr = PyBytes_AS_STRING(bytes);
Dwinconsoleio.c888 rn = _copyfrombuf(self, PyBytes_AS_STRING(bytes), bytes_size); in _io__WindowsConsoleIO_readall_impl()
893 &PyBytes_AS_STRING(bytes)[rn], bytes_size - rn, NULL, NULL); in _io__WindowsConsoleIO_readall_impl()
952 bytes_size = readinto(self, PyBytes_AS_STRING(bytes), PyBytes_GET_SIZE(bytes)); in _io__WindowsConsoleIO_read_impl()
/external/python/cpython3/Modules/
Dzlibmodule.c162 occupied = zst->next_out - (Byte *)PyBytes_AS_STRING(*buffer); in arrange_output_buffer_with_maximum()
181 zst->next_out = (Byte *)PyBytes_AS_STRING(*buffer) + occupied; in arrange_output_buffer_with_maximum()
276 (Byte *)PyBytes_AS_STRING(RetVal)) < 0) in zlib_compress_impl()
420 (Byte *)PyBytes_AS_STRING(RetVal)) < 0) in zlib_decompress_impl()
693 (Byte *)PyBytes_AS_STRING(RetVal)) == 0) in zlib_Compress_compress_impl()
724 memcpy(PyBytes_AS_STRING(new_data), in save_unconsumed_input()
725 PyBytes_AS_STRING(self->unused_data), old_size); in save_unconsumed_input()
726 memcpy(PyBytes_AS_STRING(new_data) + old_size, in save_unconsumed_input()
849 (Byte *)PyBytes_AS_STRING(RetVal)) == 0) in zlib_Decompress_decompress_impl()
933 (Byte *)PyBytes_AS_STRING(RetVal)) < 0) in zlib_Compress_flush_impl()
[all …]
D_bz2module.c163 c->bzs.next_out = PyBytes_AS_STRING(result); in compress()
185 c->bzs.next_out = PyBytes_AS_STRING(result) + data_size; in compress()
437 bzs->next_out = PyBytes_AS_STRING(result); in decompress_buf()
453 data_size = bzs->next_out - PyBytes_AS_STRING(result); in decompress_buf()
469 bzs->next_out = PyBytes_AS_STRING(result) + data_size; in decompress_buf()
Dreadline.c163 strcpy(copy, PyBytes_AS_STRING(encoded)); in parse_and_bind()
472 break_chars = strdup(PyBytes_AS_STRING(encoded)); in set_completer_delims()
570 old_entry = replace_history_entry(entry_number, PyBytes_AS_STRING(encoded), (void *)NULL); in py_replace_history()
596 add_history(PyBytes_AS_STRING(encoded)); in py_add_history()
782 rl_insert_text(PyBytes_AS_STRING(encoded)); in insert_text()
1021 result = strdup(PyBytes_AS_STRING(encoded)); in on_completion()
D_lzmamodule.c516 c->lzs.next_out = (uint8_t *)PyBytes_AS_STRING(result); in compress()
523 data_size = (char *)c->lzs.next_out - PyBytes_AS_STRING(result); in compress()
535 c->lzs.next_out = (uint8_t *)PyBytes_AS_STRING(result) + data_size; in compress()
911 lzs->next_out = (uint8_t *)PyBytes_AS_STRING(result); in decompress_buf()
919 data_size = (char *)lzs->next_out - PyBytes_AS_STRING(result); in decompress_buf()
935 lzs->next_out = (uint8_t *)PyBytes_AS_STRING(result) + data_size; in decompress_buf()
1374 &filter, (uint8_t *)PyBytes_AS_STRING(result)); in _lzma__encode_filter_properties_impl()
D_codecsmodule.c220 char *p = PyBytes_AS_STRING(v); in _codecs_escape_encode_impl()
224 assert(newsize - (p - PyBytes_AS_STRING(v)) >= 4); in _codecs_escape_encode_impl()
225 c = PyBytes_AS_STRING(data)[i]; in _codecs_escape_encode_impl()
244 if (_PyBytes_Resize(&v, (p - PyBytes_AS_STRING(v)))) { in _codecs_escape_encode_impl()
D_ssl.c2113 mem = PyBytes_AS_STRING(dest); in _ssl__SSLSocket_read_impl()
3154 data = PyBytes_AS_STRING(password_bytes); in _pwinfo_set()
3157 data = PyBytes_AS_STRING(password); in _pwinfo_set()
3276 PyBytes_AS_STRING(certfile_bytes)); in _ssl__SSLContext_load_cert_chain_impl()
3294 PyBytes_AS_STRING(keyfile ? keyfile_bytes : certfile_bytes), in _ssl__SSLContext_load_cert_chain_impl()
3491 PyBytes_AS_STRING(cadata_ascii), in _ssl__SSLContext_load_verify_locations_impl()
3504 cafile_buf = PyBytes_AS_STRING(cafile_bytes); in _ssl__SSLContext_load_verify_locations_impl()
3506 capath_buf = PyBytes_AS_STRING(capath_bytes); in _ssl__SSLContext_load_verify_locations_impl()
3716 nid = OBJ_sn2nid(PyBytes_AS_STRING(name_bytes)); in _ssl__SSLContext_set_ecdh_curve()
4162 nbytes = BIO_read(self->bio, PyBytes_AS_STRING(result), len); in _ssl_MemoryBIO_read_impl()
[all …]
/external/python/cpython2/Modules/
Dzlibmodule.c157 occupied = zst->next_out - (Byte *)PyBytes_AS_STRING(*buffer); in arrange_output_buffer_with_maximum()
180 zst->next_out = (Byte *)PyBytes_AS_STRING(*buffer) + occupied; in arrange_output_buffer_with_maximum()
268 (Byte *)PyBytes_AS_STRING(RetVal)) < 0) in PyZlib_compress()
372 (Byte *)PyBytes_AS_STRING(RetVal)); in PyZlib_decompress()
518 (Byte *)PyBytes_AS_STRING(RetVal)); in PyZlib_objcompress()
665 (Byte *)PyBytes_AS_STRING(RetVal)); in PyZlib_objdecompress()
748 (Byte *)PyBytes_AS_STRING(RetVal)); in PyZlib_flush()
927 (Byte *)PyBytes_AS_STRING(RetVal)); in PyZlib_unflush()
/external/python/cpython3/Python/
Dimportdl.c111 name_buf = PyBytes_AS_STRING(name); in _PyImport_LoadDynamicModuleWithSpec()
125 PyBytes_AS_STRING(pathbytes), in _PyImport_LoadDynamicModuleWithSpec()
Dmarshal.c117 p->buf = PyBytes_AS_STRING(p->str); in w_reserve()
429 w_pstring(PyBytes_AS_STRING(v), PyBytes_GET_SIZE(v), p); in w_complex_object()
463 w_pstring(PyBytes_AS_STRING(utf8), PyBytes_GET_SIZE(utf8), p); in w_complex_object()
1100 memcpy(PyBytes_AS_STRING(v), ptr, n); in r_object()
1600 wf.ptr = wf.buf = PyBytes_AS_STRING((PyBytesObject *)wf.str); in PyMarshal_WriteObjectToString()
1611 char *base = PyBytes_AS_STRING((PyBytesObject *)wf.str); in PyMarshal_WriteObjectToString()
/external/python/cpython3/Modules/cjkcodecs/
Dmultibytecodec.c168 PyBytes_AS_STRING(buf->outobj)); in expand_encodebuffer()
180 buf->outbuf = (unsigned char *)PyBytes_AS_STRING(buf->outobj) +orgpos; in expand_encodebuffer()
181 buf->outbuf_end = (unsigned char *)PyBytes_AS_STRING(buf->outobj) in expand_encodebuffer()
326 memcpy(buf->outbuf, PyBytes_AS_STRING(retstr), retstrsize); in multibytecodec_encerror()
491 buf.outbuf = (unsigned char *)PyBytes_AS_STRING(buf.outobj); in multibytecodec_encode()
526 PyBytes_AS_STRING(buf.outobj)); in multibytecodec_encode()
1306 ctrdata = PyBytes_AS_STRING(ctr); in mbstreamreader_iread()
1309 PyBytes_AS_STRING(cres), in mbstreamreader_iread()
1317 if (decoder_prepare_buffer(&buf, PyBytes_AS_STRING(cres), in mbstreamreader_iread()
/external/python/cpython2/Modules/_io/
Dtextio.c719 PyBytes_AS_STRING(self->errors)); in ascii_encode()
727 PyBytes_AS_STRING(self->errors), 1); in utf16be_encode()
735 PyBytes_AS_STRING(self->errors), -1); in utf16le_encode()
751 PyBytes_AS_STRING(self->errors), 0); in utf16_encode()
759 PyBytes_AS_STRING(self->errors), 1); in utf32be_encode()
767 PyBytes_AS_STRING(self->errors), -1); in utf32le_encode()
783 PyBytes_AS_STRING(self->errors), 0); in utf32_encode()
791 PyBytes_AS_STRING(self->errors)); in utf8_encode()
799 PyBytes_AS_STRING(self->errors)); in latin1_encode()
2270 input = PyBytes_AS_STRING(next_input); in textiowrapper_tell()
Dfileio.c263 name = PyBytes_AS_STRING(stringobj); in fileio_init()
575 PyBytes_AS_STRING(result) + total, in fileio_readall()
579 PyBytes_AS_STRING(result) + total, in fileio_readall()
642 ptr = PyBytes_AS_STRING(bytes); in fileio_read()
/external/python/cpython3/Objects/stringlib/
Dstringdefs.h21 #define STRINGLIB_STR PyBytes_AS_STRING
Djoin.h65 buffers[i].buf = PyBytes_AS_STRING(item); in STRINGLIB()
/external/python/cpython2/Include/
Dbytesobject.h7 #define PyBytes_AS_STRING PyString_AS_STRING macro
/external/python/cpython3/PC/
D_testconsole.c55 const wchar_t *p = (const wchar_t *)PyBytes_AS_STRING(s); in _testconsole_write_input_impl()
/external/tensorflow/tensorflow/python/lib/core/
Dpy_seq_tensor.cc317 out->assign(PyBytes_AS_STRING(v), PyBytes_GET_SIZE(v)); in ConvertOneString()
330 out->assign(PyBytes_AS_STRING(py_str), PyBytes_GET_SIZE(py_str)); in ConvertOneString()
/external/python/cpython3/Programs/
D_freeze_importlib.c105 data = (unsigned char *) PyBytes_AS_STRING(marshalled); in main()
/external/python/cpython3/Include/
Dbytesobject.h87 #define PyBytes_AS_STRING(op) (assert(PyBytes_Check(op)), \ macro

1234