|
Boost-Commit : |
From: nicola.musatti_at_[hidden]
Date: 2007-10-13 08:39:50
Author: nmusatti
Date: 2007-10-13 08:39:49 EDT (Sat, 13 Oct 2007)
New Revision: 39969
URL: http://svn.boost.org/trac/boost/changeset/39969
Log:
Updated to support C++Builder 2007 Update 3 (bcc32 5.9.2)
Text files modified:
branches/bcbboost/boost/range/as_literal.hpp | 17 ++++++++++++++---
1 files changed, 14 insertions(+), 3 deletions(-)
Modified: branches/bcbboost/boost/range/as_literal.hpp
==============================================================================
--- branches/bcbboost/boost/range/as_literal.hpp (original)
+++ branches/bcbboost/boost/range/as_literal.hpp 2007-10-13 08:39:49 EDT (Sat, 13 Oct 2007)
@@ -21,6 +21,9 @@
#include <boost/range/iterator_range.hpp>
#include <boost/range/detail/str_types.hpp>
+
+#include <boost/detail/workaround.hpp>
+
#include <cstring>
#include <cwchar>
@@ -104,15 +107,23 @@
template< class Char, std::size_t sz >
inline iterator_range<Char*> as_literal( Char (&arr)[sz] )
{
+#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x590)) && __BORLANDC__ >= 0x590
+ return boost::make_iterator_range<Char*>( arr, arr + sz - 1 );
+#else
return boost::make_iterator_range( arr, arr + sz - 1 );
+#endif
}
template< class Char, std::size_t sz >
- inline iterator_range<const Char*> as_literal( const Char (&arr)[sz] )
+ inline iterator_range<const Char*> as_literal( const Char (&arr)[sz] )
{
- return boost::make_iterator_range( arr, arr + sz - 1 );
- }
+#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x590)) && __BORLANDC__ >= 0x590
+ return boost::make_iterator_range<const Char*>( arr, arr + sz - 1 );
+#else
+ return boost::make_iterator_range( arr, arr + sz - 1 );
+#endif
+ }
}
#endif // BOOST_NO_FUNCTION_TEMPLATE_ORDERING
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk