mirror of
https://github.com/catchorg/Catch2.git
synced 2025-05-29 07:59:25 +00:00
Reworked stringification layer, removed Catch::toString
Now the order of stringification checks is 1) StringMaker specialization 2) operator<< toString overloads and specializations have been removed.
This commit is contained in:
parent
40130e59b4
commit
33ed1773f4
20 changed files with 626 additions and 557 deletions
|
@ -81,7 +81,7 @@ public:
|
|||
}
|
||||
|
||||
virtual void reconstructExpression( std::string& dest ) const override {
|
||||
dest = Catch::toString( m_truthy );
|
||||
dest = ::Catch::Detail::stringify( m_truthy );
|
||||
}
|
||||
|
||||
private:
|
||||
|
@ -120,8 +120,8 @@ public:
|
|||
}
|
||||
|
||||
virtual void reconstructExpression( std::string& dest ) const override {
|
||||
std::string lhs = Catch::toString( m_lhs );
|
||||
std::string rhs = Catch::toString( m_rhs );
|
||||
std::string lhs = ::Catch::Detail::stringify( m_lhs );
|
||||
std::string rhs = ::Catch::Detail::stringify( m_rhs );
|
||||
char delim = lhs.size() + rhs.size() < 40 &&
|
||||
lhs.find('\n') == std::string::npos &&
|
||||
rhs.find('\n') == std::string::npos ? ' ' : '\n';
|
||||
|
@ -155,7 +155,7 @@ public:
|
|||
|
||||
virtual void reconstructExpression( std::string& dest ) const override {
|
||||
std::string matcherAsString = m_matcher.toString();
|
||||
dest = Catch::toString( m_arg );
|
||||
dest = ::Catch::Detail::stringify( m_arg );
|
||||
dest += ' ';
|
||||
if( matcherAsString == Detail::unprintableString )
|
||||
dest += m_matcherString;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue