Skip to content

Commit 3370fe1

Browse files
Enhance: edit doc py::native_enum feature in upgrade.rst (#5885)
* Enhance: edit doc py::native_enum feature in upgrade.rst Added information about the inclusion requirement for py::native_enum feature. * [skip ci] Polish wording --------- Co-authored-by: Ralf W. Grosse-Kunstleve <rgrossekunst@nvidia.com>
1 parent 1ccaad5 commit 3370fe1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

docs/upgrade.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ C++ enumerations as native Python types — typically standard-library
4848
``enum.Enum`` or related subclasses. This provides improved integration with
4949
Python's enum system, compared to the older (now deprecated) ``py::enum_``.
5050
See `#5555 <https://github.com/pybind/pybind11/pull/5555>`_ for details.
51+
Note that ``#include <pybind11/native_enum.h>`` is not included automatically
52+
and must be added explicitly.
5153

5254
Functions exposed with pybind11 are now pickleable. This removes a
5355
long-standing obstacle when using pybind11-bound functions with Python features

0 commit comments

Comments
 (0)