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

summaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorPhil Nash2011-09-19 18:19:13 +0100
committerPhil Nash2011-09-19 18:19:13 +0100
commit08a1b51987d57be145de0ce828bc3b054e698706 (patch)
tree013cd9b1b18a99b4e5f33a9bdaa6ba9e28af0d41 /include
parent0653f4880ba6353b0cf9444930e9101337b6fd4a (diff)
downloadcatch3-08a1b51987d57be145de0ce828bc3b054e698706.tar.gz
Hold values by value and references by reference
Diffstat (limited to 'include')
-rw-r--r--include/internal/catch_capture.hpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/internal/catch_capture.hpp b/include/internal/catch_capture.hpp
index e049d7f5..51e9d999 100644
--- a/include/internal/catch_capture.hpp
+++ b/include/internal/catch_capture.hpp
@@ -367,7 +367,7 @@ public:
Expression
(
MutableResultInfo& result,
- const T& lhs
+ T lhs
)
: m_result( result ),
m_lhs( lhs )
@@ -475,7 +475,7 @@ public:
private:
MutableResultInfo& m_result;
- const T& m_lhs;
+ T m_lhs;
};
template<typename LhsT>
@@ -564,12 +564,12 @@ public:
///////////////////////////////////////////////////////////////////////////
template<typename T>
- Expression<T> operator->*
+ Expression<const T&> operator->*
(
const T & operand
)
{
- Expression<T> expr( m_result, operand );
+ Expression<const T&> expr( m_result, operand );
return expr;
}