mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-17 03:02:24 +01:00
Resolved #359
Eclipse header indexer did not handle the operator->* correctly. So rename the function from operator->* to eval can resolve the Eclipse false alert.
This commit is contained in:
parent
b9ec8a10ed
commit
c97927f242
@ -33,7 +33,7 @@
|
|||||||
do { \
|
do { \
|
||||||
Catch::ResultBuilder __catchResult( macroName, CATCH_INTERNAL_LINEINFO, #expr, resultDisposition ); \
|
Catch::ResultBuilder __catchResult( macroName, CATCH_INTERNAL_LINEINFO, #expr, resultDisposition ); \
|
||||||
try { \
|
try { \
|
||||||
( __catchResult->*expr ).endExpression(); \
|
__catchResult.eval(expr).endExpression(); \
|
||||||
} \
|
} \
|
||||||
catch( ... ) { \
|
catch( ... ) { \
|
||||||
__catchResult.useActiveException( Catch::ResultDisposition::Normal ); \
|
__catchResult.useActiveException( Catch::ResultDisposition::Normal ); \
|
||||||
|
@ -41,8 +41,8 @@ namespace Catch {
|
|||||||
ResultDisposition::Flags resultDisposition );
|
ResultDisposition::Flags resultDisposition );
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
ExpressionLhs<T const&> operator->* ( T const& operand );
|
ExpressionLhs<T const&> eval( T const& operand );
|
||||||
ExpressionLhs<bool> operator->* ( bool value );
|
ExpressionLhs<bool> eval( bool value );
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
ResultBuilder& operator << ( T const& value ) {
|
ResultBuilder& operator << ( T const& value ) {
|
||||||
@ -93,11 +93,11 @@ namespace Catch {
|
|||||||
namespace Catch {
|
namespace Catch {
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
inline ExpressionLhs<T const&> ResultBuilder::operator->* ( T const& operand ) {
|
inline ExpressionLhs<T const&> ResultBuilder::eval( T const& operand ) {
|
||||||
return ExpressionLhs<T const&>( *this, operand );
|
return ExpressionLhs<T const&>( *this, operand );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline ExpressionLhs<bool> ResultBuilder::operator->* ( bool value ) {
|
inline ExpressionLhs<bool> ResultBuilder::eval( bool value ) {
|
||||||
return ExpressionLhs<bool>( *this, value );
|
return ExpressionLhs<bool>( *this, value );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -724,8 +724,8 @@ namespace Catch {
|
|||||||
ResultDisposition::Flags resultDisposition );
|
ResultDisposition::Flags resultDisposition );
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
ExpressionLhs<T const&> operator->* ( T const& operand );
|
ExpressionLhs<T const&> eval( T const& operand );
|
||||||
ExpressionLhs<bool> operator->* ( bool value );
|
ExpressionLhs<bool> eval( bool value );
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
ResultBuilder& operator << ( T const& value ) {
|
ResultBuilder& operator << ( T const& value ) {
|
||||||
@ -1301,11 +1301,11 @@ private:
|
|||||||
namespace Catch {
|
namespace Catch {
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
inline ExpressionLhs<T const&> ResultBuilder::operator->* ( T const& operand ) {
|
inline ExpressionLhs<T const&> ResultBuilder::eval( T const& operand ) {
|
||||||
return ExpressionLhs<T const&>( *this, operand );
|
return ExpressionLhs<T const&>( *this, operand );
|
||||||
}
|
}
|
||||||
|
|
||||||
inline ExpressionLhs<bool> ResultBuilder::operator->* ( bool value ) {
|
inline ExpressionLhs<bool> ResultBuilder::eval( bool value ) {
|
||||||
return ExpressionLhs<bool>( *this, value );
|
return ExpressionLhs<bool>( *this, value );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1475,7 +1475,7 @@ namespace Catch {
|
|||||||
do { \
|
do { \
|
||||||
Catch::ResultBuilder __catchResult( macroName, CATCH_INTERNAL_LINEINFO, #expr, resultDisposition ); \
|
Catch::ResultBuilder __catchResult( macroName, CATCH_INTERNAL_LINEINFO, #expr, resultDisposition ); \
|
||||||
try { \
|
try { \
|
||||||
( __catchResult->*expr ).endExpression(); \
|
__catchResult.eval(expr).endExpression(); \
|
||||||
} \
|
} \
|
||||||
catch( ... ) { \
|
catch( ... ) { \
|
||||||
__catchResult.useActiveException( Catch::ResultDisposition::Normal ); \
|
__catchResult.useActiveException( Catch::ResultDisposition::Normal ); \
|
||||||
|
Loading…
Reference in New Issue
Block a user