Issue #23848: Expose _Py_DumpHexadecimal()

This function will be reused by faulthandler.
This commit is contained in:
Victor Stinner 2016-03-23 10:32:26 +01:00
parent 5dacbd4c42
commit bd31b7c483
2 changed files with 23 additions and 9 deletions

View file

@ -94,7 +94,20 @@ PyAPI_FUNC(void) _Py_DumpASCII(int fd, PyObject *text);
/* Format an integer as decimal into the file descriptor fd.
This function is signal safe. */
PyAPI_FUNC(void) _Py_DumpDecimal(int fd, unsigned long value);
PyAPI_FUNC(void) _Py_DumpDecimal(
int fd,
unsigned long value);
/* Format an integer as hexadecimal into the file descriptor fd with at least
width digits.
The maximum width is sizeof(unsigned long)*2 digits.
This function is signal safe. */
PyAPI_FUNC(void) _Py_DumpHexadecimal(
int fd,
unsigned long value,
Py_ssize_t width);
#endif /* !Py_LIMITED_API */