Go to the source code of this file.
◆ 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"; \
return s; \
} \
std::string say_everything() { \
return say_something(1) + " " + std::to_string(unlucky_number()); \
}
Definition at line 342 of file test_virtual_functions.cpp.
◆ 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; }
Definition at line 360 of file test_virtual_functions.cpp.
◆ C_METHODS
Value:public: \
int unlucky_number() override { return 4444; } \
double lucky_number() override { return 888; }
Definition at line 370 of file test_virtual_functions.cpp.
◆ D_METHODS
◆ initialize_inherited_virtuals()
void initialize_inherited_virtuals |
( |
py::module_ & |
m | ) |
|
◆ TEST_SUBMODULE()
TEST_SUBMODULE |
( |
virtual_functions |
, |
|
|
m |
|
|
) |
| |