From 91afcb9c08a99029b9a8a0834e582599607207ae Mon Sep 17 00:00:00 2001 From: Marcus Winter Date: Tue, 24 Feb 2015 15:59:16 +0100 Subject: [PATCH] base_cpp: added override for std::exception::what in embb::base::Exception --- base_cpp/include/embb/base/exceptions.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/base_cpp/include/embb/base/exceptions.h b/base_cpp/include/embb/base/exceptions.h index 7d503bf..b3ce6b6 100644 --- a/base_cpp/include/embb/base/exceptions.h +++ b/base_cpp/include/embb/base/exceptions.h @@ -175,6 +175,16 @@ class Exception : public std::exception { } /** + * Returns the error message. + * This is here for compatibility with std::exception. + * + * \return Pointer to error message + */ + virtual const char* what() const throw() { + return What(); + } + + /** * Returns an integer code representing the exception. * * \return %Exception code -- libgit2 0.26.0