mirror of
https://github.com/pybind/pybind11.git
synced 2024-11-21 20:55:11 +00:00
be0d804523
This adds support for a `py::args_kw_only()` annotation that can be specified between `py::arg` annotations to indicate that any following arguments are keyword-only. This allows you to write: m.def("f", [](int a, int b) { /* ... */ }, py::arg("a"), py::args_kw_only(), py::arg("b")); and have it work like Python 3's: def f(a, *, b): # ... with respect to how `a` and `b` arguments are accepted (that is, `a` can be positional or by keyword; `b` can only be specified by keyword). |
||
---|---|---|
.. | ||
_static | ||
advanced | ||
basics.rst | ||
benchmark.py | ||
benchmark.rst | ||
changelog.rst | ||
classes.rst | ||
compiling.rst | ||
conf.py | ||
Doxyfile | ||
faq.rst | ||
index.rst | ||
intro.rst | ||
limitations.rst | ||
Makefile | ||
pybind11_vs_boost_python1.png | ||
pybind11_vs_boost_python1.svg | ||
pybind11_vs_boost_python2.png | ||
pybind11_vs_boost_python2.svg | ||
pybind11-logo.png | ||
reference.rst | ||
release.rst | ||
requirements.txt | ||
upgrade.rst |