Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
gaoqiong
pybind11
Commits
baec23c2
Commit
baec23c2
authored
Feb 17, 2017
by
Wenzel Jakob
Browse files
minor stl caster clarifications
parent
e72eaa47
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
docs/advanced/cast/stl.rst
docs/advanced/cast/stl.rst
+6
-4
No files found.
docs/advanced/cast/stl.rst
View file @
baec23c2
...
@@ -5,10 +5,12 @@ Automatic conversion
...
@@ -5,10 +5,12 @@ Automatic conversion
====================
====================
When including the additional header file :file:`pybind11/stl.h`, conversions
When including the additional header file :file:`pybind11/stl.h`, conversions
between ``std::vector<>``, ``std::list<>``, ``std::set<>``, and ``std::map<>``
between ``std::vector<>``/``std::list<>``/``std::array<>``,
and the Python ``list``, ``set`` and ``dict`` data structures are automatically
``std::set<>``/``std::unordered_set<>``, and
enabled. The types ``std::pair<>`` and ``std::tuple<>`` are already supported
``std::map<>``/``std::unordered_map<>`` and the Python ``list``, ``set`` and
out of the box with just the core :file:`pybind11/pybind11.h` header.
``dict`` data structures are automatically enabled. The types ``std::pair<>``
and ``std::tuple<>`` are already supported out of the box with just the core
:file:`pybind11/pybind11.h` header.
The major downside of these implicit conversions is that containers must be
The major downside of these implicit conversions is that containers must be
converted (i.e. copied) on every Python->C++ and C++->Python transition, which
converted (i.e. copied) on every Python->C++ and C++->Python transition, which
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment