MCPcopy Create free account
hub / github.com/cbeck88/visit_struct / test_visitor_ptr

Class test_visitor_ptr

test_visit_struct.cpp:64–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

62};
63
64struct test_visitor_ptr {
65 std::vector<spair> result;
66
67 template <typename C>
68 void operator()(const char* name, int C::*) {
69 result.emplace_back(spair{std::string{name}, "int"});
70 }
71
72 template <typename C>
73 void operator()(const char* name, float C::*) {
74 result.emplace_back(spair{std::string{name}, "float"});
75 }
76
77 template <typename C>
78 void operator()(const char* name, std::string C::*) {
79 result.emplace_back(spair{std::string{name}, "std::string"});
80 }
81};
82
83struct test_visitor_type {
84 std::vector<spair> result;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected