[Groonga-commit] groonga/groonga [master] Add initialization of base class (std::exception).

Back to archive index

null+****@clear***** null+****@clear*****
2012年 3月 21日 (水) 10:37:43 JST


Susumu Yata	2012-03-21 10:37:43 +0900 (Wed, 21 Mar 2012)

  New Revision: fea835289bd39664856aaa7fce3c7b2fa9b6b862

  Log:
    Add initialization of base class (std::exception).
    
    In practice, initialization does nothing because std::exception
    has no member variables.

  Modified files:
    lib/dat/dat.hpp

  Modified: lib/dat/dat.hpp (+6 -3)
===================================================================
--- lib/dat/dat.hpp    2012-03-19 17:47:34 +0900 (4c05b1e)
+++ lib/dat/dat.hpp    2012-03-21 10:37:43 +0900 (d2a31cd)
@@ -170,15 +170,18 @@ enum ErrorCode {
 class Exception : public std::exception {
  public:
   Exception() throw()
-      : file_(""),
+      : std::exception(),
+        file_(""),
         line_(-1),
         what_("") {}
   Exception(const char *file, int line, const char *what) throw()
-      : file_(file),
+      : std::exception(),
+        file_(file),
         line_(line),
         what_((what != NULL) ? what : "") {}
   Exception(const Exception &ex) throw()
-      : file_(ex.file_),
+      : std::exception(ex),
+        file_(ex.file_),
         line_(ex.line_),
         what_(ex.what_) {}
   virtual ~Exception() throw() {}




Groonga-commit メーリングリストの案内
Back to archive index