Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
pybind11
Commits
55dc1319
Commit
55dc1319
authored
Nov 14, 2017
by
Antony Lee
Committed by
Jason Rhinelander
May 24, 2018
Browse files
Clarify docs for functions taking bytes and not str.
parent
e763f046
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
1 deletion
+4
-1
.gitignore
.gitignore
+1
-0
docs/advanced/cast/strings.rst
docs/advanced/cast/strings.rst
+3
-1
No files found.
.gitignore
View file @
55dc1319
...
...
@@ -27,6 +27,7 @@ MANIFEST
*.py[co]
*.egg-info
*~
.*.swp
.DS_Store
/dist
/build
...
...
docs/advanced/cast/strings.rst
View file @
55dc1319
...
...
@@ -58,7 +58,9 @@ Passing bytes to C++
--------------------
A Python ``bytes`` object will be passed to C++ functions that accept
``std::string`` or ``char*`` *without* conversion.
``std::string`` or ``char*`` *without* conversion. On Python 3, in order to
make a function *only* accept ``bytes`` (and not ``str``), declare it as taking
a ``py::bytes`` argument.
Returning C++ strings to Python
...
...
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