[Boost-bugs] [Boost C++ Libraries] #9938: sp_array_test.cpp doesn't compile on clang++ without c++11

Subject: [Boost-bugs] [Boost C++ Libraries] #9938: sp_array_test.cpp doesn't compile on clang++ without c++11
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-04-22 15:09:55


#9938: sp_array_test.cpp doesn't compile on clang++ without c++11
------------------------------+--------------------------------
 Reporter: chris.cooper@… | Owner: grafik
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: Regression Testing
  Version: Boost 1.54.0 | Severity: Problem
 Keywords: |
------------------------------+--------------------------------
 Compiling libs/smart_ptr/test/sp_array_test.cpp fails with both clang++
 and g++ (compilers that came with Xcode 5.1, "Apple LLVM version 5.1
 (clang-503.0.38) (based on LLVM 3.4svn)") unless c++11 is specified. The
 error is:

 sp_array_test.cpp:204:32: error: no matching constructor for
 initialization of 'boost::shared_ptr<X []>'
         boost::shared_ptr<X[]> px2( std::move( px ) );
 note: candidate constructor (the implicit copy constructor) not viable: no
 known conversion from 'unique_ptr<X [], std::__1::default_delete<X []> >'
 to 'const boost::shared_ptr<X []>' for 1st argument

 One fix is to replace line 197
 #if !defined( BOOST_NO_CXX11_SMART_PTR )
 with
 #if !defined( BOOST_NO_CXX11_SMART_PTR ) && !defined(
 BOOST_NO_CXX11_RVALUE_REFERENCES)

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/9938>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:16 UTC