diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2014-01-19 10:05:08 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2014-01-19 10:06:32 +0200 |
commit | 0fdf19714613a82a184f4f6e75fb9a4f9b62f18a (patch) | |
tree | 93bb2df0f9d9eab44d36dedf29d4df500ecefcbc /libxsd/xsd/cxx/parser/validating/xml-schema-pimpl.txx | |
parent | 45db924dfc19b49b7930522dbddd123fb9575e32 (diff) |
Use std::unique_ptr instead of std::auto_ptr in C++11 mode
Diffstat (limited to 'libxsd/xsd/cxx/parser/validating/xml-schema-pimpl.txx')
-rw-r--r-- | libxsd/xsd/cxx/parser/validating/xml-schema-pimpl.txx | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/libxsd/xsd/cxx/parser/validating/xml-schema-pimpl.txx b/libxsd/xsd/cxx/parser/validating/xml-schema-pimpl.txx index 021cca8..6631dd2 100644 --- a/libxsd/xsd/cxx/parser/validating/xml-schema-pimpl.txx +++ b/libxsd/xsd/cxx/parser/validating/xml-schema-pimpl.txx @@ -6,6 +6,10 @@ #include <limits> #include <locale> +#ifdef XSD_CXX11 +# include <utility> // std::move +#endif + #include <xsd/cxx/zc-istream.hxx> #include <xsd/cxx/parser/validating/exceptions.hxx> @@ -1634,10 +1638,14 @@ namespace xsd } template <typename C> - std::auto_ptr<buffer> base64_binary_pimpl<C>:: + XSD_AUTO_PTR<buffer> base64_binary_pimpl<C>:: post_base64_binary () { +#ifdef XSD_CXX11 + return std::move (buf_); +#else return buf_; +#endif } // hex_binary @@ -1721,10 +1729,14 @@ namespace xsd } template <typename C> - std::auto_ptr<buffer> hex_binary_pimpl<C>:: + XSD_AUTO_PTR<buffer> hex_binary_pimpl<C>:: post_hex_binary () { +#ifdef XSD_CXX11 + return std::move (buf_); +#else return buf_; +#endif } // time_zone |