Skip to content

Commit

Permalink
pythongh-121477: mention new PyLong_*Bytes() functions in PyLong_From…
Browse files Browse the repository at this point in the history
…String() (python#121478)

* pythongh-121477: mention new PyLong_*Bytes() functions in PyLong_FromString()

* Update Doc/c-api/long.rst

---------

Co-authored-by: Kumar Aditya <[email protected]>
  • Loading branch information
skirpichev and kumaraditya303 authored Aug 17, 2024
1 parent e9287ea commit ce4b9c8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Doc/c-api/long.rst
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,9 @@ distinguished from a number. Use :c:func:`PyErr_Occurred` to disambiguate.
ignored. If there are no digits or *str* is not NULL-terminated following the
digits and trailing whitespace, :exc:`ValueError` will be raised.
.. seealso:: Python methods :meth:`int.to_bytes` and :meth:`int.from_bytes`
to convert a :c:type:`PyLongObject` to/from an array of bytes in base
``256``. You can call those from C using :c:func:`PyObject_CallMethod`.
.. seealso:: :c:func:`PyLong_AsNativeBytes()` and
:c:func:`PyLong_FromNativeBytes()` functions can be used to convert
a :c:type:`PyLongObject` to/from an array of bytes in base ``256``.
.. c:function:: PyObject* PyLong_FromUnicodeObject(PyObject *u, int base)
Expand Down

0 comments on commit ce4b9c8

Please sign in to comment.