mirror of
https://github.com/catchorg/Catch2.git
synced 2025-09-17 02:25:38 +02:00
Removed C-style casts
This commit is contained in:
@@ -26,14 +26,14 @@ namespace Catch {
|
||||
|
||||
inline void addWarning( ConfigData& config, std::string const& _warning ) {
|
||||
if( _warning == "NoAssertions" )
|
||||
config.warnings = (WarnAbout::What)( config.warnings | WarnAbout::NoAssertions );
|
||||
config.warnings = static_cast<WarnAbout::What>( config.warnings | WarnAbout::NoAssertions );
|
||||
else
|
||||
throw std::runtime_error( "Unrecognised warning: '" + _warning + "'" );
|
||||
|
||||
}
|
||||
inline void setVerbosity( ConfigData& config, int level ) {
|
||||
// !TBD: accept strings?
|
||||
config.verbosity = (Verbosity::Level)level;
|
||||
config.verbosity = static_cast<Verbosity::Level>( level );
|
||||
}
|
||||
inline void setShowDurations( ConfigData& config, bool _showDurations ) {
|
||||
config.showDurations = _showDurations
|
||||
|
Reference in New Issue
Block a user