From 14392d7ca625facaf509b354f19ece627b81a4b0 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 4 Aug 2011 13:29:43 +0200 Subject: Add support for value wrappers Wrapper is a class that wraps another type. Examples of wrappers are various smart pointers, holders, etc. A wrapper can be transparent or it can handle the NULL semantics. The new odb::nullable class template is a NULL wrapper that helps to add the NULL semantics to a value type. New test: common/wrapper. --- odb/header.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'odb/header.cxx') diff --git a/odb/header.cxx b/odb/header.cxx index 62902f6..a17b111 100644 --- a/odb/header.cxx +++ b/odb/header.cxx @@ -89,6 +89,7 @@ namespace header os << "#include " << endl << "#include " << endl << "#include " << endl + << "#include " << endl << "#include " << endl; // In case of a boost TR1 implementation, we cannot distinguish @@ -99,12 +100,14 @@ namespace header if (ctx.unit.count ("tr1-pointer-used") && ctx.unit.get ("tr1-pointer-used")) { - os << "#include " << endl; + os << "#include " << endl + << "#include " << endl; } else if (ctx.unit.count ("boost-pointer-used") && ctx.unit.get ("boost-pointer-used")) { os << "#ifdef BOOST_TR1_MEMORY_HPP_INCLUDED" << endl + << "# include " << endl << "# include " << endl << "#endif" << endl; } -- cgit v1.1