forked from boostorg/optional
Try to make the test closer to the failing case in Beast
This commit is contained in:
committed by
Andrzej Krzemienski
parent
9e0726cee1
commit
ebef3ed6f7
@ -15,25 +15,29 @@ int main()
|
||||
#else
|
||||
|
||||
#include <boost/optional.hpp>
|
||||
#include <utility>
|
||||
|
||||
template<class T1, class T2> struct pair
|
||||
{
|
||||
T1 first;
|
||||
T2 second;
|
||||
class basic_multi_buffer;
|
||||
|
||||
pair(): first(), second()
|
||||
class const_buffers_type
|
||||
{
|
||||
}
|
||||
};
|
||||
basic_multi_buffer const* b_;
|
||||
|
||||
struct A
|
||||
{
|
||||
A() = delete;
|
||||
friend class basic_multi_buffer;
|
||||
|
||||
explicit
|
||||
const_buffers_type(basic_multi_buffer const& b);
|
||||
|
||||
public:
|
||||
|
||||
const_buffers_type() = delete;
|
||||
const_buffers_type(const_buffers_type const&) = default;
|
||||
const_buffers_type& operator=(const_buffers_type const&) = default;
|
||||
};
|
||||
|
||||
int main()
|
||||
{
|
||||
boost::optional< pair<A, int> > opt, opt2;
|
||||
boost::optional< std::pair<const_buffers_type, int> > opt, opt2;
|
||||
opt = opt2;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user