aboutsummaryrefslogtreecommitdiff
path: root/odb/plugin.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-07-30 12:25:16 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-07-30 12:25:16 +0200
commit9c9b8f3a03951e1b7cc489ce0ec018a03520c039 (patch)
treee801867e11963a13d138a4704d7df67ece226f2d /odb/plugin.cxx
parent001b34dc49b140ce689f82579032108e0a2883da (diff)
Handle regex_format exception at top level
Diffstat (limited to 'odb/plugin.cxx')
-rw-r--r--odb/plugin.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/odb/plugin.cxx b/odb/plugin.cxx
index 73ada7a..8920521 100644
--- a/odb/plugin.cxx
+++ b/odb/plugin.cxx
@@ -11,6 +11,7 @@
#include <cassert>
#include <iostream>
+#include <cutl/re.hxx>
#include <cutl/fs/path.hxx>
#include <odb/pragma.hxx>
@@ -137,6 +138,12 @@ gate_callback (void*, void*)
generator g;
g.generate (*options_, f, *u, file_);
}
+ catch (cutl::re::format const& e)
+ {
+ cerr << "error: invalid regex: '" << e.regex () << "': " <<
+ e.description () << endl;
+ r = 1;
+ }
catch (pragmas_failed const&)
{
// Diagnostics has aready been issued.