pybind11
string-view
About this project
Changelog
The Basics
First steps
Object-oriented code
Build systems
Advanced Topics
Functions
Classes
Exceptions
Smart pointers
Type conversions
Python C++ interface
Embedding the interpreter
Miscellaneous
Extra Information
Frequently asked questions
Benchmark
Limitations
Reference
pybind11
Docs
»
pybind11 — Seamless operability between C++11 and Python
Edit on GitHub
pybind11 — Seamless operability between C++11 and Python
¶
About this project
Changelog
The Basics
First steps
Compiling the test cases
Header and namespace conventions
Creating bindings for a simple function
Keyword arguments
Default arguments
Exporting variables
Supported data types
Object-oriented code
Creating bindings for a custom type
Keyword and default arguments
Binding lambda functions
Instance and static fields
Dynamic attributes
Inheritance
Overloaded methods
Enumerations and internal types
Build systems
Building with setuptools
Building with cppimport
Building with CMake
Generating binding code automatically
Advanced Topics
Functions
Return value policies
Additional call policies
Python objects as arguments
Accepting *args and **kwargs
Default arguments revisited
Non-converting arguments
Allow/Prohibiting None arguments
Overload resolution order
Classes
Overriding virtual functions in Python
Combining virtual functions and inheritance
Extended trampoline class functionality
Custom constructors
Non-public destructors
Implicit conversions
Static properties
Operator overloading
Pickling support
Multiple Inheritance
Exceptions
Built-in exception translation
Registering custom translators
Smart pointers
std::unique_ptr
std::shared_ptr
Custom smart pointers
Type conversions
Overview
Strings, bytes and Unicode conversions
STL containers
Functional
Chrono
Eigen
Custom type casters
Python C++ interface
Python types
NumPy
Utilities
Embedding the interpreter
Getting started
Executing Python code
Importing modules
Adding embedded modules
Interpreter lifetime
Sub-interpreter support
Miscellaneous
General notes regarding convenience macros
Global Interpreter Lock (GIL)
Binding sequence data types, iterators, the slicing protocol, etc.
Partitioning code over multiple extension modules
Module Destructors
Generating documentation using Sphinx
Extra Information
Frequently asked questions
Benchmark
Limitations
Reference
Read the Docs
v: string-view
Versions
latest
stable
string-view
Downloads
pdf
htmlzip
epub
On Read the Docs
Project Home
Builds
Free document hosting provided by
Read the Docs
.