[Mockpp-commits] mockpp/mockpp/compat AssertionFailedError.cpp,1.15,1.16 Exception.h,1.16,1.17
Brought to you by:
ewald-arnold
From: Ewald A. <ewa...@us...> - 2005-12-03 13:10:38
|
Update of /cvsroot/mockpp/mockpp/mockpp/compat In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6135/mockpp/compat Modified Files: AssertionFailedError.cpp Exception.h Log Message: central exception handling Index: AssertionFailedError.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/compat/AssertionFailedError.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- AssertionFailedError.cpp 27 Nov 2005 17:27:57 -0000 1.15 +++ AssertionFailedError.cpp 3 Dec 2005 13:10:30 -0000 1.16 @@ -62,7 +62,7 @@ void assertionFailed(unsigned srcline, const char* srcfile, const String &message) { - MOCKPP_THROW(AssertionFailedError(srcline, srcfile, message)); + forwardMalfunctionData(AssertionFailedError(srcline, srcfile, message)); } Index: Exception.h =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/compat/Exception.h,v retrieving revision 1.16 retrieving revision 1.17 diff -u -d -r1.16 -r1.17 --- Exception.h 26 Nov 2005 17:56:44 -0000 1.16 +++ Exception.h 3 Dec 2005 13:10:30 -0000 1.17 @@ -96,6 +96,18 @@ }; +/** Handle exceptions based on errors and failures. + * The default implementation throws the object. + * @param e excption data + */ +template <typename T> +inline +void forwardMalfunctionData(const T &e) +{ + MOCKPP_THROW(e); +} + + } // namespace mockpp |