MCPcopy Create free account
hub / github.com/aff3ct/aff3ct / equivalent

Method equivalent

src/Module/Monitor/MI/Monitor_MI.cpp:78–102  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

76
77template<typename B, typename R>
78bool
79Monitor_MI<B, R>::equivalent(const Monitor_MI<B, R>& m, bool do_throw) const
80{
81 if (get_N() != m.get_N())
82 {
83 if (!do_throw) return false;
84
85 std::stringstream message;
86 message << "'get_N()' is different than 'm.get_N()' ('get_N()' = " << get_N() << ", 'm.get_N()' = " << m.get_N()
87 << ").";
88 throw spu::tools::invalid_argument(__FILE__, __LINE__, __func__, message.str());
89 }
90
91 if (get_max_n_trials() != m.get_max_n_trials())
92 {
93 if (!do_throw) return false;
94
95 std::stringstream message;
96 message << "'get_max_n_trials()' is different than 'm.get_max_n_trials()' ('get_max_n_trials()' = "
97 << get_max_n_trials() << ", 'm.get_max_n_trials()' = " << m.get_max_n_trials() << ").";
98 throw spu::tools::invalid_argument(__FILE__, __LINE__, __func__, message.str());
99 }
100
101 return true;
102}
103
104template<typename B, typename R>
105R

Callers

nothing calls this directly

Calls 2

get_NMethod · 0.45
get_max_n_trialsMethod · 0.45

Tested by

no test coverage detected