Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/include/internal
diff options
context:
space:
mode:
authorPhil Nash2011-09-29 00:43:46 -0700
committerPhil Nash2011-09-29 00:43:46 -0700
commit820c2fb6ae22ec2b5e38a1486023bb4747d3ee8e (patch)
tree02ca362ff739f55a79a4d619a5a834aadbdfd8f8 /include/internal
parent98a21bce5da374b591ca7e8669adfcfbdd88eb12 (diff)
parent6d18d4b189ecc3fa2900fc4c61aeb5b80f38ae13 (diff)
downloadcatch3-820c2fb6ae22ec2b5e38a1486023bb4747d3ee8e.tar.gz
Merge pull request #53 from wichert/warnings
Suppress compiler warnings
Diffstat (limited to 'include/internal')
-rw-r--r--include/internal/catch_capture.hpp5
-rw-r--r--include/internal/catch_common.h1
-rw-r--r--include/internal/catch_resultinfo.hpp16
-rw-r--r--include/internal/catch_section.hpp2
-rw-r--r--include/internal/catch_test_case_info.hpp6
5 files changed, 26 insertions, 4 deletions
diff --git a/include/internal/catch_capture.hpp b/include/internal/catch_capture.hpp
index 51e9d999..d348a7a8 100644
--- a/include/internal/catch_capture.hpp
+++ b/include/internal/catch_capture.hpp
@@ -559,7 +559,8 @@ public:
const char* expr = "",
bool isNot = false
)
- : m_result( expr, isNot, filename, line, macroName )
+ : m_result( expr, isNot, filename, line, macroName ),
+ m_messageStream()
{}
///////////////////////////////////////////////////////////////////////////
@@ -659,7 +660,7 @@ class ScopedInfo
public:
///////////////////////////////////////////////////////////////////////////
ScopedInfo
- ()
+ () : m_oss()
{
Hub::getResultCapture().pushScopedInfo( this );
}
diff --git a/include/internal/catch_common.h b/include/internal/catch_common.h
index d0181d19..ea2c53f0 100644
--- a/include/internal/catch_common.h
+++ b/include/internal/catch_common.h
@@ -38,6 +38,7 @@ namespace Catch
void operator = ( const NonCopyable& );
protected:
NonCopyable(){}
+ virtual ~NonCopyable() {}
};
typedef char NoType;
diff --git a/include/internal/catch_resultinfo.hpp b/include/internal/catch_resultinfo.hpp
index 016ec8c2..258cc47c 100644
--- a/include/internal/catch_resultinfo.hpp
+++ b/include/internal/catch_resultinfo.hpp
@@ -24,7 +24,14 @@ namespace Catch
///////////////////////////////////////////////////////////////////////////
ResultInfo
()
- : m_line( 0 ),
+ : m_macroName(),
+ m_filename(),
+ m_line( 0 ),
+ m_expr(),
+ m_lhs(),
+ m_rhs(),
+ m_op(),
+ m_message(),
m_result( ResultWas::Unknown ),
m_isNot( false )
{}
@@ -44,6 +51,8 @@ namespace Catch
m_filename( filename ),
m_line( line ),
m_expr( expr ),
+ m_lhs(),
+ m_rhs(),
m_op( isNotExpression( expr ) ? "!" : "" ),
m_message( message ),
m_result( result ),
@@ -54,6 +63,11 @@ namespace Catch
}
///////////////////////////////////////////////////////////////////////////
+ virtual ~ResultInfo
+ ()
+ {
+ }
+ ///////////////////////////////////////////////////////////////////////////
bool ok
()
const
diff --git a/include/internal/catch_section.hpp b/include/internal/catch_section.hpp
index 084aa21d..c953aba8 100644
--- a/include/internal/catch_section.hpp
+++ b/include/internal/catch_section.hpp
@@ -31,6 +31,8 @@ namespace Catch
std::size_t line
)
: m_name( name ),
+ m_successes(0),
+ m_failures(0),
m_sectionIncluded( Hub::getResultCapture().sectionStarted( name, description, filename, line, m_successes, m_failures ) )
{
}
diff --git a/include/internal/catch_test_case_info.hpp b/include/internal/catch_test_case_info.hpp
index 4e88bc4f..e27a084d 100644
--- a/include/internal/catch_test_case_info.hpp
+++ b/include/internal/catch_test_case_info.hpp
@@ -42,7 +42,11 @@ namespace Catch
///////////////////////////////////////////////////////////////////////
TestCaseInfo
()
- : m_test( NULL )
+ : m_test( NULL ),
+ m_name(),
+ m_description(),
+ m_filename(),
+ m_line( 0 )
{
}