/external/python/cpython2/Lib/ctypes/test/ |
D | test_python_api.py | 21 PyString_FromStringAndSize = pythonapi.PyString_FromStringAndSize 23 PyString_FromStringAndSize.restype = py_object 24 PyString_FromStringAndSize.argtypes = c_char_p, c_py_ssize_t 26 self.assertEqual(PyString_FromStringAndSize("abcdefghi", 3), "abc")
|
/external/python/cpython2/Modules/ |
D | imageop.c | 145 rv = PyString_FromStringAndSize(NULL, nlen); in imageop_crop() 198 rv = PyString_FromStringAndSize(NULL, nlen); in imageop_scale() 241 rv = PyString_FromStringAndSize(NULL, len); in imageop_tovideo() 289 rv = PyString_FromStringAndSize(NULL, (len+7)/8); in imageop_grey2mono() 328 rv = PyString_FromStringAndSize(NULL, (len+1)/2); in imageop_grey2grey4() 365 rv = PyString_FromStringAndSize(NULL, (len+3)/4); in imageop_grey2grey2() 401 rv = PyString_FromStringAndSize(NULL, (len+7)/8); in imageop_dither2mono() 445 rv = PyString_FromStringAndSize(NULL, (len+3)/4); in imageop_dither2grey2() 487 rv = PyString_FromStringAndSize(NULL, nlen); in imageop_mono2grey() 527 rv = PyString_FromStringAndSize(NULL, nlen); in imageop_grey22grey() [all …]
|
D | stropmodule.c | 50 item = PyString_FromStringAndSize(s+j, i-j); in split_whitespace() 64 item = PyString_FromStringAndSize( in split_whitespace() 125 item = PyString_FromStringAndSize(s+j, i-j); in strop_splitfields() 140 item = PyString_FromStringAndSize(s+j, len-j); in strop_splitfields() 201 if (!(res = PyString_FromStringAndSize((char*)NULL, sz))) in strop_joinfields() 410 return PyString_FromStringAndSize(s+i, j-i); in do_strip() 470 newstr = PyString_FromStringAndSize(NULL, n); in strop_lower() 509 newstr = PyString_FromStringAndSize(NULL, n); in strop_upper() 549 newstr = PyString_FromStringAndSize(NULL, n); in strop_capitalize() 638 out = PyString_FromStringAndSize(NULL, i+j); in strop_expandtabs() [all …]
|
D | binascii.c | 211 if ( (rv=PyString_FromStringAndSize(NULL, bin_len)) == NULL ) { in binascii_a2b_uu() 297 if ( (rv=PyString_FromStringAndSize(NULL, 2 + (bin_len+2)/3*4)) == NULL ) { in binascii_b2a_uu() 386 if ( (rv=PyString_FromStringAndSize(NULL, bin_len)) == NULL ) { in binascii_a2b_base64() 458 rv = PyString_FromStringAndSize("", 0); in binascii_a2b_base64() 493 if ( (rv=PyString_FromStringAndSize(NULL, bin_len*2 + 3)) == NULL ) { in binascii_b2a_base64() 558 if ( (rv=PyString_FromStringAndSize(NULL, len+2)) == NULL ) { in binascii_a2b_hqx() 636 if ( (rv=PyString_FromStringAndSize(NULL, len*2+2)) == NULL ) { in binascii_rlecode_hqx() 700 if ( (rv=PyString_FromStringAndSize(NULL, len*2+2)) == NULL ) { in binascii_b2a_hqx() 750 return PyString_FromStringAndSize("", 0); in binascii_rledecode_hqx() 759 if ( (rv=PyString_FromStringAndSize(NULL, out_len)) == NULL ) { in binascii_rledecode_hqx() [all …]
|
D | audioop.c | 786 rv = PyString_FromStringAndSize(NULL, len); in audioop_mul() 827 rv = PyString_FromStringAndSize(NULL, len/2); in audioop_tomono() 873 rv = PyString_FromStringAndSize(NULL, len*2); in audioop_tostereo() 922 rv = PyString_FromStringAndSize(NULL, len1); in audioop_add() 974 rv = PyString_FromStringAndSize(NULL, len); in audioop_bias() 1013 rv = PyString_FromStringAndSize(NULL, len); in audioop_reverse() 1055 rv = PyString_FromStringAndSize(NULL, (len/size)*size2); in audioop_lin2lin() 1174 str = PyString_FromStringAndSize(NULL, 0); in audioop_ratecv() 1188 str = PyString_FromStringAndSize(NULL, in audioop_ratecv() 1216 rv = PyString_FromStringAndSize("", 0); in audioop_ratecv() [all …]
|
D | dbmmodule.c | 118 return PyString_FromStringAndSize(drec.dptr, drec.dsize); in dbm_subscript() 230 item = PyString_FromStringAndSize(key.dptr, key.dsize); in dbm_keys() 277 return PyString_FromStringAndSize(val.dptr, val.dsize); in dbm_get() 300 return PyString_FromStringAndSize(val.dptr, val.dsize); in dbm_setdefault() 302 defvalue = PyString_FromStringAndSize(NULL, 0); in dbm_setdefault()
|
D | md5module.c | 96 return PyString_FromStringAndSize((char *)aDigest, 16); in md5_digest() 129 return PyString_FromStringAndSize((char*)hexdigest, 32); in md5_hexdigest() 181 return PyString_FromStringAndSize("MD5", 3); in md5_get_name()
|
D | nismodule.c | 120 key = PyString_FromStringAndSize(inkey, inkeylen); in nis_foreach() 121 val = PyString_FromStringAndSize(inval, invallen); in nis_foreach() 153 res = PyString_FromStringAndSize (domain, strlen(domain)); in nis_get_default_domain() 185 res = PyString_FromStringAndSize (match, len); in nis_match()
|
D | gdbmmodule.c | 134 v = PyString_FromStringAndSize(drec.dptr, drec.dsize); in dbm_subscript() 258 item = PyString_FromStringAndSize(key.dptr, key.dsize); in dbm_keys() 309 v = PyString_FromStringAndSize(key.dptr, key.dsize); in dbm_firstkey() 341 v = PyString_FromStringAndSize(nextkey.dptr, nextkey.dsize); in dbm_nextkey()
|
D | bz2module.c | 253 v = PyString_FromStringAndSize((char *)NULL, total_v_size); in Util_GetLine() 466 PyString_FromStringAndSize(NULL, skip); in Util_ReadAheadGetLineSkip() 472 PyString_FromStringAndSize(NULL, skip+len); in Util_ReadAheadGetLineSkip() 548 ret = PyString_FromStringAndSize((char *)NULL, buffersize); in BZ2File_read() 726 big_buffer = PyString_FromStringAndSize( in BZ2File_readlines() 746 line = PyString_FromStringAndSize(q, p-q); in BZ2File_readlines() 769 line = PyString_FromStringAndSize(buffer, nfilled); in BZ2File_readlines() 956 line = PyString_FromStringAndSize(buffer, in BZ2File_writelines() 1635 ret = PyString_FromStringAndSize(NULL, SMALLCHUNK); in BZ2Comp_compress() 1715 ret = PyString_FromStringAndSize(NULL, SMALLCHUNK); in BZ2Comp_flush() [all …]
|
D | mmapmodule.c | 211 return PyString_FromStringAndSize(&self->data[self->pos++], 1); in mmap_read_byte_method() 233 result = PyString_FromStringAndSize(start, (eol - start)); in mmap_read_line_method() 253 result = PyString_FromStringAndSize(&self->data[self->pos], num_bytes); in mmap_read_method() 746 return PyString_FromStringAndSize(self->data + i, 1); in mmap_item() 764 return PyString_FromStringAndSize(self->data + ilow, ihigh-ilow); in mmap_slice() 782 return PyString_FromStringAndSize(self->data + i, 1); in mmap_subscript() 793 return PyString_FromStringAndSize("", 0); in mmap_subscript() 795 return PyString_FromStringAndSize(self->data + start, in mmap_subscript() 808 result = PyString_FromStringAndSize(result_buf, in mmap_subscript()
|
D | cStringIO.c | 121 return PyString_FromStringAndSize(((IOobject*)self)->buf, in IO_cgetval() 144 return PyString_FromStringAndSize(self->buf, s); in IO_getval() 191 return PyString_FromStringAndSize(output, n); in IO_read() 239 return PyString_FromStringAndSize(output, n); in IO_readline() 262 line = PyString_FromStringAndSize (output, n); in IO_readlines()
|
D | svmodule.c | 50 if (!(output = PyString_FromStringAndSize( in svc_conversion() 155 if (!(f1 = PyString_FromStringAndSize(obcapture, fieldsize))) in svc_GetFields() 157 if (!(f2 = PyString_FromStringAndSize(obcapture + fieldsize, in svc_GetFields() 537 if (!(videodata = PyString_FromStringAndSize(NULL, bytes))) in sv_CaptureBurst() 617 if (!(videodata = PyString_FromStringAndSize(NULL, bytes))) in sv_CaptureOneFrame() 851 if (!(output = PyString_FromStringAndSize(NULL, in sv_conversion()
|
D | fmmodule.c | 69 return PyString_FromStringAndSize(fontname, len); in fh_getfontname() 82 return PyString_FromStringAndSize(comment, len); in fh_getcomment()
|
D | fcntlmodule.c | 58 return PyString_FromStringAndSize(buf, len); in fcntl_fcntl() 168 return PyString_FromStringAndSize(buf, len); in fcntl_ioctl() 189 return PyString_FromStringAndSize(buf, len); in fcntl_ioctl()
|
/external/python/cpython2/Objects/ |
D | bufferobject.c | 364 return PyString_FromStringAndSize((const char *)ptr, size); in buffer_str() 418 ob = PyString_FromStringAndSize(NULL, size + count); in buffer_concat() 447 ob = PyString_FromStringAndSize(NULL, size * count); in buffer_repeat() 475 return PyString_FromStringAndSize((char *)ptr + idx, 1); in buffer_item() 493 return PyString_FromStringAndSize((char *)ptr + left, in buffer_slice() 522 return PyString_FromStringAndSize("", 0); in buffer_subscript() 524 return PyString_FromStringAndSize((char *)p + start, in buffer_subscript() 539 result = PyString_FromStringAndSize(result_buf, in buffer_subscript()
|
D | stringobject.c | 57 PyString_FromStringAndSize(const char *str, Py_ssize_t size) in PyString_FromStringAndSize() function 269 string = PyString_FromStringAndSize(NULL, n); in PyString_FromFormatV() 423 str = PyString_FromStringAndSize(s, size); in PyString_Decode() 503 str = PyString_FromStringAndSize(s, size); in PyString_Encode() 616 v = PyString_FromStringAndSize((char *)NULL, newlen); in PyString_DecodeEscape() 937 v = PyString_FromStringAndSize((char *)NULL, newsize); in PyString_Repr() 1005 return PyString_FromStringAndSize(t->ob_sval, Py_SIZE(t)); in string_str() 1147 return PyString_FromStringAndSize(a->ob_sval + i, j-i); in string_slice() 1181 v = PyString_FromStringAndSize(&pchar, 1); in string_item() 1320 return PyString_FromStringAndSize("", 0); in string_subscript() [all …]
|
D | fileobject.c | 1076 v = PyString_FromStringAndSize((char *)NULL, buffersize); in file_read() 1280 v = PyString_FromStringAndSize(buf, pvfree - buf); in getline_via_fgets() 1309 v = PyString_FromStringAndSize(buf, p - buf); in getline_via_fgets() 1330 v = PyString_FromStringAndSize((char*)NULL, (int)total_v_size); in getline_via_fgets() 1423 v = PyString_FromStringAndSize((char *)NULL, total_v_size); in get_line() 1603 v = PyString_FromStringAndSize(s, len-1); in PyFile_GetLine() 1729 big_buffer = PyString_FromStringAndSize( in file_readlines() 1749 line = PyString_FromStringAndSize(q, p-q); in file_readlines() 1768 line = PyString_FromStringAndSize(buffer, nfilled); in file_readlines() 1953 line = PyString_FromStringAndSize(buffer, in file_writelines() [all …]
|
/external/python/cpython2/Modules/_multiprocessing/ |
D | connection.h | 178 result = PyString_FromStringAndSize(self->buffer, res); in connection_recvbytes() 180 result = PyString_FromStringAndSize(freeme, res); in connection_recvbytes() 318 temp = PyString_FromStringAndSize(self->buffer, res); in connection_recv_obj() 320 temp = PyString_FromStringAndSize(freeme, res); in connection_recv_obj()
|
/external/python/cpython2/Mac/Modules/ |
D | MacOS.c | 320 creator = PyString_FromStringAndSize( in MacOS_GetCreatorAndType() 322 type = PyString_FromStringAndSize((char *)&info.fdType, 4); in MacOS_GetCreatorAndType() 353 creator = PyString_FromStringAndSize((char*)&(finfo->fileCreator), 4); in MacOS_GetCreatorAndType() 354 type = PyString_FromStringAndSize((char*)&(finfo->fileType), 4); in MacOS_GetCreatorAndType()
|
/external/python/cpython2/Modules/_sqlite/ |
D | cursor.c | 185 key = PyString_FromStringAndSize(type_start, pos - type_start); in pysqlite_build_row_cast_map() 210 py_decltype = PyString_FromStringAndSize(decltype, pos - decltype); in pysqlite_build_row_cast_map() 254 return PyString_FromStringAndSize(colname, pos - colname); in _pysqlite_build_column_name() 280 return PyString_FromStringAndSize(val_str, size); in pysqlite_unicode_from_string() 338 item = PyString_FromStringAndSize(val_str, nbytes); in _pysqlite_fetch_one_row() 378 converted = PyString_FromStringAndSize(val_str, nbytes); in _pysqlite_fetch_one_row()
|
/external/tensorflow/tensorflow/python/util/ |
D | py_checkpoint_reader.i | 36 tensorflow::make_safe(PyString_FromStringAndSize(v.first.c_str(), 79 tensorflow::make_safe(PyString_FromStringAndSize(v.first.c_str(), v.first.size())));
|
/external/python/cpython2/Python/ |
D | mactoolboxglue.c | 179 return PyString_FromStringAndSize((char *)&tmp, 4); in PyMac_BuildOSType() 213 return PyString_FromStringAndSize((char *)&s[1], (int)s[0]); in PyMac_BuildStr255() 223 return PyString_FromStringAndSize((char *)&s[1], (int)s[0]); in PyMac_BuildOptStr255()
|
/external/python/cpython2/RISCOS/Modules/ |
D | swimodule.c | 116 return PyString_FromStringAndSize((char*)self->block+s,e-s); in PyBlock_ToString() 128 return PyString_FromStringAndSize((char*)self->block+s,i-s); in PyBlock_NullString() 140 return PyString_FromStringAndSize((char*)self->block+s,i-s); in PyBlock_CtrlString() 424 return PyString_FromStringAndSize((char*)s, l); in swi_string()
|
/external/python/cpython2/Include/ |
D | bytesobject.h | 11 #define PyBytes_FromStringAndSize PyString_FromStringAndSize
|