aboutsummaryrefslogtreecommitdiff
path: root/odb/pragma.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2011-04-25 15:02:43 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2011-04-25 15:02:43 +0200
commit1a6a0652a6ef5b319cfc8ad05a0acee6910f7560 (patch)
tree40605db91ed90c342a9074308bd7406008b4f10b /odb/pragma.cxx
parent9c5b2f928699a6752d7c3d1a062bac7efc247c64 (diff)
Add support for abstract object types
Diffstat (limited to 'odb/pragma.cxx')
-rw-r--r--odb/pragma.cxx15
1 files changed, 14 insertions, 1 deletions
diff --git a/odb/pragma.cxx b/odb/pragma.cxx
index 8cfc3fa..d8f3aef 100644
--- a/odb/pragma.cxx
+++ b/odb/pragma.cxx
@@ -128,7 +128,8 @@ check_decl_type (tree d, string const& name, string const& p, location_t l)
}
}
else if (p == "object" ||
- p == "pointer")
+ p == "pointer" ||
+ p == "abstract")
{
if (tc != RECORD_TYPE)
{
@@ -365,6 +366,18 @@ handle_pragma (cpp_reader* reader,
tt = pragma_lex (&t);
}
+ else if (p == "abstract")
+ {
+ // abstract
+ //
+
+ // Make sure we've got the correct declaration type.
+ //
+ if (decl != 0 && !check_decl_type (decl, decl_name, p, loc))
+ return;
+
+ tt = pragma_lex (&t);
+ }
else if (p == "id")
{
// id