-/* $Id$
-
-This file is part of libmspdatafile
-Copyright © 2006 Mikko Rasa, Mikkosoft Productions
-Distributed under the LGPL
-*/
-#include <msp/strings/formatter.h>
+#include <msp/strings/format.h>
#include "binaryparser.h"
+#include "dataerror.h"
#include "parser.h"
#include "statement.h"
#include "textparser.h"
Statement Parser::parse()
{
if(!good)
- throw Exception("Parser is not good");
+ throw logic_error("Parser::parse() !good");
try
{
return st;
}
}
- catch(const Exception &e)
+ catch(const exception &e)
{
good = false;
- throw;
+ if(dynamic_cast<const data_error *>(&e))
+ throw;
+ else
+ throw data_error(src, in.get_line_number(), e);
}
}