Skip to content

Commit

Permalink
fix typo in docs (fixes #308)
Browse files Browse the repository at this point in the history
  • Loading branch information
wjakob committed Oct 2, 2023
1 parent b9a2231 commit 62c8949
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/basics.rst
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ function ``bark_later()`` that calls :cpp:func:`nb::cpp_function()
nb::class_<Dog>(m, "Dog")
// ... skipped ...
.def("bark_later", [](const Dog &p) {
auto callback = [name = p.name()] {
auto callback = [name = p.name] {
nb::print(nb::str("{}: woof!").format(name));
};
return nb::cpp_function(callback);
Expand Down

0 comments on commit 62c8949

Please sign in to comment.