Commit ce9d6e2c by François Becker Committed by Jason Rhinelander

Fixed typo in classes.rst (#1388)

Fixed typos (erroneous `;`) in `classes.rst`.
parent 5ef1af13
...@@ -46,7 +46,7 @@ Normally, the binding code for these classes would look as follows: ...@@ -46,7 +46,7 @@ Normally, the binding code for these classes would look as follows:
.. code-block:: cpp .. code-block:: cpp
PYBIND11_MODULE(example, m) { PYBIND11_MODULE(example, m) {
py::class_<Animal>(m, "Animal"); py::class_<Animal>(m, "Animal")
.def("go", &Animal::go); .def("go", &Animal::go);
py::class_<Dog, Animal>(m, "Dog") py::class_<Dog, Animal>(m, "Dog")
...@@ -95,7 +95,7 @@ The binding code also needs a few minor adaptations (highlighted): ...@@ -95,7 +95,7 @@ The binding code also needs a few minor adaptations (highlighted):
:emphasize-lines: 2,3 :emphasize-lines: 2,3
PYBIND11_MODULE(example, m) { PYBIND11_MODULE(example, m) {
py::class_<Animal, PyAnimal /* <--- trampoline*/>(m, "Animal"); py::class_<Animal, PyAnimal /* <--- trampoline*/>(m, "Animal")
.def(py::init<>()) .def(py::init<>())
.def("go", &Animal::go); .def("go", &Animal::go);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment