]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/smart_ptr/test/pointer_cast_st_fail3.cpp
2 // A negative test for unique_ptr static_cast
4 // Copyright 2016 Peter Dimov
6 // Distributed under the Boost Software License, Version 1.0.
7 // See accompanying file LICENSE_1_0.txt or copy at
8 // http://www.boost.org/LICENSE_1_0.txt
11 #include <boost/pointer_cast.hpp>
27 std::unique_ptr
<D
[]> p1( new D
[ 1 ] );
28 std::unique_ptr
<B
[]> p2
= boost::static_pointer_cast
<B
[]>( std::move( p1
) );