Always default empty destructors

This commit is contained in:
Martin Hořeňovský 2023-08-05 18:21:38 +02:00
parent ed4acded38
commit b593be2116
No known key found for this signature in database
GPG Key ID: DE48307B8B0D381A
7 changed files with 7 additions and 8 deletions

View File

@ -39,7 +39,7 @@ namespace Catch {
return parsed; return parsed;
} }
EnumInfo::~EnumInfo() {} EnumInfo::~EnumInfo() = default;
StringRef EnumInfo::lookup( int value ) const { StringRef EnumInfo::lookup( int value ) const {
for( auto const& valueToName : m_values ) { for( auto const& valueToName : m_values ) {

View File

@ -31,8 +31,7 @@ namespace Catch {
} }
#endif //!defined(CATCH_CONFIG_DISABLE_EXCEPTIONS) #endif //!defined(CATCH_CONFIG_DISABLE_EXCEPTIONS)
ExceptionTranslatorRegistry::~ExceptionTranslatorRegistry() { ExceptionTranslatorRegistry::~ExceptionTranslatorRegistry() = default;
}
void ExceptionTranslatorRegistry::registerTranslator( Detail::unique_ptr<IExceptionTranslator>&& translator ) { void ExceptionTranslatorRegistry::registerTranslator( Detail::unique_ptr<IExceptionTranslator>&& translator ) {
m_translators.push_back( CATCH_MOVE( translator ) ); m_translators.push_back( CATCH_MOVE( translator ) );

View File

@ -29,7 +29,7 @@ namespace Catch {
#else // ^^ Windows crt debug heap enabled // Windows crt debug heap disabled vv #else // ^^ Windows crt debug heap enabled // Windows crt debug heap disabled vv
Catch::LeakDetector::LeakDetector() {} Catch::LeakDetector::LeakDetector() = default;
#endif // CATCH_CONFIG_WINDOWS_CRTDBG #endif // CATCH_CONFIG_WINDOWS_CRTDBG

View File

@ -13,7 +13,7 @@
namespace Catch { namespace Catch {
TagAliasRegistry::~TagAliasRegistry() {} TagAliasRegistry::~TagAliasRegistry() = default;
TagAlias const* TagAliasRegistry::find( std::string const& alias ) const { TagAlias const* TagAliasRegistry::find( std::string const& alias ) const {
auto it = m_registry.find( alias ); auto it = m_registry.find( alias );

View File

@ -12,7 +12,7 @@
namespace Catch { namespace Catch {
AutomakeReporter::~AutomakeReporter() {} AutomakeReporter::~AutomakeReporter() = default;
void AutomakeReporter::testCaseEnded(TestCaseStats const& _testCaseStats) { void AutomakeReporter::testCaseEnded(TestCaseStats const& _testCaseStats) {
// Possible values to emit are PASS, XFAIL, SKIP, FAIL, XPASS and ERROR. // Possible values to emit are PASS, XFAIL, SKIP, FAIL, XPASS and ERROR.

View File

@ -249,6 +249,6 @@ private:
StreamingReporterBase::testRunEnded( _testRunStats ); StreamingReporterBase::testRunEnded( _testRunStats );
} }
CompactReporter::~CompactReporter() {} CompactReporter::~CompactReporter() = default;
} // end namespace Catch } // end namespace Catch

View File

@ -45,7 +45,7 @@ namespace Catch {
} // end anonymous namespace } // end anonymous namespace
TeamCityReporter::~TeamCityReporter() {} TeamCityReporter::~TeamCityReporter() = default;
void TeamCityReporter::testRunStarting( TestRunInfo const& runInfo ) { void TeamCityReporter::testRunStarting( TestRunInfo const& runInfo ) {
m_stream << "##teamcity[testSuiteStarted name='" << escape( runInfo.name ) m_stream << "##teamcity[testSuiteStarted name='" << escape( runInfo.name )