diff options
author | Andy Maloney <asmaloney@gmail.com> | 2021-01-13 23:14:45 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-13 23:14:45 -0500 |
commit | 14b375123c0ee2c1ce2d5e6e327e386672dc212a (patch) | |
tree | 69b6345a6a0816896ca7ab12305dc16af398a031 | |
parent | 210c8c218ff7e2828ad7c396b106cd7dfbf5e095 (diff) | |
download | platform_external_python_pybind11-14b375123c0ee2c1ce2d5e6e327e386672dc212a.tar.gz platform_external_python_pybind11-14b375123c0ee2c1ce2d5e6e327e386672dc212a.tar.bz2 platform_external_python_pybind11-14b375123c0ee2c1ce2d5e6e327e386672dc212a.zip |
docs: fix example code in Exceptions section (match vs. matches) (#2781)
-rw-r--r-- | docs/advanced/exceptions.rst | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/advanced/exceptions.rst b/docs/advanced/exceptions.rst index 32ea699..7a4d6cb 100644 --- a/docs/advanced/exceptions.rst +++ b/docs/advanced/exceptions.rst @@ -196,7 +196,7 @@ For example: } catch (py::error_already_set &e) { if (e.matches(PyExc_FileNotFoundError)) { py::print("missing.txt not found"); - } else if (e.match(PyExc_PermissionError)) { + } else if (e.matches(PyExc_PermissionError)) { py::print("missing.txt found but not accessible"); } else { throw; |