From 64830e3333f1921f3094b5afc35c353c74860465 Mon Sep 17 00:00:00 2001 From: Jason Rhinelander Date: Mon, 29 Aug 2016 16:58:59 -0400 Subject: [PATCH] Doc fix for OVERLOAD*_NAME macros The documentation says the string-valued python function name goes after the C++ function, but it actually goes before it. --- docs/advanced.rst | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/advanced.rst b/docs/advanced.rst index 96b64eae9..301860061 100644 --- a/docs/advanced.rst +++ b/docs/advanced.rst @@ -298,9 +298,10 @@ functions, and :func:`PYBIND11_OVERLOAD` should be used for functions which have a default implementation. There are also two alternate macros :func:`PYBIND11_OVERLOAD_PURE_NAME` and -:func:`PYBIND11_OVERLOAD_NAME` which take a string-valued name argument -after the *Name of the function* slot. This is useful when the C++ and Python -versions of the function have different names, e.g. ``operator()`` vs ``__call__``. +:func:`PYBIND11_OVERLOAD_NAME` which take a string-valued name argument between +the *Parent class* and *Name of the function* slots. This is useful when the +C++ and Python versions of the function have different names, e.g. +``operator()`` vs ``__call__``. The binding code also needs a few minor adaptations (highlighted):