Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-11-19 09:50:50

0001 #ifndef Py_INTERNAL_STRHEX_H
0002 #define Py_INTERNAL_STRHEX_H
0003 #ifdef __cplusplus
0004 extern "C" {
0005 #endif
0006 
0007 #ifndef Py_BUILD_CORE
0008 #  error "this header requires Py_BUILD_CORE define"
0009 #endif
0010 
0011 // Returns a str() containing the hex representation of argbuf.
0012 // Export for '_hashlib' shared extension.
0013 PyAPI_FUNC(PyObject*) _Py_strhex(const
0014     char* argbuf,
0015     const Py_ssize_t arglen);
0016 
0017 // Returns a bytes() containing the ASCII hex representation of argbuf.
0018 extern PyObject* _Py_strhex_bytes(
0019     const char* argbuf,
0020     const Py_ssize_t arglen);
0021 
0022 // These variants include support for a separator between every N bytes:
0023 extern PyObject* _Py_strhex_with_sep(
0024     const char* argbuf,
0025     const Py_ssize_t arglen,
0026     PyObject* sep,
0027     const int bytes_per_group);
0028 
0029 // Export for 'binascii' shared extension
0030 PyAPI_FUNC(PyObject*) _Py_strhex_bytes_with_sep(
0031     const char* argbuf,
0032     const Py_ssize_t arglen,
0033     PyObject* sep,
0034     const int bytes_per_group);
0035 
0036 #ifdef __cplusplus
0037 }
0038 #endif
0039 #endif /* !Py_INTERNAL_STRHEX_H */