From dfc260adf46e79b039685d554797b403d76c6bfd Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 22 Jun 2015 18:08:32 +0200 Subject: Implement member type mapping, more m.type() cleanups --- odb/relational/source.cxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'odb/relational/source.cxx') diff --git a/odb/relational/source.cxx b/odb/relational/source.cxx index 4bb8e9d..97e7ea0 100644 --- a/odb/relational/source.cxx +++ b/odb/relational/source.cxx @@ -1299,7 +1299,7 @@ traverse_object (type& c) // then cast away constness. Otherwise, we assume that the user- // provided expression handles this. // - bool cast (ma.direct () && const_type (id->type ())); + bool cast (ma.direct () && const_member (*id)); if (cast) os << "const_cast< id_type& > (" << endl; @@ -1334,7 +1334,7 @@ traverse_object (type& c) // then cast away constness. Otherwise, we assume that the user- // provided expression handles this. // - bool cast (opt_ma_set->direct () && const_type (opt->type ())); + bool cast (opt_ma_set->direct () && const_member (*opt)); if (cast) os << "const_cast< version_type& > (" << endl; @@ -1558,7 +1558,7 @@ traverse_object (type& c) // then cast away constness. Otherwise, we assume that the user- // provided expression handles this. // - bool cast (ma.direct () && const_type (id->type ())); + bool cast (ma.direct () && const_member (*id)); if (cast) os << "const_cast< id_type& > (" << endl; @@ -1593,7 +1593,7 @@ traverse_object (type& c) // then cast away constness. Otherwise, we assume that the user- // provided expression handles this. // - bool cast (opt_ma_set->direct () && const_type (opt->type ())); + bool cast (opt_ma_set->direct () && const_member (*opt)); if (cast) os << "const_cast< version_type& > (" << endl; @@ -2140,7 +2140,7 @@ traverse_object (type& c) // then cast away constness. Otherwise, we assume that the user- // provided expression handles this. // - bool cast (opt_ma_set->direct () && const_type (opt->type ())); + bool cast (opt_ma_set->direct () && const_member (*opt)); if (cast) os << "const_cast< version_type& > (" << endl; @@ -2459,7 +2459,7 @@ traverse_object (type& c) // then cast away constness. Otherwise, we assume that the user- // provided expression handles this. // - bool cast (opt_ma_set->direct () && const_type (opt->type ())); + bool cast (opt_ma_set->direct () && const_member (*opt)); if (cast) os << "const_cast< version_type& > (" << endl; -- cgit v1.1