Classes | Macros | Functions
test_virtual_functions.cpp File Reference
#include "pybind11_tests.h"
#include "constructor_stats.h"
#include <pybind11/functional.h>
#include <thread>
Include dependency graph for test_virtual_functions.cpp:

Go to the source code of this file.

Classes

class  A_Repeat
 
class  A_Tpl
 
class  B_Repeat
 
class  B_Tpl
 
struct  Base
 
class  C_Repeat
 
class  C_Tpl
 
class  D_Repeat
 
class  D_Tpl
 
struct  DispatchIssue
 
class  ExampleVirt
 
class  Movable
 
class  NCVirt
 
class  NCVirtTrampoline
 
class  NonCopyable
 
class  PyA_Repeat
 
class  PyA_Tpl< Base >
 
class  PyB_Repeat
 
class  PyB_Tpl< Base >
 
class  PyC_Repeat
 
class  PyD_Repeat
 
class  PyExampleVirt
 

Macros

#define A_METHODS
 
#define B_METHODS
 
#define C_METHODS
 
#define D_METHODS
 

Functions

void initialize_inherited_virtuals (py::module &m)
 
static void test_gil ()
 
static void test_gil_from_thread ()
 
 TEST_SUBMODULE (virtual_functions, m)
 

Macro Definition Documentation

#define A_METHODS
Value:
public: \
virtual int unlucky_number() = 0; \
virtual std::string say_something(unsigned times) { \
std::string s = ""; \
for (unsigned i = 0; i < times; ++i) \
s += "hi"; \
} \
std::string say_everything() { \
return say_something(1) + " " + std::to_string(unlucky_number()); \
}
for(size_t i=1;i< poses.size();++i)
if n return
RealScalar s

Definition at line 341 of file test_virtual_functions.cpp.

#define B_METHODS
Value:
public: \
int unlucky_number() override { return 13; } \
std::string say_something(unsigned times) override { \
return "B says hi " + std::to_string(times) + " times"; \
} \
virtual double lucky_number() { return 7.0; }
return int(ret)+1
if n return

Definition at line 359 of file test_virtual_functions.cpp.

#define C_METHODS
Value:
public: \
int unlucky_number() override { return 4444; } \
double lucky_number() override { return 888; }
return int(ret)+1

Definition at line 369 of file test_virtual_functions.cpp.

#define D_METHODS

Definition at line 376 of file test_virtual_functions.cpp.

Function Documentation

void initialize_inherited_virtuals ( py::module m)

Definition at line 462 of file test_virtual_functions.cpp.

static void test_gil ( )
static

Definition at line 166 of file test_virtual_functions.cpp.

static void test_gil_from_thread ( )
static

Definition at line 180 of file test_virtual_functions.cpp.

TEST_SUBMODULE ( virtual_functions  ,
m   
)

Definition at line 192 of file test_virtual_functions.cpp.



gtsam
Author(s):
autogenerated on Sat May 8 2021 02:51:40