mirror of https://github.com/catchorg/Catch2.git
Fixed an issue on some compilers with implicit conversion from nullptr to Ptr
- also cleaned up some warnings to do with CATCH_NULL
This commit is contained in:
parent
62e517f833
commit
d6f1446e4e
|
@ -78,7 +78,7 @@ namespace Catch {
|
||||||
virtual ~RunContext() {
|
virtual ~RunContext() {
|
||||||
m_reporter->testRunEnded( TestRunStats( m_runInfo, m_totals, aborting() ) );
|
m_reporter->testRunEnded( TestRunStats( m_runInfo, m_totals, aborting() ) );
|
||||||
m_context.setRunner( m_prevRunner );
|
m_context.setRunner( m_prevRunner );
|
||||||
m_context.setConfig( CATCH_NULL );
|
m_context.setConfig( Ptr<IConfig const>() );
|
||||||
m_context.setResultCapture( m_prevResultCapture );
|
m_context.setResultCapture( m_prevResultCapture );
|
||||||
m_context.setConfig( m_prevConfig );
|
m_context.setConfig( m_prevConfig );
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,6 +9,9 @@
|
||||||
#include "catch.hpp"
|
#include "catch.hpp"
|
||||||
#include "catch_test_spec_parser.hpp"
|
#include "catch_test_spec_parser.hpp"
|
||||||
|
|
||||||
|
#ifdef __clang__
|
||||||
|
# pragma clang diagnostic ignored "-Wc++98-compat"
|
||||||
|
#endif
|
||||||
|
|
||||||
inline Catch::TestCase fakeTestCase( const char* name, const char* desc = "" ){ return Catch::makeTestCase( CATCH_NULL, "", name, desc, CATCH_INTERNAL_LINEINFO ); }
|
inline Catch::TestCase fakeTestCase( const char* name, const char* desc = "" ){ return Catch::makeTestCase( CATCH_NULL, "", name, desc, CATCH_INTERNAL_LINEINFO ); }
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,8 @@
|
||||||
* file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
* file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||||
*/
|
*/
|
||||||
#ifdef __clang__
|
#ifdef __clang__
|
||||||
#pragma clang diagnostic ignored "-Wpadded"
|
# pragma clang diagnostic ignored "-Wpadded"
|
||||||
|
# pragma clang diagnostic ignored "-Wc++98-compat"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "catch.hpp"
|
#include "catch.hpp"
|
||||||
|
|
|
@ -7,7 +7,8 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef __clang__
|
#ifdef __clang__
|
||||||
#pragma clang diagnostic ignored "-Wpadded"
|
# pragma clang diagnostic ignored "-Wpadded"
|
||||||
|
# pragma clang diagnostic ignored "-Wc++98-compat"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "internal/catch_test_case_tracker.hpp"
|
#include "internal/catch_test_case_tracker.hpp"
|
||||||
|
|
|
@ -1,2 +1,4 @@
|
||||||
// This file is only here to verify (to the extent possible) the self sufficiency of the header
|
// This file is only here to verify (to the extent possible) the self sufficiency of the header
|
||||||
|
#include "catch_suppress_warnings.h"
|
||||||
#include "catch_xmlwriter.hpp"
|
#include "catch_xmlwriter.hpp"
|
||||||
|
#include "catch_reenable_warnings.h"
|
||||||
|
|
|
@ -16,8 +16,9 @@ CATCH_REGISTER_TAG_ALIAS( "[@tricky]", "[tricky]~[.]" )
|
||||||
|
|
||||||
|
|
||||||
#ifdef __clang__
|
#ifdef __clang__
|
||||||
#pragma clang diagnostic ignored "-Wpadded"
|
# pragma clang diagnostic ignored "-Wpadded"
|
||||||
#pragma clang diagnostic ignored "-Wweak-vtables"
|
# pragma clang diagnostic ignored "-Wweak-vtables"
|
||||||
|
# pragma clang diagnostic ignored "-Wc++98-compat"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue