-#include <typeinfo>
#include <msp/debug/demangle.h>
#include <msp/strings/format.h>
#include "except.h"
logic_error(w)
{ }
+
+unknown_keyword::unknown_keyword(const string &k):
+ runtime_error(k)
+{ }
+
+
+invalid_signature::invalid_signature(const string &k, const string &s):
+ runtime_error(format("%s %s", k, s))
+{ }
+
+
+no_collection::no_collection(const type_info &t):
+ runtime_error(Debug::demangle(t.name()))
+{ }
+
} // namespace DataFile
} // namespace Msp
#define MSP_DATAFILE_EXCEPT_H_
#include <stdexcept>
+#include <typeinfo>
namespace Msp {
namespace DataFile {
virtual ~nesting_error() throw() { }
};
+
+class unknown_keyword: public std::runtime_error
+{
+public:
+ unknown_keyword(const std::string &);
+ virtual ~unknown_keyword() throw() { }
+};
+
+
+class invalid_signature: public std::runtime_error
+{
+public:
+ invalid_signature(const std::string &, const std::string &);
+ virtual ~invalid_signature() throw() { }
+};
+
+
+class no_collection: public std::runtime_error
+{
+public:
+ no_collection(const std::type_info &);
+};
+
} // namespace DataFile
} // namespace Msp
namespace Msp {
namespace DataFile {
-class unknown_keyword: public runtime_error
-{
-public:
- unknown_keyword(const std::string &k):
- runtime_error(k)
- { }
-
- virtual ~unknown_keyword() throw() { }
-};
-
-
-class invalid_signature: public runtime_error
-{
-public:
- invalid_signature(const std::string &k, const std::string &s):
- runtime_error(format("%s %s", k, s))
- { }
-
- virtual ~invalid_signature() throw() { }
-};
-
-
Loader::Loader():
cur_st(0),
direct(false),
+++ /dev/null
-#include <msp/debug/demangle.h>
-#include "objectloader.h"
-
-using namespace std;
-
-namespace Msp {
-namespace DataFile {
-
-no_collection::no_collection(const type_info &t):
- runtime_error(Debug::demangle(t.name()))
-{ }
-
-} // namespace DataFile
-} // namespace Msp
#ifndef MSP_DATAFILE_OBJECTLOADER_H_
#define MSP_DATAFILE_OBJECTLOADER_H_
-#include <typeinfo>
+#include "except.h"
#include "loader.h"
namespace Msp {
namespace DataFile {
-class no_collection: public std::runtime_error
-{
-public:
- no_collection(const std::type_info &);
-};
-
class Collection;
/**