aboutsummaryrefslogtreecommitdiff
path: root/cutl/exception.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2009-09-19 08:20:12 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2009-09-19 08:20:12 +0200
commit6ca1c8ee64bf7268d194eb15e72d3024a335039d (patch)
tree8876f51d9392f35c27eca83126fb9732e01bd916 /cutl/exception.hxx
parentf0fb6aeab118255266370121db79ab2a2fed88ad (diff)
Add root exception class
Derive all other exceptions from it.
Diffstat (limited to 'cutl/exception.hxx')
-rw-r--r--cutl/exception.hxx22
1 files changed, 22 insertions, 0 deletions
diff --git a/cutl/exception.hxx b/cutl/exception.hxx
new file mode 100644
index 0000000..242057b
--- /dev/null
+++ b/cutl/exception.hxx
@@ -0,0 +1,22 @@
+// file : cutl/exception.hxx
+// author : Boris Kolpackov <boris@codesynthesis.com>
+// copyright : Copyright (c) 2009 Code Synthesis Tools CC
+// license : MIT; see accompanying LICENSE file
+
+#ifndef CUTL_EXCEPTION_HXX
+#define CUTL_EXCEPTION_HXX
+
+#include <exception>
+
+namespace cutl
+{
+ struct exception: std::exception
+ {
+ // By default return the exception type name ( typeid (*this).name () ).
+ //
+ virtual char const*
+ what () const throw ();
+ };
+}
+
+#endif // CUTL_EXCEPTION_HXX