mirror of
https://github.com/boostorg/openmethod.git
synced 2026-01-24 06:02:11 +00:00
24 lines
389 B
C++
24 lines
389 B
C++
// animal.hpp
|
|
|
|
#ifndef ANIMAL_HPP
|
|
#define ANIMAL_HPP
|
|
|
|
#include <boost/openmethod.hpp>
|
|
#include <string>
|
|
|
|
namespace animals {
|
|
|
|
struct Animal {
|
|
Animal(std::string name) : name(name) {
|
|
}
|
|
std::string name;
|
|
virtual ~Animal() = default;
|
|
};
|
|
|
|
BOOST_OPENMETHOD(
|
|
poke, (std::ostream&, boost::openmethod::virtual_ptr<Animal>), void);
|
|
|
|
} // namespace animals
|
|
|
|
#endif // ANIMAL_HPP
|