aboutsummaryrefslogtreecommitdiff
path: root/odb/boost
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-02-28 13:09:14 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-02-28 13:09:14 +0200
commit7915f725f62d866cde7ee87778a0a71bfd920fa8 (patch)
tree3b8cc4f15a097e037a034599b29be76c61c3ff87 /odb/boost
parent7ef4fb230176addaf2a10b01fc5bc4c017721180 (diff)
Improve lazy pointer interface if C++11 is available
Diffstat (limited to 'odb/boost')
-rw-r--r--odb/boost/smart-ptr/lazy-ptr.hxx9
1 files changed, 9 insertions, 0 deletions
diff --git a/odb/boost/smart-ptr/lazy-ptr.hxx b/odb/boost/smart-ptr/lazy-ptr.hxx
index 8df56e7..c2afe00 100644
--- a/odb/boost/smart-ptr/lazy-ptr.hxx
+++ b/odb/boost/smart-ptr/lazy-ptr.hxx
@@ -15,6 +15,7 @@
#include <odb/forward.hxx> // odb::database
#include <odb/traits.hxx>
#include <odb/lazy-ptr-impl.hxx>
+#include <odb/details/config.hxx> // ODB_CXX11
namespace odb
{
@@ -112,7 +113,11 @@ namespace odb
template <class Y> void reset (database_type&, std::auto_ptr<Y>&);
template <class Y> void reset (database_type&, const ::boost::shared_ptr<Y>&);
+#ifdef ODB_CXX11
+ template <class O = T>
+#else
template <class O /* = T */>
+#endif
typename object_traits<O>::id_type object_id () const;
database_type& database () const;
@@ -215,7 +220,11 @@ namespace odb
// The object_id() function can only be called when the object is
// persistent, or: expired() XOR loaded() (can use != for XOR).
//
+#ifdef ODB_CXX11
+ template <class O = T>
+#else
template <class O /* = T */>
+#endif
typename object_traits<O>::id_type object_id () const;
database_type& database () const;