mirror of
https://github.com/boostorg/system.git
synced 2025-07-31 21:14:26 +02:00
Add a deleted T const& conversion for clang-6 and earlier
This commit is contained in:
@@ -330,7 +330,7 @@ public:
|
|||||||
{
|
{
|
||||||
if( flags_ != 1 )
|
if( flags_ != 1 )
|
||||||
{
|
{
|
||||||
std::error_code e2 = *this;
|
std::error_code e2( *this );
|
||||||
::new( d2_ ) std::error_code( e2 );
|
::new( d2_ ) std::error_code( e2 );
|
||||||
flags_ = 1;
|
flags_ = 1;
|
||||||
}
|
}
|
||||||
@@ -338,6 +338,14 @@ public:
|
|||||||
return *reinterpret_cast<std::error_code*>( d2_ );
|
return *reinterpret_cast<std::error_code*>( d2_ );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(__clang__) && __clang_major__ < 7
|
||||||
|
|
||||||
|
template<class T,
|
||||||
|
class E = typename std::enable_if<std::is_same<T, std::error_code>::value>::type>
|
||||||
|
operator T const& () = delete;
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
template<class Ch, class Tr>
|
template<class Ch, class Tr>
|
||||||
|
Reference in New Issue
Block a user