mirror of
https://github.com/mat007/turtle.git
synced 2026-06-22 12:13:43 +00:00
Remove support for auto_ptr
This commit is contained in:
parent
c7873cde4b
commit
cf5ac87499
7 changed files with 0 additions and 150 deletions
|
|
@ -32,12 +32,6 @@
|
|||
# endif
|
||||
#endif
|
||||
|
||||
#if !defined(BOOST_NO_AUTO_PTR)
|
||||
# ifndef MOCK_NO_AUTO_PTR
|
||||
# define MOCK_AUTO_PTR
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if defined(__cpp_lib_uncaught_exceptions) || \
|
||||
defined(_MSC_VER) && (_MSC_VER >= 1900)
|
||||
# ifndef MOCK_NO_UNCAUGHT_EXCEPTIONS
|
||||
|
|
|
|||
|
|
@ -144,34 +144,6 @@ namespace detail
|
|||
}
|
||||
};
|
||||
|
||||
#ifdef MOCK_AUTO_PTR
|
||||
template< typename Result, typename Signature >
|
||||
class action< std::auto_ptr< Result >, Signature >
|
||||
: public action_base< std::auto_ptr< Result >, Signature >
|
||||
{
|
||||
public:
|
||||
template< typename Y >
|
||||
void returns( Y* r )
|
||||
{
|
||||
v_.reset( r );
|
||||
this->set( std::ref( v_ ) );
|
||||
}
|
||||
template< typename Y >
|
||||
void returns( std::auto_ptr< Y > r )
|
||||
{
|
||||
v_ = r;
|
||||
this->set( std::ref( v_ ) );
|
||||
}
|
||||
template< typename Y >
|
||||
void returns( const std::reference_wrapper< Y >& r )
|
||||
{
|
||||
this->set( r );
|
||||
}
|
||||
|
||||
private:
|
||||
mutable std::auto_ptr< Result > v_;
|
||||
};
|
||||
#endif // MOCK_AUTO_PTR
|
||||
}
|
||||
} // mock
|
||||
|
||||
|
|
|
|||
|
|
@ -61,14 +61,6 @@ namespace detail
|
|||
{};
|
||||
}
|
||||
|
||||
#ifdef MOCK_AUTO_PTR
|
||||
template< typename T >
|
||||
stream& operator<<( stream& s, const std::auto_ptr< T >& t )
|
||||
{
|
||||
return s << mock::format( t.get() );
|
||||
}
|
||||
#endif // MOCK_AUTO_PTR
|
||||
|
||||
template< typename T1, typename T2 >
|
||||
stream& operator<<( stream& s, const std::pair< T1, T2 >& p )
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue