upgrade to v2

[SVN r34012]
This commit is contained in:
Thorsten Jørgen Ottosen
2006-05-18 20:52:17 +00:00
parent dc96b440be
commit 554f832234
25 changed files with 248 additions and 1291 deletions

View File

@ -16,52 +16,19 @@
#endif
#include <boost/range/config.hpp>
//#ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
//#include <boost/range/detail/empty.hpp>
//#else
#include <boost/range/begin.hpp>
#include <boost/range/end.hpp>
namespace boost
{
namespace range_detail
{
//////////////////////////////////////////////////////////////////////
// primary template
//////////////////////////////////////////////////////////////////////
template< typename C >
inline bool empty( const C& c )
{
return boost::begin( c ) == boost::end( c );
}
//////////////////////////////////////////////////////////////////////
// string
//////////////////////////////////////////////////////////////////////
inline bool empty( const char* const& s )
{
return s == 0 || s[0] == 0;
}
inline bool empty( const wchar_t* const& s )
{
return s == 0 || s[0] == 0;
}
} // namespace 'range_detail'
template< class T >
inline bool empty( const T& r )
{
return range_detail::empty( r );
}
template< class T >
inline bool empty( const T& r )
{
return boost::begin( r ) == boost::end( r );
}
} // namepace 'boost'
//#endif // BOOST_NO_FUNCTION_TEMPLATE_ORDERING
#endif