MCPcopy Create free account
hub / github.com/bitwizeshift/result / report_destructor

Class report_destructor

test/src/result.test.cpp:153–167  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

151};
152
153struct report_destructor
154{
155 report_destructor() : output{nullptr}{}
156 report_destructor(bool* b) : output{b}{}
157 report_destructor(const report_destructor&) = default;
158 report_destructor(report_destructor&&) = default;
159
160 auto operator=(const report_destructor&) -> report_destructor& = default;
161 auto operator=(report_destructor&&) -> report_destructor& = default;
162
163 ~report_destructor() {
164 *output = true;
165 }
166 bool* output;
167};
168
169struct base
170{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected