Lines Matching defs:bytes
156 /* Number of bytes needed is: offsetof(PyLongObject, ob_digit) +
815 _PyLong_FromByteArray(const unsigned char* bytes, size_t n,
818 const unsigned char* pstartbyte; /* LSB of bytes */
820 const unsigned char* pendbyte; /* MSB of bytes */
821 size_t numsignificantbytes; /* number of bytes that matter */
830 pstartbyte = bytes;
831 pendbyte = bytes + n - 1;
835 pstartbyte = bytes + n - 1;
836 pendbyte = bytes;
844 significant byte. Leading 0 bytes are insignificant if the number
845 is positive, and leading 0xff bytes if negative. */
858 actually has 2 significant bytes. OTOH, 0xff0001 ==
882 8-bit bytes and (probably) 15-bit Python digits.*/
927 unsigned char* bytes, size_t n,
936 size_t j; /* # bytes filled */
937 unsigned char* p; /* pointer to next byte in bytes */
957 p = bytes;
961 p = bytes + n - 1;
1001 /* Store as many bytes as possible. */
1043 /* Fill remaining bytes with copies of the sign bit. */
1203 long long bytes;
1225 bytes = -(sdigit)v->ob_digit[0];
1228 bytes = 0;
1231 bytes = v->ob_digit[0];
1234 res = _PyLong_AsByteArray((PyLongObject *)v, (unsigned char *)&bytes,
1245 return bytes;
1255 unsigned long long bytes;
1273 res = _PyLong_AsByteArray((PyLongObject *)vv, (unsigned char *)&bytes,
1280 return bytes;
2640 * Reports an invalid literal as a bytes object.
4146 using close to SIZE_T_MAX bytes of memory each. */
5660 Returns size in memory, in bytes.
5842 Length of bytes object to use. An OverflowError is raised if the
5843 integer is not representable with the given number of bytes. Default
5857 Return an array of bytes representing an integer.
5866 PyObject *bytes;
5886 bytes = PyBytes_FromStringAndSize(NULL, length);
5887 if (bytes == NULL)
5891 (unsigned char *)PyBytes_AS_STRING(bytes),
5893 Py_DECREF(bytes);
5897 return bytes;
5904 bytes as bytes_obj: object
5905 Holds the array of bytes to convert. The argument must either
5906 support the buffer protocol or be an iterable object producing bytes.
5919 Return the integer represented by the given array of bytes.
5928 PyObject *long_obj, *bytes;
5942 bytes = PyObject_Bytes(bytes_obj);
5943 if (bytes == NULL)
5947 (unsigned char *)PyBytes_AS_STRING(bytes), Py_SIZE(bytes),
5949 Py_DECREF(bytes);
6014 bytes, or bytearray instance representing an integer literal in the\n\
6112 {"sizeof_digit", "size in bytes of the C type used to represent a digit"},