Move LazyExpr's and MessageInfo's implementation to the combined TU

Some of the implementations were inlined instead.
This commit is contained in:
Martin Hořeňovský committed 2020-05-10 20:21:04 +02:00
1 parent 27f1756d8e
commit f64487bf70
6 files changed
+61 -61

No files matched your search

-30
View File
@@ -1,30 +0,0 @@
#include <catch2/internal/catch_lazy_expr.hpp>
#include <catch2/internal/catch_decomposer.hpp>
namespace Catch {
namespace {
auto operator <<(std::ostream& os, ITransientExpression const& expr) -> std::ostream& {
expr.streamReconstructedExpression(os);
return os;
}
}
auto operator << (std::ostream& os, LazyExpression const& lazyExpr) -> std::ostream& {
if (lazyExpr.m_isNegated)
os << "!";
if (lazyExpr) {
if (lazyExpr.m_isNegated && lazyExpr.m_transientExpression->isBinaryExpression())
os << "(" << *lazyExpr.m_transientExpression << ")";
else
os << *lazyExpr.m_transientExpression;
} else {
os << "{** error - unchecked empty expression requested **}";
}
return os;
}
} // namespace Catch