diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2011-03-10 12:07:10 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2011-03-21 15:40:00 +0200 |
commit | fa1fa57d5fe1cb901520f03e7f802a156aae1034 (patch) | |
tree | b97d57e4a1262add1ff57f76bdbbf9b4b1495e0f /odb/relational | |
parent | b0f28bd39db1732db794c6ba1f02d244bce0641c (diff) |
Move the rest of generators to new ctor-less context
Diffstat (limited to 'odb/relational')
-rw-r--r-- | odb/relational/type-processor.cxx | 34 |
1 files changed, 18 insertions, 16 deletions
diff --git a/odb/relational/type-processor.cxx b/odb/relational/type-processor.cxx index 7b5eb13..52bec34 100644 --- a/odb/relational/type-processor.cxx +++ b/odb/relational/type-processor.cxx @@ -12,26 +12,28 @@ using namespace std; -// Indirect (dynamic) context values. -// -static semantics::type* -id_tree_type (context& c) -{ - semantics::data_member& id (c.id_member (*c.object)); - return &id.type (); -} - -static string -id_column_type (context& c) -{ - semantics::data_member& id (c.id_member (*c.object)); - return id.get<string> ("ref-column-type"); -} - namespace relational { namespace { + // Indirect (dynamic) context values. + // + static semantics::type* + id_tree_type () + { + context& c (context::current ()); + semantics::data_member& id (context::id_member (*c.object)); + return &id.type (); + } + + static string + id_column_type () + { + context& c (context::current ()); + semantics::data_member& id (context::id_member (*c.object)); + return id.get<string> ("ref-column-type"); + } + struct data_member: traversal::data_member, context { data_member () |