diff options
-rw-r--r-- | odb/no-id-object-result.hxx | 6 | ||||
-rw-r--r-- | odb/polymorphic-object-result.hxx | 6 | ||||
-rw-r--r-- | odb/result.hxx | 4 | ||||
-rw-r--r-- | odb/result.txx | 4 | ||||
-rw-r--r-- | odb/simple-object-result.hxx | 6 | ||||
-rw-r--r-- | odb/view-result.hxx | 6 |
6 files changed, 20 insertions, 12 deletions
diff --git a/odb/no-id-object-result.hxx b/odb/no-id-object-result.hxx index a663f41..b96dbcb 100644 --- a/odb/no-id-object-result.hxx +++ b/odb/no-id-object-result.hxx @@ -148,10 +148,12 @@ namespace odb } public: - typename object_traits<T>::pointer_type + typedef typename object_traits<T>::pointer_type pointer_type; + + pointer_type load () { - typename object_traits<T>::pointer_type r (res_->current ()); + pointer_type r (res_->current ()); res_->release (); return r; } diff --git a/odb/polymorphic-object-result.hxx b/odb/polymorphic-object-result.hxx index 2adeaa3..82b7647 100644 --- a/odb/polymorphic-object-result.hxx +++ b/odb/polymorphic-object-result.hxx @@ -184,10 +184,12 @@ namespace odb } public: - typename object_traits<T>::pointer_type + typedef typename object_traits<T>::pointer_type pointer_type; + + pointer_type load () { - typename object_traits<T>::pointer_type r (res_->current ()); + pointer_type r (res_->current ()); res_->release (); return r; } diff --git a/odb/result.hxx b/odb/result.hxx index c40f984..8b675f0 100644 --- a/odb/result.hxx +++ b/odb/result.hxx @@ -212,7 +212,9 @@ namespace odb // query_one() and query_value() implementation details. // public: - typename object_traits<T>::pointer_type + typedef typename iterator::pointer_type pointer_type; + + pointer_type one (); bool diff --git a/odb/result.txx b/odb/result.txx index da6da3e..fce29d7 100644 --- a/odb/result.txx +++ b/odb/result.txx @@ -7,11 +7,9 @@ namespace odb { template <typename T> - typename object_traits<T>::pointer_type result<T>:: + typename result<T>::pointer_type result<T>:: one () { - typedef typename object_traits<T>::pointer_type pointer_type; - iterator i (begin ()); if (i != end ()) diff --git a/odb/simple-object-result.hxx b/odb/simple-object-result.hxx index 925896e..d944179 100644 --- a/odb/simple-object-result.hxx +++ b/odb/simple-object-result.hxx @@ -167,10 +167,12 @@ namespace odb } public: - typename object_traits<T>::pointer_type + typedef typename object_traits<T>::pointer_type pointer_type; + + pointer_type load () { - typename object_traits<T>::pointer_type r (res_->current ()); + pointer_type r (res_->current ()); res_->release (); return r; } diff --git a/odb/view-result.hxx b/odb/view-result.hxx index 6dc43d0..db4e038 100644 --- a/odb/view-result.hxx +++ b/odb/view-result.hxx @@ -175,10 +175,12 @@ namespace odb } public: - typename view_traits<T>::pointer_type + typedef typename view_traits<T>::pointer_type pointer_type; + + pointer_type load () { - typename view_traits<T>::pointer_type r (res_->current ()); + pointer_type r (res_->current ()); res_->release (); return r; } |